/* ==========================================================================
   Bay Regional Property Services — brand v2 (trade identity)
   Navy carries the dark surfaces, orange is the action color.
   ========================================================================== */

:root {
  /* Color */
  --navy:        oklch(26% 0.05 255);
  --navy-2:      oklch(21% 0.045 255);
  --navy-3:      oklch(33% 0.055 252);
  --orange:      oklch(68% 0.155 55);
  --orange-deep: oklch(59% 0.145 50);
  --bg:          oklch(97.5% 0.004 250);
  --surface:     oklch(99.4% 0.002 250);
  --ink:         var(--navy);
  --muted:       oklch(42% 0.03 255);
  --line:        oklch(88% 0.01 250);
  --on-dark:     oklch(96.5% 0.004 250);
  --on-dark-2:   oklch(80% 0.018 250);

  /* Type */
  --display: "Archivo", "Arial Narrow", sans-serif;
  --body: "Public Sans", system-ui, sans-serif;

  /* Rhythm */
  --section: clamp(72px, 10vw, 136px);
  --gutter: clamp(20px, 4vw, 40px);
  --radius: 6px;

  /* z-scale */
  --z-sticky: 100;
  --z-sheet: 200;
  --z-dock: 300;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--body);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

img, svg { display: block; max-width: 100%; }

.container {
  max-width: 1160px;
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* --------------------------------------------------------------------------
   Typography
   -------------------------------------------------------------------------- */

h1, h2, h3 {
  font-family: var(--display);
  font-stretch: 87.5%;
  text-wrap: balance;
  line-height: 1.05;
}

h1 {
  font-size: clamp(2.7rem, 7.5vw, 5.2rem);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.005em;
}

h2 {
  font-size: clamp(1.9rem, 4vw, 2.9rem);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.01em;
}

h3 {
  font-size: 1.25rem;
  font-weight: 700;
  line-height: 1.25;
}

p { max-width: 68ch; text-wrap: pretty; }

.lead {
  font-size: clamp(1.1rem, 2vw, 1.3rem);
  line-height: 1.55;
  max-width: 52ch;
}

a { color: var(--ink); }

main a:not(.btn) {
  color: inherit;
  text-decoration: underline;
  text-decoration-color: var(--orange);
  text-decoration-thickness: 1.5px;
  text-underline-offset: 4px;
}

main a:not(.btn):hover { text-decoration-thickness: 3px; text-underline-offset: 3px; }

.accent { color: var(--orange); }

/* Sub-brand line: — PROPERTY SERVICES — */
.tagline-rule {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  font-family: var(--display);
  font-weight: 600;
  font-size: 0.85rem;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  white-space: nowrap;
}
.tagline-rule::before, .tagline-rule::after {
  content: "";
  width: 30px;
  height: 3px;
  background: currentColor;
}
.tagline-rule::after { background: var(--orange); }

/* --------------------------------------------------------------------------
   Buttons
   -------------------------------------------------------------------------- */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--display);
  font-stretch: 87.5%;
  font-weight: 700;
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  text-decoration: none;
  padding: 15px 26px;
  border-radius: var(--radius);
  border: 2px solid transparent;
  cursor: pointer;
  transition: background-color 0.2s cubic-bezier(0.22, 1, 0.36, 1), border-color 0.2s, color 0.2s, transform 0.2s cubic-bezier(0.22, 1, 0.36, 1);
}

.btn:active { transform: scale(0.98); }

.btn-primary { background: var(--orange); color: var(--navy-2); }
.btn-primary:hover { background: var(--orange-deep); color: var(--on-dark); }

.btn-ghost { border-color: currentColor; color: var(--ink); background: transparent; }
.btn-ghost:hover { border-color: var(--orange); color: var(--orange-deep); }

.hero .btn-ghost, .cta-band .btn-ghost, .page-hero .btn-ghost,
.mdock .btn-ghost, .on-dark .btn-ghost, .site-header .btn-ghost { color: var(--on-dark); }
.hero .btn-ghost:hover, .cta-band .btn-ghost:hover, .page-hero .btn-ghost:hover,
.on-dark .btn-ghost:hover { border-color: var(--orange); color: var(--orange); }

/* --------------------------------------------------------------------------
   Header
   -------------------------------------------------------------------------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: var(--z-sticky);
  background: var(--navy);
  border-bottom: 3px solid var(--orange);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 74px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}

.brand-mark img { width: 70px; height: auto; }

.brand-text {
  font-family: var(--display);
  font-stretch: 87.5%;
  line-height: 1;
}
.brand-text .top {
  display: block;
  font-weight: 800;
  font-size: 1.3rem;
  letter-spacing: 0.02em;
  color: var(--on-dark);
}
.brand-text .top b { color: var(--orange); font-weight: 800; }
.brand-text .sub {
  display: block;
  margin-top: 4px;
  font-weight: 600;
  font-size: 0.75rem;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--on-dark-2);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 6px;
  list-style: none;
}

.nav-links a:not(.btn) {
  display: block;
  padding: 10px 14px;
  font-family: var(--display);
  font-stretch: 87.5%;
  font-weight: 600;
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  text-decoration: none;
  color: var(--on-dark-2);
  transition: color 0.15s;
}

.nav-links a:not(.btn):hover,
.nav-links a[aria-current="page"] { color: var(--on-dark); }

.nav-links a[aria-current="page"] {
  text-decoration: underline;
  text-decoration-color: var(--orange);
  text-decoration-thickness: 3px;
  text-underline-offset: 8px;
}

.nav-links .btn { padding: 11px 20px; margin-left: 10px; }

.nav-toggle {
  display: none;
  background: none;
  border: 0;
  width: 44px;
  height: 44px;
  position: relative;
  cursor: pointer;
}
.nav-toggle span, .nav-toggle::before, .nav-toggle::after {
  content: "";
  position: absolute;
  left: 10px;
  right: 10px;
  height: 2.5px;
  background: var(--on-dark);
  transition: transform 0.25s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.2s;
}
.nav-toggle::before { top: 14px; }
.nav-toggle span { top: 21px; }
.nav-toggle::after { top: 28px; }
.nav-open .nav-toggle::before { transform: translateY(7px) rotate(45deg); }
.nav-open .nav-toggle span { opacity: 0; }
.nav-open .nav-toggle::after { transform: translateY(-7px) rotate(-45deg); }

/* --------------------------------------------------------------------------
   Hero
   -------------------------------------------------------------------------- */

.hero {
  background: var(--navy);
  color: var(--on-dark);
  padding-block: clamp(64px, 9vw, 120px) clamp(56px, 8vw, 104px);
  overflow: hidden;
}

.hero h1 .line { display: block; }
.hero h1 { max-width: 16ch; }

.hero .lead { margin-top: 22px; color: var(--on-dark-2); }

.hero-ctas {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 34px;
}

.hero-tags {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 14px;
  margin-top: 38px;
  font-family: var(--display);
  font-weight: 600;
  font-size: 0.8rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--on-dark-2);
}
.hero-tags .sep { width: 4px; height: 4px; background: var(--orange); border-radius: 50%; }

/* Page hero (inner pages) */
.page-hero {
  background: var(--navy);
  color: var(--on-dark);
  padding-block: clamp(48px, 7vw, 88px);
}
.page-hero .lead { margin-top: 16px; color: var(--on-dark-2); }

/* --------------------------------------------------------------------------
   Service strip (orange band, like the business card)
   -------------------------------------------------------------------------- */

.svc-strip {
  background: var(--orange);
  color: var(--navy-2);
  padding-block: 26px;
}

.svc-strip ul {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
}

.svc-strip li {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 9px;
  padding: 8px clamp(16px, 3vw, 36px);
  font-family: var(--display);
  font-stretch: 87.5%;
  font-weight: 700;
  font-size: 0.82rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.svc-strip li + li { border-left: 1px solid oklch(from var(--navy-2) l c h / 0.25); }

.svc-strip svg { width: 30px; height: 30px; }

/* --------------------------------------------------------------------------
   Sections
   -------------------------------------------------------------------------- */

.section { padding-block: var(--section); }
.section.tight { padding-block: calc(var(--section) * 0.66); }
.section.on-dark { background: var(--navy); color: var(--on-dark); }
.section.on-dark p { color: var(--on-dark-2); }

.section-head { margin-bottom: clamp(36px, 5vw, 64px); }
.section-head .kick {
  display: block;
  font-family: var(--display);
  font-weight: 700;
  font-size: 0.85rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--orange-deep);
  margin-bottom: 14px;
}
.on-dark .section-head .kick { color: var(--orange); }
.section-head p { margin-top: 16px; color: var(--muted); }

/* Who we serve — ruled columns, no cards */
.serve-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 0 clamp(28px, 4vw, 56px);
}
.serve-col { padding-block: 28px; border-top: 3px solid var(--navy); }
.serve-col h3 { text-transform: uppercase; font-stretch: 87.5%; letter-spacing: 0.03em; }
.serve-col p { margin-top: 12px; font-size: 0.98rem; color: var(--muted); }
.serve-col .more { display: inline-block; margin-top: 14px; font-weight: 600; font-size: 0.95rem; }

/* Service detail rows (services page) */
.svc-detail { list-style: none; }
.svc-detail li {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(0, 3fr);
  gap: 12px clamp(24px, 4vw, 64px);
  padding-block: clamp(28px, 4vw, 44px);
  border-top: 1px solid var(--line);
}
.svc-detail li:last-child { border-bottom: 1px solid var(--line); }
.svc-detail h3 {
  font-size: clamp(1.35rem, 2.4vw, 1.8rem);
  text-transform: uppercase;
}
.svc-detail p { color: var(--muted); }

/* How it works — a real sequence, numbered */
.steps { list-style: none; counter-reset: step; display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: clamp(28px, 4vw, 48px); }
.steps li { counter-increment: step; }
.steps li::before {
  content: counter(step, decimal-leading-zero);
  display: block;
  font-family: var(--display);
  font-stretch: 87.5%;
  font-weight: 800;
  font-size: 2.6rem;
  line-height: 1;
  color: var(--orange);
  margin-bottom: 14px;
}
.steps h3 { text-transform: uppercase; }
.steps p { margin-top: 10px; font-size: 0.98rem; color: var(--muted); }
.on-dark .steps p { color: var(--on-dark-2); }

/* Trust bar */
.trust {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 18px;
  font-family: var(--display);
  font-weight: 700;
  font-size: 0.9rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}
.trust .sep { width: 5px; height: 5px; background: var(--orange); border-radius: 50%; }

/* Service area */
.area-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(32px, 5vw, 72px);
  align-items: start;
}
.county-list { list-style: none; columns: 2; gap: 24px; margin-top: 8px; }
.county-list li {
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
  font-weight: 600;
  break-inside: avoid;
}
.county-list li small {
  display: block;
  font-family: var(--display);
  font-weight: 600;
  font-size: 0.75rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted);
}

/* CTA band */
.cta-band {
  background: var(--navy);
  color: var(--on-dark);
  padding-block: clamp(56px, 8vw, 96px);
}
.cta-band .inner {
  display: grid;
  grid-template-columns: minmax(0, 3fr) minmax(0, 2fr);
  gap: clamp(28px, 4vw, 64px);
  align-items: center;
}
.cta-band p { color: var(--on-dark-2); margin-bottom: 20px; }

/* --------------------------------------------------------------------------
   Contact
   -------------------------------------------------------------------------- */

.contact-grid {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(0, 3fr);
  gap: clamp(36px, 5vw, 80px);
  align-items: start;
}

.contact-list { list-style: none; }
.contact-list li {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding-block: 16px;
  border-bottom: 1px solid var(--line);
}
.contact-list svg { width: 22px; height: 22px; flex: none; margin-top: 3px; color: var(--orange-deep); }
.contact-list .k {
  display: block;
  font-family: var(--display);
  font-weight: 700;
  font-size: 0.76rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--muted);
}
.contact-list .v { display: block; font-weight: 600; font-size: 1.1rem; }
.contact-list a.v { width: fit-content; }

.form {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(24px, 4vw, 44px);
}

.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }

.field { margin-bottom: 18px; }
.field label {
  display: block;
  font-family: var(--display);
  font-weight: 700;
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  margin-bottom: 7px;
}
.field input, .field select, .field textarea {
  width: 100%;
  font: inherit;
  color: var(--ink);
  padding: 13px 14px;
  background: var(--bg);
  border: 1.5px solid var(--line);
  border-radius: var(--radius);
  transition: border-color 0.15s;
}
.field input:focus, .field select:focus, .field textarea:focus {
  outline: 2px solid var(--orange);
  outline-offset: 1px;
  border-color: var(--orange);
}
.field ::placeholder { color: var(--muted); opacity: 1; }
.field textarea { min-height: 130px; resize: vertical; }

.form-note { font-size: 0.9rem; color: var(--muted); margin-top: 14px; }
.form-success { display: none; padding: 14px 16px; background: var(--navy); color: var(--on-dark); border-radius: var(--radius); margin-top: 16px; font-weight: 600; }
.form-success.show { display: block; }

/* --------------------------------------------------------------------------
   Footer
   -------------------------------------------------------------------------- */

.site-footer {
  background: var(--navy-2);
  color: var(--on-dark-2);
  padding-block: clamp(48px, 6vw, 72px) 28px;
}

.footer-grid {
  display: grid;
  grid-template-columns: minmax(0, 2fr) repeat(2, minmax(0, 1fr));
  gap: clamp(28px, 4vw, 64px);
  padding-bottom: 40px;
  border-bottom: 1px solid oklch(from var(--on-dark) l c h / 0.14);
}

.footer-brand p { margin-top: 16px; font-size: 0.95rem; max-width: 34ch; }

.site-footer h4 {
  font-family: var(--display);
  font-weight: 700;
  font-size: 0.78rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--on-dark);
  margin-bottom: 16px;
}

.site-footer ul { list-style: none; }
.site-footer ul li { margin-bottom: 10px; }
.site-footer a { color: var(--on-dark-2); text-decoration: none; }
.site-footer a:hover { color: var(--orange); }

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 10px;
  padding-top: 24px;
  font-size: 0.85rem;
}
.footer-bottom .badges {
  font-family: var(--display);
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--orange);
}

/* --------------------------------------------------------------------------
   Mobile dock
   -------------------------------------------------------------------------- */

.mdock {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: var(--z-dock);
  gap: 10px;
  padding: 10px var(--gutter) calc(10px + env(safe-area-inset-bottom));
  background: var(--navy-2);
  box-shadow: 0 -4px 18px oklch(20% 0.04 255 / 0.35);
}
.mdock .btn { flex: 1; justify-content: center; }

/* --------------------------------------------------------------------------
   Motion
   -------------------------------------------------------------------------- */

@keyframes rise {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Hero intro: runs on load, no JS dependency */
.hero h1, .hero .lead, .hero-ctas, .hero-tags { animation: rise 0.7s cubic-bezier(0.22, 1, 0.36, 1) both; }
.hero .lead { animation-delay: 0.12s; }
.hero-ctas { animation-delay: 0.22s; }
.hero-tags { animation-delay: 0.3s; }

/* Scroll reveal: content is visible by default; JS adds .in to animate */
[data-reveal].in { animation: rise 0.6s cubic-bezier(0.22, 1, 0.36, 1) both; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero h1, .hero .lead, .hero-ctas, .hero-tags, [data-reveal].in { animation: none; }
  .btn, .nav-toggle span, .nav-toggle::before, .nav-toggle::after { transition: none; }
}

/* --------------------------------------------------------------------------
   Responsive
   -------------------------------------------------------------------------- */

@media (max-width: 960px) {
  .area-grid, .cta-band .inner, .contact-grid { grid-template-columns: 1fr; }
  .svc-detail li { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 760px) {
  .nav-toggle { display: block; }

  .nav-links {
    position: fixed;
    inset: 74px 0 0 0;
    z-index: var(--z-sheet);
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
    padding: 28px var(--gutter);
    background: var(--navy);
    transform: translateX(100%);
    transition: transform 0.3s cubic-bezier(0.22, 1, 0.36, 1);
  }
  .nav-open .nav-links { transform: translateX(0); }
  .nav-links a:not(.btn) {
    font-size: 1.6rem;
    padding: 12px 0;
  }
  .nav-links .btn { margin: 18px 0 0; }

  .svc-strip li { flex: 1 1 30%; }
  .svc-strip li + li { border-left: 0; }

  .county-list { columns: 1; }
  .form-row { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }

  .mdock { display: flex; }
  body { padding-bottom: 76px; }
}

@media (prefers-reduced-motion: reduce) {
  .nav-links { transition: none; }
}

/* --------------------------------------------------------------------------
   Touch ergonomics: comfortable tap targets on coarse pointers / small screens
   -------------------------------------------------------------------------- */

@media (pointer: coarse), (max-width: 768px) {
  main a:not(.btn), .serve-col .more {
    display: inline-block;
    padding-block: 8px;
    margin-block: -4px;
  }
  .site-footer ul a {
    display: inline-block;
    padding-block: 9px;
    margin-block: -5px;
  }
  .contact-list a.v { padding-block: 7px; margin-block: -3px; }
  .field input, .field select { min-height: 48px; }
}
