/* AI프렌즈 빌드캠프 공통 토큰 · 레이아웃
   허브(/)와 jev 특강(/jev/)이 같이 씁니다. 지난 기수 아카이브 페이지는 각자 원래 스타일을 유지합니다. */

:root {
    --bg: #07080a;
    --bg-2: #0d0f13;
    --bg-3: #13161c;
    --line: #22262e;
    --line-2: #2f3540;
    --ink: #ece8e1;
    --ink-2: #b9b4ab;
    --mute: #7d8693;
    --accent: #ff5b1a;
    --accent-ink: #ff8a57;
    --accent-dim: rgba(255, 91, 26, 0.14);
    --ok: #34d399;
    --radius: 6px;
    --wrap: 1180px;
    --gutter: clamp(16px, 4vw, 40px);
    --sans: "Pretendard Variable", Pretendard, -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Malgun Gothic", sans-serif;
    --mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
    --nav-h: 64px;
}

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

html {
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
    scroll-padding-top: calc(var(--nav-h) + 12px);
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--ink);
    font-family: var(--sans);
    font-size: 16px;
    line-height: 1.7;
    word-break: keep-all;
    overflow-wrap: anywhere;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

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

a {
    color: inherit;
}

h1,
h2,
h3,
h4 {
    margin: 0;
    line-height: 1.25;
    letter-spacing: -0.02em;
    font-weight: 700;
    text-wrap: balance;
}

p {
    margin: 0;
    text-wrap: pretty;
}

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

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
}

.skip {
    position: absolute;
    left: 12px;
    top: -60px;
    z-index: 100;
    padding: 10px 14px;
    background: var(--accent);
    color: #0b0d10;
    font-weight: 700;
    text-decoration: none;
}

.skip:focus {
    top: 12px;
}

:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 3px;
}

/* ---------- 상단 내비게이션 ---------- */

.bc-nav {
    position: fixed;
    inset: 0 0 auto;
    z-index: 50;
    height: var(--nav-h);
    border-bottom: 1px solid transparent;
    transition: background-color 0.25s, border-color 0.25s;
}

.bc-nav.is-solid,
.bc-nav.is-open {
    background: rgba(7, 8, 10, 0.94);
    border-bottom-color: var(--line);
}

.bc-nav .wrap {
    display: flex;
    align-items: center;
    gap: 24px;
    height: 100%;
}

.bc-logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 800;
    font-size: 15px;
    letter-spacing: -0.01em;
    text-decoration: none;
    white-space: nowrap;
}

.bc-logo svg {
    flex: none;
}

.bc-logo small {
    font-weight: 500;
    color: var(--mute);
    font-size: 13px;
}

.bc-links {
    display: flex;
    align-items: center;
    gap: 4px;
    margin-left: auto;
    list-style: none;
    padding: 0;
    margin-top: 0;
    margin-bottom: 0;
}

.bc-links > li {
    position: relative;
}

.bc-links a,
.bc-links button {
    display: block;
    padding: 8px 12px;
    border: 0;
    background: none;
    color: var(--ink-2);
    font: inherit;
    font-size: 14px;
    text-decoration: none;
    cursor: pointer;
    border-radius: var(--radius);
    transition: color 0.2s, background-color 0.2s;
}

.bc-links a:hover,
.bc-links button:hover,
.bc-links a[aria-current="page"] {
    color: var(--ink);
    background: var(--bg-3);
}

.bc-links button::after {
    content: "";
    display: inline-block;
    width: 6px;
    height: 6px;
    margin-left: 8px;
    border-right: 1.5px solid currentColor;
    border-bottom: 1.5px solid currentColor;
    transform: translateY(-3px) rotate(45deg);
}

.bc-menu {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    width: 340px;
    padding: 8px;
    margin: 0;
    list-style: none;
    background: var(--bg-2);
    border: 1px solid var(--line-2);
    border-radius: var(--radius);
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.55);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-4px);
    transition: opacity 0.18s, transform 0.18s, visibility 0.18s;
}

.bc-links li.is-open > .bc-menu {
    opacity: 1;
    visibility: visible;
    transform: none;
}

.bc-menu a {
    display: grid;
    grid-template-columns: 64px 1fr;
    gap: 2px 12px;
    padding: 10px 12px;
    color: var(--ink);
}

.bc-menu a b {
    grid-row: span 2;
    font-family: var(--mono);
    font-size: 12px;
    font-weight: 500;
    color: var(--mute);
    padding-top: 2px;
}

.bc-menu a span {
    font-size: 14px;
    line-height: 1.4;
}

.bc-menu a em {
    font-style: normal;
    font-size: 12px;
    color: var(--mute);
}

.bc-menu a.is-live b {
    color: var(--accent);
}

.bc-cta {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 16px;
    background: var(--accent);
    color: #0b0d10;
    font-size: 14px;
    font-weight: 700;
    text-decoration: none;
    border-radius: var(--radius);
    white-space: nowrap;
    transition: background-color 0.2s;
}

.bc-cta:hover {
    background: var(--accent-ink);
}

.bc-toggle {
    display: none;
    width: 40px;
    height: 40px;
    margin-left: auto;
    border: 1px solid var(--line-2);
    border-radius: var(--radius);
    background: transparent;
    color: var(--ink);
    cursor: pointer;
}

.bc-toggle span {
    display: block;
    width: 16px;
    height: 1.5px;
    margin: 4px auto;
    background: currentColor;
    transition: transform 0.2s;
}

.bc-nav.is-open .bc-toggle span:first-child {
    transform: translateY(2.75px) rotate(45deg);
}

.bc-nav.is-open .bc-toggle span:last-child {
    transform: translateY(-2.75px) rotate(-45deg);
}

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

    .bc-nav .bc-cta {
        display: none;
    }

    .bc-links {
        position: fixed;
        top: var(--nav-h);
        left: 0;
        right: 0;
        bottom: 0;
        display: none;
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        margin: 0;
        padding: 12px var(--gutter) 40px;
        background: var(--bg);
        overflow-y: auto;
    }

    .bc-nav.is-open .bc-links {
        display: flex;
    }

    .bc-links a,
    .bc-links button {
        width: 100%;
        text-align: left;
        padding: 14px 4px;
        font-size: 17px;
        color: var(--ink);
        border-bottom: 1px solid var(--line);
        border-radius: 0;
    }

    .bc-links a:hover,
    .bc-links button:hover {
        background: none;
    }

    .bc-links button::after {
        display: none;
    }

    .bc-menu {
        position: static;
        width: auto;
        padding: 4px 0 12px;
        border: 0;
        box-shadow: none;
        background: none;
        opacity: 1;
        visibility: visible;
        transform: none;
    }

    .bc-menu a {
        padding: 10px 4px;
        font-size: 15px;
        border-bottom: 0;
    }

    .bc-links .bc-mobile-cta {
        margin-top: 20px;
        text-align: center;
        background: var(--accent);
        color: #0b0d10;
        font-weight: 700;
        border-radius: var(--radius);
        border: 0;
    }
}

@media (min-width: 901px) {
    .bc-links .bc-mobile-cta {
        display: none;
    }
}

/* ---------- 공통 섹션 요소 ---------- */

.section {
    padding: clamp(72px, 10vw, 128px) 0;
    border-top: 1px solid var(--line);
}

.eyebrow {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 18px;
    font-family: var(--mono);
    font-size: 13px;
    color: var(--mute);
}

.eyebrow b {
    color: var(--accent);
    font-weight: 500;
}

.h2 {
    font-size: clamp(28px, 4.2vw, 46px);
}

.lead {
    margin-top: 18px;
    max-width: 640px;
    color: var(--ink-2);
    font-size: clamp(16px, 1.6vw, 18px);
}

.accent {
    color: var(--accent);
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-height: 50px;
    padding: 0 22px;
    border: 1px solid var(--line-2);
    border-radius: var(--radius);
    background: transparent;
    color: var(--ink);
    font: inherit;
    font-size: 15px;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
    transition: background-color 0.2s, border-color 0.2s, color 0.2s;
}

.btn:hover {
    border-color: var(--ink-2);
}

.btn.primary {
    background: var(--accent);
    border-color: var(--accent);
    color: #0b0d10;
}

.btn.primary:hover {
    background: var(--accent-ink);
    border-color: var(--accent-ink);
}

.btn .arr {
    transition: transform 0.2s;
}

.btn:hover .arr {
    transform: translateX(3px);
}

.tag {
    display: inline-block;
    padding: 3px 8px;
    border: 1px solid var(--line-2);
    border-radius: 4px;
    font-family: var(--mono);
    font-size: 12px;
    color: var(--ink-2);
    white-space: nowrap;
}

.mono {
    font-family: var(--mono);
}

/* FAQ */

.faq {
    margin-top: 40px;
    border-top: 1px solid var(--line);
}

.faq details {
    border-bottom: 1px solid var(--line);
}

.faq summary {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    padding: 22px 0;
    font-size: clamp(16px, 1.7vw, 18px);
    font-weight: 600;
    list-style: none;
    cursor: pointer;
}

.faq summary::-webkit-details-marker {
    display: none;
}

.faq summary::before {
    content: "Q";
    flex: none;
    width: 22px;
    font-family: var(--mono);
    color: var(--accent);
    font-weight: 500;
}

.faq summary::after {
    content: "+";
    margin-left: auto;
    font-family: var(--mono);
    color: var(--mute);
    font-weight: 400;
    transition: transform 0.2s;
}

.faq details[open] summary::after {
    transform: rotate(45deg);
}

.faq .answer {
    padding: 0 40px 26px 38px;
    color: var(--ink-2);
}

.faq .answer p + p {
    margin-top: 10px;
}

/* 푸터 */

.bc-footer {
    padding: 64px 0 120px;
    border-top: 1px solid var(--line);
    color: var(--mute);
    font-size: 14px;
}

.bc-footer .grid {
    display: grid;
    grid-template-columns: 1.2fr 2fr;
    gap: 40px;
}

.bc-footer h2 {
    font-size: 13px;
    font-family: var(--mono);
    font-weight: 500;
    color: var(--ink-2);
    margin-bottom: 14px;
}

.bc-footer ul {
    list-style: none;
    padding: 0;
    margin: 0;
    columns: 2;
    column-gap: 32px;
}

.bc-footer li {
    break-inside: avoid;
    padding: 5px 0;
}

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

.bc-footer a:hover {
    color: var(--ink);
}

.bc-footer .fine {
    margin-top: 40px;
    padding-top: 24px;
    border-top: 1px solid var(--line);
    font-size: 12.5px;
    line-height: 1.8;
}

@media (max-width: 720px) {
    .bc-footer .grid {
        grid-template-columns: 1fr;
    }

    .bc-footer ul {
        columns: 1;
    }
}

/* 라이트박스 */

.lightbox {
    position: fixed;
    inset: 0;
    z-index: 90;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: rgba(3, 4, 6, 0.92);
    cursor: zoom-out;
}

.lightbox.is-open {
    display: flex;
}

.lightbox img {
    max-height: 90vh;
    width: auto;
    border: 1px solid var(--line-2);
}

.lightbox p {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 16px;
    text-align: center;
    color: var(--ink-2);
    font-size: 14px;
}

[data-zoom] {
    cursor: zoom-in;
}

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

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