/* Sun Elevated Roofing v2 — base tokens + shared components
   Brand palette taken from sunelevated.com (Elementor kit 11). */
:root {
  --navy: #0F1231;
  --orange: #ED8122;
  --sun: #FEC42D;
  --ink: #2A2A2A;
  --mist: #EFEFEF;
  --rule: #D3D3D3;
  --muted: #7A7A7A;
  --white: #FFFFFF;

  --navy-80: rgba(15, 18, 49, .8);
  --navy-60: rgba(15, 18, 49, .6);
  --navy-10: rgba(15, 18, 49, .08);

  --font: "Outfit", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;

  --gutter: clamp(16px, 4vw, 56px);
  --maxw: 1320px;
  --r-lg: 28px;
  --r-md: 18px;
  --r-sm: 10px;
  --ease: cubic-bezier(.2, .7, .1, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--mist);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img, svg, canvas { display: block; max-width: 100%; }
[hidden] { display: none !important; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; }
h1, h2, h3, h4 { font-weight: 500; line-height: 1.05; letter-spacing: -.02em; margin: 0; color: var(--navy); }
p { margin: 0 0 1em; }
:focus-visible { outline: 2px solid var(--orange); outline-offset: 3px; border-radius: 4px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.wrap { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 var(--gutter); }

/* ---------- type helpers ---------- */
.eyebrow {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--orange);
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.eyebrow::before { content: ""; width: 22px; height: 2px; background: currentColor; }
.eyebrow.on-dark { color: var(--sun); }
.display { font-size: clamp(44px, 7.4vw, 112px); font-weight: 500; line-height: .95; letter-spacing: -.035em; }
.h2 { font-size: clamp(34px, 4.6vw, 64px); }
.h3 { font-size: clamp(22px, 2vw, 28px); }
.lede { font-size: clamp(18px, 1.5vw, 21px); color: #4a4c5e; max-width: 60ch; }
.hl { color: var(--orange); }
.mono { font-family: var(--mono); }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 12px;
  padding: 16px 26px; border-radius: 100px; border: 0;
  font-weight: 500; font-size: 16px; line-height: 1;
  transition: transform .35s var(--ease), background .25s, color .25s, box-shadow .35s;
  white-space: nowrap;
}
.btn svg { width: 18px; height: 18px; transition: transform .35s var(--ease); }
.btn:hover svg { transform: translateX(4px); }
.btn-primary { background: var(--orange); color: var(--white); box-shadow: 0 10px 30px -12px rgba(237, 129, 34, .8); }
.btn-primary:hover { background: var(--navy); box-shadow: 0 10px 30px -12px rgba(15, 18, 49, .8); }
.btn-ghost { background: transparent; color: var(--navy); box-shadow: inset 0 0 0 1.5px var(--navy); }
.btn-ghost:hover { background: var(--navy); color: var(--white); }
.btn-ghost.on-dark { color: var(--white); box-shadow: inset 0 0 0 1.5px rgba(255, 255, 255, .5); }
.btn-ghost.on-dark:hover { background: var(--white); color: var(--navy); }
.btn-sun { background: var(--sun); color: var(--navy); }
.btn-sun:hover { background: var(--white); }

/* ---------- header ---------- */
.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 50;
  padding: 14px 0;
  transition: background .35s, box-shadow .35s, padding .35s, transform .45s var(--ease);
}
.site-header.scrolled { background: rgba(239, 239, 239, .86); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); box-shadow: 0 1px 0 var(--navy-10); padding: 8px 0; }
.site-header.hide { transform: translateY(-110%); }
.nav { display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.brand img { height: 42px; width: auto; }
.nav-links { display: flex; align-items: center; gap: 6px; list-style: none; margin: 0; padding: 6px; border-radius: 100px; background: rgba(255, 255, 255, .72); box-shadow: 0 1px 0 var(--navy-10), 0 12px 30px -20px var(--navy-60); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }
.nav-links a { display: block; padding: 10px 18px; border-radius: 100px; font-size: 15px; font-weight: 500; color: var(--navy); transition: background .25s, color .25s; }
.nav-links a:hover { background: var(--navy-10); }
.nav-links a[aria-current="page"] { background: var(--navy); color: var(--white); }
.nav-cta { display: flex; align-items: center; gap: 18px; }
.nav-phone { font-weight: 500; color: var(--navy); display: inline-flex; align-items: center; gap: 8px; font-size: 15px; }
.nav-phone svg { width: 16px; height: 16px; color: var(--orange); }
.nav-cta .btn { padding: 13px 20px; font-size: 15px; }
.menu-btn { display: none; width: 46px; height: 46px; border-radius: 50%; border: 0; background: var(--navy); color: var(--white); align-items: center; justify-content: center; }
.menu-btn span, .menu-btn span::before, .menu-btn span::after { display: block; width: 18px; height: 2px; background: currentColor; position: relative; transition: transform .3s var(--ease), background .2s; }
.menu-btn span::before, .menu-btn span::after { content: ""; position: absolute; left: 0; }
.menu-btn span::before { top: -6px; } .menu-btn span::after { top: 6px; }
body.menu-open .menu-btn span { background: transparent; }
body.menu-open .menu-btn span::before { transform: translateY(6px) rotate(45deg); }
body.menu-open .menu-btn span::after { transform: translateY(-6px) rotate(-45deg); }

.mobile-menu {
  position: fixed; inset: 0; z-index: 45; background: var(--navy); color: var(--white);
  padding: 110px var(--gutter) 40px; display: flex; flex-direction: column; gap: 6px;
  clip-path: circle(0% at calc(100% - 40px) 40px); transition: clip-path .6s var(--ease);
  visibility: hidden;
}
body.menu-open .mobile-menu { clip-path: circle(150% at calc(100% - 40px) 40px); visibility: visible; }
.mobile-menu a.big { font-size: 40px; font-weight: 500; letter-spacing: -.02em; padding: 6px 0; border-bottom: 1px solid rgba(255, 255, 255, .1); }
.mobile-menu .btn { margin-top: 28px; align-self: flex-start; }
.mobile-menu .meta { margin-top: auto; font-family: var(--mono); font-size: 13px; color: rgba(255, 255, 255, .6); }

@media (max-width: 1080px) {
  .nav-links, .nav-phone { display: none; }
  .menu-btn { display: inline-flex; }
}
@media (max-width: 560px) {
  .nav-cta .btn { display: none; }
  .brand img { height: 34px; }
}

/* ---------- sections ---------- */
.section { padding: clamp(80px, 11vw, 160px) 0; position: relative; }
.section.dark { background: var(--navy); color: rgba(255, 255, 255, .78); }
.section.dark h2, .section.dark h3 { color: var(--white); }
.section.white { background: var(--white); }
.sec-head { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: end; margin-bottom: clamp(40px, 6vw, 80px); }
.sec-head .h2 { margin-top: 18px; }
@media (max-width: 860px) { .sec-head { grid-template-columns: 1fr; gap: 18px; } }

/* reveal on scroll */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity .9s var(--ease), transform .9s var(--ease); }
.reveal.in { opacity: 1; transform: none; }
.reveal[data-d="1"] { transition-delay: .08s; } .reveal[data-d="2"] { transition-delay: .16s; } .reveal[data-d="3"] { transition-delay: .24s; } .reveal[data-d="4"] { transition-delay: .32s; }

/* ---------- page hero (inner pages) ---------- */
.page-hero { padding: 170px 0 70px; position: relative; overflow: hidden; }
.page-hero .display { font-size: clamp(44px, 6.6vw, 96px); margin-top: 22px; max-width: 14ch; }
.page-hero .lede { margin-top: 26px; }
.crumbs { font-family: var(--mono); font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.crumbs a:hover { color: var(--orange); }

/* ---------- CTA band ---------- */
.cta-band { background: var(--orange); color: var(--navy); border-radius: var(--r-lg); padding: clamp(36px, 6vw, 80px); display: grid; grid-template-columns: 1.4fr 1fr; gap: 40px; align-items: center; position: relative; overflow: hidden; }
.cta-band h2 { color: var(--navy); font-size: clamp(34px, 4.4vw, 60px); }
.cta-band p { color: var(--navy); opacity: .85; max-width: 46ch; margin-top: 16px; }
.cta-band .actions { display: flex; flex-wrap: wrap; gap: 12px; justify-content: flex-end; position: relative; z-index: 1; }
.cta-band .btn-primary { background: var(--navy); box-shadow: none; }
.cta-band .btn-primary:hover { background: var(--white); color: var(--navy); }
.cta-band .btn-ghost { box-shadow: inset 0 0 0 1.5px var(--navy); }
.cta-band .sunburst { position: absolute; right: -120px; bottom: -220px; width: 520px; height: 520px; opacity: .22; pointer-events: none; }
@media (max-width: 860px) { .cta-band { grid-template-columns: 1fr; } .cta-band .actions { justify-content: flex-start; } }

/* ---------- footer ---------- */
.site-footer { background: var(--navy); color: rgba(255, 255, 255, .66); padding: 90px 0 36px; font-size: 15px; }
.foot-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: 40px; }
.foot-grid h4 { color: var(--white); font-size: 13px; font-family: var(--mono); letter-spacing: .14em; text-transform: uppercase; font-weight: 400; margin-bottom: 18px; }
.foot-grid ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.foot-grid a:hover { color: var(--sun); }
.foot-brand img { height: 92px; width: auto; margin-bottom: 20px; }
.foot-brand p { max-width: 34ch; }
.foot-bottom { margin-top: 70px; padding-top: 26px; border-top: 1px solid rgba(255, 255, 255, .1); display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; font-size: 13px; }
.socials { display: flex; gap: 10px; margin-top: 22px; }
.socials a { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .2); transition: background .25s, color .25s; }
.socials a:hover { background: var(--sun); color: var(--navy); }
.socials svg { width: 17px; height: 17px; }
.foot-big { font-size: clamp(60px, 15vw, 220px); font-weight: 600; letter-spacing: -.05em; line-height: .8; color: rgba(255, 255, 255, .05); margin-top: 60px; white-space: nowrap; user-select: none; }
@media (max-width: 960px) { .foot-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .foot-grid { grid-template-columns: 1fr; } }

/* ---------- FAQ ---------- */
.faq { border-top: 1px solid var(--rule); }
.faq details { border-bottom: 1px solid var(--rule); }
.faq summary { list-style: none; cursor: pointer; padding: 26px 0; display: flex; justify-content: space-between; gap: 20px; font-size: clamp(18px, 1.6vw, 22px); font-weight: 500; color: var(--navy); }
.faq summary::-webkit-details-marker { display: none; }
.faq summary i { flex: none; width: 34px; height: 34px; border-radius: 50%; box-shadow: inset 0 0 0 1.5px var(--navy); position: relative; transition: background .25s, transform .4s var(--ease); }
.faq summary i::before, .faq summary i::after { content: ""; position: absolute; left: 50%; top: 50%; width: 12px; height: 1.5px; background: var(--navy); transform: translate(-50%, -50%); transition: transform .3s; }
.faq summary i::after { transform: translate(-50%, -50%) rotate(90deg); }
.faq details[open] summary i { background: var(--orange); box-shadow: none; transform: rotate(45deg); }
.faq details[open] summary i::before, .faq details[open] summary i::after { background: var(--white); }
.faq .ans { padding: 0 0 28px; max-width: 70ch; color: #4a4c5e; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
  .reveal { opacity: 1; transform: none; }
}
