/* MVP Rentals — shared stylesheet.
   Design tokens at top, layout below.
   Dark-green theme (matches homepage modal). */

:root {
  --green: #07120a;
  --green-dark: #174d1c;
  --gold: #C8990A;
  --gold-soft: #E8C547;
  /* Dark-theme tokens. Names kept for compatibility with existing rules. */
  --bg: #07120a;            /* page background (matches homepage modal body) */
  --panel: #0f2614;         /* card / panel background, one shade lighter than bg */
  --panel-2: #143119;       /* slightly lighter still, for nested chips/buttons */
  --cream: var(--bg);       /* legacy alias - was light cream, now dark bg */
  --cream-dark: var(--panel-2); /* legacy alias for cells/chips */
  --ink: #e8e8e8;           /* body text on dark bg */
  --ink-soft: #b9bdb6;      /* secondary text */
  --line: #2a3d2f;          /* hairline borders on dark bg */
  --error: #ff8a80;
  --accent: var(--gold);

  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 18px;

  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.35);
  --shadow-md: 0 4px 14px rgba(0, 0, 0, 0.55);

  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Helvetica Neue", Arial, sans-serif;
  --font-display: "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", Georgia, serif;

  --container: 1080px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: var(--font-sans);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--gold-soft); text-decoration: none; }
a:hover { text-decoration: underline; color: #fff; }

h1, h2, h3, h4 { font-family: var(--font-display); color: var(--gold-soft); margin: 0 0 0.4em; line-height: 1.2; }
h1 { font-size: 2.4rem; }
h2 { font-size: 1.6rem; }
h3 { font-size: 1.2rem; }

.container { max-width: var(--container); margin: 0 auto; padding: 0 24px; }

.site-header {
  background: var(--green);
  color: #fff;
  padding: 6px 0;
  border-bottom: 4px solid var(--gold);
}
.site-header .container { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; }
.site-header .brand { color: var(--gold-soft); font-family: var(--font-display); font-size: 1.4rem; font-weight: 700; letter-spacing: 0.4px; }
.site-header .brand:hover { text-decoration: none; color: var(--gold-soft); }
.site-header nav a { color: #fff; margin-left: 18px; font-size: 0.95rem; }
.site-header nav a:hover { color: var(--gold-soft); text-decoration: none; }
.site-header .brand-wrap { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.site-header .brand-wrap:hover { text-decoration: none; }
.nav-logo { height: 52px; width: auto; vertical-align: middle; margin-right: 10px; border-radius: 50%; }

.hero {
  position: relative;
  height: clamp(260px, 42vw, 460px);
  background-size: cover;
  background-position: center;
  background-color: var(--green);
}
.hero::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,0.05) 0%, rgba(0,0,0,0.45) 100%);
}
.hero-overlay {
  position: relative; z-index: 1;
  height: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
  display: flex; flex-direction: column; justify-content: flex-end;
  padding-bottom: 28px;
  color: #fff;
}
.hero-overlay h1 { color: #fff; margin-bottom: 6px; }
.hero-overlay .tagline { font-size: 1.05rem; opacity: 0.92; }

section { padding: 36px 0; }
section + section { border-top: 1px solid var(--line); }

.lede { font-size: 1.1rem; max-width: 720px; color: var(--ink); }

.prop-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 22px;
  margin-top: 18px;
}
.prop-card {
  background: var(--panel);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  border-top: 4px solid var(--accent);
  display: flex;
  flex-direction: column;
  color: var(--ink);
}
.prop-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); text-decoration: none; }
.prop-card .card-img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; background: var(--panel-2); }
.prop-card .card-body { padding: 14px 18px 18px; }
.prop-card h3 { color: var(--gold-soft); margin-bottom: 4px; }
.prop-card .addr { color: var(--ink-soft); font-size: 0.9rem; margin-bottom: 8px; }
.prop-card .from-rate { color: #fff; font-weight: 600; font-size: 0.95rem; }

.rate-card {
  background: var(--panel);
  border-radius: var(--radius-md);
  padding: 18px 22px;
  box-shadow: var(--shadow-sm);
  border-left: 4px solid var(--accent);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(165px, 1fr));
  gap: 16px;
}
.rate-card .rate-item .label { color: var(--ink-soft); font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.5px; white-space: nowrap; }
.rate-card .rate-item .rate-note { display: block; font-size: 0.62rem; text-transform: none; letter-spacing: 0; color: var(--ink-soft); white-space: nowrap; margin-top: 3px; opacity: 0.85; }
.rate-card .rate-item .value { font-size: 1.25rem; font-weight: 600; color: #fff; margin-top: 4px; }

.calendar-wrap { margin-top: 20px; }
.calendar-controls { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.calendar-controls button {
  background: var(--panel-2); color: var(--ink); border: 0;
  padding: 8px 14px; border-radius: var(--radius-sm); cursor: pointer; font-weight: 600;
}
.calendar-controls button:hover { background: var(--gold); color: #fff; }
.calendar-controls button:disabled { opacity: 0.4; cursor: not-allowed; }
.calendar-month-label { font-family: var(--font-display); font-size: 1.2rem; color: var(--gold-soft); }

.calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
}
.cal-dow {
  text-align: center; font-size: 0.78rem; color: var(--ink-soft); padding: 4px 0;
  text-transform: uppercase; letter-spacing: 0.5px;
}
.cal-cell {
  background: var(--green-dark);
  aspect-ratio: 1 / 1;
  border-radius: var(--radius-sm);
  padding: 4px;
  display: flex; flex-direction: column; justify-content: space-between;
  font-size: 0.85rem;
  cursor: pointer;
  user-select: none;
  border: 1px solid transparent;
  transition: background 0.1s, border-color 0.1s;
}
.cal-cell .day { font-weight: 600; color: var(--ink); }
.cal-cell .price { display: none; }
.cal-cell.empty { background: transparent; cursor: default; }
.cal-cell.booked { background: #8a8f8a; color: #3a3f3a; cursor: not-allowed; }
.cal-cell.booked .day { color: #3a3f3a; text-decoration: line-through; }
.cal-cell.past { opacity: 0.35; cursor: not-allowed; }
.cal-cell.selected, .cal-cell.in-range, .cal-cell.endpoint { background: var(--gold); color: var(--bg); border-color: var(--gold-soft); }
.cal-cell.selected .day, .cal-cell.in-range .day, .cal-cell.endpoint .day { color: var(--bg); }
.cal-cell:hover:not(.empty):not(.booked):not(.past) { border-color: var(--gold-soft); }

.calendar-legend { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 12px; font-size: 0.85rem; color: var(--ink-soft); }
.calendar-legend .swatch { display: inline-block; width: 14px; height: 14px; border-radius: 3px; vertical-align: middle; margin-right: 5px; }

.total-panel {
  background: var(--panel);
  border-radius: var(--radius-md);
  padding: 16px 20px;
  margin-top: 20px;
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
  color: var(--ink);
}
.total-panel h3 { margin-bottom: 10px; color: var(--gold-soft); }
.total-panel .line { display: flex; justify-content: space-between; padding: 4px 0; font-size: 0.95rem; }
.total-panel .line.total { font-weight: 700; font-size: 1.1rem; border-top: 1px solid var(--line); margin-top: 6px; padding-top: 8px; color: #fff; }
.total-panel .empty-state { color: var(--ink-soft); font-size: 0.9rem; }

.booking-form {
  background: var(--panel);
  border-radius: var(--radius-md);
  padding: 22px;
  margin-top: 22px;
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
  color: var(--ink);
}
.booking-form .row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-bottom: 12px; }
.booking-form .row.full { grid-template-columns: 1fr; }
.booking-form label { display: block; font-size: 0.85rem; color: var(--ink-soft); margin-bottom: 4px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.5px; }
.booking-form input[type=text],
.booking-form input[type=email],
.booking-form input[type=tel],
.booking-form input[type=number],
.booking-form textarea,
.booking-form select {
  width: 100%; padding: 10px 12px; font-size: 1rem;
  border: 1px solid var(--line); border-radius: var(--radius-sm);
  font-family: inherit; background: #F8F5EF; color: #1B1F1A;
}
.booking-form textarea { min-height: 90px; resize: vertical; }
.booking-form .pets-row { display: flex; gap: 12px; align-items: center; }
.booking-form .sms-consent {
  background: var(--panel-2); padding: 12px 14px; border-radius: var(--radius-sm);
  font-size: 0.85rem; color: var(--ink-soft); margin-bottom: 12px; line-height: 1.5;
}
.booking-form .sms-consent a { color: var(--gold-soft); }
.booking-form .form-payment-note { font-size: 13px; color: var(--ink-soft); font-style: italic; margin: 0 0 12px 0; line-height: 1.45; }
.booking-form button[type=submit] {
  background: var(--green); color: #fff; border: 0;
  padding: 12px 22px; border-radius: var(--radius-sm); font-size: 1rem; font-weight: 600;
  cursor: pointer; transition: background 0.15s;
}
.booking-form button[type=submit]:hover { background: var(--gold); color: var(--bg); }
.booking-form button[type=submit]:disabled { background: #555; cursor: not-allowed; }
.form-message { margin-top: 12px; padding: 10px 14px; border-radius: var(--radius-sm); font-size: 0.95rem; display: none; }
.form-message.error { background: #4a1f1c; color: #ff8a80; display: block; }
.form-message.success { background: #1d3a1f; color: #c8e6cb; display: block; }

.pay-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; margin-top: 16px; }
.pay-block { background: var(--panel); padding: 18px 20px; border-radius: var(--radius-md); border-top: 4px solid var(--accent); box-shadow: var(--shadow-sm); color: var(--ink); }
.pay-block h4 { margin-bottom: 6px; color: var(--gold-soft); font-family: var(--font-sans); }
.pay-block .id { font-family: ui-monospace, "SF Mono", "Cascadia Mono", Menlo, Consolas, monospace; background: var(--panel-2); color: var(--ink); padding: 6px 10px; border-radius: var(--radius-sm); display: inline-block; margin: 6px 0; }
.pay-block .copy-btn { background: var(--gold); color: #fff; border: 0; padding: 6px 12px; border-radius: var(--radius-sm); font-size: 0.85rem; cursor: pointer; margin-left: 6px; }
.pay-block .copy-btn:hover { background: var(--gold-soft); color: var(--bg); }
.pay-block p { font-size: 0.9rem; color: var(--ink-soft); margin: 6px 0 0; }

.included-list { list-style: none; padding: 0; display: block; }
.included-list li { padding: 5px 0 5px 22px; position: relative; font-size: 0.95rem; color: var(--ink); }
.included-list li:not(.included-section)::before { content: "✓"; position: absolute; left: 0; color: var(--gold-soft); font-weight: 700; }

.site-footer { background: var(--green-dark); color: #fff; padding: 28px 0; margin-top: 40px; font-size: 0.9rem; }
.site-footer .container { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.site-footer a { color: var(--gold-soft); margin-right: 16px; }
.site-footer a:hover { color: #fff; }
.site-footer .legal { font-size: 0.8rem; opacity: 0.75; max-width: 540px; }

.legal-page { max-width: 760px; margin: 0 auto; padding: 30px 24px; color: var(--ink); }
.legal-page h1 { margin-bottom: 6px; color: var(--gold-soft); }
.legal-page .effective { color: var(--ink-soft); font-size: 0.9rem; margin-bottom: 24px; }
.legal-page h2 { margin-top: 28px; font-size: 1.25rem; color: var(--gold-soft); }
.legal-page ul, .legal-page ol { padding-left: 22px; }
.legal-page li { margin-bottom: 4px; }

.confirmation { max-width: 640px; margin: 60px auto; padding: 36px 28px; background: var(--panel); border-radius: var(--radius-lg); border-top: 6px solid var(--gold); box-shadow: var(--shadow-md); text-align: center; color: var(--ink); }
.confirmation .check { width: 80px; height: 80px; border-radius: 50%; background: var(--green); color: #fff; display: flex; align-items: center; justify-content: center; font-size: 3rem; margin: 0 auto 18px; line-height: 1; }
.confirmation h1 { margin-bottom: 10px; }
.confirmation p { font-size: 1.05rem; color: var(--ink-soft); }

@media (max-width: 700px) {
  h1 { font-size: 1.9rem; }
  h2 { font-size: 1.35rem; }
  .booking-form .row { grid-template-columns: 1fr; }
  .site-header .container { flex-direction: column; align-items: flex-start; }
  .site-header nav a { margin-left: 0; margin-right: 14px; }
  .cal-cell { padding: 2px; font-size: 0.78rem; }
  .cal-cell .price { font-size: 0.62rem; }
}

/* ========= utility-page CTA block (privacy/terms/etc.) ========= */
.utility-cta { max-width: 640px; margin: 40px auto 60px; padding: 28px 24px; background: var(--panel); border-radius: var(--radius-lg); border-top: 4px solid var(--gold); box-shadow: var(--shadow-md); text-align: center; color: var(--ink); }
.utility-cta h2 { font-size: 1.4rem; margin-bottom: 8px; color: var(--ink); }
.utility-cta p { color: var(--ink-soft); font-size: 1rem; margin-bottom: 18px; }
.utility-cta .cta-button { display: inline-block; background: var(--green); color: #fff; padding: 12px 28px; border-radius: var(--radius-md); font-weight: 700; font-size: 1rem; text-decoration: none; letter-spacing: 0.4px; transition: background 0.18s, transform 0.18s; }
.utility-cta .cta-button:hover { background: var(--green-dark); color: var(--gold-soft); transform: translateY(-1px); text-decoration: none; }

/* ========= 3-month calendar layout ========= */
.calendar-months { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; margin-bottom: 14px; }
.calendar-month { background: var(--panel); border-radius: var(--radius-md); padding: 14px 14px 16px; border: 1px solid var(--line); box-shadow: var(--shadow-sm); }
.calendar-month .calendar-month-label { font-family: var(--font-display); font-size: 1.05rem; color: var(--gold-soft); text-align: center; margin-bottom: 8px; padding-bottom: 6px; border-bottom: 2px solid var(--line); }
@media (max-width: 980px) { .calendar-months { grid-template-columns: 1fr; gap: 16px; } }


/* ========= property photo gallery (per-room cells, in-place toggle) ========= */
.photo-gallery-section { padding: 24px 0 0; }
.photo-gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 16px; }
/* Legacy flat-list fallback: keep older flat-photo support working */
.photo-gallery > img { width: 100%; aspect-ratio: 4/3; object-fit: cover; border-radius: var(--radius-md); background: var(--panel-2); }

/* Per-room cell card */
.photo-cell { position: relative; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius-md); overflow: hidden; box-shadow: var(--shadow-sm, 0 1px 2px rgba(0,0,0,0.2)); display: flex; flex-direction: column; }
.photo-cell__frame { position: relative; width: 100%; aspect-ratio: 4/3; background: var(--panel-2); overflow: hidden; }
.photo-cell__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; background: var(--panel-2); }

/* Prev/next arrow buttons over the photo */
.photo-cell__nav { position: absolute; top: 50%; transform: translateY(-50%); width: 36px; height: 36px; border: none; border-radius: 999px; background: rgba(10, 22, 14, 0.55); color: var(--gold-soft); font-size: 18px; line-height: 1; cursor: pointer; display: flex; align-items: center; justify-content: center; padding: 0; transition: background 0.15s, color 0.15s, opacity 0.15s; opacity: 0; }
.photo-cell:hover .photo-cell__nav,
.photo-cell:focus-within .photo-cell__nav { opacity: 1; }
.photo-cell__nav:hover { background: rgba(10, 22, 14, 0.85); color: var(--gold); }
.photo-cell__nav:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; opacity: 1; }
.photo-cell__nav--prev { left: 8px; }
.photo-cell__nav--next { right: 8px; }
.photo-cell__nav[disabled] { display: none; }

/* Label area below photo with room name + count */
.photo-cell__label { padding: 10px 12px; display: flex; align-items: baseline; justify-content: space-between; gap: 8px; background: var(--panel); }
.photo-cell__room { font-family: var(--font-display); color: var(--gold-soft); font-size: 1rem; letter-spacing: 0.4px; }
.photo-cell__count { color: var(--ink-soft); font-size: 0.85rem; white-space: nowrap; }

/* Always-show arrows on touch devices (no hover available) */
@media (hover: none) {
  .photo-cell__nav { opacity: 1; }
}

/* Mobile: narrower min cell width */
@media (max-width: 640px) {
  .photo-gallery { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
}

/* ========= per-property word cloud ========= */
.wordcloud-section { padding: 40px 0; }
.wordcloud-section h2 { margin-bottom: 6px; font-size: 3rem; line-height: 1.1; }
.wordcloud-section .wordcloud-subtitle {
  font-size: 0.95rem;
  font-style: italic;
  color: var(--ink-soft);
  margin-top: -8px;
  margin-bottom: 12px;
}
@keyframes throb-a { 0%, 100% { color: #d62828; } 50% { color: #ffd60a; } }
@keyframes throb-b { 0%, 100% { color: #ffd60a; } 50% { color: #d62828; } }
.throb-love { animation: throb-a 1.5s ease-in-out infinite; font-weight: 700; }
.throb-will { animation: throb-b 1.5s ease-in-out infinite; font-weight: 700; }
.wordcloud-section img { border-radius: var(--radius-md); }

.photo-cell--empty .photo-cell__frame { background: rgba(255,255,255,0.03); border: 1px dashed rgba(255,255,255,0.15); }
.photo-cell--empty .photo-cell__empty { display: flex; align-items: center; justify-content: center; height: 100%; color: rgba(255,255,255,0.45); font-style: italic; font-size: 0.95rem; letter-spacing: 0.5px; }
.photo-cell--empty .photo-cell__count { color: rgba(232, 197, 71, 0.6); }

/* Section headings + parenthetical note (community/home split) */
.included-list .included-section { padding-left: 0; margin: 14px 0 4px; font-weight: 700; color: var(--gold-soft); text-transform: uppercase; letter-spacing: 0.6px; font-size: 0.8em; }
.included-list .included-section:first-child { margin-top: 0; }
.included-list .included-section::before { content: none; }
.amenity-note { font-size: 0.82em; color: rgba(255,255,255,0.55); font-style: italic; margin-left: 4px; }
