:root{font-family:DM Sans,system-ui,sans-serif;color:#25243b;background:#f7f7fb;font-synthesis:none}*{box-sizing:border-box}body{margin:0}button,input,select{font:inherit}button{cursor:pointer}button:disabled{opacity:.5;cursor:not-allowed}a{color:inherit}h1,h2,h3,h4,p{margin-top:0}h1,h2,h3,h4{font-family:Outfit,system-ui,sans-serif}h1{font-size:clamp(2rem,7vw,3rem);line-height:1.08;margin-bottom:.6rem;letter-spacing:-.035em}h2{font-size:1.36rem;line-height:1.25}p{line-height:1.55}label,legend{font-weight:700;font-size:.88rem}input:not([type=checkbox]),select{width:100%;min-height:48px;border:1px solid #bfc1d3;border-radius:12px;background:#fff;color:#25243b;padding:.72rem .85rem}input:focus-visible,select:focus-visible,button:focus-visible,a:focus-visible,.flashcard:focus-visible{outline:3px solid #b42b3a;outline-offset:3px}input[type=checkbox]{accent-color:#17146b;width:20px;height:20px}.primary,.secondary{min-height:48px;padding:.74rem 1rem;border-radius:12px;font-weight:700;border:1px solid transparent}.primary{background:#17146b;color:#fff}.secondary{background:#fff;border-color:#c4c5db;color:#17146b}.secondary:hover{background:#f0eff9}.full{width:100%}.text-button,.danger-link{background:transparent;border:0;padding:.6rem;color:#17146b;font-weight:700}.danger-link{color:#a62635;text-align:left}.eyebrow{text-transform:uppercase;letter-spacing:.16em;color:#ad2938;font-size:.75rem;font-weight:700}.error{background:#fff0ee;color:#852b25;border:1px solid #e6b1ac;border-radius:10px;padding:.75rem}.center-shell{min-height:100vh;display:grid;place-items:center}.login-shell{min-height:100vh;background:linear-gradient(155deg,#17146b 0 36%,#f7f7fb 36%);padding:36px 20px}.login-brand{display:flex;gap:.75rem;align-items:center;color:#fff;line-height:1.05;font-size:1.25rem;max-width:420px;margin:0 auto 54px}.brand-mark{display:grid;place-items:center;width:48px;height:48px;border-radius:14px;background:#efedf8;color:#17146b;font-family:serif;font-size:1.6rem}.brand-mark.small{width:34px;height:34px;border-radius:10px;font-size:1.15rem}.login-card{background:#fff;border-radius:22px;padding:28px 22px;max-width:420px;margin:auto;box-shadow:0 18px 50px #17146b20}.login-card p:not(.eyebrow){color:#57596d}.login-card form{display:grid;gap:.5rem}.login-card form label:not(:first-child){margin-top:.8rem}.login-card button{margin-top:1rem}.app-shell{min-height:100vh}.topbar{height:72px;background:#17146b;color:#fff;display:flex;justify-content:space-between;align-items:center;padding:0 max(20px,calc((100vw - 980px)/2));gap:1rem}.topbar .brand{display:flex;align-items:center;gap:.7rem;white-space:nowrap}.topbar .text-button{color:#fff}.app-shell main{max-width:980px;margin:auto;padding:30px 18px 112px}.page-intro{margin-bottom:26px}.page-intro p:last-child{color:#626479}.toolbar,.filter-card,.settings-card{background:#fff;border:1px solid #e2e3ed;border-radius:18px;padding:18px;margin-bottom:22px}.toolbar{display:grid;gap:.5rem;max-width:410px}.section-nav{display:flex;gap:.6rem;overflow-x:auto;padding-bottom:12px;margin:6px 0 16px;scrollbar-width:thin}.section-nav a{flex:none;text-decoration:none;background:#efeff8;color:#17146b;border-radius:99px;padding:.65rem .9rem;font-weight:700;font-size:.85rem}.content-card{background:#fff;border:1px solid #e2e3ed;border-radius:18px;padding:20px;margin-bottom:18px;scroll-margin-top:16px}.content-card h2{border-bottom:1px solid #e5e5ef;padding-bottom:.75rem;margin-bottom:1.3rem}.content-card h2 span{color:#ad2938;margin-right:.25rem}.source-item{display:grid;grid-template-columns:2.4rem minmax(0,1fr);gap:.2rem .5rem;margin:0 0 1.25rem}.source-item:last-child{margin-bottom:0}.source-item h3{font-size:1rem;margin:0;grid-column:1}.source-item h4{grid-column:2;margin:0 0 .5rem;font-size:1rem}.source-item>p,.source-lines,.source-rows{grid-column:2;min-width:0}.source-item:not(:has(h3))>p,.source-item:not(:has(h3)) .source-lines,.source-item:not(:has(h3)) .source-rows{grid-column:1/-1}.source-lines p{margin:0 0 .25rem}.source-row{display:grid;grid-template-columns:minmax(2.2rem,auto) minmax(1.5rem,auto) minmax(0,1fr);gap:.25rem .55rem;padding:.3rem 0;border-bottom:1px solid #ececf3;line-height:1.45}.source-row:last-child{border-bottom:0}.row-label{font-weight:700;color:#5d5f75}.empty-state{background:#f0eff8;border-radius:18px;padding:25px;margin:20px 0}.empty-state h2{margin-bottom:.5rem}.empty-state p{margin-bottom:0}.grade-picker{border:0;padding:0;margin:0 0 15px;display:flex;flex-wrap:wrap;gap:10px}.grade-picker legend{width:100%;margin-bottom:.6rem}.check-pill{display:flex;align-items:center;gap:.6rem;background:#fff;border:1px solid #d9daeb;padding:.7rem .9rem;border-radius:12px;min-height:48px}.options-row,.action-row,.card-actions{display:flex;flex-wrap:wrap;gap:10px;align-items:center;margin:16px 0}.options-row label{display:flex;align-items:center;gap:.5rem;font-weight:500}.progress-line{display:flex;justify-content:space-between;gap:12px;color:#57596d;font-size:.85rem;margin-top:27px}.progress-track{height:8px;background:#e6e6f0;border-radius:99px;overflow:hidden;margin:10px 0 20px}.progress-track span{display:block;height:100%;background:#bf2b3a}.flashcard{min-height:270px;background:#fff;border:1px solid #e2e3ed;border-radius:22px;box-shadow:0 12px 30px #17146b12;padding:25px;display:flex;flex-direction:column;justify-content:space-between;align-items:flex-start;cursor:pointer;transition:transform .18s}.flashcard:hover{transform:translateY(-2px)}.flashcard strong{font:600 clamp(1.7rem,6vw,2.5rem)/1.15 Outfit,system-ui,sans-serif;overflow-wrap:anywhere}.card-hint{color:#686a7e;font-size:.85rem}.flashcard.revealed{background:#f0effa}.card-actions>*{flex:1 1 120px}.settings-card{margin-top:35px}.settings-card h2{margin-bottom:.4rem}.settings-card p{color:#686a7e}.filter-card>label{display:block;margin-bottom:.4rem}.filter-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;margin-top:14px}.filter-grid label{display:block;margin-bottom:.35rem}.result-count{color:#686a7e;font-size:.85rem}.vocab-card{background:#fff;border:1px solid #e2e3ed;border-radius:16px;padding:17px 19px;margin-bottom:11px}.vocab-card h2{margin-bottom:.2rem}.vocab-card p{margin-bottom:.4rem}.meta{font-size:.85rem;color:#6b6c7d}.tags{display:flex;flex-wrap:wrap;gap:.4rem;margin-top:.7rem}.tags span{background:#f0eff8;color:#17146b;border-radius:99px;padding:.25rem .6rem;font-size:.75rem;font-weight:700}.bottom-nav{position:fixed;bottom:0;left:0;right:0;display:flex;justify-content:center;background:#fff;border-top:1px solid #e2e3ed;padding:5px 8px max(5px,env(safe-area-inset-bottom));z-index:20;box-shadow:0 -5px 20px #17146b12}.bottom-nav button{border:0;background:transparent;color:#696b80;min-height:58px;min-width:98px;max-width:220px;flex:1;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:2px;font-size:.72rem;font-weight:700;border-radius:10px}.bottom-nav button span{font-size:1.45rem;line-height:1}.page-error{margin-bottom:20px}@media(max-width:600px){.topbar{height:60px;padding:0 16px}.app-shell main{padding:25px 16px 105px}.topbar .brand{font-size:.83rem}.filter-grid{grid-template-columns:1fr}.content-card{padding:17px}.source-row{grid-template-columns:2.7rem 1.5rem minmax(0,1fr);font-size:.93rem}.source-item{grid-template-columns:1.8rem minmax(0,1fr)}.progress-line{font-size:.78rem}}@media(prefers-reduced-motion:reduce){.flashcard{transition:none}}.source-row.dialogue-row{grid-template-columns:2.7rem minmax(0,1fr)}.source-ref{display:block;grid-column:1/-1;color:#6b6c7d;font-size:.75rem;margin-top:.55rem}.source-row span:last-child{overflow-wrap:anywhere}.flashcard strong{max-width:100%}.page-quote{margin:24px 0;padding:18px 22px;border-left:3px solid #ba2c3b;background:#fff;border-radius:0 12px 12px 0}.page-quote p{margin:0 0 .2rem}.page-quote p:last-of-type{font-size:.85rem;color:#686a7e;margin-top:.5rem}.page-quote small{color:#6b6c7d}.abbreviation-card{margin:0 0 22px;padding:16px 20px;background:#f1f0fa;border:1px solid #dedff0;border-radius:16px}.abbreviation-card h2{font-size:1rem;margin:0 0 .55rem}.abbreviation-card dl{margin:0 0 .5rem}.abbreviation-card dl div{display:flex;gap:12px;padding:.18rem 0}.abbreviation-card dt{font-weight:700;min-width:3rem}.abbreviation-card dd{margin:0}.abbreviation-card small{color:#63657a}.login-shell{background:radial-gradient(circle at 75% 0%,#eeedf9 0,#f7f7fb 45%,#fbfbfd)}.login-brand{flex-direction:column;gap:.4rem;max-width:420px;margin:0 auto 28px;color:#17146b;text-align:center;font-size:1.15rem;font-weight:700}.login-brand img{width:min(245px,80vw);height:auto;display:block}.login-card{border:1px solid #e2e3ed;box-shadow:0 18px 50px #17146b12}.topbar{height:76px;background:#fff;color:#17146b;border-bottom:1px solid #e2e3ed;box-shadow:0 3px 14px #17146b0b}.topbar .brand{min-width:0;gap:.75rem}.topbar .brand img{display:block;width:116px;height:auto;flex:none}.topbar .brand span{font-size:1rem;font-weight:700;line-height:1.2;white-space:normal}.topbar .text-button{color:#17146b}.primary{background:#17146b}.primary:hover{background:#100d58}.bottom-nav button.active{color:#17146b;background:#efeffa}@media(max-width:600px){.topbar{height:72px;justify-content:center}.topbar .brand{flex:0 1 auto;justify-content:center;gap:.45rem}.topbar .brand img{width:clamp(72px,22vw,88px)}.topbar .brand span{font-size:clamp(.72rem,3.5vw,.9rem);max-width:none;white-space:nowrap}.topbar .text-button{font-size:.78rem;padding:.35rem}}.direction-picker{border:0;padding:0;margin:0 0 18px;min-width:0}.direction-picker legend{margin-bottom:.55rem}.direction-options{display:flex;flex-wrap:wrap;gap:8px}.direction-options button{min-height:44px;border:1px solid #c4c5db;border-radius:10px;padding:.6rem .9rem;background:#fff;color:#17146b;font-weight:700}.direction-options button.active{background:#17146b;border-color:#17146b;color:#fff}.direction-options button:hover:not(.active){background:#f0eff9}.direction-picker small{display:block;margin-top:.55rem;color:#686a7e;line-height:1.4}.app-shell main.learning-main{padding-bottom:calc(220px + env(safe-area-inset-bottom))}.study-start{position:fixed;left:0;right:0;bottom:calc(68px + env(safe-area-inset-bottom));z-index:19;display:flex;align-items:center;justify-content:space-between;gap:20px;padding:14px max(20px,calc((100vw - 980px)/2));background:#fff;border-top:1px solid #dedff0;box-shadow:0 -8px 24px #17146b16}.study-start h2{margin:0 0 .25rem;color:#17146b;font-size:1.2rem}.study-start p{margin:0;color:#55566d;font-size:.85rem}.study-start .start-button{min-height:54px;padding:.8rem 1.15rem;font-size:1rem;white-space:nowrap;box-shadow:0 5px 15px #17146b29}.study-start .start-button span{margin-left:.4rem;font-size:1.15rem}.study-tools{margin-top:20px}@media(max-width:700px){.study-start{gap:10px;flex-direction:column;align-items:stretch;padding:10px 16px}.study-start h2{font-size:1rem;margin:0}.study-start p{display:none}.study-start .start-button{width:100%;min-height:50px}}.foundation-accordion{display:grid;gap:12px}.foundation-panel{background:#fff;border:1px solid #dfe0ec;border-radius:16px;overflow:hidden;scroll-margin-top:16px}.foundation-panel[open]{border-color:#bcbde0;box-shadow:0 8px 22px #17146b0e}.foundation-panel summary{display:flex;align-items:center;justify-content:space-between;gap:12px;min-height:62px;padding:16px 20px;color:#17146b;font:700 1.08rem Outfit,system-ui,sans-serif;cursor:pointer;list-style:none}.foundation-panel summary::-webkit-details-marker{display:none}.foundation-panel summary:hover{background:#f6f5fc}.foundation-panel summary:focus-visible{outline:3px solid #b42b3a;outline-offset:-4px}.foundation-chevron{flex:none;font:700 1.45rem/1 system-ui,sans-serif;transition:transform .2s}.foundation-panel[open] .foundation-chevron{transform:rotate(180deg)}.foundation-panel-body{border-top:1px solid #e5e5ef;padding:18px 20px 20px}.foundation-intro{font-weight:700;color:#17146b;margin-bottom:1.25rem}.foundation-list{display:grid;gap:0}.foundation-entry{display:flex;align-items:flex-start;gap:1rem;padding:.85rem 0;border-bottom:1px solid #ececf3}.foundation-entry:last-child{border-bottom:0}.foundation-entry>div{min-width:0}.foundation-entry h3{font-size:1rem;margin:0 0 .3rem;color:#17146b}.foundation-entry p{margin:0;white-space:pre-line}.foundation-label{flex:0 0 2rem;color:#ad2938;font-weight:800}.bottom-nav button{min-width:0}@media(max-width:600px){.bottom-nav button{padding:.2rem;font-size:.67rem}.bottom-nav button span{font-size:1.3rem}.foundation-entry{gap:.55rem}}.install-strip,.install-help{display:none}@media(max-width:700px){.install-strip{display:flex;justify-content:flex-end;max-width:980px;margin:auto;padding:5px 16px 0}.install-trigger{border:0;background:transparent;color:#17146b;font-size:.79rem;font-weight:700;padding:.45rem .25rem;min-height:38px}.install-trigger span{font-size:1.12rem;vertical-align:-.07em;margin-right:.25rem}.install-help{display:block;background:#f0effa;border:1px solid #d9d8ef;border-radius:12px;margin:3px 16px 0;padding:12px 15px;font-size:.83rem;color:#25243b}.install-help p{margin:0}}.composition-note{display:block;max-width:70ch;margin:.55rem 0 .8rem;padding:.7rem .85rem;border-left:3px solid #ad2938;border-radius:0 8px 8px 0;background:#faf4f5;color:#53546c;font-size:.85rem;line-height:1.5;overflow-wrap:anywhere}.composition-note b{color:#25243b;font-weight:600}.flashcard .composition-note{width:100%;margin:1rem 0}
