/*  NOTE1 Make pages and images crisper and clearer
@keyframes scan {
    0% {
        top: -2px;
    }
    100% {
        top: 100vh;
    }
}
*/

/* ── GALLERY ── */

.gallery-category-section {
    position: relative;
    z-index: 10;
    margin-bottom: 0;
    display: none;
}

.gallery-category-section.visible {
    display: block;
}

.gallery-cat-tabs {
    position: relative;
    z-index: 10;
    display: flex;
    gap: 5px;
    border-bottom: 1px solid var(--border);
    overflow: hidden;
}

.gallery-cat-tab {
    padding-right: 30px;
    font-family: 'Share Tech Mono', monospace;
    font-size: 1rem;
    font-weight: 900;
    letter-spacing: 0.3em;
    color: var(--text2);
    border: none;
    background: transparent;
    position: relative;
    transition: color 0.25s;
    display: inline-flex;
}

.gallery-cat-tab::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--accent, var(--c));
    transform: scaleX(0);
    transition: transform 0.25s;
    box-shadow: 0 0 10px var(--accent, var(--c));
}

.gallery-cat-tab.active {
    color: var(--accent, var(--c));
}

.gallery-cat-tab.active::after, .gallery-cat-tab:hover::after {
    transform: scaleX(1);
}

.gallery-cat-tab:hover {
    color: var(--accent, var(--c));
}

/* ── SECTION HEADER ── */
.gallery-header {
    position: relative;
    z-index: 10;
    padding: 28px 72px 0;
    display: flex;
    align-items: center;
    gap: 10px;
}

/* ── PROJECTS GRID ── */
.projects-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 3px;
    padding-top: 10px;
}

/* ── PROJECT CARD ── */
.project-card {
    position: relative;
    background: var(--bg2);
    border: 1px solid var(--border-c);
    overflow: hidden;
    transition: border-color 0.3s;
}

.project-card:hover {
    border-color: var(--yellow);
}

/* corner brackets */
.brk {
    position: absolute;
    width: 14px;
    height: 14px;
    z-index: 6;
    pointer-events: none;
}

.brk.tl {
    top: 8px;
    left: 8px;
    border-top: 1px solid var(--accent, var(--c));
    border-left: 1px solid var(--accent, var(--c));
}

.brk.tr {
    top: 8px;
    right: 8px;
    border-top: 1px solid var(--accent, var(--c));
    border-right: 1px solid var(--accent, var(--c));
}

.brk.bl {
    bottom: 8px;
    left: 8px;
    border-bottom: 1px solid var(--accent, var(--c));
    border-left: 1px solid var(--accent, var(--c));
}

.brk.br {
    bottom: 8px;
    right: 8px;
    border-bottom: 1px solid var(--accent, var(--c));
    border-right: 1px solid var(--accent, var(--c));
}

/* accent top line */
.card-accent {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    /*  NOTE1 Make pages and images crisper and clearer
    background: linear-gradient(90deg, transparent, var(--accent, var(--c)), transparent);
    */
    box-shadow: 0 0 12px var(--accent, var(--c));
    z-index: 5;
    transform: scaleX(0);
    transition: transform 0.4s ease;
}

.project-card:hover .card-accent {
    transform: scaleX(1);
}

/* ── IMAGE ZONE ── */
.img-zone {
    position: relative;
    height: 360px;
    overflow: hidden;
    cursor: zoom-in;
}

.img-zone img.main-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    filter: saturate(0.65) brightness(0.8);
    transition: transform 0.5s ease, filter 0.4s ease, opacity 0.2s ease;
}

.project-card:hover .img-zone img.main-img {
    transform: scale(1.04);
    filter: saturate(0.85) brightness(0.85);
}

.img-zone img.main-img.fading {
    opacity: 0;
}

/* gradient bottom */
.img-zone::after {
    content: '';
    position: absolute;
    inset: 0;
    /*  NOTE1 Make pages and images crisper and clearer
    background: linear-gradient(180deg, transparent 50%, rgba(6, 13, 24, 0.97) 100%);
    */
    pointer-events: none;
    z-index: 2;
}

/* zoom hint */
.zoom-hint {
    position: absolute;
    align-content: center;
    bottom: 20px;
    right: 20px;
    font-family: 'Share Tech Mono', monospace;
    font-size: 2rem;
    letter-spacing: 2px;
    color: var(--white);
    z-index: 4;
    opacity: 0;
    transition: opacity 0.3s;
}

.img-zone:hover .zoom-hint {
    opacity: 1;
}

/* ── THUMBNAILS ── */
.thumbs-row {
    display: flex;
    gap: 2px;
    padding: 8px 14px;
    background: rgba(2, 5, 12, 0.95);
    border-bottom: 1px solid var(--border);
}

.thumb-btn {
    position: relative;
    width: 72px;
    height: 46px;
    overflow: hidden;
    cursor: pointer;
    border: 1px solid rgba(255, 255, 255, 0.08);
    flex-shrink: 0;
    transition: border-color 0.2s, transform 0.2s;
    background: none;
    padding: 0;
}

.thumb-btn:hover {
    border-color: var(--accent, var(--c));
    transform: translateY(-2px);
}

.thumb-btn.active {
    border-color: var(--accent, var(--c));
    box-shadow: 0 0 10px rgba(0, 255, 231, 0.25);
}

.thumb-btn img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: saturate(0.5) brightness(0.65);
    transition: filter 0.2s;
}

.thumb-btn:hover img, .thumb-btn.active img {
    filter: saturate(0.9) brightness(0.85);
}

.thumb-btn::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--accent, var(--c));
    transform: scaleX(0);
    transition: transform 0.2s;
}

.thumb-btn.active::after {
    transform: scaleX(1);
}

.thumb-n {
    position: absolute;
    bottom: 2px;
    right: 3px;
    font-family: 'Share Tech Mono', monospace;
    font-size: 7px;
    color: rgba(255, 255, 255, 0.3);
    pointer-events: none;
}

/* ── PROJECT BODY ── */
.project-body {
    padding: 20px 22px 22px;
    display: grid;
    grid-template-columns: 1fr;
    gap: 0;
}

.proj-badge {
    font-family: 'Share Tech Mono', monospace;
    font-size: 0.9rem;
    letter-spacing: 3px;
    color: var(--accent, var(--c));
    margin-bottom: 7px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.proj-name {
    font-family: 'Orbitron', monospace;
    text-transform: uppercase;
    font-size: 1.2rem;
    font-weight: 700;
    color: #fff;
    letter-spacing: 2px;
    line-height: 2rem;
    margin-bottom: 6px;
    text-shadow: 0 0 20px rgba(255, 255, 255, 0.15);
}

/* ── INFO  ── */
.info-section {
    margin-bottom: 14px;
}

.info-label {
    font-family: 'Share Tech Mono', monospace;
    font-size: 0.9rem;
    letter-spacing: 3px;
    color: var(--accent, var(--c));
    margin-bottom: 7px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.info-label::after {
    content: '';
    flex: 1;
    height: 1px;
    background: linear-gradient(90deg, var(--border2), transparent);
}

.info-text {
    font-size: 0.9rem;
    color: rgba(142, 207, 204, 0.75);
    line-height: 1.65;
    letter-spacing: 0.3px;
}

/* software pills */
.sw-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.sw-pill {
    font-family: 'Share Tech Mono', monospace;
    font-size: 0.9rem;
    letter-spacing: 2px;
    padding: 4px 10px;
    border: 1px solid rgba(0, 255, 231, 0.2);
    color: var(--c);
    background: rgba(0, 255, 231, 0.04);
    clip-path: polygon(6px 0%, 100% 0%, calc(100% - 6px) 100%, 0% 100%);
}

.sw-pill.alt {
    border-color: rgba(255, 45, 120, 0.25);
    color: var(--c2);
    background: rgba(255, 45, 120, 0.04);
}

.sw-pill.tri {
    border-color: rgba(255, 230, 0, 0.25);
    color: var(--c3);
    background: rgba(255, 230, 0, 0.04);
}

/* tag pills */
.tag-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
}

.tag-pill {
    font-family: 'Share Tech Mono', monospace;
    font-size: 0.9rem;
    letter-spacing: 2px;
    padding: 3px 9px;
    border: 1px solid var(--border);
    color: var(--text2);
    background: transparent;
    text-transform: uppercase;
}

/* timeline */
.timeline {
    display: flex;
    align-items: center;
    gap: 0;
    position: relative;
}

.tl-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex: 1;
    position: relative;
}

.tl-step::before {
    content: '';
    position: absolute;
    top: 7px;
    left: calc(50% + 7px);
    right: calc(-50% + 7px);
    height: 1px;
    background: var(--border);
}

.tl-step:last-child::before {
    display: none;
}

.tl-dot {
    width: 14px;
    height: 14px;
    border: 1px solid var(--accent, var(--c));
    background: var(--bg2);
    position: relative;
    z-index: 1;
    margin-bottom: 6px;
    transform: rotate(45deg);
    transition: background 0.3s;
}

.tl-dot.done {
    background: var(--accent, var(--c));
    box-shadow: 0 0 8px var(--accent, var(--c));
}

.tl-label {
    font-family: 'Share Tech Mono', monospace;
    font-size: 7px;
    letter-spacing: 1px;
    color: var(--text2);
    text-align: center;
    line-height: 1.3;
}

.tl-label.done {
    color: var(--accent, var(--c));
}

/* ── LIGHTBOX ── */
#lightbox {
    position: fixed;
    inset: 0;
    background: var(--bg2);
    z-index: 10000;
    display: none;
    align-items: center;
    justify-content: center;
}

#lightbox.open {
    display: flex;
    animation: lbIn 0.3s ease;
}

@keyframes lbIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.lb-inner {
    position: relative;
    max-width: 90vw;
    max-height: 80vh;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.lb-img-wrap {
    position: relative;
    border: 1px solid var(--border2);
    box-shadow: 0 0 60px rgba(0, 255, 231, 0.1), 0 0 120px rgba(0, 255, 231, 0.05);
}

.lb-img-wrap::before, .lb-img-wrap::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    z-index: 2;
}

.lb-img-wrap::before {
    top: -1px;
    left: -1px;
    border-top: 2px solid var(--c);
    border-left: 2px solid var(--c);
}

.lb-img-wrap::after {
    bottom: -1px;
    right: -1px;
    border-bottom: 2px solid var(--c);
    border-right: 2px solid var(--c);
}

#lb-img {
    display: block;
    max-width: 85vw;
    max-height: 80vh;
    object-fit: contain;
    filter: saturate(0.9);
}

.lb-close {
    position: absolute;
    top: -18px;
    right: -18px;
    width: 36px;
    height: 36px;
    background: var(--bg2);
    border: 1px solid var(--border2);
    color: var(--c);
    font-family: 'Share Tech Mono', monospace;
    font-size: 14px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s, color 0.2s;
    z-index: 10;
}

.lb-close:hover {
    background: var(--c);
    color: var(--bg);
}

.lb-caption {
    margin-top: 14px;
    font-family: 'Share Tech Mono', monospace;
    font-size: 1rem;
    letter-spacing: 3px;
    color: var(--text2);
}

/*  NOTE1 Make pages and images crisper and clearer
.lb-scan {
    position: absolute;
    inset: 0;
    background: repeating-linear-gradient(0deg, transparent, transparent 2px, rgba(0, 0, 0, 0.12) 2px, rgba(0, 0, 0, 0.12) 4px);
    pointer-events: none;
    z-index: 3;
}
*/
/* lb grid overlay */
#lightbox::before {
    content: '';
    position: fixed;
    inset: 0;
    background: linear-gradient(rgba(0, 255, 231, 0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 255, 231, 0.02) 1px, transparent 1px);
    background-size: 60px 60px;
    pointer-events: none;
    z-index: 0;
}

/* ── RESPONSIVE ── */
@media (max-width: 900px) {
    .gallery-cat-tabs, .gallery-header, .projects-grid, .projects-grid {
        grid-template-columns: 1fr;
    }
}
