/* Calm Classic — full app refinement. Keeps the existing app structure and behaviour intact. */
:root{--cc-forest:#175e50;--cc-forest-deep:#104c40;--cc-cream:#fbf7f0;--cc-paper:#fffdf9;--cc-line:#e9e0d4;--cc-ink:#302832;--cc-muted:#786f6b;--cc-mint:#e2f0e4;--cc-shadow:0 12px 34px rgba(48,40,50,.065)}
html{background:var(--cc-cream)}
body{background:var(--cc-cream);color:var(--cc-ink)}
.app{grid-template-columns:248px minmax(0,1fr);background:var(--cc-cream)}
.side{background:linear-gradient(165deg,#1c6b59 0%,#155849 58%,#104c40 100%);padding:26px 18px 22px;box-shadow:8px 0 30px rgba(22,63,51,.07)}
.brand{padding:2px 8px 34px;font-size:25px;letter-spacing:-.045em}
.brand img{width:44px;height:44px;border-radius:14px;box-shadow:0 5px 15px rgba(0,0,0,.12)}
.side .nav{gap:7px}
.nav-btn{min-height:50px;padding:12px 14px;border:1px solid transparent;border-radius:15px;color:#e8f3ec;font-size:15px;font-weight:800;letter-spacing:-.01em}
.nav-btn:hover{background:rgba(255,255,255,.1);transform:translateX(2px)}
.nav-btn.active{background:#e7f1e5;border-color:#d2e6d4;color:#195b4b;box-shadow:0 4px 14px rgba(8,43,34,.13)}
.nav-btn.active svg{color:#26735d}
.nav-btn svg{width:21px;height:21px;opacity:.96}
.help-card{margin-top:auto;border:1px solid rgba(255,255,255,.16);background:rgba(255,255,255,.09);border-radius:18px;padding:14px}
.help-card strong{font-size:14px}
.help-card span{line-height:1.35}
.side-back{margin:17px 6px 0;color:#d7e8df;font-size:12px;font-weight:800;opacity:.85}
.main{min-width:0}
.topbar{min-height:78px;padding:14px clamp(22px,3.4vw,52px);gap:10px;border-bottom:1px solid rgba(226,216,203,.8);background:rgba(255,253,249,.91);backdrop-filter:blur(16px)}
.topbar:before{content:"";flex:1;order:0}
.topbar .mbrand{order:-1}
.topbar #status-txt{order:0}
.topbar #acct-pill,.topbar #edit-pill,.topbar button[onclick*="settings"]{order:1}
.pill{min-height:44px;padding:10px 15px;border:1px solid #e8dfd2;border-radius:13px;background:#fffefa;color:#31584c;font-size:13px;font-weight:900;box-shadow:0 2px 5px rgba(48,40,50,.025)}
.pill:hover{background:#f5f8f2;border-color:#cbdccf}
.pill.on{background:#e6f2e7;border-color:#b9d8bf;color:#175e50}
.content{max-width:1440px;padding:34px clamp(22px,3.4vw,52px) 72px}
.edit-banner{margin:0 0 20px;padding:13px 16px;border:1px solid #d6e5d2;border-radius:16px;background:#edf5e9;color:#285b4b;font-size:13px;line-height:1.5}
.edit-banner>span{color:#286c55}
.edit-banner button{padding:7px 12px;border-radius:10px;background:#dcebd9;color:#225c4a;text-decoration:none;white-space:nowrap}
.words{min-height:96px;gap:17px;padding:17px 18px;border:1px solid #eadfce;border-radius:22px;background:#f6ecd9;box-shadow:0 5px 18px rgba(107,82,45,.055)}
.words .bubble{width:54px;height:54px;border-radius:16px}
.words .eyebrow{margin-bottom:3px;color:#527260;font-size:10px;letter-spacing:.13em}
.words-line{color:#342c32;font-size:21px;font-weight:900;line-height:1.25}
.words-line.is-empty{color:#81766e;font-size:16px;font-weight:700}
.words .btn-speak{min-height:48px;padding:12px 19px;border-radius:14px;background:#175e50;box-shadow:0 4px 10px rgba(23,94,80,.14);font-size:14px}
.words .btn-clear{width:40px;height:40px;border-radius:12px;color:#756b63}
.free-compose{grid-template-columns:minmax(0,1fr) auto;gap:12px 18px;margin-top:14px;padding:16px 18px;border:1px solid #e8e2d9;border-radius:20px;background:rgba(255,255,255,.72);box-shadow:none}
.free-compose-copy{grid-column:1/-1;gap:11px}
.free-compose-icon{width:36px;height:36px;border-radius:12px;background:#e8f1e6}
.free-compose h2{font-size:16px;color:#35594b}
.free-compose p{font-size:12px;color:#817873}
.free-compose textarea{min-height:52px;border:1px solid #e6dfd5;border-radius:13px;background:#fffefa;font-size:15px}
.free-compose .btn-speak{min-height:48px;padding:10px 16px;border-radius:13px;font-size:13px}
.compose-hint{color:#8a8079;font-size:11px}
.sec-head{align-items:flex-end;margin:38px 0 20px}
.sec-head h1{margin-top:5px;color:#2f2930;font-size:clamp(32px,3.1vw,42px);font-weight:900;letter-spacing:-1.6px;line-height:1.08}
.sec-head .eyebrow{color:#34725d;font-size:11px;letter-spacing:.13em}
.sec-head .tools{gap:7px}
.chip{padding:9px 14px;border:1px solid #e5ddd1;border-radius:999px;background:#fffefa;color:#756d67;font-size:12px}
.chip.active{border-color:#175e50;background:#175e50;color:#fff}
.grid{grid-template-columns:repeat(4,minmax(0,1fr));gap:17px}
.card{min-height:204px;gap:13px;padding:20px 14px 17px;border:1px solid color-mix(in srgb,var(--b) 55%,#e8e0d6);border-radius:23px;background:linear-gradient(155deg,var(--bg),color-mix(in srgb,var(--bg) 84%,#fff));box-shadow:0 3px 0 rgba(65,53,42,.035),0 8px 20px rgba(48,40,50,.035);transition:transform .18s ease,box-shadow .18s ease,border-color .18s ease}
.card:hover{transform:translateY(-3px);box-shadow:0 12px 25px rgba(48,40,50,.09)}
.card:focus-visible{outline:3px solid #4b9476;outline-offset:3px}
.card.sel{border-color:#36836d;box-shadow:0 0 0 3px rgba(54,131,109,.18),0 10px 22px rgba(48,40,50,.08)}
.card .tile{width:92px;height:92px;border-radius:25px;background:rgba(255,255,255,.64);font-size:47px}
.card .tile svg{width:43px;height:43px;stroke-width:1.85}
.card .photo{width:100%;aspect-ratio:5/3;border-radius:17px;background:rgba(255,255,255,.6)}
.card .photo img{object-fit:cover}
.card.has-photo{gap:12px;padding:12px 12px 15px}
.card.has-photo .lbl{font-size:17px}
.card .lbl{font-size:19px;font-weight:900;letter-spacing:-.3px;line-height:1.18}
.card-btn{width:38px;height:38px;top:11px;background:rgba(255,253,249,.95);color:#416c59;box-shadow:0 2px 8px rgba(40,35,30,.1)}
.card-btn svg{width:17px;height:17px}
.card-btn.snd{right:11px}
.card-btn.fav{left:11px}
.card-btn.edit{right:56px;background:#175e50;color:#fff}
.card.add{min-height:204px;border:1.5px dashed #b7c9b7;background:rgba(255,255,255,.32);box-shadow:none}
.card.add .tile{background:#e9f2e6;color:#38735c}
.card.add .lbl{color:#4c7560;font-size:16px}
.empty{grid-column:1/-1;padding:30px;border:1px dashed #c6d5c3;border-radius:18px;background:#fffefa;color:#746d66;text-align:center}
.panel{border:1px solid #e9e1d7;border-radius:22px;background:#fffefa;box-shadow:0 7px 24px rgba(48,40,50,.045)}
.panel h2{color:#315a4b}
.settings{gap:18px}
.srow{border-color:#eee7dd}
.visual-timer{border:1px solid #e8e0d5;border-radius:24px;background:#fffefa;box-shadow:0 8px 24px rgba(48,40,50,.045)}
.timer-state{background:#f4f1eb}
.timer-countdown{color:#175e50;font-variant-numeric:tabular-nums}
.timer-progress{background:#edf0e9}
.timer-progress span{background:linear-gradient(90deg,#a8d3ad,#4c9674)}
.timer-preset{border-color:#dce7da;background:#fffefa;color:#315d4b}
.timer-preset.active{border-color:#175e50;background:#175e50;color:white}
.sheet{border:1px solid #eee5da;border-radius:26px;background:#fffefa;box-shadow:0 30px 90px rgba(30,43,36,.24)}
.sheet h2{color:#2f493e}
.field input,.field select,.field textarea{border:1px solid #ddd6cc;border-radius:12px;background:#fffefa}
.drop{border:1.5px dashed #afc8b4;border-radius:17px;background:#f5f8f1}
.preview{border:1px solid #e8e0d5;border-radius:15px;background:#faf8f3}
.bnav{background:#175e50;box-shadow:0 -8px 28px rgba(22,63,51,.12)}
.bnav button{border-radius:12px}
.bnav button.active{background:#e7f1e5;color:#195b4b}
button,a{-webkit-tap-highlight-color:transparent}
@media(min-width:1500px){.grid{grid-template-columns:repeat(4,minmax(0,1fr));gap:20px}.card{min-height:218px}}
@media(max-width:1200px) and (min-width:861px){.app{grid-template-columns:220px minmax(0,1fr)}.content{padding-left:28px;padding-right:28px}.grid{grid-template-columns:repeat(3,minmax(0,1fr))}.card{min-height:190px}}
@media(max-width:860px){
 .app{grid-template-columns:minmax(0,1fr)}
 .topbar{min-height:66px;padding:calc(10px + env(safe-area-inset-top)) 14px 10px;gap:7px}
 .topbar:before{display:none}
 .mbrand{font-size:20px}
 .content{padding:18px 16px 116px}
 .words{gap:9px;padding:12px;border-radius:18px}
 .words .bubble{width:42px;height:42px;border-radius:12px}
 .words-txt{min-width:0}
 .words-line{font-size:18px}
 .free-compose{grid-template-columns:minmax(0,1fr);padding:14px;gap:10px}
 .free-compose-copy{grid-column:1}
 .free-compose textarea{min-height:54px}
 .free-compose .btn-speak{width:100%}
 .compose-hint{grid-column:1}
 .sec-head{margin:28px 0 16px}
 .sec-head h1{font-size:31px}
 .grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
 .card{min-height:174px;padding:15px 10px 13px;border-radius:19px}
 .card .tile{width:74px;height:74px;border-radius:20px;font-size:39px}
 .card .tile svg{width:36px;height:36px}
 .card .lbl{font-size:16px}
 .card.has-photo{padding:10px 9px 12px}
 .card.has-photo .lbl{font-size:15px}
 .card-btn{width:34px;height:34px;top:8px}
 .card-btn.snd{right:8px}.card-btn.fav{left:8px}.card-btn.edit{right:48px}
 .card.add{min-height:174px}
 .edit-banner{align-items:flex-start;font-size:12px;flex-wrap:wrap}
 .edit-banner button{margin-left:auto}
 .visual-timer-grid{grid-template-columns:1fr}
}
@media(max-width:380px){.content{padding-left:12px;padding-right:12px}.grid{gap:9px}.card{min-height:158px}.card .tile{width:66px;height:66px}.card .lbl{font-size:15px}}
@media(prefers-reduced-motion:reduce){.card,.nav-btn{transition:none}.card:hover,.nav-btn:hover{transform:none}}

/* Custom area manager */
.edit-banner{justify-content:flex-start}
.edit-banner-copy{flex:1;min-width:220px}
.edit-banner-actions{display:flex;align-items:center;gap:7px;flex-wrap:wrap;margin-left:auto}
.edit-banner-actions button{margin:0;padding:8px 11px;border:1px solid #cfe0cc;border-radius:10px;background:#f8fbf5;color:#285d4a;font-size:12px;font-weight:900;text-decoration:none}
.edit-banner-actions button:last-child{background:#dcebd9}
.area-manage-row{display:flex;align-items:center;gap:8px;padding:12px 0;border-bottom:1px solid #eee8df}
.area-manage-row:last-child{border-bottom:0}
.area-manage-icon{display:grid;width:38px;height:38px;flex:0 0 38px;place-items:center;border-radius:12px;background:#e9f2e6;color:#286d55}
.area-manage-icon svg{width:19px;height:19px}
.area-manage-name{display:flex;min-width:0;flex:1;flex-direction:column;gap:2px}
.area-manage-name b{overflow:hidden;color:#344d40;font-size:14px;text-overflow:ellipsis;white-space:nowrap}
.area-manage-name small{color:#8a8078;font-size:11px;font-weight:700}
.area-move,.area-edit,.area-delete{display:grid;min-width:34px;height:34px;place-items:center;border:1px solid #e6e1d8;border-radius:10px;background:#fffefa;color:#426b57;font-size:14px;font-weight:900}
.area-move:disabled{opacity:.3;cursor:not-allowed}
.area-edit{padding:0 11px;font-size:12px}
.area-delete{color:#9c5b53}
.area-manager-intro{margin:-6px 0 16px;color:#786f69;font-size:13px;line-height:1.55}
.area-manage-list{max-height:44vh;overflow:auto;padding:0 2px}
.area-empty{padding:18px;border:1px dashed #cbd9c7;border-radius:14px;background:#f7f9f4;color:#6e786b;font-size:13px;line-height:1.5}
.area-icon-picker{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:8px}
.area-icon-picker button{display:grid;min-height:48px;place-items:center;border:1px solid #e7e1d8;border-radius:12px;background:#fffefa;color:#597064}
.area-icon-picker button svg{width:21px;height:21px}
.area-icon-picker button.on{border-color:#4b9676;background:#eaf3e8;color:#175e50;box-shadow:0 0 0 2px #d6e8d5}
.area-add{border-color:#c8ddca;color:#2c7258}
@media(max-width:860px){
 .edit-banner-actions{width:100%;margin-left:0}
 .edit-banner-actions button{flex:1}
 .area-manage-row{gap:5px}
 .area-manage-icon{width:34px;height:34px;flex-basis:34px}
 .area-move,.area-edit,.area-delete{min-width:30px;height:32px}
}
