/**
 * Frontend styles for the Camper Booking System.
 *
 * Self-contained: uses semantic class names and its own design tokens so output
 * matches the brand regardless of the active theme. Tokens can be overridden by
 * the theme by redefining the CSS variables on `.cb-scope`.
 */

.cb-scope {
  --cb-primary: #2a4839;
  --cb-primary-dark: #1e3a29;
  --cb-cream: #f6f1e7;
  --cb-sand: #e7dec9;
  --cb-ink: #1e1e1e;
  --cb-muted: #6b6b63;
  --cb-white: #ffffff;
  --cb-radius: 16px;
  font-family: "Inter", ui-sans-serif, system-ui, sans-serif;
  color: var(--cb-ink);
  box-sizing: border-box;
}

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

.cb-eyebrow {
  margin: 0;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--cb-muted);
}

.cb-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  border-radius: 0.5rem;
  padding: 0.7rem 1.2rem;
  font-size: 0.95rem;
  font-weight: 500;
  cursor: pointer;
  border: 1px solid transparent;
  text-decoration: none;
  transition: 0.25s ease;
}
.cb-btn--sm {
  padding: 0.5rem 1.2rem;
}
.cb-btn--primary {
  background: var(--cb-primary);
  color: #fff;
}
.cb-btn--primary:hover {
  background: var(--cb-primary-dark);
  color: #fff;
}
.cb-btn--soft {
  background: var(--cb-sand);
  color: var(--cb-primary);
}
.cb-btn--soft:hover {
  background: #ddd1b6;
}
.cb-btn[disabled],
.cb-btn[aria-disabled="true"] {
  opacity: 0.5;
  cursor: not-allowed;
}

/* ---- Offer grid ---- */
.cb-offer {
}
.cb-offer__inner {
  max-width: 65rem;
  margin: 0 auto;
  padding: 4rem 1rem;
}
.cb-offer__head {
  text-align: center;
  margin-bottom: 2.5rem;
}
.cb-offer__title {
  font-family: "Roboto Slab", Georgia, serif;
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 700;
  margin: 0.4rem 0 0;
  color: var(--cb-primary);
}
.cb-offer__grid {
  display: flex;
  gap: 1.5rem;
  align-items: stretch;
  justify-content: center;
}
.cb-offer__empty {
  text-align: center;
  color: var(--cb-muted);
}

/* ---- Camper card ---- */
.cb-card {
  background: var(--cb-cream);
  border-radius: var(--cb-radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
  flex: 1;
  min-width: 280px;
  max-width: 340px;
}
.cb-card__media {
  display: block;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: var(--cb-sand);
}
.cb-card__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.cb-card__body {
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  flex: 1;
}
.cb-card__title {
  font-family: "Roboto Slab", Georgia, serif;
  font-size: 1.1rem;
  font-weight: 600;
  margin: 0;
}
.cb-card__subtitle {
  margin: 0;
  color: var(--cb-muted);
  font-size: 0.85rem;
}
.cb-card__specs {
  list-style: none;
  margin: 0.5rem 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.5rem;
}
.cb-card__spec {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
  background: var(--cb-sand);
  border-radius: 10px;
  padding: 0.5rem 0.25rem;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--cb-muted);
}
.cb-card__spec-icon svg {
  width: 24px;
  height: 24px;
  color: var(--cb-primary);
  stroke-width: 2;
}
.cb-card__footer {
  margin-top: auto;
  padding-top: 0.75rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}
.cb-card__price {
  font-weight: 500;
  color: var(--cb-primary);
  font-size: 0.85rem;
}

.cb-btn--light {
  background: #fff;
  color: var(--cb-primary);
}
.cb-btn--light:hover {
  background: var(--cb-cream);
}

/* ===== Single camper ===== */
.cb-single {
  display: block;
}
.cb-single__top {
  max-width: 80rem;
  margin: 0 auto;
  padding: 1.5rem 1rem 2.5rem;
}
.cb-breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  align-items: center;
  font-size: 0.85rem;
  color: var(--cb-muted);
  margin-bottom: 1.5rem;
}
.cb-breadcrumb a {
  color: var(--cb-muted);
  text-decoration: none;
}
.cb-breadcrumb a:hover {
  color: var(--cb-primary);
}
.cb-breadcrumb__current {
  color: var(--cb-ink);
  font-weight: 500;
}
.cb-single__hero {
  display: grid;
  gap: 2.5rem;
  grid-template-columns: 1fr;
}
@media (min-width: 900px) {
  .cb-single__hero {
    grid-template-columns: 1fr 1fr;
    align-items: start;
  }

  .cb-single__info {
    position: sticky;
    top: 90px;
  }
}
.cb-badge {
  display: inline-block;
  background: var(--cb-primary);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  padding: 0.3rem 0.7rem;
  border-radius: 6px;
}
.cb-single__title {
  font-family: "Roboto Slab", Georgia, serif;
  font-size: clamp(1.7rem, 3.5vw, 2.4rem);
  font-weight: 700;
  margin: 0.7rem 0 1rem;
}
.cb-single__desc {
  color: var(--cb-muted);
  font-size: 0.95rem;
  line-height: 1.7;
}
.cb-single__desc p {
  margin: 0 0 0.8rem;
}
.cb-single__chips {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin: 1.5rem 0;
  padding: 0;
}
.cb-chip {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
  min-width: 72px;
  background: var(--cb-cream);
  border-radius: 12px;
  padding: 0.7rem 0.9rem;
  font-weight: 600;
  font-size: 0.9rem;
}
.cb-chip__icon svg {
  width: 20px;
  height: 20px;
  color: var(--cb-primary);
}
.cb-single__prices {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}
.cb-price-pill {
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
  background: var(--cb-sand);
  border-radius: 10px;
  padding: 0.6rem 1rem;
}
.cb-price-pill__label {
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--cb-primary);
}
.cb-price-pill__value {
  font-weight: 700;
}

/* Gallery */
.cb-gallery__main {
  display: block;
  border-radius: 14px;
  overflow: hidden;
  aspect-ratio: 4 / 3;
  background: var(--cb-sand);
}
.cb-gallery__main-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.cb-gallery__thumbs {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.6rem;
  margin-top: 0.6rem;
}
.cb-gallery__thumb {
  display: block;
  border-radius: 8px;
  overflow: hidden;
  aspect-ratio: 1 / 1;
  background: var(--cb-sand);
}
.cb-gallery__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Video tile in the gallery */
.cb-gallery__thumb--video {
  position: relative;
}
.cb-gallery__video-thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  background: #000;
  pointer-events: none;
}
.cb-gallery__play {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(30, 58, 41, 0.28);
  transition: background 0.2s ease;
}
.cb-gallery__thumb--video:hover .cb-gallery__play {
  background: rgba(30, 58, 41, 0.42);
}
.cb-gallery__play::before {
  content: "";
  position: absolute;
  width: 44px;
  height: 44px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.35);
  border: 2px solid rgba(255, 255, 255, 0.9);
}
.cb-gallery__play svg {
  position: relative;
  width: 22px;
  height: 22px;
  color: #fff;
  margin-left: 3px;
  filter: drop-shadow(0 1px 3px rgba(0, 0, 0, 0.45));
}
.cb-gallery__hint {
  margin-top: 0.6rem;
  font-size: 0.78rem;
  color: var(--cb-muted);
}
.cb-gallery__placeholder {
  border-radius: 14px;
  aspect-ratio: 4 / 3;
  background: var(--cb-sand);
}

/* Green CTA band */
.cb-single__cta {
  background: var(--cb-primary);
  color: #fff;
}
.cb-single__cta-inner {
  max-width: 80rem;
  margin: 0 auto;
  padding: 1.75rem 1rem;
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  align-items: center;
  justify-content: space-between;
}
.cb-single__cta-title {
  font-family: "Roboto Slab", Georgia, serif;
  font-size: 1.4rem;
  margin: 0;
}
.cb-single__cta-text {
  margin: 0.25rem 0 0;
  color: rgba(255, 255, 255, 0.8);
  font-size: 0.9rem;
}
.cb-single__cta-actions {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  flex-wrap: wrap;
}
.cb-single__cta-notice {
  margin: 0;
  color: rgba(255, 255, 255, 0.85);
  font-size: 0.9rem;
}
.cb-single__phone {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  color: #fff;
  text-decoration: none;
  font-size: 1.15rem;
  font-weight: 600;
}
.cb-single__phone-icon {
  display: inline-flex;
  width: 48px;
  height: 48px;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.15);
}
.cb-single__phone-icon svg {
  width: 24px;
  height: 24px;
}

/* Sections */
.cb-single__sections {
  max-width: 80rem;
  margin: 0 auto;
  padding: 3rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 3.5rem;
}
.cb-section__title {
  font-family: "Roboto Slab", Georgia, serif;
  font-size: 1.5rem;
  font-weight: 700;
  margin: 0.3rem 0 1.5rem;
}
.cb-spec-table {
  width: 100%;
  max-width: 640px;
  border-collapse: collapse;
  font-size: 0.92rem;
}
.cb-spec-table th,
.cb-spec-table td {
  text-align: left;
  padding: 0.7rem 1rem;
  border: 0;
}
.cb-spec-table th {
  font-weight: 500;
  color: var(--cb-ink);
  width: 45%;
}
.cb-spec-table tr:nth-child(odd) {
  background: var(--cb-cream);
}
.cb-spec-table td {
  font-weight: 600;
}

.cb-equip-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}
.cb-equip-card {
  background: var(--cb-cream);
  border-radius: 14px;
  padding: 1.5rem;
  text-align: center;
}
.cb-equip-card__icon svg {
  width: 34px;
  height: 34px;
  color: var(--cb-primary);
}
.cb-equip-card__title {
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin: 0.8rem 0 0.4rem;
}
.cb-equip-card__desc {
  font-size: 0.85rem;
  color: var(--cb-muted);
  margin: 0;
  line-height: 1.5;
}

.cb-rules-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}
.cb-rule {
  display: flex;
  gap: 1rem;
  padding: 1.25rem;
  border-radius: 14px;
  background: #f0f0ee;
}
.cb-rule--yes {
  background: #dbe9dd;
}
.cb-rule__icon {
  flex-shrink: 0;
  display: inline-flex;
  width: 36px;
  height: 36px;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.05);
}
.cb-rule__icon svg {
  width: 20px;
  height: 20px;
}
.cb-rule--yes .cb-rule__icon {
  color: var(--cb-primary);
}
.cb-rule--no .cb-rule__icon {
  color: #9aa0a6;
}
.cb-rule__title {
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin: 0 0 0.4rem;
}
.cb-rule__desc {
  font-size: 0.85rem;
  color: var(--cb-muted);
  margin: 0;
  line-height: 1.5;
}

/* ===== Booking calendar block ===== */
.cb-booking {
  max-width: 80rem;
  margin: 0 auto;
  padding: 2.5rem 1rem;
}
.cb-booking__heading {
  font-family: "Roboto Slab", Georgia, serif;
  font-size: 1.6rem;
  margin: 0 0 1.5rem;
}
.cb-booking__grid {
  display: grid;
  gap: 2rem;
  grid-template-columns: 1fr;
  align-items: start;
}
@media (min-width: 900px) {
  .cb-booking__grid {
    grid-template-columns: 2fr 1fr;
  }
}
.cb-booking__summary {
  display: flex;
  gap: 1rem;
  align-items: center;
  background: var(--cb-cream);
  border-radius: 14px;
  padding: 1rem;
  margin-bottom: 1.5rem;
}
.cb-booking__thumb {
  width: 96px;
  height: 72px;
  border-radius: 10px;
  overflow: hidden;
  flex-shrink: 0;
  background: var(--cb-sand);
}
.cb-booking__thumb-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.cb-booking__camper {
  font-family: "Roboto Slab", Georgia, serif;
  font-size: 1.2rem;
  margin: 0;
}
.cb-booking__rates {
  margin: 0.4rem 0 0;
  font-size: 0.85rem;
  color: var(--cb-muted);
}
.cb-booking__label {
  display: block;
  font-weight: 600;
  margin-bottom: 0.4rem;
}
.cb-booking__input {
  width: 100%;
  padding: 0.6rem 0.8rem;
  border: 1px solid #d8d2c2;
  border-radius: 10px;
  margin-bottom: 0.75rem;
  background: #fff;
}
.cb-booking__error {
  color: #a02c2c;
  font-size: 0.88rem;
  margin: 0.5rem 0;
}
.cb-booking__extras {
  border: 1px solid #e7e2d4;
  border-radius: 12px;
  padding: 1rem 1.25rem;
  margin-top: 1.25rem;
}
.cb-booking__extras legend {
  font-weight: 700;
  padding: 0 0.4rem;
}
.cb-booking__extra {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.4rem 0;
}
.cb-booking__extra-price {
  margin-left: auto;
  color: var(--cb-muted);
  font-size: 0.88rem;
}
.cb-booking__aside {
  position: sticky;
  top: 90px;
  background: var(--cb-cream);
  border-radius: 16px;
  padding: 1.5rem;
}
.cb-booking__hint {
  color: var(--cb-muted);
  font-size: 0.9rem;
  margin: 0;
}
.cb-booking__row {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.4rem 0;
  font-size: 0.95rem;
}
.cb-booking__row--total {
  border-top: 1px solid #ddd6c5;
  margin-top: 0.4rem;
  padding-top: 0.7rem;
  font-weight: 700;
  font-size: 1.05rem;
}
.cb-booking__row--advance {
  color: var(--cb-primary);
  font-weight: 700;
}
.cb-booking__submit {
  width: 100%;
  justify-content: center;
  margin-top: 1.25rem;
}

/* flatpickr inline tweaks to match the brand */
.cb-booking .flatpickr-calendar.inline {
  box-shadow: none;
  margin: 0 auto;
}
.cb-booking .flatpickr-day.selected,
.cb-booking .flatpickr-day.startRange,
.cb-booking .flatpickr-day.endRange {
  background: var(--cb-primary);
  border-color: var(--cb-primary);
}
.cb-booking .flatpickr-day.inRange {
  background: var(--cb-sand);
  border-color: var(--cb-sand);
  box-shadow:
    -5px 0 0 var(--cb-sand),
    5px 0 0 var(--cb-sand);
}

/* ---- Legacy details table (kept for back-compat) ---- */
.camper-details {
  width: 100%;
}
