/* ============================================================================
 * Synodos-MED+ · Home — Calm redesign layer (Στάδιο 2b+)
 * ----------------------------------------------------------------------------
 * Component styles for the carer-first, "ήρεμος συνοδοιπόρος" Home. Loaded
 * AFTER css/tokens.css so it consumes the calm palette directly (--teal,
 * --breath, --breath-bg, --teal-bg, --sm-*). Kept as a NEW module — the
 * redesign never grows the 176KB style.css monolith (strangler rule).
 *
 * These surfaces are sacred: no commercial / sponsorship content ever lands
 * here or in the Ανάσα / SOS.
 * ============================================================================ */

/* ── Στάδιο 2b · Ανάσα entry band ──────────────────────────────────────────
   High on the Home, above the day counter: a gentle, always-there invitation
   for the carer to breathe. Taps open the two-door breath space
   (window.openBreathSpace → js/features/breath/index.js). */
.home-breath-band {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  width: calc(100% - 2rem);
  margin: 0.5rem 1rem 0.25rem;
  padding: 0.9rem 1.05rem;
  border: 1px solid color-mix(in srgb, var(--breath) 25%, transparent);
  border-radius: 18px;
  background: linear-gradient(135deg, var(--breath-bg), var(--teal-bg));
  color: var(--sm-ink);
  cursor: pointer;
  text-align: left;
  -webkit-tap-highlight-color: transparent;
  transition:
    transform 0.18s ease,
    box-shadow 0.18s ease;
}

.home-breath-band:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 22px color-mix(in srgb, var(--breath) 20%, transparent);
}

.home-breath-band:active {
  transform: translateY(0);
}

.home-breath-band:focus-visible {
  outline: 2px solid var(--breath);
  outline-offset: 2px;
}

.home-breath-band-icon {
  flex-shrink: 0;
  font-size: 1.5rem;
  line-height: 1;
}

.home-breath-band-copy {
  display: flex;
  flex: 1;
  min-width: 0;
  flex-direction: column;
  gap: 0.12rem;
}

.home-breath-band-title {
  font-weight: 700;
  font-size: 1rem;
  color: var(--teal);
}

.home-breath-band-sub {
  font-size: 0.82rem;
  color: var(--sm-muted);
}

.home-breath-band-chevron {
  flex-shrink: 0;
  font-size: 1.35rem;
  color: var(--breath);
  opacity: 0.7;
}

@media (prefers-reduced-motion: reduce) {
  .home-breath-band {
    transition: none;
  }
  .home-breath-band:hover {
    transform: none;
  }
}

/* ── Στάδιο 2c · Home vertical rhythm & palette cohesion ────────────────────
   Even cadence down the top strata (greeting → band → day counter → hero) and
   a single calm colour language — the legacy blue/teal/purple phase accents are
   remapped onto the design tokens. Pure re-skin: no layout or DOM changes, so
   the Home composition contract is untouched. */

/* Greeting — styling moved out of the inline attribute into this layer, with a
   calmer top and room to breathe before the band. */
.contextual-greeting {
  padding: var(--sm-space-md) var(--sm-gutter) var(--sm-space-xs);
}
.contextual-greeting .greeting-name {
  letter-spacing: -0.01em;
}
.contextual-greeting .greeting-sub {
  margin-top: 0.3rem;
}

/* Consistent cadence between the band and its neighbours. */
.home-breath-band {
  margin-top: var(--sm-space-xs);
  margin-bottom: var(--sm-space-sm);
}
.day-counter-wrap {
  padding-top: var(--sm-space-xs);
  padding-bottom: var(--sm-space-md);
}

/* ── Phase identity — one distinct accent per care state (Στάδιο 2c·D) ────────
     Νοσοκομείο (hospital)   → navy / blue   ← keeps its base identity (style.css)
     Στο σπίτι (home_care)   → breath (teal-green)
     Καθημερινότητα (daily)  → lav (lavender)
   Three clearly distinct identities. Hospital is deliberately left to the base
   navy/blue styles; only home_care and daily are remapped onto the palette. */

/* Phase hero accent. */
.home-phase-hero[data-phase="home_care"] {
  border-left-color: var(--breath);
}
.home-phase-hero[data-phase="daily"] {
  border-left-color: var(--lav);
}
.home-phase-hero[data-phase="home_care"] .home-phase-hero-kicker {
  color: var(--breath);
}
.home-phase-hero[data-phase="daily"] .home-phase-hero-kicker {
  color: var(--lav);
}

/* Switcher summary chip (hospital keeps the base blue). */
.home-priority-summary[data-phase="home_care"] {
  color: var(--breath);
  border-color: color-mix(in srgb, var(--breath) 34%, transparent);
  background: color-mix(in srgb, var(--breath) 10%, transparent);
}
.home-priority-summary[data-phase="daily"] {
  color: var(--lav);
  border-color: color-mix(in srgb, var(--lav) 34%, transparent);
  background: color-mix(in srgb, var(--lav) 10%, transparent);
}
body.dark-theme .home-priority-summary[data-phase="home_care"] {
  color: var(--breath);
}
body.dark-theme .home-priority-summary[data-phase="daily"] {
  color: var(--lav);
}

/* Phase-menu dots (hospital keeps the base blue). */
.home-phase-menu-option[data-home-care-phase="home_care"]::before {
  background: var(--breath);
}
.home-phase-menu-option[data-home-care-phase="daily"]::before {
  background: var(--lav);
}

/* Day-counter card follows the state accent. Hospital keeps its base navy;
   home_care = teal-green, daily = lavender. Fixed dark tones, white text. */
.day-counter-card[data-phase="home_care"] {
  background: linear-gradient(135deg, #0c1f1c 0%, #14524a 50%, #2f8577 100%);
}
.day-counter-card[data-phase="daily"] {
  background: linear-gradient(135deg, #171528 0%, #2f2668 50%, #5a4aa8 100%);
}
.day-counter-card[data-phase="daily"]::before {
  background: radial-gradient(circle, rgba(140, 120, 220, 0.28) 0%, transparent 70%);
}
