/* =============================================
   DESIGN TOKENS
   ============================================= */
:root {
    --bg: #0a0a0f;
    --bg-card: #12121a;
    --bg-card-hover: #1a1a26;
    --text: #eaeaf0;
    --text-muted: #8888a0;
    --accent: #4d7cff;
    --accent-dim: rgba(77, 124, 255, 0.12);
    --accent-glow: rgba(77, 124, 255, 0.25);
    --border: rgba(255, 255, 255, 0.06);
    --border-hover: rgba(77, 124, 255, 0.4);
    --radius: 16px;
    --radius-sm: 10px;
    --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --font: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    --header-bg: rgba(10, 10, 15, 0.8);
}

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

html {
    scroll-behavior: smooth;
    scroll-padding-top: 90px;
}

html,
body {
    width: 100%;
    overflow-x: hidden;
}

body {
    background-color: var(--bg);
    color: var(--text);
    font-family: var(--font);
    font-size: 16px;
    line-height: 1.7;
    font-weight: 400;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* subtle noise grain */
body::before {
    content: "";
    position: fixed;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='100' height='100'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100' height='100' filter='url(%23n)' opacity='0.04'/%3E%3C/svg%3E");
    opacity: 0.5;
    pointer-events: none;
    z-index: 0;
}

body>* {
    position: relative;
    z-index: 1;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color var(--transition);
}

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

:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 3px;
    border-radius: 6px;
}

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

.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 24px;
}

section {
    padding: 100px 0;
}

/* =============================================
   SKIP LINK
   ============================================= */
.skip-link {
    position: fixed;
    top: 12px;
    left: 12px;
    background: var(--accent);
    color: #fff;
    padding: 8px 14px;
    border-radius: 8px;
    z-index: 2000;
    transform: translateY(-140%);
    opacity: 0;
    pointer-events: none;
    transition: var(--transition);
    font-size: 0.9rem;
}

.skip-link:focus,
.skip-link:focus-visible {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
}

/* =============================================
   TYPOGRAPHY
   ============================================= */
h1,
h2,
h3,
h4 {
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: -0.02em;
}

h1 {
    font-size: clamp(2.5rem, 5vw, 4rem);
}

h2 {
    font-size: clamp(1.8rem, 3vw, 2.5rem);
}

h3 {
    font-size: 1.25rem;
}

.section-title {
    text-align: center;
    margin-bottom: 3.5rem;
}

.section-title span {
    color: var(--accent);
}

/* =============================================
   HEADER
   ============================================= */
header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background: var(--header-bg);
    -webkit-backdrop-filter: blur(20px);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border);
    transition: var(--transition);
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 72px;
}

.logo a {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--text);
    letter-spacing: -0.02em;
}

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

.nav-links {
    list-style: none;
    display: flex;
    gap: 8px;
    align-items: center;
}

.nav-links a {
    color: var(--text-muted);
    font-weight: 500;
    font-size: 0.9rem;
    padding: 8px 14px;
    border-radius: var(--radius-sm);
    transition: var(--transition);
    position: relative;
    white-space: nowrap;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--text);
    background: var(--accent-dim);
}

.nav-btn {
    border: 1px solid var(--accent) !important;
    color: var(--accent) !important;
    border-radius: var(--radius-sm) !important;
}

.nav-btn:hover {
    background: var(--accent) !important;
    color: #fff !important;
}

.toggle-active {
    background: var(--accent) !important;
    color: #fff !important;
}

.menu-toggle {
    display: none;
    font-size: 1.4rem;
    color: var(--text);
    cursor: pointer;
    padding: 6px;
}

.mobile-nav {
    display: none;
    background: rgba(12, 12, 18, 0.98);
    position: absolute;
    top: 72px;
    left: 0;
    width: 100%;
    border-bottom: 1px solid var(--border);
    flex-direction: column;
    padding: 12px 16px 16px;
    text-align: center;
    backdrop-filter: blur(20px);
}

.mobile-nav a {
    padding: 14px 12px;
    margin: 4px 0;
    display: block;
    color: var(--text-muted);
    font-size: 1rem;
    border-radius: var(--radius-sm);
    border: 1px solid transparent;
    transition: var(--transition);
}

.mobile-nav a:hover,
.mobile-nav a:focus-visible {
    color: var(--text);
    background: var(--accent-dim);
    border-color: var(--border-hover);
}

.mobile-nav a.active {
    color: var(--text);
    background: var(--accent-dim);
    border-color: var(--border-hover);
}

@media (max-width: 768px) {
    .nav-links {
        display: none;
    }

    .menu-toggle {
        display: block;
    }

    .mobile-nav {
        display: flex;
        opacity: 0;
        transform: translateY(-10px);
        max-height: 0;
        pointer-events: none;
        overflow: hidden;
        transition: var(--transition);
    }

    .mobile-nav.active {
        opacity: 1;
        transform: translateY(0);
        max-height: 80vh;
        pointer-events: auto;
    }
}

/* =============================================
   HERO
   ============================================= */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding-top: 72px;
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

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

.hero h1 {
    margin-bottom: 12px;
}

.hero-role {
    font-size: 1.15rem;
    color: var(--text-muted);
    margin-bottom: 16px;
    font-weight: 500;
}

.hero-desc {
    color: var(--text-muted);
    max-width: 480px;
    margin-bottom: 20px;
    line-height: 1.8;
}

.hero-badges {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 28px;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 16px;
    border-radius: 999px;
    font-size: 0.85rem;
    font-weight: 500;
    border: 1px solid var(--border-hover);
    background: var(--accent-dim);
    color: var(--accent);
}

.badge::before {
    content: '';
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #22c55e;
    box-shadow: 0 0 8px rgba(34, 197, 94, 0.6);
}

.badge-outline::before {
    display: none;
}

.badge-outline {
    background: transparent;
    border-color: var(--border);
    color: var(--text-muted);
}

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

.hero-image-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
}

.hero-image {
    width: 100%;
    max-width: 380px;
    aspect-ratio: 1 / 1;
    border-radius: 24px;
    overflow: hidden;
    border: 2px solid var(--border);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4), 0 0 0 1px var(--border);
    transition: transform 0.6s cubic-bezier(0.22, 1, 0.36, 1), box-shadow var(--transition);
    will-change: transform;
    animation: hero-glow 4s ease-in-out infinite;
}

@keyframes hero-glow {

    0%,
    100% {
        box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4), 0 0 0 1px var(--border);
    }

    50% {
        box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4), 0 0 30px var(--accent-glow), 0 0 0 1px var(--border-hover);
    }
}

.hero-image:hover {
    box-shadow: 0 24px 70px rgba(0, 0, 0, 0.5), 0 0 30px var(--accent-glow);
}

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

@media (max-width: 768px) {
    .hero-content {
        grid-template-columns: 1fr;
        gap: 40px;
        text-align: center;
    }

    .hero-image-wrapper {
        order: -1;
    }

    .hero-image {
        max-width: 260px;
    }

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

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

    .hero-desc {
        margin-left: auto;
        margin-right: auto;
    }
}

/* =============================================
   BUTTONS
   ============================================= */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 28px;
    border: 1px solid var(--border);
    color: var(--text-muted);
    border-radius: var(--radius-sm);
    font-family: var(--font);
    font-size: 0.95rem;
    font-weight: 500;
    cursor: pointer;
    background: transparent;
    transition: var(--transition);
}

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

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

.btn-primary:hover {
    background: #3d6bef;
    border-color: #3d6bef;
    box-shadow: 0 8px 24px var(--accent-glow);
}

.btn-secondary {
    border-color: var(--border);
    color: var(--text);
}

.btn-sm {
    padding: 8px 20px;
    font-size: 0.85rem;
}

/* =============================================
   REVEAL ANIMATION
   ============================================= */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1), transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

.reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* stagger children */
.stack-grid .reveal:nth-child(2) {
    transition-delay: 0.06s;
}

.stack-grid .reveal:nth-child(3) {
    transition-delay: 0.12s;
}

.stack-grid .reveal:nth-child(4) {
    transition-delay: 0.18s;
}

.stack-grid .reveal:nth-child(5) {
    transition-delay: 0.24s;
}

.stack-grid .reveal:nth-child(6) {
    transition-delay: 0.30s;
}

.stack-grid .reveal:nth-child(7) {
    transition-delay: 0.36s;
}

.stack-grid .reveal:nth-child(8) {
    transition-delay: 0.42s;
}

.certs-grid .reveal:nth-child(2) {
    transition-delay: 0.08s;
}

.certs-grid .reveal:nth-child(3) {
    transition-delay: 0.16s;
}

.projects-grid .reveal:nth-child(2) {
    transition-delay: 0.1s;
}

.projects-grid .reveal:nth-child(3) {
    transition-delay: 0.2s;
}

.timeline .reveal:nth-child(2) {
    transition-delay: 0.08s;
}

.timeline .reveal:nth-child(3) {
    transition-delay: 0.16s;
}

.timeline .reveal:nth-child(4) {
    transition-delay: 0.24s;
}

.timeline .reveal:nth-child(5) {
    transition-delay: 0.32s;
}

/* =============================================
   ABOUT
   ============================================= */
.about-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 48px;
    align-items: start;
}

.about-text p {
    color: var(--text-muted);
    max-width: 60ch;
    line-height: 1.85;
    font-size: 1.02rem;
}

.about-highlights {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.highlight-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 20px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    transition: var(--transition);
}

.highlight-item:hover {
    border-color: var(--border-hover);
    background: var(--bg-card-hover);
    transform: translateY(-2px);
}

.highlight-item i {
    font-size: 1.5rem;
    color: var(--accent);
    width: 42px;
    height: 42px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--accent-dim);
    border-radius: 12px;
    flex-shrink: 0;
}

.highlight-item h4 {
    font-size: 0.95rem;
    margin-bottom: 2px;
}

.highlight-item p {
    color: var(--text-muted);
    font-size: 0.9rem;
}

@media (max-width: 768px) {
    .about-grid {
        grid-template-columns: 1fr;
        gap: 32px;
    }
}

/* =============================================
   STACK
   ============================================= */
.stack-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}

.stack-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 24px 16px;
    background: transparent;
    border: none;
    border-radius: 0;
    transition: var(--transition);
    cursor: default;
}

.stack-card i {
    font-size: 3rem;
    transition: transform 0.5s cubic-bezier(0.22, 1, 0.36, 1), filter 0.4s ease;
}

.stack-card span {
    font-size: 0.85rem;
    color: var(--text-muted);
    font-weight: 500;
    letter-spacing: 0.3px;
    transition: var(--transition);
}

.stack-card:hover {
    transform: translateY(-10px) scale(1.08);
    animation-play-state: paused;
}

.stack-card:hover i {
    transform: scale(1.25) rotate(-6deg);
    filter: drop-shadow(0 0 14px currentColor);
}

.stack-card:hover span {
    color: var(--text);
}

/* Wave float for stack cards */
.stack-card.revealed {
    animation: wave-float-sm 5s ease-in-out infinite;
}

.stack-card:nth-child(1).revealed {
    animation-delay: 0s;
}

.stack-card:nth-child(2).revealed {
    animation-delay: 0.3s;
}

.stack-card:nth-child(3).revealed {
    animation-delay: 0.6s;
}

.stack-card:nth-child(4).revealed {
    animation-delay: 0.9s;
}

.stack-card:nth-child(5).revealed {
    animation-delay: 1.2s;
}

.stack-card:nth-child(6).revealed {
    animation-delay: 0.2s;
}

.stack-card:nth-child(7).revealed {
    animation-delay: 0.5s;
}

.stack-card:nth-child(8).revealed {
    animation-delay: 0.8s;
}

@keyframes wave-float-sm {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-16px);
    }
}

@media (max-width: 768px) {
    .stack-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 400px) {
    .stack-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .stack-card {
        padding: 24px 12px;
    }
}

/* =============================================
   PROJECTS
   ============================================= */
.projects-grid {
    display: grid;
    gap: 24px;
}

.project-card {
    display: grid;
    grid-template-columns: 200px 1fr;
    gap: 28px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 28px;
    transition: var(--transition);
}

.project-card:hover {
    border-color: var(--border-hover);
    background: var(--bg-card-hover);
    transform: translateY(-3px);
    box-shadow: 0 20px 50px rgba(77, 124, 255, 0.1);
}

.project-visual {
    background: rgba(77, 124, 255, 0.05);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 160px;
    color: var(--accent);
    font-size: 2.5rem;
    transition: transform 0.6s cubic-bezier(0.22, 1, 0.36, 1);
    will-change: transform;
}

.project-body h3 {
    margin-bottom: 10px;
}

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

.tag {
    font-size: 0.78rem;
    background: var(--accent-dim);
    color: var(--accent);
    padding: 4px 10px;
    border-radius: 6px;
    font-weight: 500;
}

.project-body p {
    color: var(--text-muted);
    font-size: 0.95rem;
    margin-bottom: 16px;
    line-height: 1.7;
}

@media (max-width: 768px) {
    .project-card {
        grid-template-columns: 1fr;
    }

    .project-visual {
        min-height: 120px;
    }
}

/* =============================================
   JOURNEY / TIMELINE (Alternating Left/Right)
   ============================================= */
.timeline {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
    padding: 20px 0;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 50%;
    top: 0;
    bottom: 0;
    width: 2px;
    background: linear-gradient(to bottom, var(--accent), var(--border));
    transform: translateX(-50%);
    border-radius: 2px;
}

.timeline-item {
    position: relative;
    width: 50%;
    padding-bottom: 40px;
}

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

/* Left side items */
.timeline-left {
    left: 0;
    padding-right: 48px;
    text-align: right;
}

/* Right side items */
.timeline-right {
    left: 50%;
    padding-left: 48px;
    text-align: left;
}

.timeline-dot {
    position: absolute;
    top: 24px;
    width: 14px;
    height: 14px;
    background: var(--bg);
    border: 2px solid var(--accent);
    border-radius: 50%;
    z-index: 2;
    transition: var(--transition);
}

.timeline-left .timeline-dot {
    right: -7px;
}

.timeline-right .timeline-dot {
    left: -7px;
}

.timeline-item:hover .timeline-dot {
    background: var(--accent);
    box-shadow: 0 0 14px var(--accent-glow);
    transform: scale(1.3);
}

.timeline-content {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
    transition: var(--transition);
    text-align: left;
}

.timeline-content:hover {
    border-color: var(--border-hover);
    background: var(--bg-card-hover);
    transform: translateY(-2px);
}

.timeline-date {
    color: var(--accent);
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 6px;
    display: block;
}

.timeline-content h3 {
    margin-bottom: 6px;
}

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

/* Mobile: single column */
@media (max-width: 768px) {
    .timeline::before {
        left: 16px;
        transform: none;
    }

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

    .timeline-left,
    .timeline-right {
        left: 0;
        text-align: left;
        padding-left: 48px;
        padding-right: 0;
    }

    .timeline-left .timeline-dot,
    .timeline-right .timeline-dot {
        left: 10px;
        right: auto;
    }
}

/* =============================================
   CERTIFICATIONS
   ============================================= */
.certs-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.cert-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 36px 24px;
    text-align: center;
    transition: var(--transition);
}

.cert-card:hover {
    border-color: var(--border-hover);
    background: var(--bg-card-hover);
    transform: translateY(-6px) scale(1.03);
    box-shadow: 0 16px 40px rgba(77, 124, 255, 0.12);
    animation-play-state: paused;
}

/* Wave float for cert cards */
.cert-card.revealed {
    animation: wave-float-sm 4.5s ease-in-out infinite;
}

.cert-card:nth-child(1).revealed {
    animation-delay: 0s;
}

.cert-card:nth-child(2).revealed {
    animation-delay: 0.35s;
}

.cert-card:nth-child(3).revealed {
    animation-delay: 0.7s;
}

.cert-card i {
    font-size: 2.5rem;
    color: var(--accent);
    margin-bottom: 16px;
    display: block;
}

.cert-card h3 {
    margin-bottom: 4px;
}

.cert-card p {
    color: var(--text-muted);
    font-size: 0.9rem;
}

@media (max-width: 600px) {
    .certs-grid {
        grid-template-columns: 1fr;
    }
}

/* =============================================
   WAVE CARDS (Other Skills)
   ============================================= */
.wave-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.wave-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 36px 28px;
    text-align: center;
    position: relative;
    overflow: hidden;
    transition: transform 0.5s cubic-bezier(0.22, 1, 0.36, 1),
        border-color var(--transition),
        box-shadow 0.5s cubic-bezier(0.22, 1, 0.36, 1);
}

/* Wave floating animation — each card floats at different phases */
.wave-card.revealed {
    animation: wave-float 4s ease-in-out infinite;
}

.wave-card:nth-child(1).revealed {
    animation-delay: 0s;
}

.wave-card:nth-child(2).revealed {
    animation-delay: 0.4s;
}

.wave-card:nth-child(3).revealed {
    animation-delay: 0.8s;
}

@keyframes wave-float {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-12px);
    }
}

/* Gradient shimmer on hover */
.wave-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg,
            transparent,
            rgba(77, 124, 255, 0.06),
            transparent);
    transition: left 0.6s ease;
    pointer-events: none;
}

.wave-card:hover::before {
    left: 100%;
}

.wave-card:hover {
    border-color: var(--border-hover);
    box-shadow: 0 20px 50px rgba(77, 124, 255, 0.15);
    animation-play-state: paused;
    transform: translateY(-8px) scale(1.02);
}

.wave-card-icon {
    width: 56px;
    height: 56px;
    margin: 0 auto 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--accent-dim);
    border-radius: 16px;
    transition: var(--transition);
}

.wave-card-icon i {
    font-size: 1.6rem;
    color: var(--accent);
    transition: var(--transition);
}

.wave-card:hover .wave-card-icon {
    background: var(--accent);
    transform: scale(1.1) rotate(-3deg);
    box-shadow: 0 8px 24px var(--accent-glow);
}

.wave-card:hover .wave-card-icon i {
    color: #fff;
}

.wave-card h3 {
    margin-bottom: 6px;
    font-size: 1.15rem;
}

.wave-card-level {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 999px;
    border: 1px solid var(--border-hover);
    background: var(--accent-dim);
    color: var(--accent);
    font-size: 0.78rem;
    font-weight: 600;
    margin-bottom: 10px;
}

.wave-card p {
    color: var(--text-muted);
    font-size: 0.88rem;
}

/* Stagger reveal for wave cards */
.wave-grid .reveal:nth-child(1) {
    transition-delay: 0s;
}

.wave-grid .reveal:nth-child(2) {
    transition-delay: 0.12s;
}

.wave-grid .reveal:nth-child(3) {
    transition-delay: 0.24s;
}

@media (max-width: 768px) {
    .wave-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }
}

/* =============================================
   CONTACT FORM
   ============================================= */
.contact-wrapper {
    max-width: 560px;
    margin: 0 auto;
    background: var(--bg-card);
    padding: 40px;
    border-radius: var(--radius);
    border: 1px solid var(--border);
}

.form-helper {
    margin-bottom: 24px;
    color: var(--text-muted);
    font-size: 0.95rem;
}

.input-group {
    position: relative;
    margin-bottom: 28px;
}

.input-group input,
.input-group textarea {
    width: 100%;
    padding: 12px 0;
    background: transparent;
    border: none;
    border-bottom: 1px solid var(--border);
    color: var(--text);
    font-size: 1rem;
    font-family: var(--font);
    outline: none;
    transition: var(--transition);
}

.input-group input:focus,
.input-group textarea:focus {
    border-bottom-color: var(--accent);
}

.input-group input:focus-visible,
.input-group textarea:focus-visible {
    outline: none;
    border-bottom-color: var(--accent);
}

.input-group label {
    position: absolute;
    left: 0;
    top: 12px;
    color: var(--text-muted);
    pointer-events: none;
    transition: var(--transition);
    font-size: 0.95rem;
}

.input-group input:focus~label,
.input-group input:not(:placeholder-shown)~label,
.input-group textarea:focus~label,
.input-group textarea:not(:placeholder-shown)~label {
    top: -18px;
    font-size: 0.8rem;
    color: var(--accent);
}

.submit-btn {
    width: 100%;
    cursor: pointer;
}

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

.form-status {
    margin-top: 14px;
    font-size: 0.9rem;
    color: var(--text-muted);
    min-height: 20px;
}

.form-status[data-state="success"] {
    color: #22c55e;
}

.form-status[data-state="error"] {
    color: #ef4444;
}

.form-status[data-state="loading"] {
    color: var(--accent);
}

/* =============================================
   FOOTER
   ============================================= */
footer {
    background: var(--bg-card);
    padding: 60px 0 24px;
    border-top: 1px solid var(--border);
}

.footer-content {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 40px;
}

.footer-info h3 {
    font-size: 1.3rem;
    margin-bottom: 6px;
}

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

.footer-contact {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.footer-contact a {
    color: var(--text-muted);
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: var(--transition);
}

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

.footer-contact a i {
    color: var(--accent);
    width: 18px;
}

.social-links {
    display: flex;
    gap: 16px;
    align-items: center;
    justify-content: flex-end;
}

.social-links a {
    font-size: 1.5rem;
    color: var(--text-muted);
    transition: var(--transition);
}

.social-links a:hover {
    color: var(--accent);
    transform: translateY(-2px);
}

.copy {
    text-align: center;
    color: var(--text-muted);
    font-size: 0.85rem;
    padding-top: 24px;
    border-top: 1px solid var(--border);
}

@media (max-width: 768px) {
    .footer-content {
        grid-template-columns: 1fr;
        gap: 24px;
        text-align: center;
    }

    .social-links {
        justify-content: center;
    }

    .footer-contact {
        align-items: center;
    }
}

/* =============================================
   BACK TO TOP
   ============================================= */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 46px;
    height: 46px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    color: var(--text-muted);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
}

.back-to-top:hover {
    background: var(--accent);
    color: #fff;
    border-color: var(--accent);
}

.back-to-top.show {
    opacity: 1;
    visibility: visible;
}

/* =============================================
   WHATSAPP FLOAT
   ============================================= */
.whatsapp-float {
    position: fixed;
    width: 54px;
    height: 54px;
    bottom: 30px;
    left: 30px;
    background-color: #25d366;
    color: #fff;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    z-index: 1000;
    transition: var(--transition);
    box-shadow: 0 4px 16px rgba(37, 211, 102, 0.3);
}

.whatsapp-float:hover {
    background-color: #20ba5a;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(37, 211, 102, 0.4);
}

@media (max-width: 768px) {
    .whatsapp-float {
        width: 48px;
        height: 48px;
        font-size: 24px;
        bottom: 20px;
        left: 20px;
        border-radius: 12px;
    }

    .back-to-top {
        bottom: 20px;
        right: 20px;
    }
}

/* =============================================
   MODAL
   ============================================= */
.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    inset: 0;
    background-color: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(8px);
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity var(--transition);
}

.modal.show {
    display: flex;
    opacity: 1;
}

.modal-content {
    background: var(--bg-card);
    border: 1px solid var(--border);
    padding: 36px;
    border-radius: var(--radius);
    width: 90%;
    max-width: 480px;
    position: relative;
    transform: scale(0.9);
    transition: transform var(--transition);
}

.modal.show .modal-content {
    transform: scale(1);
}

.close-modal {
    position: absolute;
    top: 14px;
    right: 18px;
    color: var(--text-muted);
    font-size: 24px;
    cursor: pointer;
    transition: var(--transition);
    line-height: 1;
}

.close-modal:hover {
    color: var(--accent);
}

#modal-title {
    margin-bottom: 12px;
}

#modal-desc {
    color: var(--text-muted);
    line-height: 1.7;
}

.modal-link-btn {
    width: 100%;
    text-align: center;
}

/* =============================================
   SCROLLBAR
   ============================================= */
::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: var(--bg);
}

::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* =============================================
   RESPONSIVE GENERAL
   ============================================= */
@media (max-width: 600px) {
    section {
        padding: 72px 0;
    }

    .container {
        padding: 0 16px;
    }

    .btn {
        width: 100%;
        max-width: 340px;
    }

    .hero .btn+.btn {
        margin-top: 0;
    }

    .contact-wrapper {
        padding: 28px;
    }

    .modal-content {
        padding: 28px;
    }
}

/* =============================================
   CONTRAST MODE (Light)
   ============================================= */
body.white-contrast {
    --bg: #f4f5f8;
    --bg-card: #ffffff;
    --bg-card-hover: #f0f2f7;
    --text: #111318;
    --text-muted: #4a4e5a;
    --accent: #2563eb;
    --accent-dim: rgba(37, 99, 235, 0.08);
    --accent-glow: rgba(37, 99, 235, 0.2);
    --border: rgba(0, 0, 0, 0.08);
    --border-hover: rgba(37, 99, 235, 0.35);
    --header-bg: rgba(244, 245, 248, 0.92);
    color-scheme: light;
}

body.white-contrast::before {
    opacity: 0;
}

body.white-contrast .logo a {
    color: var(--text);
}

body.white-contrast .menu-toggle {
    color: var(--text);
}

body.white-contrast .mobile-nav {
    background: rgba(255, 255, 255, 0.98);
}

body.white-contrast .whatsapp-float {
    box-shadow: 0 4px 16px rgba(37, 211, 102, 0.2);
}

body.white-contrast .hero-image {
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.1), 0 0 0 1px var(--border);
}

/* =============================================
   PREFERS REDUCED MOTION
   ============================================= */
@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;
    }

    .reveal {
        opacity: 1;
        transform: none;
    }
}

/* =============================================
   TYPEWRITER ANIMATION
   ============================================= */
.hero-role {
    display: flex;
    align-items: center;
    min-height: 28px;
}
.typewriter-cursor {
    display: inline-block;
    width: 2px;
    background-color: var(--accent);
    margin-left: 4px;
    animation: blink 1s step-end infinite;
}
@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}

/* =============================================
   PROJECT FILTERS
   ============================================= */
.project-filters {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-bottom: 40px;
    flex-wrap: wrap;
}
.filter-btn {
    background: transparent;
    border: 1px solid var(--border);
    color: var(--text-muted);
    padding: 8px 20px;
    border-radius: 999px;
    font-size: 0.9rem;
    font-family: var(--font);
    cursor: pointer;
    transition: var(--transition);
}
.filter-btn:hover, .filter-btn.active {
    background: var(--accent-dim);
    color: var(--text);
    border-color: var(--accent);
}
.project-card.hidden {
    display: none;
}

/* =============================================
   AI CHATBOT
   ============================================= */
.chatbot-toggle-wrapper {
    position: fixed;
    bottom: 80px;
    right: 24px;
    z-index: 1000;
    display: flex;
    align-items: center;
    gap: 12px;
    transition: var(--transition);
}
.chatbot-tooltip {
    background: var(--accent);
    color: #fff;
    padding: 10px 16px;
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 15px rgba(77, 124, 255, 0.4);
    opacity: 0;
    transform: translateX(20px);
    pointer-events: none;
    transition: all 0.4s cubic-bezier(0.22, 1, 0.36, 1);
    position: relative;
}
.chatbot-tooltip.show {
    opacity: 1;
    transform: translateX(0);
    pointer-events: auto;
}
.chatbot-tooltip.bounce {
    animation: bounce-horizontal 2.5s infinite ease-in-out;
}
@keyframes bounce-horizontal {
    0%, 100% { transform: translateX(0); }
    50% { transform: translateX(-6px); }
}
.chatbot-tooltip::after {
    content: '';
    position: absolute;
    right: -6px;
    top: 50%;
    transform: translateY(-50%);
    border-width: 6px 0 6px 6px;
    border-style: solid;
    border-color: transparent transparent transparent var(--accent);
}
#close-tooltip {
    background: none;
    border: none;
    color: rgba(255,255,255,0.8);
    font-size: 1.2rem;
    cursor: pointer;
    line-height: 1;
    margin-left: 4px;
    transition: var(--transition);
}
#close-tooltip:hover {
    color: #fff;
}
.chatbot-toggle {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: var(--accent);
    color: #fff;
    border: none;
    box-shadow: 0 4px 20px rgba(77, 124, 255, 0.4);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    transition: var(--transition);
}
.chatbot-toggle:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 24px rgba(77, 124, 255, 0.6);
}
.chatbot-toggle-wrapper.hidden {
    opacity: 0;
    pointer-events: none;
    transform: scale(0.8);
}
.chatbot-container {
    position: fixed;
    bottom: 80px;
    right: 24px;
    width: 340px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
    z-index: 1001;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    opacity: 0;
    pointer-events: none;
    transform: translateY(20px) scale(0.95);
    transition: var(--transition);
}
.chatbot-container.active {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0) scale(1);
}
.chatbot-header {
    background: var(--header-bg);
    padding: 16px;
    border-bottom: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.chatbot-title {
    display: flex;
    flex-direction: column;
}
.chatbot-title h3 {
    font-size: 1rem;
    margin-bottom: 2px;
}
.chatbot-title div {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.8rem;
    color: var(--text-muted);
}
.status-indicator {
    width: 8px;
    height: 8px;
    background: #22c55e;
    border-radius: 50%;
    display: inline-block;
}
#close-chat {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 1.5rem;
    cursor: pointer;
    transition: var(--transition);
}
#close-chat:hover {
    color: var(--text);
}
.chatbot-messages {
    height: 300px;
    padding: 16px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.message {
    max-width: 85%;
    display: flex;
}
.user-message {
    align-self: flex-end;
}
.user-message .message-content {
    background: var(--accent);
    color: #fff;
    padding: 10px 14px;
    border-radius: 12px 12px 0 12px;
    font-size: 0.9rem;
}
.ai-message {
    align-self: flex-start;
}
.ai-message .message-content {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text);
    padding: 10px 14px;
    border-radius: 12px 12px 12px 0;
    font-size: 0.9rem;
}
.chatbot-input {
    padding: 12px;
    border-top: 1px solid var(--border);
    display: flex;
    gap: 8px;
    background: var(--header-bg);
}
#chat-input {
    flex: 1;
    background: transparent;
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 8px 12px;
    color: var(--text);
    font-family: var(--font);
    font-size: 0.9rem;
    outline: none;
}
#chat-input:focus {
    border-color: var(--accent);
}
#send-chat {
    background: var(--accent);
    color: #fff;
    border: none;
    border-radius: 8px;
    width: 40px;
    cursor: pointer;
    transition: var(--transition);
}
#send-chat:hover {
    background: #3d6bef;
}
.typing-dots {
    display: inline-flex;
    gap: 2px;
}
.typing-dots span {
    width: 6px;
    height: 6px;
    background: var(--text-muted);
    border-radius: 50%;
    animation: bounce 1.4s infinite ease-in-out both;
}
.typing-dots span:nth-child(1) { animation-delay: -0.32s; }
.typing-dots span:nth-child(2) { animation-delay: -0.16s; }
@keyframes bounce {
    0%, 80%, 100% { transform: scale(0); }
    40% { transform: scale(1); }
}

@media (max-width: 600px) {
    .chatbot-container {
        width: calc(100% - 48px);
        bottom: 80px;
    }
}