/* Rocky Mountain Land Management — mobile-first one-pager
   Theme from logo: black · gold · white */

:root {
  --bg: #f3f3f3;
  --bg-alt: #e8e8e8;
  --surface: #ffffff;
  --ink: #0a0a0a;
  --ink-soft: #222222;
  --muted: #5a5a5a;
  --line: #d0d0d0;
  --black: #0a0a0a;
  --charcoal: #161616;
  --gold: #e8a317;
  --gold-bright: #f0b429;
  --gold-hover: #c98b0c;
  --gold-soft: #fff4d6;
  --ok: #1f7a36;
  --ok-bg: #dff3e4;
  /* aliases used across the sheet */
  --forest: var(--charcoal);
  --forest-deep: var(--black);
  --pine: #2c2c2c;
  --accent: var(--gold);
  --accent-hover: var(--gold-hover);
  --accent-soft: var(--gold-soft);
  --shadow: 0 8px 28px rgba(0, 0, 0, 0.12);
  --radius: 14px;
  --max: 1080px;
  --header-h: 72px;
  --sticky-h: 64px;
  --font: "Segoe UI", system-ui, -apple-system, Roboto, Helvetica, Arial, sans-serif;
  --btn-min-h: 3rem;
  --btn-pad-y: 0.75rem;
  --btn-pad-x: 1.1rem;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  /* Match footer/sticky so iOS overscroll isn’t a white flash */
  background: var(--black);
  overscroll-behavior-y: none;
}

body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.55;
  /* No body padding — that created a light band under the black footer on mobile */
  padding-bottom: 0;
  min-height: 100%;
  overscroll-behavior-y: none;
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

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

a:hover {
  color: var(--black);
}

/* —— Header —— */
.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(10, 10, 10, 0.94);
  backdrop-filter: blur(10px);
  border-bottom: 2px solid var(--gold);
}

.header-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0.55rem 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  min-height: var(--header-h);
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  text-decoration: none;
  color: #fff;
  min-width: 0;
}

.brand-logo {
  height: 48px;
  width: auto;
  max-width: 160px;
  object-fit: contain;
  flex-shrink: 0;
  border-radius: 6px;
  background: #000;
}

.brand-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
  line-height: 1.15;
}

.brand-name {
  font-weight: 800;
  font-size: clamp(0.58rem, 2.6vw, 0.78rem);
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: #fff;
  /* Keep full company name visible on mobile (was hidden under 420px) */
  display: block;
  white-space: normal;
  line-height: 1.2;
  max-width: 12rem;
}

.brand-area {
  font-weight: 600;
  font-size: 0.7rem;
  color: var(--gold-bright);
  letter-spacing: 0.02em;
}

.header-actions {
  display: flex;
  gap: 0.45rem;
  flex-shrink: 0;
  align-items: center;
}

/* —— Buttons (consistent centering everywhere) —— */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  box-sizing: border-box;
  min-height: var(--btn-min-h);
  padding: var(--btn-pad-y) var(--btn-pad-x);
  border-radius: 999px;
  font-family: inherit;
  font-weight: 700;
  font-size: 0.95rem;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  white-space: normal;
  border: 2px solid transparent;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease, transform 0.1s ease;
  /* kill inherited link styles */
  color: inherit;
  appearance: none;
  -webkit-appearance: none;
}

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

.btn-primary {
  background: var(--gold);
  color: var(--black);
  border-color: var(--gold);
}

.btn-primary:hover {
  background: var(--gold-hover);
  border-color: var(--gold-hover);
  color: var(--black);
}

.btn-secondary {
  background: var(--black);
  color: #fff;
  border-color: var(--black);
}

.btn-secondary:hover {
  background: #222;
  border-color: #222;
  color: #fff;
}

.btn-ghost {
  background: var(--surface);
  color: var(--black);
  border-color: var(--black);
}

.btn-ghost:hover {
  background: var(--black);
  color: #fff;
  border-color: var(--black);
}

/* On dark panels (contact section) */
.btn-light {
  background: #fff;
  color: var(--black);
  border-color: #fff;
}

.btn-light:hover {
  background: var(--gold);
  border-color: var(--gold);
  color: var(--black);
}

.btn-block {
  width: 100%;
}

.btn-sm {
  min-height: 2.4rem;
  padding: 0.45rem 0.85rem;
  font-size: 0.85rem;
}

/* Header buttons on black bar */
.header-actions .btn-primary {
  background: var(--gold);
  color: var(--black);
  border-color: var(--gold);
}

.header-actions .btn-secondary {
  background: transparent;
  color: #fff;
  border-color: rgba(255, 255, 255, 0.55);
}

.header-actions .btn-secondary:hover {
  border-color: var(--gold);
  color: var(--gold-bright);
  background: transparent;
}

/* —— Layout —— */
.wrap {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 1rem;
}

.section {
  padding: 2.75rem 0;
}

.section-alt {
  background: var(--bg-alt);
}

.section-dark {
  background: linear-gradient(165deg, #000 0%, #141414 55%, #1a1408 100%);
  color: #f2f2f2;
}

.section-dark h2,
.section-dark h3 {
  color: #fff;
}

.section-dark .muted {
  color: #c4c4c4;
}

.eyebrow {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold-hover);
  margin: 0 0 0.5rem;
}

.section-dark .eyebrow {
  color: var(--gold-bright);
}

h1,
h2,
h3 {
  line-height: 1.2;
  margin: 0 0 0.75rem;
  color: var(--black);
}

h1 {
  font-size: clamp(1.65rem, 5.5vw, 2.45rem);
  letter-spacing: -0.02em;
}

h2 {
  font-size: clamp(1.4rem, 4vw, 1.85rem);
}

h3 {
  font-size: 1.1rem;
}

.lead {
  font-size: 1.05rem;
  color: var(--ink-soft);
  max-width: 38rem;
}

.muted {
  color: var(--muted);
}

.center {
  text-align: center;
}

/* —— Hero —— */
.hero {
  padding: 1rem 0 1.5rem;
}

.hero-grid {
  display: grid;
  gap: 1rem;
}

.hero-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: calc(var(--radius) + 4px);
  overflow: hidden;
  box-shadow: var(--shadow);
}

/* Media card: image fills the frame (no letterbox / white band) */
.hero-card-media {
  padding: 0;
  background: #0a0a0a;
  line-height: 0;
  overflow: hidden;
}

.hero-photo {
  display: block;
  width: 100%;
  /* Mobile: compact banner — not a full-screen portrait block */
  height: min(38vh, 220px);
  aspect-ratio: auto;
  object-fit: cover;
  object-position: center 42%;
  background: #0a0a0a;
}

.hero-body {
  padding: 1.25rem 1.15rem 1.4rem;
}

.hero-ctas {
  display: grid;
  gap: 0.65rem;
  margin-top: 1.15rem;
}

.hero-ctas .btn {
  width: 100%;
  min-height: 3.15rem;
  text-align: center;
}

/* —— Services —— */
.cards {
  display: grid;
  gap: 1rem;
  margin-top: 1.25rem;
}

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-top: 3px solid var(--gold);
  border-radius: var(--radius);
  padding: 1.15rem 1.1rem 1.2rem;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04);
}

.card p {
  margin: 0 0 0.75rem;
  color: var(--ink-soft);
}

.card .cta-line {
  margin: 0;
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--black);
}

.card .cta-line a {
  color: var(--black);
  text-decoration: underline;
  text-decoration-color: var(--gold);
  text-underline-offset: 2px;
}

.card .cta-line a:hover {
  color: var(--gold-hover);
}

/* —— Why / process —— */
.why-grid {
  display: grid;
  gap: 1rem;
  margin-top: 1.25rem;
}

.checklist {
  list-style: none;
  padding: 0;
  margin: 0;
}

.checklist li {
  position: relative;
  padding: 0.55rem 0 0.55rem 1.7rem;
  border-bottom: 1px solid var(--line);
  color: var(--ink-soft);
}

.checklist li:last-child {
  border-bottom: 0;
}

.checklist li::before {
  content: "✓";
  position: absolute;
  left: 0;
  top: 0.55rem;
  width: 1.25rem;
  height: 1.25rem;
  border-radius: 50%;
  background: var(--gold-soft);
  color: #8a5a00;
  font-size: 0.75rem;
  font-weight: 800;
  display: grid;
  place-items: center;
}

.steps {
  counter-reset: step;
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0.75rem;
}

.steps li {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0.9rem 1rem 0.9rem 3.1rem;
  position: relative;
  color: var(--ink-soft);
}

.steps li::before {
  counter-increment: step;
  content: counter(step);
  position: absolute;
  left: 0.75rem;
  top: 50%;
  transform: translateY(-50%);
  width: 1.7rem;
  height: 1.7rem;
  border-radius: 50%;
  background: var(--black);
  color: var(--gold-bright);
  font-weight: 800;
  font-size: 0.85rem;
  display: grid;
  place-items: center;
}

/* —— Area —— */
.towns {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 1rem 0 0;
  padding: 0;
  list-style: none;
}

.towns li {
  background: var(--black);
  border: 1px solid var(--black);
  border-radius: 999px;
  padding: 0.45rem 0.9rem;
  font-weight: 700;
  color: var(--gold-bright);
  font-size: 0.95rem;
}

/* —— Gallery —— */
.gallery {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.55rem;
  margin-top: 1.25rem;
}

.gallery figure {
  margin: 0;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--line);
  background: #0a0a0a;
  display: flex;
  flex-direction: column;
}

/* Mobile 2×4: hide 9th tile so nothing sits alone (desktop shows full 3×3) */
.gallery figure:last-child {
  display: none;
}

.gallery img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 1;
  object-fit: cover;
  object-position: center;
  flex: 0 0 auto;
}

.gallery figcaption {
  font-size: 0.75rem;
  color: var(--muted);
  padding: 0.4rem 0.5rem 0.55rem;
  background: var(--surface);
  text-align: center;
  line-height: 1.3;
}

/* —— Testimonials —— */
.quotes {
  display: grid;
  gap: 1rem;
  margin-top: 1.25rem;
}

.quote {
  background: var(--surface);
  border: 1px solid var(--line);
  border-left: 4px solid var(--gold);
  border-radius: var(--radius);
  padding: 1.1rem 1.15rem;
  margin: 0;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04);
}

.quote p {
  margin: 0 0 0.85rem;
  color: var(--ink-soft);
  font-size: 0.98rem;
}

.quote footer {
  font-weight: 700;
  color: var(--black);
  font-size: 0.92rem;
  font-style: normal;
}

.quote .pull {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--ink);
}

/* —— FAQ —— */
.faq {
  margin-top: 1rem;
  display: grid;
  gap: 0.65rem;
}

details.faq-item {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0.85rem 1rem;
}

details.faq-item summary {
  cursor: pointer;
  font-weight: 700;
  color: var(--black);
  list-style: none;
}

details.faq-item summary::-webkit-details-marker {
  display: none;
}

details.faq-item summary::after {
  content: "+";
  float: right;
  color: var(--gold-hover);
  font-weight: 700;
}

details.faq-item[open] summary::after {
  content: "–";
}

details.faq-item p {
  margin: 0.65rem 0 0.15rem;
  color: var(--ink-soft);
}

/* —— Contact —— */
.contact-grid {
  display: grid;
  gap: 1.25rem;
  margin-top: 1.25rem;
}

.contact-panel {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(232, 163, 23, 0.28);
  border-radius: var(--radius);
  padding: 1.15rem;
}

.contact-panel a:not(.btn) {
  color: var(--gold-bright);
  font-weight: 700;
  text-decoration: none;
}

.contact-panel a:not(.btn):hover {
  text-decoration: underline;
}

.contact-list {
  list-style: none;
  padding: 0;
  margin: 0 0 1rem;
}

.contact-list li {
  padding: 0.35rem 0;
  color: #e0e0e0;
}

.contact-actions {
  display: grid;
  gap: 0.55rem;
}

.form {
  display: grid;
  gap: 0.75rem;
}

.form label {
  display: grid;
  gap: 0.3rem;
  font-size: 0.88rem;
  font-weight: 600;
  color: #f0f0f0;
}

.form input,
.form select,
.form textarea {
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.96);
  color: var(--ink);
  border-radius: 10px;
  padding: 0.7rem 0.8rem;
  font: inherit;
}

.form textarea {
  min-height: 110px;
  resize: vertical;
}

.form input:focus,
.form select:focus,
.form textarea:focus {
  outline: 2px solid var(--gold);
  outline-offset: 1px;
}

.honeypot {
  position: absolute;
  left: -9999px;
  opacity: 0;
  height: 0;
  width: 0;
  overflow: hidden;
}

.form-note {
  font-size: 0.85rem;
  color: #c4c4c4;
  margin: 0;
  text-align: center;
}

.form-status {
  display: none;
  padding: 0.75rem 0.9rem;
  border-radius: 10px;
  font-weight: 600;
  font-size: 0.92rem;
  text-align: center;
}

.form-status.ok {
  display: block;
  background: var(--ok-bg);
  color: var(--ok);
}

.form-status.err {
  display: block;
  background: #f8d9d0;
  color: #8a2e1a;
}

/* —— Footer —— */
.site-footer {
  /* Extra bottom pad on mobile clears the fixed Call/Text bar (black, not white) */
  padding: 2rem 0 calc(1.25rem + var(--sticky-h) + env(safe-area-inset-bottom, 0px));
  border-top: 2px solid var(--gold);
  background: var(--black);
  color: #c8c8c8;
}

.site-footer p {
  margin: 0 0 0.4rem;
  color: #bdbdbd;
  font-size: 0.92rem;
}

.site-footer strong {
  color: #fff;
}

.site-footer a {
  color: var(--gold-bright);
}

.site-footer a:hover {
  color: #fff;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.85rem;
}

.footer-logo {
  height: 56px;
  width: auto;
  border-radius: 6px;
  background: #000;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.1rem;
  margin-top: 0.75rem;
}

.footer-links a {
  font-weight: 600;
  text-decoration: none;
}

/* —— Sticky mobile bar —— */
.sticky-cta {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 50;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem;
  padding: 0.55rem 0.75rem calc(0.55rem + env(safe-area-inset-bottom));
  background: rgba(10, 10, 10, 0.96);
  backdrop-filter: blur(8px);
  border-top: 2px solid var(--gold);
}

.sticky-cta .btn {
  width: 100%;
  min-height: 2.85rem;
  border-radius: 12px;
  text-align: center;
}

/* —— Desktop —— */
@media (min-width: 720px) {
  html {
    background: var(--bg);
    overscroll-behavior-y: auto;
  }

  body {
    overscroll-behavior-y: auto;
  }

  .sticky-cta {
    display: none;
  }

  .site-footer {
    padding: 2rem 0 1.5rem;
  }

  .brand-logo {
    height: 56px;
    max-width: 200px;
  }

  .brand-name {
    font-size: 0.9rem;
    max-width: none;
    overflow-wrap: normal;
  }

  .brand-area {
    font-size: 0.75rem;
  }

  .hero {
    padding: 1.5rem 0 2rem;
  }

  .hero-grid {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 1.5rem;
    /* Equal-height columns: image card matches text card */
    align-items: stretch;
  }

  .hero-card-media {
    position: relative;
    width: 100%;
    height: 100%;
    min-height: 100%;
    align-self: stretch;
  }

  /* Fill the full height of the text column beside it */
  .hero-photo {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    aspect-ratio: auto;
    max-height: none;
    object-fit: cover;
    object-position: center 40%;
  }

  .hero-body {
    padding: 1.75rem 1.5rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-height: 0;
    height: 100%;
  }

  .hero-ctas {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .hero-ctas .btn {
    font-size: 0.9rem;
    padding-left: 0.65rem;
    padding-right: 0.65rem;
  }

  .cards {
    grid-template-columns: 1fr 1fr;
  }

  .why-grid {
    grid-template-columns: 1fr 1fr;
  }

  /* True 3×3 on desktop — show all 9 */
  .gallery {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.75rem;
  }

  .gallery figure:last-child {
    display: flex;
  }

  .gallery img {
    aspect-ratio: 1;
  }

  .quotes {
    grid-template-columns: 1fr 1fr;
  }

  .contact-grid {
    grid-template-columns: 0.9fr 1.1fr;
    align-items: start;
  }

  .section {
    padding: 3.5rem 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .btn {
    transition: none;
  }
}
