/* ════════════════════════════════════════════════════════════
   Gilwell Media · Shared Stylesheet
   Design: newspaper-editorial, cream & black, serif typography
   ════════════════════════════════════════════════════════════ */

@font-face {
  font-family: 'AliceDigitalLearning';
  src: url('https://cdn.jsdelivr.net/gh/projectnoonnu/noonfonts_elice@1.0/EliceDigitalBaeum.woff2') format('woff2');
  font-weight: normal;
  font-display: swap;
}

@font-face {
  font-family: 'AliceDigitalLearning';
  src: url('https://cdn.jsdelivr.net/gh/projectnoonnu/noonfonts_elice@1.0/EliceDigitalBaeum-Bd.woff2') format('woff2');
  font-weight: 700;
  font-display: swap;
}

/* ── Reset & Box Model ───────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

/* ── Design Tokens ───────────────────────────────────────────── */
:root {
  --black:      #0a0a0a;
  --white:      #f5f3ee;
  --ink:        #1a1a1a;
  --muted:      #888080;
  --accent:     #4D006E;
  --border:     #e8e8e8;
  --bg:         #FFFFFF;
  --card-bg:    #fafafa;

  /* Category colours */
  --tag-korea:  #0094B4;
  --tag-apr:    #FF5655;
  --tag-worm:   #248737;
  --tag-people: #8A5A2B;

  /* Feedback colours */
  --success:    #248737;
  --danger:     #FF5655;
}

/* ── Base ────────────────────────────────────────────────────── */
html { scroll-behavior: smooth; }

body {
  background:  var(--bg);
  color:       var(--ink);
  font-family: 'AliceDigitalLearning', 'Noto Sans KR', sans-serif;
  font-weight: 300;
  line-height: 1.7;
  min-height:  100vh;
}

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

.skip-link {
  position: absolute;
  top: -48px;
  left: 16px;
  z-index: 10000;
  padding: 10px 14px;
  background: var(--black);
  color: var(--white);
  text-decoration: none;
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.06em;
}

.skip-link:focus {
  top: 12px;
}

p { margin-bottom: 6px; }

/* ════════════════════════════════════════════════════════════
   MASTHEAD
   ════════════════════════════════════════════════════════════ */
.masthead {
  border-bottom: 3px solid var(--accent);
  position:      sticky;
  top:           0;
  z-index:       100;
  background:    var(--bg);
}

.masthead-top {
  display:         flex;
  align-items:     center;
  justify-content: space-between;
  padding:         18px 48px;
  border-bottom:   1px solid var(--border);
  max-width:       1366px;
  margin:          0 auto;
}

.masthead-date {
  font-family: 'DM Mono', monospace;
  font-size:   12px;
  color:       var(--ink);
  line-height: 1.5;
  min-width:   160px;
}

.masthead-logo { text-align: center; }

.masthead-logo-row {
  display:         flex;
  flex-direction:  column;
  align-items:     center;
  justify-content: center;
  gap:             4px;
}

.masthead-logo-img {
  width:  38px;
  height: 38px;
  flex-shrink: 0;
}

.masthead-logo a {
  text-decoration: none;
  color:           inherit;
}

.masthead-logo h1 {
  font-family:    'AliceDigitalLearning', 'Playfair Display', serif;
  font-size:      32px;
  font-weight:    700;
  letter-spacing: -0.02em;
  color:          var(--accent);
  line-height:    1;
}

.masthead-logo .sub {
  font-family:    'DM Mono', monospace;
  font-size:      10px;
  letter-spacing: 0.2em;
  color:          var(--muted);
  text-transform: uppercase;
  margin-top:     3px;
}

.masthead-time {
  display:     block;
  font-family: 'DM Mono', monospace;
  font-size:   20px;
  font-weight: 500;
  color:       var(--accent);
  margin-top:  2px;
  letter-spacing: 0.04em;
}

.masthead-tagline {
  font-size:   11px;
  color:       var(--muted);
  text-align:  right;
  font-family: 'AliceDigitalLearning', 'Noto Serif KR', serif;
  font-style:  italic;
}

.masthead-right {
  display:        flex;
  flex-direction: column;
  align-items:    flex-end;
  gap:            6px;
  min-width:      160px;
}

.masthead-stats {
  font-family:    'DM Mono', monospace;
  font-size:      10px;
  color:          var(--muted);
  letter-spacing: 0.04em;
  text-align:     right;
  line-height:    1.5;
}

.masthead-stats strong {
  color:       var(--ink);
  font-weight: 500;
}

.stat-sep {
  margin: 0 4px;
  color:  var(--border);
}

.lang-toggle {
  display:   flex;
  gap:       0;
  border:    1px solid var(--border);
  overflow:  hidden;
}

.lang-btn {
  font-family:    'DM Mono', monospace;
  font-size:      9px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding:        3px 8px;
  border:         none;
  background:     transparent;
  color:          var(--muted);
  cursor:         pointer;
  transition:     background 0.12s, color 0.12s;
}

.lang-btn + .lang-btn { border-left: 1px solid var(--border); }

.lang-btn.active,
.lang-btn:hover {
  background: var(--black);
  color:      var(--white);
}

/* ════════════════════════════════════════════════════════════
   NAVIGATION
   ════════════════════════════════════════════════════════════ */
.nav {
  display:    flex;
  align-items: center;
  gap:         0;
  padding:     0 48px;
  overflow-x:  auto;
  border-top:  1px solid var(--border);
  max-width:   1366px;
  margin:      0 auto;
}

.nav a {
  font-family:    'DM Mono', monospace;
  font-size:      11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color:          var(--muted);
  text-decoration: none;
  padding:        12px 20px;
  white-space:    nowrap;
  transition:     color 0.15s;
  background:     none;
  border:         none;
}

.nav a:hover,
.nav a.active {
  background: none;
  color:      var(--accent);
}

/* ════════════════════════════════════════════════════════════
   TICKER
   ════════════════════════════════════════════════════════════ */
.ticker {
  background:    var(--black);
  color:         var(--white);
  padding:       8px 0;
  padding-left:  10%;
  padding-right: 10%;
  overflow:      hidden;
  white-space:   nowrap;
}

.ticker-inner {
  display:        inline-block;
  white-space:    nowrap;
  animation:      ticker 30s linear infinite;
  font-family:    'DM Mono', monospace;
  font-size:      11px;
  letter-spacing: 0.08em;
}

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

@keyframes ticker {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

/* ════════════════════════════════════════════════════════════
   CATEGORY TAGS
   ════════════════════════════════════════════════════════════ */
.category-tag {
  display:        inline-block;
  font-family:    'DM Mono', monospace;
  font-size:      10px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  padding:        3px 8px;
  color:          var(--white);
  font-weight:    500;
}

.tag-korea { background: var(--tag-korea); }
.tag-apr   { background: var(--tag-apr);   }
.tag-worm  { background: var(--tag-worm);  }
.tag-people{ background: var(--tag-people);}

/* ════════════════════════════════════════════════════════════
   HERO SECTION (index.html)
   ════════════════════════════════════════════════════════════ */
.hero {
  display:              grid;
  grid-template-columns: 1fr 340px;
  gap:                  0;
  border-bottom:        2px solid var(--black);
  max-width:            1366px;
  margin:               0 auto;
}

.hero-main {
  padding:      48px;
  border-right: 1px solid var(--border);
}

.hero-main .category-tag { margin-bottom: 16px; }

.hero-main h2 {
  font-family:    'AliceDigitalLearning', 'Noto Serif KR', serif;
  font-size:      36px;
  font-weight:    700;
  line-height:    1.35;
  letter-spacing: -0.02em;
  margin-bottom:  16px;
  color:          var(--black);
}

.hero-main .deck {
  font-size:     15px;
  color:         var(--muted);
  line-height:   1.7;
  margin-bottom: 24px;
  font-family:   'AliceDigitalLearning', 'Noto Serif KR', serif;
  font-weight:   300;
}

.hero-main .meta {
  font-family:    'DM Mono', monospace;
  font-size:      11px;
  color:          var(--muted);
  letter-spacing: 0.06em;
}

.hero-side {
  padding:        32px;
  display:        flex;
  flex-direction: column;
}

.hero-side-item {
  padding:       20px 0;
  border-bottom: 1px solid var(--border);
}

.hero-side-item:last-child { border-bottom: none; }

.hero-side-item h3 {
  font-family:   'AliceDigitalLearning', 'Noto Serif KR', serif;
  font-size:     15px;
  font-weight:   600;
  line-height:   1.4;
  margin-bottom: 8px;
  color:         var(--black);
}

.hero-side-item .meta {
  font-family:    'DM Mono', monospace;
  font-size:      10px;
  color:          var(--muted);
  letter-spacing: 0.06em;
}

/* ════════════════════════════════════════════════════════════
   MAIN CONTENT LAYOUT
   ════════════════════════════════════════════════════════════ */
.content-wrapper {
  max-width:             1366px;
  margin:                0 auto;
  display:               grid;
  grid-template-columns: 1fr 300px;
  gap:                   0;
}

.main-feed { border-right: 1px solid var(--border); }

/* ── Section Header ── */
.section-header {
  display:       flex;
  align-items:   baseline;
  gap:           16px;
  padding:       32px 48px 20px;
  border-bottom: 2px solid var(--black);
}

.section-header h2 {
  font-family:    'AliceDigitalLearning', 'Playfair Display', serif;
  font-size:      20px;
  font-weight:    700;
  letter-spacing: -0.01em;
}

.section-header .rule {
  flex:       1;
  height:     1px;
  background: var(--border);
}

/* ── Filter Bar (index.html) ── */
.filter-bar {
  display:       flex;
  gap:           8px;
  padding:       20px 48px;
  border-bottom: 1px solid var(--border);
  flex-wrap:     wrap;
  background:    var(--bg);
}

.filter-btn {
  font-family:    'DM Mono', monospace;
  font-size:      10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding:        5px 12px;
  border:         1px solid var(--border);
  background:     none;
  cursor:         pointer;
  color:          var(--muted);
  transition:     all 0.15s;
}

.filter-btn:hover,
.filter-btn.active {
  background:   var(--black);
  color:        var(--white);
  border-color: var(--black);
}

/* ════════════════════════════════════════════════════════════
   ARTICLE CARD (index.html feed)
   ════════════════════════════════════════════════════════════ */
.article-card {
  padding:        24px 0;
  border-bottom:  1px solid var(--border);
  display:        block;
  transition:     background 0.15s;
  cursor:         pointer;
  animation:      fadeUp 0.4s ease both;
}

.article-card:hover { background: rgba(0,0,0,0.02); }

.article-card:nth-child(1) { animation-delay: 0.05s; }
.article-card:nth-child(2) { animation-delay: 0.10s; }
.article-card:nth-child(3) { animation-delay: 0.15s; }
.article-card:nth-child(4) { animation-delay: 0.20s; }
.article-card:nth-child(5) { animation-delay: 0.25s; }


.article-card .category-tag { margin-bottom: 10px; }

.article-card h3 {
  font-family:   'AliceDigitalLearning', 'Noto Serif KR', serif;
  font-size:     18px;
  font-weight:   600;
  line-height:   1.45;
  margin-bottom: 8px;
  color:         var(--black);
}

.article-card .excerpt {
  font-size:     13px;
  color:         var(--muted);
  line-height:   1.65;
  margin-bottom: 12px;
}

.article-card .meta {
  font-family:    'DM Mono', monospace;
  font-size:      10px;
  color:          var(--muted);
  letter-spacing: 0.06em;
}

/* ════════════════════════════════════════════════════════════
   SIDEBAR
   ════════════════════════════════════════════════════════════ */
.sidebar { padding: 0; }

.sidebar-section {
  padding:       28px;
  border-bottom: 1px solid var(--border);
}

.sidebar-section h3 {
  font-family:    'AliceDigitalLearning', 'Playfair Display', serif;
  font-size:      14px;
  font-weight:    700;
  letter-spacing: 0.02em;
  margin-bottom:  20px;
  padding-bottom: 10px;
  border-bottom:  2px solid var(--black);
}

.sidebar-item {
  padding:       14px 0;
  border-bottom: 1px solid var(--border);
}

.sidebar-item:last-child { border-bottom: none; }

.sidebar-item h4 {
  font-family:   'AliceDigitalLearning', 'Noto Serif KR', serif;
  font-size:     13px;
  font-weight:   600;
  line-height:   1.4;
  margin-bottom: 6px;
  color:         var(--black);
}

.sidebar-item .meta {
  font-family:    'DM Mono', monospace;
  font-size:      10px;
  color:          var(--muted);
  letter-spacing: 0.05em;
}

/* ── About Box ── */
.about-box {
  background: var(--black);
  color:      var(--white);
  padding:    28px;
  margin:     28px;
}

.about-box h3 {
  font-family: 'AliceDigitalLearning', 'Playfair Display', serif;
  font-size:   18px;
  font-style:  italic;
  margin-bottom: 12px;
}

.about-box p {
  font-size:   12px;
  line-height: 1.7;
  color:       rgba(245,243,238,0.75);
  font-family: 'AliceDigitalLearning', 'Noto Serif KR', serif;
}

.about-box .divider {
  height:     1px;
  background: rgba(255,255,255,0.15);
  margin:     16px 0;
}

.about-box .domain {
  font-family:    'DM Mono', monospace;
  font-size:      11px;
  color:          var(--accent);
  letter-spacing: 0.1em;
}

/* ════════════════════════════════════════════════════════════
   SITE HERO (index.html top banner)
   ════════════════════════════════════════════════════════════ */

/* ── Hero Slider wrapper ───────────────────────────────────── */
.site-hero-slider {
  position: relative;
  overflow: hidden;
  height: 380px;
}
.site-hero-slider .site-hero-slide {
  position: absolute;
  inset: 0;
  z-index: 0;
  transform: translateX(100%);
  pointer-events: none;
  visibility: hidden;
  transition: transform 0.55s ease;
}
.site-hero-slider .site-hero-slide.active {
  z-index: 1;
  transform: translateX(0);
  visibility: visible;
  pointer-events: auto;
}
.site-hero-slider .site-hero-slide.before {
  transform: translateX(-100%);
}
.site-hero-slider .site-hero-slide.transitioning {
  visibility: visible;
}
.hero-dots {
  display: flex;
  justify-content: center;
  gap: 8px;
  padding: 10px 0 2px;
  background: #fff;
  border-bottom: 1px solid var(--border);
}
.hero-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--border);
  border: none;
  cursor: pointer;
  padding: 0;
  transition: background 0.2s;
}
.hero-dot.active {
  background: #622599;
}

.site-hero {
  background:      #ffffff;
  padding:         64px 24px;
  text-align:      center;
  position:        relative;
  overflow:        hidden;
  height:          100%;
  min-height:      380px;
  display:         flex;
  align-items:     center;
  justify-content: center;
  border-bottom:   2px solid var(--border);
}

/* Background image mode */
.site-hero.has-bg {
  background-size:     cover;
  background-position: center;
}
.site-hero.has-bg::after {
  content:    '';
  position:   absolute;
  inset:      0;
  background: rgba(0, 0, 0, 0.58);
  z-index:    1;
}

/* Large watermark subtitle in background */
.site-hero-bg-text {
  position:       absolute;
  bottom:         -4px;
  left:           0;
  right:          0;
  font-family:    'Playfair Display', serif;
  font-size:      clamp(36px, 7vw, 90px);
  font-weight:    700;
  color:          rgba(77, 0, 110, 0.05);
  white-space:    nowrap;
  overflow:       hidden;
  text-align:     center;
  pointer-events: none;
  line-height:    1;
  z-index:        2;
}
.site-hero.has-bg .site-hero-bg-text { color: rgba(255, 255, 255, 0.13); }

/* Foreground content wrapper */
.site-hero-content {
  position: relative;
  z-index:  3;
}

.site-hero-eyebrow {
  font-family:    'DM Mono', monospace;
  font-size:      10px;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color:          var(--accent);
  margin-bottom:  14px;
}
.site-hero.has-bg .site-hero-eyebrow { color: rgba(255,255,255,0.7); }

.site-hero-title {
  font-family:        'AliceDigitalLearning', 'Playfair Display', serif;
  font-size:          clamp(28px, 5vw, 48px);
  font-weight:        700;
  color:              var(--black);
  line-height:        1.2;
  max-width:          680px;
  margin:             0 auto 16px;
  display:            -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow:           hidden;
}
.site-hero.has-bg .site-hero-title { color: #ffffff; }

.site-hero-sub {
  font-family: 'AliceDigitalLearning', 'Noto Sans KR', sans-serif;
  font-size:   14px;
  color:       var(--muted);
  max-width:   520px;
  margin:      0 auto;
  line-height: 1.7;
}
.site-hero.has-bg .site-hero-sub { color: rgba(255,255,255,0.65); }

/* Subtitle text on dynamic hero */
.site-hero-subtitle {
  font-family: 'Noto Serif KR', serif;
  font-size:   16px;
  color:       rgba(255,255,255,0.78);
  max-width:   560px;
  margin:      -8px auto 20px;
  line-height: 1.6;
}

/* CTA button on dynamic hero */
.site-hero-cta {
  display:        inline-block;
  margin-top:     8px;
  padding:        10px 28px;
  border:         1px solid rgba(255,255,255,0.55);
  background:     transparent;
  color:          #ffffff;
  font-family:    'DM Mono', monospace;
  font-size:      11px;
  letter-spacing: .1em;
  text-transform: uppercase;
  cursor:         pointer;
  transition:     background .2s, border-color .2s;
}
.site-hero-cta:hover {
  background:   rgba(255,255,255,0.15);
  border-color: #fff;
}

/* ════════════════════════════════════════════════════════════
   HOME PAGE SECTIONS
   ════════════════════════════════════════════════════════════ */
.home-wrapper {
  max-width: 1366px;
  margin:    0 auto;
  padding:   0 48px 60px;
}

/* ── Shared section heading ── */
.home-section-title {
  font-family:    'AliceDigitalLearning', 'Playfair Display', serif;
  font-size:      18px;
  font-weight:    700;
  letter-spacing: -0.01em;
  padding:        32px 0 16px;
  border-bottom:  2px solid var(--black);
  margin-bottom:  20px;
  display:        flex;
  align-items:    baseline;
  gap:            12px;
}

.home-section-title .rule {
  flex:       1;
  height:     1px;
  background: var(--border);
}

.home-section-more {
  font-family:    'DM Mono', monospace;
  font-size:      10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color:          var(--muted);
  text-decoration: none;
  transition:     color 0.15s;
}
.home-section-more:hover { color: var(--accent); }

/* ── 2-column: popular + editor picks ── */
.home-2col {
  display:               grid;
  grid-template-columns: 1fr 1fr;
  gap:                   48px;
  margin-bottom:         48px;
}

/* ── Mini article list (popular / editor picks) ── */
.mini-list { display: flex; flex-direction: column; }

.mini-item {
  padding:         16px 0;
  border-bottom:   1px solid var(--border);
  cursor:          pointer;
  transition:      background 0.15s;
  display:         block;
  text-decoration: none;
  color:           inherit;
}
.mini-item:hover { background: rgba(0,0,0,0.02); }
.mini-item:last-child { border-bottom: none; }

.mini-item .category-tag { margin-bottom: 0; }

.mini-item-labels {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  margin-bottom: 6px;
}

.mini-item-labels .post-kicker {
  margin-bottom: 0;
  font-size: 10px;
  padding: 3px 8px;
  letter-spacing: 0.15em;
}

.mini-item h4 {
  font-family:   'AliceDigitalLearning', 'Noto Serif KR', serif;
  font-size:     15px;
  font-weight:   600;
  line-height:   1.4;
  color:         var(--black);
  margin-bottom: 4px;
}

.mini-item .mini-meta {
  font-family:    'DM Mono', monospace;
  font-size:      10px;
  color:          var(--muted);
  letter-spacing: 0.05em;
}

/* Thumbnail layout for mini-items */
.mini-item-row {
  display:     flex;
  align-items: flex-start;
  gap:         12px;
}

.mini-item-text { flex: 1; min-width: 0; }

.mini-thumb {
  width:       72px;
  height:      54px;
  object-fit:  cover;
  flex-shrink: 0;
  display:     block;
  border:      1px solid var(--border);
}

.mini-empty {
  padding:     24px 0;
  color:       var(--muted);
  font-family: 'AliceDigitalLearning', 'Noto Serif KR', serif;
  font-size:   13px;
}

/* ── 3-column: Korea / APR / WOSM ── */
.home-3col {
  display:               grid;
  grid-template-columns: repeat(4, 1fr);
  gap:                   40px;
  margin-bottom:         48px;
}

.home-col-header {
  display:       flex;
  align-items:   center;
  justify-content: space-between;
  padding-bottom: 10px;
  border-bottom:  2px solid var(--black);
  margin-bottom:  12px;
}

.home-col-header h3 {
  font-family: 'DM Mono', monospace;
  font-size:   12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color:       var(--black);
}

/* Reuse mini-item inside 3-col */

/* ── Index feed (legacy single-col, kept for safety) ── */
.index-wrapper {
  max-width: 760px;
  margin:    0 auto;
  padding:   0 24px 60px;
}

.index-board-links {
  display:    flex;
  gap:        12px;
  flex-wrap:  wrap;
  padding:    32px 0 0;
  border-top: 1px solid var(--border);
}

/* ════════════════════════════════════════════════════════════
   BOARD PAGE BANNER (korea / apr / worm)
   ════════════════════════════════════════════════════════════ */
.board-banner {
  border-bottom: 2px solid var(--black);
  padding:       40px 48px;
  max-width:     1366px;
  margin:        0 auto;
  display:       flex;
  align-items:   flex-end;
  justify-content: space-between;
  gap:           24px;
}

.board-banner-text h2 {
  font-family:    'AliceDigitalLearning', 'Playfair Display', serif;
  font-size:      40px;
  font-weight:    700;
  letter-spacing: -0.02em;
  color:          var(--black);
  line-height:    1.1;
  margin-bottom:  8px;
}

.board-banner-text p {
  font-family: 'AliceDigitalLearning', 'Noto Serif KR', serif;
  font-size:   14px;
  color:       var(--muted);
  line-height: 1.6;
}

.board-banner-count {
  font-family:    'AliceDigitalLearning', 'Playfair Display', serif;
  font-size:      56px;
  font-weight:    700;
  color:          var(--border);
  line-height:    1;
  flex-shrink:    0;
}

/* ════════════════════════════════════════════════════════════
   BULLETIN BOARD POST LIST
   ════════════════════════════════════════════════════════════ */
.board-container {
  max-width: 1366px;
  margin:    0 auto;
  padding:   0 48px 60px;
}

.board-grid {
  display:               grid;
  grid-template-columns: repeat(4, 1fr);
  gap:                   2px;
  margin-top:            2px;
}

/* ── Post Card (board pages) ── */
.post-card {
  background:  var(--card-bg);
  border:      1px solid var(--border);
  cursor:      pointer;
  transition:  transform 0.15s, box-shadow 0.15s;
  animation:   fadeUp 0.4s ease both;
  display:     flex;
  flex-direction: column;
}

.post-card:hover {
  transform:  translateY(-2px);
  box-shadow: 0 4px 20px rgba(0,0,0,0.08);
}

.post-card:nth-child(1) { animation-delay: 0.04s; }
.post-card:nth-child(2) { animation-delay: 0.08s; }
.post-card:nth-child(3) { animation-delay: 0.12s; }
.post-card:nth-child(4) { animation-delay: 0.16s; }
.post-card:nth-child(5) { animation-delay: 0.20s; }
.post-card:nth-child(6) { animation-delay: 0.24s; }

.post-card-thumb {
  width:          100%;
  aspect-ratio:   16 / 9;
  object-fit:     cover;
  display:        block;
  border-bottom:  1px solid var(--border);
}

.post-card-body {
  padding: 24px;
  flex:    1;
  display: flex;
  flex-direction: column;
}

.post-card-labels {
  display:       flex;
  align-items:   center;
  gap:           6px;
  flex-wrap:     wrap;
  margin-bottom: 12px;
}

.post-card-labels .category-tag,
.post-card-labels .post-kicker { margin-bottom: 0; }

.post-card-body h3 {
  font-family:   'AliceDigitalLearning', 'Noto Serif KR', serif;
  font-size:     17px;
  font-weight:   600;
  line-height:   1.45;
  margin-bottom: 10px;
  color:         var(--black);
  flex:          1;
}

.post-card-excerpt {
  font-size:     13px;
  color:         var(--muted);
  line-height:   1.65;
  margin-bottom: 16px;
  /* Clamp to 3 lines */
  display:          -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow:         hidden;
}

.post-card-meta {
  font-family:    'DM Mono', monospace;
  font-size:      10px;
  color:          var(--muted);
  letter-spacing: 0.06em;
  margin-top:     auto;
  padding-top:    6px;
}

/* ── Read More link ── */
.read-more {
  display:        inline-block;
  font-family:    'DM Mono', monospace;
  font-size:      10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color:          var(--accent);
  text-decoration: none;
  margin-top:     8px;
  border-bottom:  1px solid var(--accent);
  padding-bottom: 1px;
}

/* ── Load More button ── */
.load-more-btn {
  display:        block;
  margin:         40px auto 0;
  padding:        12px 32px;
  background:     none;
  border:         1px solid var(--border);
  font-family:    'DM Mono', monospace;
  font-size:      11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color:          var(--muted);
  cursor:         pointer;
  transition:     all 0.15s;
}

.load-more-btn:hover {
  background:   var(--black);
  color:        var(--white);
  border-color: var(--black);
}

.load-more-btn:disabled {
  opacity: 0.4;
  cursor:  not-allowed;
}

/* ════════════════════════════════════════════════════════════
   POST DETAIL MODAL
   ════════════════════════════════════════════════════════════ */
.modal-overlay {
  position:        fixed;
  inset:           0;
  background:      rgba(10,10,10,0.7);
  z-index:         500;
  display:         flex;
  align-items:     center;
  justify-content: center;
  padding:         24px;
  opacity:         0;
  pointer-events:  none;
  transition:      opacity 0.2s;
}

.modal-overlay.open {
  opacity:        1;
  pointer-events: all;
}

.modal {
  background:  var(--bg);
  max-width:   720px;
  width:       100%;
  max-height:  90vh;
  overflow-y:  auto;
  position:    relative;
  transform:   translateY(20px);
  transition:  transform 0.25s ease;
}

.modal-overlay.open .modal {
  transform: translateY(0);
}

.modal-header {
  padding:       36px 40px 0;
  border-bottom: none;
}

.modal-header .category-tag { margin-bottom: 16px; }

.modal-header h2 {
  font-family:    'AliceDigitalLearning', 'Noto Serif KR', serif;
  font-size:      26px;
  font-weight:    700;
  line-height:    1.4;
  color:          var(--black);
  margin-bottom:  12px;
}

.modal-header .modal-date {
  font-family:    'DM Mono', monospace;
  font-size:      11px;
  color:          var(--muted);
  letter-spacing: 0.06em;
  padding-bottom: 24px;
  border-bottom:  1px solid var(--border);
}

.modal-img {
  width:         100%;
  max-height:    360px;
  object-fit:    cover;
  display:       block;
  margin-top:    24px;
  border-bottom: 1px solid var(--border);
}

.youtube-embed-wrap {
  position: relative;
  width: 100%;
  padding-top: 56.25%;
  background: #000;
  margin-top: 24px;
  overflow: hidden;
}

.youtube-embed {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

.modal-body {
  padding:     28px 40px 40px;
  font-family: 'AliceDigitalLearning', 'Noto Serif KR', serif;
  font-size:   15px;
  font-weight: 300;
  line-height: 1.85;
  color:       var(--ink);
  white-space: pre-wrap; /* Preserve line breaks */
}

.modal-close {
  position:    absolute;
  top:         20px;
  right:       20px;
  background:  none;
  border:      none;
  font-size:   24px;
  cursor:      pointer;
  color:       var(--muted);
  line-height: 1;
  padding:     4px 8px;
  transition:  color 0.15s;
  font-family: 'DM Mono', monospace;
}

.modal-close:hover { color: var(--black); }

/* ════════════════════════════════════════════════════════════
   EMPTY & LOADING STATES
   ════════════════════════════════════════════════════════════ */
.empty-state {
  padding:    60px 48px;
  text-align: center;
  color:      var(--muted);
}

.empty-state .empty-icon {
  font-family:   'AliceDigitalLearning', 'Playfair Display', serif;
  font-size:     48px;
  font-style:    italic;
  color:         var(--border);
  display:       block;
  margin-bottom: 16px;
}

.empty-state p {
  font-family: 'AliceDigitalLearning', 'Noto Serif KR', serif;
  font-size:   14px;
  line-height: 1.7;
}

.loading-state {
  padding:    48px;
  text-align: center;
}

.loading-dots {
  display:        inline-flex;
  gap:            6px;
  align-items:    center;
}

.loading-dots span {
  width:      8px;
  height:     8px;
  background: var(--border);
  border-radius: 50%;
  animation:  dotPulse 1.2s ease-in-out infinite;
}

.loading-dots span:nth-child(2) { animation-delay: 0.2s; }
.loading-dots span:nth-child(3) { animation-delay: 0.4s; }

@keyframes dotPulse {
  0%, 100% { opacity: 0.3; transform: scale(0.8); }
  50%       { opacity: 1;   transform: scale(1); }
}

.error-state {
  padding:    40px 48px;
  text-align: center;
  font-family: 'DM Mono', monospace;
  font-size:  12px;
  color:      var(--danger);
}

/* ════════════════════════════════════════════════════════════
   TOAST NOTIFICATION
   ════════════════════════════════════════════════════════════ */
.toast {
  position:       fixed;
  bottom:         32px;
  right:          32px;
  background:     var(--black);
  color:          var(--white);
  font-family:    'DM Mono', monospace;
  font-size:      12px;
  letter-spacing: 0.08em;
  padding:        14px 24px;
  z-index:        999;
  transform:      translateY(80px);
  opacity:        0;
  transition:     all 0.25s ease;
  pointer-events: none;
}

.toast.show { transform: translateY(0); opacity: 1; }
.toast.success { border-left: 4px solid var(--success); }
.toast.error   { border-left: 4px solid var(--danger);  }

/* ════════════════════════════════════════════════════════════
   FOOTER
   ════════════════════════════════════════════════════════════ */
footer {
  background: #622599;
}

.footer-inner {
  max-width:       1366px;
  margin:          0 auto;
  padding:         32px 48px 24px;
  display:         flex;
  align-items:     flex-start;
  justify-content: space-between;
  flex-wrap:       wrap;
  gap:             20px;
}

footer h4 {
  font-family:    'AliceDigitalLearning', 'Playfair Display', serif;
  font-size:      14px;
  font-weight:    700;
  margin-bottom:  10px;
  color:          #ffffff;
  letter-spacing: 0.05em;
}

footer p, footer a {
  font-size:       12px;
  color:           rgba(255,255,255,0.75);
  line-height:     1.8;
  text-decoration: none;
  display:         block;
}

.footer-build {
  margin-top:      8px;
  font-family:     'DM Mono', monospace;
  font-size:       10px;
  letter-spacing:  0.12em;
  text-transform:  uppercase;
  color:           rgba(255,255,255,0.55);
}

footer a:hover { color: #ffffff; }

/* Bottom disclaimer bar */
.footer-bottom {
  width:           100%;
  border-top:      1px solid rgba(255,255,255,0.2);
  padding-top:     16px;
  margin-top:      8px;
  display:         flex;
  justify-content: space-between;
  align-items:     center;
  flex-wrap:       wrap;
  gap:             8px;
}

.footer-bottom p {
  font-family:    'DM Mono', monospace;
  font-size:      10px;
  color:          rgba(255,255,255,0.55);
  letter-spacing: 0.08em;
}

/* ════════════════════════════════════════════════════════════
   MODAL SUBTITLE
   ════════════════════════════════════════════════════════════ */
.modal-subtitle {
  font-family:   'Noto Serif KR', serif;
  font-size:     15px;
  color:         var(--muted);
  margin:        4px 0 12px;
  line-height:   1.6;
}

/* ════════════════════════════════════════════════════════════
   COVER IMAGE UPLOAD (write form)
   ════════════════════════════════════════════════════════════ */
.cover-upload-wrap  { margin-top: 8px; }

.cover-upload-btn {
  display:        inline-flex;
  align-items:    center;
  gap:            6px;
  padding:        8px 16px;
  border:         1px dashed var(--border);
  background:     var(--bg);
  font-family:    'DM Mono', monospace;
  font-size:      11px;
  color:          var(--muted);
  cursor:         pointer;
  transition:     border-color .15s, color .15s;
}
.cover-upload-btn:hover { border-color: var(--black); color: var(--ink); }

.cover-preview-img {
  display:    block;
  max-width:  100%;
  max-height: 200px;
  margin-top: 10px;
  object-fit: cover;
}

.cover-remove-btn {
  display:     block;
  margin-top:  6px;
  padding:     4px 10px;
  border:      1px solid var(--border);
  background:  none;
  font-family: 'DM Mono', monospace;
  font-size:   10px;
  color:       var(--muted);
  cursor:      pointer;
}
.cover-remove-btn:hover { color: var(--danger); border-color: var(--danger); }

/* ════════════════════════════════════════════════════════════
   HERO SEARCH RESULTS (admin)
   ════════════════════════════════════════════════════════════ */
.hero-result-item {
  padding:     10px 12px;
  border:      1px solid var(--border);
  border-top:  none;
  font-size:   13px;
  cursor:      pointer;
  transition:  background .12s;
  line-height: 1.5;
}
.hero-result-item:first-child { border-top: 1px solid var(--border); }
.hero-result-item:hover       { background: var(--bg); }

/* ════════════════════════════════════════════════════════════
   TAG PILLS (글머리 선택기)
   ════════════════════════════════════════════════════════════ */

.tag-pill-group {
  display:   flex;
  flex-wrap: wrap;
  gap:       8px;
  margin:    8px 0 16px;
}

.tag-pill {
  display:       inline-block;
  padding:       4px 12px;
  border:        1px solid var(--border);
  font-family:   'DM Mono', monospace;
  font-size:     11px;
  letter-spacing:.08em;
  color:         var(--muted);
  cursor:        pointer;
  background:    var(--bg);
  transition:    background .15s, color .15s, border-color .15s;
  user-select:   none;
}

.tag-pill:hover {
  border-color: var(--black);
  color:        var(--ink);
}

.tag-pill.active {
  background:   var(--black);
  color:        var(--white);
  border-color: var(--black);
}

.tag-admin-toolbar {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(180px, .9fr) auto;
  gap: 10px;
  margin-bottom: 14px;
}

.tag-admin-toolbar input,
.tag-admin-toolbar select {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--border);
  background: var(--white);
  color: var(--ink);
  font-family: 'DM Mono', monospace;
  font-size: 12px;
  outline: none;
  box-sizing: border-box;
}

.tag-admin-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.tag-admin-panel {
  border: 1px solid var(--border);
  background: var(--bg);
}

.tag-admin-panel-head {
  padding: 12px 14px;
  border-bottom: 1px solid var(--border);
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--muted);
}

.tag-admin-lane {
  min-height: 110px;
  padding: 12px;
  display: flex;
  flex-wrap: wrap;
  align-content: flex-start;
  gap: 8px;
  transition: background .15s, box-shadow .15s, border-color .15s;
}

.tag-admin-lane.drag-over {
  background: rgba(98,37,153,0.06);
  box-shadow: inset 0 0 0 2px rgba(98,37,153,0.18);
}

.tag-admin-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  border: 1px solid var(--border);
  background: var(--white);
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  color: var(--ink);
  cursor: grab;
  user-select: none;
}

.tag-admin-chip.dragging {
  opacity: .45;
}

.tag-admin-chip-remove {
  border: 0;
  background: none;
  color: var(--muted);
  cursor: pointer;
  font-family: inherit;
  font-size: 12px;
  line-height: 1;
  padding: 0;
}

.tag-admin-empty {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  color: var(--muted);
  letter-spacing: .08em;
  text-transform: uppercase;
}

.share-meta-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.share-meta-card {
  border: 1px solid var(--border);
  background: var(--bg);
  padding: 14px;
}

.share-meta-card-head {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 12px;
}

.share-meta-card label {
  display: block;
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 12px 0 6px;
}

.share-meta-card input,
.share-meta-card textarea {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--border);
  background: var(--white);
  color: var(--ink);
  font-family: 'Noto Sans KR', sans-serif;
  font-size: 13px;
  box-sizing: border-box;
  outline: none;
  resize: vertical;
}

/* Post kicker label shown next to category tag — outline style, same size */
.post-kicker {
  display:        inline-block;
  font-family:    'DM Mono', monospace;
  font-size:      10px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  font-weight:    500;
  background:     transparent;
  padding:        3px 8px;
}

.post-kicker-new {
  border: 1px solid #d94a3a;
  background: #fff2ee;
  color: #d94a3a;
}

/* Per-category kicker border+text colors */
.tag-korea-kicker { border: 1px solid var(--tag-korea); color: var(--tag-korea); }
.tag-apr-kicker   { border: 1px solid var(--tag-apr);   color: var(--tag-apr);   }
.tag-worm-kicker  { border: 1px solid var(--tag-worm);  color: var(--tag-worm);  }
.tag-people-kicker{ border: 1px solid var(--tag-people); color: var(--tag-people); }

/* ════════════════════════════════════════════════════════════
   ADMIN STYLES
   ════════════════════════════════════════════════════════════ */

/* Login screen */
.login-screen {
  min-height:      100vh;
  display:         flex;
  align-items:     center;
  justify-content: center;
  background:      var(--black);
}

.login-box {
  background: var(--bg);
  padding:    48px;
  width:      100%;
  max-width:  400px;
}

.login-box .logo {
  font-family:   'AliceDigitalLearning', 'Playfair Display', serif;
  font-size:     24px;
  font-weight:   700;
  margin-bottom: 4px;
}

.login-box .sub {
  font-family:    'DM Mono', monospace;
  font-size:      10px;
  letter-spacing: 0.15em;
  color:          var(--muted);
  text-transform: uppercase;
  margin-bottom:  32px;
}

.login-box label {
  display:        block;
  font-family:    'DM Mono', monospace;
  font-size:      10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color:          var(--muted);
  margin-bottom:  6px;
}

.login-box input {
  width:         100%;
  padding:       12px 14px;
  border:        1px solid var(--border);
  background:    var(--white);
  font-family:   'DM Mono', monospace;
  font-size:     14px;
  color:         var(--ink);
  margin-bottom: 20px;
  outline:       none;
  transition:    border 0.15s;
}

.login-box input:focus { border-color: var(--black); }

.login-btn {
  width:          100%;
  padding:        14px;
  background:     var(--black);
  color:          var(--white);
  border:         none;
  font-family:    'DM Mono', monospace;
  font-size:      11px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  cursor:         pointer;
  transition:     background 0.15s;
}

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

.login-error {
  margin-top:  12px;
  font-family: 'DM Mono', monospace;
  font-size:   11px;
  color:       var(--danger);
  text-align:  center;
  display:     none;
}

/* Admin layout */
.admin-screen { display: none; }

/* ── Admin Dashboard ──────────────────────────────────────── */
.admin-dashboard {
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 24px;
}
.dash-stats-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
@media (max-width: 700px) { .dash-stats-row { grid-template-columns: repeat(2, 1fr); } }
.analytics-stats-row {
  grid-template-columns: repeat(6, 1fr);
}
.dash-stat-card {
  background: var(--bg);
  border: 1px solid var(--border);
  padding: 20px 16px;
  text-align: center;
}
.dash-stat-num {
  font-family: 'Playfair Display', serif;
  font-size: 36px;
  font-weight: 700;
  color: #622599;
  line-height: 1;
  margin-bottom: 6px;
}
.dash-stat-label {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--muted);
}
.dash-actions {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}
.dashboard-2col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}
.analytics-note {
  margin: 14px 0 0;
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  color: var(--muted);
  line-height: 1.7;
}
.analytics-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  justify-content: space-between;
  gap: 14px;
}
.analytics-toolbar-group {
  display: flex;
  align-items: center;
  gap: 10px;
}
.analytics-toolbar-group label {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}
.analytics-view-toggle {
  display: inline-flex;
  border: 1px solid var(--border);
}
.analytics-view-toggle button {
  border: none;
  background: var(--bg);
  color: var(--muted);
  padding: 8px 12px;
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  cursor: pointer;
}
.analytics-view-toggle button + button {
  border-left: 1px solid var(--border);
}
.analytics-view-toggle button.active {
  background: var(--black);
  color: var(--white);
}
.analytics-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.analytics-chart-wrap,
.analytics-table-wrap {
  min-height: 160px;
}
.analytics-chart-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 14px;
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  color: var(--muted);
}
.analytics-chart-legend span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.analytics-legend-swatch {
  display: inline-block;
  width: 10px;
  height: 10px;
}
.analytics-chart {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.analytics-bar-row {
  display: grid;
  grid-template-columns: 56px 1fr;
  gap: 12px;
  align-items: start;
}
.analytics-bar-label {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  color: var(--muted);
  letter-spacing: 0.06em;
  padding-top: 4px;
}
.analytics-bar-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.analytics-bar-line {
  display: grid;
  grid-template-columns: 1fr 40px;
  gap: 10px;
  align-items: center;
}
.analytics-bar-track {
  position: relative;
  height: 12px;
  background: #f1efea;
  overflow: hidden;
}
.analytics-bar-fill {
  display: block;
  height: 100%;
  min-width: 4px;
}
.analytics-bar-fill-unique {
  background: var(--accent);
}
.analytics-bar-fill-visits {
  background: var(--tag-korea);
}
.analytics-bar-fill-views {
  background: var(--tag-apr);
}
.analytics-bar-value {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  color: var(--ink);
  text-align: right;
}
.analytics-table-scroll {
  overflow-x: auto;
}
.analytics-table {
  width: 100%;
  border-collapse: collapse;
}
.analytics-table th,
.analytics-table td {
  padding: 11px 12px;
  border-top: 1px solid var(--border);
  text-align: left;
  vertical-align: top;
}
.analytics-table th {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  background: #faf7f1;
}
.analytics-table td {
  font-size: 13px;
  color: var(--ink);
}
.analytics-inline-tag {
  display: inline-block;
  margin-right: 8px;
  padding: 2px 6px;
  font-family: 'DM Mono', monospace;
  font-size: 9px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--white);
}
.analytics-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border: 1px solid var(--border);
  background: var(--bg);
}
.analytics-item strong {
  display: block;
  font-size: 13px;
  color: var(--ink);
}
.analytics-item span {
  display: block;
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  color: var(--muted);
  letter-spacing: 0.05em;
}
@media (max-width: 700px) { .dash-actions { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 700px) {
  .analytics-stats-row {
    grid-template-columns: repeat(2, 1fr);
  }
  .dashboard-2col {
    grid-template-columns: 1fr;
  }
  .analytics-bar-row {
    grid-template-columns: 1fr;
    gap: 6px;
  }
  .analytics-toolbar {
    align-items: stretch;
  }
  .analytics-toolbar-group {
    flex-wrap: wrap;
  }
  .tag-admin-toolbar {
    grid-template-columns: 1fr;
  }
  .tag-admin-grid {
    grid-template-columns: 1fr;
  }
  .share-meta-grid {
    grid-template-columns: 1fr;
  }
}
.dash-action-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 20px 12px;
  background: var(--bg);
  border: 1px solid var(--border);
  cursor: pointer;
  text-decoration: none;
  color: var(--ink);
  transition: border-color .15s, box-shadow .15s;
}
.dash-action-btn:hover {
  border-color: #622599;
  box-shadow: 0 2px 8px rgba(98,37,153,0.12);
}
.dash-action-icon { font-size: 22px; }
.dash-action-label { font-family: 'DM Mono', monospace; font-size: 11px; letter-spacing: .08em; color: var(--muted); }

/* ── Drag-and-drop ────────────────────────────────────────── */
.drag-handle {
  flex-shrink: 0;
  padding: 0 10px;
  cursor: grab;
  color: var(--muted);
  font-size: 14px;
  line-height: 1;
  user-select: none;
}
.drag-handle:active { cursor: grabbing; }
.article-item.drag-over {
  border-color: #622599 !important;
  box-shadow: 0 0 0 2px rgba(98,37,153,0.2);
}

.admin-header {
  background:      var(--black);
  color:           var(--white);
  padding:         16px 40px;
  display:         flex;
  align-items:     center;
  justify-content: space-between;
  position:        sticky;
  top:             0;
  z-index:         100;
}

.admin-header .logo {
  font-family: 'AliceDigitalLearning', 'Playfair Display', serif;
  font-size:   18px;
  font-weight: 700;
}

.admin-header .badge {
  font-family:    'DM Mono', monospace;
  font-size:      10px;
  letter-spacing: 0.15em;
  background:     var(--accent);
  padding:        3px 10px;
  margin-left:    12px;
  text-transform: uppercase;
}

.admin-header .header-right {
  display:     flex;
  align-items: center;
  gap:         20px;
}

.admin-header a {
  font-family:    'DM Mono', monospace;
  font-size:      11px;
  letter-spacing: 0.1em;
  color:          rgba(245,243,238,0.6);
  text-decoration: none;
  text-transform:  uppercase;
  transition:     color 0.15s;
}

.admin-header a:hover { color: var(--white); }

.logout-btn {
  font-family:    'DM Mono', monospace;
  font-size:      11px;
  letter-spacing: 0.1em;
  color:          var(--accent);
  background:     none;
  border:         1px solid var(--accent);
  padding:        5px 14px;
  cursor:         pointer;
  text-transform: uppercase;
  transition:     all 0.15s;
}

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

.admin-body {
  max-width:             1100px;
  margin:                0 auto;
  padding:               40px;
  display:               grid;
  grid-template-columns: 1fr 380px;
  gap:                   32px;
  align-items:           start;
}

/* Panel */
.panel { background: var(--bg); border: 1px solid var(--border); }

.panel-header {
  padding:         20px 28px;
  border-bottom:   2px solid var(--black);
  display:         flex;
  align-items:     center;
  justify-content: space-between;
}

.panel-header h2 {
  font-family: 'AliceDigitalLearning', 'Playfair Display', serif;
  font-size:   18px;
  font-weight: 700;
}

.panel-header .count {
  font-family:    'DM Mono', monospace;
  font-size:      11px;
  color:          var(--muted);
  letter-spacing: 0.08em;
}

.panel-body { padding: 28px; }

/* Form elements */
.form-group { margin-bottom: 20px; }

.form-group label {
  display:        block;
  font-family:    'DM Mono', monospace;
  font-size:      10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color:          var(--muted);
  margin-bottom:  8px;
}

.form-group input,
.form-group select,
.form-group textarea {
  width:       100%;
  padding:     11px 14px;
  border:      1px solid var(--border);
  background:  var(--white);
  font-family: 'AliceDigitalLearning', 'Noto Sans KR', sans-serif;
  font-size:   14px;
  font-weight: 300;
  color:       var(--ink);
  outline:     none;
  transition:  border 0.15s;
  resize:      none;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus { border-color: var(--black); }

.form-group textarea { min-height: 200px; line-height: 1.7; }

.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }

.submit-btn {
  width:          100%;
  padding:        14px;
  background:     var(--black);
  color:          var(--white);
  border:         none;
  font-family:    'DM Mono', monospace;
  font-size:      11px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  cursor:         pointer;
  transition:     background 0.15s;
  margin-top:     4px;
}

.submit-btn:hover    { background: var(--accent); }
.submit-btn.editing  { background: var(--tag-apr); }

.editor-action-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 20px;
}

.editor-action-row .submit-btn,
.editor-action-row .cancel-btn,
.editor-action-row .btn-delete-soft {
  width: auto;
  margin-top: 0;
  flex: 1 1 160px;
}

.cancel-btn {
  width:          100%;
  padding:        10px;
  background:     none;
  color:          var(--muted);
  border:         1px solid var(--border);
  font-family:    'DM Mono', monospace;
  font-size:      11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor:         pointer;
  margin-top:     8px;
  display:        none;
  transition:     all 0.15s;
}

.cancel-btn:hover    { border-color: var(--ink); color: var(--ink); }
.cancel-btn.visible  { display: block; }

.btn-delete-soft {
  display: none;
  padding: 10px 14px;
  background: none;
  color: var(--danger);
  border: 1px solid rgba(204, 68, 68, 0.45);
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
  transition: all 0.15s;
}

.btn-delete-soft:hover {
  background: var(--danger);
  color: var(--white);
  border-color: var(--danger);
}

.btn-delete-soft.visible {
  display: block;
}

/* Category preview tag */
.cat-preview {
  display:        inline-block;
  font-family:    'DM Mono', monospace;
  font-size:      10px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  padding:        3px 8px;
  color:          var(--white);
  margin-top:     6px;
}

/* Stats row */
.stats-row {
  display:               grid;
  grid-template-columns: repeat(3, 1fr);
  gap:                   0;
  border-bottom:         1px solid var(--border);
}

.stat-item {
  padding:      16px 28px;
  border-right: 1px solid var(--border);
  text-align:   center;
}

.stat-item:last-child { border-right: none; }

.stat-item .stat-num {
  font-family:  'AliceDigitalLearning', 'Playfair Display', serif;
  font-size:    28px;
  font-weight:  700;
  color:        var(--black);
  display:      block;
}

.stat-item .stat-label {
  font-family:    'DM Mono', monospace;
  font-size:      10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color:          var(--muted);
}

/* Admin article list */
.article-list { display: flex; flex-direction: column; }

.article-item {
  padding:     18px 28px;
  border-bottom: 1px solid var(--border);
  display:     flex;
  align-items: flex-start;
  gap:         16px;
  transition:  background 0.15s;
}

.article-item:last-child { border-bottom: none; }
.article-item:hover      { background: rgba(0,0,0,0.02); }

.article-item-content { flex: 1; min-width: 0; }

.article-item h4 {
  font-family:    'AliceDigitalLearning', 'Noto Serif KR', serif;
  font-size:      14px;
  font-weight:    600;
  line-height:    1.4;
  margin-bottom:  6px;
  color:          var(--black);
  white-space:    nowrap;
  overflow:       hidden;
  text-overflow:  ellipsis;
}

.article-item .item-meta {
  font-family:    'DM Mono', monospace;
  font-size:      10px;
  color:          var(--muted);
  letter-spacing: 0.05em;
}

.article-item .item-actions {
  display:    flex;
  gap:        8px;
  flex-wrap:  wrap;
  justify-content: flex-end;
  flex-shrink: 0;
  padding-top: 2px;
}

.btn-edit, .btn-delete {
  font-family:    'DM Mono', monospace;
  font-size:      10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding:        4px 10px;
  border:         1px solid;
  cursor:         pointer;
  background:     none;
  transition:     all 0.15s;
}

.btn-edit  { border-color: var(--ink);    color: var(--ink); }
.btn-edit:hover  { background: var(--ink);    color: var(--white); }

.btn-delete { border-color: var(--danger); color: var(--danger); }
.btn-delete:hover { background: var(--danger); color: var(--white); }

.btn-icon {
  min-width: 36px;
  height: 30px;
  padding: 0 10px;
  border: 1px solid var(--border);
  background: var(--white);
  cursor: pointer;
  font-size: 14px;
  line-height: 1;
  transition: transform 0.12s, border-color 0.15s, background 0.15s;
}

.btn-icon:hover { transform: translateY(-1px); }

.btn-icon-success { color: #248737; border-color: rgba(36, 135, 55, 0.3); }
.btn-icon-danger { color: var(--danger); border-color: rgba(204, 68, 68, 0.3); }
.btn-icon-star { color: var(--muted); }
.btn-icon-star.active {
  color: #c18a00;
  border-color: rgba(193, 138, 0, 0.35);
  background: #fff8de;
}

.list-empty {
  padding:     40px 28px;
  text-align:  center;
  color:       var(--muted);
  font-family: 'AliceDigitalLearning', 'Noto Serif KR', serif;
  font-size:   13px;
  line-height: 1.7;
}

/* ════════════════════════════════════════════════════════════
   BOARD WRITE FEATURE
   ════════════════════════════════════════════════════════════ */

/* Write button in board banner */
.write-btn {
  display:        inline-flex;
  align-items:    center;
  gap:            6px;
  margin-top:     20px;
  font-family:    'DM Mono', monospace;
  font-size:      11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding:        10px 22px;
  background:     var(--accent);
  color:          #ffffff;
  border:         none;
  cursor:         pointer;
  transition:     background 0.15s, transform 0.1s;
  box-shadow:     0 2px 8px rgba(77,0,110,0.25);
}
.write-btn:hover  { background: #622599; }
.write-btn:active { transform: translateY(1px); }

/* Password modal */
.board-pw-overlay {
  position:        fixed;
  inset:           0;
  background:      rgba(10,10,10,0.7);
  z-index:         600;
  display:         flex;
  align-items:     center;
  justify-content: center;
  padding:         24px;
  opacity:         0;
  pointer-events:  none;
  transition:      opacity 0.2s;
}
.board-pw-overlay.open { opacity: 1; pointer-events: all; }

.board-pw-box {
  background: var(--bg);
  width:      100%;
  max-width:  360px;
  padding:    40px;
}

.board-pw-header {
  font-family:   'AliceDigitalLearning', 'Playfair Display', serif;
  font-size:     22px;
  font-weight:   700;
  margin-bottom: 8px;
  color:         var(--black);
}

.board-pw-desc {
  font-family:   'AliceDigitalLearning', 'Noto Serif KR', serif;
  font-size:     13px;
  color:         var(--muted);
  margin-bottom: 20px;
  line-height:   1.6;
}

.board-pw-box input[type="password"] {
  width:         100%;
  padding:       12px 14px;
  border:        1px solid var(--border);
  background:    var(--white);
  font-family:   'DM Mono', monospace;
  font-size:     14px;
  color:         var(--ink);
  outline:       none;
  transition:    border 0.15s;
}
.board-pw-box input[type="password"]:focus { border-color: var(--black); }

.board-pw-error {
  font-family:  'DM Mono', monospace;
  font-size:    11px;
  color:        var(--danger);
  margin-top:   10px;
  display:      none;
}

.board-pw-actions {
  display:    flex;
  gap:        8px;
  margin-top: 20px;
}
.board-pw-actions button {
  flex:           1;
  padding:        12px;
  font-family:    'DM Mono', monospace;
  font-size:      11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  border:         none;
  cursor:         pointer;
  transition:     all 0.15s;
}
.board-pw-actions button:first-child { background: var(--black); color: var(--white); }
.board-pw-actions button:first-child:hover { background: var(--accent); }
.board-pw-actions button:last-child { background: none; border: 1px solid var(--border); color: var(--muted); }
.board-pw-actions button:last-child:hover { border-color: var(--ink); color: var(--ink); }

/* Write form modal */
.board-write-overlay {
  position:        fixed;
  inset:           0;
  background:      rgba(10,10,10,0.7);
  z-index:         600;
  display:         flex;
  align-items:     center;
  justify-content: center;
  padding:         24px;
  opacity:         0;
  pointer-events:  none;
  transition:      opacity 0.2s;
}
.board-write-overlay.open { opacity: 1; pointer-events: all; }

.board-write-box {
  background:  var(--bg);
  width:       100%;
  max-width:   600px;
  max-height:  90vh;
  overflow-y:  auto;
  padding:     40px;
  position:    relative;
  transform:   translateY(20px);
  transition:  transform 0.25s ease;
}
.board-write-overlay.open .board-write-box { transform: translateY(0); }

.board-write-close {
  position:    absolute;
  top:         16px;
  right:       16px;
  background:  none;
  border:      none;
  font-size:   24px;
  cursor:      pointer;
  color:       var(--muted);
  line-height: 1;
  padding:     4px 8px;
  font-family: 'DM Mono', monospace;
  transition:  color 0.15s;
}
.board-write-close:hover { color: var(--black); }

.board-write-header {
  font-family:   'AliceDigitalLearning', 'Playfair Display', serif;
  font-size:     22px;
  font-weight:   700;
  margin-bottom: 10px;
  color:         var(--black);
}

.board-write-cat {
  display:        inline-block;
  font-family:    'DM Mono', monospace;
  font-size:      9px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  padding:        3px 8px;
  color:          var(--white);
  margin-bottom:  24px;
}

/* ════════════════════════════════════════════════════════════
   ANIMATIONS
   ════════════════════════════════════════════════════════════ */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ════════════════════════════════════════════════════════════
   RESPONSIVE
   ════════════════════════════════════════════════════════════ */
@media (max-width: 900px) {
  .masthead-top       { padding: 16px 24px; }
  .masthead-logo h1   { font-size: 26px; }
  .masthead-date      { min-width: 120px; font-size: 11px; }
  .masthead-right     { min-width: 120px; }
  .nav                { padding: 0 24px; }
  .nav a              { padding: 10px 14px; }

  .hero               { grid-template-columns: 1fr; }
  .hero-main          { padding: 32px 24px; border-right: none; }
  .hero-side          { display: none; }

  .content-wrapper    { grid-template-columns: 1fr; }
  .sidebar            { border-top: 2px solid var(--black); }

  .article-card       { padding: 24px; }
  .section-header     { padding: 24px 24px 16px; }
  .filter-bar         { padding: 16px 24px; }

  .board-banner       { padding: 28px 24px; flex-direction: column; align-items: flex-start; }
  .board-banner-count { display: none; }
  .board-container    { padding: 0 24px 40px; }
  .board-grid         { grid-template-columns: repeat(2, 1fr); }

  .modal-overlay      { padding: 0; }
  .modal              { max-height: 100vh; border-radius: 0; }
  .modal-header       { padding: 28px 24px 0; }
  .modal-body         { padding: 24px 24px 32px; }

  .footer-inner       { padding: 32px 24px 24px; gap: 16px; }
  .footer-bottom      { padding: 16px 0; flex-direction: column; gap: 8px; text-align: center; }

  .admin-body         { grid-template-columns: 1fr; padding: 24px; }
  .form-row           { grid-template-columns: 1fr; }
  .stats-row          { grid-template-columns: repeat(3, 1fr); }
  .editor-action-row  { flex-direction: column; }

  .home-wrapper       { padding: 0 24px 40px; }
  .home-2col          { grid-template-columns: 1fr; gap: 0; }
  .home-3col          { grid-template-columns: 1fr; gap: 0; }

  .post-page-wrap     { padding: 32px 24px 60px; }
  .post-page-layout   { grid-template-columns: 1fr; gap: 32px; }
  .post-page-sidebar  { position: static; }
}

@media (max-width: 480px) {
  /* ── Masthead: stack into two rows ── */
  .masthead-top {
    padding:     10px 16px;
    flex-wrap:   wrap;
    gap:         6px;
  }
  /* Hide date/time/tagline — too much for small screens */
  .masthead-date,
  .masthead-tagline   { display: none; }
  /* Logo takes full row, centered */
  .masthead-logo {
    order:    -1;
    flex:     1 0 100%;
    text-align: center;
    padding-bottom: 4px;
  }
  .masthead-logo h1   { font-size: 22px; }
  .masthead-logo .sub { font-size: 9px; letter-spacing: 0.14em; }
  .masthead-logo-img  { width: 28px; height: 28px; }
  /* Right controls shrink and align right */
  .masthead-right {
    flex:       0 0 auto;
    min-width:  0;
    flex-direction: row;
    align-items: center;
    gap: 8px;
    margin-left: auto;
  }
  .masthead-stats     { display: none; }
  /* Search expands to full width when active */
  .masthead-search:focus-within .mh-search-input,
  .mh-search-input:focus { width: 120px; }

  /* Nav */
  .nav                { padding: 0 16px; }
  .nav a              { padding: 10px 14px; font-size: 10px; }

  .board-container    { padding: 0 16px 32px; }
  .board-grid         { grid-template-columns: 1fr; }
  .admin-body         { padding: 16px; }
  .post-page-wrap     { padding: 24px 16px 48px; }

  .board-pw-box       { padding: 28px 24px; }
  .board-write-box    { padding: 28px 20px; max-height: 100vh; }
  .board-write-overlay { padding: 0; align-items: flex-end; }

  /* Hero on phone */
  .hero-main          { padding: 24px 16px; }
  .hero-main h2       { font-size: 24px; }
  .hero-main .deck    { font-size: 14px; }

  /* Board banner on phone */
  .board-banner       { padding: 20px 16px; }
  .board-banner h2    { font-size: 20px; }
  .board-banner p     { font-size: 12px; }

  /* Ticker on phone */
  .ticker             { font-size: 10px; padding: 6px 0; }

  /* site-hero on phone */
  .site-hero-title    { font-size: 22px !important; }
  .site-hero-slider   { height: 320px; }
  .site-hero          { padding: 40px 16px; min-height: 320px; }

  /* Home sections: hide Korea/APR/WORM column list on mobile */
  .home-3col          { display: none; }
}

/* ════════════════════════════════════════════════════════════
   TAG FILTER BAR
   ════════════════════════════════════════════════════════════ */
.tag-filter-bar {
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  overflow-x: clip;
}

.tag-filter-bar-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 10px 48px;
  width: min(100%, 1366px);
  box-sizing: border-box;
  margin: 0 auto;
}

.tag-filter-btn {
  font-family:    'DM Mono', monospace;
  font-size:      10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding:        5px 14px;
  border:         1px solid var(--border);
  background:     transparent;
  color:          var(--muted);
  cursor:         pointer;
  white-space:    nowrap;
  transition:     background 0.12s, color 0.12s, border-color 0.12s;
}
.tag-filter-btn.active,
.tag-filter-btn:hover {
  background:   var(--black);
  color:        var(--white);
  border-color: var(--black);
}

@media (max-width: 900px) { .tag-filter-bar-inner { padding: 10px 24px; } }
@media (max-width: 480px) { .tag-filter-bar-inner { padding: 8px 16px; gap: 6px; } }

/* ════════════════════════════════════════════════════════════
   EDITOR.JS OVERRIDES
   ════════════════════════════════════════════════════════════ */
.board-editorjs-wrap {
  border:      1px solid var(--border);
  min-height:  260px;
  background:  var(--white);
  position:    relative;
}

/* Editor.js toolbar */
.ce-toolbar__plus,
.ce-toolbar__settings-btn {
  color: var(--ink) !important;
}
.ce-toolbar__plus:hover,
.ce-toolbar__settings-btn:hover {
  background: var(--accent) !important;
  color:       #fff !important;
}

/* Editor.js popovers — must appear above the scrollable write box */
.ce-popover,
.ce-inline-toolbar,
.ce-conversion-toolbar,
.ce-toolbar__actions {
  z-index: 10 !important;
}

/* Editor.js block content */
.board-editorjs-wrap .codex-editor__redactor,
.admin-editorjs .codex-editor__redactor {
  padding-left:   60px !important;
  padding-bottom: 40px !important;
}
.board-editorjs-wrap .ce-toolbar__plus,
.admin-editorjs .ce-toolbar__plus { left: 0 !important; }
.ce-block__content {
  max-width: none !important;
  margin:    0 !important;
}
.ce-paragraph {
  font-family: 'AliceDigitalLearning', 'Noto Sans KR', sans-serif !important;
  font-size:   14px !important;
  line-height: 1.8 !important;
  color:       var(--ink) !important;
}
.ce-header {
  font-family: 'AliceDigitalLearning', 'Playfair Display', serif !important;
  color:       var(--black) !important;
}
.cdx-quote__text,
.cdx-list__item {
  font-family: 'AliceDigitalLearning', 'Noto Sans KR', sans-serif !important;
  font-size:   14px !important;
}
.cdx-quote {
  border-left: 3px solid var(--accent) !important;
}

/* Inline image tool */
.editorjs-image-tool { padding: 8px 0; }
.editorjs-image-btn {
  padding:        10px 20px;
  background:     var(--black);
  color:          var(--white);
  border:         none;
  font-family:    'DM Mono', monospace;
  font-size:      11px;
  letter-spacing: 0.1em;
  cursor:         pointer;
  transition:     background 0.15s;
}
.editorjs-image-btn:hover { background: var(--accent); }
.editorjs-image-caption {
  width:       100%;
  padding:     6px 10px;
  border:      1px solid var(--border);
  font-family: 'DM Mono', monospace;
  font-size:   11px;
  color:       var(--muted);
  margin-top:  6px;
  outline:     none;
}

/* Write modal — full-screen sized */
.board-write-box {
  background:  var(--bg);
  width:       100%;
  max-width:   860px;
  max-height:  95vh;
  overflow-y:  auto;
  padding:     40px;
  position:    relative;
  transform:   translateY(20px);
  transition:  transform 0.25s ease;
}
.board-write-overlay.open .board-write-box { transform: translateY(0); }

/* ════════════════════════════════════════════════════════════
   INDIVIDUAL POST PAGE  (/post/:id)
   ════════════════════════════════════════════════════════════ */
.post-page-wrap {
  max-width: 1366px;
  margin:    0 auto;
  padding:   40px 48px 80px;
}

.post-page-layout {
  display:               grid;
  grid-template-columns: 1fr 280px;
  gap:                   48px;
  align-items:           start;
}

.post-page-main  { min-width: 0; }

.post-page-sidebar {
  position: sticky;
  top:      100px;
}

/* Sidebar sections */
.pps-section {
  padding:       20px 0;
  border-bottom: 1px solid var(--border);
}
.pps-section:first-child { padding-top: 0; }
.pps-section:last-child  { border-bottom: none; }

.pps-label {
  font-family:    'DM Mono', monospace;
  font-size:      10px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color:          var(--muted);
  margin-bottom:  12px;
}

.pps-category {
  display:        inline-block;
  color:          #fff;
  font-family:    'DM Mono', monospace;
  font-size:      11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding:        5px 14px;
  text-decoration: none;
  transition:     opacity 0.15s;
}
.pps-category:hover { opacity: 0.85; }

.pps-row {
  display:       flex;
  gap:           8px;
  font-family:   'DM Mono', monospace;
  font-size:     11px;
  margin-bottom: 8px;
  align-items:   baseline;
}
.pps-key {
  color:      var(--muted);
  min-width:  52px;
  flex-shrink: 0;
}
.pps-val { color: var(--ink); }

.post-page-inner { position: relative; }

.post-page-back { margin-bottom: 28px; }
.post-page-back-link {
  font-family:    'DM Mono', monospace;
  font-size:      11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color:          var(--muted);
  text-decoration: none;
  transition:     color 0.15s;
}
.post-page-back-link:hover { color: var(--accent); }

.post-page-title {
  font-family:   'AliceDigitalLearning', 'Playfair Display', serif;
  font-size:     clamp(22px, 3.5vw, 36px);
  font-weight:   700;
  line-height:   1.3;
  color:         var(--black);
  margin-bottom: 14px;
}
.post-page-subtitle {
  font-family:   'AliceDigitalLearning', 'Noto Serif KR', serif;
  font-size:     clamp(14px, 2vw, 18px);
  color:         var(--muted);
  line-height:   1.6;
  margin-bottom: 16px;
}
.post-page-meta {
  font-family:    'DM Mono', monospace;
  font-size:      11px;
  color:          var(--muted);
  letter-spacing: 0.05em;
  margin-bottom:  28px;
  display:        flex;
  align-items:    center;
  gap:            8px;
  flex-wrap:      wrap;
}
.post-page-cover {
  width:         100%;
  max-height:    440px;
  object-fit:    cover;
  display:       block;
  margin-bottom: 32px;
}

.post-page-video {
  margin-bottom: 32px;
}
.post-page-body {
  position: static;
  max-width: none;
  padding:   0;
  overflow:  visible;
}
.post-page-tags {
  margin-top:  32px;
  padding-top: 20px;
  border-top:  1px solid var(--border);
  display:     flex;
  flex-wrap:   wrap;
  gap:         8px;
  align-items: center;
}
.post-page-tag {
  font-family:    'DM Mono', monospace;
  font-size:      10px;
  letter-spacing: 0.08em;
  background:     var(--bg);
  color:          var(--ink);
  padding:        3px 9px;
  border:         1px solid var(--border);
}
.post-page-share {
  margin-top:  24px;
  display:     flex;
  align-items: center;
  gap:         12px;
}
.post-share-btn {
  font-family:    'DM Mono', monospace;
  font-size:      10px;
  letter-spacing: 0.08em;
  background:     none;
  border:         1px solid var(--border);
  color:          var(--muted);
  padding:        5px 12px;
  cursor:         pointer;
  transition:     border-color 0.15s, color 0.15s;
}
.post-share-btn:hover { border-color: var(--accent); color: var(--accent); }

.post-like-wrap {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.post-like-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 14px;
  border: 1px solid rgba(217, 74, 58, 0.3);
  background: #fff4f1;
  color: #c24335;
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.08em;
  cursor: pointer;
  transition: transform 0.12s, box-shadow 0.15s, background 0.15s;
}

.post-like-btn:hover:not(:disabled) {
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(194, 67, 53, 0.12);
}

.post-like-btn:disabled,
.post-like-btn.liked {
  cursor: default;
  background: #d94a3a;
  color: #fff;
  box-shadow: none;
}

.post-like-help {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  color: var(--muted);
}

@media (max-width: 900px) {
  .post-page-wrap {
    padding: 32px 24px 60px;
  }
  .post-page-layout {
    display: flex;
    flex-direction: column;
    gap: 28px;
  }
  .post-page-main {
    order: 1;
  }
  .post-page-sidebar {
    order: 2;
    position: static;
    top: auto;
    border-top: 1px solid var(--border);
    padding-top: 8px;
  }
  .post-like-wrap {
    align-items: flex-start;
  }
}

@media (max-width: 480px) {
  .post-page-wrap {
    padding: 24px 16px 48px;
  }
}

/* Post card permalink icon */
.post-permalink {
  color:          var(--muted);
  font-size:      11px;
  text-decoration: none;
  transition:     color 0.15s;
  vertical-align: middle;
}
.post-permalink:hover { color: var(--accent); }

/* ════════════════════════════════════════════════════════════
   GLOBAL SEARCH BAR
   ════════════════════════════════════════════════════════════ */
.global-search-bar {
  background:    var(--white);
  border-bottom: 1px solid var(--border);
  padding:       12px 24px;
}
.global-search-inner {
  max-width:  900px;
  margin:     0 auto;
  display:    flex;
  gap:        8px;
  align-items: center;
}
.global-search-input {
  flex:        1;
  padding:     9px 14px;
  border:      1px solid var(--border);
  font-family: 'Noto Sans KR', sans-serif;
  font-size:   14px;
  outline:     none;
  color:       var(--ink);
  transition:  border-color 0.15s;
}
.global-search-input:focus { border-color: var(--accent); }
.global-search-btn {
  padding:        9px 20px;
  background:     var(--accent);
  color:          #fff;
  border:         none;
  font-family:    'DM Mono', monospace;
  font-size:      11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor:         pointer;
  transition:     background 0.15s;
}
.global-search-btn:hover { background: var(--black); }
.global-search-close {
  padding:     8px 14px;
  background:  none;
  border:      1px solid var(--border);
  font-family: 'DM Mono', monospace;
  font-size:   11px;
  color:       var(--muted);
  cursor:      pointer;
}
.global-search-results-wrap {
  background:    var(--white);
  border-bottom: 2px solid var(--border);
  padding:       24px;
  max-width:     100%;
}
.global-search-grid {
  max-width:  900px;
  margin:     0 auto;
  display:    grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap:        16px;
}
.global-search-item {
  display:        block;
  padding:        16px;
  border:         1px solid var(--border);
  text-decoration: none;
  color:          var(--ink);
  transition:     border-color 0.15s, box-shadow 0.15s;
}
.global-search-item:hover { border-color: var(--accent); box-shadow: 0 2px 8px rgba(0,0,0,0.06); }
.global-search-item strong { display:block; font-size:14px; margin: 6px 0 4px; }
.global-search-item p { font-size:12px; color:var(--muted); margin:0 0 6px; }
.global-search-date { font-family:'DM Mono',monospace; font-size:10px; color:var(--muted); }
.global-search-empty { text-align:center; padding:40px; font-size:14px; color:var(--muted); }

/* ════════════════════════════════════════════════════════════
   BOARD SEARCH
   ════════════════════════════════════════════════════════════ */
.board-search-wrap {
  padding:       12px 0 0;
  max-width:     100%;
}
.board-search-inner {
  display:  flex;
  gap:      8px;
  position: relative;
}
.board-search-input {
  width:       100%;
  padding:     9px 36px 9px 14px;
  border:      1px solid var(--border);
  font-family: 'Noto Sans KR', sans-serif;
  font-size:   14px;
  outline:     none;
  color:       var(--ink);
  background:  var(--white);
  transition:  border-color 0.15s;
}
.board-search-input:focus { border-color: var(--accent); }
.board-search-clear {
  position:   absolute;
  right:      10px;
  top:        50%;
  transform:  translateY(-50%);
  background: none;
  border:     none;
  font-size:  14px;
  color:      var(--muted);
  cursor:     pointer;
  padding:    4px;
}
.board-search-clear:hover { color: var(--accent); }

/* ════════════════════════════════════════════════════════════
   ADMIN TABS LAYOUT
   ════════════════════════════════════════════════════════════ */
.admin-header-top {
  display:         flex;
  justify-content: space-between;
  align-items:     center;
  padding:         16px 32px;
  border-bottom:   1px solid rgba(255,255,255,0.15);
}
.admin-tabs-nav {
  display:    flex;
  padding:    0 32px;
  gap:        4px;
  background: var(--black);
}
.admin-tab-btn {
  padding:        12px 20px;
  background:     none;
  border:         none;
  color:          rgba(255,255,255,0.6);
  font-family:    'DM Mono', monospace;
  font-size:      11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor:         pointer;
  border-bottom:  3px solid transparent;
  transition:     color 0.15s, border-color 0.15s;
}
.admin-tab-btn.active,
.admin-tab-btn:hover {
  color:         #fff;
  border-bottom-color: var(--accent);
}
.admin-tab-content {
  max-width:  1100px;
  margin:     0 auto;
  padding:    32px;
}
.admin-tab-panel { display: none; }
.admin-tab-panel.active { display: block; }

/* Author tag on cards */
.post-author {
  font-family:    'DM Mono', monospace;
  font-size:      10px;
  color:          var(--muted);
  letter-spacing: 0.04em;
}
/* Post page action buttons */
.post-page-action-btns { display:inline-flex; gap:6px; flex-wrap:wrap; }

/* ── Vertical spacing utilities ── */
.post-card-body > * + * { margin-top: 6px; }
.mini-item > * + * { margin-top: 6px; }

/* ── Masthead search ── */
.masthead-search { display: flex; align-items: center; gap: 0; margin-top: 6px; }
.mh-search-input {
  width: 0; padding: 5px 0;
  border: none; border-bottom: 1px solid transparent;
  background: transparent;
  font-family: 'DM Mono', monospace; font-size: 11px;
  color: var(--ink); outline: none; overflow: hidden;
  transition: width 0.25s ease, border-color 0.25s, padding 0.25s;
}
.masthead-search:focus-within .mh-search-input,
.mh-search-input:focus { width: 160px; padding: 5px 8px; border-bottom-color: var(--ink); }
.mh-search-btn {
  padding: 5px 6px; border: none;
  background: none; cursor: pointer;
  color: var(--muted);
  display: flex; align-items: center; justify-content: center;
  transition: color 0.15s;
}
.mh-search-btn:hover { color: var(--accent); background: none; }

/* ── AI disclaimer ── */
.ai-disclaimer {
  margin-top:  28px;
  padding:     12px 16px;
  border-left: 3px solid #622599;
  background:  rgba(98, 37, 153, 0.05);
  font-family: 'DM Mono', monospace;
  font-size:   11px;
  color:       var(--muted);
  letter-spacing: 0.04em;
}

/* ── Post byline ───────────────────────────────────────────── */
.post-byline {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  margin-top: 32px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  color: var(--muted);
  letter-spacing: 0.04em;
}
.post-byline-author {
  color: var(--ink);
}
.post-byline-report a {
  color: var(--muted);
  text-decoration: underline;
}
.post-byline-report a:hover {
  color: #622599;
}

.version-history-item {
  border-top: 1px solid var(--border);
  padding: 18px 0;
}

.version-history-item:first-child {
  border-top: none;
  padding-top: 0;
}

.version-history-top {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
  margin-bottom: 8px;
}

.version-history-version {
  font-family: 'DM Mono', monospace;
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--black);
}

.version-history-date,
.version-history-type {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  color: var(--muted);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.version-history-summary {
  margin: 0 0 10px;
  font-size: 14px;
  line-height: 1.6;
  color: var(--ink);
}

.version-history-changes {
  margin: 0;
  padding-left: 18px;
  color: var(--ink);
}

.version-history-changes li {
  margin-bottom: 6px;
  line-height: 1.6;
}

.version-history-pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px;
  margin-top: 24px;
}

.version-history-pagination button {
  padding: 8px 14px;
  border: 1px solid var(--border);
  background: none;
  color: var(--ink);
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  cursor: pointer;
}

.version-history-pagination button:disabled {
  color: var(--muted);
  cursor: default;
  opacity: 0.5;
}

.version-history-pagination span {
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  color: var(--muted);
}

/* ── Contributors page ────────────────────────────────────── */
.contributors-wrap {
  max-width: 1366px;
  margin: 0 auto;
  padding: 48px 48px 80px;
}
.contributors-thank {
  max-width: 640px;
  margin-bottom: 40px;
  font-family: 'Noto Serif KR', serif;
  font-size: 16px;
  line-height: 1.8;
  color: var(--muted);
}
.contributors-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.contributor-card {
  display: flex;
  align-items: baseline;
  gap: 12px;
  padding: 16px 20px;
  border: 1px solid var(--border);
  background: var(--bg);
}
.contributor-name {
  font-family: 'Noto Serif KR', serif;
  font-size: 16px;
  font-weight: 600;
  color: var(--ink);
  flex-shrink: 0;
}
.contributor-note {
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  color: var(--muted);
  letter-spacing: 0.03em;
}
.contributor-date {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  color: var(--muted);
  letter-spacing: 0.05em;
  margin-left: auto;
  flex-shrink: 0;
}
.contributors-empty {
  font-family: 'DM Mono', monospace;
  font-size: 12px;
  color: var(--muted);
  padding: 32px 0;
}
@media (max-width: 600px) {
  .contributors-wrap { padding: 32px 20px 60px; }
  .contributor-card { flex-direction: column; gap: 4px; }
}
