:root{font-family:system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;color:#37323d;background:#faf7f0;font-synthesis:none}
*{box-sizing:border-box}
[hidden]{display:none!important}
body{margin:0;height:100vh;height:100svh;min-height:540px;display:grid;grid-template-rows:auto minmax(0,1fr) auto}
header{width:100%;max-width:1200px;margin:auto;padding:24px 40px;display:flex;justify-content:space-between;gap:20px;align-items:center}
.brand{display:inline-flex;align-items:center;gap:10px;text-decoration:none;color:#37323d;font-size:28px;font-weight:750;letter-spacing:-1.2px}
.brand-icon{font:italic 40px Georgia,serif;width:46px;height:49px;background:#725197;color:#fff6e4;border-radius:15px 14px 16px 6px;display:grid;place-items:center;transform:rotate(-6deg);position:relative}
.brand-icon small{position:absolute;right:-6px;top:-7px;font:21px Georgia;color:#dc8c50}
.dot{color:#dc8c50;margin-left:-9px}
.family-badge{font-size:12px;color:#756782;border:1px solid #e5dbea;padding:6px 12px;border-radius:20px}
main{width:100%;max-width:1120px;min-height:0;padding:0 40px;margin:auto;height:100%;display:grid;grid-template-rows:minmax(0,1fr) auto;gap:18px}
.welcome-content{min-height:0;display:grid;grid-template-columns:1fr 1.2fr;gap:35px;align-items:center}
.welcome-copy{padding-bottom:16px}
.eyebrow{font-size:10px;font-weight:700;letter-spacing:1.7px;color:#846291;margin:0 0 16px}
h1{font:clamp(46px,5.2vw,70px)/1.08 Georgia,serif;letter-spacing:-2.2px;margin:0 0 20px}
h1 em{color:#725197;font-weight:400}
.intro{font-size:16px;color:#746b73;line-height:1.75;margin:0}
.story-example{height:100%;max-height:470px;min-height:0;min-width:0;margin:0;display:flex;flex-direction:column;justify-content:center;align-items:center;text-align:center}
.story-example>span{flex-shrink:0;font-size:10px;letter-spacing:1.6px;color:#827184;font-weight:600}
.story-example strong{color:#725197;font-weight:750}
.story-cartoon{display:block;flex:0 1 auto;min-height:0;width:100%;height:auto;max-height:calc(100% - 90px);object-fit:contain;margin:8px 0}
figcaption{flex-shrink:0;width:100%}
.story-example p{font:clamp(21px,2.1vw,28px)/1.5 Georgia,serif;margin:0 0 5px}
.story-example p span{display:inline-block}
.story-example b{color:#725197;text-decoration:underline;text-underline-offset:4px;font-weight:700}
.story-example small{font-size:11px;color:#827184}
.login-panel{text-align:center;padding:0 0 8px}
.login-panel h2{font:21px/1.3 Georgia,serif;margin:0 0 12px;color:#57445e}
#google-signin-form{position:relative;display:flex;justify-content:center;align-items:center;gap:12px;margin:0 auto;max-width:360px}
.google-button,.open-workspace{display:flex;align-items:center;justify-content:center;gap:28px;width:100%;min-height:52px;padding:13px 24px;border:0;border-radius:14px;background:#725197;color:#fff;font:600 16px/1.5 system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;box-shadow:0 3px 0 #5c3e79;cursor:pointer;text-decoration:none;transition:background .15s ease}
.google-button:hover:not(:disabled),.open-workspace:hover{background:#684588}
.google-button:disabled{cursor:wait;opacity:.6}
.google-button>span:last-child{font-size:22px;line-height:1}
.login-panel .login-explanation{font-size:11px;line-height:1.5;margin:12px 0 0;color:#776879}
.login-spinner{display:none;position:absolute;right:18px;width:18px;height:18px;border:2px solid #c8b3da;border-top-color:#fff;border-radius:50%;pointer-events:none}
.signing-in .login-spinner{display:block;animation:login-spin .8s linear infinite}
.signing-in .google-button>span:last-child{visibility:hidden}
#login-status{font-size:12px;line-height:1.5;overflow-wrap:anywhere;max-width:480px;margin:10px auto 0;color:#64566e}
#login-status:empty{display:none}
#login-status[data-kind=error]{color:#8b344e}
.login-retry{font:inherit;font-size:13px;min-height:44px;padding:8px 18px;color:#684883;background:transparent;border:0;text-decoration:underline;text-underline-offset:3px;cursor:pointer}
.open-workspace{max-width:360px;margin:0 auto 12px}
footer{text-align:center;font-size:10px;color:#827184;padding:10px 24px max(14px,env(safe-area-inset-bottom))}
a:focus-visible,button:focus-visible{outline:3px solid #bb99d1;outline-offset:4px}
@keyframes login-spin{to{transform:rotate(360deg)}}
@media(max-width:760px){
  body{min-height:540px}
  header{padding:18px 24px}
  .brand{font-size:24px;gap:8px}
  .brand-icon{width:35px;height:38px;border-radius:12px 11px 12px 5px;font-size:31px}
  .brand-icon small{font-size:17px}
  .family-badge{font-size:10px;padding:5px 8px}
  main{padding:0 24px;gap:16px;max-width:500px}
  .welcome-content{display:flex;flex-direction:column;gap:14px;text-align:center}
  .welcome-copy{flex-shrink:0;padding:0}
  .eyebrow{font-size:8px;letter-spacing:1.3px;margin-bottom:10px}
  h1{font-size:clamp(32px,8.5vw,43px);letter-spacing:-1.2px;line-height:1.1;margin-bottom:12px}
  .desktop-break{display:none}
  .intro{font-size:13px;line-height:1.65}
  .story-example{flex:1;width:100%;max-height:none}
  .story-example>span{font-size:9px;letter-spacing:1.3px}
  .story-cartoon{margin:4px 0}
  .story-example p{font-size:clamp(20px,5.2vw,23px);line-height:1.3;margin-bottom:5px;max-width:340px;margin-inline:auto}
  .story-example small{font-size:10px}
  .login-panel{padding:0}
  .login-panel h2{font-size:18px;margin-bottom:10px}
  .google-button,.open-workspace{min-height:50px;font-size:15px}
  .login-panel .login-explanation{font-size:10px;margin-top:10px}
  footer{font-size:9px;padding-top:10px}
}
@media(max-width:760px) and (max-height:680px){
  header{padding:14px 20px}
  main{gap:12px;padding-inline:20px}
  .welcome-content{gap:10px}
  .eyebrow{margin-bottom:7px}
  h1{font-size:32px;margin-bottom:8px}
  .intro{font-size:12px;line-height:1.5}
  .story-example p{font-size:21px;max-width:280px}
  .login-panel h2{font-size:16px;margin-bottom:8px}
  footer{padding-block:8px max(10px,env(safe-area-inset-bottom))}
}
@media(min-width:761px) and (max-height:650px){
  header{padding-block:16px}
  h1{font-size:48px;margin-bottom:14px}
  .eyebrow{margin-bottom:12px}
  .intro{font-size:14px}
  main{gap:10px}
}
@media(min-width:761px) and (max-height:500px){
  body{min-height:360px}
  header{padding-block:10px}
  .brand-icon{width:35px;height:38px;font-size:31px}
  .brand{font-size:24px}
  h1{font-size:30px;letter-spacing:-1px;margin-bottom:8px}
  .desktop-break{display:none}
  .welcome-copy{padding:0}
  .eyebrow{font-size:8px;margin-bottom:8px}
  .intro{font-size:12px;line-height:1.5}
  .story-example p{font-size:20px}
  .story-example>span{font-size:8px}
  .story-example small{font-size:10px}
  .story-cartoon{max-height:calc(100% - 65px);margin:4px 0}
  .login-panel h2{font-size:16px;margin-bottom:8px}
  .google-button{min-height:46px;padding-block:10px;font-size:14px}
  .login-panel .login-explanation{margin-top:8px;font-size:10px}
  .login-panel{padding:0}
  footer{padding-block:8px;font-size:9px}
}
@media(max-width:760px) and (max-height:500px){body{min-height:360px}header{padding-block:10px}main{gap:8px}.welcome-content{display:grid;grid-template-columns:1fr 1fr;align-items:center}.story-example{height:100%}h1{font-size:28px}.eyebrow{font-size:7px}.intro{font-size:11px}.story-example p{font-size:18px}.story-example small{display:none}.story-cartoon{max-height:calc(100% - 65px)}.login-panel h2{font-size:16px;margin-bottom:6px}.google-button{min-height:46px;padding-block:10px}.login-panel .login-explanation{margin-top:8px}footer{padding-block:8px}}
@media(prefers-reduced-motion:reduce){.google-button{transition:none}.signing-in .login-spinner{animation:none}}
