/* 하루퍼즐 홈페이지 — puzzle_pop 토큰(core_ui concept.dart). 시스템 한글 글꼴, 웹폰트·외부 요청 없음. */
:root {
  --rose: #D6336C;
  --rose-ink: #B8245A;
  --rose-soft: #FBE3EB;
  --teal: #00B8A9;
  --teal-ink: #00796F;
  --teal-soft: #DDF5F2;
  --bg: #FFF5F7;
  --surface: #FFFFFF;
  --ink: #2D2A32;
  --muted: #736D7A;
  --line: #F6E2E8;
  --radius: 22px;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--surface);
  color: var(--ink);
  font: 17px/1.75 -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Noto Sans KR", system-ui, sans-serif;
  word-break: keep-all;
  overflow-wrap: anywhere;
}
a { color: var(--rose-ink); text-underline-offset: 4px; }
img { max-width: 100%; height: auto; display: block; }
.wrap { width: min(1120px, 100% - 40px); margin-inline: auto; }
.skip { position: absolute; left: -999px; }
.skip:focus { left: 16px; top: 16px; background: var(--rose); color: #fff; padding: 8px 12px; border-radius: 8px; z-index: 9; }

.header { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 16px 0; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; font-weight: 800; font-size: 20px; }
.brand img { border-radius: 10px; }
nav { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; justify-content: flex-end; }
nav a { color: var(--muted); text-decoration: none; font-size: 15px; }
nav a:hover, nav a:focus-visible { color: var(--ink); }
.nav-download { color: #fff !important; background: var(--ink); padding: 6px 16px; border-radius: 999px; font-weight: 700; }

.hero { background: var(--bg); }
.hero-inner { display: grid; grid-template-columns: 1.1fr .9fr; gap: 48px; align-items: center; padding: 56px 0 64px; }
.chip { display: inline-block; margin: 0 0 18px; padding: 4px 14px; border-radius: 999px; background: var(--teal-soft); color: var(--teal-ink); font-size: 14px; font-weight: 700; }
h1 { font-size: clamp(36px, 5.6vw, 58px); line-height: 1.22; margin: 0 0 20px; letter-spacing: -0.02em; font-weight: 900; }
h1 em { font-style: normal; color: var(--rose); }
.lead { font-size: clamp(17px, 2vw, 20px); color: var(--muted); margin: 0 0 28px; }
h2 { font-size: clamp(26px, 3.4vw, 36px); line-height: 1.3; margin: 0 0 12px; letter-spacing: -0.01em; }
h3 { font-size: 21px; margin: 18px 0 6px; }
.section-lead { color: var(--muted); margin: 0 0 32px; }

.stores { display: flex; flex-wrap: wrap; gap: 12px; }
.store { display: inline-flex; align-items: center; gap: 10px; min-height: 54px; padding: 0 22px; border-radius: 14px; background: var(--ink); color: #fff; text-decoration: none; font-weight: 700; }
.store img { filter: brightness(0) invert(1); }
.store-soon { background: var(--surface); color: var(--muted); border: 2px solid #E4DCE2; font-weight: 600; }
.store-soon img { filter: invert(47%) sepia(6%) saturate(600%) hue-rotate(240deg); }
.store-note { color: var(--muted); font-size: 14px; margin: 14px 0 0; }

.shot { margin: 0; justify-self: center; width: min(340px, 80vw); border-radius: 28px; overflow: hidden; box-shadow: 0 24px 60px rgba(45, 42, 50, .18); }
.hero-shot { transform: rotate(2deg); }

/* 오늘의 한 문제 */
.today { padding: 72px 0; text-align: center; }
.quiz { max-width: 560px; margin: 0 auto; }
.quiz-meaning { background: var(--teal-soft); border: 2px solid var(--teal); border-radius: 16px; padding: 14px 18px; font-weight: 700; font-size: 18px; margin: 0 0 24px; }
.quiz-board, .quiz-choices { display: flex; justify-content: center; flex-wrap: wrap; gap: 10px; }
.quiz-board { margin-bottom: 12px; }
.tile { width: 72px; height: 72px; border-radius: 16px; border: 2px solid var(--line); background: var(--surface); font: inherit; font-size: 30px; font-weight: 800; color: var(--ink); display: grid; place-items: center; }
.tile.blank { border-color: var(--rose); background: var(--rose-soft); color: var(--rose); }
.tile.filled { border-color: var(--rose); color: var(--rose-ink); }
.quiz-choices .tile { width: 60px; height: 60px; font-size: 25px; cursor: pointer; }
.quiz-choices .tile:hover { border-color: var(--teal); }
.quiz-choices .tile:disabled { opacity: .35; cursor: default; }
.quiz-reset { font: inherit; font-size: 15px; color: var(--muted); background: none; border: 0; cursor: pointer; margin: 0 0 14px; min-height: 44px; }
.quiz-status { min-height: 1.75em; color: var(--muted); margin: 14px 0 0; font-weight: 600; }
.quiz-status.ok { color: var(--teal-ink); }
.quiz-status.no { color: var(--rose-ink); }
.quiz-answer { margin-top: 18px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; box-shadow: 0 10px 30px rgba(45, 42, 50, .08); }
.answer-word { margin: 0; font-size: 34px; }
.answer-hanja { color: var(--muted); font-size: 22px; letter-spacing: .2em; margin-left: 8px; }
.answer-readings { color: var(--muted); margin: 8px 0 0; }
.answer-meaning { font-weight: 700; margin: 12px 0 0; }
.answer-example { color: var(--muted); font-size: 15px; margin: 6px 0 20px; }
.quiz-answer .store { margin-inline: auto; }
.shake { animation: shake .3s; }
@keyframes shake { 25% { transform: translateX(-6px); } 75% { transform: translateX(6px); } }

/* 퍼즐 소개 */
.puzzles { background: var(--bg); padding: 72px 0; }
.puzzles h2 { text-align: center; margin-bottom: 36px; }
.cards { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.card { background: var(--surface); border-radius: var(--radius); padding: 26px 24px; border: 1px solid var(--line); }
.card p { color: var(--muted); margin: 0; font-size: 15px; }
.card-icon { width: 56px; height: 56px; border-radius: 16px; display: grid; place-items: center; }
.card-icon.rose { background: var(--rose-soft); fill: var(--rose); stroke: var(--rose); }
.card-icon.teal { background: var(--teal-soft); fill: var(--teal-ink); stroke: var(--teal-ink); }

.faq { padding: 72px 0; }
.faq details { max-width: 820px; }
details { border-bottom: 1px solid var(--line); padding: 14px 0; }
summary { cursor: pointer; font-weight: 700; font-size: 18px; }
details p { color: var(--muted); margin: 10px 0 0; }

.download { text-align: center; padding: 72px 0 80px; background: var(--bg); }
.download h2 { margin-bottom: 24px; }
.download .stores { justify-content: center; }

.store:focus-visible, a:focus-visible, button:focus-visible, summary:focus-visible { outline: 3px solid var(--teal); outline-offset: 3px; }

/* footer — 로또고·다정인사 홈페이지와 같은 사업자 정보 */
.site-footer { background: var(--ink); color: #c7cad1; padding-block: 48px 40px; font-size: 14px; }
.footer-top { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; align-items: center; }
.site-footer .brand { color: #fff; font-size: 17px; }
.footer-links { display: flex; gap: 18px; flex-wrap: wrap; }
.footer-links a { color: #fff; }
.disclaimer { margin-top: 24px; color: #9aa0aa; max-width: 760px; }
.business-info { margin-top: 24px; padding-top: 20px; border-top: 1px solid rgba(255, 255, 255, .1); }
.business-name { color: #fff; font-weight: 700; text-decoration: none; }
.business-name span { font-weight: 400; color: #9aa0aa; }
.business-details { display: flex; flex-wrap: wrap; gap: 6px 22px; margin: 10px 0 0; }
.business-details div { display: flex; gap: 6px; }
.business-details dt { color: #8a909a; }
.business-details dd { margin: 0; }
.business-details a { color: #c7cad1; }
.copyright { color: #8a909a; margin: 20px 0 0; }

@media (max-width: 960px) {
  .cards { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 760px) {
  .hero-inner { grid-template-columns: 1fr; gap: 36px; padding: 28px 0 48px; }
  .cards { grid-template-columns: 1fr; }
  nav a:not(.nav-download) { display: none; }
  .tile { width: 64px; height: 64px; font-size: 27px; }
  .quiz-choices .tile { width: 54px; height: 54px; font-size: 22px; }
  .stores .store { flex: 1 1 100%; justify-content: center; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero-shot { transform: none; }
  .shake { animation: none; }
}
