/* ==========================================================================
   Sedona Market Stats — dedicated stylesheet
   All selectors prefixed with .ms- to prevent conflicts.
   ========================================================================== */

:root {
  --ms-deep-brown: #3a2f25;
  --ms-gold: #c4a354;
  --ms-ivory: #f8f4ec;
  --ms-rule: rgba(196, 163, 84, 0.35);
  --ms-text: #3a2f25;
  --ms-text-soft: rgba(58, 47, 37, 0.78);
  --ms-up: #2f7d4f;
  --ms-down: #b04444;
}

.ms-page {
  background: #fff;
  color: var(--ms-text);
  font-family: 'Jost', 'Montserrat', system-ui, sans-serif;
}

/* ============ HERO ============ */
.ms-hero {
  position: relative;
  background: #1a1a1a;
  color: #fff;
  padding: 6rem 2rem 5rem;
  text-align: center;
  overflow: hidden;
}
.ms-hero__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,0.0) 0%, rgba(0,0,0,0.25) 100%);
  pointer-events: none;
}
.ms-hero__inner {
  position: relative;
  max-width: 760px;
  margin: 0 auto;
}
.ms-hero__eyebrow {
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ms-gold);
  margin: 0 0 1.25rem;
}
.ms-hero__title {
  font-family: 'Cormorant Garamond', 'Playfair Display', Georgia, serif;
  font-size: clamp(2.25rem, 5vw, 3.75rem);
  font-weight: 400;
  line-height: 1.1;
  margin: 0 0 1.5rem;
  color: #fff;
}
.ms-hero__rule {
  width: 80px;
  height: 2px;
  background: var(--ms-gold);
  margin: 0 auto 1.75rem;
}
.ms-hero__subtitle {
  font-size: 1.05rem;
  line-height: 1.7;
  color: rgba(255,255,255,0.85);
  margin: 0;
}

/* ============ STATS / CREDENTIALS STRIP ============ */
.ms-credstrip {
  background: #1a1a1a;
  color: #fff;
  padding: 2rem 1rem;
  border-top: 1px solid rgba(196,163,84,0.2);
}
.ms-credstrip__inner {
  max-width: 1100px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
  text-align: center;
}
.ms-credstrip__item {
  padding: 0 0.5rem;
  border-right: 1px solid rgba(255,255,255,0.12);
}
.ms-credstrip__item:last-child {
  border-right: none;
}
.ms-credstrip__num {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: clamp(1.75rem, 3vw, 2.5rem);
  font-style: italic;
  color: var(--ms-gold);
  line-height: 1;
  margin-bottom: 0.5rem;
}
.ms-credstrip__label {
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.85);
}
@media (max-width: 700px) {
  .ms-credstrip__inner {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem 0.5rem;
  }
  .ms-credstrip__item:nth-child(2) { border-right: none; }
  .ms-credstrip__item:nth-child(1),
  .ms-credstrip__item:nth-child(2) {
    padding-bottom: 1.25rem;
    border-bottom: 1px solid rgba(255,255,255,0.12);
  }
}

/* ============ CONTENT WRAPPER ============ */
.ms-content {
  background: #fff;
}
.ms-content > * {
  display: block;
}

/* ============ TLDR — TOP STAT CARDS ============ */
.ms-tldr {
  background: var(--ms-ivory);
  padding: 4rem 1.5rem;
  border-bottom: 1px solid var(--ms-rule);
}
.ms-tldr__inner {
  max-width: 1100px;
  margin: 0 auto;
  text-align: center;
}
.ms-tldr__eyebrow {
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ms-gold);
  margin: 0 0 2rem;
}
.ms-tldr__cards {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
}
.ms-tldr__card {
  background: #fff;
  padding: 2rem 1rem;
  border-radius: 4px;
  box-shadow: 0 2px 14px rgba(0,0,0,0.06);
  text-align: center;
}
.ms-tldr__label {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ms-text-soft);
  margin: 0 0 0.75rem;
}
.ms-tldr__value {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: clamp(1.75rem, 3.5vw, 2.5rem);
  font-weight: 500;
  line-height: 1;
  color: var(--ms-deep-brown);
  margin: 0 0 0.5rem;
}
.ms-tldr__change {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--ms-text-soft);
  margin: 0;
}
.ms-tldr__change--up { color: var(--ms-up); }
.ms-tldr__change--down { color: var(--ms-down); }
@media (max-width: 900px) {
  .ms-tldr__cards { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 480px) {
  .ms-tldr__cards { grid-template-columns: 1fr; }
}

/* ============ FROM WILL'S DESK ============ */
.ms-desk {
  padding: 5rem 1.5rem;
  background: #fff;
}
.ms-desk__inner {
  max-width: 760px;
  margin: 0 auto;
}
.ms-desk__eyebrow {
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ms-gold);
  margin: 0 0 1rem;
}
.ms-desk__h2 {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: clamp(1.85rem, 3.5vw, 2.5rem);
  font-weight: 400;
  line-height: 1.2;
  color: var(--ms-deep-brown);
  margin: 0 0 1.75rem;
}
.ms-desk p {
  font-size: 1.05rem;
  line-height: 1.8;
  color: var(--ms-text);
  margin: 0 0 1.5rem;
}
.ms-desk a {
  color: var(--ms-deep-brown);
  text-decoration: underline;
  text-decoration-color: var(--ms-gold);
  text-underline-offset: 3px;
  text-decoration-thickness: 1px;
}
.ms-desk a:hover {
  color: var(--ms-gold);
}

/* ============ TABLES INTRO ============ */
.ms-tables-intro {
  padding: 4rem 1.5rem 2rem;
  background: #fff;
  text-align: center;
  border-top: 1px solid var(--ms-rule);
}
.ms-tables-intro__inner {
  max-width: 760px;
  margin: 0 auto;
}
.ms-section-eyebrow {
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ms-gold);
  margin: 0 0 1rem;
}
.ms-section-h2 {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: clamp(1.85rem, 3.5vw, 2.5rem);
  font-weight: 400;
  line-height: 1.2;
  color: var(--ms-deep-brown);
  margin: 0 0 1.5rem;
}
.ms-tables-intro p {
  font-size: 1rem;
  line-height: 1.7;
  color: var(--ms-text-soft);
  margin: 0;
}

/* ============ METRIC SECTIONS ============ */
.ms-metric {
  padding: 3.5rem 1.5rem;
  background: #fff;
}
.ms-metric--alt {
  background: var(--ms-ivory);
}
.ms-metric__inner {
  max-width: 860px;
  margin: 0 auto;
}
.ms-metric__title {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: clamp(1.5rem, 2.75vw, 1.95rem);
  font-weight: 400;
  line-height: 1.2;
  color: var(--ms-deep-brown);
  margin: 0 0 0.85rem;
  text-align: center;
}
.ms-metric__blurb {
  font-size: 0.95rem;
  line-height: 1.7;
  color: var(--ms-text-soft);
  margin: 0 auto 2rem;
  max-width: 680px;
  text-align: center;
}
.ms-metric__table-wrap {
  overflow-x: auto;
  background: #fff;
  border-radius: 4px;
  box-shadow: 0 2px 12px rgba(0,0,0,0.05);
}
.ms-metric--alt .ms-metric__table-wrap {
  background: #fff;
}
.ms-metric__table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
}
.ms-metric__table th {
  background: var(--ms-deep-brown);
  color: #fff;
  font-weight: 500;
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 1rem 1.25rem;
  text-align: left;
  border-bottom: 2px solid var(--ms-gold);
}
.ms-metric__table th:first-child { padding-left: 1.5rem; }
.ms-metric__table th:last-child { padding-right: 1.5rem; text-align: right; }
.ms-metric__table th:nth-child(2) { text-align: right; }
.ms-metric__table td {
  padding: 0.85rem 1.25rem;
  border-bottom: 1px solid rgba(58,47,37,0.08);
  color: var(--ms-text);
  font-variant-numeric: tabular-nums;
}
.ms-metric__table td:first-child { padding-left: 1.5rem; font-weight: 500; }
.ms-metric__table td:last-child { padding-right: 1.5rem; text-align: right; color: var(--ms-text-soft); }
.ms-metric__table td:nth-child(2) { text-align: right; font-weight: 500; }
.ms-metric__table tr:first-child td {
  background: rgba(196,163,84,0.08);
  border-bottom: 1px solid var(--ms-gold);
}
.ms-metric__table tr:last-child td { border-bottom: none; }

/* ============ METHODOLOGY ============ */
.ms-methodology {
  padding: 3rem 1.5rem;
  background: #fff;
  border-top: 1px solid var(--ms-rule);
}
.ms-methodology__inner {
  max-width: 760px;
  margin: 0 auto;
}
.ms-methodology__small {
  font-size: 0.82rem;
  line-height: 1.7;
  color: var(--ms-text-soft);
  margin: 0;
}

/* ============ BOTTOM CTA ============ */
.ms-cta {
  padding: 5rem 1.5rem;
  background: #1a1a1a;
  color: #fff;
  text-align: center;
}
.ms-cta__inner {
  max-width: 760px;
  margin: 0 auto;
}
.ms-cta__eyebrow {
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ms-gold);
  margin: 0 0 1.25rem;
}
.ms-cta__title {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: clamp(1.85rem, 3.5vw, 2.5rem);
  font-weight: 400;
  line-height: 1.2;
  color: #fff;
  margin: 0 0 1.25rem;
}
.ms-cta__text {
  font-size: 1.05rem;
  line-height: 1.7;
  color: rgba(255,255,255,0.85);
  margin: 0 0 2rem;
}
.ms-cta__buttons {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}
.ms-cta__btn {
  display: inline-block;
  padding: 0.95rem 1.75rem;
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
  border-radius: 2px;
  transition: all 0.2s ease;
}
.ms-cta__btn--primary {
  background: var(--ms-gold);
  color: #1a1a1a;
}
.ms-cta__btn--primary:hover {
  background: #d4b466;
  color: #1a1a1a;
}
.ms-cta__btn--secondary {
  background: transparent;
  color: #fff;
  border: 1px solid rgba(255,255,255,0.4);
}
.ms-cta__btn--secondary:hover {
  border-color: var(--ms-gold);
  color: var(--ms-gold);
}

/* ============ MOBILE TWEAKS ============ */
@media (max-width: 700px) {
  .ms-hero { padding: 4rem 1.25rem 3rem; }
  .ms-tldr, .ms-desk, .ms-metric, .ms-cta { padding-left: 1rem; padding-right: 1rem; }
  .ms-metric__table { font-size: 0.88rem; }
  .ms-metric__table th, .ms-metric__table td { padding: 0.7rem 0.85rem; }
  .ms-metric__table th:first-child, .ms-metric__table td:first-child { padding-left: 1rem; }
  .ms-metric__table th:last-child, .ms-metric__table td:last-child { padding-right: 1rem; }
}
