/* ---------- Fonty ---------- */

@font-face {
    font-family: "Cormorant";
    src: url("../fonts/cormorant-garamond-latin-500-normal.woff2") format("woff2");
    font-weight: 500;
    font-style: normal;
    font-display: swap;
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
    font-family: "Cormorant";
    src: url("../fonts/cormorant-garamond-latin-ext-500-normal.woff2") format("woff2");
    font-weight: 500;
    font-style: normal;
    font-display: swap;
    unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1E00-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
    font-family: "Cormorant";
    src: url("../fonts/cormorant-garamond-latin-600-normal.woff2") format("woff2");
    font-weight: 600;
    font-style: normal;
    font-display: swap;
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
    font-family: "Cormorant";
    src: url("../fonts/cormorant-garamond-latin-ext-600-normal.woff2") format("woff2");
    font-weight: 600;
    font-style: normal;
    font-display: swap;
    unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1E00-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
    font-family: "Cormorant";
    src: url("../fonts/cormorant-garamond-latin-500-italic.woff2") format("woff2");
    font-weight: 500;
    font-style: italic;
    font-display: swap;
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
    font-family: "Cormorant";
    src: url("../fonts/cormorant-garamond-latin-ext-500-italic.woff2") format("woff2");
    font-weight: 500;
    font-style: italic;
    font-display: swap;
    unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1E00-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
    font-family: "Courier Prime";
    src: url("../fonts/courier-prime-latin-400-normal.woff2") format("woff2");
    font-weight: 400;
    font-display: swap;
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
    font-family: "Courier Prime";
    src: url("../fonts/courier-prime-latin-ext-400-normal.woff2") format("woff2");
    font-weight: 400;
    font-display: swap;
    unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1E00-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

/* ---------- Tokeny ---------- */

:root {
    color-scheme: dark;

    --bg: #0c0b0a;
    --bg-raised: #151311;
    --ink: #ebe3d3;
    --ink-soft: #b9b0a0;
    --muted: #8a8172;
    --line: rgb(235 227 211 / 0.14);
    --accent: #c9a25e;

    --serif: "Cormorant", "Iowan Old Style", Georgia, serif;
    --mono: "Courier Prime", "Courier New", monospace;

    --gutter: clamp(1rem, 4vw, 3rem);
    --max: 72rem;
    --section-gap: clamp(5rem, 12vw, 9rem);
    --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
}

/* ---------- Základ ---------- */

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

html {
    scroll-behavior: smooth;
    scroll-padding-top: 4rem;
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    min-height: 100dvh;
    display: flex;
    flex-direction: column;
    background: var(--bg);
    color: var(--ink);
    font-family: var(--serif);
    font-weight: 500;
    font-size: clamp(1.125rem, 1rem + 0.4vw, 1.3rem);
    line-height: 1.6;
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
}

/* filmové zrno + vinetácia */
body::before,
body::after {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 100;
}

body::before {
    background: radial-gradient(ellipse at center, transparent 55%, rgb(0 0 0 / 0.55) 100%);
}

body::after {
    inset: -50%;
    opacity: 0.09;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='220' height='220'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 1.4 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
    animation: grain 0.9s steps(6) infinite;
}

@keyframes grain {
    0% { transform: translate(0, 0); }
    20% { transform: translate(-3%, 2%); }
    40% { transform: translate(2%, -4%); }
    60% { transform: translate(-4%, -1%); }
    80% { transform: translate(3%, 3%); }
    100% { transform: translate(-1%, 4%); }
}

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

a {
    color: inherit;
    text-decoration-color: var(--accent);
    text-underline-offset: 0.2em;
    transition: color 0.25s var(--ease);

    &:hover {
        color: var(--accent);
    }
}

:focus-visible {
    outline: 1px solid var(--accent);
    outline-offset: 4px;
}

h1,
h2 {
    margin: 0;
    font-weight: 500;
    line-height: 1.05;
    letter-spacing: -0.01em;
}

p {
    margin: 0;
}

.eyebrow {
    margin: 0 0 1rem;
    font-family: var(--mono);
    font-size: 0.75rem;
    font-weight: 400;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    color: var(--accent);
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
}

.skip-link {
    position: absolute;
    top: -3rem;
    left: 1rem;
    z-index: 200;
    padding: 0.5rem 1rem;
    background: var(--ink);
    color: var(--bg);
    font-family: var(--mono);
    font-size: 0.85rem;

    &:focus {
        top: 1rem;
    }
}

main {
    flex: 1;
}

/* ---------- Hlavička ---------- */

.site-header {
    position: fixed;
    inset: 0 0 auto;
    z-index: 50;
    background: linear-gradient(to bottom, rgb(12 11 10 / 0.92), rgb(12 11 10 / 0));
}

.nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    max-width: var(--max);
    margin-inline: auto;
    padding: 1.1rem var(--gutter);
    font-family: var(--mono);
    font-size: 0.72rem;
    letter-spacing: 0.25em;
    text-transform: uppercase;

    a {
        text-decoration: none;
    }
}

.nav-brand {
    display: flex;
    gap: 0.6em;

    span {
        color: var(--muted);
    }
}

.nav-links {
    display: flex;
    gap: clamp(1rem, 3vw, 2.25rem);
    margin: 0;
    padding: 0;
    list-style: none;
}

@media (width < 34rem) {
    .nav {
        letter-spacing: 0.15em;
    }

    .nav-brand span {
        display: none;
    }
}

/* ---------- Hero / citát ---------- */

.hero {
    position: relative;
    display: grid;
    place-items: center;
    min-height: 100svh;
    padding: 6rem var(--gutter);
    text-align: center;
    overflow: hidden;
}

/* rohy hľadáčika */
.frame-corner {
    --size: clamp(1.25rem, 3vw, 2rem);
    --inset: clamp(1rem, 4vw, 3rem);
    position: absolute;
    width: var(--size);
    height: var(--size);
    border: 1px solid var(--line);
    border-color: rgb(235 227 211 / 0.35);
}
.frame-corner--tl { top: calc(var(--inset) + 3rem); left: var(--inset); border-right: 0; border-bottom: 0; }
.frame-corner--tr { top: calc(var(--inset) + 3rem); right: var(--inset); border-left: 0; border-bottom: 0; }
.frame-corner--bl { bottom: var(--inset); left: var(--inset); border-right: 0; border-top: 0; }
.frame-corner--br { bottom: var(--inset); right: var(--inset); border-left: 0; border-top: 0; }

.hero-quote {
    max-width: 52rem;
    margin: 0;

    blockquote {
        margin: 0;
    }

    p {
        font-style: italic;
        font-size: clamp(2.1rem, 1.2rem + 4.2vw, 4.75rem);
        line-height: 1.08;
        text-wrap: balance;

        &::before { content: "„"; }
        &::after { content: "“"; }
    }

    .eyebrow {
        margin-bottom: 2rem;
    }
}

.hero-quote > * {
    opacity: 0;
    animation: fade-up 1.6s var(--ease) forwards;
}
.hero-quote > blockquote {
    animation-delay: 0.5s;
}

.hero-cue {
    position: absolute;
    bottom: clamp(1.5rem, 5vw, 3rem);
    left: 50%;
    translate: -50% 0;
    color: var(--muted);
    text-decoration: none;
    font-size: 1.25rem;
    animation: cue 2.4s ease-in-out infinite;
}

@keyframes fade-up {
    from { opacity: 0; transform: translateY(1rem); filter: blur(4px); }
    to { opacity: 1; transform: none; filter: none; }
}

@keyframes cue {
    0%, 100% { transform: translateY(0); opacity: 0.5; }
    50% { transform: translateY(0.4rem); opacity: 1; }
}

/* ---------- Intro ---------- */

.intro {
    display: grid;
    justify-items: center;
    gap: clamp(2rem, 5vw, 3.5rem);
    max-width: 46rem;
    margin-inline: auto;
    padding: var(--section-gap) var(--gutter) 0;
    text-align: center;
}

.intro-title img {
    width: min(34rem, 85vw);
}

.intro-lead {
    font-size: clamp(1.25rem, 1.05rem + 0.8vw, 1.6rem);
    line-height: 1.5;
    color: var(--ink-soft);
    text-wrap: pretty;
}

/* ---------- Sekcie ---------- */

.section {
    width: 100%;
    max-width: var(--max);
    margin-inline: auto;
    padding: var(--section-gap) var(--gutter) 0;
}

.section-head {
    display: grid;
    justify-items: center;
    margin-bottom: clamp(2.5rem, 6vw, 4rem);
    text-align: center;

    h2 {
        font-size: clamp(2.5rem, 1.6rem + 3.6vw, 4.5rem);
    }

    /* filmový pás pod nadpisom */
    &::after {
        content: "";
        width: 7rem;
        height: 0.5rem;
        margin-top: 1.75rem;
        background: radial-gradient(circle, var(--muted) 0 1.5px, transparent 2px) 0 50% / 0.875rem 100% repeat-x;
        opacity: 0.6;
    }
}

.section-lead {
    max-width: 34rem;
    margin-top: 1.25rem;
    color: var(--ink-soft);
    text-wrap: balance;
}

/* ---------- Filmy ---------- */

.film-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: clamp(1.25rem, 3vw, 2.5rem) clamp(1rem, 2.5vw, 2rem);
    margin: 0;
    padding: 0;
    list-style: none;

    @media (width >= 56rem) {
        grid-template-columns: repeat(4, 1fr);
    }
}

.film-card {
    display: grid;
    gap: 0.35rem;
    text-decoration: none;
}

.film-card-poster {
    position: relative;
    display: block;
    margin-bottom: 0.75rem;
    overflow: hidden;
    background: var(--bg-raised);
    outline: 1px solid var(--line);
    outline-offset: 6px;
    transition: outline-color 0.4s var(--ease);

    img {
        aspect-ratio: 571 / 800;
        object-fit: cover;
        filter: grayscale(0.85) sepia(0.25) contrast(1.05) brightness(0.8);
        transition: filter 0.6s var(--ease), transform 0.8s var(--ease);
    }
}

.film-card-title {
    font-size: clamp(1.2rem, 1rem + 0.7vw, 1.55rem);
    line-height: 1.15;
}

.film-card-meta {
    font-family: var(--mono);
    font-size: 0.7rem;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--muted);
}

.film-card:hover,
.film-card:focus-visible {
    .film-card-poster {
        outline-color: var(--accent);
    }
    .film-card-poster img {
        filter: none;
        transform: scale(1.03);
    }
}

/* ---------- BTS ---------- */

.bts-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: clamp(0.5rem, 1.5vw, 1rem);
    margin: 0;
    padding: 0;
    list-style: none;

    @media (width >= 48rem) {
        grid-template-columns: repeat(3, 1fr);
    }
}

.bts-item {
    display: block;
    width: 100%;
    padding: 0;
    border: 0;
    background: var(--bg-raised);
    cursor: zoom-in;
    overflow: hidden;

    img {
        aspect-ratio: 3 / 2;
        object-fit: cover;
        width: 100%;
        filter: contrast(1.05) brightness(0.78);
        transition: filter 0.5s var(--ease), transform 0.8s var(--ease);
    }

    &:hover img,
    &:focus-visible img {
        filter: none;
        transform: scale(1.03);
    }
}

.lightbox {
    width: 100vw;
    max-width: none;
    height: 100dvh;
    max-height: none;
    margin: 0;
    padding: clamp(1rem, 4vw, 3rem);
    border: 0;
    background: transparent;
    color: var(--ink);

    &[open] {
        display: grid;
        place-items: center;
    }

    @media (width >= 48rem) {
        padding-inline: 5rem;
    }

    &::backdrop {
        background: rgb(5 5 4 / 0.94);
    }
}

.lightbox-img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
}

.lightbox-btn {
    position: absolute;
    z-index: 1;
    display: grid;
    place-items: center;
    width: 3rem;
    height: 3rem;
    padding: 0;
    border: 1px solid var(--line);
    background: rgb(12 11 10 / 0.6);
    color: var(--ink);
    font: 400 1.5rem/1 var(--serif);
    cursor: pointer;
    transition: border-color 0.25s, color 0.25s;

    &:hover {
        border-color: var(--accent);
        color: var(--accent);
    }
}
.lightbox-close { top: 1rem; right: 1rem; font-size: 1rem; }
.lightbox-prev { left: 1rem; top: 50%; translate: 0 -50%; }
.lightbox-next { right: 1rem; top: 50%; translate: 0 -50%; }

/* ---------- Kontakt ---------- */

.contact {
    padding-bottom: var(--section-gap);
}

.contact-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
}

.btn {
    display: grid;
    gap: 0.4rem;
    min-width: min(100%, 17rem);
    padding: 1.25rem 2rem;
    border: 1px solid var(--line);
    text-align: center;
    text-decoration: none;
    transition: border-color 0.3s var(--ease), background-color 0.3s var(--ease), color 0.3s var(--ease);

    &:hover,
    &:focus-visible {
        border-color: var(--accent);
        background: rgb(201 162 94 / 0.06);
    }
}

.btn-label {
    font-family: var(--mono);
    font-size: 0.7rem;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    color: var(--accent);
}

.btn-value {
    font-size: clamp(1.25rem, 1.1rem + 0.6vw, 1.5rem);
}

/* ---------- Detail filmu ---------- */

.film {
    width: 100%;
    max-width: 62rem;
    margin-inline: auto;
    padding: clamp(6rem, 14vw, 9rem) var(--gutter) var(--section-gap);
}

.back-link {
    display: inline-block;
    margin-bottom: clamp(2rem, 6vw, 3.5rem);
    font-family: var(--mono);
    font-size: 0.75rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    text-decoration: none;
    color: var(--muted);
}

.film-head {
    margin-bottom: clamp(2rem, 5vw, 3rem);

    h1 {
        font-size: clamp(2.75rem, 1.5rem + 5.5vw, 5.5rem);
        text-wrap: balance;
    }
}

.film-director {
    margin-top: 1rem;
    font-style: italic;
    color: var(--ink-soft);
}

.film-player {
    position: relative;
    aspect-ratio: 16 / 9;
    background: #000;
    outline: 1px solid var(--line);
    outline-offset: 8px;

    /* color-scheme musí sedieť s Vimeo dokumentom, inak ho prehliadač podloží bielou */
    iframe {
        position: absolute;
        inset: 0;
        width: 100%;
        height: 100%;
        border: 0;
        color-scheme: light;
        background: transparent;
    }
}

.film-player--scope {
    aspect-ratio: 2.35 / 1;
}

.film-body {
    display: grid;
    gap: 3rem;
    margin-top: clamp(3rem, 8vw, 5rem);

    @media (width >= 52rem) {
        grid-template-columns: 1.7fr 1fr;
        gap: 4rem;
    }
}

.film-about p {
    color: var(--ink-soft);
    text-wrap: pretty;

    & + p {
        margin-top: 1.1em;
    }
}

.film-credits dl {
    margin: 0;
}

.film-credits dt {
    margin-top: 1.25rem;
    font-family: var(--mono);
    font-size: 0.7rem;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--muted);

    &:first-child {
        margin-top: 0;
    }
}

.film-credits dd {
    margin: 0.2rem 0 0;
    line-height: 1.4;
}

.film-nav {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem 2rem;
    margin-top: clamp(4rem, 10vw, 6rem);
    padding-top: 2rem;
    border-top: 1px solid var(--line);
    font-style: italic;
    font-size: 1.2rem;

    a {
        text-decoration: none;
        color: var(--ink-soft);
    }
}

/* ---------- 404 ---------- */

.not-found {
    display: grid;
    place-content: center;
    min-height: 80svh;
    padding: 6rem var(--gutter);
    text-align: center;

    h1 {
        margin-bottom: 2rem;
        font-style: italic;
        font-size: clamp(2.25rem, 1.5rem + 3.5vw, 4rem);
    }

    .back-link {
        margin: 0;
    }
}

/* ---------- Pätička ---------- */

.site-footer {
    display: grid;
    justify-items: center;
    gap: 1rem;
    padding: 3rem var(--gutter);
    border-top: 1px solid var(--line);
    font-family: var(--mono);
    font-size: 0.7rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--muted);
}

.footer-mark {
    font-family: var(--serif);
    font-size: 1.25rem;
    letter-spacing: 0.05em;
    text-transform: none;
    color: var(--ink);
}

.footer-credit {
    margin-top: 0.5rem;
    font-size: 0.65rem;
    color: rgb(138 129 114 / 0.7);

    a {
        color: var(--ink-soft);
        text-decoration: none;
        border-bottom: 1px solid var(--line);
        padding-bottom: 0.1em;
        transition: color 0.25s var(--ease), border-color 0.25s var(--ease);

        &:hover {
            color: var(--accent);
            border-color: var(--accent);
        }
    }
}

.footer-social {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem 1.75rem;
    margin: 0;
    padding: 0;
    list-style: none;

    a {
        text-decoration: none;
    }
}

/* ---------- Scroll reveal ---------- */

.reveal {
    opacity: 0;
    transform: translateY(1.5rem);
    transition: opacity 1s var(--ease), transform 1s var(--ease);

    &.is-visible {
        opacity: 1;
        transform: none;
    }
}

/* ---------- Reduced motion ---------- */

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        animation: none !important;
        transition: none !important;
    }

    .hero-quote > *,
    .reveal {
        opacity: 1;
        transform: none;
    }
}
