/* VOKA'S Log 공통 디자인 (메인·소개·개인정보처리방침). 2026-10-23 */
:root {
    /* 밴드(구간) 배경 */
    --ink: #15132a;
    --ink-2: #1e1b3a;
    --paper: #f5f3ee;
    --white: #ffffff;

    --text: #1c1b22;
    --muted: #6b6a75;
    --line: #e7e3da;
    --surface: #ffffff;
    --surface-2: #efece5;
    --accent: #5b4ddb;
    --accent-2: #8b5cf6;
    --pink: #ec4899;
    --accent-soft: #ebe8fd;
    --live: #22c55e;

    --shadow: 0 1px 2px rgba(28, 27, 34, 0.05), 0 14px 34px -18px rgba(28, 27, 34, 0.32);
    --shadow-hover: 0 2px 4px rgba(28, 27, 34, 0.07), 0 24px 48px -18px rgba(28, 27, 34, 0.45);
    --radius: 22px;
    --wrap: 1240px;
}

@media (prefers-color-scheme: dark) {
    :root {
        --paper: #121119;
        --white: #19181f;
        --text: #f1f0f5;
        --muted: #a3a1b0;
        --line: #2c2a36;
        --surface: #1f1e27;
        --surface-2: #2a2833;
        --accent: #a597ff;
        --accent-soft: #2a2747;
        --shadow: 0 1px 2px rgba(0, 0, 0, 0.35), 0 14px 34px -18px rgba(0, 0, 0, 0.75);
        --shadow-hover: 0 2px 4px rgba(0, 0, 0, 0.4), 0 24px 48px -18px rgba(0, 0, 0, 0.9);
    }
}

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

body {
    font-family: "Pretendard Variable", Pretendard, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    font-size: 17px;
    line-height: 1.6;
    color: var(--text);
    background: var(--paper);
    -webkit-font-smoothing: antialiased;
    word-break: keep-all;
    overflow-wrap: anywhere;
}

a {
    color: inherit;
}

.wrap {
    max-width: var(--wrap);
    margin: 0 auto;
    padding: 0 32px;
}

.band {
    position: relative;
    display: flow-root; /* 안쪽 음수 여백이 밴드 밖으로 새지 않게 (요약 카드 겹침용) */
}

.band-white { background: var(--white); }
.band-paper { background: var(--paper); }

/* ───────── 히어로 (짙은 밴드) ───────── */
.band-hero {
    color: #fff;
    background:
        radial-gradient(900px 520px at 88% 8%, rgba(139, 92, 246, 0.42), transparent 62%),
        radial-gradient(700px 480px at 6% 100%, rgba(236, 72, 153, 0.22), transparent 60%),
        linear-gradient(180deg, var(--ink) 0%, var(--ink-2) 100%);
    overflow: hidden;
}

.band-hero::after {
    /* 아래 밴드와 부드럽게 이어지는 경계선 */
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.18), transparent);
}

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

.brand {
    display: inline-flex;
    align-items: center;
    gap: 11px;
    text-decoration: none;
    font-weight: 800;
    font-size: 1.12rem;
    letter-spacing: -0.02em;
}

.brand img {
    width: 36px;
    height: 36px;
    object-fit: contain;
}

.topnav {
    display: flex;
    gap: 6px;
}

.topnav a {
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.72);
    padding: 9px 16px;
    border-radius: 999px;
    transition: background 0.2s, color 0.2s;
}

.topnav a:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.1);
}

.hero {
    display: grid;
    grid-template-columns: 1.15fr 0.85fr;
    gap: 64px;
    align-items: center;
    padding: 56px 0 96px;
}

.live {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    font-size: 0.88rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.82);
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.14);
    padding: 7px 16px 7px 13px;
    border-radius: 999px;
    backdrop-filter: blur(8px);
}

.live-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--live);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.55); }
    70% { box-shadow: 0 0 0 9px rgba(34, 197, 94, 0); }
    100% { box-shadow: 0 0 0 0 rgba(34, 197, 94, 0); }
}

.hero h1 {
    font-size: clamp(2.5rem, 4.6vw, 4.3rem);
    font-weight: 800;
    letter-spacing: -0.045em;
    line-height: 1.04;
    margin: 26px 0 22px;
}

.hero h1 .grad {
    background: linear-gradient(90deg, #b9a8ff 0%, #f0abfc 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.lead {
    font-size: 1.16rem;
    color: rgba(255, 255, 255, 0.72);
    max-width: 31em;
    line-height: 1.8;
}

.lead strong {
    color: #fff;
    font-weight: 600;
}

.cta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 34px;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    font-weight: 700;
    font-size: 1rem;
    padding: 15px 26px;
    border-radius: 999px;
    transition: transform 0.2s, background 0.2s, box-shadow 0.2s;
}

.btn-light {
    background: #fff;
    color: var(--ink);
}

.btn-light:hover {
    transform: translateY(-2px);
    box-shadow: 0 16px 34px -14px rgba(185, 168, 255, 0.7);
}

.btn-glass {
    color: #fff;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.btn-glass:hover {
    background: rgba(255, 255, 255, 0.16);
}

.stats {
    display: grid;
    grid-template-columns: repeat(3, auto);
    justify-content: start;
    gap: 14px;
    margin-top: 46px;
}

.stat {
    padding: 16px 22px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
}

.stat dt {
    font-size: 0.82rem;
    color: rgba(255, 255, 255, 0.6);
    font-weight: 500;
}

.stat dd {
    font-size: 2rem;
    font-weight: 800;
    letter-spacing: -0.03em;
    line-height: 1.2;
}

.stat dd small {
    font-size: 0.95rem;
    font-weight: 600;
    margin-left: 3px;
    color: rgba(255, 255, 255, 0.6);
}

/* 사진 모자이크 */
.mosaic {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: repeat(3, 1fr);
    gap: 14px;
    aspect-ratio: 1 / 1;
}

.mosaic a {
    position: relative;
    display: block;
    overflow: hidden;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.06);
    box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.1), 0 24px 50px -24px rgba(0, 0, 0, 0.7);
}

.mosaic a:nth-child(1) { grid-column: 1 / 3; grid-row: 1 / 3; }
.mosaic a:nth-child(2) { grid-column: 3; grid-row: 1; }
.mosaic a:nth-child(3) { grid-column: 3; grid-row: 2; }
.mosaic a:nth-child(4) { grid-column: 1; grid-row: 3; }
.mosaic a:nth-child(5) { grid-column: 2 / 4; grid-row: 3; }

.mosaic img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.6s ease;
}

.mosaic a:hover img {
    transform: scale(1.06);
}

.mosaic a::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 55%, rgba(10, 8, 24, 0.7));
    opacity: 0;
    transition: opacity 0.25s;
}

.mosaic a:hover::after {
    opacity: 1;
}

.mosaic-caption {
    position: absolute;
    z-index: 1;
    left: 14px;
    right: 14px;
    bottom: 12px;
    font-size: 0.8rem;
    font-weight: 600;
    color: #fff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    opacity: 0;
    transform: translateY(4px);
    transition: opacity 0.25s, transform 0.25s;
}

.mosaic a:hover .mosaic-caption {
    opacity: 1;
    transform: none;
}

/* ───────── 일반 섹션 ───────── */
.section {
    padding-block: 88px;
}

.section-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 30px;
}

.eyebrow {
    display: inline-block;
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--accent);
    margin-bottom: 6px;
}

.section-head h2 {
    font-size: clamp(1.7rem, 2.6vw, 2.3rem);
    font-weight: 800;
    letter-spacing: -0.035em;
    line-height: 1.2;
}

.section-head p {
    color: var(--muted);
    margin-top: 6px;
}

.more {
    flex-shrink: 0;
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 700;
    padding: 11px 20px;
    border-radius: 999px;
    background: var(--surface);
    border: 1px solid var(--line);
    transition: background 0.2s, transform 0.2s;
}

.more:hover {
    transform: translateY(-1px);
    background: var(--surface-2);
}

/* 노트 카드 */
.notebooks {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;
}

.notebook {
    position: relative;
    display: flex;
    align-items: flex-end;
    min-height: 250px;
    border-radius: var(--radius);
    overflow: hidden;
    text-decoration: none;
    color: #fff;
    background: linear-gradient(135deg, #6d5ff0, #9a6cc9);
    box-shadow: var(--shadow);
    transition: transform 0.25s, box-shadow 0.25s;
}

.notebook:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.notebook img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.notebook:hover img {
    transform: scale(1.05);
}

.notebook::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(10, 8, 20, 0) 30%, rgba(10, 8, 20, 0.82) 100%);
}

.notebook-body {
    position: relative;
    z-index: 1;
    width: 100%;
    padding: 22px 24px;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 12px;
}

.notebook-title {
    font-size: 1.45rem;
    font-weight: 800;
    letter-spacing: -0.02em;
}

.notebook-period {
    font-size: 0.88rem;
    opacity: 0.85;
}

.notebook-count {
    flex-shrink: 0;
    font-size: 0.85rem;
    font-weight: 700;
    padding: 6px 12px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(6px);
}

/* 최근 기록 카드 (첫 카드는 가로로 크게) */
.recent-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;
}

.note-card {
    display: flex;
    flex-direction: column;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    overflow: hidden;
    text-decoration: none;
    color: var(--text);
    box-shadow: var(--shadow);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.note-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.note-card:focus-visible,
.notebook:focus-visible,
.mosaic a:focus-visible,
.btn:focus-visible {
    outline: 3px solid var(--accent-2);
    outline-offset: 3px;
}

.note-media {
    position: relative;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background: linear-gradient(135deg, #8d9cf3 0%, #9b6fcb 100%);
}

.note-media img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.note-card:hover .note-media img {
    transform: scale(1.05);
}

.note-placeholder {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    color: rgba(255, 255, 255, 0.92);
    font-size: 2.6rem;
    font-weight: 800;
    letter-spacing: -0.03em;
}

.note-badge {
    position: absolute;
    top: 14px;
    left: 14px;
    padding: 0.32rem 0.8rem;
    border-radius: 999px;
    background: rgba(20, 16, 44, 0.58);
    color: #fff;
    font-size: 0.78rem;
    font-weight: 600;
    backdrop-filter: blur(6px);
}

.note-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    padding: 1.25rem 1.4rem 1.5rem;
}

.note-date {
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--accent);
}

.note-title {
    font-size: 1.14rem;
    font-weight: 700;
    line-height: 1.4;
    letter-spacing: -0.015em;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.note-excerpt {
    font-size: 0.94rem;
    line-height: 1.7;
    color: var(--muted);
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.note-card.featured {
    grid-column: span 2;
    flex-direction: row;
}

.note-card.featured .note-media {
    flex: 0 0 56%;
    aspect-ratio: auto;
    min-height: 340px;
}

.note-card.featured .note-body {
    justify-content: center;
    padding: 2.2rem 2.1rem;
    gap: 0.8rem;
}

.note-card.featured .note-title {
    font-size: 1.6rem;
    -webkit-line-clamp: 3;
}

.note-card.featured .note-excerpt {
    font-size: 1rem;
    -webkit-line-clamp: 6;
}

/* ───────── 문의 (보라 밴드) ───────── */
.band-accent {
    color: #fff;
    background:
        radial-gradient(600px 300px at 90% 0%, rgba(240, 171, 252, 0.35), transparent 60%),
        linear-gradient(120deg, #4f46e5 0%, #7c3aed 55%, #a855f7 100%);
}

.contact {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding-block: 56px;
}

.contact h3 {
    font-size: clamp(1.4rem, 2.2vw, 1.9rem);
    font-weight: 800;
    letter-spacing: -0.03em;
}

.contact p {
    color: rgba(255, 255, 255, 0.78);
    margin-top: 4px;
}

/* ───────── 하단 (짙은 밴드) ───────── */
.band-ink {
    background: var(--ink);
    color: rgba(255, 255, 255, 0.6);
}

.site-footer {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding-block: 34px;
    font-size: 0.9rem;
}

.site-footer .brand {
    color: #fff;
    font-size: 1rem;
}

.site-footer .brand img {
    width: 30px;
    height: 30px;
}

.site-footer nav {
    display: flex;
    gap: 22px;
}

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

.site-footer nav a:hover {
    color: #fff;
}

/* ───────── 반응형 ───────── */
@media (max-width: 1024px) {
    .hero {
        grid-template-columns: 1fr;
        gap: 48px;
        padding: 32px 0 72px;
    }

    .mosaic {
        max-width: 620px;
    }

    .notebooks,
    .recent-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .notebooks .notebook:nth-child(3) {
        grid-column: span 2;
    }

    /* 2열에서는 마지막 줄이 한 장만 남지 않도록 */
    .note-card:nth-child(8) {
        display: none;
    }
}

@media (max-width: 640px) {
    body {
        font-size: 16px;
    }

    .wrap {
        padding: 0 18px;
    }

    .topbar {
        padding: 18px 0;
    }

    .topnav a {
        padding: 8px 11px;
    }

    .hero {
        padding: 20px 0 56px;
    }

    .lead {
        font-size: 1.02rem;
    }

    .stats {
        grid-template-columns: repeat(3, 1fr);
        gap: 8px;
    }

    .stat {
        padding: 12px 12px;
        border-radius: 14px;
    }

    .stat dd {
        font-size: 1.35rem;
    }

    .stat dd small {
        font-size: 0.8rem;
    }

    .mosaic {
        gap: 8px;
    }

    .mosaic a {
        border-radius: 14px;
    }

    .section {
        padding-block: 60px;
    }

    .notebooks,
    .recent-grid {
        grid-template-columns: 1fr;
    }

    .notebooks .notebook:nth-child(3) {
        grid-column: auto;
    }

    .notebook {
        min-height: 180px;
    }

    .note-card:nth-child(8) {
        display: flex;
    }

    .note-card.featured {
        grid-column: auto;
        flex-direction: column;
    }

    .note-card.featured .note-media {
        aspect-ratio: 4 / 3;
        min-height: 0;
    }

    .note-card.featured .note-body {
        padding: 1.25rem 1.4rem 1.5rem;
    }

    .note-card.featured .note-title {
        font-size: 1.25rem;
    }

    .note-card.featured .note-excerpt {
        -webkit-line-clamp: 3;
    }

    .contact {
        flex-direction: column;
        align-items: flex-start;
        padding-block: 44px;
    }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation: none !important;
        transition: none !important;
    }
}

/* ───────── 서브 페이지 공통 (소개, 개인정보처리방침) ───────── */
.page-hero {
    padding: 40px 0 80px;
    max-width: 820px;
}

.page-hero .eyebrow {
    color: #c4b8ff;
}

.page-hero h1 {
    font-size: clamp(2.3rem, 4.2vw, 3.6rem);
    font-weight: 800;
    letter-spacing: -0.04em;
    line-height: 1.12;
    margin: 10px 0 18px;
}

.page-hero .lead {
    max-width: 40em;
}

.page-hero .stats {
    margin-top: 36px;
}

.chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 26px;
}

.chip {
    font-size: 0.85rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.85);
    padding: 7px 14px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.14);
}

/* 주제 카드 */
.topics {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 18px;
}

.topic {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 26px 24px;
    border-radius: var(--radius);
    background: var(--surface);
    border: 1px solid var(--line);
    text-decoration: none;
    color: var(--text);
    box-shadow: var(--shadow);
    transition: transform 0.25s, box-shadow 0.25s;
}

.topic:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-hover);
}

.topic-icon {
    display: grid;
    place-items: center;
    width: 52px;
    height: 52px;
    border-radius: 16px;
    font-size: 1.6rem;
    background: var(--accent-soft, #ebe8fd);
}

.topic h3 {
    font-size: 1.15rem;
    font-weight: 800;
    letter-spacing: -0.02em;
}

.topic p {
    font-size: 0.94rem;
    color: var(--muted);
    line-height: 1.65;
    flex: 1;
}

.topic-count {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--accent);
}

/* 타임라인 */
.timeline {
    position: relative;
    max-width: 820px;
    list-style: none;
}

.timeline::before {
    content: "";
    position: absolute;
    left: 11px;
    top: 8px;
    bottom: 8px;
    width: 2px;
    background: linear-gradient(180deg, var(--accent), var(--accent-2), var(--pink));
    opacity: 0.45;
}

.timeline li {
    position: relative;
    padding: 0 0 30px 46px;
}

.timeline li:last-child {
    padding-bottom: 0;
}

.timeline li::before {
    content: "";
    position: absolute;
    left: 4px;
    top: 6px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--white);
    border: 3px solid var(--accent);
}

.timeline li.now::before {
    background: var(--live);
    border-color: var(--live);
    animation: pulse 2s infinite;
}

.timeline time {
    display: block;
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--accent);
}

.timeline strong {
    display: block;
    font-size: 1.12rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    margin: 2px 0 4px;
}

.timeline a {
    color: var(--muted);
    text-decoration: none;
    font-size: 0.95rem;
}

.timeline a:hover {
    color: var(--text);
    text-decoration: underline;
}

/* 원칙 카드 */
.principles {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
}

.principle {
    padding: 26px 24px;
    border-radius: var(--radius);
    background: var(--surface);
    border: 1px solid var(--line);
}

.principle .num {
    font-size: 0.8rem;
    font-weight: 800;
    letter-spacing: 0.12em;
    color: var(--accent);
}

.principle h3 {
    font-size: 1.1rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    margin: 8px 0 6px;
}

.principle p {
    font-size: 0.94rem;
    color: var(--muted);
    line-height: 1.7;
}

.notice {
    display: flex;
    gap: 14px;
    align-items: flex-start;
    margin-top: 22px;
    padding: 20px 22px;
    border-radius: 18px;
    background: #fff7ed;
    border: 1px solid #fed7aa;
    color: #7c2d12;
    font-size: 0.95rem;
    line-height: 1.7;
}

.notice-icon {
    font-size: 1.3rem;
    line-height: 1.4;
}

/* 개인정보처리방침: 요약 카드 + 목차 + 본문 */
.summary {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
    margin-top: -40px;
    position: relative;
    z-index: 1;
}

.summary-card {
    padding: 24px;
    border-radius: var(--radius);
    background: var(--surface);
    border: 1px solid var(--line);
    box-shadow: var(--shadow);
}

.summary-card .topic-icon {
    width: 44px;
    height: 44px;
    border-radius: 13px;
    font-size: 1.3rem;
    margin-bottom: 12px;
}

.summary-card h3 {
    font-size: 1.05rem;
    font-weight: 800;
    letter-spacing: -0.02em;
}

.summary-card p {
    font-size: 0.92rem;
    color: var(--muted);
    margin-top: 4px;
    line-height: 1.65;
}

.doc {
    display: grid;
    grid-template-columns: 220px minmax(0, 1fr);
    gap: 56px;
    align-items: start;
}

.toc {
    position: sticky;
    top: 24px;
}

.toc-title {
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--muted);
    margin-bottom: 10px;
}

.toc ol {
    list-style: none;
    border-left: 2px solid var(--line);
}

.toc a {
    display: block;
    padding: 7px 0 7px 16px;
    margin-left: -2px;
    border-left: 2px solid transparent;
    color: var(--muted);
    text-decoration: none;
    font-size: 0.93rem;
    transition: color 0.2s, border-color 0.2s;
}

.toc a:hover {
    color: var(--text);
    border-left-color: var(--accent);
}

.prose {
    max-width: 760px;
}

.prose section {
    padding: 30px 0;
    border-bottom: 1px solid var(--line);
    scroll-margin-top: 24px;
}

.prose section:first-child {
    padding-top: 0;
}

.prose section:last-child {
    border-bottom: 0;
}

.prose h2 {
    display: flex;
    align-items: baseline;
    gap: 12px;
    font-size: 1.35rem;
    font-weight: 800;
    letter-spacing: -0.025em;
    margin-bottom: 12px;
}

.prose h2 .n {
    font-size: 0.9rem;
    font-weight: 800;
    color: var(--accent);
}

.prose p,
.prose li {
    color: var(--muted);
    line-height: 1.85;
}

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

.prose ul {
    padding-left: 1.2rem;
}

.prose li + li {
    margin-top: 6px;
}

.prose a {
    color: var(--accent);
    font-weight: 600;
}

.prose strong {
    color: var(--text);
}

@media (max-width: 1024px) {
    .topics {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .principles,
    .summary {
        grid-template-columns: 1fr;
    }

    .doc {
        grid-template-columns: 1fr;
        gap: 28px;
    }

    .toc {
        position: static;
    }
}

@media (max-width: 640px) {
    .page-hero {
        padding: 16px 0 64px;
    }

    .topics {
        grid-template-columns: 1fr;
    }

    .summary {
        margin-top: -32px;
    }
}

@media (prefers-color-scheme: dark) {
    .notice {
        background: #2a1d12;
        border-color: #5c3a1c;
        color: #fed7aa;
    }
}


/* 소개 페이지: 첫 화면 오른쪽 큰 로고 */
.page-hero-split {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 48px;
}

.page-hero-logo {
    flex-shrink: 0;
    width: clamp(240px, 26vw, 360px);
    height: auto;
    margin-bottom: 40px;
    filter: drop-shadow(0 30px 60px rgba(139, 92, 246, 0.45));
    animation: float 6s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

@media (max-width: 900px) {
    .page-hero-logo {
        display: none;
    }
}

/* ───────── 메인: 기록 현황 ───────── */
:root {
    --hm-0: #ece9e2;
    --hm-1: #d9d2fb;
    --hm-2: #b3a6f6;
    --hm-3: #8573ea;
    --hm-4: #5b4ddb;
    --hm-cell: 13px;
    --hm-gap: 3px;
}

@media (prefers-color-scheme: dark) {
    :root {
        --hm-0: #26242f;
        --hm-1: #3b3470;
        --hm-2: #5a4cb0;
        --hm-3: #7f6ee6;
        --hm-4: #b1a6ff;
    }
}

.heatmap-card,
.stats-panel {
    padding: 26px 28px;
    border-radius: var(--radius);
    background: var(--surface);
    border: 1px solid var(--line);
    box-shadow: var(--shadow);
}

.heatmap-summary {
    display: flex;
    flex-wrap: wrap;
    gap: 28px;
    margin-bottom: 18px;
    color: var(--muted);
    font-size: 0.92rem;
}

.heatmap-summary strong {
    font-size: 1.7rem;
    font-weight: 800;
    letter-spacing: -0.03em;
    color: var(--text);
    margin-right: 2px;
}

.heatmap-summary span {
    margin-left: 4px;
}

.heatmap-scroll {
    overflow-x: auto;
    padding-bottom: 6px;
    scrollbar-width: thin;
    direction: rtl; /* 좁은 화면에서 최근(오른쪽)부터 보이게 - 스크롤 시작점이 오른쪽 */
}

.heatmap {
    display: flex;
    gap: 8px;
    width: max-content;
    direction: ltr;
}

.hm-days {
    display: grid;
    grid-template-rows: 18px repeat(7, var(--hm-cell));
    row-gap: var(--hm-gap);
    font-size: 0.7rem;
    color: var(--muted);
    line-height: var(--hm-cell);
}

.hm-days span:first-child {
    height: 18px;
}

.hm-months {
    display: flex;
    gap: var(--hm-gap);
    height: 18px;
    font-size: 0.72rem;
    color: var(--muted);
}

.hm-months span {
    width: var(--hm-cell);
    white-space: nowrap;
    overflow: visible;
}

.hm-grid {
    display: flex;
    gap: var(--hm-gap);
}

.hm-week {
    display: grid;
    grid-template-rows: repeat(7, var(--hm-cell));
    gap: var(--hm-gap);
}

.hm-cell {
    display: inline-block;
    width: var(--hm-cell);
    height: var(--hm-cell);
    border-radius: 3px;
    background: var(--hm-0);
}

a.hm-cell {
    transition: transform 0.15s, outline-color 0.15s;
    outline: 2px solid transparent;
    outline-offset: 1px;
}

a.hm-cell:hover {
    transform: scale(1.35);
    outline-color: var(--accent);
}

.hm-cell.hm-out { background: transparent; }
.hm-cell.l1 { background: var(--hm-1); }
.hm-cell.l2 { background: var(--hm-2); }
.hm-cell.l3 { background: var(--hm-3); }
.hm-cell.l4 { background: var(--hm-4); }

.hm-legend {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 4px;
    margin-top: 10px;
    font-size: 0.78rem;
    color: var(--muted);
}

.hm-legend .hm-cell {
    width: 11px;
    height: 11px;
}

.stats-split {
    display: grid;
    grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
    gap: 20px;
    margin-top: 20px;
}

.stats-panel h3 {
    font-size: 1.1rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    margin-bottom: 14px;
}

/* 많이 읽은 기록 */
.popular {
    list-style: none;
}

.popular a {
    display: grid;
    grid-template-columns: 22px 52px minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
    padding: 9px 6px;
    border-radius: 12px;
    text-decoration: none;
    color: var(--text);
    transition: background 0.2s;
}

.popular a:hover {
    background: var(--surface-2);
}

.popular .rank {
    font-size: 1.05rem;
    font-weight: 800;
    color: var(--accent);
    text-align: center;
}

.popular img,
.popular .thumb-empty {
    width: 52px;
    height: 40px;
    border-radius: 9px;
    object-fit: cover;
    background: var(--surface-2);
}

.popular .ttl {
    font-size: 0.95rem;
    font-weight: 600;
    line-height: 1.45;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.popular .views {
    font-size: 0.82rem;
    color: var(--muted);
    white-space: nowrap;
}

/* 방문자 */
.visit-nums {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin-bottom: 20px;
}

.visit-nums div {
    padding: 12px 14px;
    border-radius: 14px;
    background: var(--surface-2);
}

.visit-nums span {
    display: block;
    font-size: 0.8rem;
    color: var(--muted);
}

.visit-nums strong {
    font-size: 1.55rem;
    font-weight: 800;
    letter-spacing: -0.03em;
}

.spark {
    display: flex;
    align-items: flex-end;
    gap: 3px;
    height: 96px;
    padding: 0 2px;
    border-bottom: 1px solid var(--line);
}

.spark .bar {
    flex: 1;
    min-height: 3px;
    border-radius: 4px 4px 1px 1px;
    background: var(--hm-2);
    transition: background 0.2s;
}

.spark .bar:hover {
    background: var(--hm-3);
}

.spark .bar.today {
    background: var(--accent);
}

.spark-foot {
    display: flex;
    justify-content: space-between;
    margin-top: 8px;
    font-size: 0.75rem;
    color: var(--muted);
}

@media (min-width: 1200px) {
    :root {
        --hm-cell: 15px;
    }
}

@media (max-width: 1024px) {
    .stats-split {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .heatmap-card,
    .stats-panel {
        padding: 20px 16px;
    }

    .heatmap-summary {
        gap: 18px;
    }

    .heatmap-summary strong {
        font-size: 1.4rem;
    }

    .popular a {
        grid-template-columns: 18px 46px minmax(0, 1fr) auto;
        gap: 10px;
    }
}
