@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@400;500;600;700&family=Source+Serif+4:opsz,wght@8..60,600;8..60,700&display=swap');

:root, [data-theme="light"] {
  --bg: #f1f5f9;
  --bg-2: #ffffff;
  --surface: #ffffff;
  --line: rgba(15, 42, 68, .10);
  --gold: #0f2a44;
  --gold-2: #1e3a8a;
  --accent: #0f2a44;
  --teal: #2563eb;
  --text: #334155;
  --muted: #64748b;
  --danger: #b42318;
  --ok: #157347;
  --shadow: 0 8px 40px rgba(15, 42, 68, .08);
  --radius: 16px;
  --input-bg: #ffffff;
  --header-bg: rgba(255, 255, 255, .97);
  --mark-fg: #ffffff;
}

[data-theme="dark"] {
  --bg: #0b1220;
  --bg-2: #111827;
  --surface: #1a2332;
  --line: rgba(255, 255, 255, .08);
  --gold: #60a5fa;
  --gold-2: #93c5fd;
  --accent: #60a5fa;
  --teal: #60a5fa;
  --text: #e2e8f0;
  --muted: #94a3b8;
  --danger: #f87171;
  --ok: #34d399;
  --shadow: 0 8px 40px rgba(0, 0, 0, .35);
  --radius: 16px;
  --input-bg: #111827;
  --header-bg: rgba(11, 18, 32, .95);
  --mark-fg: #0b1220;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: 'Manrope', system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  line-height: 1.55;
}
a { color: var(--gold-2); text-decoration: none; }
a:hover { color: var(--gold); }
img { max-width: 100%; }
h1,h2,h3,h4 { font-family: 'Source Serif 4', Georgia, serif; font-weight: 600; letter-spacing: -.02em; margin: 0 0 .45em; }

.wrap { width: min(1180px, calc(100% - 40px)); margin: 0 auto; }
.topbar {
  position: sticky; top: 0; z-index: 40;
  backdrop-filter: blur(18px);
  background: var(--header-bg);
  border-bottom: 1px solid var(--line);
}
.topbar-inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 16px 0; }
.brand { display: flex; align-items: center; gap: 12px; color: var(--text); }
.brand-mark {
  width: 42px; height: 42px; border-radius: 12px;
  background: var(--accent);
  display: grid; place-items: center; font-family: 'Source Serif 4', serif; font-weight: 700; color: var(--mark-fg);
  box-shadow: none;
}
.brand small { display: block; color: var(--muted); font-size: 11px; letter-spacing: .18em; text-transform: uppercase; }
nav.main { display: flex; gap: 22px; align-items: center; flex-wrap: wrap; }
nav.main a { color: var(--muted); font-weight: 600; font-size: 14px; }
nav.main a:hover, nav.main a.active { color: var(--text); }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border: 1px solid transparent; border-radius: 999px; padding: 11px 20px;
  font-weight: 700; cursor: pointer; font-family: inherit;
}
.btn-gold { background: var(--accent); color: #fff; }
.btn-gold:hover { color: #fff; filter: brightness(1.08); }
.btn-ghost { border-color: var(--line); color: var(--text); background: transparent; }
.btn-teal { background: rgba(37,99,235,.10); color: var(--teal); border-color: rgba(37,99,235,.28); }
.btn-danger { background: rgba(180,35,24,.10); color: var(--danger); border: 1px solid rgba(180,35,24,.28); }
.theme-toggle {
  width: 42px; height: 42px; border-radius: 12px; border: 1px solid var(--line);
  background: var(--surface); color: var(--text); cursor: pointer; font: inherit;
}

.hero { padding: 72px 0 36px; }
.kicker { color: var(--gold); letter-spacing: .22em; text-transform: uppercase; font-size: 12px; font-weight: 700; }
.hero h1 { font-size: clamp(36px, 6vw, 72px); line-height: 1.05; max-width: 16ch; }
.hero p.lead { max-width: 62ch; color: var(--muted); font-size: 18px; }
.search-card {
  margin-top: 32px; background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 18px; box-shadow: var(--shadow);
  display: grid; grid-template-columns: 1.4fr 1fr auto; gap: 12px;
}
input, select, textarea {
  width: 100%; background: var(--input-bg); border: 1px solid var(--line); color: var(--text);
  border-radius: 12px; padding: 13px 14px; font: inherit;
}
textarea { min-height: 120px; resize: vertical; }
label { display: block; font-size: 13px; color: var(--muted); margin-bottom: 6px; font-weight: 600; }

.grid { display: grid; gap: 20px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 22px; box-shadow: var(--shadow);
}
.listing-card { overflow: hidden; padding: 0; }
.listing-card .thumb {
  height: 160px; background:
    linear-gradient(160deg, rgba(201,164,108,.25), rgba(125,211,199,.08)),
    #121722;
  display: grid; place-items: center; font-size: 42px;
}
.listing-card .thumb img { max-height: 140px; max-width: 90%; object-fit: contain; }
.listing-card .body { padding: 18px 20px 22px; }
.badge {
  display: inline-flex; align-items: center; gap: 6px; font-size: 11px; font-weight: 800;
  letter-spacing: .08em; text-transform: uppercase; padding: 5px 10px; border-radius: 999px;
  border: 1px solid var(--line); color: var(--gold);
}
.badge.orbit { color: var(--teal); }
.badge.quantum { color: var(--gold-2); }
.muted { color: var(--muted); }
.stars { color: var(--gold); letter-spacing: 2px; }

.section { padding: 48px 0; }
.section-title { display: flex; justify-content: space-between; align-items: end; margin-bottom: 22px; gap: 16px; }

.flash { border-radius: 14px; padding: 12px 16px; margin: 12px 0; }
.flash-success { background: rgba(125,190,138,.12); color: var(--ok); }
.flash-error { background: rgba(224,122,108,.12); color: var(--danger); }

.footer { margin-top: 80px; border-top: 1px solid var(--line); padding: 40px 0 28px; color: var(--muted); }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 28px; }
.cookie {
  position: fixed; bottom: 18px; left: 50%; transform: translateX(-50%); width: min(720px, calc(100% - 24px));
  background: #12151e; border: 1px solid var(--line); border-radius: 18px; padding: 16px 18px; z-index: 50;
  box-shadow: var(--shadow);
}

.layout-app { display: grid; grid-template-columns: 280px 1fr; min-height: 100vh; }
.sidebar {
  background: #0b1220; border-right: 1px solid rgba(255,255,255,.08); padding: 22px 18px;
  position: sticky; top: 0; height: 100vh; overflow: auto;
}
.sidebar a, .sidebar button {
  display: block; width: 100%; text-align: left; color: var(--muted); padding: 10px 12px; border-radius: 12px;
  background: none; border: 1px solid transparent; font: inherit; cursor: pointer;
}
.sidebar a:hover, .sidebar a.active { background: rgba(201,164,108,.1); color: var(--text); border-color: var(--line); }
.sidebar h6 { color: #60a5fa; letter-spacing: .16em; text-transform: uppercase; font-size: 11px; margin: 18px 8px 8px; }
.mainpad { padding: 28px 32px 60px; }
.table { width: 100%; border-collapse: collapse; }
.table th, .table td { padding: 12px 10px; border-bottom: 1px solid var(--line); text-align: left; font-size: 14px; }
.table th { color: var(--muted); font-weight: 700; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; }
.stat { padding: 18px; }
.stat b { display: block; font-size: 28px; font-family: 'Source Serif 4', serif; }

.package { position: relative; }
.package.featured { border-color: var(--gold); box-shadow: 0 0 0 1px var(--gold), var(--shadow); }
.price { font-size: 38px; font-family: 'Source Serif 4', serif; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.form-grid .full { grid-column: 1 / -1; }
.listing-hero { display: grid; grid-template-columns: 1.4fr .8fr; gap: 24px; }
.map { height: 220px; border-radius: 18px; overflow: hidden; border: 1px solid var(--line); background: #10151f; }

.wrap-narrow { width: min(1000px, calc(100% - 40px)); margin-left: auto; margin-right: auto; }
.map-fullscreen { width: 100%; }
.map-fullscreen iframe, .video-frame iframe { width: 100%; height: 400px; border: 0; display: block; }
.video-frame { border-radius: 12px; overflow: hidden; }
.listing-video { width: 100%; border-radius: 12px; }
.business-header { padding: 28px 0 8px; }
.business-header-inner { width: min(1000px, calc(100% - 40px)); margin: 0 auto; display: flex; justify-content: space-between; gap: 24px; align-items: flex-start; }
.business-left { display: flex; flex-direction: column; gap: 8px; }
.business-logo { max-width: 250px; height: auto; border-radius: 10px; margin-bottom: 12px; background: #fff; padding: 8px; }
.business-name-wrapper { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.business-name { font-size: clamp(28px, 4vw, 42px); margin: 0; }
.entry-id { font-size: 13px; color: var(--teal); background: rgba(125,211,199,.1); padding: 4px 10px; border-radius: 8px; }
.star-form { display: inline; }
.business-rating { display: flex; align-items: center; gap: 10px; color: var(--text); }
.rating-value { font-size: 22px; font-family: 'Source Serif 4', serif; color: var(--accent); }
.business-status { font-weight: 700; padding: 10px 16px; border-radius: 10px; white-space: nowrap; }
.status-open { background: rgba(125,190,138,.18); color: var(--ok); }
.status-closed { background: rgba(224,122,108,.16); color: var(--danger); }
.status-neutral { background: rgba(255,255,255,.06); color: var(--muted); }
.business-address-wrapper { width: min(1000px, calc(100% - 40px)); margin: 0 auto 8px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.business-address-line { display: flex; gap: 8px; color: var(--muted); }
.business-actions { width: min(1000px, calc(100% - 40px)); margin: 16px auto 28px; display: flex; flex-wrap: wrap; gap: 10px; }
.galactic-gallery-box, .galactic-admin-box, .galactic-hours-box, .galactic-description-box, .galactic-review-box {
  margin: 28px auto; padding: 28px; background: linear-gradient(160deg, #12151c, #0d1118); border: 1px solid var(--line);
  border-radius: 18px; box-shadow: var(--shadow); position: relative;
}
.gallery-floating-label { position: absolute; top: -12px; left: 22px; background: #12151c; color: var(--teal); padding: 4px 12px; border-radius: 8px; font-weight: 800; font-size: 13px; letter-spacing: .08em; text-transform: uppercase; }
.gallery-scroll { display: flex; gap: 12px; overflow-x: auto; padding: 8px 0 4px; }
.gallery-item { flex: 0 0 auto; border-radius: 10px; overflow: hidden; border: 1px solid var(--line); }
.gallery-item img { display: block; height: 140px; width: auto; }
.admin-title, .hours-title, .description-title, .review-title { color: var(--teal); font-size: 22px; }
.admin-info-list { list-style: none; padding: 0; margin: 0; }
.admin-info-list li { padding: 10px 0; border-bottom: 1px solid var(--line); display: flex; gap: 10px; align-items: center; }
.glow-hr { border: 0; height: 2px; margin: 22px 0; background: linear-gradient(to right, var(--teal), var(--gold)); }
.admin-social-icons { display: flex; gap: 14px; justify-content: center; }
.social-icon { color: var(--teal); font-weight: 700; }
.hours-toggle { border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.hours-toggle summary { cursor: pointer; padding: 12px 16px; font-weight: 700; color: var(--teal); }
.hours-table { width: 100%; border-collapse: collapse; }
.hours-table td { padding: 10px 16px; border-top: 1px solid var(--line); }
.description-text { line-height: 1.7; color: #e8e4da; }
.description-text p { margin: 0 0 12px; }
.review-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 22px; }
.review-card { background: #0b0e15; border: 1px solid var(--line); border-radius: 14px; padding: 16px; }
.review-form, .report-box form { margin-top: 18px; }
.entry-footer-meta { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; align-items: center; padding: 18px 0 40px; color: var(--muted); font-size: 14px; }
.keyword { color: var(--teal); margin-left: 8px; }
.lightbox-overlay { position: fixed; inset: 0; background: rgba(0,0,0,.86); display: none; align-items: center; justify-content: center; z-index: 80; padding: 24px; }
.lightbox-overlay.open { display: flex; }
.lightbox-overlay img { max-width: min(90vw, 1100px); max-height: 85vh; border-radius: 12px; }

@media (max-width: 960px) {
  .search-card, .grid-3, .grid-4, .grid-2, .listing-hero, .form-grid, .footer-grid, .layout-app, .business-header-inner, .review-grid {
    grid-template-columns: 1fr;
  }
  .business-header-inner { flex-direction: column; }
  .sidebar { position: relative; height: auto; }
  nav.main { display: none; }
  .map-fullscreen iframe { height: 240px; }
}
