/* ============================================================
   Hoover Buildings — 5% Thanksgiving promo
   1) site-wide pop-up (includes/promo-popup.php)
   2) Meta-ads landing page additions (pages/thanksgiving-offer.php,
      layered on top of css/custom-quote.css)
   All colors come from the brand tokens in css/style.css.
   ============================================================ */

:root{
  /* Promo colors are the site's own brand tokens (css/style.css) — red band,
     gold highlights, dark/gray neutrals — so the offer matches the main site. */
  --promo-band:linear-gradient(135deg,var(--red-darker) 0%,var(--red-dark) 45%,var(--red) 100%);
  --promo-highlight:var(--gold);
  --promo-section:var(--gray-50);
}

/* ============================================================
   1) POP-UP
   ============================================================ */
html.promo-pop-open{overflow:hidden}

.promo-pop{position:fixed;inset:0;z-index:200;display:flex;align-items:center;justify-content:center;padding:20px}
.promo-pop[hidden]{display:none}

.promo-pop-backdrop{
  position:absolute;inset:0;background:rgba(12,10,8,.62);
  opacity:0;transition:opacity .25s ease;
}
.promo-pop-card{
  position:relative;width:100%;max-width:460px;max-height:calc(100vh - 40px);overflow-y:auto;
  background:#fff;color:var(--ink);border-radius:var(--radius-lg);box-shadow:0 30px 80px rgba(0,0,0,.35);
  opacity:0;transform:translateY(16px) scale(.98);transition:opacity .25s ease,transform .25s ease;
  overscroll-behavior:contain;
}
.promo-pop.is-visible .promo-pop-backdrop{opacity:1}
.promo-pop.is-visible .promo-pop-card{opacity:1;transform:none}

/* big, obvious close — no hunting for a tiny X */
.promo-pop-close{
  position:absolute;top:12px;right:12px;z-index:2;
  width:42px;height:42px;border-radius:50%;
  display:flex;align-items:center;justify-content:center;
  background:#fff;color:var(--ink);box-shadow:0 4px 14px rgba(0,0,0,.22);
  transition:transform .15s ease,background .15s ease;
}
.promo-pop-close:hover{background:var(--gray-50);transform:scale(1.06)}
.promo-pop-close:focus-visible{outline:3px solid var(--gold);outline-offset:2px}
.promo-pop-close svg{width:20px;height:20px;stroke:currentColor;stroke-width:2.6;stroke-linecap:round;fill:none}

/* -------- autumn offer band (shared with the landing page badge) -------- */
.promo-band{
  position:relative;overflow:hidden;
  background:var(--promo-band);color:#fff;text-align:center;
  padding:26px 60px 22px;
}
.promo-band::before,
.promo-band::after{
  content:'';position:absolute;border-radius:50%;pointer-events:none;
  background:radial-gradient(circle,rgba(255,255,255,.14),rgba(255,255,255,0) 70%);
}
.promo-band::before{width:180px;height:180px;left:-60px;top:-70px}
.promo-band::after{width:220px;height:220px;right:-80px;bottom:-110px}
.promo-band-kicker{
  position:relative;display:inline-block;
  font-size:.72rem;font-weight:800;letter-spacing:.16em;text-transform:uppercase;color:var(--promo-highlight);
}
.promo-band-big{
  position:relative;font-family:var(--font-head);line-height:1;margin:6px 0 6px;
  display:flex;align-items:baseline;justify-content:center;gap:10px;
}
.promo-band-big strong{font-size:4rem;font-weight:900;letter-spacing:-.02em}
.promo-band-big span{font-size:1.9rem;font-weight:800;text-transform:uppercase;color:var(--promo-highlight)}
.promo-band-sub{position:relative;font-size:.85rem;font-weight:600;color:rgba(255,255,255,.88)}

/* -------- body + form -------- */
.promo-pop-body,
.promo-pop-done{padding:22px 26px 20px}
.promo-pop-title{font-size:1.3rem;font-weight:800;margin-bottom:6px;color:var(--ink)}
.promo-pop-lead{font-size:.9rem;color:var(--gray-700);margin-bottom:16px}
.promo-pop-lead a{color:var(--red);font-weight:700}

.promo-error{display:none;background:#fdecec;color:var(--red-dark);border:1px solid #f6c6c8;border-radius:8px;padding:9px 12px;font-size:.82rem;font-weight:600;margin-bottom:12px}
.promo-error.show{display:block}

.promo-form{display:flex;flex-direction:column;gap:12px}
.promo-row{display:grid;grid-template-columns:1fr 1fr;gap:12px}
.promo-field{display:flex;flex-direction:column;gap:5px}
.promo-field span{font-size:.75rem;font-weight:700;color:var(--gray-700)}
.promo-field input,
.promo-field select{
  width:100%;border:1.5px solid var(--gray-100);background:var(--gray-50);border-radius:10px;
  padding:11px 13px;font-size:16px;color:var(--ink); /* 16px: stops iOS zooming on focus */
  transition:border-color .15s ease,background .15s ease;
}
.promo-field input:focus,
.promo-field select:focus{outline:none;border-color:var(--red);background:#fff}
.promo-field select{
  appearance:none;-webkit-appearance:none;cursor:pointer;padding-right:32px;
  background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%23767981' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat:no-repeat;background-position:right 13px center;
}
.promo-honeypot{position:absolute;left:-9999px;top:-9999px;opacity:0;height:0;width:0;pointer-events:none}

.promo-cta{
  width:100%;display:flex;align-items:center;justify-content:center;gap:8px;
  margin-top:4px;padding:15px 20px;border-radius:999px;
  background:var(--red);color:#fff;font-weight:800;font-size:.95rem;letter-spacing:.02em;text-transform:uppercase;
  box-shadow:0 10px 24px rgba(227,30,36,.3);transition:filter .15s ease,transform .15s ease;
}
.promo-cta:hover{filter:brightness(1.06)}
.promo-cta:active{transform:translateY(1px)}
.promo-cta:disabled{opacity:.7;cursor:not-allowed}

.promo-fine{font-size:.68rem;line-height:1.5;color:var(--gray-500)}

.promo-nothanks{
  display:block;margin:12px auto 0;padding:6px 10px;
  font-size:.82rem;font-weight:600;color:var(--gray-500);text-decoration:underline;text-underline-offset:3px;
}
.promo-nothanks:hover{color:var(--ink)}

.promo-pop-done{text-align:center;padding-top:28px;padding-bottom:26px}
.promo-done-icon{
  width:60px;height:60px;border-radius:50%;margin:0 auto 16px;
  display:flex;align-items:center;justify-content:center;background:#e8f7ee;color:#1a8f4a;
}
.promo-done-icon svg{width:30px;height:30px;stroke:currentColor;stroke-width:2.6;fill:none;stroke-linecap:round;stroke-linejoin:round}
.promo-pop-done .promo-pop-lead{margin-bottom:20px}

/* -------- phones: slide-up bottom sheet, thumb-reachable -------- */
@media (max-width:600px){
  .promo-pop{align-items:flex-end;padding:0}
  .promo-pop-card{
    max-width:none;max-height:92vh;max-height:92dvh;
    border-radius:20px 20px 0 0;transform:translateY(100%);
    padding-bottom:env(safe-area-inset-bottom);
  }
  .promo-band{padding:22px 58px 18px}
  .promo-band-big strong{font-size:3.3rem}
  .promo-band-big span{font-size:1.6rem}
  .promo-pop-body{padding:18px 18px 14px}
  .promo-pop-title{font-size:1.15rem}
}
@media (max-width:380px){
  .promo-row{grid-template-columns:1fr}
}
@media (prefers-reduced-motion:reduce){
  .promo-pop-backdrop,.promo-pop-card{transition:none}
}

/* ============================================================
   2) META LANDING PAGE  (/thanksgiving-offer/)
   ============================================================ */
/* The hero itself is the homepage's .hero (css/style.css) — only the
   promo-specific bits live here. */
.tg-accent{color:var(--gold)}

.tg-countdown{
  display:flex;gap:10px;margin:-8px 0 30px;
}
.tg-countdown[hidden]{display:none}
.tg-count-unit{
  min-width:68px;padding:10px 8px;border-radius:12px;
  background:rgba(255,255,255,.1);border:1px solid rgba(255,255,255,.18);
  display:flex;flex-direction:column;align-items:center;line-height:1.1;
}
.tg-count-unit strong{font-family:var(--font-head);font-size:1.6rem;font-weight:800;color:#fff}
.tg-count-unit small{font-size:.62rem;font-weight:700;letter-spacing:.1em;text-transform:uppercase;color:var(--promo-highlight);margin-top:3px}

/* the card reuses the promo band as its header strip */
.tg-card{padding:0;overflow:hidden;scroll-margin-top:110px} /* clear the sticky header on #claim jumps */
/* compact one-row band: big "5% OFF" left, kicker + details stacked right */
.tg-card .promo-band{
  display:grid;grid-template-columns:auto auto;grid-template-areas:"big kicker" "big sub";
  justify-content:center;align-items:center;column-gap:20px;row-gap:2px;
  padding:16px 24px;text-align:left;
}
.tg-card .promo-band-big{grid-area:big;margin:0;padding-right:20px;border-right:1px solid rgba(255,255,255,.28)}
.tg-card .promo-band-big strong{font-size:3.2rem}
.tg-card .promo-band-big span{font-size:1.5rem}
.tg-card .promo-band-kicker{grid-area:kicker;align-self:end}
.tg-card .promo-band-sub{grid-area:sub;align-self:start}
.tg-card-body{padding:22px 26px 24px}
.tg-card-body .qe-label{margin-bottom:10px}
.tg-card-body .qe-label .req{color:var(--red)}
.tg-card-body .qe-field > label{font-size:.85rem;color:var(--ink)} /* step-1 questions read like the numbered "1." label */
.tg-card-body .qe-step[data-step="2"] .qe-field > label{font-size:.78rem;color:var(--gray-700)}

/* "how it works" strip */
.tg-steps{background:var(--promo-section);padding:56px 0}
.tg-steps h2{text-align:center;font-size:clamp(1.5rem,2.6vw,2rem);margin-bottom:32px}
.tg-steps-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:22px;max-width:1080px;margin:0 auto}
.tg-step{background:#fff;border-radius:var(--radius);padding:26px 24px;box-shadow:var(--shadow);text-align:center}
.tg-step-num{
  width:42px;height:42px;border-radius:50%;margin:0 auto 14px;
  display:flex;align-items:center;justify-content:center;
  background:var(--red);color:#fff;font-family:var(--font-head);font-weight:800;font-size:1.1rem;
}
.tg-step h3{font-size:1.05rem;margin-bottom:6px}
.tg-step p{font-size:.88rem;color:var(--gray-700)}

.tg-terms{max-width:760px;margin:0 auto;padding:22px 24px 30px;text-align:center;font-size:.72rem;color:var(--gray-500);line-height:1.6}

/* Once .hero stacks (≤1080px, css/style.css) — tablets and phones — center
   the copy and the form card (landing page only; homepage stays left). */
@media (max-width:1080px){
  .tg-hero .hero-copy{text-align:center}
  .tg-hero p.lead{margin-left:auto;margin-right:auto}
  .tg-hero .tg-countdown{justify-content:center}
  .tg-hero .hero-cta{justify-content:center}
  .tg-hero .hero-card{max-width:620px;margin-left:auto;margin-right:auto}
}

@media (max-width:767px){
  .tg-steps{padding:40px 0}
  .tg-steps-grid{grid-template-columns:1fr;gap:14px}
  .tg-count-unit{min-width:58px}
  .tg-count-unit strong{font-size:1.3rem}
}
@media (max-width:480px){
  .tg-card-body{padding:20px 18px 20px}
  .tg-card .promo-band{column-gap:14px;padding:14px 16px}
  .tg-card .promo-band-big{padding-right:14px}
  .tg-card .promo-band-big strong{font-size:2.5rem}
  .tg-card .promo-band-big span{font-size:1.15rem}
  .tg-card .promo-band-kicker{font-size:.64rem;letter-spacing:.1em}
  .tg-card .promo-band-sub{font-size:.76rem}
}
