:root {
  --ink: #17202a;
  --muted: #68737d;
  --line: #dce2e6;
  --paper: #f4f6f7;
  --white: #fff;
  --accent: #236659;
  --accent-soft: #e5f1ed;
  --navy: #203247;
  --amber: #cc8a22;
  --danger: #a64747;
  --shadow: 0 14px 40px rgba(23,32,42,.09);
}
* { box-sizing: border-box; }
body { margin:0; color:var(--ink); background:var(--paper); font-family:"Yu Gothic UI","Hiragino Kaku Gothic ProN",Meiryo,sans-serif; }
button,input { font:inherit; }
button { cursor:pointer; }
.shell { min-height:100vh; }
.topbar { height:72px; background:var(--white); border-bottom:1px solid var(--line); display:flex; align-items:center; justify-content:space-between; padding:0 42px; position:sticky; top:0; z-index:10; }
.brand { display:flex; align-items:center; gap:13px; font-weight:700; letter-spacing:.03em; }
.brand-mark { width:34px; height:34px; display:grid; place-items:center; color:white; background:var(--accent); border-radius:9px; font-family:Georgia,serif; font-size:20px; }
.demo-tag { font-size:11px; color:var(--accent); background:var(--accent-soft); padding:5px 8px; border-radius:99px; letter-spacing:.08em; }
.userbox { display:flex; align-items:center; gap:14px; font-size:13px; color:var(--muted); }
.layout { display:grid; grid-template-columns:238px minmax(0,1fr); min-height:calc(100vh - 72px); }
.side { background:var(--navy); color:white; padding:28px 18px; }
.side-profile { padding:4px 10px 24px; border-bottom:1px solid rgba(255,255,255,.13); margin-bottom:20px; }
.side-profile small { color:#b9c7d5; }
.side-profile strong { display:block; margin-top:6px; font-size:17px; }
.navbtn { width:100%; border:0; background:transparent; color:#d3dce5; text-align:left; padding:13px 14px; margin:4px 0; border-radius:8px; }
.navbtn:hover,.navbtn.active { background:rgba(255,255,255,.12); color:white; }
.main { padding:34px 42px 70px; max-width:1240px; width:100%; margin:auto; }
.page-head { display:flex; align-items:flex-end; justify-content:space-between; margin-bottom:24px; }
.eyebrow { margin:0 0 7px; color:var(--accent); font-size:12px; font-weight:700; letter-spacing:.13em; text-transform:uppercase; }
h1 { margin:0; font-size:28px; letter-spacing:.02em; }
h2 { margin:0 0 18px; font-size:19px; }
p { line-height:1.7; }
.muted { color:var(--muted); }
.card { background:var(--white); border:1px solid var(--line); border-radius:14px; box-shadow:var(--shadow); padding:24px; }
.grid-2 { display:grid; grid-template-columns:1.35fr .85fr; gap:22px; }
.stats { display:grid; grid-template-columns:repeat(4,1fr); gap:14px; margin-bottom:22px; }
.stat { background:white; border:1px solid var(--line); border-radius:12px; padding:18px; }
.stat-label { color:var(--muted); font-size:12px; }
.stat-value { margin-top:8px; font-size:26px; font-weight:700; }
.stat-value small { font-size:12px; color:var(--muted); font-weight:400; }
.progress { height:9px; background:#e6e9eb; border-radius:99px; overflow:hidden; }
.progress > i { display:block; height:100%; background:var(--accent); border-radius:99px; }
.lesson-list { display:grid; gap:12px; }
.lesson { border:1px solid var(--line); border-radius:10px; padding:15px; display:flex; align-items:center; gap:14px; }
.lesson-num { width:40px; height:40px; background:var(--accent-soft); color:var(--accent); display:grid; place-items:center; border-radius:8px; font-weight:700; }
.lesson-info { flex:1; }
.lesson-info strong,.lesson-info small { display:block; }
.lesson-info small { color:var(--muted); margin-top:4px; }
.btn { border:0; border-radius:8px; padding:11px 18px; background:var(--accent); color:white; font-weight:700; }
.btn:hover { filter:brightness(.95); }
.btn.secondary { background:white; color:var(--ink); border:1px solid var(--line); }
.btn.ghost { background:transparent; color:var(--muted); padding:8px 10px; }
.calendar { display:grid; grid-template-columns:repeat(9,1fr); gap:7px; }
.day { aspect-ratio:1; display:grid; place-items:center; border:1px solid var(--line); background:white; border-radius:7px; font-size:12px; color:var(--muted); }
.day.done { background:var(--accent); color:white; border-color:var(--accent); }
.day.today { color:var(--accent); border:2px solid var(--accent); font-weight:700; }
.day.locked { opacity:.45; }
.quiz-wrap { max-width:800px; margin:0 auto; }
.quiz-top { display:flex; justify-content:space-between; align-items:center; margin-bottom:14px; color:var(--muted); font-size:13px; }
.symbol-stage { min-height:245px; display:grid; place-items:center; text-align:center; background:#fbfcfc; border:1px solid var(--line); border-radius:12px; margin:18px 0 22px; }
.symbol { font-family:"Segoe UI Symbol","Arial Unicode MS",sans-serif; font-size:112px; line-height:1; font-weight:300; }
.symbol.small { font-size:46px; }
.choices { display:grid; grid-template-columns:1fr 1fr; gap:12px; }
.choice { padding:17px; border:1px solid var(--line); background:white; border-radius:9px; text-align:left; }
.choice:hover { border-color:var(--accent); background:var(--accent-soft); }
.choice.correct { border-color:var(--accent); background:var(--accent-soft); color:var(--accent); font-weight:700; }
.choice.wrong { border-color:var(--danger); background:#faeded; color:var(--danger); }
.feedback { margin-top:16px; padding:14px 16px; border-radius:9px; background:var(--accent-soft); color:var(--accent); display:flex; justify-content:space-between; align-items:center; }
.tabs { display:flex; gap:8px; margin-bottom:18px; }
.tab { border:1px solid var(--line); background:white; border-radius:8px; padding:10px 16px; color:var(--muted); }
.tab.active { background:var(--navy); color:white; border-color:var(--navy); }
.flash-answer { font-size:28px; font-weight:700; color:var(--accent); margin-top:18px; }
.sort-row { display:flex; gap:12px; justify-content:center; flex-wrap:wrap; margin:26px 0; }
.sort-item { min-width:88px; min-height:88px; padding:12px; background:white; border:2px solid var(--line); border-radius:11px; display:grid; place-items:center; }
.sort-item.selected { border-color:var(--accent); background:var(--accent-soft); transform:translateY(-3px); }
table { width:100%; border-collapse:collapse; }
th { color:var(--muted); font-size:12px; text-align:left; font-weight:600; background:#f7f8f9; }
th,td { padding:14px 12px; border-bottom:1px solid var(--line); }
.pill { display:inline-block; font-size:11px; border-radius:99px; padding:5px 9px; background:var(--accent-soft); color:var(--accent); font-weight:700; }
.pattern-grid { display:grid; grid-template-columns:repeat(5,1fr); gap:8px; }
.pattern-cell { border:1px solid var(--line); border-radius:8px; padding:10px; text-align:center; }
.pattern-cell b { font-size:28px; display:block; }
.pattern-cell small { color:var(--muted); }
.login-page { min-height:100vh; display:grid; grid-template-columns:1.05fr .95fr; background:white; }
.login-visual { background:var(--navy); color:white; padding:70px; display:flex; flex-direction:column; justify-content:space-between; position:relative; overflow:hidden; }
.login-visual:after { content:"⌁  ⟑  ⌇\A  ⊘  ⌗  ⌑"; white-space:pre; position:absolute; right:-15px; bottom:55px; font-size:90px; line-height:1.4; color:rgba(255,255,255,.055); transform:rotate(-8deg); }
.login-copy { max-width:520px; position:relative; z-index:1; }
.login-copy h1 { font-size:38px; margin:22px 0; line-height:1.45; }
.login-copy p { color:#c6d1dc; }
.login-form-wrap { display:grid; place-items:center; padding:60px; }
.login-form { width:100%; max-width:420px; }
.login-form h2 { font-size:27px; margin-bottom:8px; }
.field { margin:20px 0; }
.field label { display:block; font-size:13px; font-weight:700; margin-bottom:8px; }
.field input { width:100%; border:1px solid #cfd6dc; padding:13px 14px; border-radius:8px; outline:none; }
.field input:focus { border-color:var(--accent); box-shadow:0 0 0 3px var(--accent-soft); }
.login-form .btn { width:100%; padding:14px; }
.demo-accounts { margin-top:24px; background:#f5f7f8; border-radius:10px; padding:16px; font-size:12px; line-height:1.8; }
.login-error { color:var(--danger); font-size:13px; margin-top:10px; }
.notice { padding:13px 16px; background:#fff8e8; color:#795713; border:1px solid #f1d9a4; border-radius:9px; font-size:13px; margin-bottom:20px; }
.footer-note { text-align:center; color:var(--muted); font-size:11px; margin-top:34px; }
@media(max-width:900px){.layout{grid-template-columns:190px 1fr}.main{padding:26px 22px}.stats{grid-template-columns:1fr 1fr}.grid-2{grid-template-columns:1fr}.login-page{grid-template-columns:1fr}.login-visual{display:none}}
