/* =====================================================================
   Health Calculators – shared stylesheet
   ---------------------------------------------------------------------
   All shared rules are scoped under `.health-calc-page` so they never
   leak into the rest of the site. Page-specific tweaks live under an
   extra page class on the same wrapper:
     .hc-sleep  – Sleep Cycle Calculator
     .hc-water  – Water Intake Calculator
     .hc-heart  – Heart Rate Zone Calculator

   This shares the same visual language as the Home & Lifestyle
   calculators (home-lifestyle-cal.css): alternating full-width section
   bands, step-flow timelines, left-accent info cards, stat strips, and
   a minimal FAQ.
   ===================================================================== */

/* ===== SHARED THEME + BASE ===== */
.health-calc-page{
  --navy:#0F1F5C;
  --blue:#1A6FBF;
  --teal:#00B8C8;
  --cyan:#6EE7F0;
  --bg:#F2F6FF;
  --bg2:#E8EFFC;
  --bg-soft:#F8FAFF;
  --white:#FFFFFF;
  --text:#1C2340;
  --muted:#5B6680;
  --border:#D0DAEA;
  --grad2:linear-gradient(135deg,#1A6FBF,#00B8C8);
  --shadow-md:0 8px 40px rgba(26,46,107,0.14);
  background:var(--white);
  color:var(--text);
}

.health-calc-page .reveal{opacity:0;transform:translateY(24px);transition:opacity .5s ease,transform .5s ease}
.health-calc-page .reveal.visible{opacity:1;transform:translateY(0)}

/* ===== BREADCRUMB ===== */
.health-calc-page .breadcrumb-bar{padding:28px 5% 0;max-width:1180px;margin:0 auto}
.health-calc-page .breadcrumb{display:flex;align-items:center;gap:6px;font-size:12.5px;color:var(--muted);flex-wrap:wrap}
.health-calc-page .breadcrumb a{color:var(--muted);text-decoration:none;font-weight:600;transition:color .2s}
.health-calc-page .breadcrumb a:hover{color:var(--blue)}
.health-calc-page .breadcrumb span.sep{opacity:.5}
.health-calc-page .breadcrumb span.current{color:var(--navy);font-weight:700}

/* ===== TOOL HERO ===== */
.health-calc-page .tool-hero{padding:26px 5% 40px;position:relative;overflow:hidden;text-align:center;background:var(--white)}
.health-calc-page .tool-hero::before{content:'';position:absolute;inset:0;background:radial-gradient(ellipse 60% 60% at 80% 20%,rgba(26,111,191,0.08) 0%,transparent 70%),radial-gradient(ellipse 50% 50% at 15% 80%,rgba(0,184,200,0.08) 0%,transparent 60%);pointer-events:none}
.health-calc-page .tool-hero>*{position:relative;z-index:1}
.health-calc-page .tool-hero-eyebrow{display:inline-flex;align-items:center;gap:8px;background:rgba(26,111,191,0.1);border:1px solid rgba(26,111,191,0.28);color:var(--blue);font-size:12px;font-weight:700;text-transform:uppercase;letter-spacing:1.2px;padding:6px 16px;border-radius:50px;margin-bottom:20px}
.health-calc-page .tool-hero h1{font-size:clamp(1.9rem,4.2vw,2.9rem);font-weight:800;color:var(--navy);margin-bottom:14px;line-height:1.16}
.health-calc-page .tool-hero h1 .accent{background:var(--grad2);-webkit-background-clip:text;-webkit-text-fill-color:transparent;background-clip:text}
.health-calc-page .tool-hero p{font-size:15.5px;color:var(--muted);max-width:580px;margin:0 auto}
.health-calc-page .tool-meta-row{display:flex;gap:10px;justify-content:center;flex-wrap:wrap;margin-top:22px}
.health-calc-page .tool-meta-pill{display:inline-flex;align-items:center;gap:6px;font-size:12px;font-weight:700;color:var(--muted);padding:7px 14px;border-radius:50px;border:1.5px solid var(--border);background:var(--white)}

/* ===== TOOL PAGE WRAP + ALTERNATING SECTION BANDS ===== */
.health-calc-page .tool-page{padding:10px 0 0}
.health-calc-page .tool-wrap{max-width:920px;margin:0 auto;padding:0 5%}
.health-calc-page .tool-section{padding:52px 0}
.health-calc-page .tool-section.band{background:var(--bg-soft)}
.health-calc-page .tool-section.band .tool-wrap{padding-top:4px;padding-bottom:4px}
.health-calc-page .tool-section-head{margin-bottom:26px}
.health-calc-page .tool-section-head h2{font-size:clamp(1.3rem,2.6vw,1.7rem);font-weight:800;color:var(--navy);margin-bottom:8px;line-height:1.25}
.health-calc-page .tool-section-head p{font-size:14.5px;color:var(--muted);max-width:640px}

/* ===== CALCULATOR CARD (shared dark card) ===== */
.health-calc-page .calc-card{background:linear-gradient(160deg,#0B1845 0%,#122272 55%,#0E3A7A 100%);border-radius:26px;padding:36px;position:relative;overflow:hidden;box-shadow:0 16px 50px -10px rgba(15,31,92,0.35)}
.health-calc-page .calc-card::before{content:'';position:absolute;inset:0;background:radial-gradient(ellipse 60% 60% at 85% 10%,rgba(0,184,200,0.18),transparent 60%),radial-gradient(ellipse 50% 50% at 5% 90%,rgba(26,111,191,0.16),transparent 55%);pointer-events:none}
.health-calc-page .calc-card>*{position:relative;z-index:1}

.health-calc-page .calc-tabs{display:flex;gap:8px;background:rgba(255,255,255,0.08);border:1px solid rgba(255,255,255,0.14);border-radius:50px;padding:5px;margin-bottom:26px;max-width:460px}
.health-calc-page .calc-tab{flex:1;text-align:center;padding:10px 14px;border-radius:50px;font-size:13px;font-weight:700;color:rgba(255,255,255,0.65);cursor:pointer;transition:all .2s;user-select:none;border:none;font-family:inherit;background:transparent}
.health-calc-page .calc-tab.active{background:var(--grad2);color:#fff;box-shadow:0 4px 16px rgba(0,184,200,0.4)}

.health-calc-page .calc-form-row{display:flex;gap:16px;align-items:flex-end;flex-wrap:wrap;margin-bottom:8px}
.health-calc-page .calc-field{display:flex;flex-direction:column;gap:8px}
.health-calc-page .calc-field label{font-size:12px;font-weight:700;color:rgba(255,255,255,0.65);text-transform:uppercase;letter-spacing:.8px}
.health-calc-page .calc-field input[type="time"],
.health-calc-page .calc-field input[type="number"],
.health-calc-page .calc-field select{
  background:rgba(255,255,255,0.95);border:none;border-radius:12px;
  height:54px;box-sizing:border-box;padding:0 16px;font-size:16px;font-weight:800;
  color:var(--navy);font-family:inherit;cursor:pointer;
}
.health-calc-page .calc-field input[type="time"]{font-size:20px;width:200px}
.health-calc-page .calc-field input[type="time"]::-webkit-calendar-picker-indicator{cursor:pointer;opacity:.6}
.health-calc-page .calc-field input[type="number"]{cursor:text;width:150px}
.health-calc-page .calc-field select{width:220px}
.health-calc-page .calc-field input:focus,
.health-calc-page .calc-field select:focus{outline:none;box-shadow:0 0 0 3px rgba(0,184,200,0.35)}
.health-calc-page .calc-field input:disabled{opacity:.6;cursor:not-allowed}
.health-calc-page .calc-field-note{font-size:11px;color:rgba(255,255,255,0.5);font-weight:600}

.health-calc-page .calc-btn-row{display:flex;gap:10px;flex-wrap:wrap;align-items:flex-end}
.health-calc-page .calc-btn{display:inline-flex;align-items:center;justify-content:center;height:54px;box-sizing:border-box;background:var(--grad2);color:#fff;border:none;padding:0 28px;border-radius:12px;font-size:15px;font-weight:800;cursor:pointer;font-family:inherit;transition:all .2s;white-space:nowrap}
.health-calc-page .calc-btn:hover{transform:translateY(-2px);box-shadow:0 8px 24px rgba(0,184,200,0.4)}
.health-calc-page .calc-btn.ghost{background:rgba(255,255,255,0.1);border:1.5px solid rgba(255,255,255,0.25);box-shadow:none}
.health-calc-page .calc-btn.ghost:hover{background:rgba(255,255,255,0.16);box-shadow:none}
.health-calc-page .calc-note{font-size:12px;color:rgba(255,255,255,0.5);margin-top:14px}

.health-calc-page .calc-check-row{display:flex;align-items:center;gap:8px;margin-top:12px}
.health-calc-page .calc-check-row input{accent-color:var(--teal);width:15px;height:15px;cursor:pointer}
.health-calc-page .calc-check-row label{font-size:12.5px;color:rgba(255,255,255,0.7);cursor:pointer;font-weight:600}

/* ===== RESULTS (shared) ===== */
.health-calc-page .calc-results{margin-top:30px;display:none}
.health-calc-page .calc-results.show{display:block}
.health-calc-page .calc-results-head{font-size:13px;font-weight:700;color:rgba(255,255,255,0.7);text-transform:uppercase;letter-spacing:.8px;margin-bottom:14px}
.health-calc-page .calc-results-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(150px,1fr));gap:12px}
.health-calc-page .calc-result-card{background:rgba(255,255,255,0.08);border:1.5px solid rgba(255,255,255,0.16);border-radius:16px;padding:16px 12px;text-align:center;transition:all .2s}
.health-calc-page .calc-result-card.best{background:linear-gradient(135deg,rgba(26,111,191,0.35),rgba(0,184,200,0.28));border-color:rgba(255,255,255,0.35)}
.health-calc-page .calc-result-time{font-size:19px;font-weight:800;color:#fff;font-variant-numeric:tabular-nums;display:block}
.health-calc-page .calc-result-cycles{font-size:11px;font-weight:700;color:rgba(255,255,255,0.6);text-transform:uppercase;letter-spacing:.5px;margin-top:6px;display:block}
.health-calc-page .calc-result-hours{font-size:11px;color:rgba(255,255,255,0.45);margin-top:2px;display:block}
.health-calc-page .calc-result-card.best .calc-result-cycles,
.health-calc-page .calc-result-card.best .calc-result-hours{color:rgba(255,255,255,0.85)}
.health-calc-page .calc-badge-best{display:inline-block;font-size:9.5px;font-weight:800;text-transform:uppercase;letter-spacing:.6px;background:#fff;color:#0284C7;padding:2px 8px;border-radius:50px;margin-bottom:6px}

/* ===== STEP FLOW (timeline) ===== */
.health-calc-page .step-flow{display:flex;flex-direction:column}
.health-calc-page .step-flow-item{display:flex;gap:20px;position:relative;padding-bottom:30px}
.health-calc-page .step-flow-item:last-child{padding-bottom:0}
.health-calc-page .step-flow-item:not(:last-child)::before{content:'';position:absolute;left:19px;top:42px;bottom:0;width:2px;background:var(--border)}
.health-calc-page .step-flow-num{width:40px;height:40px;border-radius:50%;background:var(--grad2);color:#fff;font-size:15px;font-weight:800;display:flex;align-items:center;justify-content:center;flex-shrink:0;z-index:1}
.health-calc-page .step-flow-body{padding-top:6px}
.health-calc-page .step-flow-body h3{font-size:15.5px;font-weight:700;color:var(--navy);margin-bottom:5px}
.health-calc-page .step-flow-body p{font-size:13.5px;color:var(--muted);line-height:1.65;max-width:560px}

/* ===== INFO CARDS (left accent border, no fill) ===== */
.health-calc-page .info-grid{display:grid;grid-template-columns:1fr 1fr;gap:18px}
.health-calc-page .info-card{background:var(--white);border:1.5px solid var(--border);border-left:4px solid var(--teal);border-radius:14px;padding:22px 24px}
.health-calc-page .info-card h3{font-size:15px;font-weight:700;color:var(--navy);margin-bottom:10px;display:flex;align-items:center;gap:8px}
.health-calc-page .info-card p{font-size:13.5px;color:var(--muted);line-height:1.7}
.health-calc-page .info-card ul{margin:10px 0 0 18px;font-size:13.5px;color:var(--muted);line-height:1.9}

/* ===== STAGE / TIMELINE (shared) ===== */
.health-calc-page .stage-timeline{display:flex;flex-direction:column;gap:10px;margin-top:6px}
.health-calc-page .stage-row{display:flex;align-items:center;gap:14px;background:var(--white);border:1.5px solid var(--border);border-radius:14px;padding:14px 18px}
.health-calc-page .stage-dot{width:12px;height:12px;border-radius:50%;flex-shrink:0}
.health-calc-page .stage-row h4{font-size:13.5px;font-weight:700;color:var(--navy)}
.health-calc-page .stage-row p{font-size:12.5px;color:var(--muted);margin-top:2px}

/* ===== QUICK STAT STRIP ===== */
.health-calc-page .stat-strip{display:flex;gap:0;border:1.5px solid var(--border);border-radius:16px;overflow:hidden;margin-top:26px;background:var(--white)}
.health-calc-page .stat-strip-item{flex:1;text-align:center;padding:18px 12px;border-right:1.5px solid var(--border)}
.health-calc-page .stat-strip-item:last-child{border-right:none}
.health-calc-page .stat-strip-item .val{font-size:20px;font-weight:800;color:var(--navy);display:block}
.health-calc-page .stat-strip-item .lbl{font-size:11px;font-weight:700;color:var(--muted);text-transform:uppercase;letter-spacing:.5px;margin-top:4px;display:block}

/* ===== WARNING BANNER ===== */
.health-calc-page .warn-banner{display:flex;gap:14px;align-items:flex-start;background:var(--white);border:1.5px solid var(--border);border-radius:16px;padding:18px 20px;margin-top:18px}
.health-calc-page .warn-banner .icon{font-size:20px;flex-shrink:0}
.health-calc-page .warn-banner p{font-size:13px;color:var(--navy);line-height:1.6}

/* ===== FAQ (minimal until opened) ===== */
.health-calc-page .faq-list{display:flex;flex-direction:column;gap:10px}
.health-calc-page .faq-item{background:var(--white);border:1.5px solid var(--border);border-left:4px solid transparent;border-radius:12px;transition:all .2s}
.health-calc-page .faq-item.open{border-left-color:var(--teal);background:var(--bg-soft)}
.health-calc-page .faq-q{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:17px 20px;cursor:pointer;font-size:14.5px;font-weight:700;color:var(--navy)}
.health-calc-page .faq-q .plus{font-size:20px;font-weight:400;color:var(--blue);transition:transform .25s;flex-shrink:0}
.health-calc-page .faq-item.open .faq-q .plus{transform:rotate(45deg)}
.health-calc-page .faq-a{max-height:0;overflow:hidden;transition:max-height .3s ease}
.health-calc-page .faq-item.open .faq-a{max-height:260px}
.health-calc-page .faq-a p{font-size:13.5px;color:var(--muted);line-height:1.7;padding:0 20px 20px}

/* ===== RELATED TOOLS ===== */
.health-calc-page .related-tools{background:var(--bg2);padding:60px 5%}
.health-calc-page .related-tools-inner{max-width:1180px;margin:0 auto}
.health-calc-page .section-header{text-align:center;margin-bottom:40px}
.health-calc-page .section-eyebrow{display:inline-block;font-size:11px;font-weight:700;text-transform:uppercase;letter-spacing:1.5px;color:var(--blue);background:rgba(26,111,191,0.1);padding:5px 14px;border-radius:50px;margin-bottom:14px}
.health-calc-page .section-header h2{font-size:clamp(1.5rem,3vw,2rem);font-weight:800;color:var(--navy);margin-bottom:10px}
.health-calc-page .section-header p{font-size:14.5px;color:var(--muted);max-width:480px;margin:0 auto}
.health-calc-page .tools-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(240px,1fr));gap:20px}
.health-calc-page .tool-card{background:var(--white);border:1.5px solid var(--border);border-radius:18px;padding:24px;transition:all .25s;cursor:pointer;text-decoration:none;display:block}
.health-calc-page .tool-card:hover{border-color:var(--teal);box-shadow:0 6px 28px rgba(0,184,200,0.15);transform:translateY(-3px)}
.health-calc-page .tool-card.current{border-color:var(--teal);background:rgba(0,184,200,0.05);cursor:default}
.health-calc-page .tool-card.current:hover{transform:none;box-shadow:none}
.health-calc-page .tool-card-head{display:flex;align-items:center;gap:12px;margin-bottom:14px}
.health-calc-page .tool-icon{width:44px;height:44px;border-radius:12px;background:var(--grad2);display:flex;align-items:center;justify-content:center;font-size:20px;flex-shrink:0}
.health-calc-page .tool-card h3{font-size:15px;font-weight:700;color:var(--navy)}
.health-calc-page .tool-card p{font-size:13px;color:var(--muted);line-height:1.55;margin-bottom:14px}
.health-calc-page .tool-tag{display:inline-block;font-size:10.5px;font-weight:700;text-transform:uppercase;letter-spacing:.8px;padding:3px 10px;border-radius:50px;background:rgba(26,111,191,0.1);color:var(--blue)}

/* ===== SHARED RESPONSIVE ===== */
@media(max-width:900px){
  .health-calc-page .info-grid{grid-template-columns:1fr}
  .health-calc-page .calc-results-grid{grid-template-columns:repeat(2,1fr)}
  .health-calc-page .stat-strip{flex-direction:column}
  .health-calc-page .stat-strip-item{border-right:none;border-bottom:1.5px solid var(--border)}
  .health-calc-page .stat-strip-item:last-child{border-bottom:none}
}
@media(max-width:600px){
  .health-calc-page .calc-card{padding:24px 18px}
  .health-calc-page .calc-form-row{flex-direction:column;align-items:stretch}
  .health-calc-page .calc-field input[type="time"],
  .health-calc-page .calc-field input[type="number"],
  .health-calc-page .calc-field select{width:100%}
  .health-calc-page .calc-btn-row{width:100%}
  .health-calc-page .calc-btn{flex:1}
  .health-calc-page .calc-tabs{max-width:100%}
  .health-calc-page .tool-section{padding:40px 0}
}

/* =====================================================================
   PAGE-SPECIFIC: Sleep Cycle Calculator (.hc-sleep)
   ===================================================================== */
.hc-sleep .calc-form-row{flex-direction:column;align-items:flex-start}

/* =====================================================================
   PAGE-SPECIFIC: Water Intake Calculator (.hc-water)
   ===================================================================== */
.hc-water .water-visual{display:flex;justify-content:center;margin:8px 0 26px}
.hc-water .bottle{width:64px;height:110px;border:3px solid rgba(255,255,255,0.5);border-radius:0 0 14px 14px;position:relative;overflow:hidden;background:rgba(255,255,255,0.06)}
.hc-water .bottle::before{content:'';position:absolute;top:-14px;left:50%;transform:translateX(-50%);width:22px;height:16px;background:rgba(255,255,255,0.5);border-radius:4px 4px 0 0}
.hc-water .bottle-fill{position:absolute;bottom:0;left:0;right:0;background:var(--grad2);height:0%;transition:height 1s ease}
.hc-water .stage-row{justify-content:space-between}
.hc-water .stage-left{display:flex;align-items:center;gap:14px}
.hc-water .stage-amount{font-size:13.5px;font-weight:800;color:var(--blue);white-space:nowrap}
@media(max-width:600px){
  .hc-water .stage-row{flex-direction:column;align-items:flex-start;gap:6px}
}

/* =====================================================================
   PAGE-SPECIFIC: Heart Rate Zone Calculator (.hc-heart)
   ===================================================================== */
/* Keep Age + Resting HR inputs aligned even though the resting-HR field
   carries a helper note. On desktop the note is taken out of flow so both
   field columns are the same height and their inputs line up. */
@media(min-width:601px){
  .hc-heart .calc-field{position:relative}
  .hc-heart .calc-field-note{position:absolute;top:calc(100% + 8px);left:0;margin:0;white-space:nowrap}
  .hc-heart .calc-form-row{margin-bottom:34px}
}

.hc-heart .hc-stat-row{display:grid;grid-template-columns:repeat(3,1fr);gap:14px;margin-bottom:22px}
.hc-heart .hc-stat{background:rgba(255,255,255,0.08);border:1.5px solid rgba(255,255,255,0.16);border-radius:16px;padding:18px;text-align:center}
.hc-heart .hc-stat .num{font-size:24px;font-weight:800;color:#fff;display:block;font-variant-numeric:tabular-nums}
.hc-heart .hc-stat .lbl{font-size:11px;font-weight:700;color:rgba(255,255,255,0.6);text-transform:uppercase;letter-spacing:.6px;margin-top:4px;display:block}

.hc-heart .zone-list{display:flex;flex-direction:column;gap:10px}
.hc-heart .zone-row{display:flex;align-items:center;gap:16px;background:rgba(255,255,255,0.08);border:1.5px solid rgba(255,255,255,0.16);border-radius:16px;padding:14px 18px;position:relative;overflow:hidden}
.hc-heart .zone-row::before{content:'';position:absolute;left:0;top:0;bottom:0;width:6px}
.hc-heart .zone-row.z1::before{background:#6EE7F0}
.hc-heart .zone-row.z2::before{background:#22D3EE}
.hc-heart .zone-row.z3::before{background:#FBBF24}
.hc-heart .zone-row.z4::before{background:#FB923C}
.hc-heart .zone-row.z5::before{background:#EF4444}
.hc-heart .zone-num{width:34px;height:34px;border-radius:10px;display:flex;align-items:center;justify-content:center;font-size:14px;font-weight:800;color:#fff;flex-shrink:0;margin-left:6px}
.hc-heart .zone-row.z1 .zone-num{background:#22D3EE}
.hc-heart .zone-row.z2 .zone-num{background:#0EA5E9}
.hc-heart .zone-row.z3 .zone-num{background:#F59E0B}
.hc-heart .zone-row.z4 .zone-num{background:#FB923C}
.hc-heart .zone-row.z5 .zone-num{background:#EF4444}
.hc-heart .zone-body{flex:1;min-width:0}
.hc-heart .zone-body h4{font-size:14px;font-weight:700;color:#fff}
.hc-heart .zone-body p{font-size:12px;color:rgba(255,255,255,0.6);margin-top:2px}
.hc-heart .zone-range{text-align:right;flex-shrink:0}
.hc-heart .zone-range .bpm{font-size:16px;font-weight:800;color:#fff;font-variant-numeric:tabular-nums;display:block}
.hc-heart .zone-range .pct{font-size:11px;color:rgba(255,255,255,0.55);font-weight:600}

@media(max-width:900px){
  .hc-heart .hc-stat-row{grid-template-columns:1fr}
}
@media(max-width:600px){
  .hc-heart .zone-row{flex-wrap:wrap}
  .hc-heart .zone-range{text-align:left;margin-left:50px}
}
