/* Guest guide. Mobile first, system fonts (nothing loaded from third parties). */
:root {
  --bg: #f4f3ef; --card: #fff; --ink: #1d2327; --muted: #66717a; --line: #e6e3dc;
  --accent: #1f6f78; --soft: #e6f2f2; --hero: linear-gradient(135deg, #1f6f78, #2c9a8f);
  --r: 18px; --shadow: 0 1px 2px rgba(20, 30, 40, .05), 0 6px 24px rgba(20, 30, 40, .06);
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root { --bg: #121416; --card: #1c1f22; --ink: #eceff1; --muted: #9aa5ad; --line: #2b3035; --shadow: none; }
  .guide { --soft: color-mix(in srgb, var(--accent) 22%, #1c1f22) !important; }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 12px; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 16px/1.55 system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}
.i { width: 20px; height: 20px; flex: none; }
a { color: var(--accent); }
@media (prefers-color-scheme: dark) { a { color: color-mix(in srgb, var(--accent) 55%, white); } }

.guide { max-width: 640px; margin: 0 auto; padding: 0 0 40px; }

.hero {
  background: var(--hero); background-size: cover; background-position: center;
  color: #fff; padding: calc(env(safe-area-inset-top) + 56px) 24px 64px;
  border-radius: 0 0 28px 28px; position: relative; overflow: hidden;
}
.hero:not(.has-cover)::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(circle at 85% 10%, rgba(255,255,255,.22), transparent 45%),
              radial-gradient(circle at 10% 110%, rgba(255,255,255,.12), transparent 50%);
}
.hero.has-cover { padding-top: calc(env(safe-area-inset-top) + 160px); }
.hero-in { position: relative; z-index: 1; }
.eyebrow { margin: 0 0 6px; font-size: 13px; letter-spacing: .14em; text-transform: uppercase; opacity: .85; font-weight: 600; }
.hero h1 { margin: 0; font-size: clamp(30px, 8vw, 42px); line-height: 1.1; letter-spacing: -.02em; font-weight: 750; }
.intro { margin: 14px 0 0; font-size: 17px; opacity: .95; max-width: 34em; }

.quick { margin: -36px 14px 0; position: relative; z-index: 2; display: grid; gap: 12px; }
.card {
  background: var(--card); border-radius: var(--r); box-shadow: var(--shadow);
  padding: 18px 18px 20px; margin: 12px 14px 0; border: 1px solid var(--line);
}
.quick .card { margin: 0; }
.card-h { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; }
.card-h h2 { margin: 0; font-size: 19px; letter-spacing: -.01em; }
.ic {
  width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center;
  background: var(--soft); color: var(--accent); flex: none;
}
.ic.big { width: 64px; height: 64px; border-radius: 20px; margin: 0 auto 16px; }
.ic.big .i { width: 30px; height: 30px; }

.wifi-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 14px; align-items: end; }
.wifi-grid .copy { grid-column: 1 / -1; }
.kv { display: flex; flex-direction: column; min-width: 0; }
.k { font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: .08em; font-weight: 600; }
.v { font-size: 18px; font-weight: 650; overflow-wrap: anywhere; }
.mono { font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; }
.muted { color: var(--muted); }
.wifiqr { margin-top: 12px; }
.wifiqr summary { cursor: pointer; color: var(--accent); font-weight: 600; font-size: 15px; display: flex; align-items: center; gap: 8px; list-style: none; }
.wifiqr summary::-webkit-details-marker { display: none; }
.qrbox { background: #fff; padding: 10px; border-radius: 12px; width: 200px; margin: 12px auto 0; }
.qrbox svg { display: block; width: 100%; height: auto; }

.tiles { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.tile {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow);
  padding: 14px 16px; display: grid; grid-template-columns: auto 1fr; grid-template-rows: auto auto; column-gap: 12px; align-items: center;
}
.tile .ic { grid-row: 1 / 3; width: 34px; height: 34px; border-radius: 10px; }
.tile .v { font-size: 22px; line-height: 1.1; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 46px;
  padding: 10px 16px; border-radius: 14px; border: 0; cursor: pointer; text-decoration: none;
  background: var(--accent); color: #fff !important; font: inherit; font-weight: 650; font-size: 15px;
  transition: transform .1s, filter .2s;
}
.btn:active { transform: scale(.98); }
.btn:hover { filter: brightness(1.08); }
.btn.done { background: #2e7d4f; }
.btn.small { min-height: 36px; padding: 6px 14px; font-size: 14px; border-radius: 11px; }
.btns { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.btns .btn { flex: 1 1 auto; background: var(--soft); color: var(--accent) !important; }

.chips {
  display: flex; gap: 8px; overflow-x: auto; padding: 18px 14px 4px; scrollbar-width: none;
  -webkit-overflow-scrolling: touch; position: sticky; top: 0; z-index: 3;
  background: linear-gradient(var(--bg) 75%, transparent);
}
.chips::-webkit-scrollbar { display: none; }
.chip {
  display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; flex: none;
  padding: 8px 13px; border-radius: 999px; background: var(--card); border: 1px solid var(--line);
  color: var(--ink) !important; text-decoration: none; font-size: 14px; font-weight: 600;
}
.chip .i { width: 16px; height: 16px; color: var(--accent); }

.body { overflow-wrap: anywhere; }
.body p { margin: 0 0 10px; }
.body p:last-child { margin-bottom: 0; }
.body ul, .body ol { margin: 0 0 10px; padding-left: 22px; }
.body li { margin: 4px 0; }
.body li::marker { color: var(--accent); }
.body ul.check { list-style: none; padding: 0; }
.body ul.check li { margin: 0; border-bottom: 1px solid var(--line); }
.body ul.check li:last-child { border-bottom: 0; }
.body ul.check label { display: flex; gap: 12px; align-items: flex-start; padding: 10px 0; cursor: pointer; }
.body ul.check input {
  appearance: none; -webkit-appearance: none; width: 24px; height: 24px; flex: none; margin: 0;
  border: 2px solid var(--line); border-radius: 8px; display: grid; place-items: center; transition: .15s;
}
.body ul.check input:checked { background: var(--accent); border-color: var(--accent); }
.body ul.check input:checked::after { content: ""; width: 6px; height: 11px; border: solid #fff; border-width: 0 2.5px 2.5px 0; transform: translateY(-1px) rotate(45deg); }
.body ul.check input:checked + span { color: var(--muted); text-decoration: line-through; }
.sec-emergency .ic { background: #fdecec; color: #c62828; }
@media (prefers-color-scheme: dark) { .sec-emergency .ic { background: #3a2023; color: #ff8a80; } }

.addr { margin: 0 0 12px; font-weight: 600; }
.hostname { margin: 0; font-size: 18px; font-weight: 650; }
.host .mono { margin: 2px 0 0; }

.txbar {
  margin: 14px 14px 0; padding: 10px 12px 10px 14px; border-radius: 14px; background: var(--card);
  border: 1px solid var(--line); display: flex; align-items: center; gap: 10px; box-shadow: var(--shadow);
  position: relative; z-index: 2;
}
.txbar .i { color: var(--accent); }
.txbar.hint { font-size: 14px; color: var(--muted); }
.txbar.hint span { flex: 1; }
.txbar .x { background: none; border: 0; color: var(--muted); padding: 4px; cursor: pointer; }

.foot { text-align: center; padding: 28px 16px 8px; font-size: 13px; color: var(--muted); }
.foot a { color: var(--muted); text-decoration: none; }
.foot strong { color: var(--ink); }

.loading { min-height: 100vh; display: grid; place-items: center; }
.spinner { width: 32px; height: 32px; border-radius: 50%; border: 3px solid var(--line); border-top-color: var(--accent); animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.broken { max-width: 420px; margin: 0 auto; padding: 22vh 24px; text-align: center; color: var(--muted); }

.preview body { overflow-x: hidden; }
@media (min-width: 700px) {
  .guide { padding-top: 24px; }
  .hero { border-radius: 28px; margin: 0 14px; }
}
@media print {
  .chips, .txbar, .btn, .wifiqr { display: none !important; }
  .card { box-shadow: none; break-inside: avoid; }
}
.txbar .txl { flex: 1; font-size: 14px; color: var(--muted); }
