:root {
    --bg: #09090b;
    --surface: #151519;
    --surface-strong: #1f1f25;
    --text: #f6f1ee;
    --muted: #c9beb9;
    --accent: #d8b1a5;
    --accent-dark: #9d6f62;
    --line: rgba(216, 177, 165, 0.24);
    --shadow: 0 18px 50px rgba(0, 0, 0, 0.34);
}

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

html {
    scroll-behavior: smooth;
}

body {
    background: var(--bg);
    color: var(--text);
    font-family: Inter, "Segoe UI", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
    line-height: 1.6;
}

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

a {
    color: inherit;
}

.container {
    width: min(1120px, calc(100% - 32px));
    margin: 0 auto;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 10;
    border-bottom: 1px solid var(--line);
    background: rgba(9, 9, 11, 0.92);
    backdrop-filter: blur(14px);
}

.navbar {
    display: flex;
    min-height: 78px;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.logo {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    color: var(--accent);
    font-weight: 800;
    text-decoration: none;
    white-space: nowrap;
}

.logo-image {
    width: 52px;
    height: 42px;
    object-fit: contain;
}

.nav-panel,
.nav-links {
    display: flex;
    align-items: center;
}

.nav-panel {
    gap: 18px;
}

.nav-links {
    gap: 4px;
    list-style: none;
}

.nav-links a {
    display: inline-flex;
    min-height: 40px;
    align-items: center;
    border-radius: 6px;
    color: var(--muted);
    font-weight: 700;
    padding: 0 12px;
    text-decoration: none;
}

.nav-links a:hover,
.nav-links a:focus-visible {
    background: rgba(216, 177, 165, 0.11);
    color: var(--text);
}

.language-switch {
    display: inline-flex;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 3px;
}

.lang-btn {
    min-width: 40px;
    border: 0;
    border-radius: 5px;
    background: transparent;
    color: var(--muted);
    cursor: pointer;
    font-weight: 900;
    padding: 8px 10px;
}

.lang-btn.active {
    background: var(--accent);
    color: #171113;
}

.menu-toggle {
    display: none;
    width: 44px;
    height: 44px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: transparent;
    cursor: pointer;
    padding: 10px;
}

.menu-toggle span {
    display: block;
    height: 2px;
    margin: 5px 0;
    background: var(--accent);
}

section {
    padding: 82px 0;
}

.section-band {
    background: var(--surface);
}

.hero {
    display: grid;
    min-height: calc(100vh - 78px);
    align-items: center;
    background:
        linear-gradient(rgba(9, 9, 11, 0.84), rgba(9, 9, 11, 0.9)),
        url("assets/images/hero-bg-gitmo.jpeg") center / cover no-repeat,
        radial-gradient(circle at 50% 0%, rgba(216, 177, 165, 0.16), transparent 32%),
        linear-gradient(145deg, #09090b 0%, #17171c 58%, #0f0d0e 100%);
}

.landing-hero {
    text-align: center;
}

.hero-content {
    padding: 52px 0;
}

.profile-frame {
    position: relative;
    display: grid;
    width: min(280px, 68vw);
    aspect-ratio: 1;
    place-items: center;
    margin: 0 auto 26px;
    border: 1px solid var(--line);
    border-radius: 50%;
    background: linear-gradient(145deg, rgba(216, 177, 165, 0.18), rgba(31, 31, 37, 0.92));
    box-shadow: var(--shadow);
    overflow: hidden;
}

.profile-photo {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 280px;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
}

.profile-photo.is-hidden {
    display: none;
}

.profile-fallback {
    position: absolute;
    color: var(--accent);
    font-size: clamp(3rem, 18vw, 6rem);
    font-weight: 900;
}

.eyebrow,
.section-title span,
.section-copy span,
.resume-hero span,
.project-detail-hero span {
    display: block;
    margin-bottom: 10px;
    color: var(--accent);
    font-size: 0.84rem;
    font-weight: 900;
    letter-spacing: 0;
    text-transform: uppercase;
}

h1,
h2,
h3 {
    line-height: 1.12;
}

.hero h1 {
    max-width: 940px;
    margin: 0 auto 18px;
    color: var(--text);
    font-size: clamp(2.4rem, 8vw, 5rem);
}

.hero p:not(.eyebrow) {
    max-width: 760px;
    margin: 0 auto 30px;
    color: var(--muted);
    font-size: clamp(1rem, 2.4vw, 1.2rem);
}

.hero-actions,
.contact-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 14px;
}

.btn {
    display: inline-flex;
    min-height: 48px;
    align-items: center;
    justify-content: center;
    border: 1px solid transparent;
    border-radius: 7px;
    background: var(--accent);
    color: #171113;
    cursor: pointer;
    font-weight: 900;
    padding: 12px 22px;
    text-decoration: none;
}

.btn:hover,
.btn:focus-visible {
    background: #edc8bc;
}

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

.btn-secondary:hover,
.btn-secondary:focus-visible {
    background: rgba(216, 177, 165, 0.12);
}

.btn-small {
    min-height: 42px;
    padding: 9px 16px;
}

.split-section {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(280px, 0.8fr);
    align-items: start;
    gap: 28px;
}

.section-copy h2,
.section-title h1,
.section-title h2,
.resume-hero h1,
.project-detail-hero h1 {
    margin-bottom: 16px;
    font-size: clamp(2rem, 5vw, 3.4rem);
}

.section-copy p,
.section-title p,
.resume-hero p,
.project-detail-hero p {
    color: var(--muted);
    font-size: 1.06rem;
}

.section-copy p + p {
    margin-top: 14px;
}

.highlight-panel,
.content-card,
.project-card {
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface-strong);
    box-shadow: var(--shadow);
}

.highlight-panel,
.content-card {
    padding: clamp(22px, 4vw, 32px);
}

.highlight-panel h3,
.content-card h2,
.project-card h2 {
    color: var(--accent);
}

.highlight-panel ul {
    margin-top: 16px;
    padding-left: 20px;
    color: var(--muted);
}

.highlight-panel li + li {
    margin-top: 10px;
}

.section-title {
    max-width: 760px;
    margin: 0 auto 42px;
    text-align: center;
}

.page-hero {
    padding-top: 124px;
    padding-bottom: 56px;
}

.project-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;
}

.project-card {
    overflow: hidden;
}

.project-card img {
    width: 100%;
    aspect-ratio: 16 / 10;
    object-fit: cover;
}

.project-card-body {
    display: grid;
    gap: 14px;
    padding: 22px;
}

.project-card p,
.content-card p,
.timeline-item p,
.compact-item p {
    color: var(--muted);
}

.tag-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.tag-list span {
    display: inline-flex;
    min-height: 30px;
    align-items: center;
    border: 1px solid var(--line);
    border-radius: 999px;
    color: var(--accent);
    font-size: 0.82rem;
    font-weight: 800;
    padding: 4px 10px;
}

.project-detail-hero {
    padding-top: 124px;
}

.detail-hero-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(280px, 0.85fr);
    align-items: center;
    gap: 34px;
}

.detail-hero-grid img {
    width: 100%;
    aspect-ratio: 4 / 3;
    border: 1px solid var(--line);
    border-radius: 8px;
    box-shadow: var(--shadow);
    object-fit: cover;
}

.back-link {
    display: inline-flex;
    margin-bottom: 22px;
    color: var(--accent);
    font-weight: 800;
    text-decoration: none;
}

.detail-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;
}

.resume-hero {
    display: grid;
    grid-template-columns: 220px minmax(0, 1fr);
    align-items: center;
    gap: 34px;
}

.resume-hero .profile-frame {
    width: min(220px, 64vw);
    margin: 0;
}

.contact-inline {
    display: flex;
    flex-wrap: wrap;
    gap: 12px 18px;
    margin-top: 18px;
}

.contact-inline a {
    color: var(--accent);
    font-weight: 800;
    text-decoration: none;
}

.resume-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.25fr) minmax(280px, 0.75fr);
    gap: 22px;
}

.resume-side {
    display: grid;
    align-content: start;
    gap: 22px;
}

.timeline-item,
.compact-item {
    border-left: 4px solid var(--accent);
    margin-top: 24px;
    padding-left: 18px;
}

.timeline-item h3,
.compact-item h3 {
    margin-bottom: 4px;
}

.meta {
    margin-bottom: 8px;
    color: var(--accent) !important;
    font-weight: 800;
}

.contact {
    background: var(--bg);
}

footer {
    border-top: 1px solid var(--line);
    padding: 42px 0 24px;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    gap: 32px;
}

.footer-logo {
    margin-bottom: 8px;
    color: var(--accent);
    font-size: 1.25rem;
    font-weight: 900;
}

.footer-content p,
.footer-links a {
    color: var(--muted);
}

.footer-links {
    display: flex;
    max-width: 420px;
    flex-wrap: wrap;
    gap: 10px 16px;
}

.footer-links h3 {
    flex-basis: 100%;
    color: var(--accent);
}

.footer-links a {
    text-decoration: none;
}

.copyright {
    width: min(1120px, calc(100% - 32px));
    margin: 30px auto 0;
    border-top: 1px solid var(--line);
    padding-top: 20px;
    color: var(--muted);
    text-align: center;
}

.redirect-page {
    display: grid;
    min-height: 100vh;
    place-items: center;
    padding: 24px;
}

.redirect-card {
    width: min(520px, 100%);
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface-strong);
    padding: 30px;
    text-align: center;
}

.redirect-card a {
    color: var(--accent);
    font-weight: 800;
}

@media (max-width: 920px) {
    .menu-toggle {
        display: block;
    }

    .nav-panel {
        position: absolute;
        top: 78px;
        left: 0;
        right: 0;
        display: none;
        border-bottom: 1px solid var(--line);
        background: rgba(9, 9, 11, 0.98);
        padding: 18px 16px 22px;
    }

    body.menu-open .nav-panel {
        display: block;
    }

    .nav-links {
        display: grid;
        gap: 6px;
        margin-bottom: 16px;
    }

    .nav-links a {
        justify-content: center;
        width: 100%;
    }

    .language-switch {
        display: flex;
        width: fit-content;
        margin: 0 auto;
    }

    .split-section,
    .detail-hero-grid,
    .resume-layout {
        grid-template-columns: 1fr;
    }

    .project-grid,
    .detail-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 620px) {
    .container {
        width: min(100% - 24px, 1120px);
    }

    .navbar {
        min-height: 72px;
    }

    .nav-panel {
        top: 72px;
    }

    section {
        padding: 58px 0;
    }

    .hero {
        min-height: auto;
        padding-top: 26px;
    }

    .hero-content {
        padding: 34px 0 46px;
    }

    .hero-actions,
    .contact-actions {
        display: grid;
    }

    .btn {
        width: 100%;
    }

    .page-hero,
    .project-detail-hero {
        padding-top: 100px;
    }

    .project-grid,
    .detail-grid,
    .resume-hero {
        grid-template-columns: 1fr;
    }

    .resume-hero .profile-frame {
        margin: 0 auto;
    }

    .footer-content {
        display: grid;
    }
}
