/* ============================================================
   Casa Guatusa — House Guide
   Palette: jungle paper + roof-teal ink + burnt-orange warnings
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,400;9..144,500;9..144,600;9..144,700&family=Public+Sans:wght@400;500;600;700;800&family=IBM+Plex+Mono:wght@500;600&display=swap');

:root {
  --paper: #F0EEDE;
  --paper-card: #FBFAF3;
  --ink: #1B3A36;
  --ink-soft: #3D5652;
  --jungle: #3F6B4A;
  --jungle-deep: #24463A;
  --sand: #D8C9A3;
  --sand-line: #C9B98D;
  --danger: #E0672A;
  --danger-deep: #A8431A;
  --gold: #E0A83E;

  --display: 'Fraunces', serif;
  --body: 'Public Sans', system-ui, sans-serif;
  --mono: 'IBM Plex Mono', monospace;

  --radius: 14px;
  --shadow: 0 2px 0 rgba(27,58,54,0.06), 0 10px 24px -14px rgba(27,58,54,0.35);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--body);
  -webkit-font-smoothing: antialiased;
}

body {
  padding-bottom: 96px; /* room for sticky emergency bar */
  background-image:
    radial-gradient(circle at 10% 0%, rgba(63,107,74,0.08), transparent 40%),
    radial-gradient(circle at 90% 10%, rgba(224,103,42,0.06), transparent 35%);
}

a { color: inherit; }

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: var(--jungle-deep);
  color: var(--paper);
  padding: 14px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  box-shadow: 0 6px 18px -10px rgba(0,0,0,0.4);
}

.brand {
  display: flex;
  align-items: baseline;
  gap: 8px;
  min-width: 0;
}

.brand-mark {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  color: var(--gold);
  text-transform: uppercase;
  white-space: nowrap;
}

.brand-title {
  font-family: var(--display);
  font-optical-sizing: auto;
  font-weight: 600;
  font-size: 20px;
  letter-spacing: 0.01em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.lang-toggle {
  display: flex;
  border: 1px solid rgba(240,238,222,0.35);
  border-radius: 999px;
  padding: 3px;
  flex-shrink: 0;
}

.lang-toggle button {
  border: none;
  background: transparent;
  color: var(--paper);
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.06em;
  padding: 6px 12px;
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}

.lang-toggle button[aria-pressed="true"] {
  background: var(--gold);
  color: var(--jungle-deep);
}

/* ---------- Section Nav (chip scroller) ---------- */

.nav-scroller {
  position: sticky;
  top: 56px;
  z-index: 39;
  background: var(--paper);
  border-bottom: 1px solid var(--sand-line);
  padding: 10px 14px;
  display: flex;
  gap: 8px;
  overflow-x: auto;
  scrollbar-width: none;
}
.nav-scroller::-webkit-scrollbar { display: none; }

.nav-chip {
  flex-shrink: 0;
  font-family: var(--body);
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-soft);
  background: var(--paper-card);
  border: 1px solid var(--sand-line);
  border-radius: 999px;
  padding: 7px 14px;
  text-decoration: none;
  white-space: nowrap;
}

.nav-chip.is-warning {
  color: var(--danger-deep);
  border-color: var(--danger);
}

/* ---------- Layout ---------- */

.wrap {
  max-width: 640px;
  margin: 0 auto;
  padding: 18px 16px 10px;
}

.intro {
  padding: 18px 4px 6px;
  text-align: center;
}

.intro-sub {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.08em;
  color: var(--jungle);
  text-transform: uppercase;
}

.intro-line {
  font-family: var(--display);
  font-size: 17px;
  font-style: italic;
  color: var(--ink-soft);
  margin-top: 6px;
}

/* ---------- Cards ---------- */

.card {
  background: var(--paper-card);
  border: 1px solid var(--sand-line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 20px 20px 18px;
  margin-bottom: 16px;
  scroll-margin-top: 108px;
}

.card-eyebrow {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--jungle);
  margin-bottom: 6px;
}

.card-eyebrow svg { width: 15px; height: 15px; flex-shrink: 0; }

.card h2 {
  font-family: var(--display);
  font-weight: 600;
  font-size: 24px;
  margin: 0 0 12px;
  color: var(--ink);
  letter-spacing: 0.005em;
}

.card h3 {
  font-family: var(--body);
  font-weight: 700;
  font-size: 14.5px;
  margin: 16px 0 8px;
  color: var(--ink);
}
.card h3:first-of-type { margin-top: 4px; }

/* ---------- WiFi ---------- */

.wifi-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  background: var(--jungle-deep);
  color: var(--paper);
  border-radius: 10px;
  padding: 14px 16px;
}
.wifi-net {
  font-family: var(--mono);
  font-weight: 600;
  font-size: 15px;
  letter-spacing: 0.02em;
}
.wifi-note {
  font-size: 12.5px;
  opacity: 0.75;
  margin-top: 2px;
}
.wifi-icon { flex-shrink: 0; color: var(--gold); }

/* ---------- Steps ---------- */

ol.steps {
  list-style: none;
  margin: 0;
  padding: 0;
  counter-reset: step;
}
ol.steps li {
  counter-increment: step;
  display: flex;
  gap: 12px;
  padding: 7px 0;
  font-size: 15px;
  line-height: 1.45;
  border-bottom: 1px dashed var(--sand-line);
}
ol.steps li:last-child { border-bottom: none; }
ol.steps li::before {
  content: counter(step);
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--jungle);
  color: var(--paper);
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 1px;
}

ul.plain {
  list-style: none;
  margin: 0;
  padding: 0;
}
ul.plain li {
  position: relative;
  padding: 6px 0 6px 18px;
  font-size: 15px;
  line-height: 1.45;
}
ul.plain li::before {
  content: '▸';
  position: absolute;
  left: 0;
  color: var(--jungle);
  font-size: 13px;
  top: 7px;
}

/* ---------- Warnings ---------- */

.warn {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  background: #FCEDE4;
  border: 1px solid var(--danger);
  border-left: 5px solid var(--danger);
  color: var(--danger-deep);
  border-radius: 8px;
  padding: 12px 14px;
  margin-top: 10px;
  font-size: 14px;
  line-height: 1.45;
  font-weight: 500;
}
.warn svg { flex-shrink: 0; width: 18px; height: 18px; margin-top: 2px; }
.warn strong { font-weight: 800; }

/* ---------- Dog subcards ---------- */

.dog-photo {
  width: 100%;
  height: auto;
  border-radius: 10px;
  display: block;
  margin-bottom: 16px;
  border: 1px solid var(--sand-line);
}

.dog-block { margin-bottom: 18px; }
.dog-block:last-child { margin-bottom: 0; }

.dog-name-row {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin-bottom: 2px;
}
.dog-name {
  font-family: var(--display);
  font-size: 20px;
  font-weight: 600;
  color: var(--ink);
}
.dog-tag {
  font-size: 13px;
  color: var(--ink-soft);
  font-style: italic;
}

.divider {
  height: 1px;
  background: var(--sand-line);
  margin: 18px 0;
  border: none;
}

/* ---------- Checklist ---------- */

.checklist { list-style: none; margin: 0; padding: 0; }
.checklist li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px dashed var(--sand-line);
  font-size: 15px;
  line-height: 1.4;
}
.checklist li:last-child { border-bottom: none; }

.check-box {
  flex-shrink: 0;
  width: 22px;
  height: 22px;
  border-radius: 6px;
  border: 2px solid var(--jungle);
  margin-top: 1px;
  cursor: pointer;
  background: var(--paper-card);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.12s ease, border-color 0.12s ease;
}
.check-box.checked {
  background: var(--jungle);
  border-color: var(--jungle);
}
.check-box svg {
  width: 13px;
  height: 13px;
  opacity: 0;
  transition: opacity 0.12s ease;
}
.check-box.checked svg { opacity: 1; }

.checklist li.done .check-label {
  color: var(--ink-soft);
  text-decoration: line-through;
  text-decoration-color: var(--sand-line);
}
.check-label { cursor: pointer; user-select: none; }

.checklist-reset {
  margin-top: 14px;
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--ink-soft);
  background: none;
  border: 1px solid var(--sand-line);
  border-radius: 999px;
  padding: 7px 14px;
  cursor: pointer;
}

/* ---------- Emergency (sticky bottom) ---------- */

.emergency-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 50;
  background: var(--jungle-deep);
  border-top: 3px solid var(--danger);
  padding: 10px 14px;
  display: flex;
  gap: 10px;
}

.emergency-btn {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 1px;
  text-decoration: none;
  color: var(--paper);
  background: rgba(240,238,222,0.06);
  border: 1px solid rgba(240,238,222,0.2);
  border-radius: 10px;
  padding: 8px 6px;
}
.emergency-btn .e-label {
  font-family: var(--mono);
  font-size: 9.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  opacity: 0.7;
}
.emergency-btn .e-phone {
  font-family: var(--mono);
  font-weight: 600;
  font-size: 15px;
  color: var(--gold);
}

/* ---------- Emergency card (inline, in-page) ---------- */

.emergency-card {
  background: var(--jungle-deep);
  border-color: var(--jungle-deep);
}
.emergency-card h2 { color: var(--paper); }
.emergency-card .card-eyebrow { color: var(--gold); }

.contact-row {
  background: rgba(240,238,222,0.06);
  border: 1px solid rgba(240,238,222,0.15);
  border-radius: 10px;
  padding: 14px 16px;
  margin-bottom: 10px;
  color: var(--paper);
}
.contact-row:last-child { margin-bottom: 0; }
.contact-title {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 4px;
}
.contact-name { font-weight: 700; font-size: 15px; }
.contact-phone {
  font-family: var(--mono);
  font-size: 22px;
  font-weight: 600;
  color: var(--gold);
  text-decoration: none;
  display: inline-block;
  margin: 4px 0;
}
.contact-note { font-size: 13px; opacity: 0.75; line-height: 1.4; }

/* ---------- Footer ---------- */

.site-footer {
  text-align: center;
  padding: 30px 20px 10px;
  font-family: var(--display);
  font-style: italic;
  font-size: 15px;
  color: var(--ink-soft);
}
.paw-row { font-size: 18px; letter-spacing: 10px; margin-bottom: 8px; color: var(--jungle); }

/* ---------- Utility ---------- */

.lang-only-es [data-lang="en"],
.lang-only-en [data-lang="es"] { display: none; }

@media (max-width: 380px) {
  .brand-title { font-size: 17px; }
  .card h2 { font-size: 21px; }
}
