/* ========================================
   AIOS-THEMED PORTFOLIO STYLES
   Inspired by biological architecture and
   cyberpunk aesthetics
   ======================================== */

/* CSS Variables */
:root {
    --primary: #667eea;
    --primary-dark: #5a67d8;
    --secondary: #764ba2;
    --accent: #00f5d4;
    --accent-alt: #f72585;
    --bg-dark: #0a0a0f;
    --bg-card: #12121a;
    --bg-card-hover: #1a1a25;
    --text-primary: #ffffff;
    --text-secondary: #b8c5d6;
    --text-muted: #8e9bb0;
    --gradient-primary: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --gradient-accent: linear-gradient(135deg, #00f5d4 0%, #667eea 100%);
    --gradient-bg: linear-gradient(180deg, #0a0a0f 0%, #12121a 50%, #0a0a0f 100%);
    --glow-primary: 0 0 20px rgba(102, 126, 234, 0.4);
    --glow-accent: 0 0 20px rgba(0, 245, 212, 0.4);
    --border-radius: 12px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Reset */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Environmental control — text is an abstract visual object, not selectable */
body {
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg-dark);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Neural Network Canvas */
#neural-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    opacity: 0.25;
}

/* Particles Background */
.particles {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: var(--accent);
    border-radius: 50%;
    animation: float 15s infinite;
    opacity: 0.5;
}

@keyframes float {
    0%, 100% {
        transform: translateY(100vh) rotate(0deg);
        opacity: 0;
    }
    10% {
        opacity: 0.5;
    }
    90% {
        opacity: 0.5;
    }
    100% {
        transform: translateY(-100vh) rotate(720deg);
        opacity: 0;
    }
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
    position: relative;
    z-index: 1;
}

/* ========================================
   NAVBAR
   ======================================== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 16px 0;
    background: rgba(10, 10, 15, 0.8);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(102, 126, 234, 0.1);
    transition: var(--transition);
}

.navbar.scrolled {
    padding: 12px 0;
    background: rgba(10, 10, 15, 0.95);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    font-weight: 700;
    font-size: 1.25rem;
    color: var(--text-primary);
}

/* Logo Symbol with Hover Animation */
.logo-symbol {
    font-size: 2rem;
    display: inline-block;
    color: #667eea;
    transition: all 0.3s ease;
    cursor: pointer;
    text-shadow: 
        0 0 8px rgba(102, 126, 234, 0.6),
        0 0 15px rgba(102, 126, 234, 0.4);
}

.nav-logo:hover .logo-symbol,
.footer-logo:hover .logo-symbol {
    animation: atomSpin 0.8s ease-in-out infinite;
    color: #00f5d4;
    text-shadow: 
        0 0 10px rgba(0, 245, 212, 0.8),
        0 0 20px rgba(0, 245, 212, 0.6),
        0 0 30px rgba(102, 126, 234, 0.5);
}

@keyframes atomSpin {
    0% {
        transform: rotate(0deg) scale(1);
    }
    25% {
        transform: rotate(15deg) scale(1.2);
    }
    50% {
        transform: rotate(0deg) scale(1.1);
    }
    75% {
        transform: rotate(-15deg) scale(1.2);
    }
    100% {
        transform: rotate(0deg) scale(1);
    }
}

.nav-menu {
    display: flex;
    gap: 32px;
}

.nav-link {
    text-decoration: none;
    color: var(--text-secondary);
    font-weight: 500;
    font-size: 0.95rem;
    transition: var(--transition);
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--gradient-primary);
    transition: width 0.3s ease;
}

.nav-link:hover {
    color: var(--text-primary);
}

.nav-link:hover::after {
    width: 100%;
}

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
}

.bar {
    width: 25px;
    height: 2px;
    background: var(--text-primary);
    transition: var(--transition);
}

/* ========================================
   HERO SECTION
   ======================================== */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: 120px 0 80px;
    position: relative;
}

.hero-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 60px;
    align-items: center;
}

.typing-container {
    font-family: 'JetBrains Mono', monospace;
    font-size: 1rem;
    color: var(--accent);
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.code-prefix {
    color: var(--primary);
}

.cursor {
    animation: blink 1s infinite;
}

@keyframes blink {
    0%, 50% { opacity: 1; }
    51%, 100% { opacity: 0; }
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 700;
    line-height: 1.1;
    margin-bottom: 20px;
}

.highlight-gradient {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
}

.role-tag {
    background: rgba(102, 126, 234, 0.15);
    border: 1px solid rgba(102, 126, 234, 0.3);
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--primary);
}

.role-separator {
    color: var(--text-muted);
}

.hero-description {
    font-size: 1.1rem;
    color: var(--text-secondary);
    margin-bottom: 24px;
    line-height: 1.7;
}

.accent-text {
    color: var(--accent);
}

/* Hydrolang Code Block */
.hydrolang-block {
    background: var(--bg-card);
    border: 1px solid rgba(102, 126, 234, 0.2);
    border-radius: var(--border-radius);
    margin-bottom: 32px;
    overflow: hidden;
    box-shadow: var(--glow-primary);
}

.code-header {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 16px;
    background: rgba(102, 126, 234, 0.1);
    border-bottom: 1px solid rgba(102, 126, 234, 0.2);
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

.dot.red { background: #ff5f56; }
.dot.yellow { background: #ffbd2e; }
.dot.green { background: #27c93f; }

.code-title {
    margin-left: auto;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.85rem;
    color: var(--text-muted);
}

.code-content {
    padding: 20px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.85rem;
    line-height: 1.6;
    overflow-x: auto;
}

.code-content .comment { color: #6a9955; }
.code-content .decorator { color: #dcdcaa; }
.code-content .key { color: #9cdcfe; }
.code-content .number { color: #b5cea8; }
.code-content .string { color: #ce9178; }
.code-content .keyword { color: #569cd6; }
.code-content .type { color: #4ec9b0; }
.code-content .symbol { color: #c586c0; }
.code-content .function { color: #dcdcaa; }
.code-content .accent { color: var(--accent); }

/* ========================================
   3D CODE STACK - Living Abstraction Layers
   ======================================== */

.code-stack-container {
    position: relative;
    perspective: 1000px;
    margin-bottom: 32px;
    padding: 20px 0;
}

.code-stack {
    position: relative;
    height: 260px;
    transform-style: preserve-3d;
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Individual Cards */
.stack-card {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    background: var(--bg-card);
    border: 1px solid rgba(102, 126, 234, 0.2);
    border-radius: var(--border-radius);
    overflow: hidden;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    transform-origin: center bottom;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

/* Stacking positions - cards behind */
.stack-card[data-index="0"] { z-index: 5; }
.stack-card[data-index="1"] { z-index: 4; }
.stack-card[data-index="2"] { z-index: 3; }
.stack-card[data-index="3"] { z-index: 2; }
.stack-card[data-index="4"] { z-index: 1; }

/* Default stacked state - all cards visible behind */
.stack-card:not(.active) {
    opacity: 0.6;
    pointer-events: none;
}

/* Dynamic positioning based on distance from active */
.stack-card.behind-1 {
    transform: translateY(15px) translateZ(-30px) scale(0.96);
    opacity: 0.7;
}
.stack-card.behind-2 {
    transform: translateY(30px) translateZ(-60px) scale(0.92);
    opacity: 0.5;
}
.stack-card.behind-3 {
    transform: translateY(45px) translateZ(-90px) scale(0.88);
    opacity: 0.3;
}
.stack-card.behind-4 {
    transform: translateY(60px) translateZ(-120px) scale(0.84);
    opacity: 0.15;
}

/* Active card */
.stack-card.active {
    z-index: 10;
    opacity: 1;
    transform: translateY(0) translateZ(0) scale(1);
    box-shadow: var(--glow-primary), 0 10px 40px rgba(0, 0, 0, 0.4);
    pointer-events: auto;
    animation: cardBreathe 4s ease-in-out infinite;
}

/* Breathing animation - the card is alive */
@keyframes cardBreathe {
    0%, 100% {
        box-shadow: var(--glow-primary), 0 10px 40px rgba(0, 0, 0, 0.4);
    }
    50% {
        box-shadow: 0 0 30px rgba(102, 126, 234, 0.6), 0 15px 50px rgba(0, 0, 0, 0.5);
    }
}

/* Hover on active card - it notices you */
.stack-card.active:hover {
    transform: translateY(-5px) translateZ(10px) scale(1.02);
    box-shadow: 0 0 40px rgba(0, 245, 212, 0.5), 0 20px 60px rgba(0, 0, 0, 0.5);
}

/* Stack Navigation */
.stack-nav {
    position: absolute;
    right: -50px;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.stack-arrow {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(102, 126, 234, 0.2);
    border: 1px solid rgba(102, 126, 234, 0.3);
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.stack-arrow:hover {
    background: rgba(102, 126, 234, 0.4);
    color: var(--text-primary);
    transform: scale(1.1);
    box-shadow: var(--glow-primary);
}

.stack-arrow:active {
    transform: scale(0.95);
}

.stack-arrow:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.stack-arrow:disabled:hover {
    transform: none;
    background: rgba(102, 126, 234, 0.2);
}

/* Dot indicators */
.stack-indicators {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.stack-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(102, 126, 234, 0.3);
    cursor: pointer;
    transition: all 0.3s ease;
}

.stack-dot:hover {
    background: rgba(102, 126, 234, 0.6);
    transform: scale(1.3);
}

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

/* Scroll hint */
.stack-hint {
    position: absolute;
    bottom: -30px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.75rem;
    color: var(--text-muted);
    opacity: 0.6;
    transition: opacity 0.3s ease;
    animation: hintPulse 2s ease-in-out infinite;
}

.stack-hint:hover {
    opacity: 1;
}

@keyframes hintPulse {
    0%, 100% { opacity: 0.4; }
    50% { opacity: 0.8; }
}

/* Card enters from direction */
.stack-card.entering-up {
    animation: slideInFromTop 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.stack-card.entering-down {
    animation: slideInFromBottom 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes slideInFromTop {
    from {
        transform: translateY(-100px) translateZ(50px) scale(0.8);
        opacity: 0;
    }
}

@keyframes slideInFromBottom {
    from {
        transform: translateY(100px) translateZ(50px) scale(0.8);
        opacity: 0;
    }
}

/* Hero Buttons */
.hero-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 28px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.95rem;
    text-decoration: none;
    transition: var(--transition);
    border: none;
    cursor: pointer;
}

.btn-primary {
    background: var(--gradient-primary);
    color: white;
    box-shadow: var(--glow-primary);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(102, 126, 234, 0.4);
}

.btn-secondary {
    background: transparent;
    color: var(--text-primary);
    border: 2px solid rgba(102, 126, 234, 0.5);
}

.btn-secondary:hover {
    border-color: var(--primary);
    background: rgba(102, 126, 234, 0.1);
}

.btn-github {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-primary);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.btn-github:hover {
    background: rgba(255, 255, 255, 0.2);
}

.btn-icon {
    font-size: 1.2rem;
}

.btn-large {
    padding: 18px 36px;
    font-size: 1.1rem;
}

/* 3D Cube */
.hero-visual {
    display: flex;
    justify-content: center;
    align-items: center;
    perspective: 1000px;
}

.cube-container {
    width: 250px;
    height: 250px;
    perspective: 1000px;
}

.cube {
    width: 100%;
    height: 100%;
    position: relative;
    transform-style: preserve-3d;
    animation: rotateCube 20s infinite linear;
}

@keyframes rotateCube {
    0% { transform: rotateX(-20deg) rotateY(0deg); }
    100% { transform: rotateX(-20deg) rotateY(360deg); }
}

.face {
    position: absolute;
    width: 250px;
    height: 250px;
    display: flex;
    justify-content: center;
    align-items: center;
    background: rgba(102, 126, 234, 0.1);
    border: 2px solid rgba(102, 126, 234, 0.3);
    backdrop-filter: blur(10px);
}

.face-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    color: var(--text-primary);
}

.face-content i,
.face-content .cpp-icon,
.face-content .csharp-icon,
.face-content .aios-symbol {
    font-size: 3rem;
}

.face-content span:last-child {
    font-size: 1rem;
    font-weight: 600;
}

.cpp-icon, .csharp-icon {
    font-weight: 700;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.aios-symbol {
    background: var(--gradient-accent);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.front  { transform: translateZ(125px); }
.back   { transform: rotateY(180deg) translateZ(125px); }
.right  { transform: rotateY(90deg) translateZ(125px); }
.left   { transform: rotateY(-90deg) translateZ(125px); }
.top    { transform: rotateX(90deg) translateZ(125px); }
.bottom { transform: rotateX(-90deg) translateZ(125px); }

/* ========================================
   HYPERCUBE INTERIOR
   Triple-click → UI vanishes, you're inside.
   ======================================== */

/* The full-screen 3D canvas */
.hypercube-interior {
    display: none;
    position: fixed;
    inset: 0;
    width: 100vw;
    height: 100vh;
    z-index: 99999;
    cursor: crosshair;
    opacity: 0;
    transition: opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.hypercube-interior.active {
    display: block;
    opacity: 1;
}

/* Everything else vanishes */
body.hypercube-active {
    overflow: hidden;
}

body.hypercube-active > *:not(.hypercube-interior) {
    opacity: 0 !important;
    pointer-events: none !important;
    transition: opacity 0.6s ease;
}

/* Sensing pulse — 2 clicks, the cube notices */
.cube-sensing {
    animation: cubeSensingPulse 0.8s ease-out;
}

@keyframes cubeSensingPulse {
    0% { filter: brightness(1) drop-shadow(0 0 0 transparent); }
    40% { filter: brightness(1.3) drop-shadow(0 0 20px rgba(102, 126, 234, 0.5)); }
    100% { filter: brightness(1) drop-shadow(0 0 0 transparent); }
}

/* Scroll Indicator */
.scroll-indicator {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    color: var(--text-muted);
    font-size: 0.85rem;
    animation: bounce 2s infinite;
}

.mouse {
    width: 26px;
    height: 40px;
    border: 2px solid rgba(102, 126, 234, 0.5);
    border-radius: 13px;
    position: relative;
}

.wheel {
    width: 4px;
    height: 8px;
    background: var(--primary);
    border-radius: 2px;
    position: absolute;
    top: 8px;
    left: 50%;
    transform: translateX(-50%);
    animation: scroll 2s infinite;
}

@keyframes bounce {
    0%, 100% { transform: translateX(-50%) translateY(0); }
    50% { transform: translateX(-50%) translateY(-10px); }
}

@keyframes scroll {
    0% { opacity: 1; transform: translateX(-50%) translateY(0); }
    100% { opacity: 0; transform: translateX(-50%) translateY(15px); }
}

/* ========================================
   SECTIONS
   ======================================== */
section {
    padding: 100px 0;
    position: relative;
}

.section-header {
    text-align: center;
    margin-bottom: 60px;
}

.section-tag {
    display: inline-block;
    background: rgba(102, 126, 234, 0.15);
    border: 1px solid rgba(102, 126, 234, 0.3);
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 16px;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 16px;
}

.section-subtitle {
    font-size: 1.1rem;
    color: var(--text-secondary);
}

.aios-logo {
    font-size: 3rem;
    margin-right: 12px;
    background: var(--gradient-accent);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* ========================================
   AIOS SECTION
   ======================================== */
.aios-section {
    background: linear-gradient(180deg, var(--bg-dark) 0%, rgba(102, 126, 234, 0.05) 50%, var(--bg-dark) 100%);
}

.architecture-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0;
    margin-bottom: 60px;
}

.arch-layer {
    width: 100%;
    max-width: 600px;
    padding: 24px;
    background: var(--bg-card);
    border: 1px solid rgba(102, 126, 234, 0.2);
    border-radius: var(--border-radius);
    transition: var(--transition);
}

.arch-layer:hover {
    border-color: var(--primary);
    box-shadow: var(--glow-primary);
}

.layer-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.layer-icon {
    font-size: 1.5rem;
    color: var(--primary);
}

.csharp-badge, .cpp-badge {
    font-size: 1rem;
    font-weight: 700;
    padding: 4px 8px;
    background: var(--gradient-primary);
    border-radius: 4px;
    color: white;
}

.layer-header h3 {
    font-size: 1.2rem;
    font-weight: 600;
}

.layer-content {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.tech-badge {
    background: rgba(102, 126, 234, 0.15);
    border: 1px solid rgba(102, 126, 234, 0.3);
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-primary);
}

.ai-agents {
    display: flex;
    gap: 12px;
    width: 100%;
}

.agent-card {
    flex: 1;
    background: rgba(0, 245, 212, 0.1);
    border: 1px solid rgba(0, 245, 212, 0.3);
    padding: 12px;
    border-radius: 8px;
    text-align: center;
}

.agent-name {
    display: block;
    font-weight: 600;
    color: var(--accent);
    margin-bottom: 4px;
}

.agent-type {
    font-size: 0.8rem;
    color: var(--text-muted);
}

.arch-connector {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 0;
}

.connector-line {
    flex: 1;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--primary), transparent);
}

.connector-label {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.85rem;
    color: var(--text-muted);
    white-space: nowrap;
}

.security-supercell {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(247, 37, 133, 0.15);
    border: 1px solid rgba(247, 37, 133, 0.3);
    padding: 12px 20px;
    border-radius: 25px;
    color: var(--accent-alt);
    font-weight: 600;
}

.security-supercell i {
    font-size: 1.2rem;
}

.security-badge {
    background: var(--accent-alt);
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.8rem;
}

.security-line {
    background: linear-gradient(90deg, transparent, var(--accent-alt), transparent);
}

/* Features Grid */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 24px;
    margin-bottom: 48px;
}

.feature-card {
    background: var(--bg-card);
    border: 1px solid rgba(102, 126, 234, 0.2);
    border-radius: var(--border-radius);
    padding: 32px 24px;
    text-align: center;
    transition: var(--transition);
}

.feature-card:hover {
    transform: translateY(-5px);
    border-color: var(--primary);
    box-shadow: var(--glow-primary);
}

.feature-icon {
    width: 60px;
    height: 60px;
    background: var(--gradient-primary);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
}

.feature-icon i {
    font-size: 1.5rem;
    color: white;
}

.feature-card h4 {
    font-size: 1.1rem;
    margin-bottom: 12px;
}

.feature-card p {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.cta-container {
    text-align: center;
}

/* ========================================
   SKILLS SECTION
   ======================================== */
.skills {
    background: var(--bg-dark);
}

.skills-visualization {
    max-width: 800px;
    margin: 0 auto;
}

.skills-list {
    display: grid;
    gap: 32px;
}

.skill-category {
    background: var(--bg-card);
    border: 1px solid rgba(102, 126, 234, 0.2);
    border-radius: var(--border-radius);
    padding: 24px;
    transition: var(--transition);
}

.skill-category:hover {
    border-color: var(--primary);
}

.skill-category h3 {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
    font-size: 1.1rem;
}

.skill-category i {
    color: var(--primary);
}

.skill-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.skill-tag {
    background: var(--gradient-primary);
    color: white;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 500;
    transition: var(--transition);
}

.skill-tag:hover {
    transform: scale(1.05);
    box-shadow: var(--glow-primary);
}

/* ========================================
   PROJECTS SECTION
   ======================================== */
.projects {
    background: linear-gradient(180deg, var(--bg-dark) 0%, rgba(102, 126, 234, 0.03) 100%);
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 24px;
}

.project-card {
    background: var(--bg-card);
    border: 1px solid rgba(102, 126, 234, 0.2);
    border-radius: var(--border-radius);
    padding: 28px;
    position: relative;
    transition: var(--transition);
}

.project-card:hover {
    transform: translateY(-5px);
    border-color: var(--primary);
    box-shadow: var(--glow-primary);
}

.project-card.featured {
    border-color: var(--accent);
    box-shadow: var(--glow-accent);
}

.project-badge {
    position: absolute;
    top: -10px;
    right: 20px;
    background: var(--gradient-accent);
    color: var(--bg-dark);
    padding: 6px 14px;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 700;
}

.project-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.project-icon {
    font-size: 2rem;
}

.project-header h3 {
    font-size: 1.3rem;
}

.project-card p {
    color: var(--text-secondary);
    margin-bottom: 16px;
    line-height: 1.6;
}

.project-tech {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px;
}

.project-tech span {
    background: rgba(102, 126, 234, 0.15);
    border: 1px solid rgba(102, 126, 234, 0.3);
    padding: 4px 12px;
    border-radius: 4px;
    font-size: 0.8rem;
    color: var(--text-primary);
}

.project-stats {
    display: flex;
    justify-content: space-around;
    padding: 16px 0;
    border-top: 1px solid rgba(102, 126, 234, 0.2);
    border-bottom: 1px solid rgba(102, 126, 234, 0.2);
    margin-bottom: 20px;
}

.project-stats .stat {
    text-align: center;
}

.stat-value {
    display: block;
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--accent);
}

.stat-label {
    font-size: 0.8rem;
    color: var(--text-muted);
}

.project-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition);
}

.project-link:hover {
    color: var(--accent);
}

/* ========================================
   CONTACT SECTION
   ======================================== */
.contact {
    background: var(--bg-dark);
}

.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
    max-width: 900px;
    margin: 0 auto;
}

.contact-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 40px 24px;
    background: var(--bg-card);
    border: 1px solid rgba(102, 126, 234, 0.2);
    border-radius: var(--border-radius);
    text-decoration: none;
    transition: var(--transition);
}

.contact-card:hover {
    transform: translateY(-5px);
    border-color: var(--primary);
    box-shadow: var(--glow-primary);
}

.contact-card i {
    font-size: 2.5rem;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 16px;
}

.contact-card h4 {
    font-size: 1.1rem;
    margin-bottom: 8px;
    color: var(--text-primary);
}

.contact-card p {
    color: var(--text-secondary);
}

/* ========================================
   FOOTER
   ======================================== */
.footer {
    background: var(--bg-card);
    border-top: 1px solid rgba(102, 126, 234, 0.1);
    padding: 40px 0;
}

.footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    text-align: center;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 1.3rem;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    color: var(--text-primary);
}

.footer-logo:hover {
    color: var(--accent);
    text-decoration: none;
}

.footer p {
    color: var(--text-muted);
}

.social-links {
    display: flex;
    gap: 20px;
}

.social-links a {
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(102, 126, 234, 0.1);
    border: 1px solid rgba(102, 126, 234, 0.2);
    border-radius: 50%;
    color: var(--text-primary);
    text-decoration: none;
    transition: var(--transition);
}

.social-links a:hover {
    background: var(--gradient-primary);
    border-color: transparent;
    transform: translateY(-3px);
}

/* Tecnocrat Surface Sync Indicator */
.surface-sync {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 16px;
    padding: 6px 12px;
    background: rgba(102, 126, 234, 0.1);
    border: 1px solid rgba(102, 126, 234, 0.2);
    border-radius: 20px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.75rem;
    color: var(--text-muted);
    opacity: 0.7;
    transition: var(--transition);
}

.surface-sync:hover {
    opacity: 1;
    border-color: var(--accent);
}

.surface-sync.connected {
    border-color: rgba(0, 245, 212, 0.3);
}

.surface-sync.error {
    border-color: rgba(247, 37, 133, 0.3);
}

.sync-dot {
    width: 6px;
    height: 6px;
    background: var(--text-muted);
    border-radius: 50%;
    animation: pulse-connecting 1s infinite;
}

.surface-sync.connected .sync-dot {
    background: var(--accent);
    animation: pulse-sync 2s infinite;
}

.surface-sync.error .sync-dot {
    background: var(--accent-alt);
    animation: none;
}

@keyframes pulse-connecting {
    0%, 100% { opacity: 0.3; }
    50% { opacity: 1; }
}

@keyframes pulse-sync {
    0%, 100% { opacity: 1; box-shadow: 0 0 0 0 rgba(0, 245, 212, 0.4); }
    50% { opacity: 0.6; box-shadow: 0 0 0 4px rgba(0, 245, 212, 0); }
}

.sync-text {
    letter-spacing: 0.5px;
}

/* ========================================
   EXPANDABLE ARCHITECTURE LAYERS
   Click-to-reveal depth
   ======================================== */
.arch-layer.expandable {
    cursor: pointer;
    position: relative;
}

.arch-layer.expandable:hover {
    border-color: var(--accent);
    box-shadow: var(--glow-accent);
}

.expand-hint {
    margin-left: auto;
    color: var(--text-muted);
    transition: var(--transition);
    font-size: 0.8rem;
}

.arch-layer.expanded .expand-hint {
    transform: rotate(180deg);
    color: var(--accent);
}

.layer-detail {
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1), 
                opacity 0.3s ease,
                margin-top 0.3s ease;
    margin-top: 0;
}

.arch-layer.expanded .layer-detail,
.security-supercell.expanded .layer-detail {
    max-height: 300px;
    opacity: 1;
    margin-top: 16px;
}

.layer-detail p {
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 12px;
}

.detail-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.detail-tags span {
    background: rgba(0, 245, 212, 0.1);
    border: 1px solid rgba(0, 245, 212, 0.25);
    padding: 4px 12px;
    border-radius: 4px;
    font-size: 0.8rem;
    color: var(--accent);
    font-weight: 500;
}

.security-supercell.expandable {
    cursor: pointer;
    flex-direction: column;
    align-items: center;
}

.security-supercell.expandable:hover {
    background: rgba(247, 37, 133, 0.25);
}

.security-detail {
    width: 100%;
    text-align: center;
}

.security-detail p {
    font-size: 0.85rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

/* Layer header flex fix for expand hint */
.arch-layer.expandable .layer-header {
    display: flex;
    align-items: center;
    gap: 12px;
}

/* ========================================
   ORGANISM AWARENESS
   The site breathes. It notices. It lives.
   ======================================== */

/* Architecture layer breathing — subtle border glow pulse */
@keyframes organism-breathe {
    0%, 100% {
        box-shadow: 0 0 5px rgba(102, 126, 234, 0.08);
        border-color: rgba(102, 126, 234, 0.2);
    }
    50% {
        box-shadow: 0 0 18px rgba(102, 126, 234, 0.22);
        border-color: rgba(102, 126, 234, 0.38);
    }
}

/* Security supercell heartbeat — double-pulse like a biological heart */
@keyframes organism-heartbeat {
    0%, 100% {
        box-shadow: 0 0 5px rgba(247, 37, 133, 0.12);
        border-color: rgba(247, 37, 133, 0.3);
    }
    22% {
        box-shadow: 0 0 22px rgba(247, 37, 133, 0.35);
        border-color: rgba(247, 37, 133, 0.55);
    }
    34% {
        box-shadow: 0 0 8px rgba(247, 37, 133, 0.18);
        border-color: rgba(247, 37, 133, 0.35);
    }
    46% {
        box-shadow: 0 0 16px rgba(247, 37, 133, 0.28);
        border-color: rgba(247, 37, 133, 0.48);
    }
}

/* Tech badge subtle glow wave */
@keyframes organism-tag-pulse {
    0%, 100% {
        border-color: rgba(102, 126, 234, 0.3);
        box-shadow: none;
    }
    50% {
        border-color: rgba(102, 126, 234, 0.5);
        box-shadow: 0 0 8px rgba(102, 126, 234, 0.15);
    }
}

/* Sync dot steady pulse */
@keyframes organism-sync-pulse {
    0%, 100% {
        box-shadow: 0 0 4px currentColor;
        transform: scale(1);
    }
    50% {
        box-shadow: 0 0 10px currentColor;
        transform: scale(1.3);
    }
}

/* Apply breathing to architecture layers */
.organism-breathing {
    animation: organism-breathe 4.5s ease-in-out infinite;
}

/* Security supercell overrides with heartbeat */
.security-supercell.organism-breathing {
    animation: organism-heartbeat 3.2s ease-in-out infinite;
}

/* Tech badges wave animation */
.organism-tag-breathing {
    animation: organism-tag-pulse 5s ease-in-out infinite;
}

/* Sync dot pulse */
.organism-pulse {
    animation: organism-sync-pulse 2.5s ease-in-out infinite;
}

/* Feature and project cards — organism-aware transforms */
.feature-card,
.project-card {
    transform-style: preserve-3d;
    transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                box-shadow 0.3s ease,
                border-color 0.3s ease,
                background 0.4s ease;
}

/* Contact cards awareness */
.contact-card {
    transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                box-shadow 0.3s ease,
                border-color 0.3s ease;
}

/* Particle awareness — smooth transitions for glow/size */
.particle {
    transition: opacity 0.4s ease,
                box-shadow 0.4s ease,
                width 0.3s ease,
                height 0.3s ease;
}

/* ========================================
   ORGANISM SLEEP STATE
   The site rests when unobserved
   ======================================== */
.organism-sleeping #neural-canvas {
    opacity: 0.08 !important;
    transition: opacity 3s ease;
}

.organism-sleeping .particles {
    opacity: 0.15;
    transition: opacity 3s ease;
}

.organism-sleeping .organism-breathing {
    animation-duration: 9s;
}

.organism-sleeping .security-supercell.organism-breathing {
    animation-duration: 7s;
}

.organism-sleeping .organism-tag-breathing {
    animation-duration: 10s;
}

.organism-sleeping .feature-card,
.organism-sleeping .project-card,
.organism-sleeping .arch-layer,
.organism-sleeping .security-supercell {
    border-color: rgba(102, 126, 234, 0.1);
}

/* ========================================
   ORGANISM WAKE STATE
   The site stirs when the observer returns
   ======================================== */
.organism-waking #neural-canvas {
    opacity: 0.5 !important;
    transition: opacity 0.3s ease;
}

.organism-waking .particles {
    opacity: 1;
    transition: opacity 0.3s ease;
}

.organism-waking .organism-breathing {
    animation-duration: 2s;
}

.organism-waking .feature-card,
.organism-waking .project-card {
    border-color: rgba(102, 126, 234, 0.5);
    transition: border-color 0.3s ease;
}

/* ========================================
   RESPONSIVE DESIGN
   ======================================== */
@media (max-width: 992px) {
    .hero-container {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero-visual {
        display: none;
    }

    .hero-subtitle {
        justify-content: center;
    }

    .hero-buttons {
        justify-content: center;
    }

    .hydrolang-block {
        text-align: left;
    }
}

@media (max-width: 768px) {
    .nav-menu {
        position: fixed;
        top: 70px;
        left: 0;
        right: 0;
        background: rgba(10, 10, 15, 0.98);
        backdrop-filter: blur(20px);
        flex-direction: column;
        padding: 24px;
        gap: 20px;
        transform: translateX(100%);
        transition: transform 0.3s ease;
    }

    .nav-menu.active {
        transform: translateX(0);
    }

    .nav-toggle {
        display: flex;
    }

    .nav-toggle.active .bar:nth-child(1) {
        transform: rotate(45deg) translate(5px, 5px);
    }

    .nav-toggle.active .bar:nth-child(2) {
        opacity: 0;
    }

    .nav-toggle.active .bar:nth-child(3) {
        transform: rotate(-45deg) translate(5px, -5px);
    }

    .hero-title {
        font-size: 2.5rem;
    }

    .section-title {
        font-size: 2rem;
    }

    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }

    .btn {
        width: 100%;
        max-width: 280px;
        justify-content: center;
    }

    .ai-agents {
        flex-direction: column;
    }

    .scroll-indicator {
        display: none;
    }

    /* Code Stack mobile adjustments */
    .code-stack-container {
        margin: 0 -10px;
    }

    .stack-nav {
        right: 5px;
    }

    .stack-arrow {
        width: 32px;
        height: 32px;
    }

    .stack-hint {
        font-size: 0.7rem;
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 2rem;
    }

    .role-tag {
        font-size: 0.8rem;
        padding: 4px 10px;
    }

    .code-content {
        font-size: 0.75rem;
    }

    .features-grid {
        grid-template-columns: 1fr;
    }

    .projects-grid {
        grid-template-columns: 1fr;
    }

    .contact-grid {
        grid-template-columns: 1fr;
    }

    /* Code Stack small screens */
    .code-stack {
        height: 240px;
    }

    .stack-nav {
        position: relative;
        right: auto;
        top: auto;
        transform: none;
        flex-direction: row;
        justify-content: center;
        margin-top: 20px;
    }

    .stack-indicators {
        flex-direction: row;
    }

    .stack-hint {
        display: none;
    }
}

/* ═══════════════════════════════════════════════════════════
   GENOME ORGANISM DEEP LAYER
   Autonomous geometric organism interaction with UI elements
   ═══════════════════════════════════════════════════════════ */

/* ── Genome Canvas integration with organism sleep/wake ── */
#genome-canvas { transition: opacity 2s ease; }
.organism-sleeping #genome-canvas { opacity: 0.12 !important; }
.organism-waking  #genome-canvas { opacity: 1 !important; }

/* ── Button Deep Layer ── */
.genome-deep-button {
    position: relative;
    overflow: hidden;
}
.genome-deep-button::after {
    content: '';
    position: absolute;
    inset: -2px;
    border: 1px solid transparent;
    border-radius: inherit;
    opacity: 0;
    transition: opacity 0.4s, border-color 0.4s, box-shadow 0.4s;
    animation: genome-border-breathe 4.5s ease-in-out infinite;
    pointer-events: none;
}
.genome-deep-button.genome-proximity::after {
    opacity: var(--genome-intensity, 0);
    border-color: var(--genome-color, #667eea);
    box-shadow: 0 0 calc(10px * var(--genome-intensity, 0)) var(--genome-color, #667eea);
}
.genome-deep-button:hover::after { animation-duration: 1.5s; }

.genome-burst-particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: var(--genome-color, #00f5d4);
    border-radius: 50%;
    pointer-events: none;
    animation: genome-burst 0.6s ease-out forwards;
}

@keyframes genome-burst {
    0%   { transform: translate(0, 0) scale(1); opacity: 1; }
    100% { transform: translate(var(--bx), var(--by)) scale(0); opacity: 0; }
}
@keyframes genome-border-breathe {
    0%, 100% { border-color: transparent; }
    50%      { border-color: rgba(102, 126, 234, 0.25); }
}

/* ── Card Deep Layer — Corner Marks ── */
.genome-corner-marks {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 2;
}
.gcm {
    position: absolute;
    width: 12px;
    height: 12px;
    opacity: 0.15;
    transition: opacity 0.5s, width 0.5s, height 0.5s, border-color 0.5s;
}
.gcm.tl { top: 6px; left: 6px; border-top: 1px solid var(--genome-color, #667eea); border-left: 1px solid var(--genome-color, #667eea); }
.gcm.tr { top: 6px; right: 6px; border-top: 1px solid var(--genome-color, #667eea); border-right: 1px solid var(--genome-color, #667eea); }
.gcm.bl { bottom: 6px; left: 6px; border-bottom: 1px solid var(--genome-color, #667eea); border-left: 1px solid var(--genome-color, #667eea); }
.gcm.br { bottom: 6px; right: 6px; border-bottom: 1px solid var(--genome-color, #667eea); border-right: 1px solid var(--genome-color, #667eea); }

.genome-deep-card.genome-proximity .gcm {
    opacity: var(--genome-intensity, 0);
    width: calc(12px + 10px * var(--genome-intensity, 0));
    height: calc(12px + 10px * var(--genome-intensity, 0));
}
.genome-deep-card.genome-proximity {
    box-shadow: 0 0 calc(18px * var(--genome-intensity, 0)) calc(2px * var(--genome-intensity, 0)) rgba(102, 126, 234, 0.12);
}

/* ── Badge / Tag Resonance ── */
.genome-deep-badge.genome-proximity {
    animation: genome-badge-resonate 0.8s ease-in-out;
    box-shadow: 0 0 calc(6px * var(--genome-intensity, 0)) rgba(102, 126, 234, 0.25);
}
@keyframes genome-badge-resonate {
    0%, 100% { transform: scale(1); }
    50%      { transform: scale(1.08); }
}

/* ── Nav Link Deep Layer ── */
.genome-deep-nav.genome-proximity::after {
    background: var(--genome-color, #667eea) !important;
    box-shadow: 0 0 8px var(--genome-color, #667eea);
    opacity: var(--genome-intensity, 0) !important;
    width: 100% !important;
}

/* ── Section Title Glow ── */
.genome-deep-title.genome-proximity {
    text-shadow: 0 0 calc(12px * var(--genome-intensity, 0)) rgba(102, 126, 234, 0.4);
    transition: text-shadow 0.4s;
}

/* ── Social Link Glow ── */
.genome-deep-social.genome-proximity {
    box-shadow: 0 0 calc(10px * var(--genome-intensity, 0)) rgba(102, 126, 234, 0.2);
    transition: box-shadow 0.3s;
}

/* ── Icon Surprise Effects ── */
.genome-surprise-spin   { animation: genome-spin   0.8s cubic-bezier(0.4,0,0.2,1) !important; }
.genome-surprise-bounce { animation: genome-bounce  0.8s cubic-bezier(0.4,0,0.2,1) !important; }
.genome-surprise-glow   { animation: genome-glow    1.2s ease-in-out !important; }
.genome-surprise-float  { animation: genome-float   1.2s cubic-bezier(0.4,0,0.2,1) !important; }
.genome-surprise-split  { animation: genome-split   0.8s ease-in-out !important; }

@keyframes genome-spin {
    0%   { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}
@keyframes genome-bounce {
    0%, 100% { transform: translateY(0); }
    30%      { transform: translateY(-12px); }
    50%      { transform: translateY(-6px); }
    70%      { transform: translateY(-10px); }
}
@keyframes genome-glow {
    0%, 100% { filter: brightness(1) drop-shadow(0 0 0 transparent); }
    50%      { filter: brightness(1.8) drop-shadow(0 0 10px #00f5d4); }
}
@keyframes genome-float {
    0%, 100% { transform: translateY(0) scale(1); }
    50%      { transform: translateY(-16px) scale(1.15); }
}
@keyframes genome-split {
    0%, 100% { transform: scale(1); filter: blur(0); }
    25%      { transform: scale(1.3); filter: blur(1px); }
    50%      { transform: scale(0.8); filter: blur(2px); }
    75%      { transform: scale(1.1); filter: blur(0.5px); }
}

/* ── Generic Proximity Transition ── */
.genome-proximity {
    transition: box-shadow 0.4s, text-shadow 0.4s, transform 0.3s;
}

/* ═══════════════════════════════════════════════════════════
   ATOM CONSCIOUSNESS — ⚛ Logo Deep Layer
   Dormant → stirring → guide → assistant
   ═══════════════════════════════════════════════════════════ */

/* ── Atom awareness states ── */
.atom-aware { filter: brightness(1.3); }
.atom-stirring {
    animation: atom-stir 2s ease-in-out infinite !important;
}
@keyframes atom-stir {
    0%, 100% { transform: scale(1); filter: brightness(1); }
    30%     { transform: scale(1.15); filter: brightness(1.5) drop-shadow(0 0 8px #667eea); }
    70%     { transform: scale(1.05); filter: brightness(1.2); }
}

.atom-pulse-deep {
    animation: atom-deep-pulse 1.5s ease-in-out infinite !important;
}
@keyframes atom-deep-pulse {
    0%, 100% { transform: scale(1); text-shadow: 0 0 8px rgba(102,126,234,0.6); }
    50%      { transform: scale(1.3); text-shadow: 0 0 20px #00f5d4, 0 0 40px #667eea, 0 0 60px #764ba2; }
}

.atom-guide-active,
.atom-assistant-active {
    color: #00f5d4 !important;
    text-shadow: 0 0 12px rgba(0,245,212,0.8), 0 0 24px rgba(0,245,212,0.4) !important;
    animation: atom-active-breathe 3s ease-in-out infinite !important;
}
@keyframes atom-active-breathe {
    0%, 100% { transform: scale(1) rotate(0deg); }
    50%      { transform: scale(1.1) rotate(10deg); }
}

/* ── Atom Ripple ── */
.atom-ripple {
    position: absolute;
    top: 50%; left: 50%;
    width: 10px; height: 10px;
    margin: -5px 0 0 -5px;
    border-radius: 50%;
    background: rgba(0, 245, 212, 0.4);
    pointer-events: none;
    animation: atom-ripple-expand 0.7s ease-out forwards;
}
@keyframes atom-ripple-expand {
    0%   { transform: scale(0); opacity: 1; }
    100% { transform: scale(8); opacity: 0; }
}

/* ── Atom Whisper ── */
.atom-whisper {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    white-space: nowrap;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.65rem;
    color: rgba(102, 126, 234, 0.7);
    opacity: 0;
    transition: opacity 0.5s ease;
    pointer-events: none;
    margin-top: 4px;
    letter-spacing: 0.5px;
}
.atom-whisper.visible {
    opacity: 1;
    animation: atom-whisper-fade 4s ease-in-out;
}
@keyframes atom-whisper-fade {
    0%   { opacity: 0; transform: translateX(-50%) translateY(4px); }
    15%  { opacity: 1; transform: translateX(-50%) translateY(0); }
    85%  { opacity: 1; }
    100% { opacity: 0.5; }
}

/* ── Guide Panel ── */
.atom-guide-panel {
    position: fixed;
    top: 70px;
    left: 20px;
    width: 260px;
    background: rgba(12, 12, 20, 0.95);
    border: 1px solid rgba(102, 126, 234, 0.25);
    border-radius: 16px;
    backdrop-filter: blur(24px);
    z-index: 10000;
    overflow: hidden;
    opacity: 0;
    transform: translateY(-12px) scale(0.95);
    transition: opacity 0.3s ease, transform 0.3s ease;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.6), 0 0 1px rgba(102, 126, 234, 0.3);
}
.atom-guide-panel.open {
    opacity: 1;
    transform: translateY(0) scale(1);
}
.atom-guide-header {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 14px 16px;
    border-bottom: 1px solid rgba(102, 126, 234, 0.15);
}
.atom-guide-icon {
    font-size: 1.3rem;
    color: #00f5d4;
    text-shadow: 0 0 10px rgba(0, 245, 212, 0.5);
}
.atom-guide-title {
    flex: 1;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.8rem;
    font-weight: 600;
    color: #fff;
    letter-spacing: 0.5px;
}
.atom-guide-close {
    cursor: pointer;
    color: rgba(255,255,255,0.4);
    font-size: 1.2rem;
    line-height: 1;
    transition: color 0.2s;
}
.atom-guide-close:hover { color: #f72585; }

.atom-guide-body {
    padding: 8px;
}
.atom-guide-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-radius: 10px;
    text-decoration: none;
    color: #fff;
    transition: background 0.2s, box-shadow 0.2s;
    cursor: pointer;
}
.atom-guide-item:hover {
    background: rgba(102, 126, 234, 0.12);
    box-shadow: 0 0 12px rgba(102, 126, 234, 0.1);
}
.agi-icon { font-size: 1.1rem; }
.agi-label {
    flex: 1;
    font-size: 0.82rem;
    font-weight: 500;
}
.agi-hint {
    font-size: 0.65rem;
    color: rgba(102, 126, 234, 0.6);
    font-family: 'JetBrains Mono', monospace;
}
.atom-guide-footer {
    padding: 10px 16px;
    border-top: 1px solid rgba(102, 126, 234, 0.1);
    text-align: center;
}
.atom-guide-hint {
    font-size: 0.6rem;
    color: rgba(102, 126, 234, 0.5);
    font-family: 'JetBrains Mono', monospace;
    letter-spacing: 0.5px;
}

/* ── Assistant Panel ── */
.atom-assistant-panel {
    position: fixed;
    top: 70px;
    left: 20px;
    width: 320px;
    max-height: 80vh;
    background: rgba(10, 10, 18, 0.96);
    border: 1px solid rgba(0, 245, 212, 0.2);
    border-radius: 18px;
    backdrop-filter: blur(24px);
    z-index: 10000;
    overflow: hidden;
    overflow-y: auto;
    opacity: 0;
    transform: translateY(-16px) scale(0.93);
    transition: opacity 0.35s ease, transform 0.35s ease;
    box-shadow:
        0 12px 48px rgba(0, 0, 0, 0.7),
        0 0 1px rgba(0, 245, 212, 0.3),
        inset 0 1px 0 rgba(0, 245, 212, 0.08);
}
.atom-assistant-panel.open {
    opacity: 1;
    transform: translateY(0) scale(1);
}

.atom-asst-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 18px;
    border-bottom: 1px solid rgba(0, 245, 212, 0.12);
    background: rgba(0, 245, 212, 0.03);
}
.atom-asst-identity {
    display: flex;
    align-items: center;
    gap: 10px;
}
.atom-asst-symbol {
    font-size: 1.6rem;
    color: #00f5d4;
    text-shadow: 0 0 14px rgba(0, 245, 212, 0.6);
    animation: atom-active-breathe 3s ease-in-out infinite;
}
.atom-asst-name {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.85rem;
    font-weight: 600;
    color: #fff;
    letter-spacing: 0.3px;
}
.atom-asst-status {
    font-size: 0.6rem;
    color: #00f5d4;
    font-family: 'JetBrains Mono', monospace;
    letter-spacing: 1px;
    text-transform: uppercase;
}
.atom-asst-close {
    cursor: pointer;
    color: rgba(255,255,255,0.4);
    font-size: 1.3rem;
    line-height: 1;
    transition: color 0.2s;
}
.atom-asst-close:hover { color: #f72585; }

.atom-asst-body {
    padding: 16px 18px;
}
.atom-asst-msg {
    font-size: 0.78rem;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.85);
    margin-bottom: 14px;
    padding: 10px 12px;
    background: rgba(102, 126, 234, 0.06);
    border-left: 2px solid rgba(0, 245, 212, 0.3);
    border-radius: 0 8px 8px 0;
}
.atom-asst-msg.whisper {
    font-style: italic;
    color: rgba(102, 126, 234, 0.6);
    border-left-color: rgba(102, 126, 234, 0.2);
    background: rgba(102, 126, 234, 0.03);
    margin-top: 14px;
}
.atom-asst-section {
    margin-bottom: 12px;
}
.atom-asst-label {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.6rem;
    color: rgba(0, 245, 212, 0.6);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    margin-bottom: 4px;
}
.atom-asst-value {
    font-size: 0.78rem;
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.5;
}
.atom-asst-divider {
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(0, 245, 212, 0.15), transparent);
    margin: 14px 0;
}
.atom-asst-footer {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 10px 18px;
    border-top: 1px solid rgba(0, 245, 212, 0.08);
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.55rem;
    color: rgba(102, 126, 234, 0.4);
    letter-spacing: 0.5px;
}
.atom-asst-genome-indicator {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #00f5d4;
    animation: pulse-sync 2s ease-in-out infinite;
}

/* ═══════════════════════════════════════════════════════════
   AGENT INFO CARDS — Triple-click contextual reveal system
   ⚛ agent delivers info cards for registered UI elements
   ═══════════════════════════════════════════════════════════ */

/* ── Registered element hint ── */
.agent-info-target {
    cursor: pointer;
}

/* ── Active source highlight ── */
.agent-info-active {
    outline: 1px solid var(--agent-accent, rgba(102, 126, 234, 0.4));
    outline-offset: 4px;
    border-radius: 6px;
    transition: outline 0.3s;
}

/* ── Atom sensing pulse (2 clicks detected) ── */
.agent-sensing {
    animation: agent-sense-pulse 0.8s ease-out;
}
@keyframes agent-sense-pulse {
    0%   { filter: brightness(1); }
    30%  { filter: brightness(1.8) drop-shadow(0 0 8px rgba(102, 126, 234, 0.5)); }
    100% { filter: brightness(1); }
}

/* ── Atom delivering flash (card opened) ── */
.agent-delivering {
    animation: agent-deliver 1.2s ease-out;
}
@keyframes agent-deliver {
    0%   { transform: scale(1); filter: brightness(1); }
    15%  { transform: scale(1.4); filter: brightness(2) drop-shadow(0 0 14px #667eea); }
    40%  { transform: scale(0.9); filter: brightness(1.2); }
    100% { transform: scale(1); filter: brightness(1); }
}

/* ── Info Card ── */
.agent-info-card {
    position: fixed;
    width: 340px;
    background: rgba(10, 10, 30, 0.94);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(102, 126, 234, 0.15);
    border-radius: 12px;
    z-index: 10002;
    font-family: 'Inter', sans-serif;
    box-shadow:
        0 8px 32px rgba(0, 0, 0, 0.5),
        0 0 0 1px rgba(102, 126, 234, 0.06),
        inset 0 1px 0 rgba(255, 255, 255, 0.04);
    opacity: 0;
    transform: translateY(10px) scale(0.96);
    transition: opacity 0.3s, transform 0.3s;
    pointer-events: auto;
    overflow: hidden;
}
.agent-info-card.open {
    opacity: 1;
    transform: translateY(0) scale(1);
}

/* ── Card connector dot (visual link to source) ── */
.agent-card-connector {
    position: absolute;
    top: -6px;
    left: 50%;
    transform: translateX(-50%);
    width: 12px;
    height: 12px;
    background: var(--agent-accent, #667eea);
    border-radius: 50%;
    box-shadow: 0 0 10px var(--agent-accent, #667eea);
    opacity: 0.7;
}

/* ── Card header ── */
.agent-card-header {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 16px 10px;
    border-bottom: 1px solid rgba(102, 126, 234, 0.1);
}
.agent-card-icon {
    font-size: 1.2rem;
}
.agent-card-title {
    flex: 1;
    font-size: 0.85rem;
    font-weight: 600;
    color: #e0e0e0;
    letter-spacing: 0.3px;
}
.agent-card-badge {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.55rem;
    color: rgba(102, 126, 234, 0.6);
    background: rgba(102, 126, 234, 0.08);
    padding: 2px 8px;
    border-radius: 10px;
    letter-spacing: 0.5px;
}
.agent-card-close {
    cursor: pointer;
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.3);
    padding: 0 4px;
    transition: color 0.2s;
}
.agent-card-close:hover {
    color: rgba(255, 255, 255, 0.7);
}

/* ── Card body ── */
.agent-card-body {
    padding: 14px 16px;
}
.agent-card-body p {
    font-size: 0.78rem;
    line-height: 1.55;
    color: rgba(224, 224, 224, 0.75);
    margin: 0 0 10px;
}

/* ── Detail rows ── */
.agent-card-detail {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    padding: 5px 0;
    border-top: 1px solid rgba(102, 126, 234, 0.06);
}
.agent-card-detail-label {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.6rem;
    color: var(--agent-accent, rgba(102, 126, 234, 0.6));
    letter-spacing: 0.5px;
    text-transform: uppercase;
}
.agent-card-detail-value {
    font-size: 0.72rem;
    color: rgba(224, 224, 224, 0.65);
    text-align: right;
    max-width: 60%;
}

/* ── Tech tags inside card ── */
.agent-card-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-top: 8px;
}
.agent-card-tags span {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.55rem;
    background: rgba(102, 126, 234, 0.08);
    color: var(--agent-accent, rgba(102, 126, 234, 0.7));
    padding: 2px 8px;
    border-radius: 4px;
    border: 1px solid rgba(102, 126, 234, 0.1);
}

/* ── Card footer ── */
.agent-card-footer {
    padding: 8px 16px;
    border-top: 1px solid rgba(102, 126, 234, 0.08);
}
.agent-card-hint {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.5rem;
    color: rgba(102, 126, 234, 0.3);
    letter-spacing: 0.5px;
}
