:root{font-family:Inter,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;color:#27243b;background:#f6f3ed;font-synthesis:none;--violet:#6352bb;--ink:#27243b;--muted:#706b7e;--line:#e6e1d9;--paper:#fffdf9;--lavender:#eee9ff}
*{box-sizing:border-box}body{margin:0}button,input{font:inherit}button,a{-webkit-tap-highlight-color:transparent}button{cursor:pointer}button:disabled{cursor:default;opacity:.5}button:focus-visible,a:focus-visible,input:focus-visible,summary:focus-visible{outline:3px solid #9783de;outline-offset:4px}[hidden]{display:none!important}.shell{max-width:780px;margin:0 auto;padding:26px 24px 118px}.topbar{display:flex;justify-content:space-between;align-items:center;gap:10px;margin-bottom:34px}.brand{display:flex;align-items:center;gap:8px;color:var(--ink);font-size:23px;font-weight:760;letter-spacing:-.9px;text-decoration:none}.brand-icon{display:inline-grid;place-items:center;width:33px;height:36px;background:var(--violet);border-radius:12px;color:white;font-family:Georgia,serif;font-size:31px;font-style:italic}.brand-dot{color:var(--violet);margin-left:-8px}.top-note{font-size:12px;color:var(--muted)}.card{overflow-wrap:anywhere;background:var(--paper);border:1px solid var(--line);border-radius:26px;padding:32px;margin-bottom:18px}.eyebrow{text-transform:uppercase;letter-spacing:1.8px;font-size:11px;font-weight:750;color:var(--violet);margin:0 0 12px}.muted{color:var(--muted);line-height:1.6}.lead{font-size:17px;line-height:1.7;color:var(--muted);max-width:510px}h1{font-size:clamp(29px,5.2vw,43px);letter-spacing:-1.3px;font-weight:730;line-height:1.14;margin:0 0 18px}h2{font-size:25px;letter-spacing:-.5px;margin:10px 0}h3{font-size:19px;margin:0 0 10px}.hero{position:relative;overflow:hidden;background:linear-gradient(135deg,#fffdfa,#f3efff)}.hero:after{content:"";position:absolute;width:170px;height:170px;right:-95px;top:20px;border:24px solid #e5ddf4;border-radius:50%;pointer-events:none;opacity:.6}.button{display:inline-flex;align-items:center;justify-content:center;gap:8px;min-height:48px;border:0;border-radius:13px;padding:12px 20px;font-weight:650;font-size:14px;line-height:1.4}.primary{background:var(--violet);color:white}.secondary{background:#ece7df;color:var(--ink)}.ghost{background:transparent;color:var(--violet);border:1px solid #ded7ef}.actions{display:flex;gap:10px;flex-wrap:wrap;margin-top:20px}.actions .button{flex:1}.pill{display:inline-block;padding:7px 11px;border-radius:30px;background:var(--lavender);font-size:12px;color:#4d4087}.metadata{display:flex;gap:8px;align-items:center;flex-wrap:wrap;margin-bottom:20px}.stats{display:grid;grid-template-columns:repeat(3,1fr);gap:12px;margin:24px 0 12px}.stat{border-top:1px solid var(--line);padding-top:18px}.stat strong{display:block;font-size:25px;font-weight:650;color:var(--violet);margin-bottom:5px}.stat span{font-size:12px;line-height:1.5;color:var(--muted)}.section-title{display:flex;align-items:center;justify-content:space-between;margin:24px 0 16px}.section-title h2{font-size:21px}.history-item{width:100%;text-align:left;display:flex;gap:14px;align-items:center;background:var(--paper);border:1px solid var(--line);border-radius:17px;padding:17px;margin-bottom:10px;min-height:65px}.history-number{border-radius:12px;background:#ece7df;display:grid;place-items:center;width:37px;height:37px;flex-shrink:0;color:var(--violet)}.history-item b{display:block;font-size:15px;margin-bottom:4px}.history-item small{color:var(--muted)}.story{font-family:Georgia,"Times New Roman",serif;font-size:22px;line-height:1.85;overflow-wrap:break-word}.story p{margin:0 0 24px}.phrase{display:inline;border:0;background:#eee9ff;color:#4d3b9c;border-radius:6px;padding:1px 5px;font:inherit;line-height:inherit;text-align:left;text-decoration:underline;text-decoration-color:#b9aadc;text-underline-offset:5px}.inline-help{font-family:system-ui,sans-serif;display:inline;color:var(--muted);font-size:13px;padding:0 5px}.recap{padding:14px 16px;background:#f1eee8;border-radius:13px;font-size:14px;line-height:1.6;margin-bottom:22px}.cliff{font-size:16px;line-height:1.6;padding:18px 0;border-top:1px solid var(--line);color:#514674;font-style:italic}.bridge{margin:24px 0;border:1px solid #ded6ee;background:#f6f3ff;border-radius:17px;padding:16px}.bridge>summary{cursor:pointer;font-weight:650;min-height:32px;line-height:1.6}.sentence{padding:18px 0;border-bottom:1px solid #e5deef}.sentence:last-child{border:0}.sentence p{font-family:Georgia,serif;font-size:20px;line-height:1.6;margin:0 0 12px}.sentence .translation{font-family:inherit;font-size:15px;color:var(--muted);margin-top:10px}.sentence .actions{margin-top:0}.sentence .button{flex:0 1 auto;min-height:44px;padding:8px 13px}.story-footer{border-top:1px solid var(--line);padding-top:18px}.feedback-title{font-size:14px;color:var(--muted);margin:0}.navigation{position:fixed;bottom:0;left:50%;transform:translateX(-50%);width:min(780px,100%);display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:6px;padding:12px 18px calc(12px + env(safe-area-inset-bottom));background:rgba(246,243,237,.98);border-top:1px solid var(--line);z-index:20}.navigation button{min-width:0;flex-wrap:wrap;overflow-wrap:anywhere;border:0;background:transparent;min-height:55px;border-radius:13px;color:var(--muted);display:flex;align-items:center;justify-content:center;gap:8px;font-size:13px}.navigation .active{background:#e8e1f5;color:#4d3b8e;font-weight:700}.navigation span{font-size:23px}.status{font-size:14px;line-height:1.6;min-height:22px;text-align:center;color:var(--muted)}.status.error{color:#a52f45}.demo-notice{border:1px solid #e2d5b3;background:#faf1d9;color:#655330;border-radius:13px;padding:14px;font-size:13px;line-height:1.6;margin-bottom:18px}footer{text-align:center;font-size:12px;color:var(--muted);margin-top:30px}.filter-row{display:flex;gap:8px;margin:18px 0;flex-wrap:wrap}.filter-row .button{font-size:12px;min-height:44px;padding:9px 14px}.phrase-card h2{font-size:26px}.phrase-context{border-left:2px solid #d1c4eb;padding-left:13px;font-size:15px;color:var(--muted);line-height:1.7}.use-case{font-size:14px;line-height:1.6}.empty{padding:38px 20px;text-align:center}.review-prompt{font-size:23px;line-height:1.5}.answer-input{width:100%;background:white;border:1px solid #ccc1de;border-radius:13px;padding:16px;font-size:20px;color:var(--ink);margin-top:10px}.review-result{margin-top:20px;padding:20px;background:#eef3ed;border-radius:15px;line-height:1.6}.review-result.practice{background:#f0ebfa}.review-result p{margin:10px 0}.correct-answer{font-size:25px;font-weight:700}.icon-button{border:0;background:transparent;min-width:44px;min-height:44px;font-size:28px;color:var(--ink)}dialog{width:min(540px,calc(100% - 24px));border:1px solid var(--line);border-radius:24px;padding:26px;background:var(--paper);color:var(--ink);box-shadow:0 10px 70px #30203b33;max-height:80vh;overflow:auto}dialog::backdrop{background:#2d213c55}.dialog-head{display:flex;justify-content:space-between;align-items:center}.phrase-translation{font-size:20px}.hint-note{font-size:12px;line-height:1.6;color:var(--muted)}
@media(max-width:480px){.shell{padding:20px 14px 118px}.topbar{margin-bottom:24px}.top-note{display:none}.card{padding:23px 20px;border-radius:21px}.story{font-size:20px;line-height:1.85}.navigation{padding-left:8px;padding-right:8px}.navigation button{gap:5px;font-size:12px}.brand{font-size:22px}.stats{gap:7px}.stat span{font-size:11px}.button{padding:12px 15px}.review-prompt{font-size:21px}.actions{gap:8px}.actions .button{min-width:100px}}
@media(prefers-reduced-motion:no-preference){button{transition:background .15s,opacity .15s}button:hover:not(:disabled){filter:brightness(.97)}}
.field{display:grid;gap:8px;margin:0 0 16px;font-size:13px;font-weight:650}.field input,.field select,.field>select{width:100%;min-height:48px;border:1px solid #ccc1de;border-radius:13px;background:white;color:var(--ink);padding:10px 13px}.check-field{display:flex;align-items:center;gap:10px;min-height:48px;margin-bottom:16px}.check-field input{width:22px;height:22px}.time-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:10px}.wide{width:100%}.next-delivery{padding:16px;text-align:center;background:var(--lavender);border-radius:14px}.warning{border-color:#d8b46d;background:#fffaf0}@media(max-width:480px){.time-grid{grid-template-columns:1fr}}

.choice-card{margin:22px 0;padding:20px;border:1px solid #d9d0ee;border-radius:18px;background:#faf8ff}
.choice-card h2{font-size:20px}.choice-options{display:grid;gap:10px}.choice-options .button{width:100%;text-align:left;justify-content:flex-start}
.choice-reaction{padding:16px;border-radius:14px;background:#eee9ff;line-height:1.6}.choice-reaction p{margin:8px 0}.story-continuation[hidden]{display:none}
.topic-picker{margin:12px 0 22px}.topic-picker.compact{margin-bottom:12px}.topic-option{padding:8px 12px;border:1px solid var(--line);border-radius:13px;background:white;margin-bottom:8px}
.preference-prompt{border-color:#d9d0ee}.series-finish{background:#f7f3ff}.history-list{margin-bottom:10px}
@media(min-width:700px){.topic-picker:not(.compact){display:grid;grid-template-columns:1fr 1fr;gap:8px 12px}.topic-picker:not(.compact)>p{grid-column:1/-1}.topic-option{margin-bottom:0}}
.demo-notice{display:flex;align-items:center;justify-content:space-between;gap:12px}.demo-notice .button{flex:0 0 auto;text-decoration:none}@media(max-width:480px){.demo-notice{align-items:stretch;flex-direction:column}.demo-notice .button{width:100%}}
.phrase-dialog{padding:0;border:0;background:transparent}.phrase-dialog-card{border:1px solid var(--line);border-radius:24px;padding:26px;background:var(--paper)}.phrase-dialog .icon-button,.phrase-dialog .button{min-width:44px;min-height:44px}.phrase-dialog .actions{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,112px),1fr));align-items:stretch}.phrase-dialog .actions .button{width:100%;min-width:0;white-space:normal;overflow-wrap:anywhere}
