/**
 * Homecare luxury texture system
 * Soft burgundy/gold grain, micro-dot wash, and HSC-style wavy atmosphere.
 * Link after portal-nav.css (also injected by portal-nav.js on homeCareSector).
 * Colours stay burgundy/gold — texture only.
 */
:root{
  --hc-burgundy:#6B2340;
  --hc-burgundy-deep:#4A152C;
  --hc-gold:#C4A574;
  --hc-dot:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' viewBox='0 0 18 18'%3E%3Ccircle cx='1.5' cy='1.5' r='1.05' fill='%236B2340' fill-opacity='.055'/%3E%3C/svg%3E");
  --hc-grain:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140' viewBox='0 0 140 140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.82' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 0.42 0 0 0 0 0.14 0 0 0 0 0.25 0 0 0 0.05 0'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)'/%3E%3C/svg%3E");
  --hc-gold-grain:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160' viewBox='0 0 160 160'%3E%3Cfilter id='g'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.7' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 0.77 0 0 0 0 0.65 0 0 0 0 0.45 0 0 0 0.04 0'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23g)'/%3E%3C/svg%3E");
  /* Soft repeating wave lines (burgundy + champagne) */
  --hc-waves:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='280' height='140' viewBox='0 0 280 140'%3E%3Cpath d='M0 28 C35 8 70 48 105 28 S175 8 210 28 245 48 280 28' fill='none' stroke='%236B2340' stroke-opacity='.07' stroke-width='1.25'/%3E%3Cpath d='M0 56 C35 36 70 76 105 56 S175 36 210 56 245 76 280 56' fill='none' stroke='%23C4A574' stroke-opacity='.08' stroke-width='1.1'/%3E%3Cpath d='M0 84 C35 64 70 104 105 84 S175 64 210 84 245 104 280 84' fill='none' stroke='%236B2340' stroke-opacity='.05' stroke-width='1.15'/%3E%3Cpath d='M0 112 C35 92 70 132 105 112 S175 92 210 112 245 132 280 112' fill='none' stroke='%23C4A574' stroke-opacity='.06' stroke-width='1'/%3E%3C/svg%3E");
  /* Larger organic wavy wash (low-frequency turbulence) */
  --hc-wave-wash:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='420' height='420' viewBox='0 0 420 420'%3E%3Cfilter id='w'%3E%3CfeTurbulence type='turbulence' baseFrequency='0.012 0.028' numOctaves='2' seed='7' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 0.42 0 0 0 0 0.14 0 0 0 0 0.25 0 0 0 0.045 0'/%3E%3C/filter%3E%3Crect width='420' height='420' filter='url(%23w)'/%3E%3C/svg%3E");
}

/* Soft textured page wash + wavy atmosphere (palette unchanged) */
body.portal-body.portal-body--homecare,
#page-homecare.portal-body{
  background:
    radial-gradient(1100px 520px at -8% -6%, rgba(107,35,64,.09), transparent 58%),
    radial-gradient(900px 460px at 100% 0%, rgba(196,165,116,.13), transparent 55%),
    radial-gradient(700px 380px at 50% 85%, rgba(107,35,64,.04), transparent 70%),
    var(--hc-waves),
    var(--hc-dot),
    linear-gradient(180deg, #f6f2f3 0%, #f1ecee 42%, #f7f4f5 100%) !important;
  background-size:auto, auto, auto, 280px 140px, 18px 18px, auto !important;
  background-attachment:fixed !important;
}

/* Ambient photo sits quieter under the grain wash */
body.portal-body--homecare .bg-image-wrap,
#page-homecare .bg-image-wrap{
  opacity:.22 !important;
  mix-blend-mode:multiply;
}

/* Fixed grain + wavy veil over the page */
body.portal-body--homecare::before,
#page-homecare.portal-body::before{
  content:"";
  position:fixed;
  inset:0;
  z-index:0;
  pointer-events:none;
  background:
    var(--hc-wave-wash),
    var(--hc-waves),
    var(--hc-grain),
    var(--hc-gold-grain);
  background-size:420px 420px, 280px 140px, 140px 140px, 160px 160px;
  opacity:.62;
}

/* Soft wave ribbons (top / mid / bottom) — texture only, same palette */
body.portal-body--homecare::after,
#page-homecare.portal-body::after{
  content:"";
  position:fixed;
  inset:0;
  z-index:0;
  pointer-events:none;
  background:
    radial-gradient(120% 42% at 10% -8%, rgba(107,35,64,.07), transparent 58%),
    radial-gradient(110% 38% at 92% 18%, rgba(196,165,116,.09), transparent 60%),
    radial-gradient(120% 46% at 50% 108%, rgba(107,35,64,.06), transparent 62%),
    var(--hc-waves);
  background-size:auto, auto, auto, 320px 160px;
  opacity:.55;
  -webkit-mask-image:linear-gradient(180deg, rgba(0,0,0,.55), rgba(0,0,0,.2) 45%, rgba(0,0,0,.5));
  mask-image:linear-gradient(180deg, rgba(0,0,0,.55), rgba(0,0,0,.2) 45%, rgba(0,0,0,.5));
}

body.portal-body--homecare .page,
#page-homecare .page,
body.portal-body--homecare .portal-page-main,
body.portal-body--homecare #portal-footer-mount{
  position:relative;
  z-index:1;
}
/* Nav mount holds the mobile drawer — keep it well above any in-page
   decorative z-index:1/2 promotions (hero/section/cta wrappers above)
   so the mobile menu can never be out-stacked by page content. */
body.portal-body--homecare #portal-nav-mount{
  position:relative;
  z-index:100;
}

/* Hero copy panel — linen + grain */
#page-homecare .sh-left{
  position:relative;
  z-index:0;
  overflow:hidden;
  background:
    radial-gradient(920px 420px at -10% 0%, rgba(107,35,64,.12), transparent 62%),
    radial-gradient(720px 360px at 92% 100%, rgba(196,165,116,.16), transparent 58%),
    linear-gradient(165deg, rgba(255,252,251,.92) 0%, rgba(247,241,243,.88) 55%, rgba(243,236,238,.9) 100%),
    var(--hc-grain) !important;
}
#page-homecare .sh-left::after{
  content:"";
  position:absolute;
  inset:0;
  pointer-events:none;
  background:var(--hc-waves), var(--hc-dot);
  background-size:280px 140px, 18px 18px;
  opacity:.7;
  z-index:0;
}
#page-homecare .sh-left > *{position:relative;z-index:1;}

/* Sections — soft paper panels with micro-dot */
#page-homecare .section{
  position:relative;
  z-index:0;
  overflow:hidden;
  background:
    linear-gradient(160deg, rgba(255,255,255,.92) 0%, rgba(250,245,246,.88) 55%, rgba(246,240,242,.86) 100%),
    var(--hc-dot);
  border:1px solid rgba(196,165,116,.28);
  border-radius:18px;
  box-shadow:
    0 10px 28px rgba(74,21,44,.05),
    inset 0 1px 0 rgba(255,255,255,.85);
  margin-top:18px;
  margin-bottom:8px;
}
#page-homecare .section::after{
  content:"";
  position:absolute;
  inset:0;
  pointer-events:none;
  background:var(--hc-waves), var(--hc-grain);
  background-size:280px 140px, 140px 140px;
  opacity:.4;
  z-index:0;
}
#page-homecare .section > *{position:relative;z-index:1;}
#page-homecare .section::before{
  z-index:2;
}

/* Cards — subtle grain lift (no ::after — pathways use that for dividers) */
#page-homecare .hub-card{
  position:relative;
  overflow:hidden;
  background:
    radial-gradient(160px 100px at 10% 0%, rgba(196,165,116,.10), transparent 70%),
    linear-gradient(165deg, rgba(255,255,255,.97) 0%, rgba(252,248,249,.94) 100%),
    var(--hc-dot),
    var(--hc-grain) !important;
}
#page-homecare #pathways .hub-card{
  overflow:visible;
}

/* Stats + CTA — champagne paper */
#page-homecare .stats-row{
  background:
    linear-gradient(180deg, rgba(255,253,251,.9) 0%, rgba(250,244,246,.86) 100%),
    var(--hc-grain) !important;
}
#page-homecare .cta-band{
  background:linear-gradient(120deg, rgba(74,21,44,.96), rgba(107,35,64,.9) 45%, rgba(196,165,116,.88)) !important;
  border-color:rgba(196,165,116,.35) !important;
  color:#fff !important;
  box-shadow:0 18px 40px rgba(74,21,44,.16) !important;
}
#page-homecare .cta-band::after{
  content:"";
  position:absolute;
  inset:0;
  pointer-events:none;
  background:var(--hc-dot);
  opacity:.18;
  z-index:0;
}
#page-homecare .cta-band > *{position:relative;z-index:1;}
#page-homecare .cta-band .cta-t{color:#fff !important;}
#page-homecare .cta-band .cta-d{color:rgba(255,255,255,.92) !important;}
#page-homecare .cta-band .cta-d strong{color:#fff !important;}
#page-homecare .cta-band .btn-accent{
  background:#fff !important;
  color:#4A152C !important;
  box-shadow:0 8px 20px rgba(74,21,44,.18) !important;
}
#page-homecare .cta-band .btn-ghost{
  color:#fff !important;
  background:rgba(255,255,255,.1) !important;
  border-color:rgba(255,255,255,.4) !important;
}
#page-homecare .cta-band .btn-ghost:hover{
  background:rgba(255,255,255,.18) !important;
  color:#fff !important;
  border-color:rgba(255,255,255,.6) !important;
}

/* Footer sits on the same wash */
#page-homecare .site-footer{
  background:
    linear-gradient(180deg, rgba(255,252,251,.78) 0%, rgba(247,242,243,.88) 100%),
    var(--hc-dot);
}

/* Service detail page (homecare-detail.html) */
body.portal-body--homecare:not(#page-homecare) .hero,
body.hc-detail .hero{
  position:relative;
  z-index:0;
  overflow:hidden;
  background:
    linear-gradient(145deg, rgba(255,253,251,.96) 0%, rgba(249,242,244,.92) 55%, rgba(246,239,232,.9) 100%),
    var(--hc-grain) !important;
  border-color:rgba(196,165,116,.35) !important;
}
body.portal-body--homecare:not(#page-homecare) .hero::after,
body.hc-detail .hero::after{
  content:"";
  position:absolute;
  inset:0;
  pointer-events:none;
  background:var(--hc-dot);
  opacity:.4;
  z-index:0;
}
body.portal-body--homecare:not(#page-homecare) .hero > *,
body.hc-detail .hero > *{position:relative;z-index:1;}

@media (prefers-reduced-motion:reduce){
  body.portal-body.portal-body--homecare,
  #page-homecare.portal-body{
    background-attachment:scroll !important;
  }
}

/* Shared heading scale — match HSC / Education */
#page-homecare .sh-h1,
.portal-body--homecare .portal-hero h1{
  font-size:clamp(28px,3.6vw,42px) !important;
}
#page-homecare .sec-t{
  font-size:clamp(28px,3.5vw,40px) !important;
}
#page-homecare .hub-card h3,
#page-homecare .pathway-card h3{
  font-size:clamp(18px,1.6vw,22px) !important;
}
.portal-body--homecare .portal-hero h1{
  font-size:clamp(28px,3.6vw,42px) !important;
}
