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

:root {
    --teal: #0ea5a0;
    --teal-light: #17c3bd;
    --blue-accent: #5b8ef5;
    --text-dark: #0f1923;
    --text-muted: #6b7a8d;
    --bg-page: #f0f4f8;
    --bg-hero: linear-gradient(135deg, #e8f4f8 0%, #f5f0e8 100%);
    --white: #ffffff;
    --border: #e2e8f0;
    --shadow: 0 4px 24px rgba(0, 0, 0, 0.07);
    --radius: 14px;
}

body {
    font-family: 'Plus Jakarta Sans', sans-serif;
    background: var(--bg-page);
    color: var(--text-dark);
    min-height: 100vh;
}

body.lang-km {
    font-family: 'Hanuman', 'Plus Jakarta Sans', sans-serif;
}

/* ── NAV ── */
nav {
    background: var(--white);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 48px;
    height: 64px;
    box-shadow: 0 1px 0 var(--border);
    position: sticky;
    top: 0;
    z-index: 100;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    font-weight: 700;
    font-size: 1rem;
    color: var(--text-dark);
    text-decoration: none;
}

.nav-avatar {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: linear-gradient(135deg, #7ec8e3 0%, #a8d8ea 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 14px;
}

/* Language switcher pill */
.lang-switcher {
    display: flex;
    align-items: center;
    background: #f1f5f9;
    border: 1px solid var(--border);
    border-radius: 999px;
    padding: 3px;
    gap: 2px;
}

.lang-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 5px 13px;
    border-radius: 999px;
    border: none;
    background: transparent;
    font-family: inherit;
    font-size: 0.82rem;
    font-weight: 600;
    cursor: pointer;
    color: var(--text-muted);
    transition: all .2s;
    white-space: nowrap;
}

.lang-btn.active {
    background: var(--white);
    color: var(--text-dark);
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.1);
}

.lang-btn .flag-icon {
    font-size: 15px;
}

.btn-login {
    background: none;
    border: 1.5px solid var(--border);
    font-family: inherit;
    font-size: 0.88rem;
    font-weight: 600;
    cursor: pointer;
    color: var(--text-dark);
    padding: 7px 16px;
    border-radius: 8px;
    transition: border-color .2s, color .2s;
}

.btn-login:hover {
    border-color: var(--teal);
    color: var(--teal);
}

.btn-register {
    background: var(--teal);
    color: #fff;
    border: none;
    padding: 9px 20px;
    border-radius: 8px;
    font-family: inherit;
    font-size: 0.88rem;
    font-weight: 700;
    cursor: pointer;
    transition: background .2s;
}

.btn-register:hover {
    background: var(--teal-light);
}

/* ── HERO ── */
.hero {
    background: var(--bg-hero);
    padding: 80px 48px 60px;
    display: grid;
    grid-template-columns: 1fr 440px;
    gap: 60px;
    align-items: center;
    min-height: calc(100vh - 64px - 100px);
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: 999px;
    padding: 6px 16px;
    font-size: 0.82rem;
    font-weight: 500;
    color: var(--text-muted);
    margin-bottom: 28px;
}

.hero-badge .dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--teal);
    flex-shrink: 0;
}

.hero-title {
    font-size: clamp(2.2rem, 4vw, 3.2rem);
    font-weight: 800;
    line-height: 1.2;
    color: var(--text-dark);
    margin-bottom: 24px;
}

.hero-title .accent {
    color: var(--blue-accent);
}

.hero-desc {
    font-size: 1rem;
    color: var(--text-muted);
    line-height: 1.75;
    max-width: 520px;
    margin-bottom: 36px;
}

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

.btn-primary {
    background: var(--teal);
    color: #fff;
    border: none;
    padding: 14px 28px;
    border-radius: 10px;
    font-family: inherit;
    font-size: 0.95rem;
    font-weight: 700;
    cursor: pointer;
    transition: background .2s, transform .15s;
}

.btn-primary:hover {
    background: var(--teal-light);
    transform: translateY(-1px);
}

.btn-outline {
    background: var(--white);
    color: var(--text-dark);
    border: 1.5px solid var(--border);
    padding: 14px 28px;
    border-radius: 10px;
    font-family: inherit;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    transition: border-color .2s, transform .15s;
}

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

.btn-cv {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: transparent;
    color: var(--teal);
    border: 1.5px solid var(--teal);
    padding: 14px 28px;
    border-radius: 10px;
    font-family: inherit;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    transition: background .2s, color .2s, transform .15s;
}

.btn-cv:hover {
    background: var(--teal);
    color: #fff;
    transform: translateY(-1px);
}

/* ── LEARN CARD ── */
.learn-card {
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 28px;
}

.learn-card h3 {
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 20px;
}

.learn-item {
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 16px 18px;
    margin-bottom: 12px;
    transition: box-shadow .2s;
}

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

.learn-item:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
}

.learn-item-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 6px;
}

.learn-icon {
    font-size: 20px;
}

.learn-item-title {
    font-weight: 700;
    font-size: 0.95rem;
}

.learn-item-tech {
    font-size: 0.82rem;
    color: var(--text-muted);
    margin-bottom: 8px;
}

.learn-tag {
    display: inline-block;
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--teal);
    background: #e6f9f8;
    padding: 3px 10px;
    border-radius: 6px;
}

/* ── STATS ── */
.stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    padding: 0 48px 80px;
    background: var(--bg-hero);
}

.stat-box {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 24px 28px;
}

.stat-num {
    font-size: 1.9rem;
    font-weight: 800;
    color: var(--text-dark);
}

.stat-label {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-top: 4px;
}

/* ── FOOTER ── */
footer {
    background: var(--text-dark);
    color: #cbd5e1;
    padding: 64px 48px 32px;
}

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

.footer-brand-name {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
    font-size: 1rem;
    color: #fff;
    margin-bottom: 14px;
}

.footer-avatar {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: linear-gradient(135deg, #0ea5a0 0%, #5b8ef5 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
}

.footer-desc {
    font-size: 0.875rem;
    line-height: 1.7;
    color: #94a3b8;
    margin-bottom: 24px;
    max-width: 260px;
}

.footer-socials {
    display: flex;
    gap: 10px;
}

.social-btn {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    background: #1e293b;
    border: 1px solid #334155;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 15px;
    cursor: pointer;
    text-decoration: none;
    color: #cbd5e1;
    transition: background .2s, border-color .2s;
}

.social-btn:hover {
    background: var(--teal);
    border-color: var(--teal);
}

.footer-col h4 {
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: #fff;
    margin-bottom: 18px;
}

.footer-col ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.footer-col ul a {
    text-decoration: none;
    color: #94a3b8;
    font-size: 0.875rem;
    transition: color .2s;
}

.footer-col ul a:hover {
    color: var(--teal-light);
}

.footer-divider {
    border: none;
    border-top: 1px solid #1e293b;
    margin-bottom: 28px;
}

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

.footer-bottom p {
    font-size: 0.82rem;
    color: #64748b;
}

.footer-bottom p span {
    color: var(--teal-light);
}

.footer-bottom-links {
    display: flex;
    gap: 24px;
}

.footer-bottom-links a {
    font-size: 0.82rem;
    color: #64748b;
    text-decoration: none;
    transition: color .2s;
}

.footer-bottom-links a:hover {
    color: #fff;
}

/* ── SECTION COMMON ── */
.section {
    padding: 80px 48px;
    background: var(--bg-page);
}

.section-alt {
    background: var(--white);
}

.section-header {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    margin-bottom: 40px;
}

.section-label {
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: var(--teal);
    margin-bottom: 8px;
}

.section-title {
    font-size: 1.9rem;
    font-weight: 800;
    color: var(--text-dark);
    line-height: 1.2;
}

/* ── PROJECTS ── */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.project-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    transition: box-shadow .25s, transform .25s;
}

.project-card:hover {
    box-shadow: var(--shadow);
    transform: translateY(-4px);
}

.project-thumb {
    height: 160px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 48px;
}

.project-thumb.c1 {
    background: linear-gradient(135deg, #e0f2fe, #bae6fd);
}

.project-thumb.c2 {
    background: linear-gradient(135deg, #fce7f3, #fbcfe8);
}

.project-thumb.c3 {
    background: linear-gradient(135deg, #dcfce7, #bbf7d0);
}

.project-body {
    padding: 20px;
}

.project-tags {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
    margin-bottom: 10px;
}

.project-tag {
    font-size: 0.72rem;
    font-weight: 600;
    padding: 2px 9px;
    border-radius: 5px;
    background: #f1f5f9;
    color: var(--text-muted);
}

.project-name {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 6px;
}

.project-desc {
    font-size: 0.83rem;
    color: var(--text-muted);
    line-height: 1.6;
    margin-bottom: 16px;
}

.project-link {
    font-size: 0.83rem;
    font-weight: 600;
    color: var(--teal);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    transition: gap .2s;
}

.project-link:hover {
    gap: 8px;
}

/* ── EXPERIENCE ── */
.exp-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.project-thumb {
    width: 100%;
    height: 250px;
    overflow: hidden;
}

.project-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.exp-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px 28px;
    display: grid;
    grid-template-columns: 56px 1fr auto;
    gap: 20px;
    align-items: start;
    transition: box-shadow .2s;
}

.exp-card:hover {
    box-shadow: var(--shadow);
}

.exp-icon {
    width: 52px;
    height: 52px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    flex-shrink: 0;
}

.exp-icon.e1 {
    background: #ede9fe;
}

.exp-icon.e2 {
    background: #fef9c3;
}

.exp-icon.e3 {
    background: #dcfce7;
}

.exp-role {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 4px;
}

.exp-company {
    font-size: 0.88rem;
    color: var(--teal);
    font-weight: 600;
    margin-bottom: 8px;
}

.exp-desc {
    font-size: 0.84rem;
    color: var(--text-muted);
    line-height: 1.6;
}

.exp-period {
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--text-muted);
    background: #f1f5f9;
    padding: 4px 12px;
    border-radius: 999px;
    white-space: nowrap;
}

/* ── RESPONSIVE ── */
@media (max-width: 900px) {
    nav {
        padding: 0 20px;
    }

    .hero {
        grid-template-columns: 1fr;
        padding: 48px 24px 40px;
    }

    .stats {
        padding: 0 24px 60px;
    }

    footer {
        padding: 48px 24px 28px;
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 32px;
    }

    .footer-bottom {
        flex-direction: column;
        align-items: flex-start;
    }

    .section {
        padding: 60px 24px;
    }

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

    .exp-card {
        grid-template-columns: 56px 1fr;
    }

    .exp-period {
        grid-column: 2;
    }
}

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

    .btn-login,
    .btn-register {
        padding: 7px 12px;
        font-size: 0.8rem;
    }

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

    .exp-card {
        grid-template-columns: 1fr;
    }

    .exp-icon {
        display: none;
    }
}