/* ============================================================
   quietjoon.com  --  Ma (間) negative-space portfolio
   Palette: rice paper, sumi ink, washi tan
   ============================================================ */

:root {
    --rice-paper: #FAFAF8;
    --sumi-ink: #1A1A1A;
    --diluted-ink: #3A3A3A;
    --ink-soft: #2C2C2C;
    --stone-gray: #9E9E9E;
    --washi-tan: #C8B8A0;
    --parchment: #E8E4DC;
    --aged-wood: #6B5B4A;

    --col-width: 640px;
    --col-padding: 32px;

    --gap-md: 120px;
    --gap-lg: 200px;
    --gap-xl: 280px;
    --gap-xxl: 360px;

    --reveal-duration: 1800ms;
    --hover-duration: 300ms;
}

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

html {
    scroll-behavior: smooth;
    background-color: var(--rice-paper);
}

body {
    background-color: var(--rice-paper);
    color: var(--diluted-ink);
    font-family: "Lora", Georgia, serif;
    font-weight: 400;
    font-size: 17px;
    line-height: 1.85;
    overflow-x: hidden;
    min-height: 100vh;
    position: relative;
}

/* ------------------------------------------------------------
   Rice-paper grain texture (subtle)
   ------------------------------------------------------------ */
.paper-grain {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 0;
    opacity: 0.55;
    background-image:
        radial-gradient(circle at 20% 30%, rgba(107, 91, 74, 0.025) 1px, transparent 1.5px),
        radial-gradient(circle at 70% 60%, rgba(107, 91, 74, 0.02) 1px, transparent 1.5px),
        radial-gradient(circle at 45% 80%, rgba(26, 26, 26, 0.018) 1px, transparent 1.5px),
        radial-gradient(circle at 85% 15%, rgba(26, 26, 26, 0.022) 1px, transparent 1.5px);
    background-size: 7px 7px, 11px 11px, 13px 13px, 9px 9px;
    mix-blend-mode: multiply;
}

/* ------------------------------------------------------------
   Navigation: single character, expanding on hover
   ------------------------------------------------------------ */
.quiet-nav {
    position: fixed;
    top: 36px;
    left: 36px;
    z-index: 50;
    display: flex;
    align-items: flex-start;
    gap: 24px;
}

.nav-glyph {
    font-family: "Noto Serif KR", "Cormorant Garamond", serif;
    font-weight: 300;
    font-size: 30px;
    color: var(--sumi-ink);
    text-decoration: none;
    letter-spacing: 0;
    line-height: 1;
    transition: color var(--hover-duration) ease-in-out;
    display: inline-block;
}

.nav-glyph:hover {
    color: var(--aged-wood);
}

.nav-links {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 6px;
    opacity: 0;
    transform: translateX(-8px);
    pointer-events: none;
    transition: opacity 600ms ease-in-out, transform 600ms ease-in-out;
    padding-top: 8px;
}

.quiet-nav:hover .nav-links,
.quiet-nav.is-open .nav-links {
    opacity: 1;
    transform: translateX(0);
    pointer-events: auto;
}

.nav-links li {
    margin: 0;
}

.nav-links a {
    font-family: "IBM Plex Sans", "Inter", sans-serif;
    font-weight: 300;
    font-size: 12px;
    letter-spacing: 0.08em;
    text-transform: lowercase;
    color: var(--stone-gray);
    text-decoration: none;
    transition: color var(--hover-duration) ease-in-out;
}

.nav-links a:hover {
    color: var(--aged-wood);
}

/* ------------------------------------------------------------
   Main column: narrow, scroll-like
   ------------------------------------------------------------ */
main {
    position: relative;
    z-index: 1;
    max-width: var(--col-width);
    margin: 0 auto;
    padding: 200px var(--col-padding) 0 var(--col-padding);
}

/* Negative-space gaps */
.ma-gap {
    width: 100%;
    display: block;
}

.ma-gap-md { height: var(--gap-md); }
.ma-gap-lg { height: var(--gap-lg); }
.ma-gap-xl { height: var(--gap-xl); }
.ma-gap-xxl { height: var(--gap-xxl); }

/* ------------------------------------------------------------
   Reveal-on-scroll (the only animation type)
   ------------------------------------------------------------ */
.reveal {
    opacity: 0;
    transform: translateY(8px);
    transition:
        opacity var(--reveal-duration) ease-in-out,
        transform var(--reveal-duration) ease-in-out;
    will-change: opacity, transform;
}

.reveal.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* ------------------------------------------------------------
   Opening header
   ------------------------------------------------------------ */
.opening {
    padding-top: 40px;
}

.caption-mark {
    font-family: "IBM Plex Sans", "Inter", sans-serif;
    font-weight: 300;
    font-size: 12px;
    letter-spacing: 0.08em;
    text-transform: lowercase;
    color: var(--stone-gray);
    margin-bottom: 80px;
}

.opening-title {
    font-family: "Cormorant Garamond", "Lora", serif;
    font-weight: 300;
    font-size: clamp(48px, 8vw, 72px);
    line-height: 1.15;
    color: var(--sumi-ink);
    letter-spacing: 0.08em;
    margin-bottom: 56px;
}

.opening-title .line {
    display: block;
}

.opening-title .line-indent {
    margin-left: 1.6em;
    font-style: italic;
    font-weight: 300;
}

.opening-korean {
    font-family: "Noto Serif KR", serif;
    font-weight: 300;
    font-size: 36px;
    color: var(--ink-soft);
    letter-spacing: 0.05em;
    margin-bottom: 64px;
}

.opening-meta {
    font-family: "IBM Plex Sans", "Inter", sans-serif;
    font-weight: 300;
    font-size: 12px;
    letter-spacing: 0.08em;
    text-transform: lowercase;
    color: var(--stone-gray);
}

/* ------------------------------------------------------------
   Brushstroke dividers (SVG path-draw animation)
   ------------------------------------------------------------ */
.brush-divider {
    width: 100%;
    display: flex;
    justify-content: flex-start;
    padding: 0;
}

.brush-svg {
    width: 100%;
    max-width: 520px;
    height: 60px;
    overflow: visible;
}

.brush-path {
    fill: none;
    stroke: var(--sumi-ink);
    stroke-width: 1.3;
    stroke-linecap: round;
    stroke-linejoin: round;
    opacity: 0.78;
    stroke-dasharray: 1400;
    stroke-dashoffset: 1400;
    transition: stroke-dashoffset 3500ms ease-in;
}

.reveal.is-visible .brush-path {
    stroke-dashoffset: 0;
}

/* ------------------------------------------------------------
   Seasons (sections)
   ------------------------------------------------------------ */
.season {
    position: relative;
    padding: 0;
}

.season-tinted {
    background-image:
        linear-gradient(to bottom,
            transparent 0,
            rgba(232, 228, 220, 0.45) 60px,
            rgba(232, 228, 220, 0.45) calc(100% - 60px),
            transparent 100%);
    padding: 60px 0;
    margin-left: calc(var(--col-padding) * -1);
    margin-right: calc(var(--col-padding) * -1);
    padding-left: var(--col-padding);
    padding-right: var(--col-padding);
}

.season-header {
    margin-bottom: 0;
}

.season-meta {
    font-family: "IBM Plex Sans", "Inter", sans-serif;
    font-weight: 300;
    font-size: 12px;
    letter-spacing: 0.08em;
    text-transform: lowercase;
    color: var(--stone-gray);
    margin-bottom: 40px;
}

.season-title {
    font-family: "Cormorant Garamond", "Lora", serif;
    font-weight: 300;
    font-style: italic;
    font-size: clamp(40px, 6vw, 56px);
    line-height: 1.2;
    color: var(--sumi-ink);
    letter-spacing: 0.06em;
}

/* ------------------------------------------------------------
   Passages
   ------------------------------------------------------------ */
.passage {
    font-family: "Lora", Georgia, serif;
    font-weight: 400;
    font-size: 17px;
    line-height: 1.85;
    color: var(--diluted-ink);
    max-width: 540px;
}

.passage p + p {
    margin-top: 1.5em;
}

/* ------------------------------------------------------------
   Annotation (margin note)
   ------------------------------------------------------------ */
.annotation {
    border-left: 1px solid var(--stone-gray);
    padding: 6px 0 6px 28px;
    margin-left: 12px;
    max-width: 520px;
}

.annotation-mark {
    font-family: "IBM Plex Sans", "Inter", sans-serif;
    font-weight: 300;
    font-size: 12px;
    letter-spacing: 0.08em;
    text-transform: lowercase;
    color: var(--stone-gray);
    margin-bottom: 14px;
}

.annotation p:last-child {
    font-family: "Cormorant Garamond", "Lora", serif;
    font-style: italic;
    font-weight: 400;
    font-size: 22px;
    line-height: 1.55;
    color: var(--ink-soft);
}

/* ------------------------------------------------------------
   Ensō (incomplete circle)
   ------------------------------------------------------------ */
.enso-mark {
    display: flex;
    justify-content: center;
    padding: 20px 0;
}

.enso-svg {
    width: 100px;
    height: 100px;
    overflow: visible;
}

.enso-path {
    fill: none;
    stroke: var(--sumi-ink);
    stroke-width: 2.2;
    stroke-linecap: round;
    opacity: 0.85;
    stroke-dasharray: 280;
    stroke-dashoffset: 280;
    transition: stroke-dashoffset 4000ms ease-in;
}

.reveal.is-visible .enso-path {
    stroke-dashoffset: 0;
}

/* ------------------------------------------------------------
   Works list (summer)
   ------------------------------------------------------------ */
.works-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 110px;
}

.work {
    max-width: 560px;
}

.work-meta {
    display: flex;
    align-items: baseline;
    gap: 20px;
    margin-bottom: 14px;
}

.work-number {
    font-family: "Space Mono", "IBM Plex Sans", monospace;
    font-weight: 400;
    font-size: 12px;
    letter-spacing: 0.12em;
    color: var(--aged-wood);
}

.work-year {
    font-family: "IBM Plex Sans", "Inter", sans-serif;
    font-weight: 300;
    font-size: 12px;
    letter-spacing: 0.08em;
    text-transform: lowercase;
    color: var(--stone-gray);
}

.work-title {
    font-family: "Cormorant Garamond", "Lora", serif;
    font-weight: 300;
    font-size: 32px;
    line-height: 1.25;
    color: var(--sumi-ink);
    letter-spacing: 0.04em;
    margin-bottom: 18px;
}

.work-desc {
    font-family: "Lora", Georgia, serif;
    font-weight: 400;
    font-size: 17px;
    line-height: 1.85;
    color: var(--diluted-ink);
    margin-bottom: 22px;
}

.work-link {
    font-family: "IBM Plex Sans", "Inter", sans-serif;
    font-weight: 300;
    font-size: 12px;
    letter-spacing: 0.12em;
    text-transform: lowercase;
    color: var(--aged-wood);
    text-decoration: none;
    border-bottom: 1px solid transparent;
    padding-bottom: 2px;
    transition:
        color var(--hover-duration) ease-in-out,
        border-color var(--hover-duration) ease-in-out;
}

.work-link:hover {
    color: var(--sumi-ink);
    border-bottom-color: var(--washi-tan);
}

/* ------------------------------------------------------------
   Line illustrations
   ------------------------------------------------------------ */
.line-illustration {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 20px;
    max-width: 320px;
}

.line-illustration svg {
    width: 200px;
    height: 120px;
    overflow: visible;
}

.line-art {
    fill: none;
    stroke: var(--aged-wood);
    stroke-width: 1;
    stroke-linecap: round;
    opacity: 0.7;
    stroke-dasharray: 600;
    stroke-dashoffset: 600;
    transition: stroke-dashoffset 3800ms ease-in;
}

.line-art-thin {
    stroke-width: 0.6;
}

.reveal.is-visible .line-art {
    stroke-dashoffset: 0;
}

.line-caption {
    font-family: "IBM Plex Sans", "Inter", sans-serif;
    font-weight: 300;
    font-size: 12px;
    letter-spacing: 0.08em;
    text-transform: lowercase;
    color: var(--stone-gray);
}

/* ------------------------------------------------------------
   Quiet list (autumn arithmetic)
   ------------------------------------------------------------ */
.quiet-list {
    display: flex;
    flex-direction: column;
    gap: 36px;
    max-width: 520px;
}

.quiet-item {
    display: grid;
    grid-template-columns: 1fr 1.4fr;
    align-items: baseline;
    gap: 24px;
    padding-bottom: 20px;
    background-image: linear-gradient(to right,
        rgba(44, 44, 44, 0.35),
        rgba(44, 44, 44, 0));
    background-repeat: no-repeat;
    background-size: 200px 1px;
    background-position: left bottom;
}

.quiet-key {
    font-family: "IBM Plex Sans", "Inter", sans-serif;
    font-weight: 300;
    font-size: 12px;
    letter-spacing: 0.08em;
    text-transform: lowercase;
    color: var(--stone-gray);
}

.quiet-value {
    font-family: "Cormorant Garamond", "Lora", serif;
    font-weight: 300;
    font-style: italic;
    font-size: 22px;
    line-height: 1.4;
    color: var(--ink-soft);
}

/* ------------------------------------------------------------
   Quiet quote (winter)
   ------------------------------------------------------------ */
.quiet-quote {
    text-align: left;
    max-width: 520px;
    padding-left: 0;
}

.quote-korean {
    font-family: "Noto Serif KR", serif;
    font-weight: 300;
    font-size: 30px;
    color: var(--ink-soft);
    letter-spacing: 0.06em;
    line-height: 1.4;
    margin-bottom: 24px;
}

.quote-translation {
    font-family: "Cormorant Garamond", "Lora", serif;
    font-style: italic;
    font-weight: 300;
    font-size: 20px;
    color: var(--diluted-ink);
    letter-spacing: 0.04em;
}

/* ------------------------------------------------------------
   Letter form (correspondence)
   ------------------------------------------------------------ */
.letter-form {
    display: flex;
    flex-direction: column;
    gap: 18px;
    max-width: 480px;
}

.form-label {
    font-family: "IBM Plex Sans", "Inter", sans-serif;
    font-weight: 300;
    font-size: 12px;
    letter-spacing: 0.08em;
    text-transform: lowercase;
    color: var(--stone-gray);
}

.form-input {
    background: transparent;
    border: none;
    border-bottom: 1px solid var(--stone-gray);
    padding: 10px 0;
    font-family: "Lora", Georgia, serif;
    font-weight: 400;
    font-size: 17px;
    color: var(--ink-soft);
    outline: none;
    transition: border-color var(--hover-duration) ease-in-out;
}

.form-input::placeholder {
    color: var(--stone-gray);
    font-style: italic;
}

.form-input:hover {
    border-bottom-color: var(--aged-wood);
}

.form-submit {
    align-self: flex-start;
    margin-top: 24px;
    background: transparent;
    border: none;
    padding: 0;
    font-family: "IBM Plex Sans", "Inter", sans-serif;
    font-weight: 300;
    font-size: 12px;
    letter-spacing: 0.14em;
    text-transform: lowercase;
    color: var(--aged-wood);
    cursor: pointer;
    border-bottom: 1px solid var(--washi-tan);
    padding-bottom: 4px;
    transition: color var(--hover-duration) ease-in-out, border-color var(--hover-duration) ease-in-out;
}

.form-submit:hover {
    color: var(--sumi-ink);
    border-bottom-color: var(--sumi-ink);
}

.form-note {
    font-family: "IBM Plex Sans", "Inter", sans-serif;
    font-weight: 300;
    font-size: 12px;
    letter-spacing: 0.05em;
    color: var(--stone-gray);
    margin-top: 16px;
    line-height: 1.7;
    transition: color 800ms ease-in-out;
}

.form-note.is-acknowledged {
    color: var(--aged-wood);
}

/* ------------------------------------------------------------
   Footer
   ------------------------------------------------------------ */
.quiet-footer {
    text-align: center;
    padding: 40px 0 60px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 22px;
}

.enso-footer .enso-svg {
    width: 80px;
    height: 80px;
}

.footer-line {
    font-family: "Noto Serif KR", "Cormorant Garamond", serif;
    font-weight: 300;
    font-size: 20px;
    color: var(--ink-soft);
    letter-spacing: 0.12em;
    margin-top: 8px;
}

.footer-meta {
    font-family: "IBM Plex Sans", "Inter", sans-serif;
    font-weight: 300;
    font-size: 12px;
    letter-spacing: 0.08em;
    text-transform: lowercase;
    color: var(--stone-gray);
}

.footer-year {
    margin-top: 6px;
    color: var(--stone-gray);
    opacity: 0.7;
}

/* ------------------------------------------------------------
   Subtle dot grid (background suggestion on tinted seasons)
   ------------------------------------------------------------ */
.season-tinted::before {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    background-image: radial-gradient(circle, var(--parchment) 1px, transparent 1.5px);
    background-size: 40px 40px;
    background-position: 0 0;
    opacity: 0.45;
    mix-blend-mode: multiply;
}

/* ------------------------------------------------------------
   Responsive: keep the same single column, adjust gaps
   ------------------------------------------------------------ */
@media (max-width: 720px) {
    :root {
        --gap-md: 80px;
        --gap-lg: 140px;
        --gap-xl: 200px;
        --gap-xxl: 260px;
        --col-padding: 24px;
    }

    main {
        padding-top: 140px;
    }

    .quiet-nav {
        top: 22px;
        left: 22px;
    }

    .nav-glyph {
        font-size: 26px;
    }

    .nav-links {
        gap: 4px;
    }

    .opening-title .line-indent {
        margin-left: 0.8em;
    }

    .quiet-item {
        grid-template-columns: 1fr;
        gap: 6px;
    }

    .works-list {
        gap: 80px;
    }
}
