/* Bid2Stay 28.23.2 — Contrast & Text Containment Lock
   Permanent visual-safety layer for public, guest and provider surfaces.
   CSS only: no workflow, routing, JS, auth or Supabase changes. */

:root{
  --b2s-lock-navy:#071b2a;
  --b2s-lock-navy-2:#0b1d2e;
  --b2s-lock-ink:#172536;
  --b2s-lock-gold:#f7b91f;
  --b2s-lock-gold-2:#d8a51d;
  --b2s-lock-white:#ffffff;
  --b2s-lock-light:#f8fafc;
  --b2s-lock-muted-light:#c5cfda;
  --b2s-lock-muted:#667585;
  --b2s-lock-line:#dce3e9;
}

/* ---------------------------------------------------------
   1. TEXT-FILL RESET
   Old production layers used -webkit-text-fill-color in places.
   Keep text-fill bound to the final computed color so Safari/Chrome
   cannot preserve a stale dark label on a dark surface.
   --------------------------------------------------------- */
body.b2s-global-public :where(h1,h2,h3,h4,h5,h6,p,span,strong,b,small,label,a,button),
body[data-portal-role="guest"] :where(h1,h2,h3,h4,h5,h6,p,span,strong,b,small,label,a,button),
body[data-portal-role="provider"] :where(h1,h2,h3,h4,h5,h6,p,span,strong,b,small,label,a,button),
body.b2s-provider-portal :where(h1,h2,h3,h4,h5,h6,p,span,strong,b,small,label,a,button),
body.b2s-provider-accept-page :where(h1,h2,h3,h4,h5,h6,p,span,strong,b,small,label,a,button),
body.b2s-provider-submitted-page :where(h1,h2,h3,h4,h5,h6,p,span,strong,b,small,label,a,button){
  -webkit-text-fill-color:currentColor!important;
}

body.b2s-global-public :where(input,select,textarea),
body[data-portal-role="guest"] :where(input,select,textarea),
body[data-portal-role="provider"] :where(input,select,textarea){
  -webkit-text-fill-color:currentColor!important;
}

/* ---------------------------------------------------------
   2. PUBLIC HEADER / MENU CONTRAST LOCK
   --------------------------------------------------------- */
.b2s-global-header{
  background:#0b1016!important;
  border-bottom:1px solid rgba(247,185,31,.28)!important;
  color:#fff!important;
}
.b2s-global-header .b2s-global-nav a{
  color:#eef3f7!important;
  -webkit-text-fill-color:#eef3f7!important;
}
.b2s-global-header .b2s-global-nav a:hover,
.b2s-global-header .b2s-global-nav a[aria-current="page"]{
  color:var(--b2s-lock-gold)!important;
  -webkit-text-fill-color:var(--b2s-lock-gold)!important;
}
.b2s-global-header :is(.b2s-global-login,.b2s-session-account,.b2s-session-signout){
  color:#fff!important;
  -webkit-text-fill-color:#fff!important;
  border-color:rgba(255,255,255,.28)!important;
}
.b2s-global-header :is(.b2s-global-login,.b2s-session-account,.b2s-session-signout):hover{
  color:var(--b2s-lock-gold)!important;
  -webkit-text-fill-color:var(--b2s-lock-gold)!important;
  border-color:rgba(247,185,31,.48)!important;
}

/* ---------------------------------------------------------
   3. DARK SURFACES ALWAYS OWN LIGHT TYPOGRAPHY
   --------------------------------------------------------- */
:is(.b2s28162-hero,.b2s28162-cta,.b2s28162-facts,
    .b2s-home-hero,.b2s-home-provider,.b2s-journey-intro,
    .b2s-about-hero,.b2s-about-cta,
    .b2s-contact-intro,.b2s-contact-card,
    .b2s-auth-card.b2s-login-card,.b2s-public-login-card){
  color:#fff!important;
}

.b2s28162-hero :is(h1,h2,h3,strong),
.b2s28162-cta :is(h1,h2,h3,strong),
.b2s28162-facts :is(h1,h2,h3,strong),
.b2s-home-hero :is(h1,h2,h3,strong),
.b2s-home-provider :is(h1,h2,h3,strong),
.b2s-journey-intro :is(h1,h2,h3,strong),
.b2s-about-hero :is(h1,h2,h3,strong),
.b2s-about-cta :is(h1,h2,h3,strong),
.b2s-contact-intro :is(h1,h2,h3,strong),
.b2s-contact-card :is(h1,h2,h3,strong,label){
  color:#fff!important;
  -webkit-text-fill-color:#fff!important;
  opacity:1!important;
}

.b2s28162-hero p,
.b2s28162-cta p,
.b2s-home-hero p,
.b2s-home-provider p,
.b2s-journey-intro p,
.b2s-about-hero p,
.b2s-about-cta p,
.b2s-contact-intro>p,
.b2s-contact-card p,
.b2s-contact-card .b2s-contact-note{
  color:var(--b2s-lock-muted-light)!important;
  -webkit-text-fill-color:var(--b2s-lock-muted-light)!important;
  opacity:1!important;
}

.b2s28162-hero :is(.b2s28162-kicker,.b2s28162-eyebrow),
.b2s28162-cta :is(.b2s28162-kicker,.b2s28162-eyebrow),
.b2s-home-hero .b2s-home-kicker,
.b2s-home-provider .b2s-home-kicker,
.b2s-about-hero :is(.kicker,[class*="kicker"],[class*="eyebrow"]),
.b2s-contact-intro .b2s-contact-eyebrow{
  color:var(--b2s-lock-gold)!important;
  -webkit-text-fill-color:var(--b2s-lock-gold)!important;
}

/* Destination detail — the exact surfaces shown in QA. */
.b2s28162-hero h1,
.b2s28162-cta h2{
  color:#fff!important;
  -webkit-text-fill-color:#fff!important;
}
.b2s28162-facts small{color:#aeb9c7!important;-webkit-text-fill-color:#aeb9c7!important}
.b2s28162-facts strong{color:#fff!important;-webkit-text-fill-color:#fff!important}

/* Contact enquiry card — labels/titles must never inherit dark body text. */
.b2s-contact-card{
  background:rgba(6,16,27,.92)!important;
  border-color:rgba(255,255,255,.38)!important;
}
.b2s-contact-card :is(input,select,textarea){
  background:#fff!important;
  color:#172536!important;
  -webkit-text-fill-color:#172536!important;
  border-color:#d8e0e8!important;
  opacity:1!important;
}
.b2s-contact-card :is(input,textarea)::placeholder{
  color:#8795a8!important;
  -webkit-text-fill-color:#8795a8!important;
  opacity:1!important;
}

/* ---------------------------------------------------------
   4. ACTION CONTRAST — DARK MEANS LIGHT TEXT; GOLD MEANS DARK TEXT
   --------------------------------------------------------- */
.b2s28162-actions .secondary,
.b2s-btn-ghost,
.b2s-btn-dark,
.b2s-directions-actions .secondary,
.b2s-about-hero-actions .secondary,
.b2s-cta-actions .secondary{
  color:#fff!important;
  -webkit-text-fill-color:#fff!important;
}

.b2s28162-actions .primary,
.b2s-btn-primary,
.b2s-contact-submit,
#b2sContactSend,
.b2s-about-hero-actions .primary,
.b2s-cta-actions .primary{
  color:var(--b2s-lock-navy)!important;
  -webkit-text-fill-color:var(--b2s-lock-navy)!important;
}

/* Generic dark navigation / CTA classes used by older public bundles. */
body.b2s-global-public :is(.btn.dark,button.dark,.dark.btn,.navy-button,[data-variant="dark"]),
body[data-portal-role="guest"] :is(.btn.dark,button.dark,.dark.btn,.navy-button,[data-variant="dark"]),
body[data-portal-role="provider"] :is(.btn.dark,button.dark,.dark.btn,.navy-button,[data-variant="dark"]){
  color:#fff!important;
  -webkit-text-fill-color:#fff!important;
}

body.b2s-global-public :is(.btn.primary,button.primary,.primary.btn),
body[data-portal-role="guest"] :is(.btn.primary,button.primary,.primary.btn),
body[data-portal-role="provider"] :is(.btn.primary,button.primary,.primary.btn){
  color:var(--b2s-lock-navy)!important;
  -webkit-text-fill-color:var(--b2s-lock-navy)!important;
}

/* ---------------------------------------------------------
   5. LIGHT CARD TYPOGRAPHY LOCK
   --------------------------------------------------------- */
:is(.b2s28162-about,.b2s-how-card,.b2s-journey-choice,.b2s-contact-field,
    .b2s30-destination-card,.destination-card,.b2s-auth-recovery-card){
  min-width:0!important;
  max-width:100%!important;
}
.b2s28162-about :is(h1,h2,h3,strong),
.b2s-how-card :is(h1,h2,h3,strong),
.b2s-journey-choice strong,
.destination-card :is(h1,h2,h3,strong){
  color:var(--b2s-lock-ink)!important;
  -webkit-text-fill-color:var(--b2s-lock-ink)!important;
}
.b2s28162-about p,
.b2s-how-card p,
.b2s-journey-choice small,
.destination-card p{
  color:var(--b2s-lock-muted)!important;
  -webkit-text-fill-color:var(--b2s-lock-muted)!important;
}

/* ---------------------------------------------------------
   6. TEXT CONTAINMENT / SINGLE-LINE COMPACT CONTROLS
   --------------------------------------------------------- */
body.b2s-global-public :where(h1,h2,h3,h4,h5,h6,p,li,strong,span,small,label),
body[data-portal-role="guest"] :where(h1,h2,h3,h4,h5,h6,p,li,strong,span,small,label),
body[data-portal-role="provider"] :where(h1,h2,h3,h4,h5,h6,p,li,strong,span,small,label){
  min-width:0!important;
  max-width:100%!important;
  overflow-wrap:break-word;
  word-break:normal;
}

body.b2s-global-public :where(button,.btn,[role="button"],.b2s-global-nav a,.b2s-global-actions a,
  .b2s28162-actions a,.b2s-home-hero-actions a,.b2s-journey-choice,.b2s-contact-submit,
  .b2s30-explore-all,.category,.booking-filter),
body[data-portal-role="guest"] :where(button,.btn,[role="button"],.b2s-guest-desktop-nav a,.b2s-mobile-overflow-links a),
body[data-portal-role="provider"] :where(button,.btn,[role="button"],.b2s-provider-desktop-nav a){
  min-width:0!important;
  max-width:100%!important;
  white-space:nowrap!important;
  overflow:hidden!important;
  text-overflow:ellipsis!important;
  overflow-wrap:normal!important;
  word-break:normal!important;
}

/* Prevent button/card labels from being clipped vertically by old fixed line-height rules. */
body.b2s-global-public :where(button,.btn,[role="button"],.b2s-global-nav a,.b2s-global-actions a,.b2s28162-actions a),
body[data-portal-role="guest"] :where(button,.btn,[role="button"]),
body[data-portal-role="provider"] :where(button,.btn,[role="button"]){
  line-height:1.15!important;
}

/* ---------------------------------------------------------
   7. MOBILE LOCK — same contrast rules, no desktop spill
   --------------------------------------------------------- */
@media(max-width:900px){
  .b2s-global-header .b2s-global-nav{
    background:#0b1016!important;
    color:#fff!important;
  }
  .b2s-global-header .b2s-global-nav a{
    color:#fff!important;
    -webkit-text-fill-color:#fff!important;
  }
  .b2s-global-header .b2s-global-nav a[aria-current="page"]{
    color:var(--b2s-lock-gold)!important;
    -webkit-text-fill-color:var(--b2s-lock-gold)!important;
  }
  .b2s28162-actions,
  .b2s-home-hero-actions,
  .b2s-about-hero-actions,
  .b2s-cta-actions,
  .b2s2039-empty-actions{
    max-width:100%!important;
  }
  .b2s28162-actions>a,
  .b2s-home-hero-actions>a,
  .b2s-about-hero-actions>a,
  .b2s-cta-actions>a,
  .b2s2039-empty-actions>a,
  .b2s2039-empty-actions>button{
    min-width:0!important;
    max-width:100%!important;
  }
}

/* 28.23.2.1 — Empty-result and support-strip contrast closure */
body.b2s-global-public .b2s30-explore-all,
body[data-portal-role="guest"] .b2s30-explore-all{
  color:#fff!important;
  -webkit-text-fill-color:#fff!important;
}

body.b2s-contact-page .b2s-production-support{
  background:rgba(255,255,255,.065)!important;
  border:1px solid rgba(247,185,31,.34)!important;
  color:#eef3f7!important;
}
body.b2s-contact-page .b2s-production-support strong{
  color:#fff!important;
  -webkit-text-fill-color:#fff!important;
}
body.b2s-contact-page .b2s-production-support a{
  color:var(--b2s-lock-gold)!important;
  -webkit-text-fill-color:var(--b2s-lock-gold)!important;
}
