@import url("https://fonts.googleapis.com/css2?family=Ubuntu:wght@300;400;500;700&display=swap");
@import url("https://fonts.googleapis.com/css2?family=Montserrat:wght@400;500;600&display=swap");
@import url("https://fonts.googleapis.com/css2?family=Arvo:wght@400;700&display=swap");
@import url("https://fonts.googleapis.com/css2?family=Rubik:wght@400;500;600&display=swap");

:root {
    --bg: #0b0b0f;
    --bg-soft: #121219;
    --text: #f2efe9;
    --muted: #9c968c;
    --accent: #c78f45;
    --accent-soft: rgba(199, 143, 69, 0.18);
    --line: rgba(255, 255, 255, 0.08);
}

:root[data-theme="light"] {
    --bg: #f5f0e6;
    --bg-soft: #fff8ef;
    --text: #1e1913;
    --muted: #5f564b;
    --accent: #9e6726;
    --accent-soft: rgba(158, 103, 38, 0.14);
    --line: rgba(30, 25, 19, 0.14);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html,
body,
body * {
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: "Ubuntu", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: var(--bg);
    color: var(--text);
    overflow-x: hidden;
    position: relative;
}

.global-fab-container {
    position: fixed;
    right: 22px;
    bottom: 22px;
    z-index: 20;
    pointer-events: none;
}

.global-fab-nav {
    display: flex;
    flex-direction: column;
    gap: 10px;
    pointer-events: auto;
}

.scroll-next-btn,
.scroll-top-btn,
.scroll-home-btn {
    width: 48px;
    height: 48px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: rgba(11, 11, 15, 0.66);
    color: var(--accent);
    font-size: 1.2rem;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.18s ease, background-color 0.18s ease, border-color 0.18s ease;
    backdrop-filter: blur(8px);
}

.scroll-next-btn:hover,
.scroll-top-btn:hover,
.scroll-home-btn:hover {
    background: rgba(18, 18, 25, 0.9);
    border-color: var(--accent);
    transform: translateY(-1px);
}

.scroll-next-btn:focus-visible,
.scroll-top-btn:focus-visible,
.scroll-home-btn:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 3px;
}


@media (max-width: 680px) and (min-height: 500px) {
    .global-fab-container {
        right: 10px;
        top: 70%;
        bottom: auto;
        transform: translateY(-50%);
    }

    .global-fab-nav {
        gap: 8px;
    }

    .scroll-next-btn,
    .scroll-top-btn,
    .scroll-home-btn {
        width: 45px;
        height: 45px;
        font-size: 1.05rem;
    }
}

@media (min-width: 1024px) {

    .scroll-next-btn,
    .scroll-top-btn,
    .scroll-home-btn {
        width: 62px;
        height: 62px;
        font-size: 2rem;
    }
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    background:
        radial-gradient(circle at 20% 20%, rgba(199, 143, 69, 0.12), transparent 32%),
        radial-gradient(circle at 80% 80%, rgba(255, 255, 255, 0.05), transparent 28%);
    pointer-events: none;
    z-index: 0;
}

.ui-toggle-bar {
    position: fixed;
    top: 18px;
    right: 18px;
    display: flex;
    gap: 10px;
    z-index: 15;
}

.mute-toggle,
.lang-toggle,
.theme-toggle {
    border: 1px solid var(--line);
    background: rgba(18, 18, 25, 0.8);
    color: var(--text);
    border-radius: 999px;
    padding: 8px 14px;
    font-size: 0.75rem;
    letter-spacing: 0.08em;
    cursor: pointer;
    backdrop-filter: blur(10px);
}

.theme-toggle {
    min-width: 40px;
}

.mute-toggle:hover,
.lang-toggle:hover,
.theme-toggle:hover {
    border-color: var(--accent);
}

.mute-toggle:focus-visible,
.lang-toggle:focus-visible,
.theme-toggle:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 3px;
}

:root[data-theme="light"] .mute-toggle,
:root[data-theme="light"] .lang-toggle,
:root[data-theme="light"] .theme-toggle {
    background: rgba(255, 248, 239, 0.9);
}

@media (max-width: 720px) {
    .ui-toggle-bar {
        top: 12px;
        right: 12px;
        gap: 8px;
    }

    .mute-toggle,
    .lang-toggle,
    .theme-toggle {
        padding: 7px 10px;
        font-size: 0.68rem;
    }
}

main {
    height: 100vh;
    overflow-y: scroll;
    scroll-snap-type: y mandatory;
    -ms-overflow-style: none;
    scrollbar-width: none;
    position: relative;
    z-index: 1;
}

main::-webkit-scrollbar {
    width: 0;
    height: 0;
    display: none;
}

section {
    min-height: 100vh;
    scroll-snap-align: start;
    scroll-snap-stop: always;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 48px;
    position: relative;
}


.card {
    width: min(980px, 100%);
    min-height: 62vh;
    border: 1px solid var(--line);
    background: rgba(18, 18, 25, 0.0);
    backdrop-filter: blur(18px);
    border-radius: 34px;
    padding: clamp(32px, 6vw, 72px);
    display: flex;
    flex-direction: column;
    justify-content: center;
    position: relative;
    overflow: visible;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.35);
}

.eyebrow {
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
    color: var(--accent);
    text-transform: none;
    letter-spacing: 0.02em;
    font-size: clamp(1.0rem, 1.2vw, 1.05rem);
    margin-bottom: 24px;
    display: inline-flex;
    align-items: center;
    gap: 0;
    white-space: nowrap;
}

.eyebrow-prefix {
    opacity: 0.95;
}

.eyebrow-path {
    margin-left: 2px;
}

.eyebrow::after {
    content: "|";
    animation: terminal-cursor-blink 1s steps(2, start) infinite;
}

.eyebrow {
    cursor: pointer;
}

@keyframes terminal-cursor-blink {

    0%,
    49% {
        opacity: 1;
    }

    50%,
    100% {
        opacity: 0;
    }
}

h1 {
    font-size: clamp(3.8rem, 10vw, 8rem);
    line-height: 0.9;
    letter-spacing: -0.08em;
    max-width: 820px;
}

h2 {
    font-size: clamp(2.4rem, 7vw, 5.8rem);
    line-height: 0.95;
    letter-spacing: -0.06em;
    max-width: 800px;
}

p {
    color: var(--muted);
    font-size: clamp(1.1rem, 2vw, 1.45rem);
    line-height: 1.6;
    max-width: 720px;
    margin-top: 28px;
}

.big-line {
    font-size: clamp(2rem, 6vw, 5rem);
    line-height: 1.05;
    letter-spacing: -0.05em;
    max-width: 820px;
}

.grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
    margin-top: 38px;
}

section[data-route="skills"] .grid {
    grid-template-columns: none;
    grid-template-rows: repeat(2, minmax(0, 1fr));
    grid-auto-flow: column;
    grid-auto-columns: calc((100% - 36px) / 2.5);
    overflow-x: auto;
    overflow-y: hidden;
    padding-bottom: 8px;
    scroll-snap-type: none;
    -ms-overflow-style: none;
    scrollbar-width: none;
}

section[data-route="skills"] .grid::-webkit-scrollbar {
    display: none;
}

section[data-route="skills"] .mini-card {
    min-height: 100%;
    scroll-snap-align: none;
}

section[data-route="skills"] .carousel-dots {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 14px;
}

.mini-card {
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.035);
    border-radius: 22px;
    padding: 24px;
    cursor: pointer;
}

.mini-card strong {
    display: block;
    font-size: 1.1rem;
    margin-bottom: 10px;
}

.mini-card span {
    color: var(--muted);
    line-height: 1.5;
}

.carousel-dots {
    display: none;
}

.carousel-dot {
    width: 8px;
    height: 8px;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.18);
    padding: 0;
    transition: width 0.18s ease, transform 0.18s ease, background-color 0.18s ease;
}

.carousel-dot.is-active {
    width: 24px;
    background: var(--accent);
    transform: none;
}

.signals {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-top: 40px;
    font-family: "Arvo", "Montserrat", sans-serif;
}

.signal {
    border: 1px solid var(--line);
    background: var(--accent-soft);
    color: var(--text);
    padding: 12px 18px;
    border-radius: 999px;
    font-size: 0.95rem;
}

@media (max-width: 820px) and (min-height: 500px) {
    .signals {
        justify-content: center;
    }

    .signal {
        font-size: 0.75rem;
        padding: 5px 9px;
    }
}

.quote {
    font-size: clamp(2rem, 5vw, 4.8rem);
    line-height: 1.08;
    letter-spacing: -0.05em;
    max-width: 900px;
}

.subquote {
    font-style: italic;
}

.picture {
    width: 100%;
    margin-top: 28px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.picture picture {
    display: block;
}

.picture img {
    display: block;
    width: min(100%, 720px);
    height: auto;
    max-height: 70vh;
    object-fit: contain;
    border-radius: 24px;
}

.picture figcaption {
    margin-top: 16px;
    color: var(--muted);
    font-size: clamp(0.95rem, 1.6vw, 1.1rem);
    line-height: 1.5;
    text-align: center;
    max-width: 720px;
}

@media (orientation: portrait) {
    .picture img {
        max-height: 53vh;
        width: min(80%, 720px);
    }
}

.eyebrow-route-menu {
    position: fixed;
    top: 0;
    left: 0;
    transform: translateY(-8px);
    width: max-content;
    max-width: calc(100vw - 20px);
    padding: 10px 12px 8px;
    border-left: 1px solid rgba(255, 255, 255, 0.08);
    border-right: 1px solid rgba(255, 255, 255, 0.08);
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 8px;
    background: rgba(11, 11, 15, 0.5);
    backdrop-filter: blur(24px) saturate(130%);
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.18);
    z-index: 9999;
    pointer-events: none;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.18s ease, transform 0.18s ease, visibility 0.18s ease;
}

.eyebrow-route-menu.is-open {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
}

.eyebrow-route-menu::before {
    content: "";
    position: absolute;
    top: -5px;
    left: 18px;
    width: 10px;
    height: 10px;
    border-left: 1px solid rgba(255, 255, 255, 0.06);
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    background: inherit;
    transform: rotate(45deg);
}

.eyebrow-route-menu-list {
    display: grid;
    width: max-content;
    max-width: 100%;
    gap: 2px;
}

.eyebrow-route-menu-item {
    display: flex;
    align-items: center;
    gap: 0;
    width: max-content;
    max-width: 100%;
    border: 0;
    background: transparent;
    color: var(--text);
    border-radius: 4px;
    padding: 6px 8px;
    text-align: left;
    cursor: pointer;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
    font-size: 0.88rem;
    letter-spacing: 0.03em;
    transition: background-color 0.18s ease, border-color 0.18s ease, transform 0.18s ease;
}

.eyebrow-route-menu-item:hover,
.eyebrow-route-menu-item:focus-visible {
    background: rgba(199, 143, 69, 0.08);
    transform: translateX(1px);
}

.eyebrow-route-menu-item.is-active {
    background: rgba(199, 143, 69, 0.1);
}

.eyebrow-route-menu-item .eyebrow-prefix {
    margin-right: 2px;
}

.eyebrow-route-menu-item .eyebrow-path {
    display: inline-block;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

:root[data-theme="light"] .eyebrow-route-menu {
    background: rgba(255, 248, 239, 0.96);
}

:root[data-theme="light"] .eyebrow-route-menu-item {
    background: transparent;
}

.footer-links {
    display: flex;
    gap: 22px;
    margin-top: 40px;
    flex-wrap: wrap;
}

/* Accessible hidden content: readable by assistive tech, visually removed from layout. */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

a {
    color: var(--text);
    text-decoration: none;
    border-bottom: 1px solid var(--accent);
    padding-bottom: 4px;
}

.number {
    position: absolute;
    right: 36px;
    top: 10px;
    color: rgba(255, 255, 255, 0.18);
    font-size: 0.9rem;
    letter-spacing: 0.2em;
}


@media (max-width: 720px) {
    section {
        padding: 22px;
    }

    .card {
        min-height: 72vh;
        border-radius: 26px;
    }

    .grid {
        grid-template-columns: 1fr;
    }

    h1 {
        font-size: clamp(3rem, 17vw, 5rem);
    }
}

@media (max-width: 720px) {
    section[data-route="skills"] .grid {
        grid-template-columns: none;
        grid-template-rows: 1fr;
        grid-auto-flow: column;
        grid-auto-columns: calc((100% - 24px) / 1.25);
        gap: 12px;
        margin-top: 28px;
        overflow-x: auto;
        overflow-y: hidden;
        padding-bottom: 8px;
        scroll-snap-type: none;
        -ms-overflow-style: none;
        scrollbar-width: none;
    }

    section[data-route="skills"] .grid::-webkit-scrollbar {
        display: none;
    }

    section[data-route="skills"] .mini-card {
        padding: 18px;
        min-height: 100%;
        scroll-snap-align: none;
    }

    section[data-route="skills"] .carousel-dots {
        display: flex;
        justify-content: center;
        gap: 8px;
        margin-top: 14px;
    }
}

.chips {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-top: 42px;
}

.chip {
    padding: 12px 18px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--text);
    font-size: 0.95rem;
    letter-spacing: 0.02em;
    transition: all 0.25s ease;
}

.chip:hover {
    transform: translateY(-2px);
    border-color: rgba(199, 143, 69, 0.45);
    background: rgba(199, 143, 69, 0.12);
}

:root[data-theme="light"] body::before {
    background:
        radial-gradient(circle at 20% 20%, rgba(158, 103, 38, 0.1), transparent 34%),
        radial-gradient(circle at 80% 80%, rgba(0, 0, 0, 0.05), transparent 28%);
}

:root[data-theme="light"] .card {
    background: rgba(255, 248, 239, 0.85);
    box-shadow: 0 30px 80px rgba(30, 25, 19, 0.16);
}

:root[data-theme="light"] .mini-card,
:root[data-theme="light"] .chip {
    background: rgba(255, 255, 255, 0.62);
    border-color: rgba(30, 25, 19, 0.14);
}

:root[data-theme="light"] .scroll-next-btn,
:root[data-theme="light"] .scroll-top-btn,
:root[data-theme="light"] .scroll-home-btn {
    background: rgba(255, 248, 239, 0.84);
}

:root[data-theme="light"] .number {
    color: rgba(30, 25, 19, 0.28);
}