/* Palette tokens live in assets/tokens.css (single source of truth). */

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

/* Offset in-page anchors so section headings clear the fixed header
   instead of landing under it (the "jump" past the target). */
section[id],
main[id] {
  scroll-margin-top: 84px;
}

@media (max-width: 720px) {
  section[id],
  main[id] {
    scroll-margin-top: 12px;
  }
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.5;
}

body.modal-open {
  overflow: hidden;
}

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

a {
  color: inherit;
}

.site-header {
  align-items: center;
  background: rgba(251, 252, 248, 0.92);
  border-bottom: 1px solid rgba(24, 35, 34, 0.08);
  display: flex;
  gap: 24px;
  justify-content: space-between;
  left: 0;
  padding: 14px clamp(16px, 4vw, 56px);
  position: fixed;
  right: 0;
  top: 0;
  z-index: 20;
  backdrop-filter: blur(16px);
}

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

.brand-mark {
  align-items: center;
  background: var(--forest);
  border-radius: 8px;
  color: var(--white);
  display: inline-flex;
  font-weight: 800;
  height: 42px;
  justify-content: center;
  letter-spacing: 0;
  width: 42px;
}

.brand strong,
.brand small {
  display: block;
}

.brand strong {
  font-size: 1rem;
}

.brand small {
  color: var(--muted);
  font-size: 0.78rem;
  margin-top: -2px;
}

nav {
  align-items: center;
  display: flex;
  gap: clamp(12px, 2vw, 28px);
}

.mobile-nav {
  display: none;
}

nav a {
  color: #334340;
  font-size: 0.95rem;
  font-weight: 650;
  text-decoration: none;
}

nav a:hover {
  color: var(--forest);
}

.hero {
  min-height: 82svh;
  overflow: hidden;
  position: relative;
}

.hero-media,
.hero-shade {
  inset: 0;
  position: absolute;
}

.hero-media img {
  height: 100%;
  object-fit: cover;
  width: 100%;
}

.hero-shade {
  background:
    linear-gradient(90deg, rgba(10, 28, 25, 0.82), rgba(10, 28, 25, 0.48) 46%, rgba(10, 28, 25, 0.2)),
    linear-gradient(0deg, rgba(10, 28, 25, 0.5), transparent 44%);
}

.hero-content {
  color: var(--white);
  max-width: 850px;
  padding: 150px clamp(20px, 6vw, 84px) 86px;
  position: relative;
  z-index: 1;
}

.eyebrow {
  color: var(--gold-text);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.13em;
  margin: 0 0 14px;
  text-transform: uppercase;
}

/* Bright gold reads fine over the dark hero image; the darker gold-text
   above is for eyebrows on light section backgrounds (WCAG AA). */
.hero-content .eyebrow {
  color: var(--gold);
}

.hero h1 {
  /* Floor must keep "Bloomington" on one un-clipped line down to 320px screens. */
  font-size: clamp(2.3rem, 9vw, 8.2rem);
  line-height: 0.9;
  margin: 0;
}

.hero-copy {
  font-size: clamp(1.05rem, 2vw, 1.45rem);
  margin: 26px 0 30px;
  max-width: 690px;
}

.hero-actions,
.contact-actions,
.property-actions {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.button {
  align-items: center;
  border: 1px solid transparent;
  border-radius: 8px;
  cursor: pointer;
  display: inline-flex;
  font-weight: 800;
  justify-content: center;
  min-height: 46px;
  padding: 12px 18px;
  text-decoration: none;
  transition: background 160ms ease, border-color 160ms ease, color 160ms ease, transform 160ms ease;
}

.button:hover {
  transform: translateY(-1px);
}

.button-primary {
  background: var(--rust);
  color: var(--white);
}

.button-primary:hover {
  background: #9f4f31;
}

.button-ghost {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.46);
  color: var(--white);
}

.button-dark {
  background: var(--forest);
  color: var(--white);
}

.button-outline {
  border-color: rgba(19, 79, 70, 0.28);
  color: var(--forest);
}

.button-small {
  min-height: 40px;
  padding: 9px 14px;
}

.quick-finder {
  background: var(--forest-2);
  color: var(--white);
  padding: 20px clamp(16px, 4vw, 56px);
}

.finder-inner {
  display: grid;
  gap: 14px;
  grid-template-columns: minmax(220px, 1.4fr) repeat(3, minmax(150px, 0.7fr));
  margin: 0 auto;
  max-width: 1180px;
}

label span {
  color: rgba(255, 255, 255, 0.72);
  display: block;
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  margin-bottom: 6px;
  text-transform: uppercase;
}

input,
select {
  appearance: none;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 8px;
  color: var(--white);
  font: inherit;
  min-height: 46px;
  padding: 10px 12px;
  width: 100%;
}

select option {
  color: var(--ink);
}

input::placeholder {
  color: rgba(255, 255, 255, 0.55);
}

.intro-band {
  background: var(--white);
  border-bottom: 1px solid rgba(24, 35, 34, 0.08);
  display: grid;
  gap: 1px;
  grid-template-columns: repeat(3, 1fr);
}

.intro-band div {
  align-items: baseline;
  border-right: 1px solid rgba(24, 35, 34, 0.08);
  display: flex;
  gap: 10px;
  justify-content: center;
  padding: 20px 16px;
}

.intro-band div:last-child {
  border-right: 0;
}

.metric {
  color: var(--forest);
  font-size: clamp(1.35rem, 3vw, 2rem);
  font-weight: 900;
}

.section {
  padding: 82px clamp(16px, 4vw, 56px);
}

.section-heading {
  margin: 0 auto 32px;
  max-width: 780px;
  text-align: center;
}

.section-heading h2,
.contact-section h2 {
  font-size: clamp(2rem, 5vw, 4rem);
  line-height: 1;
  margin: 0 0 16px;
}

.section-heading p:not(.eyebrow),
.contact-section p {
  color: var(--muted);
  font-size: 1.05rem;
  margin: 0;
}

.property-grid {
  display: grid;
  gap: 22px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin: 0 auto;
  max-width: 1240px;
}

.results-meta {
  color: var(--muted);
  font-weight: 800;
  margin: -10px auto 24px;
  max-width: 1240px;
  text-align: right;
}

.property-card {
  background: var(--white);
  border: 1px solid rgba(24, 35, 34, 0.1);
  border-radius: var(--radius);
  box-shadow: 0 8px 28px rgba(24, 35, 34, 0.07);
  display: flex;
  flex-direction: column;
  min-width: 0;
  overflow: hidden;
}

.property-image-link {
  align-items: center;
  aspect-ratio: 4 / 3;
  background:
    linear-gradient(135deg, rgba(19, 79, 70, 0.9), rgba(47, 111, 131, 0.72)),
    linear-gradient(45deg, var(--limestone), var(--mist));
  color: var(--white);
  display: flex;
  justify-content: center;
  overflow: hidden;
  position: relative;
  text-decoration: none;
  width: 100%;
  border: 0;
  padding: 0;
  cursor: pointer;
}

.property-image-link.image-missing::after {
  border: 1px solid rgba(255, 255, 255, 0.38);
  border-radius: 8px;
  content: attr(data-fallback);
  max-width: 80%;
  font-weight: 850;
  letter-spacing: 0.08em;
  padding: 10px 14px;
  text-align: center;
  text-transform: uppercase;
}

.property-image {
  height: 100%;
  object-fit: cover;
  transition: transform 220ms ease;
  width: 100%;
}

.property-card:hover .property-image {
  transform: scale(1.025);
}

.property-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 14px;
  padding: 18px;
}

.property-topline {
  align-items: center;
  color: var(--muted);
  display: flex;
  font-size: 0.82rem;
  font-weight: 750;
  gap: 8px;
  justify-content: space-between;
  text-transform: uppercase;
}

.property-card h3 {
  font-size: 1.35rem;
  line-height: 1.1;
  margin: 0;
}

.property-name-link {
  color: inherit;
  text-decoration: none;
}
.property-name-link:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.property-keyword {
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 600;
  margin: -8px 0 0;
}

.property-summary {
  color: var(--muted);
  font-size: 0.96rem;
  margin: -4px 0 0;
}

.property-facts {
  color: var(--muted);
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.property-facts span {
  background: var(--mist);
  border-radius: 999px;
  padding: 6px 9px;
}

.property-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: auto;
}

.property-tags span {
  border: 1px solid rgba(47, 111, 131, 0.2);
  border-radius: 999px;
  color: var(--lake);
  font-size: 0.8rem;
  font-weight: 750;
  padding: 5px 9px;
}

.guidebook-link {
  color: var(--forest);
  font-size: 0.95rem;
  font-weight: 800;
  text-decoration: none;
}

.guidebook-link:hover {
  text-decoration: underline;
}

.property-dialog {
  background: transparent;
  border: 0;
  max-height: min(920px, calc(100svh - 32px));
  max-width: min(1120px, calc(100vw - 32px));
  padding: 0;
}

.property-dialog::backdrop {
  background: rgba(6, 20, 18, 0.72);
  backdrop-filter: blur(4px);
}

.dialog-shell {
  background: var(--paper);
  border-radius: 8px;
  box-shadow: var(--shadow);
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(360px, 0.8fr);
  max-height: inherit;
  overflow: hidden;
  position: relative;
}

.dialog-close {
  align-items: center;
  background: rgba(7, 28, 25, 0.86);
  border: 0;
  border-radius: 999px;
  color: var(--white);
  cursor: pointer;
  display: inline-flex;
  font-size: 1.7rem;
  height: 42px;
  justify-content: center;
  line-height: 1;
  position: absolute;
  right: 14px;
  top: 14px;
  width: 42px;
  z-index: 3;
}

.dialog-gallery {
  background: #0a1f1c;
  display: grid;
  grid-template-rows: minmax(280px, 1fr) auto;
  min-height: 560px;
}

.dialog-main-image {
  height: 100%;
  object-fit: cover;
  width: 100%;
}

.dialog-thumbs {
  display: grid;
  gap: 8px;
  grid-auto-flow: column;
  grid-auto-columns: 88px;
  overflow-x: auto;
  padding: 12px;
}

.thumb-button {
  aspect-ratio: 4 / 3;
  background: var(--forest-2);
  border: 2px solid transparent;
  border-radius: 8px;
  cursor: pointer;
  overflow: hidden;
  padding: 0;
}

.thumb-button:hover,
.thumb-button:focus-visible {
  border-color: var(--gold);
}

.thumb-button img {
  height: 100%;
  object-fit: cover;
  width: 100%;
}

.dialog-content {
  overflow-y: auto;
  padding: 40px;
}

.dialog-title {
  font-size: clamp(2rem, 4vw, 3.6rem);
  line-height: 1;
  margin: 0 0 14px;
}

.dialog-summary {
  color: var(--muted);
  font-size: 1.05rem;
  margin: 0 0 20px;
}

.dialog-facts {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 26px;
}

.dialog-facts span {
  background: var(--mist);
  border-radius: 999px;
  color: var(--forest-2);
  font-weight: 750;
  padding: 7px 10px;
}

.dialog-section {
  border-top: 1px solid rgba(24, 35, 34, 0.12);
  padding-top: 22px;
}

.dialog-section h3 {
  margin: 0 0 12px;
}

.amenity-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.amenity-list span {
  align-items: center;
  border: 1px solid rgba(47, 111, 131, 0.2);
  border-radius: 999px;
  color: var(--lake);
  display: inline-flex;
  font-size: 0.9rem;
  font-weight: 750;
  gap: 4px;
  padding: 6px 10px;
}

.amenity-icon {
  flex-shrink: 0;
  opacity: 0.72;
}

.dialog-actions {
  align-items: center;
  background: var(--paper);
  border-top: 1px solid rgba(24, 35, 34, 0.1);
  bottom: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 28px -40px -40px;
  padding: 16px 40px;
  position: sticky;
}

.empty-state {
  background: var(--mist);
  border-radius: var(--radius);
  color: var(--muted);
  margin: 24px auto 0;
  max-width: 620px;
  padding: 18px;
  text-align: center;
}

.experience-section {
  background: var(--mist);
}

.experience-grid {
  display: grid;
  gap: 20px;
  grid-template-columns: repeat(3, 1fr);
  margin: 0 auto;
  max-width: 1120px;
}

.experience-grid article {
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(24, 35, 34, 0.08);
  border-radius: var(--radius);
  padding: 28px;
}

.experience-grid h3 {
  margin: 0 0 10px;
}

.experience-grid p {
  color: var(--muted);
  margin: 0;
}

.contact-section {
  background: var(--forest-2);
  color: var(--white);
  padding: 86px clamp(16px, 5vw, 76px);
  text-align: center;
}

.contact-section p {
  color: rgba(255, 255, 255, 0.75);
}

.contact-actions {
  justify-content: center;
  margin-top: 26px;
}

.contact-section .button-outline {
  border-color: rgba(255, 255, 255, 0.35);
  color: var(--white);
}

.site-footer {
  align-items: center;
  background: #071c19;
  color: rgba(255, 255, 255, 0.7);
  display: flex;
  flex-wrap: wrap;
  gap: 12px 22px;
  justify-content: center;
  padding: 20px;
}

.site-footer a {
  color: var(--gold);
  text-decoration: none;
}

@media (max-width: 980px) {
  .finder-inner,
  .property-grid,
  .experience-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 720px) {
  body {
    padding-bottom: 58px;
  }

  .site-header {
    align-items: flex-start;
    position: absolute;
  }

  nav {
    display: none;
  }

  .mobile-nav {
    align-items: center;
    background: rgba(251, 252, 248, 0.96);
    border-top: 1px solid rgba(24, 35, 34, 0.1);
    bottom: 0;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    left: 0;
    position: fixed;
    right: 0;
    z-index: 25;
  }

  .mobile-nav a {
    color: var(--forest-2);
    font-size: 0.82rem;
    font-weight: 850;
    padding: 13px 6px 14px;
    text-align: center;
    text-decoration: none;
  }

  .hero {
    min-height: 84svh;
  }

  .hero-content {
    padding-top: 128px;
  }

  .finder-inner,
  .property-grid,
  .experience-grid,
  .intro-band {
    grid-template-columns: 1fr;
  }

  .intro-band div {
    border-right: 0;
    justify-content: flex-start;
  }

  .property-topline {
    align-items: flex-start;
    flex-direction: column;
  }

  .results-meta {
    text-align: left;
  }

  .property-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .property-actions .button,
  .property-actions .guidebook-link {
    justify-content: center;
    text-align: center;
  }

  .property-dialog {
    max-height: 100svh;
    max-width: 100vw;
    width: 100vw;
  }

  .dialog-shell {
    border-radius: 0;
    grid-template-columns: 1fr;
    max-height: 100svh;
    overflow-y: auto;
  }

  .dialog-gallery {
    display: block;
    min-height: 0;
    overflow: hidden;
  }

  .dialog-main-image {
    height: 280px;
  }

  .dialog-thumbs {
    display: flex;
    gap: 8px;
    height: 82px;
    padding: 10px;
  }

  .thumb-button {
    aspect-ratio: auto;
    flex: 0 0 78px;
    height: 58px;
  }

  .dialog-content {
    background: var(--paper);
    overflow: visible;
    padding: 24px 20px 0;
    position: relative;
    z-index: 1;
  }

  .dialog-actions {
    margin: 24px -20px 0;
    padding: 14px 20px 18px;
  }

  .dialog-actions .button {
    flex: 1 1 140px;
  }
}

/* Slim owner-referral band: the only BnBNerd mention on the guest site,
   pointing owners to bnbnerd.com without cluttering the booking flow. */
.referral-strip {
  border-top: 1px solid rgba(24, 35, 34, 0.1);
  background: var(--paper);
  padding: 20px clamp(16px, 4vw, 56px);
  text-align: center;
}

.referral-strip p {
  margin: 0 auto;
  max-width: 760px;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.5;
}

.referral-strip a {
  color: var(--forest);
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
}

.referral-strip a:hover {
  text-decoration: underline;
}

/* ── REVIEWS ───────────────────────────────────────────────────────── */

.reviews-heading {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.reviews-avg {
  align-items: center;
  display: inline-flex;
  font-size: 0.88rem;
  font-weight: 600;
  gap: 4px;
}

.reviews-avg-number {
  color: var(--ink);
  font-weight: 800;
}

.reviews-avg-count {
  color: var(--muted);
  font-weight: 600;
}

.star {
  flex-shrink: 0;
}

.star-filled {
  color: var(--gold);
}

.star-empty {
  color: var(--limestone);
}

.reviews-container {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.review-card {
  border: 1px solid rgba(24, 35, 34, 0.1);
  border-radius: var(--radius);
  padding: 16px;
}

.review-header {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 6px;
}

.review-stars {
  align-items: center;
  display: inline-flex;
  gap: 2px;
}

.review-meta {
  color: var(--muted);
  font-size: 0.84rem;
  font-weight: 600;
}

.review-title {
  font-size: 0.95rem;
  font-weight: 700;
  margin: 0 0 4px;
}

.review-content {
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.55;
  margin: 0;
  /* Clamp long reviews to 4 lines */
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.reviews-more {
  color: var(--lake);
  font-size: 0.88rem;
  font-weight: 700;
  margin: 0;
}

/* ── ACCESSIBILITY (WCAG 2.2 AA) ───────────────────────────────────── */

/* Focus indicator — visible on keyboard navigation (not mouse clicks). */
:focus-visible {
  outline: 3px solid #4f6ef7;
  outline-offset: 2px;
}

/* Skip-to-content link — first focusable element in <body>. */
.skip-link {
  position: absolute;
  top: -40px;
  left: 0;
  background: #000;
  color: #fff;
  padding: 8px 16px;
  z-index: 9999;
  font-size: 14px;
  text-decoration: none;
}
.skip-link:focus {
  top: 0;
}

/* Respect user motion preferences. */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* Screen-reader-only text — visually hidden but announced. */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Links in body content: underline so they are distinguishable by more
   than color alone (WCAG 1.4.1). Nav/button links stay as-is because
   their interactive context is clear without underline. */
.hero-copy a,
.section-heading a,
.experience-grid a,
.contact-section .button-outline {
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* Footer link underline for contrast distinguishability */
.site-footer a {
  text-decoration: underline;
  text-underline-offset: 2px;
}
