/* =============================================================================
   CAR360 — Hero Widget Styles
   hero-widget.css · car360-child theme
   ============================================================================= */

/* ── Shell ──────────────────────────────────────────────────────────────────── */
.c360-hero {
  position: relative !important;
  background: #0E1113;
  color: #fff;
  overflow: visible;
  min-height: 520px;
}

/* Radial glow (top-right) */
.c360-hero__glow {
  position: absolute;
  inset: 0;
  background: radial-gradient(
    120% 90% at 78% 12%,
    rgba(255, 255, 255, 0.10),
    transparent 55%
  );
  pointer-events: none;
}

/* ── Car silhouette ─────────────────────────────────────────────────────────── */
.c360-hero__car-wrap {
  position: absolute !important;
  top: 0 !important;
  right: 0 !important;
  bottom: 0 !important;
  width: 48% !important;
  height: 100% !important;
  pointer-events: none;
}

.c360-hero__car-img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  object-position: center center !important;
  display: block !important;
  opacity: 0.96;
}

/* fade left edge of car image into the dark background */
.c360-hero__car-wrap::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to left, transparent 60%, #0E1113 100%);
  pointer-events: none;
}

/* ── Inner wrapper ──────────────────────────────────────────────────────────── */
.c360-hero__inner {
  position: relative;
  max-width: 1240px;
  margin: 0 auto;
  padding: 84px 32px 72px;
  display: flex;
  flex-direction: column;
}

/* ── Content (text column — stays left, never bleeds into car zone) ─────────── */
.c360-hero__content {
  max-width: 52%;
}

/* ── Badge ──────────────────────────────────────────────────────────────────── */
.c360-hero__badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 14px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 9999px;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.02em;
  color: #E7E2D6;
  margin: 0 0 26px;  /* reset <p> default top margin */
}

.c360-hero__badge-dot {
  flex-shrink: 0;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #EC3D23;
}

/* ── Headline ───────────────────────────────────────────────────────────────── */
.c360-hero__headline {
  font-family: 'Space Grotesk', 'Sora', sans-serif;
  font-weight: 700;
  font-size: clamp(40px, 5.5vw, 64px);
  line-height: 1.02;
  letter-spacing: -0.03em;
  color: #fff;
  margin: 0 0 22px;
}

.c360-hero__headline-accent {
  display: block;
  color: #EC3D23;
}

/* ── Sub-headline ───────────────────────────────────────────────────────────── */
.c360-hero__sub {
  font-size: 19px;
  line-height: 1.55;
  color: #B9B4A9;
  max-width: 480px;
  margin: 0;  /* spacing handled by stats margin-top below */
}

/* ── dl/dt/dd reset (browser defaults add margins we don't want) ────────────── */
.c360-hero__booking-field,
.c360-hero__stats {
  margin: 0;
  padding: 0;
}

.c360-hero__booking-field dt,
.c360-hero__booking-field dd,
.c360-hero__stats dt,
.c360-hero__stats dd {
  margin: 0;
  padding: 0;
}

/* ── Booking bar — constrained to text column, never overlaps car image ──────── */
.c360-hero__booking {
  position: relative;
  background: #fff;
  color: #0E1113;
  border-radius: 18px;
  padding: 14px;
  display: flex;
  align-items: stretch;
  gap: 8px;
  max-width: 52%;
  box-shadow: 0 30px 60px -20px rgba(0, 0, 0, 0.55);
  flex-wrap: wrap;
  margin-top: 48px;
}

.c360-hero__booking-field {
  flex: 1;
  min-width: 120px;
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 10px 16px;
}

.c360-hero__booking-eyebrow {
  font-size: 11px;
  font-weight: 600;
  color: #9A8F7A;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.c360-hero__booking-value {
  font-size: 16px;
  font-weight: 600;
  color: #0E1113;
  white-space: nowrap; /* desktop only — overridden on mobile */
}

.c360-hero__booking-divider {
  width: 1px;
  background: rgba(14, 17, 19, 0.10);
  align-self: stretch;
  flex-shrink: 0;
}

.c360-hero__booking-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  background: #EC3D23;
  color: #fff !important;
  text-decoration: none;
  font-weight: 600;
  font-size: 16px;
  padding: 0 28px;
  border-radius: 12px;
  white-space: nowrap;
  transition: background 150ms ease, transform 150ms ease;
  flex-shrink: 0;
}

.c360-hero__booking-btn:hover {
  background: #C92F1A;
  transform: translateY(-1px);
}

/* ── Custom dropdown (c360-hdd) ───────────────────────────────────────────── */
.c360-hdd {
  position: relative;
}

.c360-hdd__trigger {
  display: flex;
  align-items: center;
  gap: 6px;
  background: none;
  border: none;
  padding: 0;
  margin: 0;
  font-family: inherit;
  font-size: 15px;
  font-weight: 600;
  color: #0E1113;
  cursor: pointer;
  width: 100%;
  text-align: left;
  line-height: 1.3;
}

.c360-hdd__trigger:hover,
.c360-hdd__trigger:focus {
  background: none !important;
  color: #0E1113 !important;
}

.c360-hdd__trigger:focus-visible {
  outline: 2px solid #EC3D23;
  outline-offset: 2px;
  border-radius: 4px;
}

.c360-hdd__value {
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.c360-hdd__chevron {
  color: #9A8F7A;
  flex-shrink: 0;
  transition: transform 200ms ease;
}

.c360-hdd.is-open .c360-hdd__chevron {
  transform: rotate(180deg);
}

.c360-hdd__panel {
  display: none;
  position: absolute;
  top: calc(100% + 10px);
  left: -16px;
  min-width: 210px;
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 16px 48px -8px rgba(14, 17, 19, 0.22), 0 2px 8px rgba(14, 17, 19, 0.08);
  list-style: none;
  margin: 0;
  padding: 6px;
  z-index: 9999;
}

.c360-hdd.is-open .c360-hdd__panel {
  display: block;
  animation: hddFadeIn 160ms ease both;
}

@keyframes hddFadeIn {
  from { opacity: 0; transform: translateY(-6px); }
  to   { opacity: 1; transform: translateY(0); }
}

.c360-hdd__option {
  padding: 9px 12px;
  border-radius: 9px;
  font-size: 14px;
  font-weight: 500;
  color: #4A4A4A;
  cursor: pointer;
  transition: background 100ms, color 100ms;
  white-space: nowrap;
}

.c360-hdd__option:hover {
  background: #FAF7F6;
  color: #0E1113;
}

.c360-hdd__option.is-selected {
  background: #FEEEEA;
  color: #A12414;
  font-weight: 600;
}

.c360-hdd__option.is-selected::after {
  content: '✓';
  float: right;
  color: #EC3D23;
  font-size: 13px;
  margin-left: 12px;
}

/* button reset for submit */
.c360-hero__booking-btn {
  border: none;
  cursor: pointer;
}

.c360-hero__booking-btn:active {
  transform: translateY(0);
}

/* ── Stats row — constrained to text column width ───────────────────────────── */
.c360-hero__stats {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  margin-top: 32px;
  flex-wrap: nowrap;
  list-style: none;
  padding: 0;
  margin-left: 0;
  max-width: 52%;
}

.c360-hero__stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  flex: 1;
  text-align: center;
}

.c360-hero__stat-value {
  font-family: 'Space Grotesk', 'Sora', sans-serif;
  font-size: 26px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #fff;
  line-height: 1.1;
}

.c360-hero__stat-stars {
  font-size: 13px;
  color: #F5A623;
  letter-spacing: 2px;
  line-height: 1;
}

.c360-hero__stat-label {
  font-size: 13px;
  color: #9A958A;
}

/* vertical separator between stat cards */
.c360-hero__stat-sep {
  width: 1px;
  height: 40px;
  background: rgba(255, 255, 255, 0.15);
  flex-shrink: 0;
}

/* ── Mobile car overlay — hidden on desktop ─────────────────────────────────── */
.c360-hero__car-mobile {
  display: none;
}

/* ── Responsive ─────────────────────────────────────────────────────────────── */

/* Tablet */
@media (max-width: 1024px) {
  .c360-hero__car-wrap {
    width: 44%;
    opacity: 0.45;
  }

  .c360-hero__content,
  .c360-hero__booking,
  .c360-hero__stats {
    max-width: 58%;
  }
}

/* ── Mobile portrait (≤ 768px) ──────────────────────────────────────────────── */
@media (max-width: 768px) {
  .c360-hero {
    min-height: auto;
  }

  .c360-hero__inner {
    position: relative;
    padding: 52px 20px 48px;
    text-align: center;
    align-items: center;   /* center children horizontally */
  }

  /* hide desktop car, show mobile overlay */
  .c360-hero__car-wrap {
    display: none !important;
  }

  .c360-hero__car-mobile {
    display: block;
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 55%;
    pointer-events: none;
    z-index: 0;
    -webkit-mask-image: linear-gradient(to bottom, rgba(0,0,0,0.55) 0%, transparent 100%);
    mask-image: linear-gradient(to bottom, rgba(0,0,0,0.55) 0%, transparent 100%);
  }

  .c360-hero__car-mobile-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center top;
    display: block;
  }

  /* all inner content sits above the overlay */
  .c360-hero__content,
  .c360-hero__booking,
  .c360-hero__stats {
    position: relative;
    z-index: 1;
    max-width: 100%;
    width: 100%;
  }

  /* center badge */
  .c360-hero__badge {
    justify-content: center;
  }

  .c360-hero__headline {
    font-size: clamp(34px, 9vw, 50px);
  }

  .c360-hero__sub {
    font-size: 16px;
    max-width: 100%;
  }

  /* booking bar: stacked column on portrait mobile */
  .c360-hero__booking {
    flex-direction: column;
    gap: 2px;
    padding: 10px;
    margin-top: 28px;
    border-radius: 14px;
  }

  .c360-hero__booking-field {
    padding: 8px 12px;
    text-align: left;
  }

  .c360-hero__booking-value {
    white-space: normal;
    font-size: 15px;
  }

  .c360-hero__booking-divider {
    width: 100%;
    height: 1px;
    background: rgba(14, 17, 19, 0.08);
    align-self: auto;
  }

  .c360-hero__booking-btn {
    padding: 14px 20px;
    border-radius: 10px;
    font-size: 15px;
    justify-content: center;
    margin-top: 4px;
  }

  /* stats: flex row with separators */
  .c360-hero__stats {
    display: flex;
    flex-wrap: nowrap;
    justify-content: center;
    gap: 0;
    margin-top: 28px;
    max-width: 100%;
  }

  .c360-hero__stat {
    flex: 1;
    min-width: 0;
  }

  .c360-hero__stat-value {
    font-size: 20px;
  }

  .c360-hero__stat-label {
    font-size: 11px;
  }

  .c360-hero__stat-stars {
    font-size: 11px;
  }
}

/* ── Mobile landscape (phone rotated) ──────────────────────────────────────── */
@media (max-width: 768px) and (orientation: landscape) {
  .c360-hero {
    min-height: auto;
  }

  .c360-hero__inner {
    padding: 32px 24px 36px;
    text-align: left;
    align-items: flex-start;   /* back to left-aligned in landscape */
  }

  /* show desktop car layout at reduced opacity in landscape */
  .c360-hero__car-wrap {
    display: block !important;
    width: 45% !important;
    opacity: 0.5;
  }

  .c360-hero__car-mobile {
    display: none;
  }

  .c360-hero__content,
  .c360-hero__booking,
  .c360-hero__stats {
    max-width: 55%;
  }

  .c360-hero__badge {
    justify-content: flex-start;
  }

  .c360-hero__headline {
    font-size: clamp(26px, 5vw, 38px);
  }

  .c360-hero__sub {
    font-size: 14px;
  }

  /* booking bar back to row in landscape */
  .c360-hero__booking {
    flex-direction: row;
    gap: 0;
    padding: 8px;
    margin-top: 20px;
    border-radius: 12px;
  }

  .c360-hero__booking-field {
    padding: 6px 10px;
  }

  .c360-hero__booking-value {
    white-space: nowrap;
    font-size: 14px;
  }

  .c360-hero__booking-divider {
    width: 1px;
    height: auto;
    background: rgba(14, 17, 19, 0.10);
    align-self: stretch;
  }

  .c360-hero__booking-btn {
    padding: 0 16px;
    font-size: 14px;
    margin-top: 0;
  }

  .c360-hero__stats {
    margin-top: 20px;
    max-width: 55%;
  }

  .c360-hero__stat-value {
    font-size: 18px;
  }
}
