:root {
    --bg-primary: #0f0f14;
    --bg-secondary: #17171d;
    --bg-tertiary: #1f1f28;
    --bg-elevated: #25252f;
    
    --accent-primary: #6366f1;
    --accent-secondary: #8b5cf6;
    --accent-hover: #7c3aed;
    
    --text-primary: #e4e4e7;
    --text-secondary: #a1a1aa;
    --text-muted: #71717a;
    
    --border-color: rgba(228, 228, 231, 0.08);
    --border-hover: rgba(99, 102, 241, 0.3);
    
    --color-white: #fff;
    --font-primary: 'Inter', sans-serif;
    --font-mono: 'Space Mono', monospace;

    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-pill: 50px;

    --color-success: #4ade80;
    --color-success-bg: rgba(74, 222, 128, 0.08);
    --color-success-border: rgba(74, 222, 128, 0.2);

    /* Theme-aware surface helpers (dark defaults) */
    --nav-bg: rgba(15, 15, 20, 0.7);
    --nav-bg-scrolled: rgba(15, 15, 20, 0.95);
    --nav-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    --dot-color: rgba(228, 228, 231, 0.04);
    --grad-1: rgba(99, 102, 241, 0.08);
    --grad-2: rgba(139, 92, 246, 0.06);
    --card-shadow: 0 8px 30px rgba(0, 0, 0, 0.4);
    color-scheme: dark;
}

/* ============================================
   LIGHT THEME
   ============================================ */
html[data-theme="light"] {
    --bg-primary: #f6f7fb;
    --bg-secondary: #ffffff;
    --bg-tertiary: #eef0f7;
    --bg-elevated: #e6e8f2;

    --text-primary: #1b1d29;
    --text-secondary: #4b4f63;
    --text-muted: #6b7280;

    --border-color: rgba(20, 22, 40, 0.10);
    --border-hover: rgba(99, 102, 241, 0.45);

    --nav-bg: rgba(255, 255, 255, 0.72);
    --nav-bg-scrolled: rgba(255, 255, 255, 0.92);
    --nav-shadow: 0 4px 18px rgba(20, 22, 40, 0.10);
    --dot-color: rgba(30, 32, 55, 0.05);
    --grad-1: rgba(99, 102, 241, 0.10);
    --grad-2: rgba(139, 92, 246, 0.08);
    --card-shadow: 0 8px 30px rgba(20, 22, 40, 0.10);
    color-scheme: light;
}

body {
    transition: background 0.35s ease, color 0.35s ease;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-primary);
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.7;
    font-weight: 400;
    overflow-x: hidden;
}

/* Background */
.bg-gradient {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(ellipse at top, var(--grad-1) 0%, transparent 60%),
                radial-gradient(ellipse at bottom right, var(--grad-2) 0%, transparent 50%);
    pointer-events: none;
    z-index: 0;
}

.bg-dots {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: radial-gradient(circle, var(--dot-color) 1px, transparent 1px);
    background-size: 32px 32px;
    pointer-events: none;
    z-index: 0;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 40px;
    position: relative;
    z-index: 2;
}

/* Navigation - CENTERED, NO NAME */
.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    padding: 16px 40px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 24px;
    z-index: 1000;
    backdrop-filter: blur(16px) saturate(180%);
    background: var(--nav-bg);
    border-bottom: 1px solid var(--border-color);
    transition: background 0.3s ease, box-shadow 0.3s ease;
}

.nav-actions {
    position: absolute;
    right: 40px;
    top: 50%;
    transform: translateY(-50%);
}

.nav.scrolled {
    background: var(--nav-bg-scrolled);
    box-shadow: var(--nav-shadow);
}

.nav-links {
    display: flex;
    gap: 36px;
    align-items: center;
}

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

.nav-link, .nav-link-cta {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 15px;
    font-weight: 500;
    transition: color 0.3s ease;
}

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

.nav-link-cta {
    padding: 8px 20px;
    background: var(--bg-tertiary);
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-color);
}

.nav-link-cta:hover {
    background: var(--bg-elevated);
    border-color: var(--border-hover);
    color: var(--text-primary);
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: 100px 0;
}

.hero-grid {
    display: grid;
    grid-template-columns: 3fr 2fr;
    gap: 80px;
    align-items: center;
}

.hero-label {
    display: inline-block;
    font-family: var(--font-mono);
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: var(--accent-primary);
    margin-bottom: 24px;
    padding: 6px 12px;
    background: rgba(99, 102, 241, 0.1);
    border-radius: 6px;
}

.hero-title {
    font-size: clamp(42px, 7vw, 64px);
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: -1.5px;
    margin-bottom: 28px;
}

.hero-subtitle {
    font-size: 19px;
    line-height: 1.7;
    color: var(--text-secondary);
    margin-bottom: 40px;
}

.hero-cta {
    display: flex;
    gap: 16px;
}

.hero-image {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

/* Profile Image - 320px */
.profile-wrapper {
    position: relative;
    width: 320px;
    height: 320px;
    border-radius: 50%;
    overflow: hidden;
    border: 4px solid var(--accent-primary);
    box-shadow: 0 20px 60px rgba(99, 102, 241, 0.4);
    animation: float 6s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-20px); }
}

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

.profile-glow {
    position: absolute;
    inset: -30px;
    background: radial-gradient(circle, rgba(99, 102, 241, 0.5), transparent 70%);
    filter: blur(40px);
    z-index: -1;
    animation: pulse 4s ease-in-out infinite;
}

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

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 28px;
    font-size: 15px;
    font-weight: 500;
    text-decoration: none;
    border-radius: var(--radius-sm);
    transition: all 0.3s ease;
    cursor: pointer;
    border: none;
}

.btn-primary {
    background: var(--accent-primary);
    color: var(--color-white);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
}

.btn-primary:hover {
    background: var(--accent-hover);
    transform: translateY(-2px);
}

.btn-secondary {
    background: var(--bg-tertiary);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

.btn-secondary:hover {
    background: var(--bg-elevated);
    border-color: var(--border-hover);
}

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

.btn-outline:hover {
    border-color: var(--accent-primary);
    background: rgba(99, 102, 241, 0.05);
}

.btn-large {
    padding: 16px 32px;
    font-size: 16px;
}

/* Sections */
section {
    padding: 100px 0;
}

.section-header {
    margin-bottom: 48px;
}

.section-label {
    display: inline-block;
    font-family: var(--font-mono);
    font-size: 12px;
    letter-spacing: 1px;
    text-transform: uppercase;
    color: var(--accent-primary);
    margin-bottom: 12px;
}

.section-title {
    font-size: clamp(32px, 5vw, 44px);
    font-weight: 700;
    line-height: 1.3;
    letter-spacing: -1px;
}

/* About Section */
.about-grid {
    display: grid;
    grid-template-columns: 3fr 2fr;
    gap: 64px;
}

.about-content p {
    font-size: 17px;
    color: var(--text-secondary);
    margin-bottom: 20px;
    line-height: 1.8;
}

.about-content .lead {
    font-size: 20px;
    color: var(--text-primary);
    font-weight: 500;
    margin-bottom: 28px;
}

.about-list {
    list-style: none;
    margin: 24px 0;
}

.about-list li {
    padding: 10px 0 10px 28px;
    position: relative;
    color: var(--text-secondary);
}

.about-list li::before {
    content: '→';
    position: absolute;
    left: 0;
    color: var(--accent-primary);
    font-weight: 600;
}

.highlight {
    color: var(--text-primary);
    font-weight: 500;
}

.about-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-content: start;
}

.stat-card {
    display: flex;
    align-items: center;
    gap: 12px;
    background: rgba(99, 102, 241, 0.04);
    padding: 14px 18px 14px 14px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-color);
    border-left: 3px solid var(--accent-primary);
    transition: all 0.3s ease;
    width: fit-content;
}

.stat-card:hover {
    transform: translateY(-4px);
    border-color: var(--border-hover);
    border-left-color: var(--accent-primary);
    background: rgba(99, 102, 241, 0.08);
}

.stat-icon {
    width: 36px;
    height: 36px;
    border-radius: var(--radius-sm);
    background: rgba(99, 102, 241, 0.15);
    color: var(--accent-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

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

.stat-number {
    font-size: 20px;
    font-weight: 600;
    color: var(--text-primary);
    line-height: 1;
    margin-bottom: 0;
}

.stat-label {
    font-size: 12px;
    font-weight: 500;
    color: var(--text-secondary);
    margin-top: 3px;
    white-space: nowrap;
}

/* Work Section */
.work {
    background: var(--bg-secondary);
}

.project {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
    align-items: center;
    margin-bottom: 80px;
}

.project-reverse {
    grid-template-columns: 1fr 1fr;
}

.project-reverse .project-image-wrapper {
    order: 2;
}

.project-reverse .project-content {
    order: 1;
}

.project-image-wrapper {
    position: relative;
    border-radius: var(--radius-lg);
    overflow: hidden;
    border: 1px solid var(--border-color);
    transition: all 0.3s ease;
}

.project-image-wrapper:hover {
    transform: translateY(-8px);
    border-color: var(--border-hover);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.project-image {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.5s ease;
}

.project-image-wrapper:hover .project-image {
    transform: scale(1.05);
}

.project-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.1), rgba(139, 92, 246, 0.1));
    opacity: 0;
    transition: opacity 0.3s ease;
}

.project-image-wrapper:hover .project-overlay {
    opacity: 1;
}

.project-title {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 16px;
    letter-spacing: -0.5px;
}

.project-description {
    font-size: 16px;
    line-height: 1.7;
    color: var(--text-secondary);
    margin-bottom: 20px;
}

.project-tags {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.tag {
    padding: 6px 14px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-size: 13px;
    color: var(--accent-primary);
    font-weight: 500;
}

.project-tools {
    display: flex;
    gap: 8px;
    margin-bottom: 24px;
    flex-wrap: wrap;
}

.project-tools span {
    padding: 6px 12px;
    background: var(--bg-secondary);
    border-radius: 6px;
    font-size: 12px;
    font-family: var(--font-mono);
    color: var(--text-muted);
}

.project-link, .project-link-secondary {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--accent-primary);
    text-decoration: none;
    font-weight: 500;
    font-size: 15px;
    transition: all 0.3s ease;
}

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

.project-link-secondary {
    color: var(--text-secondary);
    margin-left: 20px;
}

.project-links {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.view-more {
    text-align: center;
    margin-top: 40px;
}

/* Skills Section - Category Cards */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
    margin-bottom: 64px;
}

.skill-cat-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 28px;
    transition: all 0.3s ease;
}

.skill-cat-card:hover {
    border-color: var(--border-hover);
    transform: translateY(-4px);
    box-shadow: 0 12px 32px rgba(99, 102, 241, 0.12);
}

.skill-cat-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
}

.skill-cat-icon {
    width: 40px;
    height: 40px;
    border-radius: var(--radius-sm);
    background: rgba(99, 102, 241, 0.12);
    border: 1px solid rgba(99, 102, 241, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent-primary);
    flex-shrink: 0;
}

.skill-cat-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
    flex: 1;
}

.skill-cat-count {
    font-size: 11px;
    font-family: var(--font-mono);
    color: var(--accent-primary);
    background: rgba(99, 102, 241, 0.08);
    padding: 3px 8px;
    border-radius: 20px;
    border: 1px solid rgba(99, 102, 241, 0.15);
}

.skill-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.skill-pill {
    font-size: 12px;
    font-weight: 500;
    padding: 5px 12px;
    border-radius: 20px;
    background: var(--bg-tertiary);
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
    transition: all 0.2s ease;
}

.skill-pill:hover {
    border-color: var(--border-hover);
    color: var(--text-primary);
    background: var(--bg-elevated);
}

/* Tools Section */
.tools-container {
    margin-top: 12px;
}

.tools-title {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 20px;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 10px;
}

.tools-title::before {
    content: '';
    display: inline-block;
    width: 3px;
    height: 16px;
    background: var(--accent-primary);
    border-radius: 2px;
}

.tools-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}

.tool-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 28px;
    display: flex;
    flex-direction: column;
    gap: 16px;
    transition: all 0.3s ease;
    cursor: default;
}

.tool-card:hover {
    border-color: var(--border-hover);
    transform: translateY(-4px);
    box-shadow: 0 12px 32px rgba(99, 102, 241, 0.12);
}

.tool-icon-wrap {
    width: 40px;
    height: 40px;
    border-radius: var(--radius-sm);
    background: rgba(99, 102, 241, 0.12);
    border: 1px solid rgba(99, 102, 241, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: var(--accent-primary);
}

.tool-name {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-primary);
    display: block;
}

.tool-category {
    font-size: 12px;
    color: var(--text-secondary);
    display: block;
    margin-top: 4px;
}

/* Certifications */
.certifications {
    background: var(--bg-secondary);
}

.cert-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.cert-icon {
    width: 48px;
    height: 48px;
    border-radius: var(--radius-sm);
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent-primary);
}

.cert-badge {
    padding: 6px 12px;
    background: rgba(99, 102, 241, 0.1);
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
    color: var(--accent-primary);
    font-family: var(--font-mono);
}

.cert-org {
    color: var(--accent-primary);
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 12px;
}

.cert-desc {
    font-size: 15px;
    line-height: 1.6;
    color: var(--text-secondary);
    margin-bottom: 12px;
}

.cert-date {
    font-family: var(--font-mono);
    font-size: 12px;
    color: var(--text-muted);
}

/* Contact Section */
.contact-grid {
    display: grid;
    grid-template-columns: 3fr 2fr;
    gap: 32px;
    align-items: stretch;
}

.contact-intro {
    font-size: 16px;
    line-height: 1.7;
    color: var(--text-secondary);
    margin-bottom: 28px;
}

.contact-methods {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 24px;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 18px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    text-decoration: none;
    transition: all 0.3s ease;
    cursor: default;
}

.contact-item:hover {
    border-color: var(--border-hover);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.08);
}

.copy-btn {
    margin-left: auto;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.copy-btn:hover {
    border-color: var(--border-hover);
    color: var(--accent-primary);
    background: rgba(99, 102, 241, 0.08);
}

.copy-btn:focus-visible {
    outline: 2px solid var(--accent-primary);
    outline-offset: 2px;
}

.contact-icon-wrap {
    width: 40px;
    height: 40px;
    background: rgba(99, 102, 241, 0.12);
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent-primary);
    flex-shrink: 0;
}

.contact-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.contact-label {
    display: block;
    font-size: 11px;
    font-weight: 500;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.contact-value {
    display: block;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-primary);
}

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

.social-link {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    text-decoration: none;
    font-weight: 500;
    font-size: 14px;
    transition: all 0.3s ease;
    flex: 1;
    justify-content: center;
}

.social-link:hover {
    border-color: var(--border-hover);
    transform: translateY(-2px);
}

.contact-cta-box {
    background: var(--bg-secondary);
    padding: 28px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    gap: 16px;
    align-self: stretch;
    justify-content: center;
    transition: all 0.3s ease;
}

.contact-cta-box:hover {
    border-color: var(--border-hover);
    box-shadow: 0 12px 32px rgba(99, 102, 241, 0.08);
}

.cta-availability {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 5px 12px;
    background: var(--color-success-bg);
    border: 1px solid var(--color-success-border);
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
    color: var(--color-success);
    width: fit-content;
}

.cta-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--color-success);
    animation: pulse-dot 2s ease-in-out infinite;
}

@keyframes pulse-dot {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.4; }
}

/* CTA badge — same as hero status-badge but fits inside cta-box */
.cta-badge {
    margin-top: 0;
    align-self: flex-start;
}

.cta-title {
    font-size: 22px;
    font-weight: 700;
    color: var(--text-primary);
    letter-spacing: -0.5px;
}

.cta-desc {
    font-size: 15px;
    line-height: 1.6;
    color: var(--text-secondary);
}

/* Footer - SIMPLE ONLY */
.footer {
    background: var(--bg-secondary);
    padding: 40px 0;
    border-top: 1px solid var(--border-color);
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 13px;
    color: var(--text-muted);
}

/* ============================================
   NEW STYLES — Hero additions
   ============================================ */

/* Original Responsive (preserved) */
@media (max-width: 1024px) {
    .hero-grid,
    .about-grid,
    .project,
    .contact-grid {
        grid-template-columns: 1fr;
        gap: 48px;
    }

    .project-reverse .project-image-wrapper,
    .project-reverse .project-content {
        order: initial;
    }

    .skills-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .tools-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .container {
        padding: 0 24px;
    }

    .nav {
        padding: 20px 24px;
    }

    .profile-wrapper {
        width: 280px;
        height: 280px;
    }

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

    .tools-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .footer-bottom {
        flex-direction: column;
        gap: 8px;
        text-align: center;
    }
}

/* ============================================
   NEW STYLES — Hero additions (Badge, Greeting)
   ============================================ */

.status-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: rgba(99, 102, 241, 0.1);
    border: 1px solid rgba(99, 102, 241, 0.3);
    border-radius: var(--radius-pill);
    margin-top: 28px;
    backdrop-filter: blur(8px);
}

.status-dot {
    width: 8px;
    height: 8px;
    background: var(--color-success);
    border-radius: 50%;
    box-shadow: 0 0 8px rgba(74, 222, 128, 0.6);
    animation: status-pulse 2s ease-in-out infinite;
}

.status-badge span:last-child {
    color: var(--accent-primary);
    font-size: 13px;
    font-weight: 500;
    letter-spacing: 0.2px;
}

@keyframes status-pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.6; transform: scale(0.85); }
}

.hero-greeting {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-secondary);
    font-size: 18px;
    margin-bottom: 14px;
}

.hero-name {
    color: var(--text-primary);
    font-weight: 600;
}

.wave-icon {
    color: var(--accent-primary);
    animation: wave 2.5s ease-in-out infinite;
    transform-origin: 70% 70%;
}

@keyframes wave {
    0%, 60%, 100% { transform: rotate(0deg); }
    10%, 30% { transform: rotate(14deg); }
    20% { transform: rotate(-8deg); }
    40% { transform: rotate(-4deg); }
    50% { transform: rotate(10deg); }
}

/* ============================================
   NEW STYLES — About Timeline
   ============================================ */

.timeline-wrapper {
    margin-top: 64px;
    padding-top: 48px;
    border-top: 1px solid var(--border-color);
}

.timeline-title {
    font-size: 22px;
    font-weight: 600;
    margin-bottom: 32px;
    color: var(--text-primary);
}

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

.timeline-item {
    display: flex;
    gap: 20px;
    align-items: stretch;
}

.timeline-marker {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex-shrink: 0;
}

.timeline-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(99, 102, 241, 0.12);
    border: 1px solid var(--accent-primary);
    color: var(--accent-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: all 0.3s ease;
}

.timeline-icon-current {
    background: rgba(99, 102, 241, 0.18);
    border-color: var(--accent-primary);
    color: var(--accent-primary);
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.12);
}

.timeline-line {
    width: 2px;
    flex: 1;
    background: linear-gradient(to bottom, rgba(99, 102, 241, 0.4), rgba(99, 102, 241, 0.1));
    margin-top: 6px;
    min-height: 24px;
}

.timeline-content {
    padding-bottom: 28px;
    flex: 1;
}

.timeline-date {
    font-family: var(--font-mono);
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.8px;
    color: var(--text-muted);
    margin-bottom: 6px;
}

.timeline-date-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 6px;
    flex-wrap: wrap;
}

.timeline-date-current {
    color: var(--accent-primary);
    margin-bottom: 0;
}

.timeline-badge {
    display: inline-flex;
    align-items: center;
    padding: 3px 10px;
    background: rgba(99, 102, 241, 0.15);
    border: 1px solid rgba(99, 102, 241, 0.4);
    border-radius: 6px;
    font-size: 10px;
    font-weight: 600;
    color: var(--accent-primary);
    letter-spacing: 0.5px;
}

.timeline-heading {
    color: var(--text-primary);
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 4px;
}

.timeline-desc {
    color: var(--text-secondary);
    font-size: 14px;
    line-height: 1.5;
}

.timeline-current .timeline-content {
    padding-bottom: 0;
}

/* Timeline Toggle (See My Full Journey) */
.timeline-toggle-wrapper {
    display: flex;
    justify-content: center;
    padding: 18px 0 6px;
    position: relative;
}

.timeline-toggle-btn {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    padding: 11px 22px;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.14), rgba(139, 92, 246, 0.10));
    color: var(--accent-primary);
    border: 1px solid rgba(99, 102, 241, 0.30);
    border-radius: var(--radius-pill);
    font-size: 13.5px;
    font-weight: 600;
    letter-spacing: 0.2px;
    font-family: var(--font-primary);
    cursor: pointer;
    box-shadow: 0 2px 10px rgba(99, 102, 241, 0.12);
    transition: all 0.3s ease;
}

.timeline-toggle-btn:hover {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.22), rgba(139, 92, 246, 0.16));
    border-color: var(--accent-primary);
    transform: translateY(-2px);
    box-shadow: 0 6px 18px rgba(99, 102, 241, 0.22);
}

.timeline-toggle-btn svg {
    transition: transform 0.35s ease;
}

.timeline-toggle-btn[aria-expanded="true"] svg {
    transform: rotate(180deg);
}

/* Smooth expand/collapse for the extra timeline items */
.timeline-extra {
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: max-height 0.5s ease, opacity 0.4s ease;
}

.timeline-extra.open {
    max-height: 1600px;
    opacity: 1;
}

/* When the loader controls animation, ignore the [hidden] attribute */
.timeline-extra[hidden] { display: block; }

.timeline-extra {
    display: flex;
    flex-direction: column;
    gap: 0;
    overflow: hidden;
    animation: timeline-expand 0.4s ease-out;
}

.timeline-extra[hidden] {
    display: none;
}

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

/* ============================================
   NEW STYLES — Certifications redesign
   ============================================ */

.cert-list {
    display: flex;
    flex-direction: column;
    gap: 32px;
}

.cert-extra {
    display: flex;
    flex-direction: column;
    gap: 32px;
    margin-top: 32px;
}

.cert-extra[hidden] {
    display: none;
}

.cert-item {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: center;
    background: var(--bg-tertiary);
    padding: 28px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-color);
    transition: all 0.3s ease;
}

.cert-item:hover {
    transform: translateY(-4px);
    border-color: var(--border-hover);
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.25);
}

.cert-item-reverse .cert-image-wrapper {
    order: 2;
}

.cert-item-reverse .cert-info {
    order: 1;
}

.cert-image-wrapper {
    border-radius: var(--radius-sm);
    overflow: hidden;
    border: 1px solid var(--border-color);
    background: var(--bg-tertiary);
    display: flex;
    align-items: center;
    justify-content: center;
}

.cert-image {
    width: 100%;
    height: auto;
    object-fit: contain;
    display: block;
    transition: transform 0.4s ease;
}

.cert-item:hover .cert-image {
    transform: scale(1.03);
}

.cert-info h3 {
    font-size: 22px;
    font-weight: 600;
    margin: 12px 0 6px;
    color: var(--text-primary);
}

.cert-toggle-wrapper {
    text-align: center;
    margin-top: 40px;
}

.cert-toggle-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    background: transparent;
    color: var(--text-primary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    font-size: 14px;
    font-weight: 500;
    font-family: var(--font-primary);
    cursor: pointer;
    transition: all 0.3s ease;
}

.cert-toggle-btn:hover {
    border-color: var(--accent-primary);
    background: rgba(99, 102, 241, 0.05);
    color: var(--text-primary);
}

.cert-toggle-btn svg {
    transition: transform 0.3s ease;
}

.cert-toggle-btn[aria-expanded="true"] svg {
    transform: rotate(180deg);
}

/* ============================================
   Responsive overrides for new components
   ============================================ */

@media (max-width: 1024px) {
    .cert-item,
    .cert-item-reverse {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .cert-item-reverse .cert-image-wrapper,
    .cert-item-reverse .cert-info {
        order: initial;
    }
}

@media (max-width: 768px) {
    .hero-greeting {
        font-size: 16px;
    }

    .timeline-icon {
        width: 36px;
        height: 36px;
    }

    .timeline-heading {
        font-size: 15px;
    }

    .timeline-desc {
        font-size: 13px;
    }

    .cert-item {
        padding: 20px;
    }
}

/* ============================================
   ACCESSIBILITY & CONSISTENCY FIXES
   ============================================ */

/* Skip Link */
.skip-link {
    position: absolute;
    top: -60px;
    left: 24px;
    background: var(--accent-primary);
    color: var(--color-white);
    padding: 10px 20px;
    border-radius: 0 0 8px 8px;
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
    z-index: 9999;
    transition: top 0.2s ease;
}

.skip-link:focus {
    top: 0;
}

/* Focus States — nav, buttons, links */
.nav-link:focus-visible,
.nav-link-cta:focus-visible {
    outline: 2px solid var(--accent-primary);
    outline-offset: 4px;
    border-radius: 4px;
    color: var(--text-primary);
}

.btn:focus-visible {
    outline: 2px solid var(--accent-primary);
    outline-offset: 3px;
}

.project-link:focus-visible,
.project-link-secondary:focus-visible,
.social-link:focus-visible,
.contact-item:focus-visible,
.cert-toggle-btn:focus-visible,
.timeline-toggle-btn:focus-visible {
    outline: 2px solid var(--accent-primary);
    outline-offset: 3px;
    border-radius: 6px;
}

/* Float animation — reduced movement */
@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-8px); }
}

/* Extra mobile breakpoint for tools grid */
@media (max-width: 480px) {
    .tools-grid {
        grid-template-columns: 1fr;
    }
}

/* Reduced Motion — WCAG 2.1 AA */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

/* Hidden Admin Trigger */
.admin-trigger {
    width: 12px;
    height: 12px;
    background: transparent;
    border: none;
    cursor: default;
    padding: 0;
    opacity: 0;
    pointer-events: all;
}

/* ============================================
   CERT ONGOING PLACEHOLDER
   ============================================ */
.cert-image-wrapper.cert-ongoing {
    min-height: 260px;
    background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-tertiary) 100%);
    position: relative;
    overflow: hidden;
}

.cert-ongoing-wrapper {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cert-ongoing-rings {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cert-ongoing-ring {
    position: absolute;
    border-radius: 50%;
    border: 1.5px solid rgba(99, 102, 241, 0.25);
    animation: cert-ring-pulse 3s ease-in-out infinite;
}

.ring-1 {
    width: 80px; height: 80px;
    animation-delay: 0s;
    border-color: rgba(99, 102, 241, 0.4);
}
.ring-2 {
    width: 140px; height: 140px;
    animation-delay: 0.6s;
    border-color: rgba(99, 102, 241, 0.25);
}
.ring-3 {
    width: 200px; height: 200px;
    animation-delay: 1.2s;
    border-color: rgba(99, 102, 241, 0.12);
}

@keyframes cert-ring-pulse {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.08); opacity: 0.6; }
}

.cert-ongoing-center {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.cert-ongoing-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--accent-primary);
    box-shadow: 0 0 16px rgba(99, 102, 241, 0.6);
    animation: status-pulse 2s ease-in-out infinite;
}

.cert-ongoing-label {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 2px;
    color: var(--accent-primary);
    font-family: var(--font-mono);
}

.cert-badge-ongoing {
    background: rgba(99, 102, 241, 0.12) !important;
    border-color: rgba(99, 102, 241, 0.3) !important;
    color: var(--accent-primary) !important;
}

@media (prefers-reduced-motion: reduce) {
    .cert-ongoing-ring { animation: none; }
    .cert-ongoing-dot { animation: none; }
}

/* ============================================
   CV NAV BUTTON + MODAL
   ============================================ */
/* CV button — primary, prominent (matches "View My Work") */
.nav-link-cv {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: var(--accent-primary);
    border: none;
    border-radius: var(--radius-sm);
    color: var(--color-white);
    font-family: var(--font-primary);
    font-size: 14.5px;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
    transition: background 0.3s ease, transform 0.2s ease, box-shadow 0.3s ease;
}

.nav-link-cv[hidden] { display: none !important; }

.nav-link-cv svg { color: var(--color-white); }

.nav-link-cv:hover {
    background: var(--accent-hover);
    transform: translateY(-2px);
    box-shadow: 0 6px 18px rgba(99, 102, 241, 0.4);
}

.nav-link-cv:focus-visible {
    outline: 2px solid var(--accent-primary);
    outline-offset: 4px;
}

/* Theme toggle */
.theme-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: var(--radius-sm);
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    cursor: pointer;
    transition: background 0.3s ease, color 0.3s ease, border-color 0.3s ease, transform 0.2s ease;
}

.theme-toggle:hover {
    background: var(--bg-elevated);
    border-color: var(--border-hover);
    color: var(--text-primary);
    transform: translateY(-2px);
}

.theme-toggle:focus-visible {
    outline: 2px solid var(--accent-primary);
    outline-offset: 3px;
}

.theme-toggle .icon-sun { display: none; }
.theme-toggle .icon-moon { display: block; }
html[data-theme="light"] .theme-toggle .icon-sun { display: block; }
html[data-theme="light"] .theme-toggle .icon-moon { display: none; }

@media (max-width: 600px) {
    .nav { padding: 12px 14px; gap: 10px; }
    .nav-actions { right: 14px; }
    .nav-links { gap: 14px; }
    .nav-link-cv { padding: 8px 12px; font-size: 13px; }
    .nav-link-cv span { display: none; }
    .theme-toggle { width: 36px; height: 36px; }
}

/* Modal shell */
.cv-modal {
    position: fixed;
    inset: 0;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
}

.cv-modal[hidden] { display: none; }

.cv-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(10, 10, 14, 0.55);
    backdrop-filter: blur(14px) saturate(140%);
    -webkit-backdrop-filter: blur(14px) saturate(140%);
    opacity: 0;
    transition: opacity 0.28s ease;
}

.cv-modal.cv-modal-open .cv-modal-backdrop { opacity: 1; }

.cv-modal-panel {
    position: relative;
    width: min(860px, 100%);
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    background: rgba(31, 31, 40, 0.85);
    border: 1px solid rgba(228, 228, 231, 0.12);
    border-radius: var(--radius-lg);
    box-shadow: 0 24px 80px rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(20px) saturate(160%);
    -webkit-backdrop-filter: blur(20px) saturate(160%);
    overflow: hidden;
    opacity: 0;
    transform: translateY(18px) scale(0.97);
    transition: opacity 0.28s ease, transform 0.28s cubic-bezier(0.16, 1, 0.3, 1);
}

.cv-modal.cv-modal-open .cv-modal-panel {
    opacity: 1;
    transform: translateY(0) scale(1);
}

.cv-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 15px 20px;
    border-bottom: 1px solid var(--border-color);
    background: linear-gradient(180deg, rgba(99,102,241,0.06), transparent);
    flex-shrink: 0;
    position: relative;
}

/* accent underline to tie into the site brand */
.cv-modal-header::after {
    content: "";
    position: absolute;
    left: 20px;
    right: 20px;
    bottom: -1px;
    height: 2px;
    background: linear-gradient(90deg, var(--accent-primary), var(--accent-secondary), transparent);
    border-radius: 2px;
}

.cv-modal-heading {
    display: flex;
    align-items: center;
    gap: 11px;
    min-width: 0;
}

.cv-modal-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    flex-shrink: 0;
    border-radius: var(--radius-sm);
    background: rgba(99, 102, 241, 0.12);
    border: 1px solid rgba(99, 102, 241, 0.25);
    color: var(--accent-primary);
}

.cv-modal-title {
    font-size: 16px;
    font-weight: 600;
    letter-spacing: 0.2px;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.cv-modal-title[hidden] { display: none; }

.cv-modal-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.cv-download-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 16px;
    font-size: 14px;
    text-decoration: none;
}

.cv-modal-close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.cv-modal-close:hover {
    background: var(--bg-elevated);
    color: var(--text-primary);
    border-color: var(--border-hover);
}

.cv-modal-close:focus-visible,
.cv-download-btn:focus-visible {
    outline: 2px solid var(--accent-primary);
    outline-offset: 3px;
}

.cv-modal-body {
    overflow: auto;
    padding: 20px;
    background: rgba(15, 15, 20, 0.35);
    flex: 1;
    min-height: 0;
}

.cv-preview-img {
    display: block;
    width: 100%;
    height: auto;
    border-radius: var(--radius-md);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.4);
    background: #fff;
}

.cv-preview-frame {
    width: 100%;
    height: 70vh;
    border: none;
    border-radius: var(--radius-md);
    background: #fff;
}

.cv-modal-loading {
    text-align: center;
    color: var(--text-muted);
    padding: 48px 0;
    font-size: 14px;
}

/* Modal in light theme */
html[data-theme="light"] .cv-modal-panel {
    background: rgba(255, 255, 255, 0.92);
    border-color: rgba(20, 22, 40, 0.12);
    box-shadow: 0 24px 80px rgba(20, 22, 40, 0.25);
}
html[data-theme="light"] .cv-modal-body { background: rgba(240, 240, 247, 0.6); }
html[data-theme="light"] .cv-modal-backdrop { background: rgba(20, 22, 40, 0.35); }

@media (max-width: 600px) {
    .cv-modal { padding: 12px; }
    .cv-modal-header { flex-wrap: wrap; }
    .cv-modal-actions { width: 100%; justify-content: flex-end; }
    .cv-modal-title { width: 100%; }
    .cv-preview-frame { height: 60vh; }
}

@media (prefers-reduced-motion: reduce) {
    .cv-modal-backdrop,
    .cv-modal-panel { transition: opacity 0.01ms; transform: none; }
}
