/* ============================================================
   D'FAHMI HOMESTAY - Laman Utama (mobile-first)
   ============================================================ */
@import url('tokens.css?v=2');
@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap');

html { scroll-padding-top: 84px; }
body { background: var(--bg); }

/* ================= HEADER ================= */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(250, 247, 240, .92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.header-in {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; min-height: 64px;
}
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.brand-mark {
  width: 40px; height: 40px; border-radius: 12px;
  background: linear-gradient(135deg, var(--g-600), var(--g-800));
  display: grid; place-items: center; color: #fff;
}
.brand-name { font-weight: 800; font-size: 1.06rem; color: var(--ink); line-height: 1.15; }
.brand-name small { display: block; font-weight: 600; font-size: .72rem; color: var(--muted); }

.nav-links { display: none; align-items: center; gap: 4px; }
.nav-links a {
  padding: 9px 14px; border-radius: 10px; text-decoration: none;
  color: var(--body-c); font-weight: 600; font-size: .95rem;
  transition: background-color .2s ease, color .2s ease;
}
.nav-links a:hover { background: var(--g-50); color: var(--g-800); }

.header-actions { display: flex; align-items: center; gap: 8px; }
.btn-wa-head { display: none; min-height: 42px; padding: 8px 18px; }

.menu-btn {
  width: 44px; height: 44px; border-radius: 10px;
  border: 1.5px solid var(--line); background: #fff;
  display: grid; place-items: center; cursor: pointer; color: var(--ink);
}
.mobile-menu {
  display: none;
  flex-direction: column;
  padding: 8px 20px 18px;
  border-top: 1px dashed var(--line);
  background: var(--bg);
}
.mobile-menu.open { display: flex; }
.mobile-menu a {
  padding: 13px 6px; text-decoration: none; font-weight: 700; color: var(--ink);
  border-bottom: 1px solid var(--line); font-size: 1.02rem;
}
.mobile-menu a:last-child { border-bottom: none; }

@media (min-width: 900px) {
  .nav-links { display: flex; }
  .btn-wa-head { display: inline-flex; }
  .menu-btn, .mobile-menu { display: none !important; }
}

/* ================= HERO ================= */
.hero { position: relative; overflow: hidden; }
.hero-bg-deco {
  position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(720px 340px at 88% -60px, rgba(217, 154, 43, .16), transparent 65%),
    radial-gradient(780px 420px at -120px 30%, rgba(42, 140, 78, .12), transparent 62%);
}
.hero-in {
  position: relative;
  display: grid; gap: 22px;
  padding: 44px 0 52px;
  grid-template-areas: "badge" "art" "text";
}
.hero-badge { grid-area: badge; justify-self: start; }
.hero-txt { grid-area: text; }
.hero-art { grid-area: art; }
.hero-badge {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--g-50); color: var(--g-800);
  border: 1.5px solid var(--line-green);
  padding: 7px 15px; border-radius: 999px;
  font-weight: 700; font-size: .88rem; width: fit-content;
}
.hero h1 {
  font-size: clamp(2.05rem, 6vw, 3.3rem);
  letter-spacing: -.5px;
  margin: 14px 0 10px;
}
.hero h1 em { font-style: normal; color: var(--g-700); position: relative; }
.hero-tagline { font-size: clamp(1.05rem, 2.4vw, 1.28rem); color: var(--body-c); max-width: 34em; }
.hero-chips { display: flex; flex-wrap: wrap; gap: 9px; margin: 20px 0 26px; padding: 0; list-style: none; }
.hero-chips li {
  display: inline-flex; align-items: center; gap: 7px;
  background: #fff; border: 1.5px solid var(--line);
  padding: 7px 14px; border-radius: 999px;
  font-weight: 600; font-size: .89rem; color: var(--ink);
}
.hero-chips .icon { color: var(--g-600); }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; }
.hero-price {
  margin-top: 22px; display: inline-flex; align-items: baseline; gap: 8px;
  background: var(--amber-bg); border-radius: 14px; padding: 12px 20px;
  border: 1.5px dashed #E8C98F;
}
.hero-price b { font-size: 1.5rem; color: var(--amber-strong); font-weight: 800; }
.hero-price span { color: var(--amber-strong); font-weight: 600; font-size: .92rem; }

.hero-art { position: relative; }
.hero-art svg { width: 100%; height: auto; border-radius: var(--radius-l); box-shadow: var(--shadow-l); }
.hero-img {
  width: 100%; aspect-ratio: 13 / 10; object-fit: cover;
  border-radius: var(--radius-l); box-shadow: var(--shadow-l);
}

@media (min-width: 940px) {
  .hero-in {
    grid-template-columns: 1.08fr .92fr;
    grid-template-areas: "badge art" "text art";
    align-items: center; column-gap: 36px;
    padding: 68px 0 76px;
  }
  .hero-art { align-self: center; }
}

/* ================= SEKSYEN AM ================= */
.section { padding: 58px 0; }
.section-alt { background: #fff; border-block: 1px solid var(--line); }
.sec-head { max-width: 620px; margin-bottom: 30px; }
.sec-kicker {
  display: inline-flex; align-items: center; gap: 7px;
  font-weight: 800; font-size: .82rem; letter-spacing: 1.4px;
  text-transform: uppercase; color: var(--g-600); margin-bottom: 8px;
}
.sec-kicker::before { content: ""; width: 26px; height: 3px; border-radius: 2px; background: var(--gold); }
.sec-head h2 { font-size: clamp(1.55rem, 4vw, 2.15rem); margin-bottom: 8px; }
.sec-head p { color: var(--muted); margin: 0; }

/* ================= KALENDAR ================= */
.cal-layout { display: grid; gap: 22px; }
@media (min-width: 940px) { .cal-layout { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); align-items: start; } }

.cal-card {
  background: #fff; border: 1px solid var(--line);
  border-radius: var(--radius-l); box-shadow: var(--shadow);
  padding: 20px 16px 18px;
}
.cal-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.cal-title { font-weight: 800; font-size: 1.08rem; color: var(--ink); text-align: center; flex: 1; }
.cal-nav-btn {
  width: 46px; height: 46px; border-radius: 12px;
  border: 1.5px solid var(--line); background: #fff; color: var(--ink);
  display: grid; place-items: center; cursor: pointer;
  transition: background-color .2s ease, border-color .2s ease;
}
.cal-nav-btn:hover:not(:disabled) { background: var(--g-50); border-color: var(--line-green); }
.cal-nav-btn:disabled { opacity: .35; cursor: not-allowed; }

.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 8px; }
.cal-dow {
  text-align: center; font-size: .74rem; font-weight: 800;
  letter-spacing: .6px; color: var(--muted); text-transform: uppercase;
  padding: 6px 0;
}
.cal-cell {
  aspect-ratio: 1; min-height: 42px; min-width: 0;
  border-radius: 11px; border: 1.5px solid transparent;
  background: var(--g-50); color: var(--g-900);
  font-weight: 700; font-size: .95rem;
  display: grid; place-items: center;
  cursor: pointer; padding: 0;
  transition: transform .12s ease, background-color .18s ease, border-color .18s ease;
}
.cal-cell:hover:not(:disabled):not(.booked) { border-color: var(--g-500); transform: scale(1.06); }
.cal-cell.empty { background: transparent; cursor: default; }
.cal-cell.past, .cal-cell.booked {
  background: var(--red-bg); color: #C97B7B; cursor: not-allowed; text-decoration: line-through;
  text-decoration-thickness: 2px;
}
.cal-cell.booked { background: var(--red-bg); }
.cal-cell.past { background: #EFEDE6; color: #B9B4A6; }
.cal-cell.sel-start, .cal-cell.sel-end {
  background: var(--g-700); color: #fff;
  box-shadow: 0 4px 12px -3px rgba(27, 94, 54, .5);
}
.cal-cell.in-range { background: var(--g-100); color: var(--g-900); border-color: var(--g-300); }
.cal-cell.today::after {
  content: ""; position: absolute;
}
.cal-cell.today { border-color: var(--gold); border-width: 2px; }

.cal-today {
  text-align: center; font-size: .88rem; font-weight: 600; color: var(--muted);
  margin-bottom: 12px;
}
.cal-today b { color: var(--g-700); }

.cal-legend {
  display: flex; flex-wrap: wrap; align-items: center; gap: 8px 18px;
  margin-top: 16px; padding-top: 14px; border-top: 1px dashed var(--line);
}
.cal-clear {
  margin-left: auto; border: none; background: none; cursor: pointer;
  font-family: inherit; font-size: .86rem; font-weight: 800; color: var(--red-deep);
  padding: 8px 12px; border-radius: 8px; transition: background-color .2s ease;
}
.cal-clear:hover { background: var(--red-bg); }
.cal-clear[hidden] { display: none; }
.cal-legend span { display: inline-flex; align-items: center; gap: 7px; font-size: .84rem; font-weight: 600; color: var(--body-c); }
.dot { width: 14px; height: 14px; border-radius: 5px; flex: none; }
.dot-free { background: var(--g-50); border: 1.5px solid var(--g-300); }
.dot-taken { background: var(--red-bg); border: 1.5px solid #EFC9C9; }
.dot-sel { background: var(--g-700); }

/* Kad ringkasan pilihan */
.pick-card {
  background: linear-gradient(160deg, var(--g-800), var(--g-950));
  border-radius: var(--radius-l);
  color: #EAF4ED;
  padding: 26px 22px;
  box-shadow: var(--shadow-l);
  position: sticky; top: 84px;
}
.pick-card h3 { color: #fff; font-size: 1.25rem; display: flex; align-items: center; gap: 10px; }
.pick-empty { text-align: center; padding: 14px 6px 6px; }
.pick-empty .icon-big { width: 52px; height: 52px; margin: 0 auto 10px; color: var(--g-300); opacity: .85; }
.pick-empty p { color: #BCD6C5; margin: 0; font-size: .96rem; }

.pick-body { display: none; }
.pick-body.show { display: block; }
.pick-row { display: flex; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px dashed rgba(255,255,255,.16); font-size: .97rem; }
.pick-row span:first-child { color: #A9CDB8; font-weight: 600; }
.pick-row b { color: #fff; }
.pick-row.total { border-bottom: none; font-size: 1.12rem; padding-top: 14px; }
.pick-row.total b { color: var(--gold); font-size: 1.35rem; font-weight: 800; }
.pick-note {
  margin: 12px 0 16px; font-size: .86rem; color: #A9CDB8;
  background: rgba(255,255,255,.07); border-radius: 10px; padding: 10px 14px;
  display: flex; gap: 9px; align-items: flex-start;
}
.pick-note .icon { margin-top: 2px; color: var(--gold); }
.pick-card .btn { width: 100%; }

/* ================= TENTANG + KEMUDAHAN ================= */
.about-grid { display: grid; gap: 30px; }
@media (min-width: 940px) { .about-grid { grid-template-columns: 1fr 1fr; align-items: center; } }
.about-text p { color: var(--body-c); font-size: 1.03rem; }
.about-img {
  width: 100%; aspect-ratio: 4 / 3; object-fit: cover;
  border-radius: var(--radius-l); box-shadow: var(--shadow);
  margin-bottom: 20px; background: var(--g-50);
}
.fac-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr; gap: 9px; }
@media (min-width: 560px) { .fac-list { grid-template-columns: 1fr 1fr; } }
.fac-list li {
  display: flex; align-items: flex-start; gap: 12px;
  background: #fff; border: 1px solid var(--line);
  padding: 14px 16px; border-radius: 14px;
  transition: box-shadow .2s ease, transform .2s ease;
}
.fac-list li:hover { box-shadow: var(--shadow-s); transform: translateY(-2px); }
.fac-ico {
  width: 42px; height: 42px; flex: none; border-radius: 12px;
  background: var(--g-50); border: 1.5px solid var(--line-green);
  color: var(--g-700); display: grid; place-items: center;
}
.fac-ico .icon { width: 22px; height: 22px; }
.fac-txt { min-width: 0; }
.fac-txt b { display: block; color: var(--ink); font-size: .95rem; line-height: 1.35; }
.fac-txt small { display: block; color: var(--muted); font-size: .84rem; line-height: 1.45; margin-top: 2px; }

/* Harga disembunyikan (toggle admin) */
body.no-price .price-el { display: none !important; }

/* ================= GALERI ================= */
.gal-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
@media (min-width: 760px) { .gal-grid { grid-template-columns: repeat(3, 1fr); } }
.gal-item {
  position: relative; border: none; padding: 0; cursor: zoom-in;
  border-radius: var(--radius); overflow: hidden; background: var(--g-50);
  aspect-ratio: 4 / 3; box-shadow: var(--shadow-s);
}
.gal-item img { width: 100%; height: 100%; object-fit: cover; transition: transform .45s ease; }
.gal-item:hover img { transform: scale(1.06); }
.gal-cap {
  position: absolute; left: 0; right: 0; bottom: 0;
  background: linear-gradient(transparent, rgba(12, 42, 24, .78));
  color: #fff; font-weight: 700; font-size: .84rem;
  padding: 26px 12px 10px; text-align: left;
}

/* Lightbox */
.lightbox {
  position: fixed; inset: 0; z-index: 2000;
  background: rgba(10, 26, 17, .93);
  display: none; align-items: center; justify-content: center;
  padding: 20px;
}
.lightbox.open { display: flex; }
.lightbox img { max-width: min(920px, 100%); max-height: 84vh; border-radius: 14px; }
.lightbox-close {
  position: absolute; top: 16px; right: 16px;
  width: 48px; height: 48px; border-radius: 12px; border: none;
  background: rgba(255,255,255,.14); color: #fff; font-size: 1.4rem;
  display: grid; place-items: center; cursor: pointer;
}
.lightbox-close:hover { background: rgba(255,255,255,.26); }

/* ================= LOKASI ================= */
.loc-grid { display: grid; gap: 26px; }
@media (min-width: 940px) { .loc-grid { grid-template-columns: 1.05fr .95fr; align-items: start; } }
.nearby-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.nearby-list li {
  display: flex; align-items: center; gap: 13px;
  background: #fff; border: 1px solid var(--line);
  border-radius: 14px; padding: 11px 14px;
  transition: box-shadow .2s ease;
}
.nearby-list li:hover { box-shadow: var(--shadow-s); }
.nearby-thumb {
  width: 58px; height: 58px; flex: none; border-radius: 12px;
  object-fit: cover; border: 1.5px solid var(--line-green); background: var(--g-50);
}
.nearby-pin {
  width: 52px; height: 52px; flex: none; border-radius: 12px;
  background: var(--g-50); border: 1.5px dashed var(--line-green); color: var(--g-600);
  display: grid; place-items: center;
}
.nearby-info { flex: 1; min-width: 0; }
.nearby-top { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.nearby-list .nm { font-weight: 700; color: var(--ink); font-size: .96rem; }
.nearby-list .ds { display: block; color: var(--muted); font-size: .84rem; line-height: 1.4; margin-top: 1px; }
.nearby-time {
  background: var(--amber-bg); color: var(--amber-strong);
  font-size: .78rem; font-weight: 800; padding: 3px 10px; border-radius: 999px; white-space: nowrap;
}
.map-card { border-radius: var(--radius-l); overflow: hidden; border: 1px solid var(--line); box-shadow: var(--shadow); background: #fff; }
.map-wrap { position: relative; }
.map-frame { width: 100%; height: 280px; border: 0; display: block; background: var(--g-50); }
.map-label {
  position: absolute; top: 12px; left: 12px; z-index: 2;
  display: inline-flex; align-items: center; gap: 7px;
  background: rgba(7, 43, 30, .88); color: #fff;
  font-weight: 800; font-size: .88rem;
  padding: 8px 14px; border-radius: 999px;
  box-shadow: var(--shadow); pointer-events: none;
}
.map-label .icon { color: var(--gold); }
.map-foot { padding: 14px 16px; display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.map-foot .addr { display: flex; align-items: center; gap: 9px; font-weight: 700; color: var(--ink); font-size: .94rem; }
.map-foot .addr .icon { color: var(--red); }

/* ================= HUBUNGI / FOOTER ================= */
.contact-cards { display: grid; gap: 14px; grid-template-columns: 1fr; }
@media (min-width: 700px) { .contact-cards { grid-template-columns: 1fr 1fr; } }
.c-card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius-l);
  padding: 22px; box-shadow: var(--shadow-s);
}
.c-card .who { display: flex; align-items: center; gap: 13px; margin-bottom: 6px; }
.avatar {
  width: 48px; height: 48px; border-radius: 50%;
  background: linear-gradient(135deg, var(--g-500), var(--g-800));
  color: #fff; font-weight: 800; font-size: 1.1rem;
  display: grid; place-items: center;
}
.c-card .who b { color: var(--ink); font-size: 1.08rem; }
.c-card .who small { display: block; color: var(--muted); font-weight: 600; }
.c-card .num { font-size: 1.15rem; font-weight: 800; color: var(--g-800); letter-spacing: .5px; margin-bottom: 14px; }
.c-actions { display: flex; gap: 9px; flex-wrap: wrap; }
.c-actions .btn { flex: 1; min-width: 130px; padding-inline: 10px; }

.footer {
  background: var(--g-950); color: #9FBFAD;
  padding: 34px 0 calc(30px + env(safe-area-inset-bottom));
  text-align: center; font-size: .92rem;
}
.footer b { color: #fff; }
.footer .foot-brand { display: inline-flex; align-items: center; gap: 9px; margin-bottom: 10px; color: #fff; font-weight: 800; font-size: 1.05rem; }
.footer a { color: #CFE6D6; }

/* ================= BUTANG WA TERAPUNG ================= */
.wa-fab {
  position: fixed; right: 16px; bottom: 16px; z-index: 900;
  width: 58px; height: 58px; border-radius: 50%;
  background: var(--wa); color: #fff;
  display: grid; place-items: center;
  box-shadow: 0 10px 26px -6px rgba(21, 128, 61, .55);
  transition: transform .2s ease;
}
.wa-fab:hover { transform: scale(1.07); }
.wa-fab svg { width: 28px; height: 28px; fill: currentColor; stroke: none; }

/* ================= MODAL TEMPAHAN ================= */
.modal-overlay {
  position: fixed; inset: 0; z-index: 1500;
  background: rgba(12, 32, 20, .6);
  backdrop-filter: blur(4px);
  display: none; align-items: flex-end; justify-content: center;
  padding: 0;
}
.modal-overlay.open { display: flex; }
.modal {
  background: var(--bg); width: 100%; max-width: 560px;
  border-radius: 22px 22px 0 0;
  max-height: 92dvh; overflow-y: auto;
  animation: slide-up .28s ease;
  padding: 22px 20px calc(24px + env(safe-area-inset-bottom));
}
@keyframes slide-up { from { transform: translateY(40px); opacity: 0; } to { transform: none; opacity: 1; } }
@media (min-width: 640px) {
  .modal-overlay { align-items: center; padding: 24px; }
  .modal { border-radius: 22px; }
}
.modal-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.modal-head h3 { font-size: 1.3rem; margin: 0; }
.modal-head p { color: var(--muted); margin: 4px 0 0; font-size: .93rem; }
.modal-x {
  width: 42px; height: 42px; flex: none; border-radius: 11px;
  border: 1.5px solid var(--line); background: #fff; color: var(--ink);
  display: grid; place-items: center; cursor: pointer;
}
.modal-x:hover { background: var(--g-50); }

.bsum {
  background: var(--g-50); border: 1.5px solid var(--line-green);
  border-radius: 14px; padding: 14px 16px; margin-bottom: 18px;
  font-size: .93rem;
}
.bsum .row { display: flex; justify-content: space-between; gap: 10px; padding: 4px 0; }
.bsum .row.grand { border-top: 1.5px dashed var(--line-green); margin-top: 6px; padding-top: 10px; font-weight: 800; color: var(--ink); font-size: 1.02rem; }
.bsum .row.grand b { color: var(--g-700); }

.form-actions { display: flex; gap: 10px; margin-top: 20px; }
.form-actions .btn { flex: 1; }

/* Skrin berjaya */
.success-step { display: none; text-align: center; padding: 12px 4px 4px; }
.success-step.show { display: block; }
.success-icon {
  width: 78px; height: 78px; margin: 6px auto 16px; border-radius: 50%;
  background: var(--ok-bg); color: var(--ok);
  display: grid; place-items: center;
}
.success-icon svg { width: 40px; height: 40px; }
.success-step h3 { font-size: 1.35rem; }
.success-step p { color: var(--muted); max-width: 30em; margin-inline: auto; }
.success-actions { display: grid; gap: 10px; margin-top: 20px; }

/* HP: sembunyi scroll bar horizontal */
body.modal-lock { overflow: hidden; }
