/* frontend/css/style.css */
:root, [data-theme="cyber-dark"] {
    --primary: #6366f1;
    --primary-dark: #4f46e5;
    --primary-light: #818cf8;
    --secondary: #a855f7;
    --background: #0b091a;
    --bg-mesh-1: rgba(99, 102, 241, 0.15);
    --bg-mesh-2: rgba(168, 85, 247, 0.12);
    --nav-bg: rgba(11, 9, 26, 0.88);
    --surface: rgba(255, 255, 255, 0.05);
    --surface-hover: rgba(255, 255, 255, 0.08);
    --surface-active: rgba(255, 255, 255, 0.12);
    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;
    --border-color: rgba(255, 255, 255, 0.1);
    --border-glow: rgba(99, 102, 241, 0.35);
    --radius: 16px;
    --shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    --card-shadow: 0 15px 35px rgba(0, 0, 0, 0.4);
    --transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    --canvas-particle: #818cf8;
    --canvas-line: rgba(99, 102, 241, 0.22);
}

[data-theme="clean-light"] {
    --primary: #2563eb;
    --primary-dark: #1d4ed8;
    --primary-light: #3b82f6;
    --secondary: #4f46e5;
    --background: #f8fafc;
    --bg-mesh-1: rgba(37, 99, 235, 0.06);
    --bg-mesh-2: rgba(79, 70, 229, 0.05);
    --nav-bg: rgba(255, 255, 255, 0.92);
    --surface: #ffffff;
    --surface-hover: #f1f5f9;
    --surface-active: #e2e8f0;
    --text-primary: #0f172a;
    --text-secondary: #475569;
    --text-muted: #94a3b8;
    --border-color: #e2e8f0;
    --border-glow: rgba(37, 99, 235, 0.25);
    --radius: 16px;
    --shadow: 0 12px 36px rgba(0, 0, 0, 0.08);
    --card-shadow: 0 10px 25px rgba(0, 0, 0, 0.06);
    --transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    --canvas-particle: #3b82f6;
    --canvas-line: rgba(37, 99, 235, 0.15);
}

[data-theme="emerald-matrix"] {
    --primary: #10b981;
    --primary-dark: #059669;
    --primary-light: #34d399;
    --secondary: #06b6d4;
    --background: #05140d;
    --bg-mesh-1: rgba(16, 185, 129, 0.15);
    --bg-mesh-2: rgba(6, 182, 212, 0.1);
    --nav-bg: rgba(5, 20, 13, 0.88);
    --surface: rgba(16, 185, 129, 0.06);
    --surface-hover: rgba(16, 185, 129, 0.1);
    --surface-active: rgba(16, 185, 129, 0.15);
    --text-primary: #ecfdf5;
    --text-secondary: #86efac;
    --text-muted: #4ade80;
    --border-color: rgba(16, 185, 129, 0.22);
    --border-glow: rgba(16, 185, 129, 0.4);
    --radius: 16px;
    --shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    --card-shadow: 0 15px 35px rgba(0, 0, 0, 0.5);
    --transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    --canvas-particle: #10b981;
    --canvas-line: rgba(16, 185, 129, 0.25);
}

[data-theme="midnight-sapphire"] {
    --primary: #38bdf8;
    --primary-dark: #0284c7;
    --primary-light: #7dd3fc;
    --secondary: #6366f1;
    --background: #060d1f;
    --bg-mesh-1: rgba(56, 189, 248, 0.14);
    --bg-mesh-2: rgba(99, 102, 241, 0.12);
    --nav-bg: rgba(6, 13, 31, 0.88);
    --surface: rgba(30, 58, 138, 0.15);
    --surface-hover: rgba(30, 58, 138, 0.25);
    --surface-active: rgba(30, 58, 138, 0.35);
    --text-primary: #f0f9ff;
    --text-secondary: #93c5fd;
    --text-muted: #60a5fa;
    --border-color: rgba(56, 189, 248, 0.22);
    --border-glow: rgba(56, 189, 248, 0.35);
    --radius: 16px;
    --shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    --card-shadow: 0 15px 35px rgba(0, 0, 0, 0.5);
    --transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    --canvas-particle: #38bdf8;
    --canvas-line: rgba(56, 189, 248, 0.22);
}

[data-theme="sunset-amber"] {
    --primary: #f97316;
    --primary-dark: #ea580c;
    --primary-light: #fb923c;
    --secondary: #e11d48;
    --background: #140909;
    --bg-mesh-1: rgba(249, 115, 22, 0.14);
    --bg-mesh-2: rgba(225, 29, 72, 0.12);
    --nav-bg: rgba(20, 9, 9, 0.88);
    --surface: rgba(249, 115, 22, 0.06);
    --surface-hover: rgba(249, 115, 22, 0.1);
    --surface-active: rgba(249, 115, 22, 0.16);
    --text-primary: #fff7ed;
    --text-secondary: #fdba74;
    --text-muted: #fb923c;
    --border-color: rgba(249, 115, 22, 0.22);
    --border-glow: rgba(249, 115, 22, 0.35);
    --radius: 16px;
    --shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    --card-shadow: 0 15px 35px rgba(0, 0, 0, 0.5);
    --transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    --canvas-particle: #f97316;
    --canvas-line: rgba(249, 115, 22, 0.22);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--background);
    color: var(--text-primary);
    min-height: 100vh;
    line-height: 1.6;
    transition: background-color 0.4s ease, color 0.3s ease;
    position: relative;
    overflow-x: hidden;
}

/* 3D Background Canvas */
.scene-3d-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    pointer-events: none;
    z-index: 0;
    opacity: 0.9;
}

#app {
    position: relative;
    z-index: 1;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ============================================
   NAVBAR
   ============================================ */
.navbar {
    background: var(--nav-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-color);
    padding: 16px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: background-color 0.3s ease, border-color 0.3s ease;
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo {
    font-size: 1.8rem;
}

.brand-name {
    font-size: 1.5rem;
    font-weight: 700;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.nav-controls {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
}

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

.btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
}

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

.btn-primary:active {
    transform: translateY(0);
}

.last-synced {
    font-size: 0.85rem;
    color: var(--text-secondary);
    padding: 6px 12px;
    background: var(--surface);
    border-radius: 20px;
    border: 1px solid var(--border-color);
}

/* Theme Selector Controls */
.theme-selector-wrapper {
    position: relative;
    display: inline-block;
}

.btn-theme {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    font-size: 0.88rem;
    background: var(--surface);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
}

.btn-theme:hover {
    background: var(--surface-hover);
    border-color: var(--primary);
}

.theme-arrow {
    font-size: 0.75rem;
    opacity: 0.7;
    transition: transform 0.2s ease;
}

.theme-dropdown {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    min-width: 250px;
    background: var(--nav-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--border-color);
    border-radius: 14px;
    box-shadow: var(--shadow);
    padding: 10px;
    z-index: 10002;
    animation: themeDropFade 0.25s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes themeDropFade {
    from {
        opacity: 0;
        transform: translateY(-8px) scale(0.97);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.theme-dropdown-header {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding: 6px 10px;
}

.theme-option {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 8px 10px;
    border: none;
    background: transparent;
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 0.88rem;
    font-weight: 500;
    cursor: pointer;
    text-align: left;
    transition: background-color 0.2s ease, transform 0.15s ease;
}

.theme-option:hover {
    background: var(--surface-hover);
    transform: translateX(3px);
}

.theme-option.active {
    background: var(--surface-active);
    color: var(--primary-light);
    font-weight: 600;
}

.theme-swatch {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.4);
    flex-shrink: 0;
}

.swatch-cyber-dark {
    background: linear-gradient(135deg, #6366f1, #a855f7);
}

.swatch-clean-light {
    background: linear-gradient(135deg, #2563eb, #ffffff);
}

.swatch-emerald {
    background: linear-gradient(135deg, #10b981, #06b6d4);
}

.swatch-sapphire {
    background: linear-gradient(135deg, #38bdf8, #6366f1);
}

.swatch-sunset {
    background: linear-gradient(135deg, #f97316, #e11d48);
}

.theme-name {
    flex: 1;
}

.theme-check {
    font-size: 0.85rem;
    color: var(--primary);
    opacity: 0;
}

.theme-option.active .theme-check {
    opacity: 1;
}

.theme-dropdown-divider {
    height: 1px;
    background: var(--border-color);
    margin: 8px 0;
}

.theme-custom-section {
    padding: 6px 10px;
}

.custom-color-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
    font-size: 0.82rem;
    color: var(--text-secondary);
}

.custom-color-row input[type="color"] {
    -webkit-appearance: none;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    width: 32px;
    height: 24px;
    cursor: pointer;
    background: transparent;
    padding: 0;
}

.btn-export-pdf {
    background: rgba(99, 102, 241, 0.15);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
    padding: 8px 18px;
    border-radius: 12px;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-export-pdf:hover {
    background: var(--primary);
    color: #ffffff;
    border-color: var(--primary);
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(99, 102, 241, 0.35);
}

/* ============================================
   HERO SECTION & 3D ARCHITECTURE
   ============================================ */
.hero-section {
    padding: 50px 0 30px;
    margin-bottom: 40px;
    perspective: 1200px;
}

.hero-3d-wrapper {
    perspective: 1000px;
}

.hero-card-3d {
    background: var(--surface);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border: 1px solid var(--border-color);
    border-radius: 24px;
    padding: 40px;
    display: flex;
    align-items: center;
    gap: 40px;
    box-shadow: var(--shadow);
    position: relative;
    overflow: hidden;
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.hero-card-3d:hover {
    border-color: var(--border-glow);
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.4), 0 0 30px var(--border-glow);
}

.hero-card-3d::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, var(--bg-mesh-1) 0%, transparent 70%);
    pointer-events: none;
    border-radius: 50%;
}

.hero-avatar-col {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
    flex-shrink: 0;
}

.avatar.3d-tilt-element {
    width: 140px;
    height: 140px;
    border-radius: 50%;
    margin: 0;
    background: var(--surface);
    border: 3px solid var(--primary);
    overflow: hidden;
    position: relative;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.3);
    animation: avatarFloat 4s ease-in-out infinite;
    transform-style: preserve-3d;
}

@keyframes avatarFloat {
    0%, 100% {
        transform: translateY(0px) rotate(0deg);
    }
    50% {
        transform: translateY(-8px) rotate(1deg);
    }
}

.avatar-specular-ring {
    position: absolute;
    inset: 0;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.4) 0%, transparent 60%);
    pointer-events: none;
}

.avatar-status-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.78rem;
    font-weight: 600;
    color: #10b981;
    background: rgba(16, 185, 129, 0.12);
    border: 1px solid rgba(16, 185, 129, 0.3);
    padding: 4px 12px;
    border-radius: 999px;
    white-space: nowrap;
}

.status-pulse-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #10b981;
    box-shadow: 0 0 10px #10b981;
    animation: statusPulse 2s infinite;
}

@keyframes statusPulse {
    0%, 100% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.3);
        opacity: 0.6;
    }
}

.hero-text-col {
    flex: 1;
    text-align: left;
}

#name {
    font-size: 2.8rem;
    font-weight: 800;
    margin-bottom: 6px;
    background: linear-gradient(135deg, var(--primary-light), var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: -0.02em;
}

#headline {
    font-size: 1.25rem;
    color: var(--text-primary);
    font-weight: 500;
    margin-bottom: 12px;
}

.hero-bio {
    font-size: 0.98rem;
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 24px;
    max-width: 720px;
}

.hero-action-buttons {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

/* ============================================
   SECTIONS
   ============================================ */
.section {
    margin-bottom: 48px;
}

.section-title {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 24px;
    color: var(--text-primary);
    letter-spacing: -0.5px;
}

.loading-placeholder {
    color: var(--text-secondary);
    text-align: center;
    padding: 40px;
    font-style: italic;
}

/* ============================================
   EXPERIENCE GRID
   ============================================ */
.experience-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
}

.experience-card {
    background: var(--surface);
    border-radius: var(--radius);
    padding: 24px;
    border: 1px solid var(--border-color);
    transition: var(--transition);
}

.experience-card:hover {
    background: var(--surface-hover);
    transform: translateY(-2px);
}

.experience-card h3 {
    font-size: 1.2rem;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.experience-company {
    color: var(--primary);
    font-weight: 500;
    margin-bottom: 4px;
}

.experience-duration {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-bottom: 12px;
}

.experience-bullets {
    list-style: none;
    padding: 0;
}

.experience-bullets li {
    padding: 4px 0 4px 20px;
    position: relative;
    color: var(--text-secondary);
}

.experience-bullets li::before {
    content: "•";
    color: var(--primary);
    position: absolute;
    left: 0;
}

/* ============================================
   PROJECT GRID
   ============================================ */
.project-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

.project-card {
    background: var(--surface);
    border-radius: var(--radius);
    padding: 24px;
    border: 1px solid var(--border-color);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
}

.project-card:hover {
    background: var(--surface-hover);
    transform: translateY(-4px);
    border-color: var(--primary);
}

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

.project-description {
    color: var(--text-secondary);
    font-size: 0.95rem;
    flex: 1;
    margin-bottom: 12px;
}

.project-meta {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
    margin-bottom: 12px;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.project-stars {
    display: flex;
    align-items: center;
    gap: 4px;
}

.project-tech {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: auto;
}

.tech-tag {
    background: var(--surface);
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
}

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

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

/* ============================================
   SKILLS CLOUD
   ============================================ */
.skills-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.skill-tag {
    background: var(--surface);
    padding: 8px 20px;
    border-radius: 30px;
    font-size: 0.95rem;
    border: 1px solid var(--border-color);
    transition: var(--transition);
    color: var(--text-secondary);
}

.skill-tag:hover {
    background: var(--surface-hover);
    border-color: var(--primary);
    color: var(--text-primary);
    transform: translateY(-2px);
}

/* ============================================
   EDUCATION & CERTIFICATIONS
   ============================================ */
.education-grid,
.certification-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
}

.education-card,
.certification-card {
    background: var(--surface);
    border-radius: var(--radius);
    padding: 20px;
    border: 1px solid var(--border-color);
    transition: var(--transition);
}

.education-card:hover,
.certification-card:hover {
    background: var(--surface-hover);
}

.education-card h4,
.certification-card h4 {
    color: var(--text-primary);
    margin-bottom: 4px;
}

.education-details,
.certification-details {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

/* ============================================
   FOOTER
   ============================================ */
.footer {
    border-top: 1px solid var(--border-color);
    padding: 24px 0;
    margin-top: 40px;
}

.footer .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
}

.footer p {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.footer-status {
    display: flex;
    align-items: center;
    gap: 8px;
}

.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    display: inline-block;
}

.status-dot.online {
    background: #4CAF50;
}

.status-dot.offline {
    background: #f44336;
}

.status-dot.syncing {
    background: #FFA500;
    animation: pulse 1s infinite;
}

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

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 768px) {
    .navbar .container {
        flex-direction: column;
        align-items: stretch;
    }
    
    .nav-controls {
        justify-content: space-between;
        flex-wrap: wrap;
    }
    
    .project-grid {
        grid-template-columns: 1fr;
    }
    
    .education-grid,
    .certification-grid {
        grid-template-columns: 1fr;
    }
    
    #name {
        font-size: 2rem;
    }
    
    #headline {
        font-size: 1rem;
    }
    
    .section-title {
        font-size: 1.4rem;
    }
    
    .experience-card {
        padding: 16px;
    }
    
    .project-card {
        padding: 16px;
    }
}

@media (max-width: 480px) {
    .nav-controls {
        flex-direction: column;
        align-items: stretch;
    }
    
    .btn {
        justify-content: center;
    }
    
    .hero-section {
        padding: 40px 0 24px;
    }
}

/* ============================================
   NEW BUTTONS & BADGES
   ============================================ */
.btn-secondary {
    background: linear-gradient(135deg, #4f46e5, #7c3aed);
    color: white;
}

.btn-secondary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(79, 70, 229, 0.4);
}

.btn-outline {
    background: var(--surface);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

.btn-outline:hover {
    background: var(--surface-hover);
    border-color: var(--primary);
    transform: translateY(-2px);
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    background: rgba(16, 185, 129, 0.15);
    color: #10b981;
    border: 1px solid rgba(16, 185, 129, 0.3);
}

.pulse-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #10b981;
    box-shadow: 0 0 8px #10b981;
    animation: pulse 1.5s infinite;
}

.hidden {
    display: none !important;
}

/* ============================================
   HUMAN-IN-THE-LOOP (HITL) REVIEW PANEL
   ============================================ */
.hitl-panel {
    background: linear-gradient(135deg, rgba(79, 70, 229, 0.15), rgba(124, 58, 237, 0.15));
    border: 2px solid #818cf8;
    border-radius: var(--radius);
    padding: 24px;
    margin-bottom: 32px;
    box-shadow: 0 15px 35px rgba(79, 70, 229, 0.2);
    animation: fadeIn 0.4s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

.hitl-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 12px;
}

.hitl-title-wrap {
    display: flex;
    align-items: center;
    gap: 12px;
}

.hitl-badge {
    background: #4f46e5;
    color: white;
    padding: 4px 10px;
    border-radius: 8px;
    font-size: 0.8rem;
    font-weight: 700;
}

.hitl-heading {
    font-size: 1.3rem;
    color: var(--text-primary);
}

.hitl-tag {
    background: rgba(255, 255, 255, 0.1);
    color: #c7d2fe;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.75rem;
    border: 1px solid rgba(255, 255, 255, 0.15);
}

.hitl-desc {
    color: var(--text-secondary);
    font-size: 0.95rem;
    margin-bottom: 18px;
}

.hitl-diff-box {
    background: rgba(0, 0, 0, 0.25);
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 18px;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.diff-title {
    font-size: 0.95rem;
    color: #a5b4fc;
    margin-bottom: 10px;
}

.hitl-diff-list {
    list-style: none;
    padding-left: 0;
}

.hitl-diff-list li {
    padding: 4px 0 4px 20px;
    position: relative;
    color: #e0e7ff;
    font-size: 0.9rem;
}

.hitl-diff-list li::before {
    content: "✦";
    position: absolute;
    left: 0;
    color: #818cf8;
}

.hitl-preview-box {
    background: rgba(255, 255, 255, 0.04);
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 18px;
    display: grid;
    gap: 12px;
}

.preview-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.preview-label {
    font-size: 0.8rem;
    text-transform: uppercase;
    color: #94a3b8;
    letter-spacing: 0.5px;
}

.preview-content {
    font-size: 1rem;
    color: #f8fafc;
}

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

.preview-tag {
    background: rgba(99, 102, 241, 0.2);
    color: #c7d2fe;
    border: 1px solid rgba(99, 102, 241, 0.3);
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 0.85rem;
}

.hitl-feedback-group {
    margin-bottom: 20px;
}

.hitl-label {
    display: block;
    font-size: 0.9rem;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.hitl-input-row {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.hitl-input {
    flex: 1;
    min-width: 260px;
    padding: 10px 16px;
    border-radius: 10px;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    font-size: 0.95rem;
}

.hitl-input:focus {
    outline: none;
    border-color: #818cf8;
    box-shadow: 0 0 10px rgba(129, 140, 248, 0.3);
}

.hitl-history {
    margin-top: 8px;
    font-size: 0.85rem;
    color: #94a3b8;
    font-style: italic;
}

.hitl-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

/* ============================================
   MODALS
   ============================================ */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    padding: 20px;
}

.modal-dialog {
    background: #16152b;
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    width: 100%;
    max-width: 650px;
    max-height: 90vh;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    box-shadow: var(--shadow);
}

.modal-large {
    max-width: 800px;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 24px;
    border-bottom: 1px solid var(--border-color);
}

.modal-header h3 {
    font-size: 1.25rem;
    color: var(--text-primary);
}

.modal-close {
    background: transparent;
    border: none;
    color: var(--text-secondary);
    font-size: 1.8rem;
    cursor: pointer;
    line-height: 1;
}

.modal-close:hover {
    color: white;
}

.modal-body {
    padding: 24px;
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    padding: 16px 24px;
    border-top: 1px solid var(--border-color);
    background: rgba(0, 0, 0, 0.2);
}

.form-group {
    margin-bottom: 20px;
}

.form-label {
    display: block;
    margin-bottom: 6px;
    color: var(--text-primary);
    font-size: 0.95rem;
}

.form-help {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-bottom: 8px;
}

.form-control {
    width: 100%;
    padding: 12px 16px;
    border-radius: 10px;
    background: var(--surface);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    font-size: 0.95rem;
    font-family: inherit;
}

.form-control:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 10px rgba(102, 126, 234, 0.3);
}

.form-textarea {
    resize: vertical;
}

/* ============================================
   LINKEDIN TOS COMPLIANCE BOX
   ============================================ */
.tos-box {
    background: rgba(245, 158, 11, 0.1);
    border: 1px solid rgba(245, 158, 11, 0.3);
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 20px;
    display: flex;
    gap: 14px;
    align-items: flex-start;
}

.tos-icon {
    font-size: 1.5rem;
    line-height: 1;
}

.tos-content {
    flex: 1;
    font-size: 0.9rem;
    color: #fef3c7;
}

.tos-content p {
    margin: 4px 0 10px;
    color: #fde68a;
    line-height: 1.5;
}

.tos-steps {
    cursor: pointer;
    font-size: 0.85rem;
    background: rgba(0, 0, 0, 0.2);
    padding: 8px 12px;
    border-radius: 8px;
}

.tos-steps summary {
    font-weight: 600;
    color: #fbbf24;
}

.tos-steps ol {
    padding-left: 20px;
    margin-top: 8px;
    color: #fef08a;
}

.tos-steps li {
    margin-bottom: 4px;
}

/* ============================================
   DATABASE GUIDE & TABS
   ============================================ */
.modal-intro {
    font-size: 0.95rem;
    color: var(--text-secondary);
    margin-bottom: 20px;
    line-height: 1.5;
}

.tab-list {
    display: flex;
    gap: 8px;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 20px;
    overflow-x: auto;
    padding-bottom: 4px;
}

.tab-btn {
    background: transparent;
    border: none;
    color: var(--text-secondary);
    padding: 8px 16px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.9rem;
    transition: var(--transition);
    white-space: nowrap;
}

.tab-btn.active, .tab-btn:hover {
    background: var(--surface-hover);
    color: var(--primary);
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
    animation: fadeIn 0.3s ease;
}

.tab-content h4 {
    color: var(--text-primary);
    margin-bottom: 12px;
    font-size: 1.1rem;
}

.baby-steps {
    padding-left: 20px;
    color: var(--text-secondary);
    margin-bottom: 16px;
    font-size: 0.95rem;
}

.baby-steps li {
    margin-bottom: 8px;
}

.baby-steps a {
    color: var(--primary);
    text-decoration: underline;
}

.code-example {
    background: #090817;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 12px 16px;
    margin-bottom: 20px;
    overflow-x: auto;
    font-family: monospace;
    font-size: 0.85rem;
    color: #38bdf8;
}

.db-test-box {
    margin-top: 24px;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
}

.db-input-row {
    display: flex;
    gap: 12px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.db-input-row input {
    flex: 1;
    min-width: 280px;
}

.db-result-box {
    border-radius: 12px;
    padding: 16px;
    font-size: 0.9rem;
    line-height: 1.5;
}

.db-result-box.valid {
    background: rgba(16, 185, 129, 0.15);
    border: 1px solid #10b981;
    color: #d1fae5;
}

.db-result-box.invalid {
    background: rgba(239, 68, 68, 0.15);
    border: 1px solid #ef4444;
    color: #fee2e2;
}

.status-alert {
    padding: 12px 16px;
    border-radius: 8px;
    font-size: 0.9rem;
    margin-top: 16px;
}

.status-alert.info {
    background: rgba(99, 102, 241, 0.2);
    border: 1px solid #6366f1;
    color: #c7d2fe;
}

/* Offline Notice Banner */
.offline-banner {
    background: linear-gradient(90deg, rgba(234, 179, 8, 0.2), rgba(202, 138, 4, 0.25));
    border-bottom: 1px solid rgba(234, 179, 8, 0.4);
    color: #fef08a;
    padding: 10px 20px;
    font-size: 0.9rem;
    font-weight: 500;
    text-align: center;
    position: sticky;
    top: 65px;
    z-index: 999;
    backdrop-filter: blur(8px);
    transition: all 0.3s ease;
}

.offline-banner.hidden {
    display: none !important;
}

.offline-banner-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.offline-badge-pill {
    background: rgba(234, 179, 8, 0.3);
    border: 1px solid rgba(234, 179, 8, 0.6);
    padding: 2px 8px;
    border-radius: 999px;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 700;
}

/* ============================================
   TOAST NOTIFICATION SYSTEM
   ============================================ */
.toast-container {
    position: fixed;
    top: 80px;
    right: 24px;
    z-index: 10000;
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-width: 420px;
    width: calc(100% - 48px);
    pointer-events: none;
}

.toast {
    pointer-events: auto;
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 14px 16px;
    border-radius: 12px;
    background: rgba(26, 21, 56, 0.95);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    box-shadow: 0 12px 36px rgba(0, 0, 0, 0.45);
    color: #f3f4f6;
    animation: toastSlideIn 0.35s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.toast.toast-fade-out {
    opacity: 0;
    transform: translateX(30px);
}

@keyframes toastSlideIn {
    from {
        opacity: 0;
        transform: translateX(40px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateX(0) scale(1);
    }
}

.toast-icon {
    font-size: 1.25rem;
    line-height: 1;
    margin-top: 2px;
    flex-shrink: 0;
}

.toast-body {
    flex: 1;
    min-width: 0;
}

.toast-title {
    font-weight: 600;
    font-size: 0.92rem;
    margin-bottom: 3px;
    color: #ffffff;
}

.toast-message {
    font-size: 0.85rem;
    line-height: 1.45;
    color: #d1d5db;
    word-break: break-word;
}

.toast-action-btn {
    margin-top: 8px;
    display: inline-block;
    padding: 4px 10px;
    font-size: 0.78rem;
    font-weight: 600;
    border-radius: 6px;
    border: 1px solid rgba(255, 255, 255, 0.25);
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
    cursor: pointer;
    transition: all 0.2s ease;
}

.toast-action-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.4);
}

.toast-close {
    background: transparent;
    border: none;
    color: #9ca3af;
    font-size: 1.2rem;
    line-height: 1;
    cursor: pointer;
    padding: 0 4px;
    transition: color 0.2s ease;
    flex-shrink: 0;
}

.toast-close:hover {
    color: #ffffff;
}

/* Toast Variants */
.toast-error {
    border-left: 4px solid #ef4444;
    background: linear-gradient(135deg, rgba(30, 20, 35, 0.96), rgba(20, 15, 30, 0.98));
}
.toast-error .toast-title {
    color: #fca5a5;
}

.toast-warning {
    border-left: 4px solid #f59e0b;
    background: linear-gradient(135deg, rgba(35, 28, 20, 0.96), rgba(22, 18, 28, 0.98));
}
.toast-warning .toast-title {
    color: #fde68a;
}

.toast-success {
    border-left: 4px solid #10b981;
    background: linear-gradient(135deg, rgba(18, 35, 28, 0.96), rgba(15, 22, 28, 0.98));
}
.toast-success .toast-title {
    color: #a7f3d0;
}

.toast-info {
    border-left: 4px solid #6366f1;
    background: linear-gradient(135deg, rgba(22, 25, 45, 0.96), rgba(16, 18, 35, 0.98));
}
.toast-info .toast-title {
    color: #c7d2fe;
}

/* ============================================
   GLOBAL ERROR BOUNDARY
   ============================================ */
.global-error-boundary {
    position: fixed;
    inset: 0;
    background: rgba(10, 8, 25, 0.85);
    backdrop-filter: blur(16px);
    z-index: 10001;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.global-error-boundary.hidden {
    display: none !important;
}

.error-boundary-dialog {
    background: #191436;
    border: 1px solid rgba(239, 68, 68, 0.4);
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.6), 0 0 30px rgba(239, 68, 68, 0.15);
    border-radius: 18px;
    max-width: 520px;
    width: 100%;
    padding: 32px;
    text-align: center;
}

.error-boundary-icon {
    font-size: 3rem;
    margin-bottom: 12px;
}

.error-boundary-dialog h2 {
    font-size: 1.35rem;
    color: #fca5a5;
    margin-bottom: 10px;
}

.error-boundary-dialog p {
    font-size: 0.92rem;
    color: #d1d5db;
    line-height: 1.5;
    margin-bottom: 18px;
}

.boundary-error-details {
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 12px;
    font-family: monospace;
    font-size: 0.8rem;
    color: #f87171;
    text-align: left;
    max-height: 120px;
    overflow-y: auto;
    margin-bottom: 20px;
    white-space: pre-wrap;
}

.boundary-actions {
    display: flex;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
}

/* ============================================
   SECTION HEADERS & TOOLBARS
   ============================================ */
.section-header-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 16px;
    margin-bottom: 20px;
}

.section-subtitle {
    color: var(--text-secondary);
    font-size: 0.95rem;
    margin-top: 4px;
    max-width: 650px;
}

.projects-toolbar,
.certs-toolbar {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.projects-count-indicator {
    font-size: 0.82rem;
    color: #a0aec0;
    background: rgba(255, 255, 255, 0.06);
    padding: 4px 10px;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.badge-public {
    background: rgba(16, 185, 129, 0.15);
    color: #10b981;
    border: 1px solid rgba(16, 185, 129, 0.35);
    padding: 4px 12px;
    border-radius: 999px;
    font-size: 0.8rem;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.badge-linkedin {
    background: rgba(10, 102, 194, 0.2);
    color: #60a5fa;
    border: 1px solid rgba(10, 102, 194, 0.4);
    padding: 4px 12px;
    border-radius: 999px;
    font-size: 0.8rem;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.btn-sm {
    padding: 6px 14px;
    font-size: 0.82rem;
}

/* ============================================
   PROJECT CARD ACTIONS & HIDE / UNHIDE
   ============================================ */
.project-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 8px;
}

.project-card-title-group {
    flex: 1;
    min-width: 0;
}

.project-card-title-group h3 {
    margin-bottom: 4px;
    word-break: break-word;
}

.project-card-badges {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
    margin-top: 4px;
}

.badge-public-chip {
    font-size: 0.72rem;
    font-weight: 700;
    padding: 2px 7px;
    border-radius: 6px;
    background: rgba(16, 185, 129, 0.15);
    color: #34d399;
    border: 1px solid rgba(16, 185, 129, 0.3);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.badge-hidden-chip {
    font-size: 0.72rem;
    font-weight: 700;
    padding: 2px 7px;
    border-radius: 6px;
    background: rgba(239, 68, 68, 0.15);
    color: #f87171;
    border: 1px solid rgba(239, 68, 68, 0.3);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.repo-hide-btn {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #9ca3af;
    border-radius: 8px;
    padding: 4px 10px;
    font-size: 0.78rem;
    cursor: pointer;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    flex-shrink: 0;
}

.repo-hide-btn:hover {
    background: rgba(239, 68, 68, 0.2);
    border-color: rgba(239, 68, 68, 0.4);
    color: #fca5a5;
}

.repo-unhide-btn {
    background: rgba(16, 185, 129, 0.15);
    border: 1px solid rgba(16, 185, 129, 0.4);
    color: #6ee7b7;
    border-radius: 8px;
    padding: 4px 10px;
    font-size: 0.78rem;
    cursor: pointer;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    flex-shrink: 0;
}

.repo-unhide-btn:hover {
    background: rgba(16, 185, 129, 0.25);
    border-color: #10b981;
    color: #ffffff;
}

.project-card.is-hidden {
    opacity: 0.75;
    border-style: dashed;
    border-color: rgba(245, 158, 11, 0.5);
    background: rgba(245, 158, 11, 0.03);
}

.project-card.is-hidden:hover {
    opacity: 1;
    border-color: #f59e0b;
}

/* ============================================
   CERTIFICATION CARDS & CREDENTIALS
   ============================================ */
.certification-card {
    background: var(--surface);
    border-radius: var(--radius);
    padding: 22px;
    border: 1px solid var(--border-color);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: hidden;
}

.certification-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(180deg, #3b82f6, #6366f1);
}

.cert-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 8px;
}

.cert-title {
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--text-primary);
    line-height: 1.4;
}

.cert-badge {
    background: rgba(59, 130, 246, 0.15);
    color: #93c5fd;
    border: 1px solid rgba(59, 130, 246, 0.35);
    padding: 2px 8px;
    border-radius: 6px;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    flex-shrink: 0;
}

.cert-issuer {
    color: #c7d2fe;
    font-weight: 500;
    font-size: 0.92rem;
    margin-bottom: 4px;
}

.cert-meta-row {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 8px;
    font-size: 0.82rem;
    color: var(--text-secondary);
}

.cert-credential-id {
    background: rgba(255, 255, 255, 0.05);
    padding: 2px 8px;
    border-radius: 4px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    font-family: monospace;
    font-size: 0.78rem;
    color: #e2e8f0;
}

.cert-verify-link {
    color: #60a5fa;
    text-decoration: none;
    font-size: 0.82rem;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    transition: color 0.2s ease;
}

.cert-verify-link:hover {
    color: #93c5fd;
    text-decoration: underline;
}

/* ============================================
   3D CARD TILT & SPECULAR GLARE
   ============================================ */
.project-card,
.certification-card,
.experience-card,
.education-card {
    transform-style: preserve-3d;
    transition: transform 0.15s ease-out, box-shadow 0.25s ease, border-color 0.25s ease;
    position: relative;
    overflow: hidden;
    will-change: transform;
}

.project-card:hover,
.certification-card:hover,
.experience-card:hover,
.education-card:hover {
    border-color: var(--border-glow);
    box-shadow: var(--card-shadow), 0 0 25px var(--border-glow);
}

.card-specular-glare {
    position: absolute;
    inset: 0;
    pointer-events: none;
    border-radius: inherit;
    opacity: 0;
    transition: opacity 0.3s ease;
    mix-blend-mode: overlay;
    z-index: 5;
}

.project-card:hover .card-specular-glare,
.certification-card:hover .card-specular-glare,
.experience-card:hover .card-specular-glare,
.education-card:hover .card-specular-glare {
    opacity: 1;
}

/* ============================================
   PDF EXPORT MODAL & LIVE PREVIEW
   ============================================ */
.modal-lg {
    max-width: 880px !important;
    width: 95% !important;
}

.pdf-config-panel {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-top: 14px;
}

.pdf-options-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

@media (max-width: 768px) {
    .pdf-options-row {
        grid-template-columns: 1fr;
    }
}

.pdf-dropdowns-bar {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 16px;
    padding: 14px 16px;
    background: var(--surface);
    border: 1px solid var(--border-glow);
    border-radius: 12px;
}

@media (max-width: 640px) {
    .pdf-dropdowns-bar {
        grid-template-columns: 1fr;
    }
}

.pdf-dropdown-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.pdf-select {
    width: 100%;
    padding: 8px 12px;
    background: var(--surface-active);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.pdf-select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 10px var(--border-glow);
}

.dropdown-hint {
    font-size: 0.75rem;
    color: var(--text-secondary);
}

.pdf-style-selectors {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 6px;
}

.pdf-style-card {
    display: flex;
    flex-direction: column;
    padding: 10px 14px;
    border-radius: 10px;
    border: 1px solid var(--border-color);
    background: var(--surface);
    cursor: pointer;
    transition: var(--transition);
    position: relative;
}

.pdf-style-card:hover {
    background: var(--surface-hover);
    border-color: var(--primary);
}

.pdf-style-card.active {
    border-color: var(--primary);
    background: var(--surface-active);
    box-shadow: 0 0 15px var(--border-glow);
}

.pdf-style-card input[type="radio"] {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.pdf-style-card .style-title {
    font-size: 0.92rem;
    font-weight: 700;
    color: var(--text-primary);
}

.pdf-style-card .style-desc {
    font-size: 0.78rem;
    color: var(--text-secondary);
    margin-top: 2px;
}

.pdf-sections-grid {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-top: 6px;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.88rem;
    color: var(--text-primary);
    cursor: pointer;
}

.checkbox-label input[type="checkbox"] {
    accent-color: var(--primary);
    width: 16px;
    height: 16px;
    cursor: pointer;
}

.pdf-live-preview-box {
    border: 1px solid var(--border-color);
    border-radius: 12px;
    background: rgba(0, 0, 0, 0.25);
    overflow: hidden;
}

.pdf-preview-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 14px;
    background: var(--surface);
    border-bottom: 1px solid var(--border-color);
    font-size: 0.8rem;
    color: var(--text-secondary);
    font-weight: 600;
}

.pdf-badge-print {
    background: rgba(16, 185, 129, 0.15);
    color: #10b981;
    border: 1px solid rgba(16, 185, 129, 0.3);
    padding: 2px 8px;
    border-radius: 999px;
    font-size: 0.72rem;
}

.pdf-preview-scroll-area {
    max-height: 380px;
    overflow-y: auto;
    padding: 20px;
    display: flex;
    justify-content: center;
    background: #475569;
}

.pdf-paper-document {
    background: #ffffff;
    color: #1e293b;
    width: 100%;
    max-width: 650px;
    min-height: 800px;
    padding: 36px 40px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.35);
    font-family: 'Inter', -apple-system, sans-serif;
    font-size: 11pt;
    line-height: 1.5;
}

/* Print Preview Inner Styles */
.pdf-doc-header {
    border-bottom: 2px solid #2563eb;
    padding-bottom: 14px;
    margin-bottom: 18px;
}

.pdf-doc-header h1 {
    font-size: 20pt;
    color: #0f172a;
    font-weight: 800;
    margin: 0;
    letter-spacing: -0.02em;
}

.pdf-doc-header .pdf-doc-headline {
    font-size: 11pt;
    color: #2563eb;
    font-weight: 600;
    margin-top: 4px;
}

.pdf-doc-contact-row {
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
    font-size: 8.5pt;
    color: #64748b;
    margin-top: 6px;
}

.pdf-doc-section {
    margin-bottom: 16px;
}

.pdf-doc-section-title {
    font-size: 10pt;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #0f172a;
    border-bottom: 1px solid #cbd5e1;
    padding-bottom: 4px;
    margin-bottom: 8px;
}

.pdf-doc-summary {
    font-size: 9.5pt;
    color: #334155;
    line-height: 1.5;
}

.pdf-doc-item {
    margin-bottom: 10px;
}

.pdf-doc-item-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    font-size: 9.5pt;
}

.pdf-doc-role {
    font-weight: 700;
    color: #0f172a;
}

.pdf-doc-company {
    color: #334155;
    font-weight: 500;
}

.pdf-doc-date {
    font-size: 8.5pt;
    color: #64748b;
    font-weight: 500;
}

.pdf-doc-bullets {
    margin-top: 4px;
    padding-left: 18px;
    font-size: 8.8pt;
    color: #334155;
}

.pdf-doc-bullets li {
    margin-bottom: 2px;
}

.pdf-doc-tech-tags {
    font-size: 8pt;
    color: #475569;
    margin-top: 3px;
    font-style: italic;
}

.pdf-doc-certs-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}

.pdf-doc-cert-item {
    font-size: 8.8pt;
    border-left: 2px solid #3b82f6;
    padding-left: 8px;
}

.pdf-doc-cert-name {
    font-weight: 700;
    color: #0f172a;
}

.pdf-doc-cert-issuer {
    font-size: 8pt;
    color: #475569;
}

.pdf-doc-skills-list {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    font-size: 8.5pt;
    color: #1e293b;
}

.pdf-doc-skill-pill {
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    padding: 2px 8px;
    border-radius: 4px;
}

/* ============================================
   @MEDIA PRINT - HIGH IMPACT RESUME FORMATTING
   ============================================ */
@media print {
    @page {
        margin: 12mm 15mm;
        size: auto;
    }

    body {
        background: #ffffff !important;
        color: #0f172a !important;
        font-size: 10pt !important;
        line-height: 1.45 !important;
        margin: 0 !important;
        padding: 0 !important;
    }

    /* Hide Web Application Interface Elements */
    #app,
    .navbar,
    .scene-3d-canvas,
    .modal,
    .toast-container,
    .global-error-boundary,
    .offline-banner,
    .hitl-panel {
        display: none !important;
    }

    /* Show Dedicated Printable Resume Container */
    #printableResume {
        display: block !important;
        width: 100% !important;
        background: #ffffff !important;
        color: #0f172a !important;
    }

    .printable-resume-container {
        font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    }

    .pdf-doc-section,
    .pdf-doc-item {
        break-inside: avoid !important;
        page-break-inside: avoid !important;
    }

    .pdf-doc-header {
        border-bottom: 2pt solid #0f172a !important;
    }

    .pdf-doc-header h1 {
        font-size: 22pt !important;
        color: #000000 !important;
    }

    .pdf-doc-section-title {
        color: #000000 !important;
        border-bottom: 1pt solid #94a3b8 !important;
    }

    a {
        text-decoration: none !important;
        color: inherit !important;
    }
}

/* ==========================================================================
   Security, Anti-Copy, Anti-Download & Anti-Capture Protections
   ========================================================================== */

/* Protected Avatar Canvas & Interactive Voice Shield */
.talking-photo-container {
    position: relative;
    cursor: pointer;
    overflow: hidden;
    border-radius: 50%;
    user-select: none;
    -webkit-user-select: none;
    -webkit-touch-callout: none;
}

.protected-avatar-canvas {
    display: block;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    pointer-events: none;
    user-select: none;
    -webkit-user-select: none;
}

.avatar-shield {
    position: absolute;
    inset: 0;
    border-radius: 50%;
    z-index: 5;
    background: transparent;
    cursor: pointer;
    user-select: none;
    -webkit-user-select: none;
}

.avatar-shield:focus-visible {
    outline: 2px solid var(--primary);
    outline-offset: 4px;
}

.avatar-voice-prompt-pill {
    position: absolute;
    bottom: -6px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: #ffffff;
    font-size: 0.72rem;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 20px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4);
    display: flex;
    align-items: center;
    gap: 5px;
    white-space: nowrap;
    z-index: 6;
    pointer-events: none;
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: var(--transition);
}

.talking-photo-container:hover .avatar-voice-prompt-pill {
    transform: translateX(-50%) scale(1.06);
    box-shadow: 0 6px 20px var(--border-glow);
}

.avatar-speech-wave {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    display: flex;
    align-items: center;
    gap: 4px;
    z-index: 4;
    pointer-events: none;
}

.avatar-speech-wave span {
    width: 4px;
    height: 18px;
    background: #ffffff;
    border-radius: 4px;
    animation: speechBounce 1s infinite ease-in-out;
}
.avatar-speech-wave span:nth-child(2) { animation-delay: 0.15s; height: 26px; }
.avatar-speech-wave span:nth-child(3) { animation-delay: 0.3s; height: 34px; }
.avatar-speech-wave span:nth-child(4) { animation-delay: 0.45s; height: 26px; }
.avatar-speech-wave span:nth-child(5) { animation-delay: 0.6s; height: 18px; }

@keyframes speechBounce {
    0%, 100% { transform: scaleY(0.4); }
    50% { transform: scaleY(1); }
}

/* Privacy Blackout Cloak for Camera & Screenshot Detection */
.privacy-blackout-cloak {
    position: fixed;
    inset: 0;
    background: rgba(5, 4, 12, 0.98);
    backdrop-filter: blur(40px);
    z-index: 9999999;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 24px;
    user-select: none;
    -webkit-user-select: none;
}

.privacy-blackout-cloak.hidden {
    display: none !important;
}

.blackout-card {
    max-width: 480px;
    padding: 36px 30px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 20px;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.8);
    color: #ffffff;
}

.blackout-icon {
    font-size: 3.5rem;
    margin-bottom: 12px;
}

.blackout-card h2 {
    font-size: 1.5rem;
    margin-bottom: 10px;
    color: #f8fafc;
}

.blackout-card p {
    font-size: 0.95rem;
    color: #cbd5e1;
    line-height: 1.5;
    margin-bottom: 8px;
}

.blackout-sub {
    font-size: 0.85rem;
    color: #94a3b8;
}

/* Subtle background optical watermark to disrupt camera photos */
body::before {
    content: "ALOK SRIVASTAVA • 91 REPOS • 43 CERTS • OFFICIAL PORTFOLIO • ";
    position: fixed;
    top: 0;
    left: 0;
    width: 200%;
    height: 200%;
    font-size: 10pt;
    color: rgba(255, 255, 255, 0.015);
    pointer-events: none;
    z-index: 9998;
    white-space: pre-wrap;
    overflow: hidden;
    line-height: 40px;
    letter-spacing: 6px;
    user-select: none;
}

/* ==========================================================================
   Security & Automated Testing Operations Center Modal Styling
   ========================================================================== */
.sec-modal-title-wrap {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
}

.security-metrics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 12px;
    margin-bottom: 20px;
}

.sec-metric-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px;
    background: var(--surface);
    border: 1px solid var(--border-color);
    border-radius: 12px;
}

.sec-metric-icon {
    font-size: 1.8rem;
}

.sec-metric-info {
    display: flex;
    flex-direction: column;
}

.sec-metric-title {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    font-weight: 600;
}

.sec-metric-val {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-primary);
}

.sec-metric-val.status-green {
    color: #10b981;
}

.sec-metric-sub {
    font-size: 0.7rem;
    color: var(--text-secondary);
}

.sec-action-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    padding: 12px 16px;
    background: var(--surface-active);
    border: 1px solid var(--border-glow);
    border-radius: 10px;
    margin-bottom: 16px;
}

.test-badge-pass {
    padding: 3px 8px;
    border-radius: 6px;
    font-size: 0.78rem;
    font-weight: 700;
    background: rgba(16, 185, 129, 0.15);
    color: #10b981;
    border: 1px solid rgba(16, 185, 129, 0.3);
}

.sec-subheading {
    font-size: 0.95rem;
    color: var(--text-primary);
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.sec-test-results-box,
.sec-healing-history-box {
    margin-bottom: 16px;
}

.test-results-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    max-height: 240px;
    overflow-y: auto;
    padding-right: 4px;
}

.test-item-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 12px;
    background: var(--surface);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    gap: 12px;
}

.test-item-left {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.test-item-name {
    font-size: 0.88rem;
    font-weight: 600;
    color: var(--text-primary);
}

.test-item-desc {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.test-category-tag {
    display: inline-block;
    font-size: 0.65rem;
    padding: 2px 6px;
    border-radius: 4px;
    background: var(--surface-hover);
    color: var(--primary-light);
    margin-right: 6px;
}

.test-status-pill {
    padding: 4px 8px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 700;
    white-space: nowrap;
}

.test-status-pill.pass {
    background: rgba(16, 185, 129, 0.15);
    color: #10b981;
    border: 1px solid rgba(16, 185, 129, 0.3);
}

.test-status-pill.fail {
    background: rgba(239, 68, 68, 0.15);
    color: #ef4444;
    border: 1px solid rgba(239, 68, 68, 0.3);
}

.sec-shields-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 10px;
    padding-top: 10px;
    border-top: 1px solid var(--border-color);
}

.shield-item {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    font-size: 0.8rem;
    color: var(--text-secondary);
}

.shield-item strong {
    color: var(--text-primary);
    display: block;
    font-size: 0.83rem;
}

/* ==========================================================================
   Talking Photo Storyteller Modal & Waveform Styling
   ========================================================================== */
.modal-storyteller {
    max-width: 650px !important;
}

.story-title-group {
    display: flex;
    align-items: center;
    gap: 12px;
}

.story-icon-pulse {
    font-size: 1.8rem;
    animation: pulseGlow 1.5s infinite alternate;
}

.story-sub {
    font-size: 0.78rem;
    color: var(--text-muted);
}

.story-lang-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 10px;
    padding: 12px 14px;
    background: var(--surface);
    border: 1px solid var(--border-glow);
    border-radius: 12px;
    margin-bottom: 16px;
}

.story-lang-buttons {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.speech-lang-btn {
    padding: 7px 12px;
    background: var(--surface-active);
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-size: 0.82rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 6px;
}

.speech-lang-btn:hover {
    background: var(--surface-hover);
    color: var(--text-primary);
    border-color: var(--primary);
}

.speech-lang-btn.active {
    background: var(--primary);
    color: #ffffff;
    border-color: var(--primary);
    box-shadow: 0 4px 12px var(--border-glow);
}

.story-visualizer-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: radial-gradient(circle at center, rgba(99, 102, 241, 0.15), transparent 70%);
    border-radius: 16px;
    margin-bottom: 16px;
    border: 1px solid var(--border-color);
    position: relative;
}

.speaking-avatar-wrap {
    position: relative;
    width: 100px;
    height: 100px;
    border-radius: 50%;
    margin-bottom: 12px;
}

.speaking-avatar-halo {
    position: absolute;
    inset: -6px;
    border-radius: 50%;
    border: 2px dashed var(--primary);
    animation: rotateHalo 8s linear infinite;
    opacity: 0.6;
}

.speaking-avatar-wrap.is-speaking .speaking-avatar-halo {
    border-color: #10b981;
    border-style: solid;
    box-shadow: 0 0 20px rgba(16, 185, 129, 0.6);
    animation: rotateHalo 3s linear infinite, pulseHalo 1.2s infinite alternate;
}

@keyframes rotateHalo {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

@keyframes pulseHalo {
    from { transform: scale(1); opacity: 0.6; }
    to { transform: scale(1.08); opacity: 1; }
}

.speaking-avatar-img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--primary);
    pointer-events: none;
    user-select: none;
}

.story-visualizer-bars {
    display: flex;
    align-items: center;
    gap: 4px;
    height: 32px;
    margin-bottom: 6px;
}

.story-visualizer-bars span {
    width: 3px;
    height: 8px;
    background: var(--primary-light);
    border-radius: 3px;
    transition: height 0.15s ease;
}

.speaking-avatar-wrap.is-speaking ~ .story-visualizer-bars span {
    animation: audioWave 0.8s infinite ease-in-out alternate;
}

.story-visualizer-bars span:nth-child(2) { animation-delay: 0.1s; }
.story-visualizer-bars span:nth-child(3) { animation-delay: 0.2s; }
.story-visualizer-bars span:nth-child(4) { animation-delay: 0.3s; }
.story-visualizer-bars span:nth-child(5) { animation-delay: 0.15s; }
.story-visualizer-bars span:nth-child(6) { animation-delay: 0.25s; }
.story-visualizer-bars span:nth-child(7) { animation-delay: 0.35s; }
.story-visualizer-bars span:nth-child(8) { animation-delay: 0.05s; }
.story-visualizer-bars span:nth-child(9) { animation-delay: 0.22s; }
.story-visualizer-bars span:nth-child(10) { animation-delay: 0.18s; }
.story-visualizer-bars span:nth-child(11) { animation-delay: 0.28s; }
.story-visualizer-bars span:nth-child(12) { animation-delay: 0.08s; }
.story-visualizer-bars span:nth-child(13) { animation-delay: 0.32s; }
.story-visualizer-bars span:nth-child(14) { animation-delay: 0.14s; }
.story-visualizer-bars span:nth-child(15) { animation-delay: 0.26s; }

@keyframes audioWave {
    0% { height: 6px; }
    100% { height: 28px; }
}

.speaking-status-tag {
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--text-muted);
}

.story-controls-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 16px;
}

.story-ctrl-btn {
    padding: 8px 16px;
    font-size: 0.88rem;
}

.story-rate-control {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.8rem;
    color: var(--text-secondary);
}

.story-select {
    padding: 6px 8px;
    font-size: 0.8rem;
    width: auto;
}

.story-transcript-panel {
    background: var(--surface);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 14px;
}

.story-transcript-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 10px;
    padding-bottom: 6px;
    border-bottom: 1px solid var(--border-color);
}

.story-transcript-scroll {
    max-height: 180px;
    overflow-y: auto;
    font-size: 0.88rem;
    line-height: 1.6;
    color: var(--text-secondary);
    padding-right: 6px;
}

.transcript-section {
    padding: 6px 10px;
    border-radius: 6px;
    margin-bottom: 6px;
    transition: background 0.3s ease;
}

.transcript-section.active-sentence {
    background: rgba(99, 102, 241, 0.2);
    color: var(--text-primary);
    font-weight: 600;
}



