@charset "UTF-8";
:root{--ink:#183630;--green:#176953;--light:#f3f6f2;--line:#e0e7e1;--muted:#687a72;--gold:#d7b773}*{box-sizing:border-box}html{scroll-behavior:smooth;scroll-padding-top:24px}body{margin:0;color:var(--ink);background:#f6f8f5;font:14px/1.75 "Yu Gothic UI","Meiryo",sans-serif}a{color:inherit}button,input,select,textarea{font:inherit}button,a,input,select,textarea{ -webkit-tap-highlight-color:transparent}button{cursor:pointer}button:disabled{cursor:default;opacity:.4}button:focus-visible,a:focus-visible,input:focus-visible,select:focus-visible,textarea:focus-visible{outline:3px solid #d1a64f;outline-offset:3px}button{border:0}h1,h2,h3,p{margin-top:0}h1{font-size:30px;letter-spacing:.04em;margin-bottom:5px}h2{font-size:21px;letter-spacing:.03em}h3{font-size:16px}.sidebar{width:238px;position:fixed;inset:0 auto 0 0;background:#fff;border-right:1px solid var(--line);padding:35px 24px;display:flex;flex-direction:column;z-index:2}.brand{display:flex;gap:12px;align-items:center;text-decoration:none;font-size:23px;letter-spacing:.02em}.brand-icon{display:grid;place-items:center;background:var(--green);color:#fff;border-radius:11px;width:43px;height:46px;font-size:24px}.brand small{display:block;font-size:8px;letter-spacing:.19em;color:var(--muted)}.brand b{font-weight:500}.nav-label,.eyebrow{font-size:10px;letter-spacing:.17em;color:var(--green);font-weight:700}.nav-label{margin:50px 10px 12px;color:#7b8d83}nav{display:grid;gap:8px}nav a{text-decoration:none;padding:11px 12px;border-radius:7px;font-size:13px}nav a:hover,nav a.active{background:#eaf3ec;color:var(--green);font-weight:700}nav span{float:right;border-radius:5px;background:#d8e8db;padding:0 6px}.side-bottom{margin-top:auto;padding-top:35px}.side-bottom p{font-size:12px;margin-bottom:7px}.side-bottom small{font-size:10px;color:var(--muted)}.side-bottom button{display:block;width:100%;margin-top:18px}.side-bottom>a{display:block;margin-top:20px;font-size:11px;color:var(--muted)}.import-label{cursor:pointer;display:block;font-size:11px;text-align:center;margin-top:10px;text-decoration:underline}.import-label input{max-width:100%;display:block;font-size:10px;margin-top:7px}.shell{margin-left:238px}.topbar{height:67px;background:#fff;border-bottom:1px solid var(--line);padding:0 45px;display:flex;align-items:center;justify-content:space-between;font-size:11px;color:var(--muted)}main{max-width:1260px;margin:auto;padding:36px 45px 55px}.page-heading{display:flex;justify-content:space-between;align-items:center;margin-bottom:27px}.page-heading p:last-child{font-size:12px;color:var(--muted);margin-bottom:0}.eyebrow{margin-bottom:9px}.local-badge{font-size:10px;border:1px solid #dbe6dd;padding:5px 11px;border-radius:20px;white-space:nowrap;color:var(--green)}.hero{overflow:hidden;position:relative;border-radius:15px;background:#174f40;color:#fff;padding:32px 38px;display:flex;justify-content:space-between;min-height:287px}.pill{display:inline-block;border:1px solid #6c9382;border-radius:20px;padding:3px 12px;font-size:10px;letter-spacing:.04em}.hero h2{font-size:32px;line-height:1.5;margin:17px 0 10px;letter-spacing:.08em}.hero p{font-size:12px;color:#d3e3d8}.primary,.secondary,.ghost{display:inline-block;border-radius:7px;padding:10px 18px;text-decoration:none;font-weight:600;font-size:12px}.primary{background:var(--green);color:#fff}.primary:hover{background:#0e4d3c}.hero .primary{background:#f0e7cc;color:#234b3a;margin-top:4px;min-width:182px}.hero .primary span{float:right;margin-left:20px}.secondary{border:1px solid #ccdbce;color:var(--green);background:#fff}.ghost{background:#fff;border:1px solid var(--line);color:var(--ink)}.hero-art{width:34%;position:relative;align-self:stretch;min-height:240px}.orbit{position:absolute;width:270px;height:270px;border:1px solid #456e5c;border-radius:50%;top:-5px;left:-25px;box-shadow:0 0 0 30px #ffffff05,0 0 0 60px #ffffff04}.book{position:absolute;top:35px;left:20px;width:145px;height:182px;border-radius:4px 12px 12px 4px;background:#e8ddbc;transform:rotate(-12deg);box-shadow:12px 13px 0 #0c392b,15px 16px 0 #78927a;color:#315541;padding:30px 24px;border-left:8px solid #c7b888}.book span{font-size:22px;font-weight:600;line-height:1.6;letter-spacing:.04em}.book i{display:block;position:absolute;left:20px;right:20px;top:18px;border-top:1px solid #a7976c}.spark{position:absolute;font-size:30px;color:var(--gold)}.spark.a{right:20px;top:20px}.spark.b{left:-30px;bottom:15px}.stats{display:grid;grid-template-columns:repeat(4,1fr);gap:15px;margin:22px 0 28px}.stats article{border:1px solid var(--line);border-radius:10px;background:#fff;padding:18px 20px}.stats article>span{font-size:11px;color:var(--muted)}.stats strong{display:block;font-size:29px;font-weight:600;margin:5px 0}.stats strong small{font-size:12px;font-weight:400;color:var(--muted)}.stats article>small{font-size:9px;color:var(--muted)}.track{height:4px;background:#edf1ec;border-radius:5px;margin-top:18px}.track i{display:block;height:100%;background:#3e8566;border-radius:5px;width:0}.review-panel{background:#eaf0e6;border:1px solid #dce5d6;border-radius:10px;padding:24px 27px;display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:15px;margin-bottom:40px}.review-panel h2{font-size:18px;margin-bottom:5px}.review-panel p:last-child{font-size:11px;color:var(--muted);margin-bottom:0}#review-list{display:flex;gap:8px;flex-wrap:wrap;width:100%}#review-list:empty{display:none}#review-list button{background:#fff;color:var(--green);border-radius:5px;padding:6px 12px;font-size:11px}.section-heading{display:flex;align-items:end;justify-content:space-between}.section-heading h2{margin-bottom:0}.muted{color:var(--muted);font-size:11px}.section-help{font-size:11px;color:var(--muted);margin:12px 0 20px}.filters{display:flex;gap:12px;background:#fff;border:1px solid var(--line);padding:16px;border-radius:10px;align-items:end}.filters label{font-size:10px;display:block;color:var(--muted)}.filters input,.filters select{display:block;margin-top:4px;width:100%;background:#fafcf9;border:1px solid var(--line);border-radius:6px;padding:10px;color:var(--ink);min-height:42px;font-size:11px}.search-label{flex:1;min-width:160px}.filters label:not(.search-label){flex:0 1 165px}.list-caption{display:flex;justify-content:space-between;gap:15px;font-size:10px;color:var(--muted);margin:16px 0 10px}.questions{display:grid;gap:9px}.question{background:#fff;border:1px solid var(--line);border-radius:9px;padding:17px 19px;display:flex;align-items:center;gap:17px}.q-num{background:#f0f4ed;min-width:45px;height:45px;border-radius:7px;display:grid;place-items:center;font-size:18px;color:var(--green)}.q-body{flex:1;min-width:0}.q-body h3{font-size:13px;margin:4px 0;overflow-wrap:anywhere}.q-meta{font-size:9px;color:var(--muted);display:flex;gap:10px;flex-wrap:wrap}.q-meta .tag{color:var(--green)}.q-status{font-size:10px;color:var(--muted);white-space:nowrap}.question .secondary{padding:8px 14px;white-space:nowrap;font-size:11px}.pagination{display:flex;align-items:center;justify-content:center;gap:22px;margin:22px 0 45px;font-size:11px}.steps{display:grid;grid-template-columns:repeat(3,1fr);gap:16px;margin-top:20px}.steps article{background:#fff;border:1px solid var(--line);border-radius:9px;padding:23px}.steps span{color:var(--green);font-size:10px;letter-spacing:.12em}.steps h3{margin:12px 0 9px;font-size:14px}.steps p,.source p{font-size:11px;color:var(--muted);margin-bottom:0}.source{border-top:1px solid var(--line);padding-top:24px;margin-top:26px}.source strong{font-size:12px}.source p{margin-top:9px}footer{padding:20px 45px;border-top:1px solid var(--line);font-size:13px;display:flex;gap:20px;align-items:center}footer span{font-size:10px;color:var(--muted)}footer a{margin-left:auto;font-size:10px}dialog{border:1px solid var(--line);border-radius:14px;width:min(570px,calc(100% - 30px));max-height:90vh;padding:30px;color:var(--ink)}dialog::backdrop{background:#102c2477;backdrop-filter:blur(3px)}dialog h2{font-size:20px;padding-right:20px}dialog .close{position:absolute;right:16px;top:10px;background:none;font-size:26px;color:var(--muted)}fieldset{border:1px solid var(--line);border-radius:6px;margin:20px 0;padding:12px}fieldset label{display:inline-block;margin:4px 13px 4px 0;font-size:12px}legend{font-size:12px}.field{display:block;font-size:12px;margin:14px 0}.field select,.field textarea{display:block;width:100%;padding:9px;border:1px solid #c6d5ca;border-radius:6px;color:var(--ink);background:#fafcf9;margin-top:5px}#history{margin:14px 0;white-space:pre-line}#notice:not(:empty){padding:12px 18px;background:#fff3d4;border:1px solid #dbc688;border-radius:7px;margin-bottom:20px;font-size:12px}.skip{position:fixed;top:-60px;left:20px;background:#fff;z-index:10;padding:8px}.skip:focus{top:8px}.empty{text-align:center;padding:35px;color:var(--muted);border:1px dashed var(--line);border-radius:8px}
@media(min-width:1450px){.hero-art{margin-right:40px}}@media(max-width:1120px){.sidebar{width:205px;padding:28px 18px}.shell{margin-left:205px}main{padding:28px}.topbar{padding:0 28px}.stats{gap:9px}.stats article{padding:15px 12px}.filters{flex-wrap:wrap}.search-label{flex-basis:100%}.filters label:not(.search-label){flex:1}.hero-art{width:30%}.book{left:0}.hero{padding:29px}.local-badge{display:none}.stats article>small{font-size:9px}}@media(max-width:760px){.sidebar{position:static;width:100%;padding:18px 20px;border-right:0;border-bottom:1px solid var(--line)}.brand{font-size:20px}.brand-icon{width:35px;height:38px;font-size:20px}.brand small{font-size:7px}.nav-label,.side-bottom{display:none}nav{display:flex;gap:5px;margin-top:17px;overflow-x:auto}nav a{padding:8px 10px;font-size:11px;white-space:nowrap}nav a:last-child{display:none}.shell{margin-left:0}.topbar{height:44px;padding:0 20px;font-size:9px}main{padding:25px 20px 35px}h1{font-size:23px}.page-heading p:last-child{font-size:11px}.hero{min-height:285px;padding:27px 24px}.hero h2{font-size:27px}.hero p{max-width:255px;font-size:11px}.hero-art{position:absolute;right:-65px;bottom:0;width:155px;opacity:.24;pointer-events:none}.hero>div:first-child{z-index:1}.book{left:18px;top:40px;width:125px}.pill{font-size:9px}.stats{grid-template-columns:repeat(2,1fr);gap:10px}.stats article{padding:14px 17px}.stats strong{font-size:26px}.review-panel{padding:20px;gap:12px;margin-bottom:30px}.review-panel h2{font-size:16px}.section-heading{align-items:start;gap:10px}.section-heading h2{font-size:19px}.section-heading>.muted{font-size:9px;margin-top:24px;white-space:nowrap}.filters{padding:12px;gap:9px}.filters label:not(.search-label){flex:1 1 30%;min-width:80px}.filters select{font-size:10px;padding:8px 4px}.list-caption{font-size:9px}.list-caption span:last-child{max-width:170px;text-align:right}.question{padding:13px 12px;gap:10px;flex-wrap:wrap}.q-num{min-width:35px;height:37px;font-size:16px}.q-body{flex-basis:calc(100% - 50px)}.q-status{margin-left:45px;flex:1}.question .secondary{padding:6px 13px}.steps{grid-template-columns:1fr;gap:10px}.steps article{padding:20px}.steps h3{margin:7px 0}.source p{font-size:10px}footer{padding:17px 20px;flex-wrap:wrap;gap:8px}footer span{font-size:9px}dialog{padding:24px 20px}dialog h2{font-size:18px}}

[hidden]{display:none!important}.account-content{padding:28px;max-width:500px}.account-content p{line-height:1.9}.account-actions{display:flex;gap:12px;margin:16px 0}#account-resolve{border:1px solid #d8dfd8;border-radius:8px;padding:16px;margin:16px 0}.topbar{gap:12px}.topbar #today{margin-left:auto}.local-badge{white-space:normal}#account-dialog .close{position:absolute;right:12px;top:10px}@media(max-width:600px){.topbar{flex-wrap:wrap}.account-content{padding:20px}.page-heading{flex-wrap:wrap;gap:12px}}

/* Short study sessions and interruption feedback. */
#resume-summary{font-size:.9rem;max-width:38rem}.recall{background:#f0f5ef;padding:16px;border-radius:12px;margin:16px 0}#recall-note{white-space:pre-wrap;overflow-wrap:anywhere}#pause-study{display:block;width:100%;margin:16px 0}#draft-status{min-height:2.5em}dialog button{min-height:44px}

#email-auth input,#password-recovery input{box-sizing:border-box;width:100%;min-width:0;padding:12px;border:1px solid #ced9d2;border-radius:8px;font:inherit}#email-auth-message{white-space:pre-wrap;overflow-wrap:anywhere}#email-auth,#password-recovery{margin:20px 0}#email-reset{display:block;margin-top:12px}.field[hidden]{display:none}


/* Mobile layout: readable text, reachable controls, and usable short-screen dialogs. */
@media (max-width: 1120px) {
  .topbar, .page-heading > div, .hero > div:first-child {min-width:0}
  .primary,.secondary,.ghost,nav a,#review-list button {min-height:44px}
  input,select,textarea {font-size:16px}
  .filters label, .stats article, .steps article {min-width:0}
  .account-content {max-width:none;padding:0}
  #account-profile, #account-modal-status, #account-resolve, .source a {overflow-wrap:anywhere}
}
@media (max-width: 760px) {
  body {font-size:15px;line-height:1.75}
  html {scroll-padding-top:16px}
  .sidebar {padding:16px max(16px,env(safe-area-inset-right)) 12px max(16px,env(safe-area-inset-left))}
  nav {display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:6px;overflow:visible;margin-top:14px}
  nav a, nav a:last-child {display:block;min-height:44px;padding:10px 8px;font-size:13px;white-space:normal}
  .topbar {height:auto;min-height:56px;padding:10px 16px;display:grid;grid-template-columns:minmax(0,1fr) auto;gap:6px 10px}
  .topbar > span:first-child {font-size:12px;grid-column:1/-1}
  .topbar #today {margin-left:0;font-size:12px}
  #account-button {max-width:100%;min-width:0;overflow-wrap:anywhere}
  main {padding:22px max(16px,env(safe-area-inset-right)) 32px max(16px,env(safe-area-inset-left))}
  .page-heading {gap:12px;margin-bottom:20px}
  .page-heading p:last-child {font-size:14px}
  .local-badge {display:block;font-size:12px;max-width:100%}
  h1 {font-size:clamp(22px,6vw,28px);line-height:1.5}
  .hero {padding:24px 20px;min-height:0}
  .hero h2 {font-size:clamp(24px,6.6vw,30px);letter-spacing:.04em}
  .hero p {font-size:14px;max-width:none}
  .pill {font-size:11px}
  .hero .primary {width:100%;margin-top:10px}
  #resume-summary {font-size:13px;margin:14px 0 0;overflow-wrap:anywhere}
  .primary,.secondary,.ghost {font-size:14px;min-height:44px;padding:11px 14px;line-height:1.5;white-space:normal}
  .stats {grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;margin:18px 0 24px}
  .stats article {padding:14px 12px}
  .stats article>span,.stats article>small {font-size:12px}
  .stats strong {font-size:27px;line-height:1.5}
  .review-panel {padding:20px 16px}
  .review-panel h2 {font-size:19px}
  .review-panel p:last-child {font-size:14px}
  #review-start {width:100%}
  #review-list {display:grid;grid-template-columns:repeat(2,minmax(0,1fr))}
  #review-list button {min-height:44px;font-size:13px;padding:10px 8px}
  .section-heading {flex-wrap:wrap;gap:4px}
  .section-heading>.muted {font-size:12px;margin-top:0;white-space:normal}
  .section-help,.muted,.source p,.steps p {font-size:14px}
  .filters {display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;padding:14px}
  .filters .search-label {grid-column:1/-1;min-width:0}
  .filters label,.filters label:not(.search-label) {min-width:0;font-size:13px}
  .filters label:last-child {grid-column:1/-1}
  .filters input,.filters select,.field select,.field textarea,#email-auth input,#password-recovery input {font-size:16px;min-height:48px;width:100%;min-width:0;padding:11px 10px}
  .list-caption {font-size:12px;align-items:start;gap:10px}
  .list-caption span:last-child {max-width:60%;text-align:right}
  .question {display:grid;grid-template-columns:36px minmax(0,1fr);gap:10px;padding:16px 12px}
  .q-num {min-width:0;width:36px;align-self:start}
  .q-body {min-width:0}
  .q-body h3 {font-size:16px;line-height:1.6}
  .q-meta {font-size:12px;gap:4px 10px}
  .q-status {grid-column:2;white-space:normal;font-size:13px;margin:0;overflow-wrap:anywhere}
  .question .secondary {grid-column:1/-1;width:100%;font-size:14px;min-height:44px;padding:11px 14px}
  .pagination {gap:12px;font-size:13px;justify-content:space-between}
  .pagination button {flex:1;max-width:140px}
  .steps article {padding:20px 16px}
  .steps span {font-size:12px}
  .steps h3 {font-size:17px}
  .source strong {font-size:15px}
  footer {padding:20px 16px calc(20px + env(safe-area-inset-bottom));gap:10px;align-items:start}
  footer span,footer a {font-size:12px}
  footer a {min-height:44px;padding:10px 0}
  #guide>.ghost,#guide>.import-label {width:100%;margin-top:14px}
  .import-label {font-size:14px;padding:12px;border:1px solid var(--line);border-radius:8px;background:#fff}
  .import-label input {font-size:16px;margin-top:10px;width:100%}
  dialog {width:calc(100% - 24px);max-width:570px;max-height:calc(100dvh - 24px - env(safe-area-inset-top) - env(safe-area-inset-bottom));padding:26px 18px 20px;overflow-y:auto;overscroll-behavior:contain;scroll-padding:16px}
  dialog h2 {font-size:21px;overflow-wrap:anywhere}
  dialog .close {width:44px;height:44px;top:4px;right:4px;padding:0;line-height:1}
  dialog .eyebrow {padding-right:28px}
  dialog .primary,dialog .secondary,dialog .ghost {width:100%;margin-top:10px}
  dialog .field,dialog legend {font-size:14px}
  fieldset {padding:10px 12px}
  fieldset label {display:flex;align-items:center;gap:10px;min-height:48px;font-size:15px;margin:2px 0}
  fieldset input[type=radio] {width:22px;height:22px;flex:0 0 auto;margin:0;accent-color:var(--green)}
  .account-content {padding:0;max-width:none}
  .account-actions {flex-direction:column;gap:0}
  #account-resolve {padding:12px;overflow-wrap:anywhere}
  #notice:not(:empty) {font-size:14px;padding:12px;overflow-wrap:anywhere}
  #memo-details summary {font-size:15px;min-height:44px;padding:10px 0;cursor:pointer}
}
@media (max-width:420px) {.hero-art{display:none}.list-caption{flex-wrap:wrap}.list-caption span:last-child{max-width:none;text-align:left}footer span{flex-basis:100%}}
@media (prefers-reduced-motion:reduce) {html{scroll-behavior:auto}}

/* Question-specific AI support. */
#ai-dialog{width:min(680px,calc(100% - 24px))}#ai-dialog p{overflow-wrap:anywhere}#ai-title{padding-right:28px}.ai-message{padding:16px;border:1px solid var(--line);border-radius:10px;margin:14px 0;background:#f3f7f2}.ai-message.user{background:#fff}.ai-message p{white-space:pre-wrap;margin:8px 0 0}.ai-message a{overflow-wrap:anywhere;text-decoration:underline}.ai-quick,.ai-actions{display:flex;flex-wrap:wrap;gap:8px;margin:16px 0}.ai-consent{display:flex;align-items:flex-start;gap:10px;font-size:14px}.ai-consent input{flex:0 0 auto;width:22px;height:22px;margin:4px 0}#ai-status{white-space:pre-wrap;font-size:14px}#ai-keep{border-top:1px solid var(--line);margin-top:20px;padding-top:20px}#open-ai{margin:14px 0}@media(max-width:760px){#ai-dialog{padding:26px 18px 20px}.ai-message{padding:12px}.ai-message p{font-size:15px}.ai-quick{gap:6px}.ai-quick button{width:auto;flex:1 1 40%;margin:0;font-size:13px}.ai-actions{display:block}.ai-consent{font-size:14px}}

.learning-context,.storage-guide{padding:24px;background:#fff;border:1px solid var(--line);border-radius:16px;margin:24px 0}.context-header,.context-actions{display:flex;align-items:center;gap:12px;flex-wrap:wrap}.context-header{justify-content:space-between}.context-header h2{font-size:22px}.context-header label{display:flex;flex-direction:column;gap:6px;font-size:13px}.context-header select{min-height:44px;max-width:100%}.context-actions a{display:inline-flex;align-items:center;justify-content:center;min-height:48px;text-decoration:none}.storage-guide h2{font-size:21px}.storage-guide dl{display:grid;grid-template-columns:1fr 1fr;gap:20px}.storage-guide dt{font-weight:700}.storage-guide dd{margin:8px 0;line-height:1.8}.storage-guide p,#stage-tip{line-height:1.8}@media(max-width:600px){.learning-context,.storage-guide{padding:18px}.context-header{display:block}.context-header select{width:100%;font-size:16px}.context-actions a{width:100%;box-sizing:border-box}.storage-guide dl{grid-template-columns:1fr;gap:8px}}
