/* =========================================================
   Gastenportaal – template-stijl
   Kleuren komen uit brands/<merk>.json (en eventueel de hotel-config).
   De waarden hieronder zijn alleen standaardwaarden.
   ========================================================= */

/* Zelf-gehost lettertype (geen Google Fonts → geen IP-adressen naar derden).
   Zet de .woff2-bestanden in /assets/fonts/ – zie README. Ontbreken ze,
   dan wordt automatisch het systeemlettertype gebruikt. */
@font-face { font-family: "Open Sans"; font-weight: 400; font-display: swap; src: url("/assets/fonts/open-sans-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "Open Sans"; font-weight: 600; font-display: swap; src: url("/assets/fonts/open-sans-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "Open Sans"; font-weight: 700; font-display: swap; src: url("/assets/fonts/open-sans-latin-700-normal.woff2") format("woff2"); }

:root {
  --bg:        #f4efe8;
  --tile:      #d9cbbb;
  --tile-2:    #e6dccf;
  --overlay:   .58;
  --accent:    #b8955a;
  --accent-ink:#ffffff;
  --ink:       #1c1b19;
  --muted:     #6b645b;
  --line:      rgba(28,27,25,.12);
  --radius:    16px;
  --font: "Open Sans", "Segoe UI", system-ui, -apple-system, Roboto, Arial, sans-serif;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; min-height: 100%; }
body {
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
}
body.loading .app, body.loading .fab { visibility: hidden; }

/* Grote schermen: app als kolom in het midden, vervaagde foto erachter */
.backdrop { display: none; }
@media (min-width: 620px) {
  body { background: var(--tile); }
  .backdrop {
    display: block; position: fixed; inset: -30px; z-index: -1;
    background: var(--tile) center / cover no-repeat;
    filter: blur(14px) brightness(.9);
  }
  .app {
    max-width: 460px; margin: 32px auto; min-height: calc(100vh - 64px);
    border-radius: 28px; overflow: hidden;
    box-shadow: 0 20px 60px rgba(0,0,0,.25);
  }
}
.app { background: var(--bg); position: relative; min-height: 100vh; }

/* ---------- Header ---------- */
header {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 18px 20px 14px;
  position: sticky; top: 0; z-index: 20; background: var(--bg);
}
.round-btn {
  width: 44px; height: 44px; flex: none; border: 0; border-radius: 12px; cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center;
  font: 700 14px var(--font); color: var(--accent-ink); background: var(--accent);
}
.round-btn svg { width: 22px; height: 22px; }
.round-btn[hidden] { display: inline-flex; visibility: hidden; }
.back { background: var(--tile); color: var(--ink); visibility: hidden; }
body.detail .back { visibility: visible; }

.logo { display: flex; align-items: center; justify-content: center; text-decoration: none; color: var(--ink); min-width: 0; }
.logo img { height: 42px; width: auto; max-width: 220px; object-fit: contain; display: block; }
.logo .words { display: flex; flex-direction: column; line-height: 1.1; white-space: nowrap; text-align: left; }
.logo .words small { font-size: 9px; letter-spacing: .12em; }
.logo .words strong { font-size: 15px; font-weight: 400; letter-spacing: .06em; }

main { padding: 6px 20px 110px; }

/* ---------- Beoordelingsbanner ---------- */
.banner {
  display: flex; align-items: center; gap: 16px;
  background: var(--tile); border-radius: var(--radius);
  padding: 18px 16px 18px 22px; margin-bottom: 16px;
  color: inherit; text-decoration: none;
}
.banner[hidden] { display: none; }
.banner svg { width: 34px; height: 34px; flex: none; }
.banner .chev { width: 22px; height: 22px; margin-left: auto; }
.banner span { font-size: 15px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* ---------- Tegels (bento-grid) ---------- */
.grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-auto-rows: 114px;
  grid-auto-flow: dense;
  gap: 16px;
}
.tile {
  position: relative; overflow: hidden;
  border-radius: var(--radius);
  background: var(--tile) center / cover no-repeat;
  color: var(--ink); text-decoration: none;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px;
  text-align: center; padding: 12px;
  transition: transform .15s ease;
}
.tile::before, .page-hero::before {
  content: ""; position: absolute; inset: 0;
  background: var(--tile); opacity: var(--overlay);
}
.tile:not(.has-img)::before, .page-hero:not(.has-img)::before { opacity: 1; }
.tile > *, .page-hero > * { position: relative; }
.tile:active { transform: scale(.98); }
.tile:focus-visible, .banner:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.tile svg { width: 46px; height: 46px; }
.tile h2 { margin: 0; font-size: 15px; font-weight: 600; line-height: 1.2; }

.wide { grid-column: span 2; }
.tall { grid-row: span 2; }
.full { grid-column: span 3; }
.full.row { flex-direction: row; justify-content: flex-start; gap: 40px; padding-left: 36px; }

@media (max-width: 360px) {
  .grid { gap: 12px; grid-auto-rows: 104px; }
  main, header { padding-left: 14px; padding-right: 14px; }
}

/* ---------- Detailpagina ---------- */
.page { display: none; }
body.detail .home { display: none; }
body.detail .page { display: block; }

.page-hero {
  position: relative; overflow: hidden; border-radius: var(--radius);
  background: var(--tile) center / cover no-repeat;
  min-height: 150px; padding: 22px;
  display: flex; flex-direction: column; justify-content: flex-end; gap: 8px;
}
.page-hero svg { width: 40px; height: 40px; }
.page-hero h1 { margin: 0; font-size: 24px; font-weight: 700; }

.section { background: var(--tile-2); border-radius: var(--radius); padding: 18px 20px; margin-top: 14px; }
.section h3 { margin: 0 0 6px; font-size: 16px; }
.section p { margin: 0 0 8px; }
.section p:last-child { margin-bottom: 0; }
.rows { list-style: none; margin: 4px 0 0; padding: 0; }
.rows li { display: flex; justify-content: space-between; gap: 16px; padding: 9px 0; border-bottom: 1px solid var(--line); }
.rows li:last-child { border-bottom: 0; }
.rows li span:first-child { color: var(--muted); }
.rows li span:last-child { text-align: right; font-weight: 600; }
.btn {
  display: inline-block; margin-top: 10px; padding: 11px 18px; border-radius: 999px;
  background: var(--ink); color: var(--bg); text-decoration: none; font-weight: 600; font-size: 14px;
}

.error { background: var(--tile-2); border-radius: var(--radius); padding: 20px; margin-top: 16px; }

/* ---------- Zwevende +-knop & snelmenu ---------- */
.fab {
  position: fixed; right: 20px; bottom: calc(20px + env(safe-area-inset-bottom));
  width: 58px; height: 58px; border-radius: 50%; border: 0; cursor: pointer;
  background: var(--accent); color: var(--accent-ink); z-index: 40;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 6px 18px rgba(0,0,0,.2);
  transition: transform .2s ease;
}
.fab[hidden] { display: none; }
.fab svg { width: 28px; height: 28px; }
body.sheet-open .fab { transform: rotate(45deg); }
@media (min-width: 620px) { .fab { right: calc(50% - 230px + 20px); bottom: 52px; } }

.scrim {
  position: fixed; inset: 0; background: rgba(0,0,0,.3); z-index: 30;
  opacity: 0; pointer-events: none; transition: opacity .2s ease;
}
.sheet {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 35;
  max-width: 460px; margin: 0 auto;
  background: var(--bg); border-radius: 22px 22px 0 0;
  padding: 22px 20px calc(96px + env(safe-area-inset-bottom));
  transform: translateY(100%); visibility: hidden;
  transition: transform .25s ease, visibility 0s linear .25s;
}
body.sheet-open .scrim { opacity: 1; pointer-events: auto; }
body.sheet-open .sheet { transform: none; visibility: visible; transition: transform .25s ease; }
.sheet h3 { margin: 0 0 12px; font-size: 16px; }
.action {
  display: flex; align-items: center; gap: 14px; padding: 14px 16px; margin-top: 10px;
  background: var(--tile-2); border-radius: 14px; color: inherit; text-decoration: none; font-weight: 600;
}
.action svg { width: 24px; height: 24px; flex: none; }
