/* ============================================
   PREMIUM PORTFOLIO — DESIGN SYSTEM
   Batuhan Alkoç — batualkoc.com
   ============================================ */

/* --- CSS Custom Properties (Dark Theme — Default) --- */
:root {
    /* Colors */
    --primary-color: #0a192f;
    --secondary-color: #112240;
    --accent-color: #64ffda;
    --accent-color-rgb: 100, 255, 218;
    --accent-secondary: #00bfa5;
    --text-color: #ccd6f6;
    --text-secondary-color: #8892b0;
    --header-bg: rgba(10, 25, 47, 0.85);
    --nav-mobile-bg: rgba(10, 25, 47, 0.97);
    --card-bg: rgba(17, 34, 64, 0.5);
    --card-border: rgba(100, 255, 218, 0.1);
    --card-hover-border: rgba(100, 255, 218, 0.3);
    --input-bg: rgba(17, 34, 64, 0.6);
    --input-border: rgba(136, 146, 176, 0.3);
    --shadow-accent: rgba(100, 255, 218, 0.15);

    /* Typography */
    --font-display: 'Syne', sans-serif;
    --font-body: 'DM Sans', sans-serif;
    --font-mono: 'JetBrains Mono', monospace;

    --fs-hero: clamp(3rem, 8vw, 6rem);
    --fs-h1: clamp(2rem, 5vw, 3.5rem);
    --fs-h2: clamp(1.8rem, 4vw, 2.5rem);
    --fs-h3: clamp(1.1rem, 2vw, 1.5rem);
    --fs-body: 1rem;
    --fs-small: 0.875rem;
    --fs-xs: 0.75rem;

    /* Spacing */
    --sp-1: 0.25rem;
    --sp-2: 0.5rem;
    --sp-3: 0.75rem;
    --sp-4: 1rem;
    --sp-6: 1.5rem;
    --sp-8: 2rem;
    --sp-10: 2.5rem;
    --sp-12: 3rem;
    --sp-16: 4rem;
    --sp-20: 5rem;
    --sp-24: 6rem;

    /* Layout */
    --container-max: 1200px;
    --nav-height: 72px;

    /* Easing & Duration */
    --ease-out: cubic-bezier(0.25, 0.46, 0.45, 0.94);
    --ease-out-expo: cubic-bezier(0.19, 1, 0.22, 1);
    --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
    --duration-fast: 200ms;
    --duration-normal: 400ms;
    --duration-slow: 700ms;

    /* Radius */
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --radius-full: 9999px;
}

/* --- Light Theme --- */
[data-theme="light"] {
    --primary-color: #f5f5f7;
    --secondary-color: #e8e8ed;
    --accent-color: #0a7ea4;
    --accent-color-rgb: 10, 126, 164;
    --accent-secondary: #067a9e;
    --text-color: #1d1d1f;
    --text-secondary-color: #424245;
    --header-bg: rgba(245, 245, 247, 0.85);
    --nav-mobile-bg: rgba(245, 245, 247, 0.97);
    --card-bg: rgba(232, 232, 237, 0.6);
    --card-border: rgba(10, 126, 164, 0.1);
    --card-hover-border: rgba(10, 126, 164, 0.3);
    --input-bg: rgba(255, 255, 255, 0.8);
    --input-border: rgba(66, 66, 69, 0.2);
    --shadow-accent: rgba(10, 126, 164, 0.15);
}

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

* {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    background-color: var(--primary-color);
    color: var(--text-color);
    line-height: 1.6;
    overflow-x: hidden;
    transition: background-color var(--duration-normal) ease, color var(--duration-normal) ease;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

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

button {
    font-family: inherit;
    cursor: pointer;
    border: none;
    background: none;
    color: inherit;
}

section {
    padding: 100px 15%;
    position: relative;
}

/* --- Accessibility --- */
.skip-link {
    position: absolute;
    top: -100%;
    left: 16px;
    padding: 8px 16px;
    background: var(--accent-color);
    color: var(--primary-color);
    border-radius: 0 0 var(--radius-sm) var(--radius-sm);
    z-index: 200;
    font-weight: 600;
    text-decoration: none;
    transition: top var(--duration-fast);
}

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

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

*:focus-visible {
    outline: 3px solid var(--accent-color);
    outline-offset: 2px;
}

/* ============================================
   NOISE OVERLAY
   ============================================ */
.noise-overlay {
    position: fixed;
    inset: 0;
    z-index: 9998;
    pointer-events: none;
    opacity: 0.025;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
    background-repeat: repeat;
    background-size: 256px 256px;
}

/* ============================================
   CUSTOM CURSOR
   ============================================ */
@media (pointer: fine) {
    .cursor-outer {
        position: fixed;
        width: 40px;
        height: 40px;
        border: 1.5px solid var(--accent-color);
        border-radius: 50%;
        pointer-events: none;
        z-index: 9997;
        transform: translate(-50%, -50%);
        transition: width 0.2s ease, height 0.2s ease, border-color 0.2s ease, opacity 0.2s ease;
        mix-blend-mode: difference;
        opacity: 0;
    }

    .cursor-inner {
        position: fixed;
        width: 6px;
        height: 6px;
        background: var(--accent-color);
        border-radius: 50%;
        pointer-events: none;
        z-index: 9997;
        transform: translate(-50%, -50%);
        opacity: 0;
    }

    .cursor-outer.visible,
    .cursor-inner.visible {
        opacity: 1;
    }

    .cursor-outer.hover {
        width: 60px;
        height: 60px;
        border-color: rgba(var(--accent-color-rgb), 0.5);
    }
}

@media (pointer: coarse) {
    .cursor-outer,
    .cursor-inner {
        display: none !important;
    }
}

/* ============================================
   PRELOADER
   ============================================ */
.preloader {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    transition: opacity 0.6s ease, visibility 0.6s ease;
}

.preloader__logo-text {
    font-family: var(--font-display);
    font-size: 3rem;
    font-weight: 800;
    color: var(--accent-color);
    letter-spacing: -0.03em;
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid rgba(var(--accent-color-rgb), 0.3);
    border-radius: var(--radius-lg);
    animation: pulse-loader 1.2s ease-in-out infinite;
}

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

.preloader__bar {
    width: 200px;
    height: 2px;
    background: rgba(var(--accent-color-rgb), 0.15);
    border-radius: 2px;
    margin-top: var(--sp-6);
    overflow: hidden;
}

.preloader__bar-fill {
    height: 100%;
    width: 0;
    background: var(--accent-color);
    border-radius: 2px;
    transition: width 0.3s ease;
}

.preloader__text {
    font-family: var(--font-mono);
    font-size: var(--fs-xs);
    color: var(--text-secondary-color);
    margin-top: var(--sp-4);
    letter-spacing: 0.15em;
}

/* ============================================
   HEADER & NAVBAR
   ============================================ */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 18px 15%;
    background-color: var(--header-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 100;
    transition: top 0.35s var(--ease-out), background-color var(--duration-normal) ease;
    border-bottom: 1px solid rgba(var(--accent-color-rgb), 0.05);
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.logo {
    display: flex;
    align-items: center;
    text-decoration: none;
    transition: transform 0.3s ease;
    flex-shrink: 0;
}

.logo:hover {
    transform: scale(1.05);
}

.logo-img {
    height: 40px;
    width: auto;
    transition: transform 0.3s ease;
}

.logo-img-light {
    display: none;
}

[data-theme="light"] .logo-img-dark {
    display: none;
}

[data-theme="light"] .logo-img-light {
    display: block;
}

.nav-links {
    list-style: none;
    display: flex;
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    gap: var(--sp-1);
}

.nav-link {
    color: var(--text-secondary-color);
    text-decoration: none;
    font-size: var(--fs-small);
    font-weight: 500;
    padding: var(--sp-2) var(--sp-4);
    border-radius: var(--radius-full);
    transition: color var(--duration-fast) ease, background var(--duration-fast) ease;
    letter-spacing: 0.02em;
    position: relative;
}

.nav-link:hover,
.nav-link.active {
    color: var(--accent-color);
    background: rgba(var(--accent-color-rgb), 0.08);
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: var(--sp-3);
}

/* Theme Toggle */
.theme-toggle {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary-color);
    transition: color var(--duration-fast) ease, background var(--duration-fast) ease;
}

.theme-toggle:hover {
    color: var(--accent-color);
    background: rgba(var(--accent-color-rgb), 0.1);
}

.icon-moon {
    display: none;
}

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

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

/* Mobile Menu Toggle */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
    padding: 6px;
    gap: 5px;
    width: 36px;
    height: 36px;
    justify-content: center;
    align-items: center;
    border-radius: var(--radius-sm);
    transition: background var(--duration-fast) ease;
}

.mobile-menu-toggle:hover {
    background: rgba(var(--accent-color-rgb), 0.1);
}

.mobile-menu-toggle span {
    width: 22px;
    height: 2px;
    background-color: var(--text-color);
    transition: transform 0.3s ease, opacity 0.3s ease;
    border-radius: 2px;
    display: block;
}

.mobile-menu-toggle.active span:nth-child(1) {
    transform: rotate(-45deg) translate(-4px, 5px);
}

.mobile-menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.mobile-menu-toggle.active span:nth-child(3) {
    transform: rotate(45deg) translate(-4px, -5px);
}

/* Language Switcher (PHP version) */
.lang-switcher {
    display: flex;
    gap: 2px;
    background: rgba(var(--accent-color-rgb), 0.05);
    border-radius: var(--radius-full);
    padding: 2px;
    border: 1px solid rgba(var(--accent-color-rgb), 0.1);
}

.lang-switcher__link {
    font-family: var(--font-mono);
    font-size: var(--fs-xs);
    font-weight: 500;
    padding: 4px 10px;
    border-radius: var(--radius-full);
    color: var(--text-secondary-color);
    text-decoration: none;
    transition: all var(--duration-fast) ease;
    letter-spacing: 0.05em;
}

.lang-switcher__link:hover {
    color: var(--accent-color);
}

.lang-switcher__link.active {
    background: rgba(var(--accent-color-rgb), 0.15);
    color: var(--accent-color);
}

/* Certifications section (reuses skill-card styles) */
.cert-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: var(--sp-6);
    max-width: 1100px;
    margin: 0 auto;
}

/* ============================================
   HERO SECTION
   ============================================ */
.hero {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    text-align: center;
    position: relative;
    overflow: hidden;
    padding-top: 80px;
    background: var(--primary-color);
}

.hero__canvas {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
}

.hero__grid {
    position: absolute;
    inset: 0;
    z-index: 1;
    background-image:
        linear-gradient(rgba(var(--accent-color-rgb), 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(var(--accent-color-rgb), 0.03) 1px, transparent 1px);
    background-size: 60px 60px;
    mask-image: radial-gradient(ellipse 70% 60% at 50% 50%, black 20%, transparent 100%);
    -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 50%, black 20%, transparent 100%);
}

.hero-content {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    max-width: 900px;
    padding: 0 var(--sp-4);
}

/* Profile Photo */
.hero__photo-wrapper {
    position: relative;
    margin-bottom: var(--sp-8);
}

.profile-photo {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    border: 3px solid rgba(var(--accent-color-rgb), 0.4);
    object-fit: cover;
    box-shadow:
        0 0 40px rgba(var(--accent-color-rgb), 0.15),
        0 0 80px rgba(var(--accent-color-rgb), 0.05);
    transition: transform 0.4s var(--ease-out), box-shadow 0.4s var(--ease-out);
    position: relative;
    z-index: 1;
}

.profile-photo:hover {
    transform: scale(1.05);
    box-shadow:
        0 0 50px rgba(var(--accent-color-rgb), 0.25),
        0 0 100px rgba(var(--accent-color-rgb), 0.1);
}

/* Hero Name */
.hero__name {
    font-family: var(--font-display);
    font-size: var(--fs-hero);
    font-weight: 800;
    line-height: 1.05;
    letter-spacing: -0.03em;
    margin-bottom: var(--sp-4);
    background: linear-gradient(135deg, var(--text-color) 0%, var(--accent-color) 50%, var(--text-color) 100%);
    background-size: 200% auto;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: gradient-shift 4s ease infinite;
}

@keyframes gradient-shift {
    0%, 100% { background-position: 0% center; }
    50% { background-position: 100% center; }
}

/* Hero Job Title — Typing Effect */
.hero-job-title {
    font-family: var(--font-body);
    font-size: clamp(1rem, 2.5vw, 1.4rem);
    color: var(--text-secondary-color);
    margin-bottom: var(--sp-4);
    font-weight: 400;
    min-height: 1.8em;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 2px;
}

.typing-cursor {
    display: inline-block;
    color: var(--accent-color);
    font-weight: 300;
    animation: blink 1s step-end infinite;
}

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

/* Hero Subtitle Tags */
.hero-subtitle {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: var(--sp-2);
    margin-bottom: var(--sp-10);
}

.hero-subtitle__tag {
    font-family: var(--font-mono);
    font-size: var(--fs-xs);
    color: var(--accent-color);
    letter-spacing: 0.1em;
    font-weight: 500;
    padding: var(--sp-1) var(--sp-3);
    border: 1px solid rgba(var(--accent-color-rgb), 0.2);
    border-radius: var(--radius-full);
    background: rgba(var(--accent-color-rgb), 0.05);
}

.hero-subtitle__dot {
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: rgba(var(--accent-color-rgb), 0.4);
    display: none;
}

/* Hero Buttons */
.hero-buttons {
    display: flex;
    justify-content: center;
    gap: var(--sp-4);
    margin-bottom: var(--sp-10);
}

/* Buttons — Global */
.btn {
    display: inline-flex;
    align-items: center;
    gap: var(--sp-2);
    padding: 14px 28px;
    border-radius: var(--radius-sm);
    font-size: var(--fs-small);
    font-weight: 600;
    font-family: var(--font-body);
    text-decoration: none;
    transition: all 0.3s var(--ease-out);
    position: relative;
    overflow: hidden;
    border: none;
    cursor: pointer;
    letter-spacing: 0.02em;
}

.btn--primary {
    background: var(--accent-color);
    color: var(--primary-color);
}

.btn--primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(var(--accent-color-rgb), 0.3);
}

.btn--outline {
    background: transparent;
    color: var(--accent-color);
    border: 2px solid rgba(var(--accent-color-rgb), 0.4);
}

.btn--outline:hover {
    border-color: var(--accent-color);
    background: rgba(var(--accent-color-rgb), 0.08);
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(var(--accent-color-rgb), 0.15);
}

.btn__icon {
    transition: transform 0.3s ease;
    flex-shrink: 0;
}

.btn--primary:hover .btn__icon {
    transform: translateX(4px);
}

.btn__icon--left {
    order: -1;
}

.btn--outline:hover .btn__icon--left {
    transform: translateY(2px);
}

/* Social Links */
.social-links {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: var(--sp-4);
}

.social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary-color);
    text-decoration: none;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: var(--card-bg);
    backdrop-filter: blur(10px);
    border: 1px solid var(--card-border);
    transition: all 0.3s var(--ease-out);
}

.social-link:hover {
    color: var(--accent-color);
    background: rgba(var(--accent-color-rgb), 0.1);
    border-color: var(--card-hover-border);
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(var(--accent-color-rgb), 0.15);
}

.social-icon {
    width: 22px;
    height: 22px;
    display: block;
    fill: currentColor;
    transition: transform 0.3s ease;
}

.social-link:hover .social-icon {
    transform: scale(1.1);
}

/* Scroll Indicator */
.scroll-indicator {
    position: absolute;
    bottom: 32px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--sp-2);
    z-index: 2;
    opacity: 0.6;
    transition: opacity 0.3s ease;
}

.scroll-indicator:hover {
    opacity: 1;
}

.scroll-indicator__text {
    font-family: var(--font-mono);
    font-size: 0.65rem;
    letter-spacing: 0.3em;
    color: var(--text-secondary-color);
}

.scroll-indicator__line {
    width: 1px;
    height: 40px;
    background: linear-gradient(to bottom, var(--accent-color), transparent);
    animation: scroll-line 2s ease-in-out infinite;
}

@keyframes scroll-line {
    0% { transform: scaleY(0); transform-origin: top; opacity: 1; }
    50% { transform: scaleY(1); transform-origin: top; opacity: 1; }
    50.01% { transform: scaleY(1); transform-origin: bottom; }
    100% { transform: scaleY(0); transform-origin: bottom; opacity: 1; }
}

/* ============================================
   SECTION TITLE
   ============================================ */
.section-title {
    font-family: var(--font-display);
    font-size: var(--fs-h2);
    font-weight: 700;
    color: var(--text-color);
    margin-bottom: var(--sp-16);
    text-align: center;
    position: relative;
    letter-spacing: -0.02em;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -12px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, transparent, var(--accent-color), transparent);
    border-radius: 3px;
}

/* ============================================
   ABOUT SECTION
   ============================================ */
.about-section {
    background-color: var(--secondary-color);
}

.about-layout {
    max-width: 1000px;
    margin: 0 auto;
}

.about-content {
    display: grid;
    gap: var(--sp-8);
    margin-bottom: var(--sp-16);
}

.about-block {
    position: relative;
    padding-left: var(--sp-6);
    border-left: 2px solid rgba(var(--accent-color-rgb), 0.2);
}

.about-block h3 {
    font-family: var(--font-display);
    font-size: var(--fs-h3);
    color: var(--accent-color);
    margin-bottom: var(--sp-3);
    font-weight: 600;
}

.about-text {
    font-size: var(--fs-body);
    color: var(--text-secondary-color);
    line-height: 1.8;
}

/* Stats */
.about-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: var(--sp-6);
}

.stat-card {
    text-align: center;
    padding: var(--sp-8) var(--sp-4);
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: var(--radius-lg);
    backdrop-filter: blur(10px);
    transition: transform 0.3s var(--ease-out), border-color 0.3s ease;
}

.stat-card:hover {
    transform: translateY(-4px);
    border-color: var(--card-hover-border);
}

.stat-card__number {
    font-family: var(--font-display);
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 800;
    color: var(--accent-color);
    line-height: 1;
    display: inline;
}

.stat-card__suffix {
    font-family: var(--font-display);
    font-size: clamp(1.5rem, 3vw, 2rem);
    font-weight: 700;
    color: var(--accent-color);
}

.stat-card__label {
    display: block;
    font-family: var(--font-mono);
    font-size: var(--fs-xs);
    color: var(--text-secondary-color);
    margin-top: var(--sp-2);
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

/* ============================================
   EXPERIENCE SECTION — TIMELINE
   ============================================ */
.experience-section {
    background-color: var(--primary-color);
}

.timeline {
    position: relative;
    max-width: 900px;
    margin: 0 auto;
}

.timeline::after {
    content: '';
    position: absolute;
    width: 2px;
    background: linear-gradient(to bottom, var(--accent-color), rgba(var(--accent-color-rgb), 0.1));
    top: 0;
    bottom: 0;
    left: 50%;
    margin-left: -1px;
}

.timeline-item {
    padding: var(--sp-4) 0;
    position: relative;
    width: 50%;
}

.timeline-item:nth-child(odd) {
    left: 0;
    padding-right: var(--sp-12);
}

.timeline-item:nth-child(even) {
    left: 50%;
    padding-left: var(--sp-12);
}

/* Timeline dot */
.timeline-item::after {
    content: '';
    position: absolute;
    width: 14px;
    height: 14px;
    background-color: var(--primary-color);
    border: 3px solid var(--accent-color);
    top: 32px;
    border-radius: 50%;
    z-index: 1;
    transition: background-color 0.3s ease, box-shadow 0.3s ease;
}

.timeline-item:nth-child(odd)::after {
    right: -8px;
}

.timeline-item:nth-child(even)::after {
    left: -8px;
}

.timeline-item:hover::after {
    background-color: var(--accent-color);
    box-shadow: 0 0 15px rgba(var(--accent-color-rgb), 0.4);
}

.timeline-item__card {
    padding: var(--sp-6);
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: var(--radius-md);
    backdrop-filter: blur(10px);
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.timeline-item:hover .timeline-item__card {
    border-color: var(--card-hover-border);
    box-shadow: 0 8px 32px rgba(var(--accent-color-rgb), 0.08);
}

.timeline-item__card h3 {
    font-family: var(--font-display);
    font-size: var(--fs-h3);
    color: var(--accent-color);
    margin-bottom: var(--sp-1);
    font-weight: 600;
}

.timeline-item__card h4 {
    font-size: var(--fs-body);
    color: var(--text-color);
    margin-bottom: var(--sp-2);
    font-weight: 500;
}

.timeline-item__date {
    display: inline-block;
    font-family: var(--font-mono);
    font-size: var(--fs-xs);
    color: var(--text-secondary-color);
    margin-bottom: var(--sp-3);
    letter-spacing: 0.1em;
    padding: var(--sp-1) var(--sp-3);
    background: rgba(var(--accent-color-rgb), 0.06);
    border-radius: var(--radius-full);
}

.timeline-item__card p {
    color: var(--text-secondary-color);
    font-size: var(--fs-small);
    line-height: 1.7;
}

.timeline-item:nth-child(odd) .timeline-item__card {
    text-align: right;
}

/* ============================================
   SKILLS SECTION
   ============================================ */
.skills-section {
    background-color: var(--secondary-color);
}

.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: var(--sp-6);
    max-width: 1100px;
    margin: 0 auto;
}

.skill-card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    padding: var(--sp-8);
    border-radius: var(--radius-lg);
    backdrop-filter: blur(10px);
    transition: all 0.4s var(--ease-out);
    position: relative;
    overflow: hidden;
}

.skill-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--accent-color), transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.skill-card:hover::before {
    opacity: 1;
}

.skill-card:hover {
    transform: translateY(-6px);
    border-color: var(--card-hover-border);
    box-shadow: 0 16px 40px rgba(var(--accent-color-rgb), 0.1);
}

.skill-card__icon {
    color: var(--accent-color);
    margin-bottom: var(--sp-4);
    opacity: 0.8;
}

.skill-card h3 {
    font-family: var(--font-display);
    font-size: var(--fs-h3);
    color: var(--text-color);
    margin-bottom: var(--sp-4);
    font-weight: 600;
}

.skill-card__tags {
    display: flex;
    flex-wrap: wrap;
    gap: var(--sp-2);
}

.skill-tag {
    font-family: var(--font-mono);
    font-size: var(--fs-xs);
    color: var(--text-secondary-color);
    padding: var(--sp-1) var(--sp-3);
    background: rgba(var(--accent-color-rgb), 0.06);
    border: 1px solid rgba(var(--accent-color-rgb), 0.1);
    border-radius: var(--radius-full);
    transition: all 0.2s ease;
    letter-spacing: 0.02em;
}

.skill-card:hover .skill-tag {
    border-color: rgba(var(--accent-color-rgb), 0.2);
    color: var(--accent-color);
}

/* ============================================
   CONTACT SECTION
   ============================================ */
.contact-section {
    background-color: var(--primary-color);
}

.contact-layout {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: var(--sp-16);
    max-width: 1000px;
    margin: 0 auto;
    align-items: start;
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: var(--sp-8);
}

.contact-info__item {
    display: flex;
    align-items: flex-start;
    gap: var(--sp-4);
}

.contact-info__icon {
    width: 48px;
    height: 48px;
    border-radius: var(--radius-md);
    background: rgba(var(--accent-color-rgb), 0.08);
    border: 1px solid var(--card-border);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent-color);
    flex-shrink: 0;
}

.contact-info__label {
    display: block;
    font-family: var(--font-mono);
    font-size: var(--fs-xs);
    color: var(--text-secondary-color);
    letter-spacing: 0.1em;
    text-transform: uppercase;
    margin-bottom: var(--sp-1);
}

.contact-info__value {
    color: var(--text-color);
    font-size: var(--fs-body);
    font-weight: 500;
    transition: color 0.2s ease;
}

a.contact-info__value:hover {
    color: var(--accent-color);
}

/* Contact Form */
.contact-form {
    display: flex;
    flex-direction: column;
    gap: var(--sp-6);
}

.form-group {
    position: relative;
}

.contact-form input,
.contact-form textarea {
    width: 100%;
    padding: 16px 18px;
    background: var(--input-bg);
    border: 1px solid var(--input-border);
    border-radius: var(--radius-md);
    color: var(--text-color);
    font-family: var(--font-body);
    font-size: var(--fs-body);
    transition: border-color 0.3s ease, box-shadow 0.3s ease, background 0.3s ease;
}

.contact-form input:focus,
.contact-form textarea:focus {
    outline: none;
    border-color: var(--accent-color);
    box-shadow: 0 0 0 3px rgba(var(--accent-color-rgb), 0.1);
    background: rgba(var(--accent-color-rgb), 0.02);
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
    color: var(--text-secondary-color);
    opacity: 0.7;
}

.contact-form textarea {
    resize: vertical;
    min-height: 150px;
}

.g-recaptcha {
    display: flex;
    justify-content: flex-start;
}

/* Submit Button */
.btn--submit {
    align-self: flex-start;
    min-width: 200px;
    justify-content: center;
}

.btn--submit:disabled {
    cursor: not-allowed;
    opacity: 0.7;
}

.btn-spinner {
    animation: spin 1s linear infinite;
    font-size: 1.2rem;
}

.btn-success {
    color: #4CAF50;
    font-size: 1.2rem;
    animation: checkmark-pop 0.5s ease-in-out;
}

.btn-error {
    color: #f44336;
    font-size: 1.2rem;
    animation: shake-btn 0.5s ease-in-out;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes checkmark-pop {
    0% { transform: scale(0); }
    50% { transform: scale(1.2); }
    100% { transform: scale(1); }
}

@keyframes shake-btn {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-5px); }
    75% { transform: translateX(5px); }
}

.btn-text {
    transition: opacity 0.3s ease;
}

.btn.loading .btn-text,
.btn.success .btn-text,
.btn.error .btn-text {
    opacity: 0;
}

.form-status {
    font-size: var(--fs-small);
    font-weight: 500;
    min-height: 1.4em;
}

/* ============================================
   FOOTER
   ============================================ */
.footer {
    padding: var(--sp-8) 15%;
    background-color: var(--secondary-color);
    border-top: 1px solid rgba(var(--accent-color-rgb), 0.05);
}

.footer__inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: var(--container-max);
    margin: 0 auto;
    gap: var(--sp-6);
}

.footer__brand {
    display: flex;
    align-items: center;
    gap: var(--sp-4);
}

.footer__brand .logo-img {
    height: 32px;
}

.footer__tagline {
    font-size: var(--fs-xs);
    color: var(--text-secondary-color);
    font-family: var(--font-mono);
    letter-spacing: 0.05em;
}

.footer__social {
    display: flex;
    gap: var(--sp-3);
}

.footer__social-link {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    color: var(--text-secondary-color);
    transition: all 0.2s ease;
}

.footer__social-link:hover {
    color: var(--accent-color);
    background: rgba(var(--accent-color-rgb), 0.1);
}

.footer__copy {
    font-size: var(--fs-xs);
    color: var(--text-secondary-color);
}

/* ============================================
   SCROLL TO TOP
   ============================================ */
.scroll-top {
    position: fixed;
    bottom: 32px;
    right: 32px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    backdrop-filter: blur(10px);
    color: var(--accent-color);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 50;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all 0.3s var(--ease-out);
}

.scroll-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.scroll-top:hover {
    background: rgba(var(--accent-color-rgb), 0.1);
    border-color: var(--card-hover-border);
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(var(--accent-color-rgb), 0.15);
}

/* ============================================
   REVEAL ANIMATIONS
   ============================================ */
.reveal-up,
.reveal-left,
.reveal-right {
    opacity: 0;
    transition: opacity var(--duration-slow) var(--ease-out-expo),
                transform var(--duration-slow) var(--ease-out-expo);
    transition-delay: var(--delay, 0s);
}

.reveal-up {
    transform: translateY(40px);
}

.reveal-left {
    transform: translateX(-40px);
}

.reveal-right {
    transform: translateX(40px);
}

.reveal-up.visible,
.reveal-left.visible,
.reveal-right.visible {
    opacity: 1;
    transform: translate(0, 0);
}

/* ============================================
   RESPONSIVE — TABLET (768px)
   ============================================ */
@media (max-width: 768px) {
    section {
        padding: 80px 8%;
    }

    .header {
        padding: 16px 6%;
    }

    .mobile-menu-toggle {
        display: flex;
    }

    .nav-links {
        position: fixed;
        top: 0;
        left: -100%;
        width: 100%;
        height: 100vh;
        background-color: var(--nav-mobile-bg);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 0;
        transition: left 0.4s var(--ease-out-expo);
        transform: none;
        z-index: 99;
    }

    .nav-links.active {
        left: 0;
    }

    .nav-links li {
        margin: 0;
    }

    .nav-link {
        font-size: 1.5rem;
        font-family: var(--font-display);
        font-weight: 600;
        padding: var(--sp-4) var(--sp-8);
        display: block;
        text-align: center;
    }

    .nav-actions {
        z-index: 101;
    }

    .hero {
        padding-top: 100px;
        min-height: 100vh;
    }

    .profile-photo {
        width: 180px;
        height: 180px;
    }

    .hero__name {
        font-size: clamp(2.5rem, 10vw, 4rem);
    }

    .hero-buttons {
        flex-direction: column;
        align-items: center;
        gap: var(--sp-3);
    }

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

    .social-links {
        gap: var(--sp-3);
    }

    .social-link {
        width: 48px;
        height: 48px;
    }

    .social-icon {
        width: 20px;
        height: 20px;
    }

    .scroll-indicator {
        display: none;
    }

    /* About Stats */
    .about-stats {
        grid-template-columns: repeat(2, 1fr);
    }

    /* Timeline — Single column */
    .timeline::after {
        left: 16px;
    }

    .timeline-item {
        width: 100%;
        padding-left: 48px;
        padding-right: 0;
    }

    .timeline-item:nth-child(odd) {
        padding-right: 0;
    }

    .timeline-item:nth-child(even) {
        left: 0;
        padding-left: 48px;
    }

    .timeline-item::after,
    .timeline-item:nth-child(even)::after {
        left: 9px;
        right: auto;
    }

    .timeline-item:nth-child(odd) .timeline-item__card {
        text-align: left;
    }

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

    /* Contact */
    .contact-layout {
        grid-template-columns: 1fr;
        gap: var(--sp-10);
    }

    .g-recaptcha {
        justify-content: center;
    }

    .btn--submit {
        align-self: center;
    }

    /* Footer */
    .footer__inner {
        flex-direction: column;
        text-align: center;
        gap: var(--sp-4);
    }

    .footer__brand {
        flex-direction: column;
    }
}

/* ============================================
   RESPONSIVE — MOBILE SMALL (480px)
   ============================================ */
@media (max-width: 480px) {
    section {
        padding: 60px 6%;
    }

    .hero {
        padding-top: 100px;
    }

    .profile-photo {
        width: 150px;
        height: 150px;
    }

    .hero-subtitle {
        gap: var(--sp-1);
    }

    .hero-subtitle__tag {
        font-size: 0.65rem;
        padding: 2px 8px;
    }

    .social-link {
        width: 44px;
        height: 44px;
    }

    .social-icon {
        width: 18px;
        height: 18px;
    }

    .about-stats {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--sp-3);
    }

    .stat-card {
        padding: var(--sp-4) var(--sp-3);
    }

    .scroll-top {
        bottom: 16px;
        right: 16px;
        width: 40px;
        height: 40px;
    }

    .section-title {
        margin-bottom: var(--sp-10);
    }
}

/* ============================================
   REDUCED MOTION
   ============================================ */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    html {
        scroll-behavior: auto;
    }

    .reveal-up,
    .reveal-left,
    .reveal-right {
        opacity: 1;
        transform: none;
    }

    .hero__name {
        animation: none;
        background-size: 100% auto;
    }

    .scroll-indicator__line {
        animation: none;
    }

    .typing-cursor {
        animation: none;
    }
}
