:root {
  --navy: #0b1d3f;
  --navy-2: #1d4f9a;
  --blue: #2f74d0;
  --accent: #4fd1ff;
  --ink: #12213b;
  --muted: #5d6b82;
  --line: #e2e8f2;
  --bg: #f5f8fc;
  --card: #ffffff;
  --snow: #1d6fd6;
  --radius: 14px;
}
@media (prefers-color-scheme: dark) {
  :root {
    --ink: #e8eef8;
    --muted: #9aa8bf;
    --line: #22324f;
    --bg: #0a1529;
    --card: #101f3a;
    --blue: #9fd3ff;
    --snow: #7cc4ff;
  }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 16px/1.6 system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}
a { color: var(--blue); }
h1, h2, h3 { line-height: 1.25; }
h1 { font-size: clamp(1.6rem, 4.5vw, 2.4rem); margin: 0 0 .5rem; letter-spacing: -.01em; }
h2 { font-size: 1.35rem; margin: 2.2rem 0 .8rem; }
h3 { font-size: 1.05rem; margin: 1.4rem 0 .3rem; }
.wrap { max-width: 980px; margin: 0 auto; padding: 0 16px; }
.narrow { max-width: 720px; }
.muted { color: var(--muted); }
.fine { color: var(--muted); font-size: .85rem; }

.site-header { background: linear-gradient(180deg, var(--navy), #10295a); }
.header-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 72px; flex-wrap: wrap; }
.brand img { display: block; height: 48px; width: auto; }
.nav { display: flex; gap: 6px; flex-wrap: wrap; }
.nav a { color: #dbe9ff; text-decoration: none; padding: 6px 10px; border-radius: 999px; font-size: .95rem; }
.nav a:hover { background: rgba(255,255,255,.1); }
.nav .nav-cta { background: var(--accent); color: var(--navy); font-weight: 600; }

.hero { background: linear-gradient(180deg, #10295a, var(--navy-2)); color: #fff; padding: 28px 0 34px; }
.hero .lead { color: #d6e6ff; max-width: 680px; margin: .2rem 0; }
.hero .updated { color: var(--accent); font-size: .9rem; margin: .6rem 0 0; }
.app-icon { border-radius: 22px; margin-bottom: 12px; }

.highlights { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-top: -18px; }
.highlight { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; text-decoration: none; color: var(--ink); display: grid; box-shadow: 0 6px 18px rgba(11,29,63,.08); }
.h-name { font-weight: 600; }
.h-depth { font-size: 1.9rem; font-weight: 800; color: var(--snow); line-height: 1.2; }
.h-city { color: var(--muted); font-size: .85rem; }
.notice { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; margin-top: 20px; }

.table-wrap { overflow-x: auto; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); }
table { width: 100%; border-collapse: collapse; }
th, td { padding: 10px 14px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: middle; }
tbody tr:last-child td { border-bottom: 0; }
th { font-size: .8rem; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); font-weight: 600; }
.num { text-align: right; white-space: nowrap; }
td a { font-weight: 600; text-decoration: none; }
td a:hover { text-decoration: underline; }
.depth { font-weight: 700; color: var(--snow); }
.nosnow .depth { color: var(--muted); font-weight: 500; }
.snow { color: var(--snow); font-weight: 700; }

.crumbs { font-size: .9rem; color: var(--muted); margin: 16px 0 6px; }
.crumbs a { text-decoration: none; }
.resort-hero { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin-bottom: 14px; }
.resort-hero p { margin: 0; }
.big-depth { background: linear-gradient(160deg, var(--navy), var(--navy-2)); color: #fff; border-radius: var(--radius); padding: 14px 22px; display: grid; text-align: right; min-width: 220px; }
.big-depth .value { font-size: 2.8rem; font-weight: 800; line-height: 1.1; }
.big-depth.none .value { font-size: 1.8rem; }
.big-depth .when { color: #cfe3ff; font-size: .85rem; }

.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 10px; margin: 0; }
.facts div { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 10px 14px; }
.facts dt { color: var(--muted); font-size: .8rem; }
.facts dd { margin: 0; font-weight: 700; font-size: 1.15rem; }

.trails { display: flex; gap: 8px; flex-wrap: wrap; }
.t { padding: 3px 10px; border-radius: 999px; font-size: .85rem; font-weight: 600; color: #fff; }
.t.easy { background: #2a9d4b; }
.t.medium { background: #2f74d0; }
.t.hard { background: #c0392b; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.chips a { background: var(--card); border: 1px solid var(--line); border-radius: 999px; padding: 4px 12px; text-decoration: none; color: var(--ink); font-size: .9rem; }

.cta { margin: 2.4rem 0; background: linear-gradient(150deg, var(--navy), var(--navy-2)); color: #fff; border-radius: var(--radius); padding: 20px 22px; display: flex; gap: 18px; align-items: center; justify-content: space-between; flex-wrap: wrap; }
.cta h2 { margin: 0 0 .3rem; color: #fff; }
.cta p { margin: 0; color: #d6e6ff; max-width: 560px; }
.store-buttons { display: flex; gap: 10px; flex-wrap: wrap; }
.store-buttons.big { margin: 18px 0 8px; }
.store { background: #fff; color: var(--navy); text-decoration: none; font-weight: 700; padding: 10px 18px; border-radius: 12px; white-space: nowrap; }
.store:hover { background: var(--accent); }

.features { padding-left: 1.1rem; }
.features li { margin: .5rem 0; }
.faq p { margin: 0 0 .6rem; }

.site-footer { border-top: 1px solid var(--line); margin-top: 3rem; padding: 22px 0 30px; }
.credits a, .footer-links a { color: var(--muted); font-size: .9rem; margin-right: 14px; display: inline-block; }
.footer-links { margin: 10px 0; }

@media (max-width: 640px) {
  .highlights { grid-template-columns: 1fr; margin-top: 16px; }
  .hide-sm { display: none; }
  .brand img { height: 40px; }
  .big-depth { text-align: left; width: 100%; }
  th, td { padding: 9px 10px; }
}

.flag { width: 24px; height: 18px; border-radius: 3px; vertical-align: -3px; object-fit: cover; box-shadow: 0 0 0 1px rgba(0,0,0,.08); }
.country-h .flag { width: 28px; height: 21px; vertical-align: -2px; margin-right: 4px; }
.map-box { position: relative; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; margin: 0 0 8px; }
.map { height: 460px; background: #dfe7f1; }
.legend { position: absolute; left: 10px; bottom: 22px; z-index: 500; background: rgba(255,255,255,.92); color: #12213b; border-radius: 999px; padding: 4px 12px; font-size: .78rem; display: flex; gap: 10px; align-items: center; box-shadow: 0 2px 8px rgba(0,0,0,.15); }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 50%; margin-right: 4px; vertical-align: -1px; }
.pin-wrap { background: none; border: 0; }
.pin { display: inline-block; transform: translate(-50%, -50%); white-space: nowrap; font: 700 12px/1 system-ui, sans-serif; padding: 5px 8px; border-radius: 999px; border: 1.5px solid rgba(255,255,255,.9); box-shadow: 0 2px 6px rgba(0,0,0,.3); cursor: pointer; }
.pin-focus { font-size: 14px; padding: 7px 11px; border: 2.5px solid #ffcc33; }
.leaflet-popup-content { font: 14px/1.5 system-ui, sans-serif; }
@media (max-width: 640px) { .map { height: 360px; } .legend { gap: 6px; font-size: .72rem; } }
.chips + .map-box { margin-top: 16px; }
