:root {
  --bg: #f8fafc;
  --surface: #ffffff;
  --surface-muted: #f1f5f9;
  --text: #0f172a;
  --text-muted: #475569;
  --border: #e2e8f0;
  --primary: #0f4c81;
  --primary-hover: #0a365c;
  --accent: #0ea5e9;
  --accent-soft: #e0f2fe;
  --gold: #d97706;
  --gold-soft: #fef3c7;
  --success: #059669;
  --success-soft: #d1fae5;
  --danger: #dc2626;
  --danger-soft: #fee2e2;
  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --shadow-sm: 0 1px 3px rgba(15, 23, 42, 0.06), 0 1px 2px rgba(15, 23, 42, 0.04);
  --shadow-md: 0 10px 25px -5px rgba(15, 23, 42, 0.08), 0 4px 10px -4px rgba(15, 23, 42, 0.04);
  --shadow-lg: 0 24px 48px -12px rgba(15, 23, 42, 0.18);
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: 'Plus Jakarta Sans', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

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

button, input, select, textarea {
  font: inherit;
}

a {
  color: inherit;
  text-decoration: none;
}

.visually-hidden:where(:not(:focus-within, :active)) {
  position: absolute !important;
  clip-path: inset(50%) !important;
  overflow: hidden !important;
  width: 1px !important;
  height: 1px !important;
  margin: -1px !important;
  padding: 0 !important;
  border: 0 !important;
  white-space: nowrap !important;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
}

.header-inner {
  max-width: 1320px;
  margin: 0 auto;
  padding: 14px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand-mark {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: linear-gradient(135deg, #0f4c81 0%, #0ea5e9 100%);
  color: #fff;
  display: grid;
  place-items: center;
  font-weight: 800;
  font-size: 1.1rem;
  letter-spacing: -0.02em;
  box-shadow: 0 6px 14px rgba(15, 76, 129, 0.25);
}

.brand-text strong {
  display: block;
  font-size: 1.05rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text);
}

.brand-text span {
  display: block;
  font-size: 0.74rem;
  color: var(--text-muted);
  font-weight: 500;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: 999px;
  border: 1px solid transparent;
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  transition: transform 0.15s ease, background 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
  white-space: nowrap;
}

.btn:active {
  transform: scale(0.98);
}

.btn-primary {
  background: var(--primary);
  color: #fff;
  box-shadow: 0 4px 12px rgba(15, 76, 129, 0.22);
}

.btn-primary:hover {
  background: var(--primary-hover);
}

.btn-accent {
  background: linear-gradient(135deg, #0ea5e9 0%, #0284c7 100%);
  color: #fff;
}

.btn-accent:hover {
  filter: brightness(1.05);
}

.btn-outline {
  background: #fff;
  color: var(--text);
  border-color: var(--border);
}

.btn-outline:hover {
  background: var(--surface-muted);
  border-color: #cbd5e1;
}

.btn-ghost {
  background: transparent;
  color: var(--text-muted);
}

.btn-ghost:hover {
  background: var(--surface-muted);
  color: var(--text);
}

.btn-whatsapp {
  background: #16a34a;
  color: #fff;
}

.btn-whatsapp:hover {
  background: #15803d;
}

.btn-sm {
  padding: 7px 14px;
  font-size: 0.82rem;
}

/* Hero Section */
.hero {
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, #092540 0%, #0f4c81 55%, #0369a1 100%);
  color: #fff;
  padding: 56px 24px 68px;
}

.hero-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.18;
  pointer-events: none;
}

.hero-inner {
  position: relative;
  z-index: 1;
  max-width: 1180px;
  margin: 0 auto;
}

.hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.24);
  padding: 6px 14px;
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 600;
  margin-bottom: 16px;
}

.hero h1 {
  margin: 0 0 12px;
  font-size: clamp(1.9rem, 4vw, 3.1rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.12;
  max-width: 780px;
}

.hero p.hero-sub {
  margin: 0 0 28px;
  font-size: 1.05rem;
  color: rgba(255, 255, 255, 0.88);
  max-width: 680px;
}

/* Booking-style Floating Search Bar */
.search-bar {
  background: #fff;
  color: var(--text);
  border-radius: 20px;
  padding: 10px;
  box-shadow: var(--shadow-lg);
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr 1fr auto;
  gap: 8px;
  align-items: center;
}

.search-field {
  padding: 8px 14px;
  border-radius: 12px;
  transition: background 0.15s ease;
  border-right: 1px solid var(--border);
}

.search-field:last-of-type {
  border-right: none;
}

.search-field:focus-within {
  background: #f8fafc;
}

.search-field label {
  display: block;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-weight: 700;
  color: var(--text-muted);
  margin-bottom: 3px;
}

.search-field input,
.search-field select {
  width: 100%;
  border: none;
  outline: none;
  background: transparent;
  color: var(--text);
  font-size: 0.94rem;
  font-weight: 600;
}

.search-submit {
  height: 54px;
  padding: 0 26px;
  border-radius: 14px;
  font-size: 0.96rem;
}

.quick-cities {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 18px;
}

.quick-cities span {
  font-size: 0.82rem;
  color: rgba(255, 255, 255, 0.8);
  font-weight: 600;
}

.city-pill {
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: #fff;
  padding: 5px 13px;
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s ease;
}

.city-pill:hover,
.city-pill.active {
  background: #fff;
  color: var(--primary);
}

/* Filter Toolbar */
.container {
  max-width: 1320px;
  margin: 0 auto;
  padding: 28px 24px 64px;
}

.toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 22px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--border);
}

.amenity-chips {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border-radius: 999px;
  background: #fff;
  border: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 0.84rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
}

.chip:hover {
  border-color: var(--accent);
  color: var(--primary);
}

.chip.active {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
}

.view-controls {
  display: flex;
  align-items: center;
  gap: 10px;
}

.results-meta {
  font-size: 0.9rem;
  color: var(--text-muted);
  font-weight: 600;
}

/* Main Split Layout (Catalog + Map) */
.catalog-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  align-items: start;
}

.catalog-layout.with-map {
  grid-template-columns: minmax(0, 1.35fr) minmax(340px, 0.85fr);
}

.venues-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(310px, 1fr));
  gap: 22px;
}

.map-panel {
  position: sticky;
  top: 86px;
  height: calc(100vh - 110px);
  min-height: 480px;
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-md);
  background: #e2e8f0;
  display: none;
}

.catalog-layout.with-map .map-panel {
  display: block;
}

#venuesMap {
  width: 100%;
  height: 100%;
}

/* Venue Card */
.venue-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.venue-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: #cbd5e1;
}

.venue-card.tier-featured {
  border-color: rgba(217, 119, 6, 0.45);
  box-shadow: 0 8px 24px -8px rgba(217, 119, 6, 0.2);
}

.card-media {
  position: relative;
  aspect-ratio: 16 / 10;
  background: #e2e8f0;
  overflow: hidden;
  cursor: pointer;
}

.card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease;
}

.venue-card:hover .card-media img {
  transform: scale(1.04);
}

.card-badges {
  position: absolute;
  top: 12px;
  left: 12px;
  right: 12px;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 8px;
  pointer-events: none;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 5px 10px;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 700;
  backdrop-filter: blur(8px);
}

.badge-featured {
  background: rgba(217, 119, 6, 0.95);
  color: #fff;
}

.badge-verified {
  background: rgba(15, 76, 129, 0.92);
  color: #fff;
}

.badge-free {
  background: rgba(15, 23, 42, 0.72);
  color: #fff;
}

.badge-rating {
  background: rgba(255, 255, 255, 0.95);
  color: var(--text);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}

.badge-rating .star {
  color: #f59e0b;
}

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

.card-location {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 0.8rem;
  color: var(--primary);
  font-weight: 700;
}

.card-type {
  font-size: 0.74rem;
  color: var(--text-muted);
  font-weight: 600;
}

.card-title {
  margin: 0;
  font-size: 1.08rem;
  font-weight: 800;
  line-height: 1.28;
  cursor: pointer;
}

.card-title:hover {
  color: var(--primary);
}

.card-tagline {
  margin: 0;
  font-size: 0.85rem;
  color: var(--text-muted);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-specs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 2px;
}

.spec-pill {
  font-size: 0.75rem;
  font-weight: 600;
  padding: 4px 9px;
  border-radius: 8px;
  background: var(--surface-muted);
  color: #334155;
}

.spec-pill.highlight {
  background: var(--accent-soft);
  color: #0369a1;
}

.card-footer {
  margin-top: auto;
  padding-top: 12px;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.price-box strong {
  display: block;
  font-size: 0.9rem;
  color: var(--text);
}

.price-box span {
  font-size: 0.75rem;
  color: var(--success);
  font-weight: 600;
}

.price-box span.busy {
  color: var(--danger);
}

.card-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}

/* Compare Bar */
.compare-bar {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 45;
  background: #0f172a;
  color: #fff;
  padding: 12px 20px;
  border-radius: 999px;
  box-shadow: var(--shadow-lg);
  display: none;
  align-items: center;
  gap: 16px;
}

.compare-bar.visible {
  display: flex;
}

/* Plans / Monetization Banner */
.plans-section {
  background: #fff;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 64px 24px;
}

.plans-inner {
  max-width: 1180px;
  margin: 0 auto;
}

.section-header {
  text-align: center;
  max-width: 720px;
  margin: 0 auto 40px;
}

.section-header h2 {
  margin: 0 0 10px;
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  font-weight: 800;
  letter-spacing: -0.02em;
}

.section-header p {
  margin: 0;
  color: var(--text-muted);
}

.plans-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}

.plan-card {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
  background: var(--bg);
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.plan-card.popular {
  background: #fff;
  border: 2px solid var(--primary);
  box-shadow: var(--shadow-md);
  position: relative;
}

.plan-tag {
  display: inline-block;
  align-self: flex-start;
  padding: 4px 12px;
  border-radius: 999px;
  font-size: 0.74rem;
  font-weight: 700;
  background: var(--accent-soft);
  color: var(--primary);
}

.plan-price {
  font-size: 1.9rem;
  font-weight: 800;
  letter-spacing: -0.03em;
}

.plan-price small {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-muted);
}

.plan-features {
  list-style: none;
  padding: 0;
  margin: 8px 0 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  font-size: 0.9rem;
  color: #334155;
}

/* Native Dialog Modals (Modern Web Guidance compliant) */
dialog {
  border: none;
  padding: 0;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  max-width: 960px;
  width: calc(100% - 28px);
  max-height: 90vh;
  background: #fff;
  color: var(--text);
}

dialog.dialog-sm {
  max-width: 560px;
}

dialog:modal {
  overscroll-behavior: contain;
}

dialog::backdrop {
  background: rgba(15, 23, 42, 0.62);
  backdrop-filter: blur(4px);
  overflow: hidden;
  overscroll-behavior: contain;
}

.modal-header {
  position: sticky;
  top: 0;
  z-index: 5;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(10px);
  padding: 18px 24px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.modal-header h2 {
  margin: 0;
  font-size: 1.25rem;
  font-weight: 800;
}

.modal-close {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: #fff;
  color: var(--text);
  font-size: 1.2rem;
  cursor: pointer;
  display: grid;
  place-items: center;
}

.modal-close:hover {
  background: var(--surface-muted);
}

.modal-body {
  padding: 24px;
}

/* Venue Detail inside Dialog */
.gallery-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 10px;
  margin-bottom: 22px;
}

.gallery-main {
  border-radius: var(--radius-md);
  overflow: hidden;
  aspect-ratio: 16 / 10;
  background: #e2e8f0;
}

.gallery-main img,
.gallery-thumbs img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.gallery-thumbs {
  display: grid;
  gap: 10px;
  grid-template-rows: repeat(2, 1fr);
}

.gallery-thumb {
  border-radius: var(--radius-sm);
  overflow: hidden;
  cursor: pointer;
  background: #e2e8f0;
}

.detail-grid {
  display: grid;
  grid-template-columns: 1.35fr 0.95fr;
  gap: 24px;
}

.capacity-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(105px, 1fr));
  gap: 10px;
  margin: 14px 0 22px;
}

.cap-box {
  background: var(--surface-muted);
  border-radius: 12px;
  padding: 12px 10px;
  text-align: center;
}

.cap-box strong {
  display: block;
  font-size: 1.15rem;
  color: var(--primary);
}

.cap-box span {
  font-size: 0.74rem;
  color: var(--text-muted);
  font-weight: 600;
}

.tech-list {
  display: grid;
  gap: 12px;
  margin-bottom: 22px;
}

.tech-item {
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 12px 14px;
  display: flex;
  gap: 12px;
  align-items: flex-start;
}

.tech-item strong {
  display: block;
  font-size: 0.9rem;
}

.tech-item p {
  margin: 2px 0 0;
  font-size: 0.84rem;
  color: var(--text-muted);
}

.review-card {
  background: var(--surface-muted);
  border-radius: 12px;
  padding: 12px 14px;
  margin-bottom: 10px;
  font-size: 0.85rem;
}

.quote-box {
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 20px;
  background: #f8fafc;
  position: sticky;
  top: 84px;
}

/* Forms & Modern Validation */
.form-grid {
  display: grid;
  gap: 14px;
}

.form-row-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.field label {
  display: block;
  font-size: 0.82rem;
  font-weight: 700;
  margin-bottom: 4px;
  color: #334155;
}

.field .hint {
  display: block;
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-bottom: 4px;
}

.field input:not([type="checkbox"]),
.field select,
.field textarea {
  width: 100%;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid #cbd5e1;
  background: #fff;
  color: var(--text);
  font-size: 0.9rem;
  outline: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.16);
}

.error-msg {
  display: none;
  color: var(--danger);
  font-size: 0.78rem;
  font-weight: 600;
  margin-top: 4px;
}

:is(input:user-invalid, select:user-invalid, textarea:user-invalid, .user-invalid-fallback) {
  border-color: var(--danger) !important;
  background-color: #fef2f2 !important;
}

:is(input:user-invalid, select:user-invalid, textarea:user-invalid, .user-invalid-fallback) + .error-msg {
  display: block;
}

input:user-valid {
  border-color: var(--success);
}

.checkbox-card {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
  padding: 12px;
  border-radius: 12px;
  font-size: 0.83rem;
  color: #065f46;
  cursor: pointer;
}

.checkbox-card input {
  margin-top: 3px;
  accent-color: #059669;
}

/* Compare Table */
.compare-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
}

.compare-table th,
.compare-table td {
  padding: 12px;
  border-bottom: 1px solid var(--border);
  text-align: left;
  vertical-align: top;
}

.compare-table th {
  background: var(--surface-muted);
  font-weight: 700;
  width: 180px;
}

/* Footer */
.site-footer {
  background: #0f172a;
  color: #cbd5e1;
  padding: 40px 24px;
}

.footer-inner {
  max-width: 1320px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  font-size: 0.86rem;
}

.empty-state {
  grid-column: 1 / -1;
  text-align: center;
  padding: 56px 24px;
  background: #fff;
  border: 1px dashed #cbd5e1;
  border-radius: var(--radius-md);
}

@media (max-width: 980px) {
  .search-bar {
    grid-template-columns: 1fr 1fr;
  }
  .search-field {
    border-right: none;
    border-bottom: 1px solid var(--border);
  }
  .search-submit {
    grid-column: 1 / -1;
  }
  .catalog-layout.with-map {
    grid-template-columns: 1fr;
  }
  .map-panel {
    position: relative;
    top: 0;
    height: 360px;
    order: -1;
  }
  .detail-grid,
  .gallery-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 600px) {
  .search-bar {
    grid-template-columns: 1fr;
  }
  .form-row-2 {
    grid-template-columns: 1fr;
  }
  .header-inner {
    padding: 12px 16px;
  }
}
