/* Coo (Smart Living): the Coo app on the web.
   Built on the site variables, so it follows both the light theme (style.css) and the dark glass theme.
   Soft tints are translucent, so they read on white and on the dark glass alike. */

.coo-shell{ max-width:880px; margin:0 auto; }
.coo-app{
  background:var(--white); border:1px solid var(--line); border-radius:var(--radius-lg);
  box-shadow:var(--shadow-soft); padding:22px 26px 30px; min-height:520px;
}
@media (max-width:600px){ .coo-app{ padding:16px 16px 24px; border-radius:var(--radius-md); } }
.coo-app .sr-only{ position:absolute; width:1px; height:1px; overflow:hidden; clip:rect(0 0 0 0); white-space:nowrap; }
.coo-app a{ text-decoration:none; color:inherit; }
.coo-app small{ display:block; color:var(--muted); font-size:0.84rem; line-height:1.45; }
.coo-app b{ color:var(--forest); font-weight:700; }
.coo-app :focus-visible{ outline:2px solid var(--primary); outline-offset:2px; border-radius:10px; }

/* ---------- tabs (Journey / Vault / Calendar / Family) ---------- */
.coo-tabs{ display:flex; gap:6px; padding:5px; border:1px solid var(--line); border-radius:var(--radius-pill);
  background:var(--mint-50); margin-bottom:22px; }
.coo-tab{ flex:1; display:flex; align-items:center; justify-content:center; gap:7px; padding:10px 8px;
  border-radius:var(--radius-pill); font-weight:600; font-size:0.92rem; color:var(--muted); white-space:nowrap; }
.coo-tab:hover{ color:var(--forest); }
.coo-tab.on{ background:var(--primary); color:#fff; box-shadow:var(--shadow-tight); }
[data-theme="dark"] .coo-tab.on, html:not([data-theme="light"]) .coo-tab.on{ color:#0F2A1F; }
@media (max-width:480px){ .coo-tab{ flex-direction:column; gap:2px; font-size:0.76rem; padding:8px 4px; } }

.coo-warn{ background:rgba(221,90,76,0.12); border:1px solid rgba(221,90,76,0.4); border-radius:var(--radius-md);
  padding:12px 14px; margin-bottom:18px; font-size:0.9rem; }

/* ---------- headings & text ---------- */
.coo-h2{ font-size:1.45rem; margin:6px 0 4px; outline:none; }
.coo-h2.big{ font-size:1.7rem; }
.coo-h3{ font-size:1.08rem; margin:26px 0 8px; }
.coo-sub{ color:var(--muted); margin:0 0 14px; }
.coo-hint{ color:var(--muted); font-size:0.86rem; margin:6px 0 10px; }
.coo-error{ color:var(--red); font-size:0.88rem; min-height:1em; margin:4px 0; }
.coo-error:empty{ display:none; }
.coo-back{ display:inline-flex; align-items:center; gap:6px; font-weight:600; color:var(--muted) !important; margin-bottom:10px; }
.coo-back:hover{ color:var(--forest) !important; }
.coo-btns{ display:flex; flex-wrap:wrap; gap:10px; margin-top:8px; }
.coo-btns.center{ justify-content:center; }
.coo-link-btn{ background:none; border:0; color:var(--muted); text-decoration:underline; padding:8px 4px; }
.coo-link-btn.danger{ color:var(--red); margin-top:14px; }
.coo-headrow{ display:flex; align-items:center; justify-content:space-between; gap:12px; }

/* ---------- journey header ---------- */
.coo-pill{ display:flex; align-items:center; gap:12px; padding:12px 20px; border-radius:var(--radius-pill);
  border:1px solid var(--line); box-shadow:var(--shadow-tight); background:var(--white); }
.coo-pill-ic{ font-size:1.3rem; }
.coo-stages{ display:flex; gap:4px; overflow-x:auto; border-bottom:1px solid var(--line); margin:16px 0 18px; padding:0 2px;
  scrollbar-width:none; }
.coo-stages::-webkit-scrollbar{ display:none; }
.coo-stage{ position:relative; flex:0 0 auto; display:flex; flex-direction:column; align-items:center; gap:4px;
  padding:6px 12px 10px; background:none; border:0; border-bottom:2px solid transparent; color:var(--muted);
  font:inherit; font-size:0.8rem; font-weight:600; cursor:pointer; }
.coo-stage .e{ font-size:1.5rem; opacity:.6; filter:grayscale(.35); }
.coo-stage.on{ color:var(--forest); border-bottom-color:var(--forest); }
.coo-stage.on .e{ opacity:1; filter:none; }
.coo-stage .now{ position:absolute; top:4px; right:8px; width:8px; height:8px; border-radius:50%; background:var(--red); }

.coo-notice{ display:block; background:rgba(224,162,62,0.16); border-radius:var(--radius-md); padding:14px 16px; margin-bottom:16px; }

/* ---------- art (stage scenes with Nestiy) ---------- */
.coo-art{ position:relative; display:flex; align-items:flex-end; justify-content:center; gap:4px; height:230px;
  border-radius:var(--radius-md); overflow:hidden; }
.coo-art.small{ height:140px; }
.coo-art.wide{ height:220px; margin-bottom:14px; }
.coo-art .coo-badge{ position:absolute; top:12px; left:12px; z-index:2; }
.coo-art-nestiy{ width:auto; height:88%; max-height:180px; object-fit:contain; filter:drop-shadow(0 10px 18px rgba(18,56,42,.18)); }
.coo-art.small .coo-art-nestiy{ height:78%; }
.coo-art-emoji{ font-size:3.2rem; align-self:center; margin-right:-6px; }
.coo-art.small .coo-art-emoji{ font-size:2.1rem; }
.tint-planning{ background:rgba(126,200,140,0.18); }
.tint-pregnancy{ background:rgba(93,225,232,0.22); }
.tint-baby{ background:rgba(255,200,69,0.22); }
.tint-toddler{ background:rgba(69,194,177,0.2); }
.tint-preschool{ background:rgba(143,227,201,0.28); }
.tint-school{ background:rgba(143,201,224,0.26); }
.tint-cat-health{ background:rgba(93,225,232,0.22); }
.tint-cat-vaccines{ background:rgba(69,194,177,0.2); }
.tint-cat-growth{ background:rgba(255,200,69,0.22); }
.tint-cat-milestones{ background:rgba(143,227,201,0.28); }
.tint-cat-documents{ background:rgba(143,201,224,0.26); }

.coo-badge{ display:inline-block; background:#fff; color:#222; font-size:0.74rem; font-weight:700;
  padding:5px 10px; border-radius:var(--radius-pill); box-shadow:0 2px 6px rgba(0,0,0,.14); }
.coo-badge.late{ color:#C93A3A; }
.coo-badge.ok{ color:#1F8A7D; }
.coo-badge.quiet{ color:#6B6B6B; }

/* ---------- cards ---------- */
.coo-hero-card{ display:grid; gap:10px; margin-top:12px; }
.coo-hero-text{ display:block; }
.coo-meta{ display:flex; justify-content:space-between; gap:10px; align-items:baseline; }
.coo-meta b{ font-size:1.05rem; }
.coo-meta em{ font-style:normal; font-weight:700; font-size:0.86rem; color:var(--forest); white-space:nowrap; }
@media (min-width:720px){
  .coo-hero-card{ grid-template-columns:1.25fr 1fr; align-items:center; gap:22px; }
}
.coo-hero-card:hover .coo-art, .coo-mini:hover .coo-art, .coo-tile:hover .coo-art{ transform:translateY(-2px); }
.coo-art{ transition:transform .2s ease; }

.coo-grid{ display:grid; grid-template-columns:repeat(auto-fill, minmax(190px, 1fr)); gap:18px 14px; margin-top:20px; }
.coo-mini b, .coo-tile b{ display:block; margin-top:8px; font-size:0.94rem; }
.coo-grid.tiles{ grid-template-columns:repeat(auto-fill, minmax(150px, 1fr)); }

.coo-card{ border:1px solid var(--line); border-radius:var(--radius-md); padding:16px; margin-bottom:12px; background:var(--white); }
.coo-big{ font-family:var(--font-head); font-size:1.6rem; font-weight:700; color:var(--forest); }
.coo-chart{ width:100%; height:120px; margin-top:8px; }
.coo-chart polyline{ fill:none; stroke:var(--red); stroke-width:3; stroke-linejoin:round; stroke-linecap:round; }
.coo-chart circle{ fill:var(--white); stroke:var(--red); stroke-width:2.5; }
.coo-record{ display:flex; gap:12px; align-items:flex-start; justify-content:space-between; }
.coo-record p{ margin:6px 0 0; font-size:0.9rem; }
.coo-record .coo-measure{ font-weight:700; color:var(--forest); }

.coo-icon-btn{ flex:0 0 auto; width:38px; height:38px; border-radius:50%; border:1px solid var(--line);
  background:var(--white); color:var(--forest); cursor:pointer; font-size:1.05rem; line-height:1; }
.coo-icon-btn:hover{ border-color:var(--primary); }

.coo-private{ display:flex; gap:12px; align-items:flex-start; background:rgba(69,194,177,0.14); border-radius:var(--radius-md);
  padding:14px 16px; font-size:0.9rem; margin:0 0 18px; }
.coo-add{ margin-top:22px; }

/* ---------- rows & checks ---------- */
.coo-row, .coo-cal{ display:flex; align-items:center; gap:14px; padding:11px 2px; border-bottom:1px solid var(--line); }
.coo-row:hover b, .coo-cal:hover b{ color:var(--primary-dark); }
.coo-row-text{ flex:1; min-width:0; }
.coo-row-text b{ display:block; }
.coo-app small.late{ color:var(--red); }
.coo-app small.booked{ color:var(--primary-dark); }
.coo-chev{ color:var(--muted); font-size:1.4rem; }
.coo-check{ flex:0 0 auto; width:26px; height:26px; border-radius:50%; border:2px solid #CFCFCF; display:inline-grid; place-items:center;
  transition:background .15s ease, border-color .15s ease; }
.coo-check.due{ border-color:var(--gold); }
.coo-check.late{ border-color:var(--red); }
.coo-check.on{ background:#2A9E8F; border-color:#2A9E8F; }
.coo-check.on::after{ content:""; width:11px; height:6px; border:solid #fff; border-width:0 0 2.5px 2.5px; transform:translateY(-1px) rotate(-45deg); }

.coo-tasks{ display:grid; gap:4px; }
.coo-task{ display:flex; align-items:center; gap:14px; text-align:left; padding:10px 8px; border-radius:12px; border:0;
  background:none; color:var(--ink); font:inherit; font-weight:600; cursor:pointer; }
.coo-task:hover{ background:var(--mint-50); }
.coo-task.on span:last-child{ color:var(--muted); }

.coo-progress{ display:flex; align-items:center; gap:10px; margin:10px 0 6px; }
.coo-progress > span{ flex:1; height:8px; border-radius:4px; background:var(--mint-100); overflow:hidden; }
.coo-progress i{ display:block; height:100%; background:#2A9E8F; border-radius:4px; }

.coo-catchup{ border:1px solid var(--line); border-radius:var(--radius-md); padding:14px 16px; margin-top:24px; }
.coo-catchup summary{ cursor:pointer; list-style:none; display:flex; align-items:center; gap:10px; }
.coo-catchup summary::-webkit-details-marker{ display:none; }
.coo-catchup summary::after{ content:"›"; font-size:1.4rem; color:var(--muted); margin-left:auto; transition:transform .15s ease; }
.coo-catchup[open] summary::after{ transform:rotate(90deg); }

.coo-cal .coo-day{ flex:0 0 52px; height:56px; border-radius:var(--radius-sm); background:var(--mint-100);
  display:flex; flex-direction:column; align-items:center; justify-content:center; }
.coo-cal .coo-day b{ font-size:1.2rem; line-height:1.1; }
.coo-cal .coo-day.booked{ background:var(--red); }
.coo-cal .coo-day.booked b, .coo-cal .coo-day.booked small{ color:#fff; }
.coo-star{ color:var(--muted); }

/* ---------- step page ---------- */
.coo-guide{ display:flex; align-items:center; gap:14px; padding:14px 0; border-top:1px solid var(--line); border-bottom:1px solid var(--line); margin-top:10px; }
.coo-avatar{ width:56px; height:56px; object-fit:contain; border-radius:50%; background:rgba(93,225,232,0.22); }
.coo-why{ margin:16px 0 0; line-height:1.6; }
.coo-local{ display:flex; gap:10px; background:rgba(69,194,177,0.14); border-radius:var(--radius-md); padding:12px 14px; margin-top:14px; font-size:0.9rem; }
.coo-date-row{ display:flex; flex-wrap:wrap; align-items:flex-end; gap:10px; }
.coo-date-row .coo-field{ flex:1 1 200px; margin:0; }
.coo-linked{ padding:8px 0; border-bottom:1px solid var(--line); }
.coo-actionbar{ position:sticky; bottom:12px; z-index:3; display:flex; align-items:center; justify-content:space-between; gap:12px;
  margin-top:28px; padding:14px 16px; border:1px solid var(--line); border-radius:var(--radius-md);
  background:var(--white); box-shadow:var(--shadow-soft); backdrop-filter:blur(16px); -webkit-backdrop-filter:blur(16px); }
.coo-actionbar b{ text-decoration:underline; }

/* ---------- forms ---------- */
.coo-form{ display:grid; gap:16px; max-width:560px; }
.coo-field{ display:grid; gap:6px; }
.coo-field > span{ font-size:0.82rem; font-weight:600; color:var(--forest); }
.coo-field input, .coo-field textarea{
  width:100%; padding:12px 14px; border-radius:12px; border:1px solid var(--line); background:var(--mint-50);
  color:var(--ink); font:inherit; font-size:0.98rem; }
.coo-field input:focus, .coo-field textarea:focus{ outline:none; border-color:var(--primary); box-shadow:0 0 0 3px rgba(30,122,58,0.14); }
.coo-field input[type=date]{ min-height:48px; }
html:not([data-theme="light"]) .coo-field input[type=date]{ color-scheme:dark; }
.coo-growth{ display:grid; grid-template-columns:1fr 1fr; gap:12px; }
.coo-growth .coo-field:last-child{ grid-column:1 / -1; }
.coo-growth[hidden]{ display:none; }
.coo-form > .btn{ justify-self:start; }

.coo-chips{ border:0; padding:0; margin:0; display:flex; flex-wrap:wrap; gap:8px; }
.coo-chips legend{ font-size:0.82rem; font-weight:600; color:var(--forest); margin-bottom:8px; padding:0; }
.coo-chips label{ position:relative; cursor:pointer; }
.coo-chips input{ position:absolute; opacity:0; pointer-events:none; }
.coo-chips span{ display:inline-block; padding:8px 14px; border-radius:var(--radius-pill); border:1px solid var(--line);
  font-size:0.86rem; font-weight:600; color:var(--forest); }
.coo-chips input:checked + span{ background:var(--forest); border-color:var(--forest); color:var(--white); }
html:not([data-theme="light"]) .coo-chips input:checked + span{ background:var(--primary); border-color:var(--primary); color:#0F2A1F; }
.coo-chips input:focus-visible + span{ outline:2px solid var(--primary); outline-offset:2px; }

.coo-options{ border:0; padding:0; margin:0; display:grid; gap:12px; }
.coo-option{ position:relative; display:flex; align-items:center; gap:14px; padding:14px 16px; border:1px solid var(--line);
  border-radius:var(--radius-md); cursor:pointer; }
.coo-option .e{ font-size:2rem; }
.coo-option input{ position:absolute; opacity:0; pointer-events:none; }
.coo-option:has(input:checked){ border-color:var(--forest); box-shadow:0 0 0 1px var(--forest) inset; background:var(--mint-50); }
.coo-option:has(input:focus-visible){ outline:2px solid var(--primary); outline-offset:2px; }

.coo-file{ position:relative; overflow:hidden; cursor:pointer; }
.coo-file input{ position:absolute; inset:0; opacity:0; cursor:pointer; }

/* ---------- onboarding ---------- */
.coo-welcome{ text-align:center; padding:10px 0 6px; }
.coo-welcome-nestiy{ width:200px; height:200px; object-fit:contain; }
.coo-welcome .coo-sub{ max-width:460px; margin:10px auto 18px; }
.coo-ob-top{ display:flex; align-items:center; gap:14px; margin-bottom:18px; }
.coo-ob-top .coo-progress{ flex:1; margin:0; }
.coo-guide.bubble{ border:0; padding:0; align-items:flex-end; }
.coo-guide.bubble .coo-avatar{ width:64px; height:64px; }
.coo-bubble{ flex:1; background:var(--mint-100); border-radius:18px 18px 18px 4px; padding:14px 16px; font-weight:600; color:var(--forest); }

/* ---------- family ---------- */
.coo-family-hero{ display:flex; align-items:center; gap:16px; padding:16px 20px; border-radius:var(--radius-lg); margin:10px 0 6px; }
.coo-family-hero b{ font-size:1.3rem; }
.coo-family-nestiy{ width:110px; height:110px; object-fit:contain; }
.coo-event{ display:grid; gap:10px; margin-top:16px; }
.coo-detail{ display:flex; justify-content:space-between; gap:16px; padding:11px 0; border-bottom:1px solid var(--line); }
.coo-detail b{ text-align:right; }
.coo-about{ margin-top:22px; background:var(--mint-50); }
.coo-about p{ margin:4px 0 0; font-size:0.88rem; color:var(--muted); }
.coo-about a{ text-decoration:underline !important; }

.coo-empty{ text-align:center; padding:26px 0; }
.coo-empty-nestiy{ width:130px; height:130px; object-fit:contain; }
.coo-empty b{ display:block; font-size:1.1rem; margin-top:6px; }
.coo-empty p{ color:var(--muted); max-width:320px; margin:4px auto 0; font-size:0.92rem; }

@media (prefers-reduced-motion: reduce){ .coo-art, .coo-check{ transition:none; } }
