/* ROIGENT — shared site styles
 * 브랜드 규칙: .claude/skills/roigent-brand/SKILL.md
 * 컬러 원본:  brand/color/tokens.css
 *
 * 팔레트 원칙
 *  - 바탕은 화이트, 면 분할은 연한 그레이
 *  - 코랄레드는 프라이머리. CTA·아이콘·큰 숫자 등 결정적인 곳에만
 *  - 블랙은 무게중심(본문·다크 섹션), 세이지는 태그·아이콘 면
 */

/* 서브셋 폰트 — 원본 6.4MB TTF 에서 상용 한글 2,350자만 남겨 440KB woff2 로 압축.
 * 로컬 파일만 사용한다 (CDN 금지 — 브랜드 규칙). */
@font-face {
    font-family: "Pretendard";
    src: url("assets/fonts/pretendard-subset.woff2") format("woff2-variations"),
         url("assets/fonts/pretendard-subset.woff2") format("woff2");
    font-weight: 100 900;
    font-style: normal;
    font-display: swap;
}

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

:root {
    /* ===== 사이트 코어 =====
     * CI 확정 4색 중 Deep Brown(#462a2a) 자리는 웹에서 블랙으로 대체한다.
     * 화면을 더 선명하게 가져가기 위한 결정. 코랄·세이지는 CI 그대로 쓴다.
     * 헤더 CI 원본의 워드마크가 실제로 블랙이라 로고와도 어긋나지 않는다. */
    --ink: #000000;
    --coral: #e9483d;
    --sage: #bdd9d1;
    --offwhite: #f1f1f1;

    /* ===== 파생값 — 팔레트 추가가 아니라 위 색들의 명도 변형 ===== */
    --ink-hover: #262626;
    --coral-hover: #d33e34;
    --coral-soft: #fdecea;      /* 코랄 10% 틴트 — 태그·아이콘 면 */
    --link: #b8392e;            /* 본문 링크 전용. 흰 배경 5.7:1 (코랄 3.8:1 은 AA 미달) */
    --sage-soft: #e4f0ec;

    /* ===== 중립 — 화이트 바탕 + 연한 그레이 =====
     * 브라운이 빠졌으므로 웜 틴트를 걷고 순수 그레이로 간다. 이게 더 선명하다. */
    --bg: #ffffff;
    --bg-soft: #f9f9f9;         /* 섹션 교차용 */
    --bg-muted: var(--offwhite);/* 더 강한 면 분할 */
    --bg-dark: var(--ink);
    --border: #e5e5e5;
    --border-soft: #f0f0f0;

    /* ===== 텍스트 — 전부 흰 배경 WCAG AA 이상 ===== */
    --text: #111111;            /* 18.9:1 — 본문. 순수 블랙은 장문에서 눈이 피로해 한 단계 낮췄다 */
    --text-light: #4a4a4a;      /*  8.9:1 — 보조 */
    --text-muted: #6b6b6b;      /*  5.3:1 — 메타·캡션 */

    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.07);
    --shadow-lg: 0 18px 36px rgba(0, 0, 0, 0.10);

    --radius: 10px;
    --radius-lg: 16px;
    --radius-xl: 24px;

    /* ===== 구 변수 별칭 =====
     * HTML 인라인 스타일 92곳이 아직 아래 이름을 참조한다.
     * 값만 브랜드 컬러로 돌려두고, 인라인 정리 후 삭제한다.
     *  --accent 는 12px 텍스트에도 쓰이므로 코랄(3.8:1) 대신 --link(5.7:1) 로 연결
     *  --accent-2 는 11곳 모두 다크 배경 위 → 세이지 (블랙 대비 15.6:1) */
    --primary: var(--ink);
    --primary-2: #333333;
    --accent: var(--link);
    --accent-2: var(--sage);
    --accent-soft: var(--coral-soft);
}

html { scroll-behavior: smooth; }

body {
    /* Pretendard 를 맨 앞에 둔다. -apple-system 이 앞서면 맥에서 영영 적용되지 않는다. */
    font-family: "Pretendard", -apple-system, BlinkMacSystemFont,
                 system-ui, "Malgun Gothic", sans-serif;
    color: var(--text);
    line-height: 1.65;
    background: var(--bg);
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    word-break: keep-all;       /* 한글은 단어 중간에서 끊지 않는다 */
    overflow-wrap: break-word;
}

/* 본문 링크는 --link. 밑줄 색만 코랄로 두어 브랜드를 남긴다. */
a {
    color: var(--link);
    text-decoration: none;
}

.article-body a {
    text-decoration: underline;
    text-decoration-color: var(--coral);
    text-underline-offset: 3px;
}

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

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

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

.container-narrow {
    max-width: 820px;
    margin: 0 auto;
    padding: 0 24px;
}

/* ===== Header / Nav ===== */
header.site-header {
    position: sticky;
    top: 0;
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
    z-index: 100;
}

.nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 0;
}

/* ===== 로고 =====
 * CI 원본 이미지를 그대로 쓴다. 비율 변형·간격 조정은 브랜드 금지 사항이므로
 * height 만 지정하고 width 는 auto 로 둔다.
 *  헤더(흰 배경)  → roigent-ci.png       심볼 코랄 + 워드마크 다크
 *  푸터(블랙)     → roigent-ci-light.png 심볼 코랄 + 워드마크 화이트 */
.logo {
    display: inline-flex;
    align-items: center;
}

.logo img {
    display: block;
    height: 34px;
    width: auto;
}

footer .logo img { height: 30px; }

/* 이미지 로고로 교체되기 전 텍스트 워드마크가 남아 있을 때의 대비값 */
.logo { font-size: 22px; font-weight: 700; color: var(--ink); letter-spacing: -0.5px; }
.logo span { color: var(--coral); }

.nav-links {
    display: flex;
    gap: 28px;
    list-style: none;
}

.nav-links a {
    color: var(--text-light);
    text-decoration: none;
    font-size: 15px;
    font-weight: 500;
    transition: color 0.15s;
}

/* 15px 이라 코랄은 대비 미달. 명도를 낮춰 상태를 표현한다. */
.nav-links a:hover,
.nav-links a.active {
    color: var(--ink);
}

/* 헤더 CTA 는 블랙. 코랄은 본문 CTA 에만 남겨 희소성을 지킨다. */
.nav-cta {
    background: var(--ink);
    color: white !important;
    padding: 10px 20px;
    border-radius: 8px;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    transition: background 0.2s;
}

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

.menu-toggle { display: none; background: none; border: none; font-size: 24px; cursor: pointer; color: var(--ink); }

/* ===== Buttons =====
 * 코랄 배경 위 흰 글자는 3.85:1. WCAG 는 18.66px 이상 굵은 글자에 3:1 을 적용하므로
 * 버튼 라벨을 19px/700 으로 고정한다. 이 아래로 줄이면 AA 가 깨진다. */
.btn-primary, .btn-secondary, .btn-accent {
    display: inline-block;
    padding: 15px 30px;
    border-radius: var(--radius);
    font-family: inherit;
    font-weight: 700;
    font-size: 19px;
    letter-spacing: -0.02em;
    transition: background 0.2s, border-color 0.2s, color 0.2s;
    text-decoration: none;
    cursor: pointer;
    border: none;
}

.btn-primary {
    background: var(--coral);
    color: white;
}

.btn-primary:hover { background: var(--coral-hover); }

.btn-secondary {
    background: white;
    color: var(--ink);
    border: 1.5px solid var(--border);
}

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

.btn-accent {
    background: var(--ink);
    color: white;
}

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

/* ===== Hero / Page Header =====
 * CI 가 플랫하고 단정하다. 그라데이션과 장식 블롭은 쓰지 않는다. */
.page-hero {
    padding: 80px 0 60px;
    background: var(--bg-soft);
    border-bottom: 1px solid var(--border-soft);
}

/* 세이지 칩 + 블랙 글자 — CI 승인 조합 */
.eyebrow {
    display: inline-block;
    padding: 6px 14px;
    background: var(--sage-soft);
    color: var(--ink);
    border-radius: 20px;
    font-size: 13px;
    font-weight: 700;
    margin-bottom: 20px;
    letter-spacing: 0.3px;
}

.page-hero h1 {
    font-size: 48px;
    font-weight: 700;   /* 워드마크가 가늘어 800 이상은 브랜드 인상과 어긋난다 */
    color: var(--ink);
    line-height: 1.2;
    letter-spacing: -0.025em;
    margin-bottom: 20px;
    max-width: 820px;
}

.page-hero .lead {
    font-size: 19px;
    color: var(--text-light);
    max-width: 680px;
    margin-bottom: 32px;
    line-height: 1.8;
}

.hero-buttons {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

/* ===== Sections ===== */
section.block { padding: 90px 0; }
section.block.tight { padding: 60px 0; }
section.block.soft { background: var(--bg-soft); }
section.block.muted { background: var(--bg-muted); }

.section-header {
    text-align: center;
    max-width: 720px;
    margin: 0 auto 56px;
}

.section-eyebrow {
    color: var(--text-muted);
    font-size: 13px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    margin-bottom: 14px;
}

.section-title {
    font-size: 36px;
    font-weight: 700;
    color: var(--ink);
    line-height: 1.25;
    letter-spacing: -0.022em;
    margin-bottom: 16px;
}

.section-desc {
    font-size: 17px;
    color: var(--text-light);
}

/* ===== Cards ===== */
.card-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 22px;
}

.card-grid.two { grid-template-columns: repeat(2, 1fr); }
.card-grid.four { grid-template-columns: repeat(4, 1fr); }

.card {
    background: white;
    padding: 32px 28px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    transition: border-color 0.25s, transform 0.25s, box-shadow 0.25s;
}

/* 테두리는 그래픽 요소라 코랄 사용 가능 (비텍스트 대비 3:1 기준 충족) */
.card:hover {
    border-color: var(--coral);
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}

.card-icon {
    width: 44px; height: 44px;
    background: var(--sage-soft);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    margin-bottom: 18px;
}

.card h3 {
    font-size: 19px;
    font-weight: 700;
    color: var(--ink);
    margin-bottom: 10px;
    letter-spacing: -0.3px;
}

.card p {
    font-size: 15px;
    color: var(--text-light);
    line-height: 1.7;
}

/* ===== CTA Card =====
 * 다크 섹션은 블랙. 그라데이션 없음. */
.cta-card {
    background: var(--ink);
    border-radius: var(--radius-xl);
    padding: 64px 48px;
    text-align: center;
    color: white;
}

/* 블랙 면 위 코랄 심볼. 여기가 콘텐츠 안에서 심볼이 가장 잘 작동하는 자리다. */
.cta-card .cta-symbol {
    height: 44px;
    width: auto;
    margin: 0 auto 24px;
}

.cta-card h2 {
    font-size: 34px;
    font-weight: 700;
    margin-bottom: 14px;
    letter-spacing: -0.022em;
    line-height: 1.3;
}

.cta-card p {
    font-size: 17px;
    color: rgba(255, 255, 255, 0.85);
    margin-bottom: 28px;
    max-width: 540px;
    margin-left: auto;
    margin-right: auto;
}

/* 블랙 위에서는 코랄을 그대로 쓴다 (대비 확보) */
.cta-card .btn-primary {
    background: var(--coral);
    color: white;
}

.cta-card .btn-primary:hover { background: var(--coral-hover); }

.cta-card .btn-secondary {
    background: transparent;
    color: white;
    border-color: rgba(255, 255, 255, 0.4);
}

.cta-card .btn-secondary:hover { border-color: white; }

/* ===== Footer ===== */
footer.site-footer {
    background: var(--ink);
    color: rgba(255, 255, 255, 0.72);
    padding: 60px 0 32px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr 1fr;
    gap: 48px;
    margin-bottom: 40px;
}

.footer-brand .logo { color: white; margin-bottom: 12px; }
.footer-brand .logo span { color: var(--sage); }  /* 블랙 배경 → 세이지 */
.footer-brand p { font-size: 14px; line-height: 1.7; max-width: 280px; }

.footer-col h4 {
    color: white;
    font-size: 14px;
    font-weight: 700;
    margin-bottom: 14px;
    letter-spacing: 0.3px;
}

.footer-col ul { list-style: none; }
/* 링크가 아닌 항목(주소 등)도 링크와 같은 크기로 맞춘다.
 * font-size 를 .footer-col a 에만 두면 <a> 가 없는 li 는 16px 기본값을 그대로 받는다. */
.footer-col li {
    margin-bottom: 8px;
    font-size: 14px;
    line-height: 1.6;
}

.footer-col a {
    color: rgba(255, 255, 255, 0.72);
    text-decoration: none;
    font-size: 14px;
    transition: color 0.15s;
}

.footer-col a:hover { color: white; }

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.14);
    padding-top: 24px;
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    font-size: 13px;
}

.footer-bottom a { color: rgba(255, 255, 255, 0.72); }

/* ===== Article (Insights detail) ===== */
.article-meta {
    display: flex;
    gap: 16px;
    color: var(--text-muted);
    font-size: 14px;
    margin-bottom: 14px;
}

.article-meta .tag {
    background: var(--sage-soft);
    color: var(--ink);
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 700;
}

.article-body {
    padding: 40px 0 80px;
    font-size: 17px;
    line-height: 1.85;
    color: var(--text);
}

.article-body h2 {
    font-size: 26px;
    font-weight: 700;
    color: var(--ink);
    margin: 48px 0 16px;
    letter-spacing: -0.5px;
}

.article-body h3 {
    font-size: 20px;
    font-weight: 700;
    color: var(--ink);
    margin: 32px 0 12px;
}

.article-body p { margin-bottom: 18px; }
.article-body ul, .article-body ol { margin: 0 0 22px 24px; }
.article-body li { margin-bottom: 8px; }
.article-body strong { color: var(--ink); font-weight: 600; }

.article-body blockquote {
    border-left: 3px solid var(--coral);
    padding: 14px 0 14px 20px;
    margin: 24px 0;
    color: var(--ink);
    background: var(--bg-soft);
    border-radius: 0 8px 8px 0;
}

.article-body blockquote p:last-child { margin-bottom: 0; }

.article-body table {
    width: 100%;
    border-collapse: collapse;
    margin: 24px 0;
    font-size: 15px;
    border: 1px solid var(--border);
    border-radius: 10px;
    overflow: hidden;
    background: white;
}

.article-body th {
    background: var(--bg-muted);
    text-align: left;
    padding: 12px 16px;
    font-weight: 700;
    color: var(--ink);
    border-bottom: 1px solid var(--border);
    font-size: 14px;
}

.article-body td {
    padding: 12px 16px;
    border-bottom: 1px solid var(--border);
    vertical-align: top;
}

.article-body tr:last-child td { border-bottom: none; }

/* ===== Insights list ===== */
.post-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 22px;
}

.post-card {
    background: white;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 32px;
    transition: border-color 0.25s, transform 0.25s, box-shadow 0.25s;
    text-decoration: none;
    display: block;
}

.post-card:hover {
    border-color: var(--coral);
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}

.post-card .tag {
    display: inline-block;
    background: var(--sage-soft);
    color: var(--ink);
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 700;
    margin-bottom: 16px;
}

.post-card h3 {
    font-size: 22px;
    font-weight: 700;
    color: var(--ink);
    line-height: 1.35;
    margin-bottom: 12px;
    letter-spacing: -0.3px;
}

.post-card p {
    font-size: 15px;
    color: var(--text-light);
    line-height: 1.7;
    margin-bottom: 18px;
}

.post-card .post-meta {
    display: flex;
    justify-content: space-between;
    font-size: 13px;
    color: var(--text-muted);
}

/* Case Analysis 는 코랄 틴트, 이론/모델 글은 세이지 틴트로 구분 */
.post-card .tag-case,
.article-meta .tag-case {
    background: var(--coral-soft);
    color: var(--link);
}

.post-card .tag-theory,
.article-meta .tag-theory {
    background: var(--sage-soft);
    color: var(--ink);
}

/* ===== Form ===== */
.form-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 18px;
}

.form-row { display: flex; flex-direction: column; }
.form-row.full { grid-column: 1 / -1; }

.form-row label {
    font-size: 14px;
    font-weight: 600;
    color: var(--ink);
    margin-bottom: 8px;
}

.form-row input,
.form-row select,
.form-row textarea {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid var(--border);
    border-radius: 8px;
    font-size: 15px;
    font-family: inherit;
    color: var(--text);
    background: white;
    transition: border-color 0.15s, box-shadow 0.15s;
}

.form-row input:focus,
.form-row select:focus,
.form-row textarea:focus {
    outline: none;
    border-color: var(--coral);
    box-shadow: 0 0 0 3px rgba(233, 72, 61, 0.14);
}

.form-row textarea { min-height: 120px; resize: vertical; }

.form-row .help {
    font-size: 13px;
    color: var(--text-muted);
    margin-top: 6px;
}

/* ===== Stats ===== */
.stat {
    text-align: center;
    padding: 24px 16px;
}

/* 44px 이므로 코랄이 가장 강하게 작동하는 자리 */
.stat-num {
    font-size: 44px;
    font-weight: 700;
    color: var(--ink);
    line-height: 1;
    margin-bottom: 8px;
    letter-spacing: -1px;
}

.stat-num span { color: var(--coral); }

.stat-label {
    font-size: 14px;
    color: var(--text-light);
}

/* ===== Misc ===== */
.divider { border: none; border-top: 1px solid var(--border); margin: 40px 0; }

.tag-row { display: flex; gap: 8px; flex-wrap: wrap; }

.checklist { list-style: none; margin: 20px 0; }

.checklist li {
    padding: 10px 0 10px 32px;
    position: relative;
    color: var(--text);
}

/* 체크 마크는 아이콘 취급 — 비텍스트 대비 3:1 기준 충족 */
.checklist li::before {
    content: '✓';
    position: absolute;
    left: 0;
    top: 10px;
    width: 22px; height: 22px;
    background: var(--coral);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 700;
}

/* ===== Article 부속 요소 ===== */
.article-body .callout {
    background: var(--bg-muted);
    border-radius: var(--radius-lg);
    padding: 28px 32px;
    margin: 32px 0;
}

.article-body .callout p:last-child { margin-bottom: 0; }

.article-body .check-item { margin-bottom: 28px; }

.article-body .check-item .q {
    font-size: 18px;
    font-weight: 700;
    color: var(--ink);
    margin-bottom: 8px;
    line-height: 1.5;
}

.article-body .check-item p {
    font-size: 16px;
    color: var(--text-light);
    margin-bottom: 0;
}

.article-source {
    border-top: 1px solid var(--border);
    margin-top: 48px;
    padding-top: 24px;
    font-size: 14px;
    line-height: 1.8;
    color: var(--text-light);
}

.page-hero .article-meta {
    margin-top: 24px;
    margin-bottom: 0;
    align-items: center;
}

/* ===== Responsive ===== */
@media (max-width: 900px) {
    .nav-links { display: none; }
    .menu-toggle { display: block; }
    .page-hero { padding: 60px 0 40px; }
    .page-hero h1 { font-size: 34px; }
    .page-hero .lead { font-size: 17px; }
    .section-title { font-size: 28px; }
    section.block { padding: 60px 0; }
    .card-grid, .card-grid.two, .card-grid.four,
    .post-grid, .form-grid {
        grid-template-columns: 1fr;
    }
    .footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 32px;
    }
    .cta-card { padding: 48px 24px; }
    .cta-card h2 { font-size: 26px; }
    .article-body { font-size: 16px; }
    .article-body h2 { font-size: 22px; }
    .btn-primary, .btn-secondary, .btn-accent { font-size: 18px; padding: 14px 26px; }
}

@media (max-width: 540px) {
    .footer-grid { grid-template-columns: 1fr; }
    .hero-buttons { flex-direction: column; align-items: stretch; }
    .hero-buttons .btn-primary,
    .hero-buttons .btn-secondary { text-align: center; }
}

/* ═══════════════════════════════════════════════
   블랙 히어로 — .dark-top 이 붙은 페이지에만 적용
   ═══════════════════════════════════════════════ */
/* ===== 상단 검은 블록 ===== */

.dark-top .site-header {
    background: var(--ink);
    border-bottom: none;
    /* 스크롤해도 헤더는 검게 유지된다 — 상단이 계속 브랜드 면으로 읽힌다 */
}

.dark-top .nav-links a {
    color: rgba(255, 255, 255, 0.72);
}

.dark-top .nav-links a:hover,
.dark-top .nav-links a.active {
    color: #ffffff;
}

/* 검은 헤더 위에서는 반전 — 흰 버튼 + 검은 글자 (21:1) */
.dark-top .nav-cta {
    background: #ffffff;
    color: var(--ink) !important;
}

.dark-top .nav-cta:hover {
    background: var(--sage);
}

.dark-top .menu-toggle { color: #ffffff; }

/* ===== 히어로 ===== */

.dark-top .page-hero {
    background: var(--ink);
    border-bottom: none;
    padding: 96px 0 104px;
    /* 기본 상속색을 밝게 잡아둔다. 이게 없으면 히어로에 클래스 없는 텍스트를
     * 넣었을 때 body 의 #111 을 물려받아 검은 면에서 보이지 않는다. */
    color: rgba(255, 255, 255, 0.78);
}

/* 세이지 아웃라인 칩 — 검은 면에서 세이지가 가장 정확히 읽힌다 (15.6:1) */
.dark-top .page-hero .eyebrow {
    background: transparent;
    color: var(--sage);
    box-shadow: inset 0 0 0 1px rgba(189, 217, 209, 0.45);
}

.dark-top .page-hero h1 {
    color: #ffffff;
    font-size: 52px;
}

/* 검은 배경에서는 코랄 원색을 그대로 쓴다 — 5.5:1 로 흰 배경(3.8:1)보다 오히려 산다.
 * 흰 배경일 때 --link 로 눌러 쓰던 제약이 여기서는 없다. */
.dark-top .page-hero h1 span {
    color: var(--coral) !important;
}

.dark-top .page-hero .lead {
    color: rgba(255, 255, 255, 0.78);
}

/* 검은 면 위 코랄 버튼 — 대비가 충분해 가장 강한 CTA 가 된다 */
.dark-top .page-hero .btn-secondary {
    background: transparent;
    color: #ffffff;
    border-color: rgba(255, 255, 255, 0.38);
}

.dark-top .page-hero .btn-secondary:hover {
    border-color: #ffffff;
    background: rgba(255, 255, 255, 0.06);
}

/* 아티클 히어로의 날짜·읽는시간. --text-muted 는 검은 면에서 3.9:1 로 미달이라 올린다 */
.dark-top .page-hero .article-meta {
    color: rgba(255, 255, 255, 0.68);   /* 9.4:1 */
}

.dark-top :focus-visible {
    outline-color: var(--sage);
}

/* 검은 블록 다음 섹션은 기본 흰 바탕을 그대로 쓴다.
 * 여기서 background 를 강제하면 `block soft tight` 조합의 회색 면까지 덮어버린다. */

@media (max-width: 900px) {
    .dark-top .page-hero { padding: 64px 0 72px; }
    .dark-top .page-hero h1 { font-size: 36px; }
}

/* ═══════════════════════════════════════════════
   온라인 커피챗 예약 (contact.html)
   왼쪽 달력에서 날짜 → 오른쪽에서 시간 → 연락처 순으로 진행한다.
   구글 캘린더 예약 페이지를 연결하면 #booking-embed 가 이 자리를 대신한다.
   ═══════════════════════════════════════════════ */

#booking-embed:empty { display: none; }
#booking-embed iframe { display: block; width: 100%; min-height: 620px; border: 0; border-radius: var(--radius-lg); }

.booking {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    align-items: start;
}

/* ── 달력 ── */
.booking__cal {
    background: var(--ink);
    border-radius: var(--radius-lg);
    padding: 26px 24px 22px;
    color: #ffffff;
}

.cal__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 18px;
}

.cal__head strong { font-size: 17px; font-weight: 700; }

.cal__nav {
    width: 34px; height: 34px;
    border: 1px solid rgba(255,255,255,0.24);
    background: transparent;
    color: #ffffff;
    border-radius: 8px;
    font-size: 20px;
    line-height: 1;
    cursor: pointer;
    transition: background 0.15s, border-color 0.15s;
}

.cal__nav:hover:not(:disabled) { background: rgba(255,255,255,0.10); border-color: rgba(255,255,255,0.5); }
.cal__nav:disabled { opacity: 0.3; cursor: default; }

.cal__week, .cal__grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 4px;
}

.cal__week {
    margin-bottom: 6px;
    font-size: 12px;
    font-weight: 600;
    color: rgba(255,255,255,0.55);
    text-align: center;
}

.cal__pad { aspect-ratio: 1; }

.cal__day {
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: rgba(255,255,255,0.30);
    font-family: inherit;
    font-size: 14px;
    font-weight: 500;
    cursor: default;
}

/* 예약 가능한 날만 코랄 테두리로 열려 있음을 알린다 */
.cal__day.is-open {
    color: #ffffff;
    font-weight: 700;
    cursor: pointer;
    box-shadow: inset 0 0 0 1.5px var(--coral);
    transition: background 0.15s;
}

.cal__day.is-open:hover { background: rgba(233, 72, 61, 0.22); }

.cal__day.is-picked {
    background: var(--coral);
    color: #ffffff;
    box-shadow: none;
}

.cal__day:focus-visible { outline: 2px solid var(--sage); outline-offset: 2px; }

.cal__empty {
    margin-top: 14px;
    font-size: 13px;
    color: rgba(255,255,255,0.68);
}

.cal__legend {
    list-style: none;
    margin-top: 18px;
    padding-top: 16px;
    border-top: 1px solid rgba(255,255,255,0.14);
    font-size: 13px;
    line-height: 1.9;
    color: rgba(255,255,255,0.68);
}

.cal__dot {
    display: inline-block;
    width: 11px; height: 11px;
    margin-right: 8px;
    border-radius: 3px;
    box-shadow: inset 0 0 0 1.5px var(--coral);
    vertical-align: -1px;
}

/* ── 오른쪽 패널 ── */
.booking__panel {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 26px 24px;
    min-height: 320px;
}

.booking__step {
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.08em;
    color: var(--text-muted);
    margin-bottom: 8px;
}

.booking__chosen {
    font-size: 17px;
    font-weight: 700;
    color: var(--ink);
    margin-bottom: 16px;
}

.booking__panel:not(.is-active) .booking__chosen {
    font-size: 15px;
    font-weight: 400;
    color: var(--text-muted);
}

.booking__slots { display: flex; flex-wrap: wrap; gap: 8px; }

.cal__slot {
    padding: 11px 18px;
    border: 1.5px solid var(--border);
    border-radius: 8px;
    background: var(--bg);
    color: var(--ink);
    font-family: inherit;
    font-size: 15px;
    font-weight: 600;
    font-variant-numeric: tabular-nums;
    cursor: pointer;
    transition: border-color 0.15s, background 0.15s, color 0.15s;
}

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

.cal__slot.is-picked {
    background: var(--coral);
    border-color: var(--coral);
    color: #ffffff;
}

.cal__slot:focus-visible { outline: 2px solid var(--coral); outline-offset: 2px; }

/* ── 연락처 폼 ── */
.booking__form[hidden] { display: none; }

.booking__form {
    margin-top: 22px;
    padding-top: 20px;
    border-top: 1px solid var(--border-soft);
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.booking__form label {
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-size: 13px;
    font-weight: 600;
    color: var(--ink);
}

.booking__form input,
.booking__form textarea {
    padding: 11px 13px;
    border: 1px solid var(--border);
    border-radius: 8px;
    font-family: inherit;
    font-size: 15px;
    font-weight: 400;
    color: var(--text);
    background: var(--bg);
}

.booking__form input:focus,
.booking__form textarea:focus {
    outline: none;
    border-color: var(--coral);
    box-shadow: 0 0 0 3px rgba(233, 72, 61, 0.14);
}

.booking__form textarea { resize: vertical; }

.booking__form .btn-primary { margin-top: 4px; width: 100%; text-align: center; }

.booking__note {
    font-size: 13px;
    line-height: 1.7;
    color: var(--text-muted);
}

@media (max-width: 900px) {
    .booking { grid-template-columns: 1fr; }
}

/* ═══════════════════════════════════════════════
   아티클 헤드라인 이미지
   CI 의 2×2 블록 모듈로 구성한다. 스톡 일러스트를 쓰지 않기 위한 선택이며,
   검은 히어로에서 본문 흰 면으로 넘어가는 구간을 이어 주는 역할도 한다.
   ═══════════════════════════════════════════════ */

.article-cover {
    margin: 0;
    background: var(--ink);
    line-height: 0;
}

.article-cover img {
    display: block;
    width: 100%;
    height: clamp(180px, 26vw, 320px);
    object-fit: cover;
}

/* ═══════════════════════════════════════════════
   본문 설명 다이어그램 (인라인 SVG)
   페이지 폰트와 컬러 토큰을 그대로 상속받도록 인라인으로 넣는다.
   외부 파일로 빼면 Pretendard 가 적용되지 않는다.
   ═══════════════════════════════════════════════ */

.dgm {
    margin: 40px 0;
    padding: 0;
}

.dgm svg {
    display: block;
    width: 100%;
    height: auto;
    font-family: inherit;
    overflow: visible;
}

.dgm figcaption {
    margin-top: 14px;
    font-size: 14px;
    line-height: 1.7;
    color: var(--text-muted);
}

/* 텍스트 계열 */
.dgm-t   { font-size: 15px; font-weight: 700; fill: var(--ink); }
.dgm-pt  { font-size: 13px; font-weight: 600; fill: var(--ink); }
.dgm-ax  { font-size: 13px; font-weight: 600; fill: var(--text-muted); }
.dgm-note{ font-size: 13px; font-weight: 400; fill: var(--text-light); }
.dgm-in  { font-size: 14px; font-weight: 700; fill: #ffffff; }
.dgm-inb { font-size: 14px; font-weight: 700; fill: var(--ink); }

/* 선 계열 */
.dgm-grid  { stroke: var(--border); stroke-width: 1; }
.dgm-axis  { stroke: var(--ink); stroke-width: 1.5; }
.dgm-arrow { stroke: var(--text-muted); stroke-width: 1.5; fill: none; stroke-linecap: round; }
.dgm-dash  { stroke: var(--border); stroke-width: 1.5; stroke-dasharray: 5 4; }
.dgm-line  { fill: none; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
.dgm-sage  { stroke: #7fb3a4; }   /* 세이지 원색은 흰 면에서 대비가 낮아 명도를 낮춘 선용 값 */
.dgm-ink   { stroke: var(--ink); }
.dgm-coral { stroke: var(--coral); }

@media (max-width: 600px) {
    .dgm svg { font-size: 15px; }
}

/* 목록 카드 썸네일 — 아티클 헤드라인 이미지와 동일한 에셋을 재사용한다 */
.post-card { padding: 0; overflow: hidden; }

.post-card__thumb {
    display: block;
    width: 100%;
    height: 132px;
    object-fit: cover;
    background: var(--ink);
}

.post-card > :not(.post-card__thumb) { margin-left: 28px; margin-right: 28px; }
.post-card > .tag { margin-top: 24px; }
.post-card > .post-meta { padding-bottom: 26px; }

/* 최신 콘텐츠 표시 — 태그 옆에 붙는 작은 배지.
 * 코랄 배경 + 흰 글자는 11px 에서 대비가 부족하므로 --link(5.7:1) 를 쓴다. */
.badge-new {
    display: inline-block;
    margin-left: 6px;
    padding: 4px 9px;
    border-radius: 20px;
    background: var(--link);
    color: #ffffff;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.06em;
    vertical-align: middle;
}

.page-hero .badge-new { background: var(--coral); }

/* 검은 달력 패널 안의 단계 라벨 */
.booking__step--onwhite {
    color: rgba(255, 255, 255, 0.55);
    margin-bottom: 12px;
}

/* ═══════════════════════════════════════════════
   폼 — 동의 항목과 전송 상태 표시
   ═══════════════════════════════════════════════ */

.form-consent {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    margin: 4px 0 14px;
    font-size: 13px;
    line-height: 1.7;
    color: var(--text-light);
    text-align: left;
    cursor: pointer;
}

.form-consent input[type="checkbox"] {
    flex: 0 0 auto;
    width: 17px; height: 17px;
    margin-top: 2px;
    accent-color: var(--coral);
    cursor: pointer;
}

.form-consent em { font-style: normal; font-weight: 700; color: var(--link); }
.form-consent a { text-decoration: underline; text-underline-offset: 2px; }

/* 전송 결과 — alert 대신 폼 안에서 상태를 보여준다 */
.form-status {
    margin-top: 12px;
    padding: 11px 14px;
    border-radius: 8px;
    font-size: 14px;
    line-height: 1.6;
    text-align: left;
}

.form-status.is-info  { background: var(--bg-muted); color: var(--text); }
.form-status.is-ok    { background: var(--sage-soft); color: var(--ink); font-weight: 600; }
.form-status.is-error { background: var(--coral-soft); color: var(--link); font-weight: 600; }

/* 구독 폼 */
.subscribe { max-width: 480px; margin: 0 auto; }

.subscribe__row { display: flex; gap: 8px; margin-bottom: 12px; }

.subscribe__row input {
    flex: 1;
    padding: 12px 14px;
    border: 1px solid var(--border);
    border-radius: 8px;
    font-size: 15px;
    font-family: inherit;
    color: var(--text);
    background: var(--bg);
}

.subscribe__row input:focus {
    outline: none;
    border-color: var(--coral);
    box-shadow: 0 0 0 3px rgba(233, 72, 61, 0.14);
}

.subscribe__row .btn-primary { font-size: 17px; padding: 12px 24px; }

@media (max-width: 540px) {
    .subscribe__row { flex-direction: column; }
}
