:root {
    --bg-dark: #050505;
    --gold: #d4af37;
    --gold-dim: #8a7122;
    --dark-grey: #1a1a1a;
    --text-main: #e0e0e0;

    --font-heading: 'Cinzel', serif;
    --font-tech: 'Rajdhani', sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    scrollbar-width: none;
    /* Firefox */
    -ms-overflow-style: none;
    /* IE/Edge */
}

*::-webkit-scrollbar {
    display: none;
    /* Chrome/Safari/Opera */
    width: 0;
    height: 0;
}

body {
    background-color: var(--bg-dark);
    color: var(--text-main);
    font-family: var(--font-tech);
    overflow-x: hidden;
}

/* Canvas Background */
#poly-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

.vignette {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, transparent 40%, black 100%);
    z-index: -1;
    pointer-events: none;
}

/* Header Removed */

/* Hex Navigation */
.hex-nav {
    position: fixed;
    left: 20px;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    gap: 8px;
    z-index: 400;
}

.hex-link {
    text-decoration: none;
    position: relative;
    display: flex;
    align-items: center;
}

.hex {
    width: 42px;
    /* Reduced slightly to fit more items */
    height: 48px;
    background: rgba(26, 26, 26, 0.8);
    clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
    display: flex;
    justify-content: center;
    align-items: center;
    color: var(--gold-dim);
    transition: 0.3s;
}

.hex:hover,
.hex-link.active .hex {
    background: var(--gold);
    color: black;
    transform: scale(1.1);
}

.hex i {
    font-size: 1rem;
}

.hex-link::after {
    content: attr(data-label);
    position: absolute;
    left: 50px;
    background: var(--gold);
    color: black;
    padding: 5px 10px;
    font-weight: bold;
    font-size: 0.8rem;
    clip-path: polygon(10px 0, 100% 0, 100% 100%, 0 100%);
    opacity: 0;
    transform: translateX(-10px);
    transition: 0.3s;
    pointer-events: none;
    white-space: nowrap;
    z-index: 401;
    /* Ensure tooltip is above content */
}

.hex-link:hover::after {
    opacity: 1;
    transform: translateX(0);
}


/* Layout */
main {
    margin-left: 100px;
    /* Reduced since nav is smaller */
    margin-top: 0;
    /* Add top margin to clear fixed header */
}

.screen-section {
    min-height: 100vh;
    padding: 6rem 5%;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.section-title {
    margin-bottom: 3rem;
    border-left: 4px solid var(--gold);
    padding-left: 20px;
}

.section-title h2 {
    font-family: var(--font-heading);
    color: var(--gold);
    font-size: 2.5rem;
    letter-spacing: 2px;
}

.gold-bar {
    width: 100px;
    height: 2px;
    background: var(--gold);
    margin-top: 10px;
}

/* Loader */
#loader {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: #050505;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    transition: opacity 0.8s ease-out, visibility 0.8s;
}

#loader.loaded {
    opacity: 0;
    visibility: hidden;
}

.sr-logo {
    width: 300px;
    height: 150px;
    margin: 0 auto;
    /* Removed bottom margin */
    display: block;
}

.sr-text {
    font-family: var(--font-heading);
    font-size: 100px;
    font-weight: bold;
    fill: transparent;
    stroke: var(--gold);
    stroke-width: 2px;
    stroke-dasharray: 400;
    stroke-dashoffset: 400;
    animation: draw-sr 2.5s ease-in-out forwards, fill-sr 1s ease-out 2.2s forwards;
    filter: drop-shadow(0 0 10px rgba(212, 175, 55, 0.5));
}

.loader-msg {
    position: absolute;
    /* Independent layer */
    top: calc(50% + 90px);
    /* Positioned below centered logo */
    left: 0;
    width: 100%;

    font-family: var(--font-heading);
    color: var(--gold);
    font-size: 1.2rem;
    letter-spacing: 5px;
    text-transform: uppercase;
    text-align: center;
    /* Ensure text is centered in the absolute container */

    animation: fade-up 1s ease-out forwards;
    opacity: 0;
    transform: translateY(20px);
    animation-delay: 2.5s;
    /* Wait for SR to finish drawing */
}

@keyframes draw-sr {
    to {
        stroke-dashoffset: 0;
    }
}

@keyframes fill-sr {
    to {
        fill: var(--gold);
        stroke: transparent;
    }
}

@keyframes fade-up {
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Hero */
.hero-shard {
    position: relative;
    max-width: 900px;
}

.sub-head {
    color: transparent;
    /* Hide real text but keep layout size */
    font-size: 1.2rem;
    letter-spacing: 3px;
    margin: 0 0 1rem 0;
    /* Left aligned to match name */
    display: block;
    width: fit-content;
    white-space: nowrap;
    position: relative;
}

.sub-head::before {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 0;
    height: 100%;
    color: var(--gold-dim);
    overflow: hidden;
    border-right: 2px solid var(--gold);
    animation: typing-loop 5s steps(30, end) infinite, blink 0.75s step-end infinite;
}

@keyframes typing-loop {
    0% {
        width: 0;
    }

    30% {
        width: 100%;
    }

    75% {
        width: 100%;
    }

    /* Pause reading */
    90% {
        width: 0;
    }

    /* Delete */
    100% {
        width: 0;
    }
}

@keyframes blink {

    from,
    to {
        border-color: transparent
    }

    50% {
        border-color: var(--gold)
    }
}

.main-head {
    font-family: var(--font-heading);
    font-size: clamp(3rem, 10vw, 5rem);
    color: var(--gold);
    line-height: 0.9;
    margin-bottom: 2rem;
    position: relative;
    display: inline-block;
    z-index: 1;
}

/* Shadow Spread Effect */
.main-head::before,
.main-head::after {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    color: var(--gold);
    opacity: 0.5;
    z-index: -1;
    animation: spread-wave 3s ease-out infinite;
    filter: blur(2px);
}

.main-head::after {
    animation-delay: 1.5s;
}



@keyframes spread-wave {
    0% {
        transform: scale(1);
        opacity: 0.6;
        filter: blur(0px);
    }

    100% {
        transform: scale(1.3);
        opacity: 0;
        filter: blur(8px);
    }
}

/* Hero Layout */
.hero-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 4rem;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
}

.hero-shard {
    flex: 1;
    z-index: 2;
}

.hero-visual {
    flex: 1;
    display: flex;
    justify-content: center;
    position: relative;
    z-index: 2;
    animation: fade-in-vis 1.5s ease-out forwards;
}

/* Holographic Projection */
.profile-frame {
    width: 300px;
    height: 400px;
    position: relative;
    margin-top: 2rem;
    display: flex;
    justify-content: center;
    align-items: flex-end;
    /* Align image to bottom emitter */
    perspective: 1000px;
}

/* The Emitter Base */
.profile-frame::after {
    content: '';
    position: absolute;
    bottom: -20px;
    width: 200px;
    height: 20px;
    background: radial-gradient(ellipse at center, var(--gold) 0%, rgba(212, 175, 55, 0.2) 60%, transparent 80%);
    border-radius: 50%;
    filter: blur(5px);
    z-index: 1;
    animation: pulse-emitter 2s ease-in-out infinite;
}

/* The Image Hologram */
.profile-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 2;
    /* Holo Effects */
    filter: sepia(100%) hue-rotate(5deg) brightness(0.9) contrast(1.2) drop-shadow(0 0 10px rgba(212, 175, 55, 0.5));
    opacity: 0.85;
    mask-image: linear-gradient(to bottom, black 0%, black 85%, transparent 100%);
    -webkit-mask-image: linear-gradient(to bottom, black 0%, black 85%, transparent 100%);
    transition: 0.4s;
    transform-origin: bottom;
    animation: holo-flicker 4s infinite;
}

/* Scanlines */
.profile-glow {
    position: absolute;
    inset: 0;
    z-index: 3;
    background: repeating-linear-gradient(0deg,
            transparent 0px,
            transparent 3px,
            rgba(212, 175, 55, 0.1) 4px,
            rgba(212, 175, 55, 0.3) 5px);
    pointer-events: none;
    mask-image: linear-gradient(to bottom, black 0%, black 85%, transparent 100%);
    /* Match image mask */
    background-size: 100% 100%;
    opacity: 0.7;
}

/* Interaction */
.profile-frame:hover .profile-img {
    filter: none;
    /* Full Color */
    opacity: 1;
    animation: none;
    transform: scale(1.02);
    drop-shadow: 0 0 20px rgba(212, 175, 55, 0.8);
}

.profile-frame:hover .profile-glow {
    opacity: 0.1;
    /* Fade scanlines */
}

/* Hover Data Tag */
.hero-visual::after {
    content: 'HOLOGRAM_LINK: STABLE';
    position: absolute;
    bottom: -40px;
    color: var(--gold-dim);
    font-family: var(--font-tech);
    font-size: 0.8rem;
    letter-spacing: 2px;
    opacity: 0;
    transition: 0.4s;
}

.profile-frame:hover~.hero-visual::after,
.hero-visual:hover::after {
    opacity: 1;
}

/* Animations */
@keyframes holo-flicker {

    0%,
    100% {
        opacity: 0.85;
        transform: scale(1);
        filter: sepia(100%) hue-rotate(5deg) brightness(0.9) blur(0.5px);
    }

    2% {
        opacity: 0.4;
        transform: scale(1.01) skewX(2deg);
        filter: sepia(100%) hue-rotate(5deg) brightness(1.5);
    }

    4% {
        opacity: 0.85;
        transform: scale(1);
    }

    15% {
        filter: sepia(100%) hue-rotate(5deg) brightness(0.9) blur(1px);
    }

    16% {
        filter: sepia(100%) hue-rotate(5deg) brightness(0.9) blur(0px);
    }
}

@keyframes pulse-emitter {

    0%,
    100% {
        opacity: 0.6;
        transform: scaleX(1);
    }

    50% {
        opacity: 1;
        transform: scaleX(1.1);
        box-shadow: 0 0 20px var(--gold);
    }
}

@keyframes fade-in-vis {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Remove unused keyframes */

/* Response Update */
@media (max-width: 900px) {
    .hero-container {
        flex-direction: column;
        text-align: center;
        gap: 2rem;
    }

    .hero-visual {
        order: -1;
        /* Image visual on top */
        margin-bottom: 2rem;
    }

    .btn-group {
        justify-content: center;
    }
}

.separator {
    width: 100%;
    height: 1px;
    background: linear-gradient(90deg, var(--gold), transparent);
    margin-bottom: 2rem;
}

.hero-role {
    font-size: 1.8rem;
    color: white;
    margin-bottom: 1rem;
    font-weight: 900;
    min-height: 2rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
    /* Prevent layout shift */
}

.cursor {
    display: inline-block;
    width: 2px;
    background-color: var(--gold);
    margin-left: 5px;
    animation: blink-cursor 0.7s infinite;
}

@keyframes blink-cursor {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0;
    }
}

.hero-bio {
    font-size: 1.2rem;
    color: #ccc;
    max-width: 600px;
    margin-bottom: 3rem;
    line-height: 1.6;
}

.btn-group {
    display: flex;
    gap: 20px;
}

.gold-btn {
    padding: 15px 40px;
    background: var(--gold);
    color: black;
    text-decoration: none;
    font-weight: bold;
    font-size: 1.1rem;
    clip-path: polygon(20px 0, 100% 0, 100% calc(100% - 20px), calc(100% - 20px) 100%, 0 100%, 0 20px);
    transition: 0.3s;
    border: none;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.gold-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.8), transparent);
    transform: skewX(-25deg);
    transition: 0.5s;
    z-index: -1;
}

.gold-btn:hover {
    color: black;
    transform: translateY(-2px);
    box-shadow: 0 0 20px rgba(212, 175, 55, 0.6);
}

.gold-btn:hover::before {
    left: 100%;
}

.outline-btn {
    padding: 15px 40px;
    background: transparent;
    color: var(--gold);
    text-decoration: none;
    font-weight: bold;
    font-size: 1.1rem;
    border: 1px solid var(--gold);
    transition: 0.3s;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.outline-btn::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--gold);
    z-index: -1;
    transition: transform 0.4s cubic-bezier(0.19, 1, 0.22, 1);
    transform: scaleX(0);
    transform-origin: right;
}

.outline-btn:hover {
    color: black;
    border-color: var(--gold);
}

.outline-btn:hover::after {
    transform: scaleX(1);
    transform-origin: left;
}

.outline-btn:hover {
    background: rgba(212, 175, 55, 0.1);
}

/* Content Boxes Common */
.content-box {
    background: rgba(20, 20, 20, 0.8);
    border: 1px solid var(--gold-dim);
    padding: 3rem;
    position: relative;
    box-shadow: 0 0 30px rgba(0, 0, 0, 0.5);
}

/* About */
/* Info Modules Grid */
.info-modules {
    display: flex;
    flex-wrap: nowrap;
    gap: 20px;
    justify-content: center;
    max-width: 1200px;
    margin: 0 auto;
    overflow-x: auto;
    padding: 20px 10px;
    -webkit-overflow-scrolling: touch;
    /* Smooth scroll on mobile */
}

/* Scrollbar styling for this section */
.info-modules::-webkit-scrollbar {
    height: 8px;
}

.info-modules::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 4px;
}

.info-modules::-webkit-scrollbar-thumb {
    background: var(--gold-dim);
    border-radius: 4px;
}

.info-module {
    flex: 0 0 340px;
    width: 340px;
    height: 340px;
    background: rgba(10, 10, 10, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.1);
    position: relative;
    overflow: hidden;
    cursor: pointer;
    transition: 0.3s;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.5);

    /* Default color fallback */
    --accent: var(--gold);
}

.info-module:hover {
    border-color: var(--accent);
    box-shadow: 0 0 30px var(--accent);
    /* Glow with accent color */
}

/* Module Front */
.module-front {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    transition: 0.5s ease-in-out;
    background: rgba(5, 5, 5, 0.95);
    z-index: 2;
}

.info-module:hover .module-front {
    transform: translateY(-100%);
    opacity: 0;
}

.module-front i {
    font-size: 4rem;
    color: rgba(255, 255, 255, 0.2);
    margin-bottom: 1rem;
    transition: 0.3s;
}

.info-module:hover .module-front i {
    color: var(--accent);
    transform: scale(1.2);
    text-shadow: 0 0 20px var(--accent);
}

.module-front h3 {
    font-family: var(--font-heading);
    color: white;
    font-size: 1.5rem;
    letter-spacing: 3px;
    margin-bottom: 2rem;
    transition: 0.3s;
}

.info-module:hover .module-front h3 {
    color: var(--accent);
}

/* Module Back */
.module-back {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 2rem;
    background: linear-gradient(135deg, rgba(20, 20, 20, 0.95), rgba(10, 10, 10, 0.95));
    opacity: 0;
    /* Hidden by default */
    transform: translateY(50px);
    transition: 0.5s ease-in-out;
    z-index: 1;
}

.info-module:hover .module-back {
    opacity: 1;
    transform: translateY(0);
}

/* Back Content Styles */
.mod-img {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    border: 2px solid var(--accent);
    overflow: hidden;
    margin-bottom: 1rem;
    box-shadow: 0 0 15px var(--accent);
}

.mod-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.mod-info h3 {
    color: var(--accent);
    font-family: var(--font-heading);
    margin-bottom: 5px;
}

.mod-rank {
    display: block;
    color: white;
    font-size: 0.9rem;
    margin-bottom: 5px;
}

.mod-loc {
    color: #888;
    font-size: 0.8rem;
}

.mod-desc {
    color: #ccc;
    font-size: 0.9rem;
    /* Slightly smaller text */
    line-height: 1.5;
    margin-bottom: 1rem;
}

.mod-stats-grid {
    display: flex;
    gap: 15px;
    width: 100%;
    justify-content: center;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 1rem;
}

.ms-item b {
    display: block;
    color: var(--accent);
    font-size: 1.5rem;
    font-family: var(--font-heading);
}

.ms-item small {
    color: #888;
    font-size: 0.7rem;
}

.mod-quote {
    font-style: italic;
    color: #ddd;
    font-size: 1rem;
    margin-bottom: 2rem;
    border-left: 2px solid var(--accent);
    padding-left: 15px;
}

.mod-mission-tags {
    display: flex;
    gap: 10px;
    justify-content: center;
}

.mod-mission-tags span {
    border: 1px solid var(--accent);
    color: var(--accent);
    padding: 3px 10px;
    font-size: 0.7rem;
    border-radius: 20px;
}


/* Projects Hex Grid */
.projects-hex-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    justify-content: center;
}

.project-hex {
    width: 100%;
    max-width: 350px;
    height: 480px;
    /* Increased height for image */
    background: linear-gradient(135deg, #111, #0a0a0a);
    clip-path: polygon(50% 0%, 100% 10%, 100% 100%, 50% 100%, 0% 100%, 0% 10%);
    /* Adjusted top angle */
    border-top: 2px solid var(--gold);
    position: relative;
    transition: 0.3s;
    display: flex;
    flex-direction: column;
}

.project-hex:hover {
    transform: translateY(-10px);
    background: #151515;
}

.project-hex::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 5px;
    background: var(--gold);
    z-index: 10;
}

.project-img {
    width: 100%;
    height: 180px;
    overflow: hidden;
    position: relative;
}

.project-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.8;
    transition: 0.5s;
}

.project-hex:hover .project-img img {
    opacity: 1;
    transform: scale(1.1);
}

.hex-content {
    padding: 1.5rem;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.hex-content h3 {
    font-size: 1.4rem;
    color: white;
    margin-bottom: 0.5rem;
    font-family: var(--font-heading);
}

.hex-content p {
    color: #888;
    margin-bottom: 1rem;
    font-size: 0.95rem;
    line-height: 1.4;
    flex-grow: 1;
}

.tags span {
    display: inline-block;
    border: 1px solid var(--gold-dim);
    color: var(--gold);
    padding: 2px 8px;
    font-size: 0.8rem;
    margin-right: 5px;
}

.view-op {
    display: block;
    margin-top: 2rem;
    text-align: right;
    color: var(--text-main);
    text-decoration: none;
    font-weight: bold;
}

.view-op:hover {
    color: var(--gold);
}

/* Tech Grid */
/* Core Skill Hex Grid */
.core-skills-grid {
    display: flex;
    justify-content: center;
    gap: 30px;
    flex-wrap: wrap;
    margin-bottom: 3rem;
    perspective: 1000px;
}

.skill-hex {
    width: 120px;
    height: 140px;
    position: relative;
    clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
    background: rgba(10, 10, 10, 0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    transition: 0.4s;
    animation: float-hex 3s ease-in-out infinite;
    animation-delay: var(--d);
    cursor: pointer;
}

.skill-hex::before {
    content: '';
    position: absolute;
    inset: 2px;
    clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
    background: rgba(255, 255, 255, 0.05);
    z-index: -1;
}

.skill-hex::after {
    content: '';
    position: absolute;
    inset: 0;
    clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
    background: var(--gold);
    z-index: -2;
    opacity: 0.3;
    transition: 0.4s;
}

.skill-hex:hover {
    transform: scale(1.1) translateY(-10px);
}

.skill-hex:hover::after {
    opacity: 1;
    box-shadow: 0 0 30px var(--gold);
}

.hex-inner {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 100%;
    height: 100%;
    text-align: center;
    color: white;
    z-index: 10;
}

.hex-inner i {
    font-size: 2.5rem;
    color: var(--gold);
    margin-bottom: 8px;
    /* Adjusted spacing */
    transition: 0.4s;
    line-height: 1;
    /* Ensure no extra line-height spacing */
}

.skill-hex:hover i {
    color: #fff;
    text-shadow: 0 0 10px white;
}

.hex-inner span {
    font-family: var(--font-tech);
    font-size: 0.8rem;
    letter-spacing: 1px;
}

@keyframes float-hex {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-8px);
    }
}

/* Skill Controls */
.skill-controls {
    text-align: center;
    margin-bottom: 2rem;
}

.scan-btn {
    background: transparent;
    border: 1px solid var(--gold);
    color: var(--gold);
    padding: 1rem 2rem;
    font-family: var(--font-tech);
    font-size: 1rem;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transition: 0.3s;
    letter-spacing: 2px;
}

.scan-btn:hover {
    background: rgba(212, 175, 55, 0.1);
    box-shadow: 0 0 20px rgba(212, 175, 55, 0.3);
    text-shadow: 0 0 5px var(--gold);
}

.hidden-panel {
    display: none;
    opacity: 0;
    transform: translateY(20px);
    transition: 0.5s ease-in-out;
}

.hidden-panel.visible {
    display: block;
    /* Changed to block for wrapper div */
    opacity: 1;
    transform: translateY(0);
}

/* Constructor Grid */
.skill-circuit {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    max-width: 1000px;
    margin: 0 auto;
}

.circuit-node {
    background: linear-gradient(180deg, rgba(15, 15, 15, 0.95) 0%, rgba(25, 25, 25, 0.95) 100%);
    border: 1px solid rgba(255, 255, 255, 0.1);
    position: relative;
    padding: 25px;
    overflow: hidden;

    /* Pre-animation State */
    opacity: 0;
    transform: scale(0.1);
    /* Start small */
    transform-origin: center;
}

/* Constructor Animation */
.circuit-node.scanned {
    animation: construct-window 0.6s cubic-bezier(0.165, 0.84, 0.44, 1) forwards;
}

@keyframes construct-window {
    0% {
        opacity: 0;
        transform: scaleX(0.05) scaleY(0.05);
        background: var(--gold);
        /* Flash start */
    }

    40% {
        opacity: 1;
        transform: scaleX(1) scaleY(0.05);
        /* Expand width */
        background: var(--gold);
    }

    100% {
        opacity: 1;
        transform: scaleX(1) scaleY(1);
        /* Expand height */
        background: linear-gradient(180deg, rgba(15, 15, 15, 0.95) 0%, rgba(25, 25, 25, 0.95) 100%);
    }
}

/* Corner Brackets */
.circuit-node::before,
.circuit-node::after {
    content: '';
    position: absolute;
    width: 15px;
    height: 15px;
    transition: 0.4s;
    border: 2px solid transparent;
    z-index: 2;
    opacity: 0.6;
}

.circuit-node::before {
    top: 0;
    left: 0;
    border-top-color: var(--gold);
    border-left-color: var(--gold);
}

.circuit-node::after {
    bottom: 0;
    right: 0;
    border-bottom-color: var(--gold);
    border-right-color: var(--gold);
}

.circuit-node:hover::before,
.circuit-node:hover::after {
    width: 100%;
    height: 100%;
    opacity: 1;
    z-index: 0;
    /* Move behind text */
}

.circuit-node:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
    transition: transform 0.3s;
}

/* Content Fade In (Delayed) */
.circuit-node .node-head,
.circuit-node .node-chips {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.4s, transform 0.4s;
}

/* When scanned, delay content appearance slightly to match window opening */
.circuit-node.scanned .node-head {
    opacity: 1;
    transform: translateY(0);
    transition-delay: 0.4s;
}

.circuit-node.scanned .node-chips {
    opacity: 1;
    transform: translateY(0);
    transition-delay: 0.5s;
}

.node-head {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    padding-bottom: 15px;
    position: relative;
    z-index: 1;
}

.node-head i {
    font-size: 1.8rem;
    color: var(--gold);
    background: rgba(255, 255, 255, 0.05);
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 5px;
}

.node-head h3 {
    font-family: var(--font-heading);
    color: white;
    font-size: 1.1rem;
    letter-spacing: 2px;
}

.node-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.node-chips span {
    font-family: var(--font-tech);
    font-size: 0.8rem;
    color: #888;
    background: rgba(0, 0, 0, 0.3);
    padding: 4px 10px;
    border: none;
    border-left: 2px solid var(--gold-dim);
    transition: 0.3s;
}

.node-chips span:hover {
    color: white;
    background: var(--gold-dim);
    border-left-color: white;
    box-shadow: 0 0 15px rgba(212, 175, 55, 0.2);
    transform: none;
    /* Reset */
}



.circuit-node:hover .node-chips span {
    border-color: var(--gold-dim);
    color: white;
}

.node-chips span:hover {
    background: var(--gold);
    border-color: var(--gold);
    color: black;
    transform: scale(1.1);
    box-shadow: 0 0 10px var(--gold);
}

/* Research */
/* Tactical Ops Grid */
/* Mag-Lev Grid */
/* Data Slate Grid (Isometric) */
/* Schematic Blueprint Grid */
.schematic-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(360px, 1fr));
    gap: 40px;
    padding: 20px 0;
}

@media (max-width: 768px) {
    .schematic-grid {
        display: flex;
        /* Use flex column for mobile stack to easily center */
        flex-direction: column;
        align-items: center;
        /* Center horizontally */
    }

    .schematic-card {
        width: 100%;
        max-width: 400px;
        /* Optional: constrain width for better look */
    }
}

.schematic-card {
    position: relative;
    padding: 10px;
    background: transparent;
    transition: 0.3s;
}

.schematic-frame {
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(10, 10, 10, 0.3);
    padding: 20px;
    position: relative;
    transition: 0.3s;
}

.schematic-card:hover .schematic-frame {
    border-color: var(--gold);
    box-shadow: 0 0 20px rgba(212, 175, 55, 0.1);
    background: rgba(10, 10, 10, 0.8);
}

/* Blueprint Background Pattern */
.blueprint-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
    background-size: 20px 20px;
    pointer-events: none;
    z-index: 0;
}

/* Visual Section */
.schematic-visual {
    height: 180px;
    position: relative;
    border: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: 20px;
    overflow: hidden;
}

.schematic-visual img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: 0.5s;
}

.maximize-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 35px;
    height: 35px;
    background: rgba(0, 0, 0, 0.7);
    color: var(--gold);
    border: 1px solid var(--gold-dim);
    border-radius: 50%;
    cursor: pointer;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: 0.3s;
    z-index: 10;
}

.schematic-card:hover .maximize-btn {
    opacity: 1;
}

.maximize-btn:hover {
    background: var(--gold);
    color: black;
    box-shadow: 0 0 10px var(--gold);
}

.measure-lines {
    position: absolute;
    bottom: 10px;
    right: 10px;
    width: 50px;
    height: 10px;
    border-bottom: 1px solid var(--gold);
    border-right: 1px solid var(--gold);
}

.measure-lines::before {
    content: '100px';
    position: absolute;
    bottom: 2px;
    right: 5px;
    font-size: 0.6rem;
    color: var(--gold);
    font-family: var(--font-tech);
}

/* Info Section */
.schematic-info {
    position: relative;
    z-index: 1;
}

.spec-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin-bottom: 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding-bottom: 5px;
}

.spec-header h3 {
    font-family: var(--font-heading);
    color: white;
    font-size: 1.3rem;
}

.serial {
    font-family: var(--font-tech);
    color: var(--gold-dim);
    font-size: 0.75rem;
}

/* Spec Grid Table */
.spec-grid {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 10px;
    margin-bottom: 20px;
}

.spec-item {
    display: flex;
    flex-direction: column;
}

.spec-item .label {
    font-size: 0.65rem;
    color: #666;
    font-family: var(--font-tech);
    margin-bottom: 3px;
}

.spec-item .value {
    font-size: 0.8rem;
    color: var(--gold);
    font-family: var(--font-tech);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 4px;
    text-align: center;
}

.schematic-desc {
    color: #999;
    font-size: 0.9rem;
    line-height: 1.5;
    margin-bottom: 20px;
    min-height: 3em;
}

.schematic-btn {
    display: block;
    width: 100%;
    padding: 10px;
    text-align: center;
    border: 1px dashed var(--gold);
    color: var(--gold);
    text-decoration: none;
    font-family: var(--font-tech);
    font-size: 0.9rem;
    transition: 0.3s;
}

.schematic-btn:hover {
    background: rgba(212, 175, 55, 0.1);
    border-style: solid;
    letter-spacing: 1px;
}

/* Corner Markers */
.corner-marker {
    position: absolute;
    width: 10px;
    height: 10px;
    border: 2px solid var(--gold-dim);
    transition: 0.3s;
}

.corner-marker.top-left {
    top: -1px;
    left: -1px;
    border-right: none;
    border-bottom: none;
}

.corner-marker.bottom-right {
    bottom: -1px;
    right: -1px;
    border-left: none;
    border-top: none;
}

.schematic-card:hover .corner-marker {
    width: 20px;
    height: 20px;
    border-color: var(--gold);
}



.research-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.research-item {
    background: rgba(10, 10, 10, 0.8);
    border-left: 3px solid var(--gold-dim);
    padding: 2rem;
    position: relative;
    transition: 0.3s;
}

.research-item:hover {
    border-left-color: var(--gold);
    background: rgba(20, 20, 20, 0.9);
}

.res-icon {
    font-size: 2rem;
    color: var(--gold);
    margin-bottom: 1rem;
    opacity: 0.5;
}

.res-info h3 {
    font-family: var(--font-heading);
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
}

.res-meta {
    display: block;
    color: var(--gold-dim);
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.gold-link {
    display: inline-block;
    color: var(--gold);
    font-weight: bold;
    text-decoration: none;
    margin-top: 1rem;
    border-bottom: 1px solid transparent;
}

.gold-link:hover {
    border-bottom-color: var(--gold);
}

/* Certifications */
.cert-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
}

.cert-card {
    border: 1px solid var(--border-color, #333);
    padding: 2rem;
    text-align: center;
    background: rgba(255, 255, 255, 0.02);
    transition: 0.3s;
}

.cert-card:hover {
    border-color: var(--gold);
    transform: scale(1.05);
}

.cert-card i {
    font-size: 2.5rem;
    color: var(--gold);
    margin-bottom: 1rem;
    display: block;
}

.cert-date {
    display: block;
    margin-top: 1rem;
    color: #666;
    font-size: 0.8rem;
}

/* Education Timeline */
.edu-timeline {
    position: relative;
    border-left: 2px solid var(--dark-grey);
    margin-left: 20px;
    padding-left: 40px;
}

.timeline-item {
    position: relative;
    margin-bottom: 3rem;
}

.marker {
    position: absolute;
    left: -51px;
    top: 5px;
    width: 20px;
    height: 20px;
    background: var(--bg-dark);
    border: 2px solid var(--gold);
    transform: rotate(45deg);
}

.timeline-content h3 {
    color: var(--gold);
    font-family: var(--font-heading);
    margin-bottom: 0.5rem;
}

.edu-place {
    color: #888;
    font-style: italic;
    margin-bottom: 1rem;
    display: block;
}

/* Contact */
.uplink-interface {
    max-width: 600px;
    background: rgba(20, 20, 20, 0.8);
    border: 1px solid var(--gold);
    padding: 3rem;
}

.form-header {
    color: var(--gold);
    margin-bottom: 2rem;
    letter-spacing: 2px;
    text-align: center;
}

.input-group {
    margin-bottom: 1.5rem;
}

.input-group label {
    display: block;
    color: var(--gold);
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.input-group input,
.input-group textarea {
    width: 100%;
    background: #050505;
    border: 1px solid var(--gold-dim);
    color: white;
    padding: 1rem;
    font-family: var(--font-tech);
    font-size: 1.1rem;
}

.input-group input:focus,
.input-group textarea:focus {
    border-color: var(--gold);
    outline: none;
}

.full {
    width: 100%;
    margin-top: 1rem;
}

.contact-info-row {
    margin-top: 2rem;
    text-align: center;
    color: var(--text-main);
}

.contact-info-row i {
    color: var(--gold);
    margin-right: 10px;
}

/* Responsive */
@media (max-width: 1100px) {
    main {
        margin-left: 0;
        padding-bottom: 100px;
        margin-top: 0;
    }

    .hex-nav {
        left: 50%;
        top: auto;
        bottom: 10px;
        transform: translateX(-50%);
        flex-direction: row;
        width: 100%;
        justify-content: center;
        gap: 5px;
        background: rgba(0, 0, 0, 0.9);
        padding: 10px;
    }

    .hex {
        width: 35px;
        height: 40px;
    }

    .hex i {
        font-size: 0.9rem;
    }

    .hero-shard {
        text-align: center;
    }

    .sub-head {
        margin: 0 auto 1rem auto;
        /* Re-center on mobile */
    }

    .btn-group {
        justify-content: center;
    }

    .bio-layout {
        grid-template-columns: 1fr;
    }

    /* Responsive Loader */
    .sr-logo {
        width: 200px;
        height: 100px;
    }

    .sr-text {
        font-size: 80px;
    }

    .loader-msg {
        font-size: 0.9rem;
        letter-spacing: 2px;
        padding: 0 20px;
        text-align: center;
    }
}

@media (max-width: 650px) {
    .main-head {
        font-size: 3rem;
    }

    .screen-section {
        padding: 4rem 5%;
    }

    .projects-hex-grid,
    .research-list,
    .cert-grid,
    .tech-grid {
        grid-template-columns: 1fr;
    }

    .btn-group {
        flex-wrap: wrap;
    }

    .project-hex {
        width: 100%;
        max-width: 320px;
    }

    .uplink-interface {
        padding: 1.5rem;
    }

    .bio-visual {
        width: 250px;
        height: 250px;
    }

    .image-container,
    .tech-ring-1,
    .tech-ring-2 {
        transform: scale(0.8);
    }

    /* Dossier Mobile */
    /* Info Modules Stack on Mobile */
    .info-modules {
        display: block;
        /* Switch to block to avoid flex shrinking */
        width: 100%;
        padding: 0 10px;
        /* Small padding from screen edges */
    }

    .info-module {
        width: 100%;
        /* Force full width */
        height: 350px;
        margin-bottom: 20px;
        max-width: none;
        /* Remove previous limits */
    }

    .dossier-header {
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }

    .dossier-decor-line {
        width: 100%;
        margin: 5px 0;
        height: 1px;
    }

    .data-row {
        flex-direction: column;
        gap: 5px;
        text-align: center;
    }

    .data-bio p {
        border-left: none;
        padding-left: 0;
        text-align: center;
    }

    /* Center Alignments */
    .section-title {
        text-align: center;
        border-left: none;
        padding-left: 0;
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    .gold-bar {
        margin: 10px auto 0;
    }

    .hero-bio {
        margin-left: auto;
        margin-right: auto;
    }

    .bio-data {
        text-align: center;
    }

    .stats-tri {
        justify-content: center;
    }

    .uplink-interface {
        margin: 0 auto;
    }


    .project-hex {
        margin: 0 auto;
    }

    /* Mobile Loader Tweaks */
    .sr-logo {
        width: 240px;
        height: 120px;
        margin: 0 auto;
    }

    .sr-text {
        font-size: 90px;
    }

    .loader-msg {
        top: calc(50% + 75px);
        font-size: 0.7rem;
        letter-spacing: 2px;
        width: 100%;
        padding: 0;
        margin: 0;
        white-space: nowrap;
        text-align: center;
    }

    /* Skill Circuit Mobile */
    .circuit-node {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }

    .node-chips {
        max-width: 100%;
        justify-content: flex-start;
    }
}

/* Project Details Modal - Schematic Theme */
#project-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(10, 10, 12, 0.95);
    backdrop-filter: blur(15px);
    z-index: 10001;
    display: none;
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

#project-modal.active {
    opacity: 1;
}

.modal-content.schematic-theme {
    width: 90%;
    max-width: 1000px;
    background: rgba(16, 20, 24, 0.98);
    border: 1px solid rgba(212, 175, 55, 0.3);
    box-shadow: 0 0 50px rgba(0, 0, 0, 0.8), 0 0 20px rgba(212, 175, 55, 0.1);
    position: relative;
    padding: 30px;
    display: flex;
    flex-direction: column;
    gap: 20px;
    transform: translateY(20px);
    transition: transform 0.3s ease;
    max-height: 90vh;
    overflow-y: auto;
}

#project-modal.active .modal-content {
    transform: translateY(0);
}

.modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: transparent;
    border: 1px solid rgba(212, 175, 55, 0.5);
    color: #d4af37;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.modal-close:hover {
    background: #d4af37;
    color: #000;
    box-shadow: 0 0 15px rgba(212, 175, 55, 0.4);
}

.modal-header {
    border-bottom: 1px dashed rgba(212, 175, 55, 0.3);
    padding-bottom: 15px;
}

.modal-header h2 {
    color: #fff;
    font-family: var(--font-heading);
    font-size: 2rem;
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.modal-subtitle {
    color: #d4af37;
    font-family: var(--font-tech);
    font-size: 0.9rem;
    margin-top: 5px;
    opacity: 0.8;
}

.modal-body {
    display: flex;
    flex-direction: column;
    gap: 20px;
    align-items: center;
}

.modal-visual {
    width: fit-content;
    max-width: 100%;
    margin: 0 auto;
    position: relative;
    border: 1px solid rgba(212, 175, 55, 0.4);
    padding: 0;
    background: transparent;
    display: flex;
}

.modal-visual img {
    max-width: 100%;
    max-height: 50vh;
    height: auto;
    display: block;
}

.modal-info {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.modal-stack {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.modal-chip {
    background: rgba(212, 175, 55, 0.05);
    border: 1px solid rgba(212, 175, 55, 0.3);
    color: #d4af37;
    padding: 6px 14px;
    font-size: 0.8rem;
    font-family: var(--font-tech);
    text-transform: uppercase;
    border-radius: 2px;
    letter-spacing: 1px;
}

.modal-desc {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.modal-desc li {
    position: relative;
    padding-left: 25px;
    color: #ccc;
    font-family: var(--font-tech);
    font-size: 1.1rem;
    line-height: 1.6;
}

.modal-desc li::before {
    content: '>';
    position: absolute;
    left: 0;
    color: #d4af37;
    font-weight: bold;
    font-family: var(--font-tech);
}

@media (max-width: 900px) {
    /* Styles removed as they are now default behavior */
}

/* Strategic Clearances (Certifications) 3D Grid */
.cert-deck {
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
    justify-content: center;
    padding: 40px 20px;
    perspective: 1000px;
    /* Essential for 3D effect */
}

.cert-card-3d {
    width: 320px;
    height: 200px;
    position: relative;
    transform-style: preserve-3d;
    transition: transform 0.4s ease-out;
    cursor: pointer;
}

.cert-card-3d:hover {
    transform: rotateX(10deg) rotateY(-10deg) translateZ(20px);
    z-index: 10;
}

/* Glass Container */
.cert-glass {
    position: absolute;
    inset: 0;
    background: rgba(15, 15, 15, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 6px;
    /* Tactical squared corners with slight roundness */
    padding: 24px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5), inset 0 0 20px rgba(0, 0, 0, 0.8);
    overflow: hidden;
    transition: 0.3s;
}

.cert-card-3d:hover .cert-glass {
    border-color: var(--gold);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6), inset 0 0 10px rgba(212, 175, 55, 0.1);
    background: rgba(20, 20, 20, 0.9);
}

/* Header: Icon + ID */
.cert-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding-bottom: 12px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.cert-header i {
    font-size: 2rem;
    color: var(--gold);
    text-shadow: 0 0 10px rgba(212, 175, 55, 0.3);
}

.cert-id {
    font-family: var(--font-tech);
    font-size: 0.7rem;
    color: rgba(255, 255, 255, 0.3);
    letter-spacing: 1px;
}

/* Body: Title */
.cert-body h3 {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    color: white;
    margin-bottom: 5px;
    line-height: 1.2;
    text-transform: uppercase;
}

.cert-body p {
    font-family: var(--font-tech);
    font-size: 0.8rem;
    color: #888;
}

/* Footer: Issuer + Status */
.cert-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: auto;
}

.issuer {
    font-family: var(--font-tech);
    font-size: 0.75rem;
    color: var(--gold-dim);
    letter-spacing: 1px;
    font-weight: bold;
}

.status {
    font-family: var(--font-tech);
    font-size: 0.65rem;
    padding: 3px 8px;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid #333;
    border-radius: 3px;
    letter-spacing: 1px;
}

.status.verified {
    color: #39ff14;
    /* Neon Green */
    border-color: rgba(57, 255, 20, 0.3);
    text-shadow: 0 0 5px rgba(57, 255, 20, 0.5);
}

/* Scan Line Animation */
.scan-line {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    /* Cover entire area but use gradient bar */
    background: linear-gradient(to bottom, transparent 40%, rgba(212, 175, 55, 0.1) 50%, transparent 60%);
    background-size: 100% 200%;
    background-position: 0% -100%;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s;
}

.cert-card-3d:hover .scan-line {
    opacity: 1;
    animation: scan-pass 1.5s linear infinite;
}

@keyframes scan-pass {
    0% {
        background-position: 0% -100%;
    }

    100% {
        background-position: 0% 200%;
    }
}

/* Responsive adjustment */
@media (max-width: 768px) {
    .cert-deck {
        padding: 20px 10px;
    }

    .cert-card-3d {
        width: 100%;
        max-width: 340px;
    }
}

/* Clearance Archives (Certifications) Dossier Interface */
.archive-container {
    display: flex;
    gap: 40px;
    max-width: 1100px;
    margin: 0 auto;
    padding: 20px;
}

@media (max-width: 900px) {
    .archive-container {
        flex-direction: column;
    }
}

/* LEFT: List of Data Tapes */
.archive-list {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-height: 500px;
    overflow-y: auto;
    padding-right: 10px;
}

/* Scrollbar for list */
.archive-list::-webkit-scrollbar {
    width: 4px;
}

.archive-list::-webkit-scrollbar-track {
    background: #111;
}

.archive-list::-webkit-scrollbar-thumb {
    background: var(--gold-dim);
}

.archive-item {
    display: flex;
    align-items: center;
    background: rgba(10, 10, 10, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 15px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.archive-item:hover {
    background: rgba(20, 20, 20, 0.9);
    border-color: var(--gold-dim);
    transform: translateX(10px);
}

.archive-item.active {
    background: rgba(212, 175, 55, 0.1);
    border-color: var(--gold);
    border-left: 4px solid var(--gold);
}

.item-status {
    width: 8px;
    height: 8px;
    background: #333;
    border-radius: 50%;
    margin-right: 15px;
    box-shadow: 0 0 5px #000;
    transition: 0.3s;
}

.archive-item.active .item-status {
    background: #39ff14;
    box-shadow: 0 0 10px #39ff14;
}

.item-details {
    display: flex;
    flex-direction: column;
}

.item-details .code {
    font-family: var(--font-tech);
    font-size: 0.7rem;
    color: var(--gold-dim);
    letter-spacing: 1px;
}

.item-details .name {
    font-family: var(--font-heading);
    font-size: 0.9rem;
    color: #ccc;
    font-weight: bold;
    margin-top: 2px;
}

.archive-item.active .name {
    color: white;
}

/* RIGHT: Terminal Viewer */
.archive-terminal {
    flex: 1.2;
    perspective: 1000px;
}

.terminal-frame {
    background: #050505;
    border: 1px solid #333;
    border-radius: 6px;
    overflow: hidden;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
    height: 100%;
    min-height: 400px;
    display: flex;
    flex-direction: column;
}

.term-header {
    background: #111;
    border-bottom: 1px solid #333;
    padding: 10px 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.term-controls {
    display: flex;
    gap: 8px;
}

.term-controls .dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    opacity: 0.7;
}

.red {
    background: #ff5f56;
}

.yellow {
    background: #ffbd2e;
}

.green {
    background: #27c93f;
}

.term-title {
    font-family: var(--font-tech);
    color: #666;
    font-size: 0.8rem;
    letter-spacing: 2px;
}

.term-screen {
    flex: 1;
    background: radial-gradient(circle at center, #1a1a1a 0%, #000 100%);
    position: relative;
    padding: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.scan-line-overlay {
    position: absolute;
    inset: 0;
    background: repeating-linear-gradient(0deg,
            rgba(0, 0, 0, 0.2),
            rgba(0, 0, 0, 0.2) 1px,
            transparent 1px,
            transparent 2px);
    pointer-events: none;
    z-index: 2;
}

/* Viewer Content Styling */
.cert-display {
    text-align: center;
    opacity: 0;
    transform: translateY(10px);
    transition: 0.4s ease-out;
    display: none;
    /* Changed from just opacity */
}

.cert-display.active-display {
    display: block;
    opacity: 1;
    transform: translateY(0);
    animation: text-flicker 0.2s ease-in-out;
}

@keyframes text-flicker {
    0% {
        opacity: 0;
    }

    50% {
        opacity: 0.5;
    }

    100% {
        opacity: 1;
    }
}

.cert-icon-large {
    font-size: 4rem;
    color: var(--gold);
    margin-bottom: 20px;
    filter: drop-shadow(0 0 20px rgba(212, 175, 55, 0.3));
}

.cd-title {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    color: white;
    margin-bottom: 10px;
    letter-spacing: 1px;
}

.cd-subtitle {
    font-family: var(--font-tech);
    font-size: 1rem;
    color: #888;
    margin-bottom: 30px;
}

.cd-meta {
    display: grid;
    gap: 10px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 15px;
    margin-bottom: 25px;
    text-align: left;
}

.cd-row {
    display: flex;
    justify-content: space-between;
    border-bottom: 1px dashed rgba(255, 255, 255, 0.1);
    padding-bottom: 5px;
}

.cd-row:last-child {
    border-bottom: none;
}

.cd-label {
    font-family: var(--font-tech);
    color: #666;
    font-size: 0.8rem;
}

.cd-val {
    font-family: var(--font-tech);
    color: var(--gold);
    font-size: 0.9rem;
}

.cd-val.highlight {
    color: #39ff14;
    text-shadow: 0 0 5px #39ff14;
}

.cd-desc {
    font-size: 0.9rem;
    color: #aaa;
    line-height: 1.6;
    text-align: justify;
}

/* Mainframe Rack (Certifications) */
.mainframe-rack {
    max-width: 900px;
    margin: 0 auto;
    background: #080808;
    border: 1px solid #333;
    padding: 30px;
    box-shadow: inset 0 0 50px rgba(0, 0, 0, 0.8);
    position: relative;
}

/* Metallic Frame Border */
.rack-border {
    border-left: 5px solid #222;
    border-right: 5px solid #222;
    padding: 20px 0;
    position: relative;
    background: linear-gradient(90deg,
            rgba(20, 20, 20, 1) 0%,
            rgba(40, 40, 40, 1) 2%,
            rgba(20, 20, 20, 1) 4%,
            rgba(0, 0, 0, 0) 5%,
            rgba(0, 0, 0, 0) 95%,
            rgba(20, 20, 20, 1) 96%,
            rgba(40, 40, 40, 1) 98%,
            rgba(20, 20, 20, 1) 100%);
}

.rack-vents {
    height: 10px;
    background: repeating-linear-gradient(90deg,
            #111,
            #111 2px,
            #333 4px,
            #333 4px);
    margin: 0 10px;
    opacity: 0.5;
}

.rack-vents.top {
    margin-bottom: 20px;
}

.rack-vents.bottom {
    margin-top: 20px;
}

/* The Rack Unit Item */
.rack-unit {
    margin: 0 10px 10px 10px;
    background: #0f0f0f;
    border: 1px solid #2a2a2a;
    transition: 0.3s;
}

.rack-unit:hover {
    border-color: var(--gold-dim);
}

.rack-unit.active {
    border-color: var(--gold);
    box-shadow: 0 0 15px rgba(212, 175, 55, 0.1);
}

/* The Visible Face Plate */
.unit-plate {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    background: linear-gradient(180deg, #1a1a1a 0%, #111 100%);
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.unit-plate::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 2px;
    height: 100%;
    background: #333;
    transition: 0.3s;
}

.rack-unit.active .unit-plate::after {
    background: var(--gold);
    box-shadow: 0 0 10px var(--gold);
}

/* Left Section: Status LED + Serial */
.plate-left {
    display: flex;
    align-items: center;
    gap: 15px;
    width: 25%;
}

.status-led {
    width: 10px;
    height: 10px;
    background: #333;
    border-radius: 50%;
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.5);
    position: relative;
}

/* LED States */
.status-led.online {
    background: #39ff14;
    box-shadow: 0 0 8px #39ff14;
}

.status-led.warning {
    background: #ffbd2e;
    box-shadow: 0 0 8px #ffbd2e;
}

.status-led.processing {
    background: #00f0ff;
    box-shadow: 0 0 8px #00f0ff;
}

/* Blinking Effect for active unit */
.rack-unit.active .status-led {
    animation: led-pulse 1s infinite alternate;
}

@keyframes led-pulse {
    from {
        opacity: 0.6;
    }

    to {
        opacity: 1;
        filter: brightness(1.5);
    }
}

.unit-serial {
    font-family: var(--font-tech);
    font-size: 0.7rem;
    color: #555;
    letter-spacing: 1px;
}

/* Center Section: Icon + Title */
.plate-center {
    display: flex;
    align-items: center;
    gap: 15px;
    width: 50%;
}

.plate-center i {
    color: var(--gold-dim);
    font-size: 1.2rem;
    width: 25px;
    text-align: center;
    transition: 0.3s;
}

.unit-title {
    font-family: var(--font-heading);
    font-size: 1rem;
    color: #bbb;
    letter-spacing: 1px;
    transition: 0.3s;
}

.rack-unit.active .unit-title {
    color: white;
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.3);
}

.rack-unit.active .plate-center i {
    color: var(--gold);
    text-shadow: 0 0 10px var(--gold);
}

/* Right Section: Capacity + Toggle */
.plate-right {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 20px;
    width: 25%;
}

.unit-capacity {
    font-family: var(--font-tech);
    font-size: 0.7rem;
    color: #444;
    background: #080808;
    padding: 2px 6px;
    border: 1px solid #222;
}

.toggle-icon {
    font-size: 0.8rem;
    color: #666;
    transition: 0.3s;
}

.rack-unit.active .toggle-icon {
    transform: rotate(180deg);
    color: var(--gold);
}

/* The Core (Hidden Content) */
.unit-core {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.5s cubic-bezier(0, 1, 0, 1);
    background: #0a0a0a;
}

.rack-unit.active .unit-core {
    max-height: 200px;
    /* Approximate max height needed */
    transition: max-height 0.5s ease-in-out;
}

.core-inner {
    padding: 20px;
    border-top: 1px dashed #222;
    background:
        repeating-linear-gradient(45deg,
            rgba(0, 0, 0, 0.2),
            rgba(0, 0, 0, 0.2) 10px,
            rgba(0, 0, 0, 0.3) 10px,
            rgba(0, 0, 0, 0.3) 20px);
}

.core-desc {
    font-family: sans-serif;
    color: #999;
    font-size: 0.9rem;
    line-height: 1.6;
    margin-bottom: 15px;
}

.core-specs {
    display: flex;
    gap: 20px;
    font-family: var(--font-tech);
    font-size: 0.75rem;
    color: var(--gold-dim);
}

.core-specs i {
    margin-right: 5px;
}

/* Responsive */
@media (max-width: 768px) {
    .unit-plate {
        flex-wrap: wrap;
    }

    .plate-left,
    .plate-center,
    .plate-right {
        width: 100%;
        margin-bottom: 10px;
        justify-content: flex-start;
    }

    .plate-right {
        margin-bottom: 0;
        justify-content: space-between;
    }

    .status-led {
        display: none;
        /* Hide LED on mobile to save space */
    }
}

/* Data Blades (Horizontal Accordion) */
.blade-container {
    display: flex;
    flex-direction: row;
    height: 400px;
    gap: 5px;
    max-width: 1200px;
    margin: 0 auto;
    overflow: hidden;
    padding: 0 10px;
}

.blade {
    position: relative;
    flex: 1;
    /* Default width */
    background: #080808;
    border: 1px solid #333;
    transition: flex 0.6s cubic-bezier(0.25, 1, 0.5, 1), background 0.4s;
    overflow: hidden;
    cursor: pointer;
    box-shadow: inset 0 0 20px rgba(0, 0, 0, 0.8);
    min-width: 60px;
    /* Ensure collapsed blades don't vanish */
}

/* Hover / Active Logic */
.blade:hover {
    flex: 5;
    /* Expand significantly */
    background: #0d0d0d;
    border-color: var(--gold-dim);
}

.blade:hover .blade-collapsed {
    opacity: 0;
    pointer-events: none;
    transform: translateY(-20px);
}

.blade:hover .blade-expanded {
    opacity: 1;
    transform: translateX(0);
    transition-delay: 0.1s;
}

/* Collapsed Content */
.blade-collapsed {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: center;
    padding: 20px 0;
    transition: 0.4s;
    opacity: 1;
}

.blade-id {
    writing-mode: vertical-rl;
    text-orientation: mixed;
    transform: rotate(180deg);
    font-family: var(--font-tech);
    color: #444;
    font-size: 0.7rem;
    letter-spacing: 2px;
}

.blade-rotater {
    writing-mode: vertical-rl;
    text-orientation: mixed;
    transform: rotate(180deg);
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 20px;
}

.blade-rotater i {
    font-size: 1.2rem;
    color: var(--gold);
    transform: rotate(90deg);
    /* Counter-rotate icon so it's upright-ish or just distinct */
}

.blade-rotater span {
    font-family: var(--font-heading);
    font-size: 1rem;
    color: #aaa;
    letter-spacing: 1px;
    white-space: nowrap;
}

/* Expanded Content */
.blade-expanded {
    position: absolute;
    inset: 0;
    padding: 40px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    background: radial-gradient(circle at center, rgba(212, 175, 55, 0.05) 0%, transparent 70%);
    opacity: 0;
    transform: translateX(20px);
    transition: 0.5s;
    pointer-events: none;
    /* Prevent clicking when hidden */
}

.blade:hover .blade-expanded {
    pointer-events: auto;
}

.be-content {
    max-width: 400px;
    margin: 0 auto;
    text-align: left;
}

.be-header {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 20px;
    border-bottom: 1px solid rgba(212, 175, 55, 0.3);
    padding-bottom: 15px;
}

.be-header i {
    font-size: 2.5rem;
    color: var(--gold);
    text-shadow: 0 0 15px rgba(212, 175, 55, 0.4);
}

.be-header h3 {
    font-family: var(--font-heading);
    color: white;
    font-size: 1.5rem;
    line-height: 1.2;
}

.be-meta {
    display: flex;
    justify-content: space-between;
    margin-bottom: 20px;
    font-family: var(--font-tech);
    font-size: 0.8rem;
    color: #666;
}

.be-meta .status {
    color: #39ff14;
    border: 1px solid #39ff14;
    padding: 2px 8px;
    border-radius: 2px;
    font-size: 0.7rem;
    box-shadow: 0 0 5px rgba(57, 255, 20, 0.3);
}

.be-content p {
    color: #ccc;
    line-height: 1.6;
    margin-bottom: 30px;
    font-size: 0.95rem;
}

.be-link {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: var(--gold);
    text-decoration: none;
    font-family: var(--font-tech);
    border: 1px solid var(--gold);
    padding: 10px 20px;
    transition: 0.3s;
    background: rgba(0, 0, 0, 0.5);
}

.be-link:hover {
    background: var(--gold);
    color: black;
    box-shadow: 0 0 20px rgba(212, 175, 55, 0.4);
}

/* Animations using Index Variable --i */
.blade-collapsed {
    transition-delay: calc(var(--i) * 0.05s);
}

/* Keyframe for initial load */
@keyframes blade-entry {
    from {
        transform: translateY(50px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.blade {
    animation: blade-entry 0.6s ease-out backwards;
    animation-delay: calc(var(--i) * 0.1s);
}

/* Mobile Responsive */
@media (max-width: 800px) {
    .blade-container {
        flex-direction: column;
        height: auto;
        gap: 10px;
    }

    .blade {
        flex: none;
        width: 100%;
        height: 60px;
        /* Collapsed height */
        transition: height 0.4s;
    }

    .blade-collapsed {
        flex-direction: row;
        justify-content: flex-start;
        padding: 0 20px;
    }

    .blade-id {
        writing-mode: horizontal-tb;
        transform: none;
        width: 80px;
    }

    .blade-rotater {
        writing-mode: horizontal-tb;
        transform: none;
        margin-bottom: 0;
    }

    .blade-rotater i {
        transform: none;
    }

    /* Mobile: Expand on Click (or simple hover simulation) */
    .blade:hover,
    .blade:active {
        height: 350px;
        flex: none;
    }

    .blade-expanded {
        padding: 20px;
        transform: translateY(10px);
    }
}

/* Radial Reactor (Certifications) */
.reactor-container {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 50px;
    max-width: 1100px;
    margin: 0 auto;
    padding: 40px 0;
    position: relative;
    /* overflow: hidden; Removed to avoid cutting off effects */
}

/* LEFT: Reactor Core */
.reactor-left {
    position: relative;
    width: 300px;
    height: 300px;
    flex-shrink: 0;
}

.orbit-system {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Core Hub (Center) */
.core-hub {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: radial-gradient(circle at center, #222, #000);
    border: 2px solid var(--gold);
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    z-index: 10;
    box-shadow: 0 0 30px rgba(212, 175, 55, 0.4);
}

.core-hub i {
    font-size: 2rem;
    color: var(--gold);
    z-index: 12;
}

.core-pulse {
    position: absolute;
    inset: -5px;
    border-radius: 50%;
    border: 1px solid var(--gold);
    opacity: 0;
    animation: pulse-ring 2s infinite;
}

@keyframes pulse-ring {
    0% {
        transform: scale(1);
        opacity: 0.8;
    }

    100% {
        transform: scale(1.5);
        opacity: 0;
    }
}

/* Orbit Rings */
.orbit-ring {
    position: absolute;
    border-radius: 50%;
    border: 1px dashed rgba(255, 255, 255, 0.1);
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    pointer-events: none;
}

.ring-1 {
    width: 200px;
    height: 200px;
    animation: spin 20s linear infinite;
    border-color: rgba(212, 175, 55, 0.2);
}

.ring-2 {
    width: 280px;
    height: 280px;
    animation: spin-reverse 30s linear infinite;
}

@keyframes spin {
    from {
        transform: translate(-50%, -50%) rotate(0deg);
    }

    to {
        transform: translate(-50%, -50%) rotate(360deg);
    }
}

@keyframes spin-reverse {
    from {
        transform: translate(-50%, -50%) rotate(360deg);
    }

    to {
        transform: translate(-50%, -50%) rotate(0deg);
    }
}

/* Orbit Nodes */
.orbit-node {
    position: absolute;
    width: 40px;
    height: 40px;
    background: #111;
    border: 1px solid #444;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    transition: 0.3s;
    color: #666;
    font-size: 1.2rem;
    z-index: 5;

    /* Center them initially */
    top: 50%;
    left: 50%;
    margin-top: -20px;
    margin-left: -20px;
}

/* Position nodes in a circle (Radius = 140px) */
.node-1 {
    transform: rotate(0deg) translate(140px) rotate(0deg);
}

.node-2 {
    transform: rotate(45deg) translate(140px) rotate(-45deg);
}

.node-3 {
    transform: rotate(90deg) translate(140px) rotate(-90deg);
}

.node-4 {
    transform: rotate(135deg) translate(140px) rotate(-135deg);
}

.node-5 {
    transform: rotate(180deg) translate(140px) rotate(-180deg);
}

.node-6 {
    transform: rotate(225deg) translate(140px) rotate(-225deg);
}

.node-7 {
    transform: rotate(270deg) translate(140px) rotate(-270deg);
}

.node-8 {
    transform: rotate(315deg) translate(140px) rotate(-315deg);
}

.orbit-node:hover,
.orbit-node.active {
    background: var(--gold);
    color: #000;
    box-shadow: 0 0 15px var(--gold);
    border-color: var(--gold);
    transform: scale(1.1) !important;
    /* Disabling rotation maintenance on hover for simple pop effect, or re-apply calc */
    /* Re-calculating proper transform for active state to keep position */
}

.node-1.active {
    transform: rotate(0deg) translate(140px) rotate(0deg) scale(1.2);
}

.node-2.active {
    transform: rotate(45deg) translate(140px) rotate(-45deg) scale(1.2);
}

.node-3.active {
    transform: rotate(90deg) translate(140px) rotate(-90deg) scale(1.2);
}

.node-4.active {
    transform: rotate(135deg) translate(140px) rotate(-135deg) scale(1.2);
}

.node-5.active {
    transform: rotate(180deg) translate(140px) rotate(-180deg) scale(1.2);
}

.node-6.active {
    transform: rotate(225deg) translate(140px) rotate(-225deg) scale(1.2);
}

.node-7.active {
    transform: rotate(270deg) translate(140px) rotate(-270deg) scale(1.2);
}

.node-8.active {
    transform: rotate(315deg) translate(140px) rotate(-315deg) scale(1.2);
}


/* RIGHT: HUD Display */
.reactor-right {
    flex: 1;
    min-width: 300px;
    height: 300px;
    perspective: 1000px;
}

.holo-hud {
    width: 100%;
    height: 100%;
    border: 1px solid rgba(212, 175, 55, 0.3);
    background: rgba(10, 10, 10, 0.8);
    position: relative;
    padding: 30px;
    display: flex;
    align-items: center;
    clip-path: polygon(10% 0, 100% 0, 100% 90%, 90% 100%, 0 100%, 0 10%);
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.5);
}

.holo-hud::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 20px;
    height: 20px;
    border-top: 2px solid var(--gold);
    border-left: 2px solid var(--gold);
}

.holo-hud::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 20px;
    height: 20px;
    border-bottom: 2px solid var(--gold);
    border-right: 2px solid var(--gold);
}

.hud-content {
    width: 100%;
    opacity: 0;
    transform: translateX(20px);
    transition: 0.4s ease-out;
    display: none;
}

.hud-content.active {
    opacity: 1;
    transform: translateX(0);
    display: block;
}

.hud-header {
    border-bottom: 1px dashed rgba(255, 255, 255, 0.2);
    padding-bottom: 15px;
    margin-bottom: 20px;
}

.serial-no {
    font-family: var(--font-tech);
    color: #666;
    font-size: 0.8rem;
    letter-spacing: 2px;
    display: block;
    margin-bottom: 5px;
}

.hud-title {
    font-family: var(--font-heading);
    color: white;
    font-size: 1.5rem;
    margin: 0;
}

.hud-row {
    font-family: var(--font-tech);
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
    font-size: 0.9rem;
}

.hud-row .label {
    color: #888;
}

.hud-row .value {
    color: var(--gold);
    text-align: right;
}

.hud-row .value.success {
    color: #39ff14;
    text-shadow: 0 0 5px #39ff14;
}

.hud-desc {
    color: #ccc;
    font-size: 0.9rem;
    line-height: 1.6;
    margin-top: 20px;
}

.scan-bar {
    height: 2px;
    background: var(--gold);
    width: 100%;
    margin-top: 20px;
    opacity: 0.5;
    box-shadow: 0 0 10px var(--gold);
    animation: scan-x 2s ease-in-out infinite alternate;
}

@keyframes scan-x {
    from {
        width: 0%;
        margin-left: 0;
    }

    to {
        width: 100%;
        margin-left: 0;
    }
}


/* Responsive */
@media (max-width: 900px) {
    .reactor-container {
        flex-direction: column;
    }

    .reactor-left {
        width: 250px;
        height: 250px;
    }

    .orbit-node {
        transform: scale(0.8) !important;
        /* Simplifying transforms for smaller screens if needed, though media queries for transforms are tricky without redeclaring all locations. Using simplified relative scale. */
    }

    /* Redefine positions for smaller circle if needed, or just scale the container */
    .reactor-left {
        transform: scale(0.9);
    }
}

/* Neural Matrix (Hexagonal Flip Grid) */
.hex-matrix-container {
    max-width: 1100px;
    margin: 40px auto;
    padding: 20px;
    display: flex;
    justify-content: center;
}

.hex-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px 20px;
    /* Vertical gap, Horizontal gap */
    max-width: 900px;
    /* constrain to force wrap nicely */
}

.hex-wrapper {
    width: 200px;
    height: 230px;
    perspective: 1000px;
    /* Scene depth */
    position: relative;
    /* Optional: Negative margins to nest them tighter like honeycomb? 
       Standard hex grid requires precise math. Let's keep it simple flexible grid first.
       If we want tight honeycomb: margin: 0 5px; plus row offsets. 
       Let's stick to a 'floating nodes' look which is safer for varying screen sizes. */
    margin: 10px;
}

.hex-inner {
    position: relative;
    width: 100%;
    height: 100%;
    text-align: center;
    transition: transform 0.8s;
    transform-style: preserve-3d;
    cursor: pointer;
    clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
    background: transparent;
    /* allow clip path on children */
}

/* Flip Logic */
.hex-inner.flipped {
    transform: rotateY(180deg);
}

.hex-front,
.hex-back {
    position: absolute;
    width: 100%;
    height: 100%;
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
    background: rgba(10, 10, 10, 0.9);
    border: 1px solid #333;
    /* Fallback */
}

/* Front Face */
.hex-front {
    background: linear-gradient(135deg, #101010 0%, #050505 100%);
    box-shadow: inset 0 0 20px rgba(0, 0, 0, 0.8);
}

.hex-front:hover {
    background: linear-gradient(135deg, #1a1a1a 0%, #0a0a0a 100%);
}

/* Back Face */
.hex-back {
    transform: rotateY(180deg);
    background: radial-gradient(circle at center, rgba(212, 175, 55, 0.1) 0%, #000 100%);
    border-color: var(--gold);
}

.hex-content {
    padding: 20px;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    width: 100%;
}

/* Front Styling */
.hex-front i {
    font-size: 3rem;
    color: var(--gold-dim);
    margin-bottom: 15px;
    transition: 0.3s;
}

.hex-wrapper:hover .hex-front i {
    color: var(--gold);
    transform: scale(1.1);
    text-shadow: 0 0 10px var(--gold);
}

.hex-front h3 {
    font-family: var(--font-heading);
    color: white;
    font-size: 1rem;
    margin-bottom: 5px;
    letter-spacing: 1px;
}

.hex-id {
    font-family: var(--font-tech);
    color: #555;
    font-size: 0.8rem;
    border-top: 1px solid #333;
    padding-top: 5px;
    width: 60%;
    margin-top: 5px;
}

/* Back Styling */
.hex-back h3 {
    font-family: var(--font-heading);
    color: var(--gold);
    font-size: 0.9rem;
    margin-bottom: 10px;
}

.hex-back p {
    color: #ccc;
    font-size: 0.75rem;
    line-height: 1.4;
    margin-bottom: 15px;
}

.hex-back .status {
    background: rgba(57, 255, 20, 0.1);
    color: #39ff14;
    padding: 2px 8px;
    border: 1px solid #39ff14;
    font-family: var(--font-tech);
    font-size: 0.7rem;
    box-shadow: 0 0 5px rgba(57, 255, 20, 0.2);
}

/* Hex Border Glow */
.hex-border {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 10;
    /* CSS hacks for Hex Borders with clip-path are tricky. 
       We rely on bg color and inner content. 
       Or use a dedicated svg overlay if needed.
       Simple approach: Box shadow doesn't work well with clip-path.
       We'll simulate it with a pseudo element or filter drop-shadow container. */
}

/* Glow effect using filter on container? */
.hex-inner:hover {
    filter: drop-shadow(0 0 10px rgba(212, 175, 55, 0.2));
}

.hex-inner.flipped {
    filter: drop-shadow(0 0 15px rgba(212, 175, 55, 0.4));
}

/* Responsive */
@media (max-width: 600px) {
    .hex-wrapper {
        width: 150px;
        height: 172px;
        /* Aspect ratio roughly 1 : 1.15 */
    }

    .hex-front i {
        font-size: 2rem;
    }

    .hex-front h3 {
        font-size: 0.8rem;
    }

    .hex-back p {
        font-size: 0.65rem;
        display: none;
        /* Hide text on very small screens? No, just shrink */
        display: block;
    }
}

/* Holographic Container */
.holo-container {
    padding: 0px 20px;
    position: relative;
    max-width: 1000px;
    margin: 0 auto;
    overflow: visible;
}

/* Background Effects */
.holo-background {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) perspective(1000px) rotateX(60deg);
    width: 600px;
    height: 600px;
    z-index: 0;
    pointer-events: none;
    opacity: 0.3;
}

.holo-ring {
    position: absolute;
    top: 50%;
    left: 50%;
    border-radius: 50%;
    border: 2px dashed rgba(212, 175, 55, 0.2);
    transform: translate(-50%, -50%);
}

.ring-outer {
    width: 100%;
    height: 100%;
    animation: rotate-cw 40s linear infinite;
}

.ring-inner {
    width: 70%;
    height: 70%;
    border-color: rgba(57, 255, 20, 0.2);
    animation: rotate-ccw 30s linear infinite;
}

.holo-grid-bg {
    position: absolute;
    inset: -50%;
    background:
        linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
    background-size: 40px 40px;
    width: 200%;
    height: 200%;
    transform: translateZ(-200px);
    mask-image: radial-gradient(circle, black 30%, transparent 70%);
}

/* Main Stage */
.holo-stage {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 40px;
    position: relative;
    z-index: 10;
    min-height: 450px;
}

.nav-btn {
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid var(--gold-dim);
    color: var(--gold);
    width: 50px;
    height: 50px;
    border-radius: 50%;
    font-size: 1.2rem;
    cursor: pointer;
    transition: 0.3s;
    backdrop-filter: blur(5px);
}

.nav-btn:hover {
    background: var(--gold);
    color: black;
    box-shadow: 0 0 20px rgba(212, 175, 55, 0.4);
}

/* Projector Assembly */
.projector-assembly {
    position: relative;
    width: 500px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.projector-base {
    width: 300px;
    height: 40px;
    background: linear-gradient(90deg, #111 0%, #333 50%, #111 100%);
    border-radius: 50%;
    /* flattened cylinder look */
    border: 1px solid #444;
    position: relative;
    margin-top: -20px;
    z-index: 1;
    box-shadow: 0 10px 30px black;
}

.base-light {
    position: absolute;
    top: -5px;
    left: 20%;
    right: 20%;
    height: 10px;
    background: var(--gold);
    border-radius: 50%;
    filter: blur(10px);
    opacity: 0.8;
    animation: pulse-light 2s infinite alternate;
}

.projection-beam {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    width: 300px;
    /* Beam width at source */
    height: 400px;
    background: linear-gradient(to top, rgba(212, 175, 55, 0.1), transparent 80%);
    clip-path: polygon(20% 100%, 80% 100%, 100% 0, 0 0);
    z-index: 0;
    pointer-events: none;
    opacity: 0.6;
}

/* Hologram Content */
.hologram-content {
    min-height: 350px;
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    perspective: 800px;
}

.holo-card {
    background: rgba(10, 15, 20, 0.85);
    border: 1px solid rgba(212, 175, 55, 0.4);
    padding: 30px;
    border-radius: 10px;
    width: 100%;
    text-align: center;
    backdrop-filter: blur(8px);
    box-shadow: 0 0 30px rgba(0, 0, 0, 0.5), inset 0 0 20px rgba(212, 175, 55, 0.05);
    transform-origin: bottom center;
    display: none;
    opacity: 0;
    /* initial state for animation */
    transform: translateY(20px) scale(0.95);
}

.holo-card.active {
    display: block;
    animation: holo-materialize 0.6s cubic-bezier(0.19, 1, 0.22, 1) forwards;
}

@keyframes holo-materialize {
    0% {
        opacity: 0;
        transform: translateY(40px) scale(0.9) skewX(2deg);
        filter: blur(10px);
    }

    50% {
        opacity: 0.8;
        transform: translateY(-5px) scale(1.02) skewX(-1deg);
        filter: blur(2px);
    }

    100% {
        opacity: 1;
        transform: translateY(0) scale(1) skewX(0);
        filter: blur(0);
    }
}

.holo-card.leaving {
    animation: holo-dematerialize 0.4s ease-in forwards;
}

@keyframes holo-dematerialize {
    0% {
        opacity: 1;
        transform: translateY(0);
        filter: blur(0);
    }

    100% {
        opacity: 0;
        transform: translateY(-30px) scale(1.1);
        filter: blur(15px);
    }
}

/* Visual Icon */
.holo-visual {
    margin-bottom: 20px;
    position: relative;
    display: inline-block;
}

.holo-visual i {
    font-size: 3.5rem;
    color: var(--gold);
    filter: drop-shadow(0 0 15px rgba(212, 175, 55, 0.6));
}

.holo-glitch {
    position: absolute;
    inset: 0;
    background: transparent;
    mix-blend-mode: overlay;
    display: none;
    /* activated via js? or animation keyframes if simple css override */
}

/* Info Styling */
.holo-header h2 {
    font-family: var(--font-heading);
    color: white;
    font-size: 1.6rem;
    margin: 5px 0 10px 0;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.holo-id {
    font-family: var(--font-tech);
    color: #666;
    font-size: 0.8rem;
    letter-spacing: 2px;
}

.holo-status {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(57, 255, 20, 0.1);
    border: 1px solid #39ff14;
    padding: 4px 12px;
    border-radius: 20px;
    margin-bottom: 20px;
    font-family: var(--font-tech);
    font-size: 0.75rem;
    color: #39ff14;
    box-shadow: 0 0 10px rgba(57, 255, 20, 0.2);
}

.status-dot {
    width: 6px;
    height: 6px;
    background: #39ff14;
    border-radius: 50%;
    box-shadow: 0 0 5px #39ff14;
    animation: blink 1s infinite alternate;
}

.holo-desc {
    color: #ccc;
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 25px;
}

.holo-meta {
    display: flex;
    justify-content: center;
    gap: 20px;
    color: #888;
    font-size: 0.9rem;
    font-family: var(--font-tech);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 15px;
}

.holo-meta i {
    color: var(--gold-dim);
    margin-right: 5px;
}

/* Pagination */
.holo-pagination {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 30px;
}

.holo-pagination .dot {
    width: 30px;
    height: 4px;
    background: #333;
    cursor: pointer;
    transition: 0.3s;
    border-radius: 2px;
}

.holo-pagination .dot.active {
    background: var(--gold);
    box-shadow: 0 0 10px var(--gold);
    width: 50px;
}

/* Animations */
@keyframes rotate-cw {
    from {
        transform: translate(-50%, -50%) rotate(0deg);
    }

    to {
        transform: translate(-50%, -50%) rotate(360deg);
    }
}

@keyframes rotate-ccw {
    from {
        transform: translate(-50%, -50%) rotate(360deg);
    }

    to {
        transform: translate(-50%, -50%) rotate(0deg);
    }
}

@keyframes pulse-light {
    from {
        opacity: 0.5;
        height: 8px;
    }

    to {
        opacity: 0.9;
        height: 12px;
    }
}

@keyframes blink {
    from {
        opacity: 0.4;
    }

    to {
        opacity: 1;
    }
}

/* Responsive */
@media (max-width: 768px) {
    .holo-stage {
        flex-direction: column;
        min-height: auto;
    }

    .projector-assembly {
        width: 100%;
    }

    .holo-card {
        padding: 20px;
    }

    .nav-btn {
        position: absolute;
        top: 50%;
        z-index: 20;
    }

    .prev-btn {
        left: 0;
    }

    .next-btn {
        right: 0;
    }
}

/* Strategic Carousel 3D Styles */
.carousel-scope {
    max-width: 1000px;
    margin: 40px auto;
    perspective: 1000px;
    overflow: hidden;
    padding-bottom: 40px;
    position: relative;
}

.carousel-stage {
    position: relative;
    height: 350px;
    display: flex;
    justify-content: center;
    align-items: center;
    transform-style: preserve-3d;
}

/* Individual Card Styling */
.carousel-card {
    position: absolute;
    width: 220px;
    height: 300px;
    background: linear-gradient(135deg, rgba(20, 20, 20, 0.95), rgba(10, 10, 10, 0.98));
    border: 1px solid #333;
    border-radius: 6px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    transition: all 0.5s cubic-bezier(0.25, 1, 0.5, 1);
    cursor: pointer;
    /* Reflection Effect */
    -webkit-box-reflect: below 5px linear-gradient(transparent 70%, rgba(0, 0, 0, 0.4));
}

.card-visual {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid #444;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 20px;
    box-shadow: inset 0 0 20px rgba(0, 0, 0, 0.8);
}

.card-visual i {
    font-size: 2.5rem;
    color: #666;
    transition: 0.3s;
}

.card-content h3 {
    font-family: var(--font-heading);
    color: #ccc;
    font-size: 1rem;
    margin-bottom: 5px;
    text-align: center;
}

.card-id {
    font-family: var(--font-tech);
    color: #555;
    font-size: 0.8rem;
    display: block;
    text-align: center;
    margin-bottom: 15px;
}

.card-status {
    background: #111;
    color: #444;
    border: 1px solid #333;
    padding: 2px 8px;
    font-size: 0.7rem;
    font-family: var(--font-tech);
    border-radius: 4px;
}

/* 3D State Classes (Controlled by JS) */
.carousel-card.active {
    transform: translateX(0) scale(1.1) translateZ(50px);
    z-index: 10;
    border-color: var(--gold);
    box-shadow: 0 0 20px rgba(212, 175, 55, 0.2);
}

.carousel-card.active .card-visual i {
    color: var(--gold);
    text-shadow: 0 0 10px var(--gold);
}

.carousel-card.active .card-status {
    color: #39ff14;
    border-color: #39ff14;
    box-shadow: 0 0 5px rgba(57, 255, 20, 0.3);
}

.carousel-card.prev-1 {
    transform: translateX(-140%) scale(0.85) rotateY(25deg) translateZ(-50px);
    z-index: 5;
    opacity: 0.6;
    background: rgba(10, 10, 10, 0.8);
}

.carousel-card.next-1 {
    transform: translateX(140%) scale(0.85) rotateY(-25deg) translateZ(-50px);
    z-index: 5;
    opacity: 0.6;
    background: rgba(10, 10, 10, 0.8);
}

.carousel-card.prev-2 {
    transform: translateX(-240%) scale(0.7) rotateY(45deg) translateZ(-100px);
    z-index: 2;
    opacity: 0.3;
}

.carousel-card.next-2 {
    transform: translateX(240%) scale(0.7) rotateY(-45deg) translateZ(-100px);
    z-index: 2;
    opacity: 0.3;
}

.carousel-card.hidden {
    transform: translateX(0) scale(0);
    opacity: 0;
    z-index: 0;
}

/* Controls */
.carousel-nav {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 30px;
    margin-top: 10px;
}

.c-btn {
    background: transparent;
    color: var(--gold);
    border: 1px solid var(--gold-dim);
    width: 40px;
    height: 40px;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    transition: 0.3s;
}

.c-btn:hover {
    background: var(--gold);
    color: black;
    box-shadow: 0 0 10px var(--gold);
}

.c-indicators {
    display: flex;
    gap: 5px;
}

.c-dot {
    width: 6px;
    height: 6px;
    background: #333;
    border-radius: 50%;
    transition: 0.3s;
    cursor: pointer;
}

.c-dot.active {
    background: var(--gold);
    box-shadow: 0 0 5px var(--gold);
    transform: scale(1.5);
}

/* Details Panel */
.carousel-details {
    margin-top: 30px;
    min-height: 120px;
    text-align: center;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    background: rgba(255, 255, 255, 0.02);
    border-top: 2px solid var(--gold);
    padding: 20px;
    position: relative;
}

.carousel-details::before {
    content: '';
    position: absolute;
    top: -2px;
    left: 0;
    width: 10px;
    height: 10px;
    background: var(--gold);
}

.carousel-details::after {
    content: '';
    position: absolute;
    top: -2px;
    right: 0;
    width: 10px;
    height: 10px;
    background: var(--gold);
}

.info-inner h2 {
    font-family: var(--font-heading);
    color: white;
    font-size: 1.4rem;
    margin-bottom: 10px;
}

.info-inner p {
    color: #aaa;
    line-height: 1.5;
    font-size: 0.95rem;
}

/* Cyber-Dock Interface */
.deck-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    height: 500px;
    position: relative;
    padding: 20px 0;
}

/* Reader Stage (Top) */
.deck-reader {
    width: 600px;
    height: 300px;
    background: #050505;
    border: 2px solid #333;
    border-radius: 10px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 0 50px rgba(0, 0, 0, 0.8);
    background-image: linear-gradient(0deg, transparent 24%, rgba(255, 255, 255, .02) 25%, rgba(255, 255, 255, .02) 26%, transparent 27%, transparent 74%, rgba(255, 255, 255, .02) 75%, rgba(255, 255, 255, .02) 76%, transparent 77%, transparent), linear-gradient(90deg, transparent 24%, rgba(255, 255, 255, .02) 25%, rgba(255, 255, 255, .02) 26%, transparent 27%, transparent 74%, rgba(255, 255, 255, .02) 75%, rgba(255, 255, 255, .02) 76%, transparent 77%, transparent);
    background-size: 30px 30px;
}

.reader-screen {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.reader-scan-line {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 5px;
    background: rgba(212, 175, 55, 0.5);
    box-shadow: 0 0 10px var(--gold);
    animation: scanReader 3s linear infinite;
    pointer-events: none;
    z-index: 10;
}

@keyframes scanReader {
    0% {
        top: -10%;
        opacity: 0;
    }

    10% {
        opacity: 1;
    }

    90% {
        opacity: 1;
    }

    100% {
        top: 110%;
        opacity: 0;
    }
}

.reader-glare {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 50% 10%, rgba(255, 255, 255, 0.05), transparent 60%);
    pointer-events: none;
    z-index: 5;
}

/* Reader Content */
.reader-content {
    display: none;
    flex-direction: row;
    align-items: center;
    gap: 30px;
    width: 100%;
    padding: 30px;
    opacity: 0;
    transform: scale(0.9);
}

.reader-content.active {
    display: flex;
    animation: contentPop 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

@keyframes contentPop {
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.content-left i {
    font-size: 5rem;
    color: var(--gold);
    filter: drop-shadow(0 0 15px rgba(212, 175, 55, 0.6));
}

.content-right h2 {
    font-family: var(--font-heading);
    color: white;
    font-size: 1.5rem;
    margin-bottom: 10px;
    text-transform: uppercase;
}

.r-meta {
    display: flex;
    gap: 15px;
    font-family: var(--font-tech);
    font-size: 0.8rem;
    color: #666;
    margin-bottom: 15px;
}

.r-status {
    color: #39ff14;
    border: 1px solid #39ff14;
    padding: 1px 6px;
    border-radius: 4px;
}

.content-right p {
    color: #bbb;
    font-size: 0.95rem;
    line-height: 1.5;
}

.r-bar {
    height: 2px;
    width: 50px;
    background: var(--gold);
    margin-top: 15px;
    box-shadow: 0 0 10px var(--gold);
}


/* Cyber Dock (Bottom) */
.cyber-dock-wrapper {
    position: absolute;
    bottom: 20px;
    width: 100%;
    display: flex;
    justify-content: center;
}

.cyber-dock {
    display: flex;
    gap: 10px;
    background: rgba(255, 255, 255, 0.05);
    /* Glassmorph base */
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 10px 15px;
    backdrop-filter: blur(10px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    align-items: flex-end;
    /* All items sit on bottom baseline */
    height: 80px;
    /* Base height */
}

.dock-item {
    width: 50px;
    /* Base width */
    height: 50px;
    /* Base height */
    background: #111;
    border-radius: 12px;
    border: 1px solid #444;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    transition: width 0.1s, height 0.1s, transform 0.1s;
    /* Very fast transition for mouse follower */
    position: relative;
    flex-shrink: 0;
}

.dock-icon i {
    color: #888;
    font-size: 1.2rem;
    pointer-events: none;
    transition: 0.1s;
}

.dock-item:hover {
    border-color: var(--gold);
    background: #222;
    box-shadow: 0 0 15px rgba(212, 175, 55, 0.4);
}

.dock-item:hover .dock-icon i {
    color: var(--gold);
}

/* Tooltip */
.dock-tooltip {
    position: absolute;
    top: -40px;
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 5px 10px;
    border-radius: 5px;
    font-size: 0.75rem;
    font-family: var(--font-tech);
    opacity: 0;
    pointer-events: none;
    transition: 0.2s;
    white-space: nowrap;
    border: 1px solid #333;
}

.dock-item:hover .dock-tooltip {
    opacity: 1;
    top: -50px;
}

/* Responsive */
@media (max-width: 700px) {
    .deck-reader {
        width: 95%;
        height: auto;
        min-height: 250px;
    }

    .content-left i {
        font-size: 3rem;
    }

    .reader-content {
        flex-direction: column;
        text-align: center;
    }

    .cyber-dock {
        overflow-x: auto;
        justify-content: flex-start;
        max-width: 100%;
    }
}

/* --- NEW ARCHIVES INTERFACE --- */
.archives-container {
    display: flex;
    gap: 30px;
    max-width: 1100px;
    margin: 0 auto;
    min-height: 500px;
    align-items: stretch;
}

/* LEFT: Archives List */
.archives-list {
    flex: 0 0 350px;
    background: rgba(10, 10, 10, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    flex-direction: column;
    max-height: 600px;
    overflow-y: auto;
}

.archive-header {
    background: rgba(212, 175, 55, 0.1);
    color: var(--gold);
    padding: 15px;
    font-family: var(--font-heading);
    letter-spacing: 2px;
    border-bottom: 1px solid var(--gold);
    position: sticky;
    top: 0;
    z-index: 10;
    backdrop-filter: blur(5px);
}

.archive-item {
    display: flex;
    align-items: center;
    padding: 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    cursor: pointer;
    transition: 0.3s;
    position: relative;
    background: transparent;
}

.archive-item:hover {
    background: rgba(255, 255, 255, 0.05);
    padding-left: 20px;
}

.archive-item.active {
    background: rgba(212, 175, 55, 0.1);
    border-left: 4px solid var(--gold);
}

.item-status {
    width: 8px;
    height: 8px;
    background: #444;
    border-radius: 50%;
    margin-right: 15px;
    box-shadow: 0 0 5px rgba(0, 0, 0, 0.5);
    transition: 0.3s;
}

.archive-item.active .item-status {
    background: #00ff00;
    box-shadow: 0 0 10px #00ff00;
}

.item-meta {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.item-id {
    font-family: var(--font-tech);
    font-size: 0.7rem;
    color: #666;
    letter-spacing: 1px;
}

.item-name {
    font-family: var(--font-tech);
    font-size: 1rem;
    color: white;
    font-weight: 600;
}

.archive-item.active .item-name {
    color: var(--gold);
}

.archive-item i.fa-chevron-right {
    font-size: 0.8rem;
    color: #444;
    transition: 0.3s;
}

.archive-item.active i.fa-chevron-right {
    color: var(--gold);
    transform: translateX(5px);
}

/* RIGHT: Viewer */
.archives-viewer {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.viewer-frame {
    flex: 1;
    background: rgba(0, 0, 0, 0.8);
    border: 1px solid rgba(212, 175, 55, 0.3);
    position: relative;
    padding: 2px;
    /* Inner border spacing */
    box-shadow: 0 0 30px rgba(0, 0, 0, 0.5);
    background-image:
        radial-gradient(circle at center, rgba(10, 30, 50, 0.4) 0%, rgba(0, 0, 0, 0.9) 100%),
        repeating-linear-gradient(0deg, transparent 0, transparent 1px, rgba(0, 255, 255, 0.02) 2px, transparent 3px);
    background-size: 100% 100%, 100% 4px;
}

.viewer-overlay {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 1;
    background: radial-gradient(circle at 50% 50%, transparent 80%, rgba(0, 0, 0, 0.8) 100%);
    box-shadow: inset 0 0 50px rgba(0, 0, 0, 0.5);
}

.viewer-header-bar {
    display: flex;
    justify-content: space-between;
    padding: 10px 20px;
    border-bottom: 1px solid rgba(212, 175, 55, 0.2);
    font-family: var(--font-tech);
    font-size: 0.8rem;
    color: var(--gold-dim);
    letter-spacing: 2px;
    background: rgba(0, 0, 0, 0.5);
}

.blink-text {
    animation: blink-soft 2s infinite;
}

@keyframes blink-soft {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.5;
    }
}

.viewer-indicators span {
    margin-left: 10px;
    color: #444;
}

.viewer-indicators span:first-child {
    color: var(--gold);
}

/* CONTENT AREA */
#cert-content-area {
    padding: 40px;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    z-index: 2;
}

.cert-display {
    text-align: center;
    max-width: 600px;
    opacity: 0;
    transform: translateY(20px);
    transition: 0.5s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.cert-display.active-display {
    opacity: 1;
    transform: translateY(0);
}

.cert-icon-large {
    font-size: 5rem;
    color: var(--gold);
    margin-bottom: 20px;
    text-shadow: 0 0 30px rgba(212, 175, 55, 0.3);
    animation: float-icon 4s ease-in-out infinite;
}

@keyframes float-icon {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }
}

.cd-title {
    font-family: var(--font-heading);
    color: white;
    font-size: 2rem;
    margin-bottom: 5px;
    letter-spacing: 2px;
}

.cd-subtitle {
    font-family: var(--font-tech);
    color: #888;
    font-size: 1.1rem;
    margin-bottom: 30px;
}

.cd-meta {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 10px;
    margin-bottom: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding: 15px 0;
}

.cd-row {
    text-align: center;
}

.cd-label {
    display: block;
    font-size: 0.7rem;
    color: #555;
    margin-bottom: 3px;
}

.cd-val {
    display: block;
    font-size: 0.9rem;
    color: var(--gold);
    font-weight: bold;
}

.cd-val.highlight {
    color: #00ff00;
    text-shadow: 0 0 10px rgba(0, 255, 0, 0.3);
}

.cd-desc {
    font-size: 1rem;
    line-height: 1.6;
    color: #ccc;
    text-align: justify;
}

/* Viewer Corners */
.viewer-corner {
    position: absolute;
    width: 20px;
    height: 20px;
    border: 2px solid var(--gold);
    transition: 0.3s;
}

.viewer-corner.top-left {
    top: -1px;
    left: -1px;
    border-right: none;
    border-bottom: none;
}

.viewer-corner.bottom-right {
    bottom: -1px;
    right: -1px;
    border-left: none;
    border-top: none;
}

/* Responsive Archives */
@media (max-width: 850px) {
    .archives-container {
        flex-direction: column;
        height: auto;
    }

    .archives-list {
        flex: none;
        /* Auto height */
        max-height: 250px;
    }

    .archives-viewer {
        min-height: 400px;
    }

    .cd-meta {
        grid-template-columns: 1fr;
        gap: 15px;
    }
}

/* --- STRATEGIC CAROUSEL & CAROUSEL --- */
.carousel-wrapper {
    position: relative;
    max-width: 1000px;
    margin: 0 auto;
    padding: 20px 0;
}

.c-track-container {
    overflow: hidden;
    width: 100%;
    padding: 40px 0;
    /* Space for scale effect */
    mask-image: linear-gradient(to right, transparent, black 20%, black 80%, transparent);
    -webkit-mask-image: linear-gradient(to right, transparent, black 20%, black 80%, transparent);
}

.c-track {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0;
    /* Gap handled by transforms */
    position: relative;
    height: 350px;
    /* perspective: 1000px; Remove perspective from track, handle in JS */
}

/* Carousel Card */
.carousel-card {
    flex: 0 0 240px;
    height: 300px;
    background: rgba(10, 10, 10, 0.9);
    border: 1px solid var(--gold-dim);
    position: absolute;
    /* Absolute positioning for 3D stack */
    transition: all 0.5s cubic-bezier(0.25, 1, 0.5, 1);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
    cursor: pointer;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    left: 50%;
    transform: translateX(-50%);
    /* Start at center */
}

.carousel-card.active {
    z-index: 10;
    transform: translateX(-50%) scale(1.1);
    border-color: var(--gold);
    box-shadow: 0 0 40px rgba(212, 175, 55, 0.3);
    background: radial-gradient(circle at center, rgba(30, 30, 30, 0.9), rgba(10, 10, 10, 0.95));
}

.carousel-card.prev-1 {
    z-index: 5;
    transform: translateX(-160%) scale(0.85) rotateY(15deg);
    opacity: 0.6;
    background: rgba(10, 10, 10, 0.7);
}

.carousel-card.next-1 {
    z-index: 5;
    transform: translateX(60%) scale(0.85) rotateY(-15deg);
    opacity: 0.6;
    background: rgba(10, 10, 10, 0.7);
}

.carousel-card.prev-2 {
    z-index: 2;
    transform: translateX(-240%) scale(0.7) rotateY(25deg);
    opacity: 0.3;
}

.carousel-card.next-2 {
    z-index: 2;
    transform: translateX(140%) scale(0.7) rotateY(-25deg);
    opacity: 0.3;
}

.carousel-card.hidden {
    opacity: 0;
    pointer-events: none;
    z-index: 0;
}

.c-icon {
    font-size: 3rem;
    color: var(--gold);
    margin-bottom: 20px;
    text-shadow: 0 0 10px rgba(212, 175, 55, 0.5);
}

.carousel-card.active .c-icon {
    transform: scale(1.1);
    color: #fff;
    text-shadow: 0 0 20px var(--gold);
}

.c-card-title {
    font-family: var(--font-heading);
    color: white;
    font-size: 1.1rem;
    text-align: center;
    margin-bottom: 5px;
}

.c-card-id {
    font-family: var(--font-tech);
    color: var(--gold-dim);
    font-size: 0.8rem;
    letter-spacing: 1px;
}

/* Controls */
.c-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-100%);
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid var(--gold);
    color: var(--gold);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    z-index: 20;
    transition: 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.c-btn:hover {
    background: var(--gold);
    color: black;
    box-shadow: 0 0 15px var(--gold);
}

.c-btn.prev {
    left: 10px;
}

.c-btn.next {
    right: 10px;
}

/* Indicators */
.c-indicators {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 10px;
}

.c-dot {
    width: 8px;
    height: 8px;
    background: #444;
    border-radius: 50%;
    cursor: pointer;
    transition: 0.3s;
}

.c-dot.active {
    background: var(--gold);
    box-shadow: 0 0 10px var(--gold);
    transform: scale(1.2);
}

/* Details Panel */
.c-details-panel {
    text-align: center;
    margin-top: 30px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.05);
    border-top: 1px solid var(--gold-dim);
    border-bottom: 1px solid var(--gold-dim);
    position: relative;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.c-panel-header {
    margin-bottom: 15px;
}

.c-tag {
    display: inline-block;
    font-family: var(--font-tech);
    font-size: 0.7rem;
    color: var(--gold);
    border: 1px solid var(--gold);
    padding: 2px 8px;
    margin-bottom: 10px;
    letter-spacing: 2px;
}

.c-details-panel h3 {
    font-family: var(--font-heading);
    color: white;
    font-size: 1.5rem;
    letter-spacing: 1px;
}

.c-desc {
    color: #ccc;
    font-size: 1rem;
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.6;
}

.c-decor-bar {
    width: 100px;
    height: 3px;
    background: var(--gold);
    margin: 20px auto 0;
    box-shadow: 0 0 10px var(--gold);
}

/* MOBILE RESPONSE */
@media (max-width: 768px) {
    .c-track-container {
        /* On mobile, switch to scroll snap */
        mask-image: none;
        -webkit-mask-image: none;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        display: block;
        padding: 20px 0;
        height: auto;
    }

    .c-track {
        display: flex;
        /* Flex row for scroll */
        justify-content: flex-start;
        /* Start align */
        width: max-content;
        /* Allow growing */
        position: static;
        /* Reset absolute positioning context */
        height: auto;
        padding: 0 20px;
        /* Spacer */
        gap: 20px;
    }

    .carousel-card {
        position: static;
        /* Reset absolute */
        transform: none !important;
        /* Disable 3D transforms */
        opacity: 1 !important;
        /* Always visible */
        flex: 0 0 260px;
        /* Fixed width card */
        scroll-snap-align: center;
        background: rgba(20, 20, 20, 0.9);
        margin: 0;
        left: auto;
    }

    .carousel-card.active {
        border-color: var(--gold);
        transform: scale(1.05) !important;
        /* Mild scale */
    }

    /* Hide 3D buttons on mobile, rely on swipe */
    .c-btn {
        display: none;
    }

    .carousel-wrapper {
        padding: 0;
    }
}

/* --- QUANTUM DATA FIELD --- */
.edu-quantum-gate {
    display: flex;
    justify-content: center;
    align-items: stretch;
    padding: 60px 20px;
    max-width: 1100px;
    margin: 0 auto;
    gap: 30px;
}

/* Generator Pillars */
.gate-pillar {
    width: 60px;
    background: linear-gradient(180deg, #111, #222, #111);
    border: 1px solid #333;
    border-radius: 4px;
    position: relative;
    display: flex;
    justify-content: center;
    padding: 10px 0;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.8);
    flex-shrink: 0;
}

.pillar-core {
    width: 6px;
    background: #000;
    border-radius: 3px;
    height: 100%;
    position: relative;
    overflow: hidden;
}

/* Energy flow inside the core */
.pillar-core::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 50%;
    background: linear-gradient(180deg, transparent, var(--gold), transparent);
    filter: blur(2px);
    animation: energy-flow 2s linear infinite;
    opacity: 0.5;
}

@keyframes energy-flow {
    0% {
        top: -50%;
        opacity: 0;
    }

    50% {
        opacity: 0.8;
    }

    100% {
        top: 100%;
        opacity: 0;
    }
}

.pillar-light {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 20px;
    height: 60%;
    background: var(--gold);
    filter: blur(15px);
    opacity: 0.2;
    animation: pillar-pulse 3s infinite alternate;
}

@keyframes pillar-pulse {
    from {
        height: 40%;
        opacity: 0.1;
        box-shadow: 0 0 10px var(--gold);
    }

    to {
        height: 80%;
        opacity: 0.4;
        box-shadow: 0 0 30px var(--gold);
    }
}

/* Central Content */
.gate-content-zone {
    flex: 1;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.energy-particles {
    position: absolute;
    inset: 0;
    background-image: radial-gradient(circle, rgba(212, 175, 55, 0.2) 1px, transparent 1px);
    background-size: 30px 30px;
    opacity: 0.5;
    z-index: 1;
    mask-image: linear-gradient(90deg, transparent, black, transparent);
    -webkit-mask-image: linear-gradient(90deg, transparent, black, transparent);
    animation: particle-drift 20s linear infinite;
}

@keyframes particle-drift {
    from {
        background-position: 0 0;
    }

    to {
        background-position: 100px 0;
    }
}

.gate-card {
    position: relative;
    z-index: 5;
    background: rgba(15, 15, 15, 0.9);
    border: 1px solid rgba(212, 175, 55, 0.2);
    /* Neon bracket borders */
    border-left: 4px solid var(--gold);
    border-right: 4px solid var(--gold);
    padding: 40px;
    text-align: center;
    box-shadow: 0 0 50px rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    transform: scale(0.95);
    transition: all 0.5s ease-out;
    /* Base transition */
    width: 100%;
    max-width: 700px;
    /* Apply zoom-out animation when not hovered */
    /* Base Float Animation */
    animation: card-float 4s ease-in-out infinite;
    overflow: hidden;
    /* For scan line */
}

/* Hover state stops float and scales up */
/* Hover state stops float and scales up */
.gate-card:hover {
    transform: scale(1.05);
    /* Transition smoothly handles this */
    box-shadow: 0 0 40px rgba(212, 175, 55, 0.15);
    border-color: rgba(212, 175, 55, 0.4);
    animation-play-state: paused;
    /* Pause float so it doesn't jump */
}

@keyframes card-float {

    0%,
    100% {
        transform: translateY(0) scale(0.95);
    }

    50% {
        transform: translateY(-10px) scale(0.95);
    }
}

/* Holographic Scan Line */
.gate-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 50%;
    background: linear-gradient(180deg, transparent, rgba(212, 175, 55, 0.1), transparent);
    transform: translateY(-100%);
    animation: scan-line 3s cubic-bezier(0.4, 0, 0.2, 1) infinite;
    pointer-events: none;
}

@keyframes scan-line {
    0% {
        transform: translateY(-150%);
        opacity: 0;
    }

    20% {
        opacity: 1;
    }

    100% {
        transform: translateY(200%);
        opacity: 0;
    }
}

.gc-header {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-bottom: 20px;
    color: var(--gold);
    font-family: var(--font-tech);
    font-size: 0.9rem;
    letter-spacing: 2px;
}

.gc-main {
    margin-bottom: 30px;
}

.gc-degree {
    font-family: var(--font-heading);
    font-size: 2.2rem;
    color: white;
    line-height: 1.1;
    margin-bottom: 15px;
    text-shadow: 0 0 20px rgba(0, 0, 0, 0.5);
}

.gc-divider {
    height: 1px;
    width: 100px;
    background: linear-gradient(90deg, transparent, var(--gold), transparent);
    margin: 0 auto 15px;
}

.gc-uni {
    font-family: var(--font-tech);
    font-size: 1.2rem;
    color: #aeaeae;
    letter-spacing: 3px;
}

.gc-footer {
    display: flex;
    justify-content: space-around;
    border-top: 1px dashed rgba(255, 255, 255, 0.1);
    padding-top: 20px;
}

.gc-stat {
    display: flex;
    flex-direction: column;
    gap: 5px;
    transition: 0.3s;
}

.gc-stat:hover {
    transform: translateY(-3px);
}

.stat-lbl {
    font-size: 0.7rem;
    color: #555;
    font-family: var(--font-tech);
    letter-spacing: 1px;
}

.stat-val {
    font-size: 1rem;
    color: #ccc;
    font-weight: bold;
}

.stat-val.highlight {
    color: #39ff14;
    text-shadow: 0 0 5px rgba(57, 255, 20, 0.4);
}

/* RESPONSIVE */
@media (max-width: 768px) {
    .edu-quantum-gate {
        flex-direction: column;
        align-items: center;
        gap: 0;
        padding-top: 30px;
    }

    .gate-pillar {
        width: 100%;
        height: 40px;
        flex-direction: row;
        /* Horizontal pillars on mobile */
        margin: 10px 0;
    }

    .pillar-core {
        height: 6px;
        width: 100%;
        margin-top: 15px;
        /* Center somewhat */
    }

    .pillar-core::after {
        width: 50%;
        height: 100%;
        background: linear-gradient(90deg, transparent, var(--gold), transparent);
        animation-name: energy-flow-h;
    }

    @keyframes energy-flow-h {
        0% {
            left: -50%;
            opacity: 0;
        }

        50% {
            opacity: 0.8;
        }

        100% {
            left: 100%;
            opacity: 0;
        }
    }

    .gate-card {
        border-left: 1px solid rgba(212, 175, 55, 0.2);
        border-right: 1px solid rgba(212, 175, 55, 0.2);
        border-top: 4px solid var(--gold);
        border-bottom: 4px solid var(--gold);
        padding: 30px 20px;
        animation: none;
        /* Disable float on mobile for steadiness */
        transform: scale(1);
    }

    .gc-footer {
        flex-direction: column;
        gap: 15px;
    }

    .gc-degree {
        font-size: 1.6rem;
    }
}

/* =========================================
   HOLOGRAPHIC COMMAND TERMINAL (Contact Section)
   ========================================= */

.holo-terminal-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: flex-start;
    gap: 60px;
    perspective: 1500px;
    padding: 40px 20px;
    position: relative;
    z-index: 10;
}

/* Background Grid Setup */
.terminal-grid-bg {
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background-image:
        linear-gradient(rgba(212, 175, 55, 0.05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(212, 175, 55, 0.05) 1px, transparent 1px);
    background-size: 50px 50px;
    transform: perspective(500px) rotateX(60deg);
    z-index: -1;
    opacity: 0.5;
    pointer-events: none;
    animation: grid-scroll 20s linear infinite;
}

@keyframes grid-scroll {
    from {
        transform: perspective(500px) rotateX(60deg) translateY(0);
    }

    to {
        transform: perspective(500px) rotateX(60deg) translateY(50px);
    }
}

/* TERMINAL MAIN UNIT */
.holo-terminal {
    flex: 1;
    min-width: 350px;
    max-width: 700px;
    background: rgba(10, 10, 12, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(212, 175, 55, 0.3);
    border-top: 2px solid var(--gold);
    border-radius: 8px;
    box-shadow:
        0 20px 50px rgba(0, 0, 0, 0.6),
        0 0 0 1px rgba(212, 175, 55, 0.1),
        inset 0 0 60px rgba(0, 0, 0, 0.8);
    transform: rotateX(5deg);
    transition: transform 0.4s ease, box-shadow 0.4s ease;
    overflow: hidden;
    position: relative;
}

.holo-terminal:hover,
.holo-terminal:focus-within {
    transform: rotateX(0deg) translateY(-5px);
    box-shadow:
        0 30px 60px rgba(0, 0, 0, 0.7),
        0 0 20px rgba(212, 175, 55, 0.15),
        inset 0 0 40px rgba(0, 0, 0, 0.8);
    border-color: var(--gold);
}

/* Terminal Header */
.terminal-header {
    background: rgba(20, 20, 20, 0.95);
    padding: 15px 25px;
    border-bottom: 1px solid rgba(212, 175, 55, 0.2);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.status-lights {
    display: flex;
    gap: 8px;
}

.light {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #333;
}

.light.red {
    background: #ff5f56;
    box-shadow: 0 0 5px #ff5f56;
}

.light.yellow {
    background: #ffbd2e;
    box-shadow: 0 0 5px #ffbd2e;
}

.light.green {
    background: #27c93f;
    box-shadow: 0 0 5px #27c93f;
}

.terminal-title {
    font-family: var(--font-tech);
    color: var(--gold);
    letter-spacing: 2px;
    font-size: 0.9rem;
    opacity: 0.8;
}

.connection-status {
    font-family: var(--font-tech);
    color: #39ff14;
    font-size: 0.8rem;
    display: flex;
    gap: 8px;
    align-items: center;
    text-shadow: 0 0 5px rgba(57, 255, 20, 0.5);
}

/* Terminal Body */
.terminal-body {
    padding: 40px;
    position: relative;
}

/* Scan Line Animation */
.scan-line {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: rgba(212, 175, 55, 0.3);
    box-shadow: 0 0 10px rgba(212, 175, 55, 0.5);
    animation: scan-vertical 3s linear infinite;
    opacity: 0.3;
    pointer-events: none;
}

@keyframes scan-vertical {
    0% {
        top: 0;
    }

    100% {
        top: 100%;
    }
}

/* Form Styles */
.holo-group {
    position: relative;
    margin-bottom: 35px;
}

.holo-group input,
.holo-group textarea {
    width: 100%;
    background: transparent;
    border: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    padding: 10px 0;
    color: white;
    font-family: var(--font-tech);
    font-size: 1.1rem;
    letter-spacing: 1px;
    outline: none;
    transition: 0.3s;
}

.holo-group textarea {
    min-height: 100px;
    resize: vertical;
}

.holo-group label {
    position: absolute;
    top: 10px;
    left: 0;
    color: #888;
    font-family: var(--font-tech);
    font-size: 0.9rem;
    letter-spacing: 1px;
    transition: 0.3s;
    pointer-events: none;
}

/* Focus States */
.holo-group input:focus,
.holo-group input:not(:placeholder-shown),
.holo-group textarea:focus,
.holo-group textarea:not(:placeholder-shown) {
    border-bottom-color: transparent;
}

.holo-group input:focus~label,
.holo-group input:not(:placeholder-shown)~label,
.holo-group textarea:focus~label,
.holo-group textarea:not(:placeholder-shown)~label {
    top: -20px;
    color: var(--gold);
    font-size: 0.8rem;
    font-weight: bold;
}

/* Animated Border Line */
.input-border {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--gold);
    transition: 0.4s ease;
    box-shadow: 0 0 10px var(--gold);
}

.holo-group input:focus~.input-border,
.holo-group textarea:focus~.input-border {
    width: 100%;
}

/* Transmit Button */
.transmit-btn {
    width: 100%;
    padding: 18px;
    background: rgba(212, 175, 55, 0.1);
    border: 1px solid var(--gold);
    color: var(--gold);
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: bold;
    letter-spacing: 3px;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transition: 0.3s;
    clip-path: polygon(10px 0, 100% 0, 100% calc(100% - 10px), calc(100% - 10px) 100%, 0 100%, 0 10px);
}

.transmit-btn:hover {
    background: var(--gold);
    color: black;
    box-shadow: 0 0 30px rgba(212, 175, 55, 0.4);
    letter-spacing: 5px;
}

.transmit-btn i {
    margin-right: 10px;
}

/* Form Footer */
.form-footer {
    display: flex;
    justify-content: space-between;
    margin-top: 25px;
    color: #555;
    font-family: var(--font-tech);
    font-size: 0.8rem;
}

.form-footer span i {
    margin-right: 5px;
    color: var(--gold-dim);
}

/* CONTACT SHARDS (Right Side) */
.contact-shards {
    display: flex;
    flex-direction: column;
    gap: 25px;
    padding-top: 20px;
}

.shard {
    display: flex;
    align-items: center;
    gap: 20px;
    background: rgba(20, 20, 20, 0.6);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 20px 30px;
    width: 320px;
    text-decoration: none;
    transition: 0.4s;
    position: relative;
    transform: translateZ(20px);
}

.shard::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: var(--gold);
    transform: scaleY(0);
    transition: 0.3s;
    transform-origin: bottom;
}

.shard:hover {
    transform: translateZ(50px) translateX(-10px);
    background: rgba(30, 30, 30, 0.9);
    border-color: var(--gold);
    box-shadow: -10px 10px 30px rgba(0, 0, 0, 0.5);
}

.shard:hover::before {
    transform: scaleY(1);
}

.shard-icon {
    font-size: 2rem;
    color: #666;
    transition: 0.3s;
}

.shard:hover .shard-icon {
    color: var(--gold);
    text-shadow: 0 0 10px var(--gold);
}

.shard-text {
    display: flex;
    flex-direction: column;
}

.shard-label {
    font-family: var(--font-tech);
    color: #888;
    font-size: 0.75rem;
    letter-spacing: 2px;
    margin-bottom: 4px;
}

.shard-val {
    font-family: var(--font-tech);
    color: white;
    font-size: 1rem;
    letter-spacing: 1px;
}

/* Responsive */
@media (max-width: 900px) {
    .holo-terminal-container {
        flex-direction: column;
        align-items: center;
        perspective: none;
        gap: 40px;
    }

    .holo-terminal {
        width: 100%;
        transform: none !important;
        /* Flatten on mobile */
        max-width: 500px;
    }

    .terminal-grid-bg {
        display: none;
        /* Heavy performance save on mobile */
    }

    .contact-shards {
        width: 100%;
        align-items: center;
    }

    .shard {
        width: 100%;
        max-width: 500px;
        transform: none !important;
    }
}

/* =========================================
   CRYSTAL GLASS CONTACT SECTION (GOLD GLASS UPDATE)
   ========================================= */

.crystal-contact-container {
    display: flex;
    justify-content: space-between;
    align-items: stretch;
    /* EQUAL HEIGHT */
    gap: 60px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* LEFT SIDE: Intro (Unchanged) */
.contact-intro {
    flex: 1;
    max-width: 500px;
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.ci-head {
    font-family: var(--font-heading);
    font-size: 3.5rem;
    color: white;
    line-height: 1.1;
    margin-bottom: 25px;
}

.ci-head .highlight {
    color: transparent;
    -webkit-text-stroke: 1px var(--gold);
    text-shadow: 0 0 20px rgba(212, 175, 55, 0.3);
}

.ci-sub {
    font-size: 1.1rem;
    color: #bbb;
    line-height: 1.7;
    margin-bottom: 15px;
    /* Reduced from 40px */
    max-width: 90%;
}

.direct-links {
    margin-top: 15px;
    /* Reduced from 30px */
}

.dl-item {
    display: flex;
    align-items: center;
    gap: 15px;
    text-decoration: none;
    color: var(--gold);
    font-size: 1.2rem;
    margin-bottom: 25px;
    transition: 0.3s;
    width: fit-content;
    padding: 10px 20px;
    border: 1px solid rgba(212, 175, 55, 0.2);
    border-radius: 50px;
}

.dl-item:hover {
    background: rgba(212, 175, 55, 0.1);
    box-shadow: 0 0 20px rgba(212, 175, 55, 0.2);
    transform: translateX(10px);
}

.dl-socials {
    display: flex;
    gap: 15px;
}

/* Social Icons with Gold Tech Tooltip */
.social-icon {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.2);
    display: flex;
    justify-content: center;
    align-items: center;
    color: white;
    font-size: 1.2rem;
    text-decoration: none;
    transition: 0.3s;
    position: relative;
    /* For tooltip alignment */
}

/* Tooltip Body */
.social-icon::before {
    content: attr(data-tooltip);
    position: absolute;
    top: 120%;
    /* Moved to below */
    left: 50%;
    transform: translateX(-50%) translateY(-10px);
    background: rgba(0, 0, 0, 0.9);
    color: var(--gold);
    border: 1px solid var(--gold);
    padding: 5px 12px;
    font-size: 0.8rem;
    font-family: var(--font-tech);
    letter-spacing: 1px;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: 0.3s cubic-bezier(0.68, -0.55, 0.27, 1.55);
    border-radius: 4px;
    box-shadow: 0 0 10px rgba(212, 175, 55, 0.3);
    z-index: 10;
}

/* Tooltip Arrow */
.social-icon::after {
    content: '';
    position: absolute;
    top: 110%;
    /* Moved to below */
    left: 50%;
    transform: translateX(-50%) translateY(-10px);
    border: 6px solid transparent;
    border-bottom-color: var(--gold);
    /* Pointing up */
    opacity: 0;
    transition: 0.3s cubic-bezier(0.68, -0.55, 0.27, 1.55);
    pointer-events: none;
}

/* Hover State: Original Brand Colors */
.social-icon:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(255, 255, 255, 0.3);
    color: white;
    /* Ensure icon stays white or appropriate contrast */
    border-color: transparent;
    /* Remove border to let bg shine */
}

/* Specific Colors based on tooltip data-attribute */
.social-icon[data-tooltip="LinkedIn"]:hover {
    background: #0077b5;
    box-shadow: 0 5px 20px rgba(0, 119, 181, 0.4);
}

.social-icon[data-tooltip="GitHub"]:hover {
    background: #333;
    box-shadow: 0 5px 20px rgba(51, 51, 51, 0.4);
}

.social-icon[data-tooltip="Resume"]:hover {
    background: #e1ad01;
    /* Gold for Resume */
    color: black;
    box-shadow: 0 5px 20px rgba(225, 173, 1, 0.4);
}

.social-icon:hover::before {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

.social-icon:hover::after {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* RIGHT SIDE: Golden Glass Form */
.contact-form-wrapper.gold-glass-theme {
    flex: 1;
    /* Equal width to left side */
    position: relative;
    padding: 30px;
    /* Reduced padding */
    background: rgba(255, 215, 0, 0.02);
    border: 1px solid rgba(212, 175, 55, 0.2);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: 4px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    overflow: hidden;
    transition: 0.4s ease;
}

/* Hover Effect: Crystal Resonance (Subtle & Safe for Mobile) */
.contact-form-wrapper.gold-glass-theme:hover {
    background: rgba(255, 215, 0, 0.05);
    border-color: rgba(212, 175, 55, 0.6);
    box-shadow:
        0 10px 40px rgba(0, 0, 0, 0.5),
        inset 0 0 20px rgba(212, 175, 55, 0.1);
    /* Inner glow */
}

/* Sheen Effect */
.contact-form-wrapper.gold-glass-theme::after {
    content: '';
    position: absolute;
    top: 0;
    left: -150%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.05), transparent);
    transform: skewX(-20deg);
    transition: 0.5s;
    pointer-events: none;
}

.contact-form-wrapper.gold-glass-theme:hover::after {
    left: 150%;
    /* Smooth sheen pass */
    transition: 0.7s ease-in-out;
}

/* Golden Corners: Static Pulse (No movement) */
.gold-corner {
    position: absolute;
    width: 15px;
    height: 15px;
    border: 2px solid var(--gold);
    transition: 0.4s ease;
    opacity: 0.7;
    box-shadow: 0 0 5px rgba(0, 0, 0, 0.5);
}

.gold-corner.top-left {
    top: 0;
    left: 0;
    border-right: none;
    border-bottom: none;
}

.gold-corner.top-right {
    top: 0;
    right: 0;
    border-left: none;
    border-bottom: none;
}

.gold-corner.bottom-left {
    bottom: 0;
    left: 0;
    border-right: none;
    border-top: none;
}

.gold-corner.bottom-right {
    bottom: 0;
    right: 0;
    border-left: none;
    border-top: none;
}

.contact-form-wrapper.gold-glass-theme:hover .gold-corner {
    opacity: 1;
    box-shadow: 0 0 15px var(--gold);
    /* Just glow, no movement */
    border-color: #fff;
}

.gold-glass-structure {
    display: flex;
    flex-direction: column;
    gap: 20px;
    position: relative;
    z-index: 2;
}

.gold-header {
    margin-bottom: 20px;
}

.gold-header h3 {
    font-family: var(--font-heading);
    font-size: 2rem;
    color: white;
    letter-spacing: 2px;
    margin-bottom: 10px;
    transition: 0.3s;
}

.contact-form-wrapper.gold-glass-theme:hover .gold-header h3 {
    letter-spacing: 4px;
    /* Expand text */
    text-shadow: 0 0 20px var(--gold);
}

.gold-line {
    width: 50px;
    height: 3px;
    /* Slightly thicker to show sharp taper */
    background: var(--gold);
    transition: width 0.6s cubic-bezier(0.22, 1, 0.36, 1);
    /* Make right side sharp (taper to a point) */
    clip-path: polygon(0 0, 100% 50%, 0 100%);
    filter: drop-shadow(0 0 2px var(--gold));
}

.contact-form-wrapper.gold-glass-theme:hover .gold-line {
    width: 100%;
    filter: drop-shadow(0 0 8px var(--gold));
}

.gold-inputs {
    display: flex;
    gap: 20px;
}

.gold-field {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.gold-field.full {
    width: 100%;
}

.gold-field label {
    font-family: var(--font-tech);
    color: var(--gold);
    font-size: 0.9rem;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.gold-field input,
.gold-field textarea {
    width: 100%;
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    /* Slight radius for touch friendliness */
    padding: 15px;
    color: white;
    font-family: inherit;
    font-size: 1rem;
    transition: 0.3s;
    outline: none;
}

.gold-field textarea {
    min-height: 120px;
    resize: vertical;
}

.gold-field input:focus,
.gold-field textarea:focus {
    border-color: var(--gold);
    box-shadow: 0 0 15px rgba(212, 175, 55, 0.15);
    background: rgba(212, 175, 55, 0.05);
}

/* Hover over field */
.gold-field:hover input,
.gold-field:hover textarea {
    border-color: rgba(212, 175, 55, 0.5);
    background: rgba(255, 255, 255, 0.02);
}

/* Button: Neon Circuit Fill */
.gold-btn-glass {
    width: 100%;
    margin-top: 10px;
    padding: 16px 0;
    justify-content: center;
    background: transparent;
    border: 1px solid var(--gold);
    color: var(--gold);
    font-family: var(--font-heading);
    font-weight: bold;
    font-size: 1.1rem;
    letter-spacing: 2px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 15px;
    text-transform: uppercase;
    position: relative;
    overflow: hidden;
    z-index: 1;
    border-radius: 4px;
}

/* Background Slide Animation */
.gold-btn-glass::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 0%;
    /* Start empty */
    height: 100%;
    background: var(--gold);
    transition: cubic-bezier(0.77, 0, 0.175, 1) 0.5s;
    z-index: -1;
}

/* Icon Slide Animation */
.gold-btn-glass i {
    transition: transform 0.4s ease;
}

.gold-btn-glass:hover {
    color: black;
    /* Contrast text on gold */
    box-shadow: 0 0 25px rgba(212, 175, 55, 0.5);
    /* Glow */
    border-color: var(--gold);
    transform: translateY(-2px);
    /* Slight lift */
}

.gold-btn-glass:hover::before {
    width: 100%;
    /* Fill completely */
}

.gold-btn-glass:hover i {
    transform: translateX(10px) scale(1.2);
    /* Move and grow icon */
}

/* Responsive */
@media (max-width: 900px) {
    .crystal-contact-container {
        flex-direction: column;
        align-items: center;
        gap: 40px;
        padding: 0 20px;
    }

    .contact-intro {
        text-align: center;
        max-width: 100%;
        margin-bottom: 0;
    }

    .dl-item {
        margin: 0 auto 25px auto;
    }

    .dl-socials {
        justify-content: center;
    }

    .contact-form-wrapper.gold-glass-theme {
        width: 100%;
        padding: 30px 25px;
        /* Comfortable padding */
        min-height: auto;
        /* Allow natural height */
    }

    .contact-form-wrapper.gold-glass-theme:hover {
        transform: none;
    }

    .contact-form-wrapper.gold-glass-theme:hover .gold-corner {
        /* Disable flying effect on mobile, just glow */
        transform: none;
        width: 15px;
        height: 15px;
    }

    .gold-glass-structure {
        padding: 0;
    }
}

@media (max-width: 600px) {
    .section-title h2 {
        font-size: 2.5rem;
    }

    .ci-head {
        font-size: 2.2rem;
        margin-bottom: 20px;
    }

    .ci-sub {
        font-size: 1rem;
        margin-bottom: 30px;
    }

    .gold-inputs {
        flex-direction: column;
        gap: 20px;
    }

    .gold-btn-glass {
        width: 100%;
        justify-content: center;
    }

    .dl-item {
        font-size: 1rem;
        padding: 8px 16px;
        width: 100%;
        justify-content: center;
    }

    .social-icon {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }
}

/* =========================================
/* =========================================
   QUANTUM GLASS FOOTER
   ========================================= */

.quantum-footer {
    position: relative;
    padding: 60px 20px 20px;
    background: #030303;
    overflow: hidden;
    font-family: var(--font-heading);
}

.quantum-footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 50% 100%, rgba(212, 175, 55, 0.05), transparent 70%);
    pointer-events: none;
}

.quantum-footer::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, transparent, var(--gold), transparent);
    animation: foot-scan 3s linear infinite;
    box-shadow: 0 0 15px var(--gold);
}

@keyframes foot-scan {
    0% {
        transform: translateX(-100%);
    }

    100% {
        transform: translateX(100%);
    }
}

.q-container {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    max-width: 1200px;
    margin: 0 auto 50px;
    flex-wrap: wrap;
    gap: 40px;
}

.q-block {
    flex: 1;
    min-width: 250px;
}

/* Brand Block */
.q-logo {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 20px;
}

.q-initial {
    font-size: 3rem;
    font-weight: bold;
    color: transparent;
    -webkit-text-stroke: 1px var(--gold);
    text-shadow: 0 0 20px rgba(212, 175, 55, 0.3);
}

.q-name-stack {
    display: flex;
    flex-direction: column;
    line-height: 1;
    font-size: 1.2rem;
    letter-spacing: 2px;
    color: white;
}

.q-tagline {
    font-family: var(--font-tech);
    color: #888;
    font-size: 0.9rem;
    max-width: 280px;
    line-height: 1.6;
}

/* Navigation Matrix */
.q-block.nav {
    display: flex;
    flex-direction: column;
    gap: 15px;
    align-items: flex-start;
    /* Or center depending on pref */
    margin-top: 10px;
}

.q-link {
    text-decoration: none;
    color: #666;
    font-size: 1.1rem;
    letter-spacing: 1px;
    display: flex;
    align-items: center;
    gap: 15px;
    transition: 0.4s cubic-bezier(0.25, 1, 0.5, 1);
    position: relative;
    padding-left: 20px;
}

.q-link span {
    font-size: 0.9rem;
    color: var(--gold);
    opacity: 0.5;
    transition: 0.3s;
    width: 20px;
    display: flex;
    justify-content: center;
}

.q-link::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 6px;
    height: 6px;
    background: var(--gold);
    border-radius: 50%;
    opacity: 0;
    transition: 0.3s;
}

.q-link:hover {
    color: white;
    transform: translateX(10px);
    text-shadow: 0 0 15px rgba(255, 255, 255, 0.3);
}

.q-link:hover::before {
    opacity: 1;
    box-shadow: 0 0 10px var(--gold);
}

.q-link:hover span {
    opacity: 1;
}

/* Social Frequency */
.q-block.social {
    display: flex;
    gap: 15px;
    justify-content: flex-end;
}

.q-social-btn {
    width: 50px;
    height: 50px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    justify-content: center;
    align-items: center;
    color: white;
    font-size: 1.2rem;
    text-decoration: none;
    transition: 0.4s;
    position: relative;
    overflow: hidden;
}

.q-social-btn::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 0%;
    background: var(--gold);
    transition: 0.3s;
    z-index: 0;
}

.q-social-btn i {
    position: relative;
    z-index: 2;
    transition: 0.3s;
}

.q-social-btn:hover {
    border-color: var(--gold);
    box-shadow: 0 0 20px rgba(212, 175, 55, 0.2);
}

.q-social-btn:hover::after {
    height: 100%;
}

.q-social-btn:hover i {
    color: black;
}

/* Bottom Bar */
.q-bottom {
    max-width: 1200px;
    margin: 0 auto;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    padding-top: 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: #555;
    font-family: var(--font-tech);
    font-size: 0.8rem;
    letter-spacing: 2px;
}

.q-line {
    flex: 1;
    height: 1px;
    background: #222;
    margin: 0 30px;
}

/* Responsive */
@media (max-width: 900px) {
    .q-container {
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 50px;
    }

    .q-block.nav {
        align-items: center;
    }

    .q-block.social {
        justify-content: center;
    }

    .q-logo {
        flex-direction: column;
        /* Stack vertically for mobile */
        justify-content: center;
        gap: 10px;
    }

    .q-name-stack {
        flex-direction: row;
        /* One line on mobile */
        gap: 8px;
        /* Space between SURYA and RAJ */
        align-items: center;
        font-size: 1.5rem;
    }

    .q-link {
        padding-left: 0;
        /* Remove dot padding on mobile if centering */
        justify-content: center;
    }

    .q-link::before {
        display: none;
        /* Hide dot on mobile for cleaner center alignment */
    }

    .q-link:hover {
        transform: scale(1.1);
        /* Scale instead of slide on mobile */
    }

    .q-bottom {
        flex-direction: column;
        gap: 20px;
    }

    .q-line {
        display: none;
    }
}

/* Mobile Footer */
@media (max-width: 768px) {
    .footer-grid {
        flex-direction: column;
        gap: 40px;
    }

    .footer-bottom {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
}

/* =========================================
   PLASMA NODE DOCK (Independent Floating)
   ========================================= */

/* =========================================
   HERO SOCIAL DOCK (Absolute within Hero)
   ========================================= */

.hero-social-dock {
    position: absolute;
    /* Changed from fixed */
    top: 50%;
    right: 30px;
    transform: translateY(-50%);
    z-index: 100;
    /* Lower z-index than fixed, but above hero bg */
    pointer-events: none;
}

/* Invisible Container */
.dock-links {
    display: flex;
    flex-direction: column;
    gap: 25px;
    /* Large gap for independence */
    pointer-events: auto;
    /* Re-enable for links */
    background: transparent;
    padding: 0;
    border: none;
    box-shadow: none;
    backdrop-filter: none;
}

/* Remove spine decorations */
.dock-links::before {
    display: none;
}

/* Independent Nodes */
.dock-icon {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background: rgba(10, 10, 10, 0.4);
    /* Minimal background */
    border: 1px solid rgba(212, 175, 55, 0.2);
    /* Faint gold ring */
    display: flex;
    justify-content: center;
    align-items: center;
    color: var(--gold);
    font-size: 1.1rem;
    text-decoration: none;
    transition: 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    position: relative;
    backdrop-filter: blur(4px);
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.2);
    z-index: 2;
}

/* Pulse Animation for "Alive" feel */
.dock-icon::before {
    content: '';
    position: absolute;
    inset: -5px;
    /* Ring outside */
    border-radius: 50%;
    border: 1px solid var(--gold);
    opacity: 0;
    transform: scale(0.8);
    transition: 0.4s;
    background: transparent;
    width: auto;
    height: auto;
    right: auto;
    top: auto;
}

/* Hover Effects */
.dock-icon:hover {
    transform: scale(1.2);
    background: var(--gold);
    color: black;
    box-shadow: 0 0 25px rgba(212, 175, 55, 0.6);
    border-color: transparent;
}

.dock-icon:hover::before {
    transform: scale(1.5);
    opacity: 0;
    /* Ping effect */
    animation: ping-ring 1s infinite;
}

@keyframes ping-ring {
    0% {
        transform: scale(1);
        opacity: 0.8;
        border-width: 2px;
    }

    100% {
        transform: scale(2);
        opacity: 0;
        border-width: 0px;
    }
}

/* Tooltip: Floating Label - Redefining :after */
.dock-icon::after {
    content: attr(data-tooltip);
    position: absolute;
    right: 60px;
    /* Far to left */
    top: 50%;
    transform: translateY(-50%) translateX(20px);
    background: transparent;
    color: var(--gold);
    font-family: var(--font-code);
    font-size: 0.8rem;
    font-weight: bold;
    letter-spacing: 2px;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: 0.3s;
    text-shadow: 0 0 5px black;
    width: auto;
    height: auto;
    border-radius: 0;
    z-index: 5;
    border: none;
}

.dock-icon:hover::after {
    opacity: 1;
    transform: translateY(-50%) translateX(0);
    width: auto;
    right: 60px;
}

/* Mobile Responsive */
/* Mobile Responsive */
@media (max-width: 768px) {
    .hero-social-dock {
        right: 15px;
        top: 35%;
        /* Approximate bottom right of image area */
        bottom: auto;
        transform: translateY(-50%);
    }

    .dock-links {
        gap: 15px;
        /* Tighter gap on mobile */
    }

    .dock-icon {
        width: 35px;
        /* Slightly smaller for mobile */
        height: 35px;
        font-size: 0.9rem;
        background: rgba(0, 0, 0, 0.6);
    }

    /* Hide tooltips on mobile to prevent clutter */
    .dock-icon::after {
        display: none;
    }
}

/* =========================================
   SCROLL TRIGGER ANIMATION UTILITIES
   ========================================= */
.scroll-animate {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.scroll-animate.animate-in {
    opacity: 1;
    transform: translateY(0);
}