/* ======================================================
   StayFlow — Premium Hotel Booking Portal
   Google Fonts: Playfair Display (headings) + Inter (body)
   Color palette: Gold / Navy / Cream
   ====================================================== */

@import url("https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,400;0,600;0,700;1,400&family=Inter:wght@300;400;500;600&display=swap");

/* ── CSS Variables ── */
:root {
  --gold:        #c9a84c;
  --gold-light:  #e8c96d;
  --gold-dark:   #a8893a;
  --navy:        #0d1b2a;
  --navy-soft:   #1a2e45;
  --cream:       #faf8f4;
  --warm-white:  #ffffff;
  --text:        #1a1a2e;
  --text-soft:   #4a4a6a;
  --text-muted:  #8b8b9e;
  --border:      #e8e4dc;
  --success:     #22c55e;
  --shadow-sm:   0 2px 8px rgba(13,27,42,.08);
  --shadow-md:   0 8px 32px rgba(13,27,42,.14);
  --shadow-lg:   0 20px 60px rgba(13,27,42,.20);
  --radius:      12px;
  --radius-sm:   8px;
}

/* ── Reset & Base ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: "Inter", sans-serif;
  font-size: 15px;
  line-height: 1.65;
  color: var(--text);
  background: var(--cream);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-family: "Playfair Display", serif;
  font-weight: 600;
  line-height: 1.25;
}

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

input, select, textarea, button {
  font-family: "Inter", sans-serif;
  font-size: inherit;
  outline: none;
}

/* ── Scrollbar ── */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--cream); }
::-webkit-scrollbar-thumb { background: var(--gold); border-radius: 99px; }

/* ======================================================
   NAV
   ====================================================== */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 2.5rem;
  height: 70px;
  background: rgba(13, 27, 42, 0.88);
  backdrop-filter: blur(18px) saturate(160%);
  -webkit-backdrop-filter: blur(18px) saturate(160%);
  border-bottom: 1px solid rgba(201, 168, 76, 0.18);
  transition: background .3s;
}

.nav-brand {
  font-family: "Playfair Display", serif;
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--gold);
  letter-spacing: .04em;
  cursor: default;
  user-select: none;
}

.nav-brand::after {
  content: "";
  display: inline-block;
  width: 6px; height: 6px;
  background: var(--gold);
  border-radius: 50%;
  margin-left: 4px;
  vertical-align: middle;
  transform: translateY(-3px);
}

.nav-links { display: flex; align-items: center; gap: .5rem; }

/* Language switcher — pill buttons */
.lang-switcher {
  display: flex;
  align-items: center;
  gap: 4px;
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(201,168,76,.25);
  border-radius: 99px;
  padding: 4px;
}

.lang-btn {
  background: transparent;
  border: none;
  color: rgba(255,255,255,.6);
  font-size: .75rem;
  font-weight: 500;
  letter-spacing: .06em;
  padding: 4px 10px;
  border-radius: 99px;
  cursor: pointer;
  transition: all .2s;
}

.lang-btn:hover { color: #fff; background: rgba(255,255,255,.1); }

.lang-btn.active {
  background: var(--gold);
  color: var(--navy);
  font-weight: 600;
}

/* Hidden legacy select — keep for JS compat, visually replaced */
.lang-select { display: none; }

/* ======================================================
   HERO
   ====================================================== */
.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 120px 2rem 140px;
  background: linear-gradient(135deg, #0d1b2a 0%, #1a3a5c 50%, #0d1b2a 100%);
  background-size: 400% 400%;
  animation: heroGradient 12s ease infinite;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 60% at 50% 0%, rgba(201,168,76,.08) 0%, transparent 70%),
    radial-gradient(ellipse 60% 40% at 20% 100%, rgba(26,58,92,.6) 0%, transparent 60%);
  pointer-events: none;
}

/* subtle grid texture */
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.03) 1px, transparent 1px);
  background-size: 60px 60px;
  pointer-events: none;
}

@keyframes heroGradient {
  0%   { background-position: 0% 50%;   }
  50%  { background-position: 100% 50%; }
  100% { background-position: 0% 50%;   }
}

.hotel-logo {
  width: 88px; height: 88px;
  border-radius: 50%;
  border: 3px solid var(--gold);
  object-fit: cover;
  margin-bottom: 1.5rem;
  position: relative; z-index: 1;
  box-shadow: 0 0 0 8px rgba(201,168,76,.12);
}

.hotel-name {
  font-family: "Playfair Display", serif;
  font-size: clamp(2.4rem, 6vw, 4.5rem);
  font-weight: 700;
  color: #fff;
  letter-spacing: .02em;
  position: relative; z-index: 1;
  text-shadow: 0 4px 24px rgba(0,0,0,.4);
  margin-bottom: .5rem;
}

.stars {
  color: var(--gold);
  font-size: 1.4rem;
  letter-spacing: .15em;
  position: relative; z-index: 1;
  text-shadow: 0 2px 8px rgba(201,168,76,.5);
  margin-bottom: .75rem;
}

.hotel-meta {
  display: flex;
  flex-wrap: wrap;
  gap: .75rem 1.5rem;
  justify-content: center;
  position: relative; z-index: 1;
}

.hotel-meta span {
  font-size: .85rem;
  color: rgba(255,255,255,.75);
  font-weight: 400;
  letter-spacing: .02em;
}

.hotel-meta a:hover { color: var(--gold-light); }

/* Loading spinner */
.loading-spin {
  width: 44px; height: 44px;
  border: 3px solid rgba(201,168,76,.2);
  border-top-color: var(--gold);
  border-radius: 50%;
  animation: spin .8s linear infinite;
}

@keyframes spin { to { transform: rotate(360deg); } }

/* Empty state */
.empty-state {
  text-align: center; padding: 4rem 2rem; color: rgba(255,255,255,.7);
}
.empty-state .empty-icon { font-size: 3.5rem; margin-bottom: 1rem; }
.empty-state h2 { font-family: "Playfair Display", serif; color: #fff; margin-bottom: .5rem; }
.empty-state code {
  background: rgba(255,255,255,.1); padding: 2px 8px; border-radius: 4px;
  color: var(--gold-light); font-size: .85em;
}

/* ======================================================
   BOOKING BAR
   ====================================================== */
.booking-bar {
  position: relative;
  z-index: 100;
  margin-top: -60px;
  padding: 0 2rem 2rem;
}

.booking-bar-inner {
  max-width: 1100px;
  margin: 0 auto;
  background: var(--warm-white);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border);
  overflow: hidden;
}

.booking-form {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr 1fr auto;
  gap: 0;
}

.form-group {
  padding: 1rem 1.25rem;
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.form-group:last-child { border-right: none; padding: .75rem 1rem; justify-content: flex-end; }

.form-group label {
  font-size: .7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--text-muted);
}

.form-group input[type="date"],
.form-group select {
  border: none;
  background: transparent;
  color: var(--text);
  font-size: .95rem;
  font-weight: 500;
  cursor: pointer;
  padding: 0;
  width: 100%;
  -webkit-appearance: none;
  appearance: none;
}

.form-group input[type="date"]:focus,
.form-group select:focus { color: var(--navy); }

.btn-search {
  background: linear-gradient(135deg, var(--gold) 0%, var(--gold-dark) 100%);
  color: var(--navy);
  border: none;
  border-radius: var(--radius-sm);
  padding: .75rem 1.5rem;
  font-weight: 700;
  font-size: .9rem;
  letter-spacing: .04em;
  cursor: pointer;
  white-space: nowrap;
  transition: all .2s;
  box-shadow: 0 4px 14px rgba(201,168,76,.35);
}

.btn-search:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(201,168,76,.5);
}

.btn-search:disabled {
  opacity: .6; cursor: not-allowed; transform: none;
}

/* ======================================================
   SECTIONS
   ====================================================== */
.section {
  max-width: 1200px;
  margin: 0 auto;
  padding: 3.5rem 2rem;
}

.section-title {
  font-family: "Playfair Display", serif;
  font-size: 2rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  border-bottom: 2px solid var(--border);
  position: relative;
}

.section-title::after {
  content: "";
  position: absolute;
  bottom: -2px; left: 0;
  width: 60px; height: 2px;
  background: var(--gold);
}

/* ======================================================
   CAMPAIGNS
   ====================================================== */
.campaigns-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1.5rem;
}

.campaign-card {
  background: var(--warm-white);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  border-left: 4px solid var(--gold);
  overflow: hidden;
  transition: transform .25s, box-shadow .25s;
  box-shadow: var(--shadow-sm);
}

.campaign-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.campaign-img {
  height: 140px;
  background: linear-gradient(135deg, var(--navy-soft) 0%, var(--navy) 100%);
  display: flex; align-items: center; justify-content: center;
  font-size: 3rem;
}

.campaign-body { padding: 1.25rem; }

.discount-badge {
  display: inline-block;
  background: var(--gold);
  color: var(--navy);
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  padding: 3px 10px;
  border-radius: 99px;
  margin-bottom: .6rem;
}

.campaign-title {
  font-family: "Playfair Display", serif;
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: .3rem;
}

.campaign-dates {
  font-size: .78rem;
  color: var(--text-muted);
  margin-top: .25rem;
}

.days-left {
  font-size: .78rem;
  color: #e85d04;
  font-weight: 600;
  margin-top: .3rem;
}

/* ======================================================
   ROOMS
   ====================================================== */
#roomsGrid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 1.75rem;
}

.room-card {
  background: var(--warm-white);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: transform .3s, box-shadow .3s;
  display: flex;
  flex-direction: column;
}

.room-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-md);
}

.room-img {
  width: 100%; height: 220px;
  object-fit: cover;
  background: linear-gradient(135deg, #1a2e45 0%, #0d2b44 50%, #0d1b2a 100%);
  display: flex; align-items: center; justify-content: center;
  font-size: 4rem;
  color: rgba(255,255,255,.15);
  flex-shrink: 0;
}

.room-body {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.room-name {
  font-family: "Playfair Display", serif;
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: .75rem;
}

.room-features {
  display: flex;
  flex-wrap: wrap;
  gap: .4rem .75rem;
  font-size: .8rem;
  color: var(--text-soft);
  margin-bottom: .75rem;
}

.room-features span { display: flex; align-items: center; gap: 3px; }

.room-amenities {
  display: flex; flex-wrap: wrap; gap: .35rem;
  margin-bottom: .75rem;
}

.amenity-tag {
  background: #f0ece4;
  border: 1px solid var(--border);
  color: var(--text-soft);
  font-size: .72rem;
  padding: 3px 9px;
  border-radius: 99px;
  font-weight: 500;
}

.room-price {
  font-family: "Playfair Display", serif;
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--gold-dark);
  margin-bottom: .5rem;
  margin-top: auto;
}

.room-price span {
  font-family: "Inter", sans-serif;
  font-size: .8rem;
  font-weight: 400;
  color: var(--text-muted);
}

.btn-book {
  margin-top: .75rem;
  padding: .75rem 1.25rem;
  background: linear-gradient(135deg, var(--gold) 0%, var(--gold-dark) 100%);
  color: var(--navy);
  border: none;
  border-radius: var(--radius-sm);
  font-weight: 700;
  font-size: .88rem;
  letter-spacing: .04em;
  cursor: pointer;
  transition: all .22s;
  box-shadow: 0 4px 14px rgba(201,168,76,.3);
}

.btn-book:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 22px rgba(201,168,76,.5);
}

/* ======================================================
   ABOUT
   ====================================================== */
#aboutSection { background: var(--cream); }

.about-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 1.25rem;
}

.about-card {
  background: var(--navy);
  border-radius: var(--radius);
  padding: 1.75rem 1.25rem;
  text-align: center;
  transition: transform .25s;
  box-shadow: var(--shadow-sm);
}

.about-card:hover { transform: translateY(-3px); }

.about-icon { font-size: 1.8rem; margin-bottom: .5rem; }

.about-value {
  font-family: "Playfair Display", serif;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--gold);
  margin-bottom: .25rem;
}

.about-label {
  font-size: .75rem;
  color: rgba(255,255,255,.55);
  text-transform: uppercase;
  letter-spacing: .08em;
  font-weight: 500;
}

#aboutDesc {
  margin-top: 1.5rem !important;
  color: var(--text-soft) !important;
  font-size: .95rem !important;
  max-width: 760px;
  line-height: 1.8;
}

/* ======================================================
   MODAL
   ====================================================== */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(13,27,42,.65);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity .25s;
}

.modal-overlay.open {
  opacity: 1;
  pointer-events: all;
}

.modal {
  background: var(--warm-white);
  border-radius: var(--radius);
  width: 100%;
  max-width: 560px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shadow-lg);
  padding: 2rem;
  position: relative;
  transform: scale(.96) translateY(12px);
  transition: transform .25s;
}

.modal-overlay.open .modal {
  transform: scale(1) translateY(0);
}

.modal h3 {
  font-family: "Playfair Display", serif;
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 1.25rem;
  padding-bottom: .75rem;
  border-bottom: 2px solid var(--gold);
  display: flex; align-items: center; gap: .5rem;
}

/* Modal form */
.modal-form { display: flex; flex-direction: column; gap: .85rem; }

.modal-label {
  display: block;
  font-size: .72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .07em;
  color: var(--text-muted);
  margin-bottom: .3rem;
}

.modal-form input,
.modal-form select,
.modal-form textarea {
  width: 100%;
  padding: .65rem .85rem;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  background: #faf8f4;
  color: var(--text);
  font-size: .9rem;
  transition: border-color .2s, box-shadow .2s;
}

.modal-form input:focus,
.modal-form select:focus,
.modal-form textarea:focus {
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(201,168,76,.15);
  background: #fff;
}

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: .75rem; }

.promo-row { display: flex; gap: .5rem; }
.promo-row input { flex: 1; }

.btn-promo {
  background: var(--navy);
  color: var(--gold);
  border: none;
  border-radius: var(--radius-sm);
  padding: .65rem 1rem;
  font-weight: 600;
  font-size: .83rem;
  cursor: pointer;
  white-space: nowrap;
  transition: background .2s;
}

.btn-promo:hover { background: var(--navy-soft); }

.discount-info {
  font-size: .82rem;
  color: var(--success);
  margin-top: .4rem;
  padding: .5rem .75rem;
  background: rgba(34,197,94,.08);
  border-radius: 6px;
  border: 1px solid rgba(34,197,94,.2);
}

/* Price summary */
.price-summary {
  background: #f6f3ed;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  padding: 1rem 1.25rem;
  display: flex;
  flex-direction: column;
  gap: .4rem;
}

.price-row {
  display: flex;
  justify-content: space-between;
  font-size: .88rem;
  color: var(--text-soft);
}

.price-row.total {
  border-top: 1.5px solid var(--border);
  padding-top: .5rem;
  margin-top: .25rem;
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--text);
}

.price-row.total span:last-child { color: var(--gold-dark); }

.btn-confirm {
  width: 100%;
  padding: .9rem;
  background: linear-gradient(135deg, var(--gold) 0%, var(--gold-dark) 100%);
  color: var(--navy);
  border: none;
  border-radius: var(--radius-sm);
  font-size: .95rem;
  font-weight: 700;
  letter-spacing: .05em;
  cursor: pointer;
  transition: all .22s;
  box-shadow: 0 4px 16px rgba(201,168,76,.35);
}

.btn-confirm:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 24px rgba(201,168,76,.5);
}

.btn-confirm:disabled { opacity: .6; cursor: not-allowed; transform: none; }

.btn-cancel {
  width: 100%;
  padding: .75rem;
  background: transparent;
  color: var(--text-muted);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: .88rem;
  font-weight: 500;
  cursor: pointer;
  transition: all .2s;
  margin-top: .25rem;
}

.btn-cancel:hover { border-color: var(--text-muted); color: var(--text); }

/* Success screen */
.success-screen { text-align: center; padding: 1rem 0; }
.success-icon { font-size: 3.5rem; margin-bottom: .75rem; }

.success-num {
  font-family: "Playfair Display", serif;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--gold-dark);
  margin-bottom: .5rem;
}

.success-screen h3 {
  font-family: "Playfair Display", serif;
  font-size: 1.35rem;
  color: var(--navy);
  border: none;
  margin-bottom: 0;
  padding: 0;
}

/* ======================================================
   FOOTER
   ====================================================== */
footer {
  background: var(--navy);
  color: rgba(255,255,255,.55);
  text-align: center;
  padding: 3rem 2rem;
  font-size: .85rem;
  margin-top: 2rem;
}

footer strong, #footerBrand {
  font-family: "Playfair Display", serif;
  color: var(--gold);
  font-size: 1.1rem;
  font-weight: 700;
}

.footer-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .75rem;
}

.footer-links {
  display: flex; gap: 1.5rem; flex-wrap: wrap; justify-content: center;
  margin: .5rem 0;
}

.footer-links a {
  color: rgba(255,255,255,.45);
  font-size: .82rem;
  letter-spacing: .04em;
  transition: color .2s;
}

.footer-links a:hover { color: var(--gold); }

.footer-divider {
  width: 40px; height: 1px;
  background: rgba(201,168,76,.3);
  margin: .5rem auto;
}

/* ======================================================
   RESPONSIVE
   ====================================================== */
@media (max-width: 900px) {
  .booking-form {
    grid-template-columns: 1fr 1fr;
  }
  .form-group { border-right: none; border-bottom: 1px solid var(--border); }
  .form-group:last-child { border-bottom: none; }

  #roomsGrid { grid-template-columns: 1fr; }
  .grid-2 { grid-template-columns: 1fr; }
}

@media (max-width: 600px) {
  .nav { padding: 0 1.25rem; }
  .nav-brand { font-size: 1.3rem; }

  .hero { padding: 100px 1.25rem 120px; }
  .hotel-name { font-size: 2rem; }

  .booking-bar { margin-top: -30px; padding: 0 1rem 1.5rem; }
  .booking-form { grid-template-columns: 1fr; }

  .section { padding: 2.5rem 1.25rem; }
  .section-title { font-size: 1.5rem; }

  .about-grid { grid-template-columns: repeat(2, 1fr); }
  .campaigns-grid { grid-template-columns: 1fr; }

  .modal { padding: 1.5rem; }
}
