:root {
  --bg: #f7f6f2;
  --surface: #ffffff;
  --text: #1d1d1b;
  --muted: #6b6a64;
  --line: #e4e2da;
  --accent: #2456d6;
  --accent-soft: #e8eefc;
  --danger: #c23a2b;
  --radius: 14px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #141413;
    --surface: #1e1e1c;
    --text: #ecebe6;
    --muted: #9c9b94;
    --line: #34332f;
    --accent: #7ea2ff;
    --accent-soft: #232c45;
    --danger: #ff7a6b;
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Pretendard", "Apple SD Gothic Neo", "Malgun Gothic", system-ui, sans-serif;
  line-height: 1.6;
  word-break: keep-all;
  overflow-wrap: anywhere;
}
a { color: var(--accent); }
.wrap { max-width: 760px; margin: 0 auto; padding: 48px 16px 64px; }

header.site { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 40px; }
header.site .logo { font-weight: 800; font-size: 20px; color: var(--text); text-decoration: none; letter-spacing: -0.02em; }
header.site nav a { color: var(--muted); text-decoration: none; margin-left: 16px; font-size: 15px; }
header.site nav a:hover { color: var(--text); }

h1 { font-size: clamp(28px, 6vw, 40px); line-height: 1.25; letter-spacing: -0.03em; margin: 0 0 12px; }
h2 { font-size: 18px; margin: 48px 0 16px; letter-spacing: -0.01em; }
.lead { color: var(--muted); font-size: 17px; margin: 0; }
.muted { color: var(--muted); }
.small { font-size: 14px; }

.cards { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
.card {
  display: block; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 18px; color: var(--text); text-decoration: none; transition: border-color .15s, transform .15s;
}
a.card:hover { border-color: var(--accent); transform: translateY(-2px); }
.card strong { display: block; font-size: 16px; margin-bottom: 4px; }
.card span { color: var(--muted); font-size: 14px; }
.tag { display: inline-block; font-size: 12px; padding: 2px 8px; border-radius: 99px; background: var(--accent-soft); color: var(--accent); margin-bottom: 8px; }

.list { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.row { display: flex; align-items: center; gap: 12px; padding: 14px 16px; border-top: 1px solid var(--line); }
.row:first-child { border-top: 0; }
.row .grow { flex: 1; min-width: 0; }
.row .name { font-weight: 600; }
.row .meta { color: var(--muted); font-size: 13px; }

button, .btn {
  font: inherit; font-size: 15px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface);
  color: var(--text); padding: 8px 14px; cursor: pointer; text-decoration: none; display: inline-flex; align-items: center; gap: 6px; white-space: nowrap;
}
button:hover, .btn:hover { border-color: var(--accent); }
.primary { background: var(--accent); border-color: var(--accent); color: #fff; }
@media (prefers-color-scheme: dark) { .primary { color: #10131c; } }
.danger { color: var(--danger); }
button:disabled { opacity: .5; cursor: default; }

input, textarea {
  font: inherit; width: 100%; padding: 10px 12px; border-radius: 10px; border: 1px solid var(--line);
  background: var(--surface); color: var(--text);
}
textarea { min-height: 80px; resize: vertical; }
label { display: block; font-size: 14px; color: var(--muted); margin: 12px 0 4px; }

.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }
.notice { padding: 12px 16px; border-radius: 10px; background: var(--accent-soft); color: var(--text); }
.error { color: var(--danger); }
.hidden { display: none !important; }

footer.site { margin-top: 64px; color: var(--muted); font-size: 13px; }

/* QR 크게 보기 (발표 화면용) */
.qr-screen {
  position: fixed; inset: 0; background: #fff; color: #111; z-index: 10;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 24px; padding: 16px; text-align: center;
}
.qr-screen .qr-box img, .qr-screen .qr-box canvas { width: min(70vh, 80vw) !important; height: auto !important; image-rendering: pixelated; }
.qr-screen .qr-url { font-size: clamp(24px, 5vw, 48px); font-weight: 800; letter-spacing: -0.02em; }
.qr-screen .qr-title { font-size: clamp(16px, 3vw, 24px); color: #555; }
.qr-screen button { position: absolute; top: 16px; right: 16px; background: #fff; color: #111; border-color: #ccc; }
