/* Logic Club: shared visual system for the public site and control room. */
:root {
  --bg: #f7f6f0;
  --surface: #fffefa;
  --text: #202d29;
  --muted: #68736a;
  --line: #dddfd4;
  --brand: #245c46;
  --brand-dark: #184331;
  --brand-soft: #eaf0e6;
  --accent: #b95731;
  --ink: #17392d;
  --ink-2: #27503d;
  --radius: 18px;
  --radius-sm: 10px;
  --shadow-sm: 0 2px 4px rgba(28, 46, 32, .03);
  --shadow: 0 8px 24px rgba(28, 46, 32, .035);
  --shadow-lg: 0 18px 40px rgba(28, 46, 32, .1);
  --max: 1180px;
}

body { line-height: 1.75; font-size: 15px; }
body, button, input, select, textarea { font-family: "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif; }
body { background-image: radial-gradient(#53684e10 .65px, transparent .65px); background-size: 7px 7px; }
::selection { color: var(--text); background: #e4e7c8; }
[hidden] { display: none !important; }
button, input, select, textarea { -webkit-tap-highlight-color: transparent; }
button { touch-action: manipulation; }
:focus-visible { outline: 3px solid #c47c47; outline-offset: 4px; }
a { text-underline-offset: 4px; }
hr { border: 0; border-top: 1px solid var(--line); margin: 30px 0; }
.container { padding-left: 28px; padding-right: 28px; }
.kicker { color: var(--brand); font-size: 11px; letter-spacing: .16em; margin-bottom: 12px; }
.text-link { font-size: 14px; font-weight: 600; white-space: nowrap; }
.skip-link { position: absolute; left: 20px; top: -100px; background: var(--brand); color: white; padding: 10px 18px; border-radius: 8px; z-index: 100; }
.skip-link:focus { top: 12px; }
.page-loading { min-height: 55vh; display: grid; place-content: center; justify-items: center; gap: 12px; color: var(--muted); }
.page-loading::before { content: ""; height: 22px; width: 22px; border: 2px solid var(--line); border-top-color: var(--brand); border-radius: 50%; animation: turn 1s linear infinite; }
@keyframes turn { to { transform: rotate(360deg); } }

/* Navigation */
.site-header { background: rgba(247,246,240,.95); border-color: var(--line); backdrop-filter: blur(16px); }
.site-header .container { height: 82px; gap: 24px; }
.brand { gap: 12px; font-size: 18px; letter-spacing: .05em; }
.brand-logo { width: 40px; height: 40px; border-radius: 12px; background: var(--brand); box-shadow: none; font-size: 20px; }
.brand-logo img { border-radius: 12px; }
.brand-name { line-height: 1.3; }
.brand-name small { display: block; font-size: 9px; color: var(--muted); font-weight: 600; letter-spacing: .16em; margin-top: 4px; }
.nav { gap: 6px; }
.nav a { padding: 8px 12px; font-size: 13px; border-radius: 7px; }
.nav a.active { color: var(--brand); background: var(--brand-soft); }
.nav a:last-child { margin-left: 8px; border: 1px solid var(--brand); color: var(--brand); }
.nav a:hover { color: var(--brand); }
.nav-toggle { min-height: 42px; color: var(--brand); font: inherit; font-size: 13px; font-weight: 600; padding: 8px 12px; }
.nav-toggle span { margin-left: 6px; }
.admin-header-nav a { border: 1px solid #cdd3c6; border-radius: 8px; padding: 10px 12px; font-size: 12px; white-space: nowrap; }

/* A notebook instead of a stock hero image */
.hero { color: var(--text); background: transparent; border-bottom: 1px solid var(--line); }
.hero::after { display: none; }
.hero-grid { grid-template-columns: 1.2fr .8fr; gap: 70px; padding-top: 74px; padding-bottom: 72px; }
.hero-kicker { display: inline-flex; align-items: center; gap: 9px; color: var(--brand); font-size: 11px; letter-spacing: .12em; margin-bottom: 24px; }
.status-dot { height: 7px; width: 7px; border-radius: 50%; background: var(--brand); display: inline-block; flex: none; }
.hero-copy h1 { font-family: "Noto Serif SC", "Songti SC", "STSong", "SimSun", serif; font-size: clamp(36px,4.4vw,58px); line-height: 1.35; font-weight: 700; letter-spacing: -.035em; margin-bottom: 22px; }
.hero-copy h1 span { color: var(--brand); }
.hero-copy p { color: var(--muted); max-width: 510px; font-size: 15px; line-height: 1.95; margin-bottom: 27px; }
.hero-cta { gap: 10px; margin-bottom: 40px; }
.hero-cta .btn { min-width: 142px; }
.hero-stats { gap: 30px; }
.hero-stats > div { padding-right: 28px; border-right: 1px solid var(--line); }
.hero-stats > div:last-child { border: 0; padding: 0; }
.hero-stats strong { color: var(--brand); font-size: 24px; font-weight: 600; }
.hero-stats span { color: var(--muted); font-size: 11px; }
.hero-notebook { background: #eeeee1; border: 1px solid #d6dac9; border-radius: 4px 28px 28px 4px; position: relative; padding: 22px 26px 24px 34px; box-shadow: 7px 8px 0 #e3e6d9; transform: rotate(2deg); }
.hero-notebook::before { content: ""; position: absolute; left: 13px; top: 0; bottom: 0; border-left: 1px solid #cfd4bf; }
.notebook-top { display: flex; justify-content: space-between; font-size: 10px; font-weight: 600; color: var(--brand); letter-spacing: .13em; }
.notebook-top > span:last-child { font-size: 21px; line-height: 1; }
.logic-symbol { height: 192px; margin: 20px 0; position: relative; display: flex; align-items: center; justify-content: center; isolation: isolate; }
.logic-symbol span, .logic-symbol b { width: 150px; height: 150px; border-radius: 50%; display: grid; place-items: center; font-family: Georgia, serif; font-size: 92px; font-weight: 400; border: 1px solid var(--brand); color: var(--brand); }
.logic-symbol span { transform: translateX(22px) rotate(-8deg); background: #e2e8d6; }
.logic-symbol b { transform: translateX(-22px) rotate(8deg); border-color: var(--accent); background: #e9c39f85; color: var(--accent); mix-blend-mode: multiply; }
.logic-symbol i { width: 160px; height: 1px; background: var(--brand); position: absolute; transform: rotate(-40deg); z-index: -1; }
.notebook-note { padding: 12px 0 22px; font-family: "Songti SC", "SimSun", serif; font-size: 20px; line-height: 1.65; color: var(--brand); }
.notebook-bottom { display: flex; justify-content: space-between; border-top: 1px solid #ccd3bd; padding-top: 14px; font-size: 11px; color: #4b614e; }
.quick-paths { border-bottom: 1px solid var(--line); background: #f0f1e8; }
.path-grid { display: grid; grid-template-columns: repeat(3,1fr); }
.path-item { display: flex; align-items: center; gap: 18px; padding: 27px 24px; color: var(--text); border-right: 1px solid var(--line); transition: background .18s; }
.path-item:first-child { padding-left: 0; }
.path-item:last-child { padding-right: 0; border: 0; }
.path-item:hover { background: #e9edde; text-decoration: none; }
.path-number { font: italic 24px Georgia,serif; color: var(--accent); }
.path-item strong { font-size: 16px; font-weight: 600; display: block; }
.path-item div > span { font-size: 11px; color: var(--muted); }
.path-arrow { margin-left: auto; font-size: 20px; color: var(--brand); }

/* Reading and cards */
.section { padding: 58px 0; }
.section + .section { padding-top: 18px; }
.section-head { margin-bottom: 28px; }
.section-head h2 { font-size: 28px; font-weight: 650; line-height: 1.45; margin-bottom: 8px; letter-spacing: -.025em; }
.section-head h2::before { width: 7px; height: 7px; background: var(--accent); border-radius: 50%; }
.section-head h1 { font-family: "Songti SC", "SimSun", serif; color: var(--brand); font-size: 38px; line-height: 1.45; margin: 0 0 10px; }
body:not([data-page=home]):not([data-page=admin]) #page > .section:first-child > .container > .section-head { padding-bottom: 30px; border-bottom: 1px solid var(--line); margin-bottom: 32px; }
body:not([data-page=home]):not([data-page=admin]) #page > .section:first-child .section-head h2 { font-family: "Songti SC", "SimSun", serif; font-size: 38px; color: var(--brand); }
body:not([data-page=home]) .section-head h2::before { display: none; }
.grid { gap: 22px; }
.grid > * { min-width: 0; }
.card { padding: 28px; border-radius: var(--radius); box-shadow: none; }
.card h3 { font-size: 19px; }
.card p { line-height: 1.85; }
.card, .row-card, .daily-stat { overflow-wrap: anywhere; }
.puzzle { position: relative; border-top: 3px solid #91a27b; }
.puzzle-head { margin-bottom: 14px; align-items: flex-start; }
.puzzle-head h3 { font-size: 21px; line-height: 1.4; font-family: "Songti SC", "SimSun", serif; }
.badge { font-size: 11px; border-radius: 6px; padding: 3px 9px; }
.badge.easy { background: #eaf0e4; color: #375c34; }
.badge.mid { background: #f5e8cd; color: #83501b; }
.badge.hard { background: #f7e3de; color: #a14037; }
.tags { margin-bottom: 8px; gap: 8px; }
.tags span { background: transparent; padding: 0; color: var(--muted); font-size: 11px; }
.puzzle-author { font-size: 11px; margin-bottom: 14px; }
.puzzle .surface { background: #f2f3eb; border-left: 2px solid #9cab8a; padding: 18px; border-radius: 0 8px 8px 0; margin-bottom: 20px; }
.puzzle-toolbar { justify-content: space-between; padding: 16px; background: #eeefe6; border-radius: 12px; margin-bottom: 24px; }
.puzzle-search { max-width: 400px; flex-grow: 1; }
.chips { gap: 6px; }
.chip { font-size: 12px; padding: 8px 14px; min-height: 40px; }
.answer, .hints, .qa, .daily-mark, .ai-host { border-top-style: solid; }
.answer-label { border-radius: 5px; }
.qa-item, .subs-text, .ai-progress { background: #f1f2eb; }
.poster-grid { gap: 24px; }
.poster-card { border-radius: 14px; box-shadow: none; background: #e9ece2; }
.poster-card img { height: 350px; object-fit: contain; padding: 12px; }
.poster-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.poster-cap { background: #1c3d30ed; padding: 10px 16px; }
.president-card { box-shadow: none; border-radius: 20px; padding: 36px; background: #eeefe5; }
.president-avatar { background: #e2e9d9; border-radius: 12px; }
.president-body blockquote { font-family: "Songti SC", "SimSun", serif; font-size: 22px; border-left-color: var(--accent); }
.news-item { padding: 25px 0; gap: 38px; }
.news-date { font-size: 12px; color: var(--accent); flex-basis: 88px; }
.news-item h3 { font-size: 19px; font-weight: 600; }
.news-item h3 a { color: var(--text); }
.news-item h3 a:hover { color: var(--brand); }
.news-item p { font-size: 13px; }
.article { background: var(--surface); padding: 40px; border-radius: 18px; border: 1px solid var(--line); margin: 0 auto; }
.article h1 { font-family: "Songti SC", "SimSun", serif; line-height: 1.4; }
.article .body { line-height: 2; }
.empty { padding: 30px 20px; background: #f1f2ea; border: 1px dashed #d4d9c9; border-radius: 12px; font-size: 14px; }
.site-footer { background: #ecefe5; margin-top: 34px; padding: 38px 0; font-size: 12px; }
.site-footer .container { gap: 32px; }
.footer-brand { font-size: 20px; }
.footer-tagline { margin: 5px 0 12px; color: var(--muted); font-size: 12px; }

/* Controls and forms */
.btn { display: inline-flex; justify-content: center; align-items: center; gap: 14px; min-height: 46px; padding: 10px 20px; border-radius: 9px; font-size: 13px; font-weight: 600; }
.btn:hover { box-shadow: 0 4px 12px #245c4614; }
.btn.ghost { background: transparent; border-color: #cdd3c6; box-shadow: none; }
.btn.ghost:hover { background: var(--brand-soft); }
.btn.small { font-size: 12px; padding: 7px 12px; min-height: 38px; }
.btn.danger { color: #a1433c; background: #faece7; border-color: #eccfc6; }
.btn.danger:hover { color: #8b332b; background: #f4dcd5; }
.btn[disabled] { opacity: .6; cursor: wait; }
.field { margin-bottom: 18px; }
.field label { color: #38483b; font-size: 12px; margin-bottom: 8px; }
input, select, textarea { min-width: 0; min-height: 46px; padding: 11px 13px; font-size: 14px; background: #fffefb; border-color: #d5dacd; border-radius: 8px; }
input::placeholder, textarea::placeholder { color: #8a9287; opacity: 1; }
input:focus, select:focus, textarea:focus { box-shadow: 0 0 0 3px #dce8d6; border-color: var(--brand); }
input[type=checkbox], input[type=radio] { width: auto; min-height: 0; accent-color: var(--brand); }
.hint { font-size: 12px; line-height: 1.7; }
.notice { line-height: 1.8; font-size: 13px; border-radius: 10px; padding: 12px 15px; }
.notice.info { border-color: #d6e0cf; background: #edf2e8; color: #36523c; }
.notice.ok { border-color: #cfdfc7; background: #ecf4e7; color: #365d2e; }
.notice.err { border-color: #efcec7; background: #fcf0eb; color: #a04236; }
.notice a { font-weight: 600; }
.form { padding: 28px; background: var(--surface); border: 1px solid var(--line); border-radius: 18px; }
.join-card p { margin-bottom: 24px; }
.join-steps { padding: 0; list-style: none; margin: 24px 0 28px; display: grid; gap: 12px; font-size: 13px; }
.join-steps span { font: italic 16px Georgia,serif; color: var(--accent); margin-right: 15px; }
.submit-section { background: #f0f1e8; }
.auth-section { padding: 72px 0; }
.auth-layout { display: grid; grid-template-columns: 1fr 480px; align-items: start; gap: 88px; }
.auth-intro { padding-top: 42px; }
.auth-intro h1 { font-family: "Songti SC", "SimSun", serif; font-size: 42px; line-height: 1.5; letter-spacing: -.03em; color: var(--brand); margin: 0 0 24px; }
.auth-intro > p { max-width: 350px; font-size: 14px; color: var(--muted); margin: 0; }
.auth-note { display: flex; gap: 16px; margin-top: 48px; padding-top: 24px; border-top: 1px solid var(--line); max-width: 350px; }
.auth-note > span { font-size: 26px; color: var(--accent); }
.auth-note strong { font-size: 13px; font-weight: 600; }
.auth-note p { font-size: 12px; color: var(--muted); margin: 4px 0 0; }
.login-wrap { padding-top: 0; }
.login-card { max-width: none; padding: 36px; border-radius: 20px; box-shadow: var(--shadow); text-align: left; }
.login-card h2 { font-size: 26px; font-weight: 650; margin: 5px 0 8px; }
.login-eyebrow { color: var(--accent); font-size: 10px; letter-spacing: .13em; font-weight: 700; }
.login-sub { font-size: 13px; margin-bottom: 26px; }
.login-form { gap: 0; }
.login-form .field { margin-bottom: 18px; }
.login-form input { text-align: left; font-size: 14px; padding: 12px; }
.login-form > .btn { width: 100%; margin-top: 6px; }
.login-hint { font-size: 11px; margin: 16px 0 0; }
.password-field { position: relative; }
.password-field input { padding-right: 64px; }
.password-toggle { position: absolute; right: 4px; top: 4px; bottom: 4px; padding: 0 10px; border: 0; border-radius: 5px; background: transparent; color: var(--brand); font-size: 11px; cursor: pointer; }
.password-toggle:hover { background: var(--brand-soft); }
.optional { color: var(--muted); font-weight: 400; font-size: 11px; margin-left: 5px; }
.register-panel { margin-top: 24px; padding-top: 20px; }
.register-panel summary { display: flex; align-items: center; justify-content: space-between; list-style: none; font-size: 14px; }
.register-panel summary::-webkit-details-marker { display: none; }
.summary-plus { font-size: 20px; line-height: 1; font-weight: 400; }
.register-panel[open] .summary-plus { transform: rotate(45deg); }
.register-panel .login-form { margin-top: 22px; }
.register-panel > .hint { margin-top: 10px; }
.login-card.applying > .login-form, .login-card.applying > .login-hint,
.login-card.applying > #member-login-notice, .login-card.applying .register-panel summary { display: none; }
.login-card.applying .register-panel { border: 0; padding-top: 0; margin-top: 0; }
.login-return { display: block; margin-top: 22px; border-top: 1px solid var(--line); padding-top: 18px; font-size: 12px; }

/* Daily challenge and host */
.daily-bar { display: grid; grid-template-columns: repeat(4,1fr); gap: 14px; }
.daily-stat { padding: 22px; min-width: 0; box-shadow: none; border-radius: 14px; }
.daily-stat:first-child { background: #e5ebda; border-color: #d3ddc8; }
.daily-stat strong { color: var(--brand); font-size: 24px; font-weight: 600; }
.daily-stat span { font-size: 11px; }
.ai-log { max-height: 340px; padding: 10px 0; gap: 12px; }
.ai-msg { padding: 13px; line-height: 1.8; background: #f0f1e9; }
.ai-msg.player { background: #edf0e2; margin-left: 22px; }
.ai-msg.host { background: #e6eedf; margin-right: 22px; }
.ai-msg.host .ai-who { color: var(--brand); }
.ai-kp-fill { background: var(--brand); }
.ai-msg.celebrate { background: #e6eedf; }
.ai-kp-bar { background: #dce2d2; }
.ai-input .btn { flex: none; }
.member-row { padding: 13px 0; }
.member-row-avatar { background: #e4ebd9; color: var(--brand); font-size: 13px; border-radius: 12px; }

/* Control room */
body[data-page=admin] { background-color: #f2f3ec; }
body[data-page=admin] #page { max-width: 1380px; }
.admin-shell { display: grid; grid-template-columns: 196px minmax(0,1fr); gap: 40px; padding: 40px 0 60px; }
.admin-sidebar { min-width: 0; align-self: start; position: sticky; top: 106px; max-height: calc(100vh - 130px); overflow-y: auto; scrollbar-width: thin; }
.sidebar-heading { padding: 0 10px 22px; border-bottom: 1px solid var(--line); margin-bottom: 14px; }
.sidebar-heading .kicker { display: block; margin-bottom: 4px; color: var(--muted); font-size: 9px; }
.sidebar-heading strong { font-size: 18px; font-weight: 600; }
.admin-sidebar .tabs { display: flex; flex-direction: column; gap: 5px; border: 0; margin: 0 0 28px; }
.admin-sidebar .tabs button { display: flex; align-items: center; justify-content: space-between; text-align: left; padding: 11px 13px; border: 1px solid transparent; margin: 0; border-radius: 9px; font-size: 13px; min-height: 44px; }
.admin-sidebar .tabs button:hover { background: #e8ecdf; }
.admin-sidebar .tabs button.active { color: var(--brand); background: #e1e9d7; border-color: #d4dfc8; }
.tab-arrow { opacity: 0; }
.tabs button.active .tab-arrow { opacity: 1; }
.sidebar-user { display: flex; align-items: center; gap: 10px; border-top: 1px solid var(--line); padding: 24px 0 14px; }
.sidebar-user strong { display: block; font-size: 12px; }
.sidebar-user div > span { display: block; font-size: 10px; color: var(--muted); }
.admin-sidebar > .btn { width: 100%; }
.admin-main { min-width: 0; }
.admin-heading { display: flex; justify-content: space-between; gap: 18px; align-items: center; margin-bottom: 22px; }
.admin-heading .kicker { font-size: 9px; margin: 0 0 6px; }
.admin-heading h1 { font-size: 30px; line-height: 1.4; margin: 0 0 7px; font-weight: 650; }
.admin-heading p { color: var(--muted); margin: 0; font-size: 12px; }
.admin-toolbar { gap: 8px; margin-bottom: 20px; }
.primary-toolbar { padding: 16px 20px; margin: 0 0 14px; background: #e9ede1; border: 1px solid #dce3d2; border-radius: 12px; }
.primary-toolbar .hint { margin-left: auto; }
.admin-tools { margin-bottom: 22px; border: 1px solid var(--line); border-radius: 10px; background: #f9faf3; }
.admin-tools summary { padding: 11px 16px; cursor: pointer; font-size: 11px; color: var(--muted); }
.admin-tools summary > span { float: right; }
.admin-tools .admin-toolbar { padding: 12px 16px; margin: 0; border-top: 1px solid var(--line); }
.admin-content { padding: 30px; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; min-width: 0; }
.admin-content h3 { font-size: 17px; margin: 24px 0 14px; font-weight: 600; }
.admin-content > h3:first-child { margin-top: 0; }
.row-card { padding: 18px; background: #fafbf6; border-color: #dee4d5; border-radius: 12px; }
.row-card .row-head { align-items: flex-start; }
.row-card .row-head strong { font-size: 13px; }
.row-actions { flex-wrap: wrap; align-items: center; }
.row-head .row-actions { justify-content: flex-end; }

/* Mobile and tablet */
@media (max-width: 1080px) {
  .nav { gap: 2px; }
  .nav a { padding: 8px; font-size: 12px; }
  .hero-grid { gap: 42px; }
  .auth-layout { gap: 42px; grid-template-columns: 1fr 440px; }
  .admin-shell { gap: 24px; grid-template-columns: 180px minmax(0,1fr); }
}
@media (max-width: 900px) {
  .site-header .container { height: 72px; }
  .nav { display: none; position: absolute; top: 72px; left: 0; right: 0; background: var(--surface); flex-direction: column; align-items: stretch; padding: 16px; border-bottom: 1px solid var(--line); box-shadow: var(--shadow); gap: 4px; }
  .nav.open { display: flex; }
  .nav a { font-size: 14px; padding: 11px 15px; }
  .nav a:last-child { margin: 6px 0 0; }
  .nav-toggle { display: block; }
  .site-header .container { position: relative; }
  .hero-grid { grid-template-columns: 1.15fr .85fr; gap: 30px; padding-top: 52px; padding-bottom: 52px; }
  .hero-copy h1 { font-size: 38px; }
  .hero-notebook { padding: 20px; }
  .logic-symbol { height: 150px; }
  .logic-symbol span, .logic-symbol b { width: 115px; height: 115px; font-size: 70px; }
  .notebook-note { font-size: 17px; }
  .path-item { gap: 12px; padding: 22px 16px; }
  .path-item div > span { font-size: 10px; }
  .auth-layout { grid-template-columns: 1fr 400px; gap: 28px; }
  .auth-intro h1 { font-size: 32px; }
  .login-card { padding: 28px; }
  .admin-sidebar { top: 94px; }
  .admin-content { padding: 22px; }
}
@media (max-width: 720px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-copy h1 { font-size: 44px; }
  .hero-notebook { max-width: 440px; width: calc(100% - 10px); padding: 22px 26px 24px 34px; margin: 4px auto 0; }
  .logic-symbol { height: 170px; }
  .logic-symbol span, .logic-symbol b { width: 140px; height: 140px; font-size: 86px; }
  .path-grid { grid-template-columns: 1fr; }
  .path-item, .path-item:first-child, .path-item:last-child { padding: 20px 0; border-right: 0; border-bottom: 1px solid var(--line); gap: 22px; }
  .path-item:last-child { border-bottom: 0; }
  .path-item div > span { font-size: 12px; }
  .path-number { font-size: 23px; }
  .auth-layout { grid-template-columns: 1fr; gap: 26px; max-width: 500px; margin: 0 auto; }
  .auth-intro { padding-top: 0; }
  .auth-intro h1 { font-size: 32px; margin-bottom: 12px; }
  .auth-intro > p { max-width: none; }
  .auth-note { display: none; }
  .auth-section { padding: 36px 0; }
  .admin-shell { grid-template-columns: minmax(0,1fr); gap: 24px; padding-top: 24px; }
  .admin-sidebar { position: static; max-height: none; overflow: visible; }
  .sidebar-heading { padding: 0 0 12px; margin-bottom: 12px; }
  .admin-sidebar .tabs { flex-direction: row; flex-wrap: nowrap; overflow-x: auto; padding-bottom: 8px; margin-bottom: 10px; gap: 5px; scrollbar-width: thin; }
  .admin-sidebar .tabs button { flex: none; padding: 10px 12px; font-size: 12px; }
  .admin-sidebar .tabs .tab-arrow { display: none; }
  .sidebar-user { border: 0; padding: 10px 0; display: inline-flex; }
  .admin-sidebar > .btn { width: auto; float: right; margin-top: 10px; }
  .admin-heading h1 { font-size: 26px; }
  .daily-bar { grid-template-columns: repeat(2,1fr); }
}
@media (max-width: 640px) {
  .container { padding-left: 20px; padding-right: 20px; }
  .site-header .container { gap: 14px; }
  body[data-page=admin] .brand { font-size: 15px; }
  .section { padding: 38px 0; }
  .section + .section { padding-top: 14px; }
  .grid.cols-2, .grid.cols-3 { grid-template-columns: 1fr; }
  .hero-copy h1 { font-size: clamp(32px,9.5vw,44px); }
  .hero-grid { padding: 38px 20px 42px; }
  .hero-copy p { font-size: 14px; }
  .hero-kicker { font-size: 10px; margin-bottom: 18px; }
  .hero-cta { margin-bottom: 30px; }
  .hero-stats { gap: 20px; }
  .hero-stats > div { padding-right: 20px; }
  .hero-stats strong { font-size: 21px; }
  .section-head h2 { font-size: 24px; }
  .section-head h1 { font-size: 32px; }
  body:not([data-page=home]):not([data-page=admin]) #page > .section:first-child .section-head h2 { font-size: 32px; }
  .section-head p { font-size: 13px; }
  .card { padding: 22px; }
  .puzzle-head h3 { font-size: 21px; }
  .puzzle-toolbar { padding: 12px; gap: 12px; }
  .puzzle-search { max-width: none; flex-basis: 100%; }
  .chips { gap: 5px; }
  .puzzle-actions { gap: 7px; }
  .puzzle-actions .btn { min-height: 42px; }
  .poster-card img { height: 300px; }
  .president-card { padding: 24px; }
  .president-body blockquote { font-size: 19px; }
  .news-item { gap: 6px; padding: 22px 0; }
  .article { padding: 25px 22px; }
  .article h1 { font-size: 26px; }
  .login-card { padding: 26px 22px; }
  .login-card h2 { font-size: 24px; }
  input, select, textarea, .login-form input { font-size: 16px; }
  .password-field input { min-height: 50px; }
  .password-toggle { top: 2px; bottom: 2px; font-size: 12px; }
  .btn { min-height: 46px; }
  .auth-section { padding: 32px 0; }
  .auth-intro h1 { font-size: 30px; }
  .auth-intro .kicker { margin-bottom: 14px; }
  .form { padding: 22px; }
  .daily-stat { padding: 18px; }
  .daily-stat strong { font-size: 21px; }
  .daily-actions .btn { flex: 1; }
  .admin-content { padding: 20px 16px; }
  .primary-toolbar { padding: 12px; }
  .primary-toolbar .hint { width: 100%; margin-left: 0; }
  .admin-heading { align-items: flex-start; }
  .admin-heading .text-link { font-size: 11px; padding-top: 5px; }
  .row-card .row-head { flex-wrap: wrap; }
  .row-head .row-actions { justify-content: flex-start; }
  .row-body .two { grid-template-columns: 1fr; }
  .site-footer .container { flex-direction: column; gap: 22px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
