@import url('https://cdn.jsdelivr.net/gh/orioncactus/pretendard@v1.3.9/dist/web/variable/pretendardvariable-dynamic-subset.css');

/* ==========================================================================
   Ohmuse — design tokens
   ========================================================================== */

:root {
    --bg:           #0a0e14;
    --bg-alt:       #0d1219;
    --surface:      #12171f;
    --surface-2:    #161d27;
    --surface-3:    #1a2430;
    --border:       #232c38;
    --border-hi:    #39465a;

    --text:         #e8ecf1;
    --text-2:       #b9c4d0;
    --muted:        #94a3b3;
    --dim:          #7c8b9c;

    --accent:       #4da3ff;
    --accent-soft:  #1a2430;
    --amber:        #ffb454;

    --font: 'Pretendard Variable', Pretendard, -apple-system, BlinkMacSystemFont,
            'Malgun Gothic', 'Apple SD Gothic Neo', system-ui, sans-serif;
    --mono: 'JetBrains Mono', 'SFMono-Regular', Consolas, 'Liberation Mono', monospace;

    --max:      1180px;
    --narrow:   760px;
    --radius:   14px;
    --radius-s: 9px;

    --ease: cubic-bezier(.22, .61, .36, 1);
}

*, *::before, *::after { box-sizing: border-box; }

html {
    scroll-behavior: smooth;
    scroll-padding-top: 88px;
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: var(--font);
    font-size: 1rem;
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
    /* clip: hidden 과 달리 body 를 스크롤 컨테이너로 만들지 않는다
       (hidden 이면 sticky 헤더와 scrollIntoView 가 어긋난다) */
    overflow-x: clip;
    /* 한국어는 어절 중간에서 줄바꿈되지 않도록 */
    word-break: keep-all;
    overflow-wrap: break-word;
}

img { max-width: 100%; height: auto; display: block; }
a   { color: inherit; text-decoration: none; }

h1, h2, h3, h4 { margin: 0; line-height: 1.25; font-weight: 700; letter-spacing: -.02em; }
p  { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }

::selection { background: var(--accent); color: #05080d; }

:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 3px;
    border-radius: 4px;
}

/* ==========================================================================
   Layout primitives
   ========================================================================== */

.row {
    width: 100%;
    max-width: var(--max);
    margin-inline: auto;
    padding-inline: 24px;
}

.section        { padding-block: clamp(72px, 9vw, 128px); }
.section--alt   { background: var(--bg-alt); border-block: 1px solid var(--border); }

.section__head  { max-width: var(--narrow); margin-bottom: clamp(36px, 5vw, 60px); }

.eyebrow {
    display: inline-block;
    margin-bottom: 14px;
    color: var(--accent);
    font-size: .75rem;
    font-weight: 700;
    letter-spacing: .16em;
    text-transform: uppercase;
}

.section__title {
    font-size: clamp(1.75rem, 3.6vw, 2.6rem);
    margin-bottom: 16px;
}

.section__lead {
    color: var(--muted);
    font-size: clamp(1rem, 1.5vw, 1.1rem);
}

/* ==========================================================================
   Header / navigation
   ========================================================================== */

.header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(10, 14, 20, .72);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-bottom: 1px solid transparent;
    transition: border-color .3s var(--ease), background .3s var(--ease);
}

.header.is-stuck {
    border-bottom-color: var(--border);
    background: rgba(10, 14, 20, .93);
}

.header__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    height: 72px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 1.15rem;
    font-weight: 800;
    letter-spacing: -.03em;
}

.brand__logo {
    width: auto;
    height: 30px;
}

.nav__items {
    display: flex;
    align-items: center;
    gap: 30px;
}

.nav__link {
    color: var(--text-2);
    font-size: .94rem;
    font-weight: 500;
    transition: color .2s var(--ease);
}

.nav__link:hover { color: var(--text); }

.nav__cta {
    padding: 9px 18px;
    border: 1px solid var(--border-hi);
    border-radius: 999px;
    color: var(--text);
    font-size: .9rem;
    font-weight: 600;
    transition: background .2s var(--ease), border-color .2s var(--ease);
}

.nav__cta:hover { background: var(--surface-3); border-color: var(--accent); }

.nav__toggle {
    display: none;
    width: 42px;
    height: 42px;
    padding: 0;
    background: none;
    border: 1px solid var(--border);
    border-radius: 10px;
    color: var(--text);
    cursor: pointer;
}

/* ==========================================================================
   Hero
   ========================================================================== */

.hero {
    position: relative;
    padding-block: clamp(72px, 12vw, 150px) clamp(56px, 7vw, 92px);
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(var(--border) 1px, transparent 1px),
        linear-gradient(90deg, var(--border) 1px, transparent 1px);
    background-size: 68px 68px;
    opacity: .28;
    mask-image: radial-gradient(ellipse 80% 62% at 50% 34%, #000 25%, transparent 78%);
    -webkit-mask-image: radial-gradient(ellipse 80% 62% at 50% 34%, #000 25%, transparent 78%);
    pointer-events: none;
}

.hero::after {
    content: '';
    position: absolute;
    top: -22%;
    left: 50%;
    width: min(1100px, 130vw);
    aspect-ratio: 2 / 1;
    translate: -50% 0;
    background: radial-gradient(ellipse at center, rgba(77, 163, 255, .16), transparent 62%);
    pointer-events: none;
}

.hero__inner { position: relative; z-index: 1; }

.hero__badge {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    margin-bottom: 26px;
    padding: 7px 15px;
    background: var(--accent-soft);
    border: 1px solid var(--border-hi);
    border-radius: 999px;
    color: var(--text-2);
    font-size: .82rem;
    font-weight: 500;
}

.hero__badge b { color: var(--accent); font-weight: 700; }

.hero__title {
    max-width: 17ch;
    font-size: clamp(2.2rem, 6.2vw, 4.2rem);
    line-height: 1.16;
    letter-spacing: -.035em;
}

.hero__title em {
    font-style: normal;
    background: linear-gradient(100deg, var(--accent), #9ad0ff);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.hero__lead {
    max-width: 54ch;
    margin-top: 26px;
    color: var(--muted);
    font-size: clamp(1rem, 1.9vw, 1.2rem);
}

.hero__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-top: 38px;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    padding: 14px 26px;
    border: 1px solid transparent;
    border-radius: 999px;
    font-size: .96rem;
    font-weight: 600;
    cursor: pointer;
    transition: transform .2s var(--ease), background .2s var(--ease),
                border-color .2s var(--ease);
}

.btn--primary { background: var(--accent); color: #05080d; }
.btn--primary:hover { background: #6cb4ff; transform: translateY(-2px); }

.btn--ghost { border-color: var(--border-hi); color: var(--text); }
.btn--ghost:hover { background: var(--surface-2); border-color: var(--accent); transform: translateY(-2px); }

/* stats */

.stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1px;
    margin-top: clamp(48px, 6vw, 72px);
    background: var(--border);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
}

.stat { padding: 26px 22px; background: var(--surface); }

.stat__num {
    display: block;
    font-size: clamp(1.6rem, 3.4vw, 2.3rem);
    font-weight: 800;
    letter-spacing: -.03em;
    /* 수치가 포인트 색, 단위는 흰색 */
    color: var(--accent);
}

.stat__num sup { font-size: .5em; color: var(--text); top: -.7em; }

.stat__label { display: block; margin-top: 4px; color: var(--muted); font-size: .86rem; }

/* ==========================================================================
   Marquee
   ========================================================================== */

.marquee {
    padding-block: 10px 0;
    border-block: 1px solid var(--border);
    background: var(--bg-alt);
    overflow: hidden;
    mask-image: linear-gradient(90deg, transparent, #000 7%, #000 93%, transparent);
    -webkit-mask-image: linear-gradient(90deg, transparent, #000 7%, #000 93%, transparent);
}

.marquee__track {
    display: flex;
    width: max-content;
    gap: 14px;
    padding-block: 22px;
    animation: marquee 68s linear infinite;
}

.marquee:hover .marquee__track { animation-play-state: paused; }

.marquee__item {
    flex: none;
    height: 150px;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: var(--surface);
    overflow: hidden;
}

.marquee__item img {
    height: 100%;
    width: auto;
    object-fit: cover;
    opacity: .82;
    transition: opacity .3s var(--ease);
}

.marquee__item:hover img { opacity: 1; }

@keyframes marquee {
    from { transform: translateX(0); }
    to   { transform: translateX(calc(-50% - 7px)); }
}

/* ==========================================================================
   Services grid
   ========================================================================== */

.grid-3 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
}

.svc {
    display: flex;
    flex-direction: column;
    padding: 28px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    transition: border-color .25s var(--ease), transform .25s var(--ease),
                background .25s var(--ease);
}

.svc:hover {
    border-color: var(--border-hi);
    background: var(--surface-2);
    transform: translateY(-3px);
}

.svc__no {
    font-family: var(--mono);
    font-size: .78rem;
    font-weight: 700;
    letter-spacing: .1em;
    color: var(--accent);
}

.svc__title { margin: 12px 0 10px; font-size: 1.22rem; }

.svc__desc { color: var(--muted); font-size: .94rem; }

.svc__tags {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    margin-top: 20px;
    padding-top: 18px;
    border-top: 1px solid var(--border);
}

.tag {
    padding: 4px 11px;
    background: var(--surface-3);
    border-radius: 999px;
    color: var(--text-2);
    font-size: .76rem;
    font-weight: 500;
}

/* ==========================================================================
   Featured work
   ========================================================================== */

.works { display: grid; gap: 22px; }

.work {
    display: grid;
    grid-template-columns: 1fr 1fr;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    transition: border-color .25s var(--ease);
}

.work:hover { border-color: var(--border-hi); }

.work--wide { grid-template-columns: 1fr; }

.work__body {
    display: flex;
    flex-direction: column;
    padding: clamp(28px, 3.4vw, 44px);
}

.work__meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    margin-bottom: 16px;
}

.chip {
    padding: 4px 11px;
    border: 1px solid var(--border-hi);
    border-radius: 999px;
    font-size: .74rem;
    font-weight: 600;
    letter-spacing: .04em;
    color: var(--muted);
}

.chip--role { background: var(--accent-soft); border-color: var(--accent); color: var(--accent); }

.work__title { font-size: clamp(1.3rem, 2.3vw, 1.7rem); margin-bottom: 8px; }

.work__client { color: var(--dim); font-size: .9rem; margin-bottom: 20px; }

.work__problem {
    padding: 16px 18px;
    margin-bottom: 18px;
    background: var(--bg-alt);
    border-left: 2px solid var(--amber);
    border-radius: 0 var(--radius-s) var(--radius-s) 0;
    color: var(--text-2);
    font-size: .93rem;
}

.work__problem b { color: var(--amber); font-weight: 700; }

.work__desc { color: var(--muted); font-size: .95rem; }

.work__facts {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 1px;
    margin-top: 24px;
    background: var(--border);
    border: 1px solid var(--border);
    border-radius: var(--radius-s);
    overflow: hidden;
}

.fact { padding: 14px 16px; background: var(--bg-alt); }
.fact__num   { display: block; font-size: 1.2rem; font-weight: 800; color: var(--accent); letter-spacing: -.02em; }
.fact__label { display: block; margin-top: 2px; color: var(--dim); font-size: .78rem; }

.work__stack {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    margin-top: auto;
    padding-top: 24px;
}

.work__stack span {
    font-family: var(--mono);
    font-size: .74rem;
    color: var(--dim);
    padding: 3px 9px;
    border: 1px solid var(--border);
    border-radius: 5px;
}

/* media side */

.work__media {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: clamp(24px, 3vw, 40px);
    background:
        radial-gradient(ellipse at 50% 0%, rgba(77, 163, 255, .09), transparent 68%),
        var(--bg-alt);
    border-left: 1px solid var(--border);
    overflow: hidden;
}

.work--wide .work__media { border-left: 0; border-top: 1px solid var(--border); }

.work--flip .work__body  { order: 2; }
.work--flip .work__media { order: 1; border-left: 0; border-right: 1px solid var(--border); }

.shots {
    display: flex;
    gap: 12px;
    align-items: flex-end;
    justify-content: center;
    width: 100%;
}

.shots img {
    flex: 1 1 0;
    min-width: 0;
    max-height: 340px;
    object-fit: contain;
    border-radius: 10px;
    border: 1px solid var(--border);
    background: var(--surface);
    box-shadow: 0 18px 40px rgba(0, 0, 0, .45);
    transition: transform .3s var(--ease);
}

.shots img:nth-child(2) { transform: translateY(-14px); }
.work:hover .shots img:nth-child(2) { transform: translateY(-20px); }

.shots--wide img { max-height: 300px; object-fit: cover; }

/* 가로가 긴 이미지를 두 장 이상 놓을 때는 세로로 쌓아야 내용이 보인다 */
.shots--stack { flex-direction: column; align-items: stretch; gap: 14px; }
.shots--stack img { width: 100%; max-height: 210px; object-fit: cover; }
.shots--stack img:nth-child(2) { transform: none; }
.work:hover .shots--stack img:nth-child(2) { transform: none; }

.diagram { width: 100%; max-width: 980px; }

/* secondary work grid */

.more {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 18px;
    margin-top: 22px;
}

.mini {
    display: flex;
    flex-direction: column;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    transition: border-color .25s var(--ease), transform .25s var(--ease);
}

.mini:hover { border-color: var(--border-hi); transform: translateY(-3px); }

.mini__thumb {
    height: 168px;
    background: var(--bg-alt);
    border-bottom: 1px solid var(--border);
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mini__thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top center;
    opacity: .9;
    transition: transform .4s var(--ease), opacity .3s var(--ease);
}

.mini:hover .mini__thumb img { transform: scale(1.04); opacity: 1; }

.mini__body { padding: 20px 22px 24px; }
.mini__cat   { color: var(--accent); font-size: .74rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; }
.mini__title { margin: 8px 0 8px; font-size: 1.05rem; }
.mini__desc  { color: var(--muted); font-size: .88rem; }

/* ==========================================================================
   Capabilities
   ========================================================================== */

.caps { display: grid; gap: 1px; background: var(--border); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }

.cap {
    display: grid;
    grid-template-columns: 220px 1fr;
    gap: 24px;
    padding: 24px 28px;
    background: var(--surface);
}

.cap__name { font-size: 1rem; font-weight: 700; color: var(--text); }
.cap__name span { display: block; margin-top: 3px; color: var(--dim); font-size: .78rem; font-weight: 500; letter-spacing: .06em; }

.cap__items { display: flex; flex-wrap: wrap; gap: 8px; align-content: flex-start; }

.cap__items li {
    font-family: var(--mono);
    font-size: .78rem;
    color: var(--text-2);
    padding: 4px 10px;
    background: var(--surface-3);
    border-radius: 6px;
}

/* ==========================================================================
   Clients
   ========================================================================== */

.clients {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(255px, 1fr));
    gap: 1px;
    background: var(--border);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
}

.client { padding: 26px 24px; background: var(--surface); transition: background .25s var(--ease); }
.client:hover { background: var(--surface-2); }

.client__name   { font-size: 1.02rem; font-weight: 700; letter-spacing: -.01em; }
.client__domain { margin-top: 5px; color: var(--dim); font-size: .82rem; }

.clients__note { margin-top: 18px; color: var(--dim); font-size: .84rem; }

/* ==========================================================================
   Process
   ========================================================================== */

.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 20px; }

.step { position: relative; padding: 28px 24px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); }

.step__no {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    margin-bottom: 16px;
    background: var(--accent-soft);
    border: 1px solid var(--accent);
    border-radius: 9px;
    color: var(--accent);
    font-family: var(--mono);
    font-size: .84rem;
    font-weight: 700;
}

.step__title { font-size: 1.08rem; margin-bottom: 8px; }
.step__desc  { color: var(--muted); font-size: .92rem; }

/* ==========================================================================
   About
   ========================================================================== */

.about { display: grid; grid-template-columns: 1.15fr .85fr; gap: clamp(32px, 5vw, 72px); align-items: start; }

.about__text p + p { margin-top: 18px; }
.about__text p { color: var(--text-2); font-size: 1.02rem; }
.about__text strong { color: var(--text); font-weight: 700; }

.profile { padding: 28px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); }
.profile__name { font-size: 1.2rem; }
.profile__role { margin-top: 4px; color: var(--accent); font-size: .9rem; font-weight: 600; }

.profile__list { margin-top: 22px; padding-top: 20px; border-top: 1px solid var(--border); display: grid; gap: 14px; }
.profile__list li { display: grid; grid-template-columns: 96px 1fr; gap: 14px; font-size: .9rem; }
.profile__list dt, .profile__list b { color: var(--dim); font-weight: 500; }
.profile__list span { color: var(--text-2); }

/* ==========================================================================
   Contact
   ========================================================================== */

.contact__box {
    display: grid;
    grid-template-columns: 1.1fr .9fr;
    gap: clamp(32px, 5vw, 64px);
    padding: clamp(32px, 5vw, 64px);
    background:
        radial-gradient(ellipse at 12% 0%, rgba(77, 163, 255, .12), transparent 58%),
        var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
}

.contact__title { font-size: clamp(1.6rem, 3.2vw, 2.3rem); margin-bottom: 16px; }
.contact__lead  { color: var(--muted); }

.contact__mail {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-top: 28px;
    font-size: clamp(1.1rem, 2.4vw, 1.5rem);
    font-weight: 700;
    color: var(--accent);
    letter-spacing: -.02em;
    border-bottom: 1px solid transparent;
    transition: border-color .2s var(--ease);
}

.contact__mail:hover { border-bottom-color: var(--accent); }

.contact__intro { align-self: start; }

.contact__item { padding: 16px 18px; margin-top: 14px; background: var(--bg-alt); border: 1px solid var(--border); border-radius: var(--radius-s); }
.contact__item:first-of-type { margin-top: 32px; }
.contact__item dt { color: var(--dim); font-size: .78rem; letter-spacing: .06em; text-transform: uppercase; }
.contact__item dd { margin: 6px 0 0; color: var(--text-2); font-size: .93rem; }

/* ==========================================================================
   Contact form
   ========================================================================== */

.form { display: grid; gap: 18px; align-content: start; }

.form__row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }

.field { display: grid; gap: 7px; min-width: 0; }

.field label {
    color: var(--text-2);
    font-size: .86rem;
    font-weight: 600;
}

.field label span[aria-hidden] { color: var(--accent); }

.field__opt {
    margin-left: 4px;
    color: var(--dim);
    font-size: .76rem;
    font-weight: 500;
}

.field input[type="text"],
.field input[type="email"],
.field input[type="tel"],
.field select,
.field textarea {
    width: 100%;
    padding: 12px 14px;
    background: var(--bg-alt);
    border: 1px solid var(--border);
    border-radius: var(--radius-s);
    color: var(--text);
    font-family: inherit;
    font-size: .94rem;
    line-height: 1.55;
    transition: border-color .2s var(--ease), background .2s var(--ease);
}

.field textarea { resize: vertical; min-height: 130px; }

.field select {
    appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' fill='none'%3E%3Cpath d='M1 1.5 6 6.5l5-5' stroke='%2394a3b3' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 38px;
    cursor: pointer;
}

.field ::placeholder { color: var(--dim); opacity: 1; }

.field input:focus,
.field select:focus,
.field textarea:focus {
    outline: none;
    border-color: var(--accent);
    background: var(--surface-2);
}

.field.is-invalid input,
.field.is-invalid select,
.field.is-invalid textarea { border-color: #ff6b6b; }

.field__err {
    display: none;
    color: #ff8c8c;
    font-size: .82rem;
}

.field.is-invalid .field__err { display: block; }

/* 동의 체크박스 */

.field--check { gap: 7px; }

.checkbox {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 11px;
    align-items: start;
    color: var(--muted);
    font-size: .86rem;
    font-weight: 400;
    line-height: 1.6;
    cursor: pointer;
}

.checkbox input {
    width: 18px;
    height: 18px;
    margin: 2px 0 0;
    accent-color: var(--accent);
    cursor: pointer;
}

.checkbox a { color: var(--accent); border-bottom: 1px solid transparent; }
.checkbox a:hover { border-bottom-color: var(--accent); }

/* 보조 입력 영역 — 화면과 스크린리더 모두에서 빼둔다 */

.form__aux,
.form__ext {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

/* 제출 버튼 / 상태 */

.form__submit { justify-content: center; margin-top: 4px; }

.form__spinner { display: none; animation: spin .8s linear infinite; }

.form.is-sending .form__spinner { display: block; }
.form.is-sending .form__submit { pointer-events: none; opacity: .65; }

@keyframes spin { to { transform: rotate(360deg); } }

.form__status {
    display: none;
    padding: 14px 16px;
    border-radius: var(--radius-s);
    font-size: .9rem;
}

.form__status.is-ok {
    display: block;
    background: rgba(77, 163, 255, .1);
    border: 1px solid var(--accent);
    color: var(--text);
}

.form__status.is-error {
    display: block;
    background: rgba(255, 107, 107, .1);
    border: 1px solid #ff6b6b;
    color: #ffc9c9;
}

/* ==========================================================================
   Footer
   ========================================================================== */

.footer { padding-block: 56px 44px; background: var(--bg-alt); border-top: 1px solid var(--border); }

.footer__top {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 24px;
    padding-bottom: 28px;
    margin-bottom: 28px;
    border-bottom: 1px solid var(--border);
}

.footer__links { display: flex; flex-wrap: wrap; gap: 24px; }
.footer__links a { color: var(--muted); font-size: .9rem; transition: color .2s var(--ease); }
.footer__links a:hover { color: var(--text); }

.biz { display: flex; flex-wrap: wrap; gap: 8px 22px; color: var(--dim); font-size: .84rem; }
.biz b { color: var(--muted); font-weight: 500; }

.footer__copy { margin-top: 20px; color: var(--dim); font-size: .82rem; }

/* ==========================================================================
   Back to top
   ========================================================================== */

.back-to-top {
    position: fixed;
    right: 22px;
    bottom: 22px;
    z-index: 40;
    display: grid;
    place-items: center;
    width: 46px;
    height: 46px;
    background: var(--surface-2);
    border: 1px solid var(--border-hi);
    border-radius: 50%;
    color: var(--text);
    opacity: 0;
    visibility: hidden;
    transform: scale(.8);
    transition: opacity .25s var(--ease), transform .25s var(--ease),
                visibility .25s var(--ease), background .2s var(--ease);
}

.back-to-top.is-visible { opacity: 1; visibility: visible; transform: scale(1); }
.back-to-top:hover { background: var(--accent); color: #05080d; }

/* ==========================================================================
   Reveal on scroll
   ========================================================================== */

.reveal {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity .6s var(--ease), transform .6s var(--ease);
}

.reveal.is-in { opacity: 1; transform: none; }

/* ==========================================================================
   Document pages (개인정보처리방침 등)
   ========================================================================== */

.doc { padding-block: clamp(48px, 7vw, 88px) clamp(64px, 8vw, 104px); }

.doc__head {
    padding-bottom: 28px;
    margin-bottom: 40px;
    border-bottom: 1px solid var(--border);
}

.doc__title { font-size: clamp(1.8rem, 4vw, 2.6rem); }

.doc__dates {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 22px;
    margin-top: 14px;
    color: var(--dim);
    font-size: .86rem;
}

.doc__body { max-width: 860px; }

.doc__body h2 {
    margin: 48px 0 16px;
    padding-top: 28px;
    border-top: 1px solid var(--border);
    font-size: 1.22rem;
}

.doc__body h2:first-of-type { margin-top: 0; padding-top: 0; border-top: 0; }

.doc__body h3 { margin: 26px 0 10px; font-size: 1rem; color: var(--accent); }

.doc__body p { margin: 12px 0; color: var(--text-2); font-size: .96rem; }

.doc__body ul { margin: 12px 0; padding-left: 0; }

.doc__body li {
    position: relative;
    margin: 8px 0;
    padding-left: 18px;
    color: var(--muted);
    font-size: .93rem;
}

.doc__body li::before {
    content: '';
    position: absolute;
    left: 2px;
    top: .72em;
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--border-hi);
}

.doc__body li ul { margin: 6px 0 0; }
.doc__body li li::before { background: none; border: 1px solid var(--border-hi); }

.doc__toc {
    padding: 24px 26px;
    margin-bottom: 8px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
}

.doc__toc ol { margin: 0; padding-left: 20px; display: grid; gap: 7px; }
.doc__toc li { color: var(--text-2); font-size: .92rem; padding-left: 0; }
.doc__toc li::before { content: none; }
.doc__toc a { color: var(--text-2); transition: color .2s var(--ease); }
.doc__toc a:hover { color: var(--accent); }

.doc__contact {
    display: grid;
    gap: 10px;
    padding: 22px 24px;
    margin: 16px 0;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-s);
}

.doc__contact div { display: grid; grid-template-columns: 110px 1fr; gap: 14px; font-size: .93rem; }
.doc__contact dt { color: var(--dim); }
.doc__contact dd { margin: 0; color: var(--text-2); }

.doc__back {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 26px;
    color: var(--muted);
    font-size: .9rem;
    transition: color .2s var(--ease);
}

.doc__back:hover { color: var(--accent); }

@media (max-width: 560px) {
    .doc__contact div { grid-template-columns: 1fr; gap: 2px; }
}

/* ==========================================================================
   Responsive
   ========================================================================== */

@media (max-width: 1000px) {
    .work,
    .about,
    .contact__box { grid-template-columns: 1fr; }

    .work__media  { border-left: 0; border-top: 1px solid var(--border); }
    .work--flip   { direction: ltr; }
    .work--flip .work__media { border-right: 0; border-top: 1px solid var(--border); }

    .cap { grid-template-columns: 1fr; gap: 14px; }
    .stats { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 760px) {
    .form__row { grid-template-columns: 1fr; }

    .nav__items { display: none; }
    .nav__items.is-open {
        display: flex;
        position: absolute;
        inset: 72px 0 auto;
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        padding: 12px 24px 22px;
        background: var(--bg);
        border-bottom: 1px solid var(--border);
        box-shadow: 0 18px 30px rgba(0, 0, 0, .45);
    }
    .nav__items.is-open li { border-bottom: 1px solid var(--border); }
    .nav__items.is-open li:last-child { border-bottom: 0; padding-top: 14px; }
    .nav__items.is-open .nav__link { display: block; padding: 14px 0; font-size: 1rem; }
    .nav__toggle { display: grid; place-items: center; }

    .shots img { max-height: 260px; }
    .btn { flex: 1 1 auto; justify-content: center; }
    .profile__list li { grid-template-columns: 82px 1fr; }
}

@media (max-width: 460px) {
    .row { padding-inline: 18px; }
    .stats { grid-template-columns: 1fr; }
    .marquee__item { height: 120px; }
}

/* ==========================================================================
   Motion / print preferences
   ========================================================================== */

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after {
        animation-duration: .001ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: .001ms !important;
    }
    .reveal { opacity: 1; transform: none; }
    .marquee__track { animation: none; }
}
