:root {
  --bg: #06070d;
  --bg2: #0a0e1a;
  --cyan: #4deaff;
  --purple: #a06bff;
  --pink: #ff6bd6;
  --text: #eef1ff;
  --muted: #8b93b5;
  --glass: rgba(255, 255, 255, 0.05);
  --glass-border: rgba(255, 255, 255, 0.12);
  --danger: #ff5c7a;
  --ok: #45f0b0;
  font-family: 'Inter', sans-serif;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
}

body { position: relative; overflow-x: hidden; }

h1, h2, h3 { font-family: 'Sora', sans-serif; margin: 0 0 0.4em; }

.hidden { display: none !important; }

.bg-glow {
  position: fixed;
  inset: -20%;
  z-index: -2;
  background:
    radial-gradient(40% 35% at 20% 15%, rgba(77, 234, 255, 0.18), transparent 60%),
    radial-gradient(45% 40% at 85% 20%, rgba(160, 107, 255, 0.20), transparent 60%),
    radial-gradient(50% 45% at 50% 90%, rgba(255, 107, 214, 0.14), transparent 60%);
  animation: drift 18s ease-in-out infinite alternate;
}

@keyframes drift {
  0% { transform: translate3d(0,0,0) scale(1); }
  100% { transform: translate3d(2%, -2%, 0) scale(1.05); }
}

.bg-grid {
  position: fixed;
  inset: 0;
  z-index: -1;
  background-image:
    linear-gradient(rgba(255,255,255,0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.035) 1px, transparent 1px);
  background-size: 42px 42px;
  mask-image: radial-gradient(ellipse 80% 60% at 50% 20%, #000 40%, transparent 90%);
}

.accent {
  background: linear-gradient(90deg, var(--cyan), var(--purple), var(--pink));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.glass {
  background: var(--glass);
  border: 1px solid var(--glass-border);
  border-radius: 18px;
  backdrop-filter: blur(16px);
  box-shadow: 0 8px 40px rgba(0,0,0,0.35);
}

/* Top nav */
.topnav {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
  padding: 14px 32px;
  background: rgba(6,7,13,0.7);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--glass-border);
}

@media (max-width: 520px) {
  .topnav { padding: 12px 16px; }
  .nav-user { font-size: 0.8rem; gap: 8px; }
}

.brand { display: flex; align-items: center; gap: 8px; font-family: 'Sora', sans-serif; font-weight: 700; font-size: 1.15rem; }
.brand-mark { color: var(--cyan); text-shadow: 0 0 12px var(--cyan); }

.nav-links { display: flex; gap: 8px; }
.nav-link {
  background: transparent; border: 1px solid transparent; color: var(--muted);
  padding: 8px 14px; border-radius: 10px; cursor: pointer; font-size: 0.92rem; font-weight: 500;
}
.nav-link:hover { color: var(--text); border-color: var(--glass-border); }
.nav-link.active { color: var(--text); background: var(--glass); border-color: var(--glass-border); }

.nav-user { display: flex; align-items: center; gap: 14px; color: var(--muted); font-size: 0.9rem; }

/* Buttons & inputs */
.btn {
  font-family: 'Inter', sans-serif;
  font-weight: 600;
  border-radius: 10px;
  padding: 10px 18px;
  border: 1px solid transparent;
  cursor: pointer;
  font-size: 0.92rem;
  white-space: nowrap;
  transition: transform 0.12s ease, box-shadow 0.12s ease;
}
.btn:active { transform: translateY(1px); }
.btn-primary {
  background: linear-gradient(90deg, var(--cyan), var(--purple));
  color: #06070d;
  box-shadow: 0 0 24px rgba(77,234,255,0.25);
}
.btn-primary:hover { box-shadow: 0 0 32px rgba(160,107,255,0.4); }
.btn-secondary { background: var(--glass); color: var(--text); border-color: var(--glass-border); }
.btn-secondary:hover { border-color: var(--cyan); }
.btn-ghost { background: transparent; color: var(--muted); border-color: var(--glass-border); }
.btn-ghost:hover { color: var(--text); }
.btn-danger { background: rgba(255,92,122,0.15); color: var(--danger); border-color: rgba(255,92,122,0.4); }

input, select {
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--glass-border);
  color: var(--text);
  padding: 10px 14px;
  border-radius: 10px;
  font-family: 'Inter', sans-serif;
  font-size: 0.92rem;
  flex: 1;
}
input:focus, select:focus { outline: none; border-color: var(--cyan); box-shadow: 0 0 0 3px rgba(77,234,255,0.15); }
input[type="date"] { flex: none; width: auto; color-scheme: dark; }

.row-inline { display: flex; gap: 10px; margin-bottom: 12px; width: 100%; }

/* Layout */
main { max-width: 1080px; margin: 0 auto; padding: 40px 24px 80px; }
.view { animation: fadein 0.4s ease; }
@keyframes fadein { from { opacity: 0; transform: translateY(6px);} to { opacity: 1; transform: translateY(0);} }

.view-landing .hero { text-align: center; padding: 60px 0 20px; }
.eyebrow {
  text-transform: uppercase; letter-spacing: 0.16em; font-size: 0.78rem;
  color: var(--cyan); font-weight: 600; margin-bottom: 18px;
}
.hero h1 { font-size: clamp(2.2rem, 5vw, 3.6rem); line-height: 1.15; font-weight: 800; }
.hero-sub { color: var(--muted); max-width: 620px; margin: 20px auto 34px; font-size: 1.05rem; line-height: 1.6; }

.signin-box { max-width: 380px; margin: 0 auto 60px; padding: 28px; }
#google-btn-slot { display: flex; justify-content: center; }
.dev-login { display: flex; flex-direction: column; gap: 10px; }
.dev-note { color: var(--muted); font-size: 0.82rem; margin: 0 0 6px; }

.feature-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 18px; text-align: left; margin-top: 20px; }
.feature { padding: 24px; }
.feature-icon { font-size: 1.6rem; margin-bottom: 10px; }
.feature h3 { font-size: 1.05rem; }
.feature p { color: var(--muted); font-size: 0.9rem; line-height: 1.5; margin: 0; }

.center-card { max-width: 460px; margin: 100px auto; padding: 40px; text-align: center; }
.pulse-orb {
  width: 60px; height: 60px; margin: 0 auto 20px; border-radius: 50%;
  background: radial-gradient(circle, var(--cyan), var(--purple));
  box-shadow: 0 0 40px rgba(77,234,255,0.5);
  animation: pulse 1.8s ease-in-out infinite;
}
@keyframes pulse { 0%,100% { transform: scale(1); opacity: 1;} 50% { transform: scale(1.15); opacity: 0.7;} }

.page-head { margin-bottom: 24px; }
.page-head p { color: var(--muted); margin: 4px 0 0; }

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-bottom: 20px; }
@media (max-width: 800px) { .grid-2 { grid-template-columns: 1fr; } }

.panel { padding: 24px; margin-bottom: 20px; }
.panel h3 { font-size: 1.05rem; }

.list { display: flex; flex-direction: column; gap: 10px; margin-top: 14px; }
.list-item {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 12px 14px; border-radius: 12px; background: rgba(255,255,255,0.03);
  border: 1px solid var(--glass-border); flex-wrap: wrap;
}
.list-item .meta { display: flex; flex-direction: column; gap: 2px; }
.list-item .meta strong { font-size: 0.95rem; }
.list-item .meta span { color: var(--muted); font-size: 0.8rem; }
.tag {
  font-size: 0.72rem; font-weight: 600; padding: 3px 9px; border-radius: 999px;
  background: rgba(77,234,255,0.12); color: var(--cyan); border: 1px solid rgba(77,234,255,0.3);
  text-transform: uppercase; letter-spacing: 0.04em;
}
.tag.role-super_admin { background: rgba(255,107,214,0.12); color: var(--pink); border-color: rgba(255,107,214,0.3); }
.tag.role-org_admin { background: rgba(160,107,255,0.12); color: var(--purple); border-color: rgba(160,107,255,0.3); }
.tag.status-pending { background: rgba(255,196,77,0.12); color: #ffc44d; border-color: rgba(255,196,77,0.3); }
.tag.status-active { background: rgba(69,240,176,0.12); color: var(--ok); border-color: rgba(69,240,176,0.3); }

.list-item-controls { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.list-item-controls select { flex: none; width: auto; padding: 6px 10px; font-size: 0.82rem; }

.muted { color: var(--muted); font-size: 0.85rem; }
.small { font-size: 0.78rem; font-weight: 400; }

.grid-scroll { overflow-x: auto; }
table.price-grid { border-collapse: collapse; width: 100%; min-width: 720px; }
table.price-grid th, table.price-grid td {
  padding: 8px 10px; text-align: center; font-size: 0.82rem; border-bottom: 1px solid var(--glass-border);
  white-space: nowrap;
}
table.price-grid th { color: var(--muted); font-weight: 600; text-align: left; }
table.price-grid td.hotel-name { text-align: left; font-weight: 600; }
table.price-grid td.price-cell { font-variant-numeric: tabular-nums; }
table.price-grid td.price-cell.weekend { color: var(--pink); }
table.price-grid td.no-data { color: var(--muted); }

.history-table { width: 100%; border-collapse: collapse; margin-top: 8px; }
.history-table th, .history-table td { padding: 8px 10px; border-bottom: 1px solid var(--glass-border); font-size: 0.85rem; text-align: left; }

.history-group { margin-bottom: 24px; }
.history-group:last-child { margin-bottom: 0; }
.history-group h4 { font-family: 'Sora', sans-serif; font-size: 0.95rem; margin: 0; display: flex; align-items: center; gap: 8px; }

.list-item .edit-name, .list-item .edit-url { width: 100%; }

.raw-json {
  background: rgba(0,0,0,0.35);
  border: 1px solid var(--glass-border);
  border-radius: 10px;
  padding: 14px;
  font-family: 'Courier New', monospace;
  font-size: 0.75rem;
  line-height: 1.5;
  color: var(--muted);
  max-height: 400px;
  overflow: auto;
  white-space: pre-wrap;
  word-break: break-word;
  margin: 8px 0 0;
}
