/* ===== CSS Variables & Theming ===== */
:root {
    --font-display: 'Syne', sans-serif;
    --font-body: 'Outfit', sans-serif;

    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 20px;
    --radius-full: 9999px;

    --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 0.6s cubic-bezier(0.4, 0, 0.2, 1);

    --container: 1200px;
    --nav-height: 88px;
}

[data-theme="dark"] {
    --bg-primary: #0a0a0f;
    --bg-secondary: #12121a;
    --bg-tertiary: #1a1a26;
    --text-primary: #f0f0f5;
    --text-secondary: #9898a8;
    --text-muted: #6b6b7b;
    --accent: #6366f1;
    --accent-hover: #818cf8;
    --accent-glow: rgba(99, 102, 241, 0.35);
    --gradient-1: #6366f1;
    --gradient-2: #a855f7;
    --gradient-3: #ec4899;
    --glass-bg: rgba(255, 255, 255, 0.04);
    --glass-border: rgba(255, 255, 255, 0.08);
    --shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 20px 60px rgba(0, 0, 0, 0.5);
    --nav-bg: rgba(10, 10, 15, 0.75);
    --nav-bg-solid: rgba(10, 10, 15, 0.95);
}

[data-theme="light"] {
    --bg-primary: #f8f8fc;
    --bg-secondary: #ffffff;
    --bg-tertiary: #eeeef4;
    --text-primary: #12121a;
    --text-secondary: #4a4a5a;
    --text-muted: #7a7a8a;
    --accent: #4f46e5;
    --accent-hover: #6366f1;
    --accent-glow: rgba(79, 70, 229, 0.25);
    --gradient-1: #4f46e5;
    --gradient-2: #9333ea;
    --gradient-3: #db2777;
    --glass-bg: rgba(255, 255, 255, 0.7);
    --glass-border: rgba(0, 0, 0, 0.06);
    --shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 20px 60px rgba(0, 0, 0, 0.12);
    --nav-bg: rgba(248, 248, 252, 0.75);
    --nav-bg-solid: rgba(248, 248, 252, 0.95);
}

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

html {
    scroll-behavior: smooth;
    scroll-padding-top: var(--nav-height);
}

body {
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 1.7;
    color: var(--text-primary);
    background: transparent;
    overflow-x: hidden;
    transition: background var(--transition), color var(--transition);
}

body.page-loading { opacity: 0; }
body.page-loaded { opacity: 1; transition: opacity 0.6s ease; }

img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--accent-hover); }
ul { list-style: none; }

.container {
    width: 100%;
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 24px;
}

.skip-link {
    position: absolute;
    top: -100%;
    left: 16px;
    z-index: 10000;
    padding: 12px 20px;
    background: var(--accent);
    color: #fff;
    border-radius: var(--radius-sm);
    font-weight: 600;
}
.skip-link:focus { top: 16px; }

/* ===== Typography ===== */
.section-label {
    display: inline-block;
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--accent);
    margin-bottom: 12px;
}

.section-title {
    font-family: var(--font-display);
    font-size: clamp(2rem, 5vw, 3rem);
    font-weight: 700;
    line-height: 1.15;
    margin-bottom: 16px;
}

.section-subtitle {
    color: var(--text-secondary);
    max-width: 560px;
    margin: 0 auto;
}

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

.section {
    padding: 100px 0;
    position: relative;
    content-visibility: auto;
    contain-intrinsic-size: auto 600px;
}

.hero {
    content-visibility: visible;
    contain-intrinsic-size: auto 100vh;
}

/* ===== Glass Card ===== */
.glass-card {
    background: var(--glass-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
}

.glass-card:hover {
    border-color: rgba(99, 102, 241, 0.2);
    box-shadow: var(--shadow-lg);
}

/* ===== Buttons ===== */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 14px 28px;
    font-family: var(--font-body);
    font-size: 0.95rem;
    font-weight: 600;
    border-radius: var(--radius-full);
    border: 2px solid transparent;
    cursor: pointer;
    transition: all var(--transition);
    position: relative;
    overflow: hidden;
}

.btn-primary {
    background: linear-gradient(135deg, var(--gradient-1), var(--gradient-2));
    color: #fff;
    box-shadow: 0 4px 20px var(--accent-glow);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px var(--accent-glow);
    color: #fff;
}

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

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

/* ===== Navbar — Glass Pill ===== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 16px 20px 0;
    background: transparent;
    border: none;
    height: auto;
    pointer-events: none;
}

.nav-pill {
    pointer-events: auto;
    max-width: 980px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 8px 10px 8px 22px;
    border-radius: var(--radius-full);
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(24px) saturate(160%);
    -webkit-backdrop-filter: blur(24px) saturate(160%);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2), inset 0 1px 0 rgba(255, 255, 255, 0.06);
    transition: background var(--transition), box-shadow var(--transition), border-color var(--transition);
}

.navbar.scrolled .nav-pill {
    background: rgba(10, 10, 15, 0.82);
    border-color: rgba(255, 255, 255, 0.12);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

[data-theme="light"] .nav-pill {
    background: rgba(255, 255, 255, 0.65);
    border-color: rgba(0, 0, 0, 0.08);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

[data-theme="light"] .navbar.scrolled .nav-pill {
    background: rgba(255, 255, 255, 0.92);
}

.nav-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 100%;
}

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

.nav-brand {
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--accent);
    padding: 4px 10px;
    border-radius: var(--radius-full);
    background: rgba(99, 102, 241, 0.12);
    border: 1px solid rgba(99, 102, 241, 0.2);
}

.logo-bracket { color: var(--accent); }

.nav-menu {
    display: flex;
    align-items: center;
    gap: 8px;
}

.nav-link {
    padding: 8px 14px;
    color: var(--text-secondary);
    font-size: 0.875rem;
    font-weight: 500;
    border-radius: var(--radius-full);
    transition: color var(--transition), background var(--transition);
    position: relative;
}

.nav-link::after { display: none; }

.nav-link:hover, .nav-link.active {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.08);
}

.nav-link.active {
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.06);
}

.nav-cta {
    background: var(--accent);
    color: #fff !important;
    border-radius: var(--radius-full);
    padding: 8px 20px;
}

.nav-cta::after { display: none; }
.nav-cta:hover { background: var(--accent-hover); transform: translateY(-1px); }

.theme-toggle {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    color: var(--text-primary);
    width: 42px;
    height: 42px;
    border-radius: var(--radius-full);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-left: 12px;
    transition: all var(--transition);
}

.theme-toggle:hover {
    border-color: var(--accent);
    color: var(--accent);
}

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

.nav-toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--text-primary);
    transition: all var(--transition);
}

/* ===== Site-wide Video Background ===== */
.site-video-wrap {
    position: fixed;
    inset: 0;
    z-index: -2;
    overflow: hidden;
    background: var(--bg-primary) url('../images/hero-poster.jpg') center/cover no-repeat;
}

.site-video {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transition: opacity 1s ease;
}

.site-video.is-ready { opacity: 1; }

.site-video-overlay {
    position: absolute;
    inset: 0;
    background:
        rgba(10, 10, 15, 0.78),
        radial-gradient(ellipse 70% 50% at 50% 0%, rgba(99, 102, 241, 0.12), transparent),
        radial-gradient(ellipse 60% 40% at 80% 100%, rgba(168, 85, 247, 0.08), transparent);
    pointer-events: none;
}

[data-theme="light"] .site-video-overlay {
    background:
        rgba(248, 248, 252, 0.88),
        radial-gradient(ellipse 70% 50% at 50% 0%, rgba(79, 70, 229, 0.08), transparent);
}

#main-content,
.footer,
.navbar { position: relative; z-index: 1; }

/* ===== Hero ===== */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    padding-top: var(--nav-height);
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    padding: 80px 24px;
}

.hero-greeting {
    font-size: 1.1rem;
    color: var(--accent);
    font-weight: 500;
    margin-bottom: 8px;
}

.hero-name {
    font-family: var(--font-display);
    font-size: clamp(2.5rem, 8vw, 5rem);
    font-weight: 800;
    line-height: 1.05;
    background: linear-gradient(135deg, var(--text-primary) 30%, var(--accent));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 4px;
}

.hero-brand {
    font-size: 0.95rem;
    font-weight: 600;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--accent);
    margin-bottom: 16px;
}

.hero-role {
    font-family: var(--font-display);
    font-size: clamp(1.25rem, 3vw, 2rem);
    font-weight: 600;
    color: var(--text-secondary);
    min-height: 2.5em;
    margin-bottom: 24px;
}

.typing-cursor {
    color: var(--accent);
    animation: blink 1s step-end infinite;
}

.hero-tagline {
    font-size: 1.15rem;
    color: var(--text-secondary);
    max-width: 580px;
    margin: 0 auto 40px;
}

.hero-actions {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 40px;
}

.hero-social {
    display: flex;
    gap: 16px;
    justify-content: center;
}

.hero-social a {
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-full);
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    color: var(--text-secondary);
    font-size: 1.1rem;
    transition: all var(--transition);
}

.hero-social a:hover {
    color: var(--accent);
    border-color: var(--accent);
    transform: translateY(-3px);
}

.scroll-indicator {
    position: absolute;
    bottom: 32px;
    left: 50%;
    transform: translateX(-50%);
    animation: bounce 2s infinite;
}

.scroll-mouse {
    display: block;
    width: 24px;
    height: 38px;
    border: 2px solid var(--text-muted);
    border-radius: 12px;
    position: relative;
}

.scroll-mouse::after {
    content: '';
    position: absolute;
    top: 8px;
    left: 50%;
    transform: translateX(-50%);
    width: 4px;
    height: 8px;
    background: var(--accent);
    border-radius: 2px;
    animation: scroll-dot 2s infinite;
}

/* ===== About ===== */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 64px;
    align-items: center;
}

.about-image { position: relative; overflow: hidden; padding: 0; }

.about-image img {
    width: 100%;
    border-radius: var(--radius-lg);
    aspect-ratio: 5/6;
    object-fit: cover;
}

.about-image-accent {
    position: absolute;
    bottom: -20px;
    right: -20px;
    width: 120px;
    height: 120px;
    background: linear-gradient(135deg, var(--gradient-1), var(--gradient-2));
    border-radius: var(--radius-lg);
    z-index: -1;
    opacity: 0.6;
}

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

.about-content p {
    color: var(--text-secondary);
    margin-bottom: 16px;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin-top: 32px;
}

.stat-item {
    padding: 24px;
    text-align: center;
}

.stat-number {
    display: block;
    font-family: var(--font-display);
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--accent);
    line-height: 1;
    margin-bottom: 8px;
}

.stat-label {
    font-size: 0.85rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* ===== Skills ===== */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin-bottom: 48px;
}

.skill-category { padding: 32px; }

.skill-category-title {
    font-family: var(--font-display);
    font-size: 1.15rem;
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    gap: 10px;
}

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

.skill-item { margin-bottom: 20px; }
.skill-item:last-child { margin-bottom: 0; }

.skill-header {
    display: flex;
    justify-content: space-between;
    font-size: 0.9rem;
    margin-bottom: 8px;
}

.skill-percent { color: var(--accent); font-weight: 600; }

.skill-bar {
    height: 6px;
    background: var(--bg-tertiary);
    border-radius: var(--radius-full);
    overflow: hidden;
}

.skill-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--gradient-1), var(--gradient-2));
    border-radius: var(--radius-full);
    transition: width 1.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.skill-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: center;
}

.skill-tag {
    padding: 8px 18px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-full);
    font-size: 0.85rem;
    color: var(--text-secondary);
    transition: all var(--transition);
    cursor: default;
}

.skill-tag:hover {
    border-color: var(--accent);
    color: var(--accent);
    transform: translateY(-2px);
}

/* ===== Projects ===== */
.project-filters {
    display: flex;
    gap: 8px;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 48px;
}

.filter-btn {
    padding: 10px 22px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-full);
    color: var(--text-secondary);
    font-family: var(--font-body);
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all var(--transition);
}

.filter-btn:hover, .filter-btn.active {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 28px;
}

.project-card { overflow: hidden; padding: 0; }
.project-card.hidden { display: none; }

.project-image {
    position: relative;
    overflow: hidden;
    aspect-ratio: 16/10;
}

.project-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-slow);
}

.project-card:hover .project-image img { transform: scale(1.08); }

.project-overlay {
    position: absolute;
    inset: 0;
    background: rgba(10, 10, 15, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    opacity: 0;
    transition: opacity var(--transition);
}

.project-card:hover .project-overlay { opacity: 1; }

.project-link {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--accent);
    color: #fff;
    border-radius: var(--radius-full);
    font-size: 1.1rem;
    transform: translateY(10px);
    transition: all var(--transition);
}

.project-card:hover .project-link { transform: translateY(0); }
.project-link:hover { background: var(--accent-hover); color: #fff; transform: scale(1.1); }

.project-body { padding: 24px; }
.project-body h3 {
    font-family: var(--font-display);
    font-size: 1.15rem;
    margin-bottom: 8px;
}

.project-body p {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 16px;
    line-height: 1.6;
}

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

.project-tag {
    padding: 4px 12px;
    background: var(--bg-tertiary);
    border-radius: var(--radius-full);
    font-size: 0.75rem;
    color: var(--accent);
    font-weight: 500;
}

/* ===== Timeline ===== */
.timeline {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
    padding-left: 40px;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 15px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: linear-gradient(to bottom, var(--gradient-1), var(--gradient-2), transparent);
}

.timeline-item {
    position: relative;
    margin-bottom: 48px;
}

.timeline-item:last-child { margin-bottom: 0; }

.timeline-marker {
    position: absolute;
    left: -40px;
    top: 24px;
    width: 32px;
    height: 32px;
    background: var(--accent);
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 0.75rem;
    box-shadow: 0 0 0 4px var(--bg-primary), 0 0 20px var(--accent-glow);
    z-index: 1;
}

.timeline-content { padding: 28px 32px; }

.timeline-date {
    font-size: 0.85rem;
    color: var(--accent);
    font-weight: 600;
}

.timeline-content h3 {
    font-family: var(--font-display);
    font-size: 1.2rem;
    margin: 8px 0 4px;
}

.timeline-org {
    display: block;
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 12px;
}

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

/* ===== Testimonials ===== */
.t-wrap { max-width: 960px; margin: 0 auto; }

.t-slider { overflow: hidden; }

.t-track {
    display: flex;
    transition: transform 0.55s cubic-bezier(0.22, 1, 0.36, 1);
}

.t-slide { min-width: 100%; flex-shrink: 0; }

.t-card { padding: 0; overflow: hidden; }

.t-card-inner {
    display: grid;
    grid-template-columns: 220px 1fr;
    min-height: 280px;
}

.t-profile {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 32px 24px;
    background: rgba(99, 102, 241, 0.06);
    border-right: 1px solid var(--glass-border);
}

.t-avatar {
    padding: 3px;
    border-radius: var(--radius-full);
    background: linear-gradient(135deg, var(--gradient-1), var(--gradient-2));
    margin-bottom: 16px;
}

.t-avatar img {
    width: 72px;
    height: 72px;
    border-radius: var(--radius-full);
    object-fit: cover;
    border: 3px solid var(--bg-primary);
    display: block;
}

.t-name {
    font-style: normal;
    font-weight: 700;
    font-size: 1.05rem;
    margin-bottom: 4px;
}

.t-role {
    font-size: 0.82rem;
    color: var(--text-secondary);
    margin-bottom: 2px;
}

.t-co {
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--accent);
    margin-bottom: 14px;
}

.t-stars {
    color: #fbbf24;
    font-size: 0.75rem;
    display: flex;
    gap: 3px;
}

.t-body {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 40px 44px;
}

.t-index {
    position: absolute;
    top: 20px;
    right: 28px;
    font-family: var(--font-display);
    font-size: 3rem;
    font-weight: 800;
    line-height: 1;
    color: var(--accent);
    opacity: 0.12;
}

.t-quote {
    font-size: clamp(1.05rem, 2.2vw, 1.25rem);
    line-height: 1.85;
    color: var(--text-primary);
    padding-left: 20px;
    border-left: 3px solid var(--accent);
    margin-bottom: 24px;
}

.t-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    align-self: flex-start;
    font-size: 0.72rem;
    font-weight: 600;
    color: #34d399;
    background: rgba(52, 211, 153, 0.1);
    border: 1px solid rgba(52, 211, 153, 0.2);
    padding: 6px 12px;
    border-radius: var(--radius-full);
}

.t-nav {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-top: 28px;
    padding: 10px 16px;
    border-radius: var(--radius-full);
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

.t-btn {
    width: 40px;
    height: 40px;
    flex-shrink: 0;
    border-radius: var(--radius-full);
    border: 1px solid var(--glass-border);
    background: transparent;
    color: var(--text-primary);
    cursor: pointer;
    transition: all var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
}

.t-btn:hover {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
}

.t-bar {
    flex: 1;
    height: 3px;
    background: var(--bg-tertiary);
    border-radius: var(--radius-full);
    overflow: hidden;
}

.t-bar-fill {
    height: 100%;
    width: 25%;
    background: linear-gradient(90deg, var(--gradient-1), var(--gradient-2));
    transition: width 0.55s ease;
}

.t-count {
    font-family: var(--font-display);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    color: var(--text-muted);
    white-space: nowrap;
}

.t-dots { display: flex; gap: 6px; }

.t-dot {
    width: 8px;
    height: 8px;
    border-radius: var(--radius-full);
    background: var(--text-muted);
    border: none;
    cursor: pointer;
    padding: 0;
    opacity: 0.4;
    transition: all var(--transition);
}

.t-dot.active {
    background: var(--accent);
    width: 24px;
    opacity: 1;
}

@media (max-width: 768px) {
    .t-card-inner { grid-template-columns: 1fr; min-height: auto; }
    .t-profile {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: flex-start;
        text-align: left;
        gap: 12px;
        padding: 24px;
        border-right: none;
        border-bottom: 1px solid var(--glass-border);
    }
    .t-avatar { margin-bottom: 0; }
    .t-avatar img { width: 56px; height: 56px; }
    .t-stars { width: 100%; }
    .t-body { padding: 28px 24px; }
    .t-index { font-size: 2rem; top: 12px; right: 16px; }
    .t-nav { flex-wrap: wrap; border-radius: var(--radius-lg); }
    .t-bar { order: 5; width: 100%; flex: none; }
    .t-count { display: none; }
}

/* ===== Contact ===== */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 32px;
    align-items: start;
}

.contact-card { padding: 32px; margin-bottom: 24px; }
.contact-card h3 {
    font-family: var(--font-display);
    margin-bottom: 24px;
}

.contact-list li {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 16px;
    color: var(--text-secondary);
}

.contact-list i { color: var(--accent); width: 20px; text-align: center; }

.contact-social {
    display: flex;
    gap: 12px;
    margin-top: 24px;
}

.contact-social a {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-full);
    background: var(--bg-tertiary);
    color: var(--text-secondary);
    transition: all var(--transition);
}

.contact-social a:hover { background: var(--accent); color: #fff; }

.contact-map { overflow: hidden; padding: 0; }
.contact-map iframe { width: 100%; height: 200px; border: 0; display: block; }

.contact-form { padding: 40px; }

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

.form-group label {
    display: block;
    font-size: 0.9rem;
    font-weight: 500;
    margin-bottom: 8px;
    color: var(--text-secondary);
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 14px 18px;
    background: var(--bg-tertiary);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-family: var(--font-body);
    font-size: 0.95rem;
    transition: border-color var(--transition), box-shadow var(--transition);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-glow);
}

.form-group textarea { resize: vertical; min-height: 120px; }

.form-error {
    display: block;
    color: #ef4444;
    font-size: 0.8rem;
    margin-top: 6px;
    min-height: 1.2em;
}

.form-status {
    margin-bottom: 16px;
    font-size: 0.9rem;
    min-height: 1.4em;
}

.form-status.success { color: #22c55e; }
.form-status.error { color: #ef4444; }

.hp-field {
    position: absolute;
    left: -9999px;
    opacity: 0;
    height: 0;
    overflow: hidden;
}

/* ===== Footer ===== */
.footer {
    background: rgba(18, 18, 26, 0.75);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-top: 1px solid var(--glass-border);
    padding: 64px 0 0;
}

[data-theme="light"] .footer {
    background: rgba(255, 255, 255, 0.8);
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 48px;
    padding-bottom: 48px;
}

.footer-logo {
    font-family: var(--font-display);
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-primary);
    display: inline-block;
    margin-bottom: 16px;
}

.footer-brand p { color: var(--text-secondary); font-size: 0.9rem; max-width: 300px; }

.footer-links h3, .footer-social h3 {
    font-family: var(--font-display);
    font-size: 0.95rem;
    margin-bottom: 16px;
}

.footer-links li { margin-bottom: 10px; }
.footer-links a { color: var(--text-secondary); font-size: 0.9rem; }
.footer-links a:hover { color: var(--accent); }

.social-row { display: flex; gap: 12px; }
.social-row a {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-full);
    background: var(--bg-tertiary);
    color: var(--text-secondary);
    transition: all var(--transition);
}
.social-row a:hover { background: var(--accent); color: #fff; }

.footer-bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 24px 0;
    border-top: 1px solid var(--glass-border);
}

.footer-bottom p { font-size: 0.85rem; color: var(--text-muted); }

.back-to-top {
    width: 44px;
    height: 44px;
    border-radius: var(--radius-full);
    background: var(--accent);
    color: #fff;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition);
    opacity: 0;
    pointer-events: none;
}

.back-to-top.visible { opacity: 1; pointer-events: auto; }
.back-to-top:hover { background: var(--accent-hover); transform: translateY(-3px); }

/* ===== Custom Cursor ===== */
.cursor-dot, .cursor-ring {
    position: fixed;
    pointer-events: none;
    z-index: 9999;
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.2s, height 0.2s, opacity 0.2s;
}

.cursor-dot {
    width: 6px;
    height: 6px;
    background: var(--accent);
}

.cursor-ring {
    width: 36px;
    height: 36px;
    border: 1.5px solid var(--accent);
    opacity: 0.5;
}

@media (hover: none), (pointer: coarse) {
    .cursor-dot, .cursor-ring { display: none; }
}

/* ===== Responsive ===== */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 3px;
}

@media (max-width: 1024px) {
    .about-grid, .contact-grid { grid-template-columns: 1fr; gap: 40px; }
    .skills-grid, .projects-grid { grid-template-columns: repeat(2, 1fr); }
    .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
    .section { padding: 72px 0; }
    .section-header { margin-bottom: 40px; }

    .nav-toggle { display: flex; }

    .nav-menu {
        position: fixed;
        top: calc(16px + 52px + 10px);
        left: 20px;
        right: 20px;
        background: rgba(10, 10, 15, 0.95);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        flex-direction: column;
        padding: 16px;
        gap: 4px;
        border: 1px solid var(--glass-border);
        border-radius: var(--radius-lg);
        transform: translateY(-20px);
        opacity: 0;
        visibility: hidden;
        transition: opacity var(--transition), transform var(--transition), visibility var(--transition);
        pointer-events: none;
        box-shadow: var(--shadow-lg);
    }

    .nav-menu.open {
        transform: translateY(0);
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
    }

    .nav-link:hover, .nav-link.active { background: rgba(255, 255, 255, 0.08); }

    .nav-link { width: 100%; text-align: center; padding: 12px; }

    .skills-grid, .projects-grid { grid-template-columns: 1fr; }
    .stats-grid { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr; gap: 32px; }

    .timeline { padding-left: 32px; }
    .timeline-marker { left: -32px; }
}

@media (max-width: 480px) {
    .hero-actions { flex-direction: column; align-items: center; }
    .btn { width: 100%; justify-content: center; max-width: 280px; }
    .contact-form { padding: 24px; }
    .nav-brand { display: none; }
}
