#bag-relic { grid-column:1/-1;min-height:0; }
#bag-relic>h2 { margin:4px 0 8px;font-size:20px; }
.relic-layout { display:grid;grid-template-columns:minmax(140px,.65fr) minmax(0,1.35fr);align-items:center;gap:22px;min-height:190px;padding:12px 20px;border:1px solid #b5bdc6;border-radius:16px;background:linear-gradient(125deg,#eef2f4,#d2d9df,#f6f1dd); }
#relic-art { display:grid;place-items:center; }
#relic-art canvas { width:min(170px,100%);height:auto;filter:drop-shadow(0 0 7px #92e3ed) drop-shadow(0 0 10px #bd9de7); }
.relic-layout h3 { margin:0 0 8px;font-size:22px; }
.relic-layout p { font-size:13px;line-height:1.5;margin:7px 0; }
.relic-layout button { min-height:38px;font-size:13px; }
.school-day-status { margin:5px 0 0;font-size:11px;color:#ffe7a2;max-width:210px;line-height:1.4; }
#world[data-area="alien"] .world-prompt { top:66px;max-width:40%; }
#classroom-dialog,#alien-shop-dialog { box-sizing:border-box;width:min(860px,95vw);max-width:95vw;max-height:94dvh;overflow:hidden;border-radius:18px;padding:12px 16px; }
#classroom-dialog { background:#f3e5c8;border:2px solid #799583;color:#26433d; }
#classroom-dialog::backdrop,#alien-shop-dialog::backdrop { background:#152b2bbc;backdrop-filter:blur(4px); }
#classroom-dialog header,#classroom-dialog footer,#alien-shop-dialog header { display:flex;justify-content:space-between;align-items:center;gap:12px; }
#classroom-dialog h2,#alien-shop-dialog h2 { margin:0;font-size:22px; }
#classroom-dialog header button,#alien-shop-dialog header button { min-height:34px;padding:5px 12px;font-size:12px;white-space:nowrap; }
.classroom-layout { display:grid;grid-template-columns:minmax(0,2fr) minmax(155px,.9fr);gap:14px;margin:10px 0; }
.classroom-board { display:flex;flex-direction:column;justify-content:center;background:linear-gradient(120deg,#244c43,#355c4f);color:#fff6dd;border:5px solid #a37d54;border-radius:10px;padding:15px;min-height:190px;box-shadow:inset 0 0 25px #102b2666; }
#classroom-subject { color:#ffe7a7;margin:0;font-size:17px; }
#classroom-copy { font-size:15px;line-height:1.6;margin:12px 0; }
#classroom-options { display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:7px; }
#classroom-options button { font-size:12px;min-height:43px;padding:6px;background:#52776a;color:#fff8dd;border-color:#b9c8a4;line-height:1.35; }
#classroom-options button.correct { background:#d0e6a4;color:#28463b;border-color:#e8eabb; }
.classroom-layout aside { align-self:center; }
#classroom-teacher .portrait { width:72px;margin:0 auto 8px; }
#classroom-teacher canvas { width:72px;height:72px;border-radius:15px; }
#classroom-teacher figcaption { display:none; }
#classroom-feedback { font-size:12px;line-height:1.6;margin:0; }
#classroom-dialog footer { font-size:12px;color:#617a62; }
#classroom-next { min-height:38px;font-size:13px;padding:6px 14px; }
#alien-shop-dialog { background:linear-gradient(130deg,#252e42,#443954);color:#f4eadc;border:2px solid #9b8dbc; }
#alien-shop-balance { margin:5px 0 0;color:#b6e9df;font-size:12px; }
#alien-shop-dialog header .quiet { background:#51596e;color:#fff2cf;border-color:#a1afbc; }
#alien-shop-tabs { display:flex;gap:8px;margin:9px 0; }
#alien-shop-tabs button { min-height:33px;padding:4px 15px;font-size:12px;color:#e4e6d2;background:#45485c;border-color:#8892a2; }
#alien-shop-tabs button[aria-pressed="true"] { background:#718c83;color:#fff6df;border-color:#c8e3c6; }
#alien-shop-items { display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px; }
#alien-shop-items .stock-item { min-height:172px;padding:9px;display:flex;flex-direction:column;gap:4px;background:#343d51;border-color:#798496;color:#f5eddd;border-radius:12px; }
.alien-item-symbol { font-size:22px;color:#a8f2d6;line-height:1; }
#alien-shop-items h3 { font-size:16px;margin:0; }
#alien-shop-items .stock-kind { font-size:10px;color:#bed6db; }
#alien-shop-items .stock-effect { font-size:12px;line-height:1.4;margin:2px 0;flex:1;color:#d1dce0; }
#alien-shop-items button { min-height:35px;padding:4px 10px;font-size:12px;align-self:start; }
#alien-shop-notice { margin:8px 0 0;font-size:11px;color:#d5ddd0;line-height:1.35; }
.android-app #story-heading { font-size:clamp(23px,3.8vw,36px); }
@media (max-height:380px) and (orientation:landscape) {
  #classroom-dialog,#alien-shop-dialog { padding:9px 12px; }
  #classroom-dialog h2,#alien-shop-dialog h2 { font-size:19px; }
  .classroom-board { padding:10px;min-height:170px; }
  #classroom-copy { font-size:13px; }
  #alien-shop-items .stock-item { min-height:155px; }
  .relic-layout { min-height:160px;padding:8px 14px; }
  #relic-art canvas { width:140px; }
}
@media (max-width:600px) and (orientation:portrait) {
  .classroom-layout,.relic-layout { grid-template-columns:1fr; }
  #alien-shop-items { grid-template-columns:1fr;max-height:55dvh;overflow:auto; }
  #classroom-teacher { display:none; }
}
