:root {
  --bg: #fafaf7;
  --ink: #20221f;
  --muted: #656861;
  --line: #dedfd8;
  --accent: #365c45;
  --mono: "Cascadia Code", "SFMono-Regular", Consolas, monospace;
  --sans: "Segoe UI", "Helvetica Neue", Arial, sans-serif;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 24px; }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: var(--sans); -webkit-font-smoothing: antialiased; }
body:has(dialog[open]) { overflow: hidden; }
::selection { background: var(--accent); color: var(--bg); }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; }
a, button { -webkit-tap-highlight-color: transparent; }
a:focus-visible, button:focus-visible, summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 5px; }
img { display: block; max-width: 100%; height: auto; }
h1, h2, p { margin: 0; }
[data-i18n] { white-space: pre-line; }
em { font-family: inherit; font-style: normal; font-weight: inherit; color: var(--ink); }
.mono { font-family: var(--mono); font-size: 10px; font-weight: 400; letter-spacing: .08em; }
.shell { width: min(1400px, calc(100% - 96px)); margin-inline: auto; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
.skip-link { position: fixed; top: -100px; left: 20px; padding: 14px 20px; z-index: 5; color: var(--bg); background: var(--accent); }
.skip-link:focus { top: 15px; }
.site-header { height: 104px; display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.brand { font-size: 36px; font-weight: 750; letter-spacing: -.09em; line-height: 1; }
.brand span { color: var(--accent); }
.site-header nav { display: flex; gap: 28px; margin-left: auto; }
.site-header nav a { font-size: 13px; color: var(--ink); }
.site-header nav a:hover { color: var(--accent); }
.header-actions { display: flex; align-items: center; gap: 26px; margin-left: 30px; }
.language-switch { display: flex; gap: 6px; align-items: center; font-family: var(--mono); font-size: 10px; }
.language-switch > span { color: var(--line); }
.language-switch button { padding: 10px 3px; background: none; border: 0; color: var(--muted); font-size: 10px; }
.language-switch button[aria-pressed="true"] { color: var(--accent); }
.text-link { display: inline-flex; align-items: center; gap: 15px; font-size: 12px; line-height: 1.5; padding-block: 7px; }
.text-link > span[aria-hidden] { color: var(--accent); }
.text-link:hover { color: var(--accent); }
.hero { height: 570px; position: relative; margin-top: 34px; margin-bottom: 48px; }
.hero-photo { position: absolute; right: 0; top: 0; width: 38%; height: 100%; object-fit: cover; object-position: center 60%; }
.hero-topline { position: absolute; top: 34px; left: 0; right: 0; display: flex; justify-content: space-between; gap: 20px; font-size: 10px; color: var(--muted); }
.hero-topline > :last-child { position: absolute; top: 552px; right: 0; background: var(--bg); padding-top: 18px; }
.hero-copy { position: absolute; left: 0; top: 115px; width: 58%; }
.hero h1 { font-size: clamp(90px, 10vw, 150px); font-weight: 600; letter-spacing: -.075em; line-height: .95; }
.hero h1 em { letter-spacing: -.075em; }
.hero-description { font-size: clamp(18px, 2vw, 28px); color: var(--muted); margin-top: 30px; letter-spacing: -.025em; }
.hero-link { margin-top: 30px; font-size: 15px; border-bottom: 1px solid var(--line); }
.hero-coordinate { position: absolute; bottom: 0; left: 0; font-size: 9px; color: var(--muted); }
.about { display: grid; grid-template-columns: 1fr 325px; align-items: center; gap: 70px; padding-block: 50px 70px; }
.about-copy h2 { color: var(--accent); font-size: 9px; }
.about-copy > p { font-size: 24px; line-height: 1.5; max-width: 780px; letter-spacing: -.025em; margin-top: 18px; text-wrap: pretty; }
.about-bottom { display: flex; align-items: center; gap: 25px; margin-top: 24px; }
.quote-label { color: var(--accent); font-size: 9px; }
.about-quote { color: var(--muted); font-size: 12px; font-family: Georgia, "Times New Roman", serif; font-style: italic; }
.telemetry { padding: 22px; border: 1px solid var(--line); background: #f0f1eb; }
.telemetry-header { display: flex; justify-content: space-between; align-items: center; gap: 15px; }
.telemetry-header h2 { font-size: 8px; color: var(--muted); }
.connection-state { font-family: var(--mono); font-size: 8px; display: inline-flex; align-items: center; gap: 7px; color: var(--accent); }
.status-dot { width: 5px; height: 5px; border-radius: 50%; background: currentColor; }
.connection-state[data-state="error"] { color: #a83e27; }
.connection-state[data-state="checking"], .connection-state[data-state="paused"] { color: var(--muted); }
.telemetry-reading { display: flex; gap: 7px; align-items: baseline; margin-top: 13px; }
#latency-value { font-family: var(--mono); font-size: 30px; font-weight: 300; letter-spacing: -.07em; }
.telemetry-reading > .mono { color: var(--muted); font-size: 9px; }
#latency-chart { margin-left: auto; width: 90px; height: 32px; align-self: center; }
.chart-baseline { stroke: var(--line); stroke-width: 1; }
.chart-line { fill: none; stroke: var(--accent); stroke-width: 1.5; stroke-linejoin: round; stroke-linecap: round; }
#measure-button { width: 30px; height: 30px; border-radius: 50%; background: none; border: 1px solid var(--line); color: var(--accent); font-size: 20px; line-height: 1; align-self: center; margin-left: 6px; }
#measure-button:disabled { cursor: wait; opacity: .45; }
.telemetry-note { margin-top: 10px; font-size: 9px; color: var(--muted); line-height: 1.5; }
.outside { border-top: 1px solid var(--line); padding-block: 42px 36px; }
.gallery-header { display: flex; align-items: center; justify-content: space-between; gap: 25px; margin-bottom: 30px; }
.gallery-header h2 { font-size: 44px; font-weight: 500; letter-spacing: -.055em; }
.gallery-header .mono { color: var(--muted); font-size: 8px; }
.gallery-controls { display: flex; justify-content: flex-end; gap: 12px; margin-bottom: 14px; }
.gallery-controls[hidden] { display: none; }
.gallery-controls button { background: none; border: 1px solid var(--line); color: var(--ink); padding: 10px 16px; font-size: 11px; }
.gallery-controls button[aria-pressed="true"] { background: var(--accent); color: var(--bg); }
.gallery-layout { display: grid; grid-template-columns: 1.1fr 1fr; gap: 24px; }
.photo-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); grid-template-rows: repeat(4, 155px); gap: 14px; }
.featured-photo { min-height: 0; }
.featured-photo img { position: absolute; inset: 0; object-position: var(--photo-position, center); }
.photo-grid .photo-card.is-featured { outline: 2px solid var(--accent); outline-offset: 3px; }
.photo-grid .photo-caption { left: 0; right: 0; bottom: 0; min-height: 28px; padding: 6px 0 0; background: var(--bg); }
.photo-grid .photo-caption .mono { display: none; }
.photo-grid .photo-title { font-size: 11px; margin-top: 0; }
.featured-photo .photo-title { font-size: 30px; }
.photo-card { position: relative; overflow: hidden; display: block; background: #e8ebe6; }
.photo-card img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s; }
.photo-grid .photo-card img { position: absolute; inset: 0; height: calc(100% - 34px); }
.photo-card:hover img { transform: scale(1.035); }
.photo-card:focus-visible { outline-offset: 2px; }
.track-card img { object-position: center 85%; }
.covadonga-card img { object-position: center 72%; }
.paddock-card img { object-position: 39% center; }
.quiet-card img { object-position: center 68%; }
.adventure-card img { object-position: center 60%; }
.mtb-coast-card img { object-position: center 85%; }
.disney-card img, .family-card img, .together-card img { object-position: center 65%; }
.photo-caption { position: absolute; bottom: 0; left: 0; right: 0; padding: 18px 20px; z-index: 1; color: var(--ink); background: #fafaf7f0; }
.photo-caption .mono { display: block; font-size: 9px; line-height: 1.6; color: var(--muted); }
.photo-title { display: block; font-size: 22px; line-height: 1.15; letter-spacing: -.035em; margin-top: 6px; text-wrap: balance; }
.photo-expand { position: absolute; top: 12px; right: 12px; z-index: 1; display: grid; place-items: center; width: 27px; height: 27px; border: 0; background: #fafaf7e6; border-radius: 50%; color: var(--ink); font-size: 15px; }
.gallery-footer { display: flex; justify-content: space-between; align-items: center; gap: 25px; margin-top: 20px; }
.hobby-chip { font-family: var(--mono); font-size: 9px; color: var(--muted); line-height: 1.5; }
.contact { padding-block: 55px 70px; display: flex; align-items: center; justify-content: space-between; gap: 25px; }
.contact h2 { font-size: 54px; font-weight: 500; color: var(--ink); letter-spacing: -.055em; }
.contact-link { display: flex; align-items: center; gap: 25px; font-size: 13px; }
.contact-link > span[aria-hidden] { display: grid; place-items: center; width: 48px; height: 48px; font-size: 30px; border: 1px solid var(--line); border-radius: 50%; color: var(--accent); transition: color .2s, background .2s; }
.contact-link:hover > span[aria-hidden] { background: var(--accent); color: var(--bg); }
.site-footer { border-top: 1px solid var(--line); min-height: 70px; display: flex; align-items: center; justify-content: space-between; gap: 20px; color: var(--muted); }
.site-footer .mono { font-size: 8px; }
dialog { padding: 18px; border: 1px solid var(--line); background: var(--bg); color: var(--ink); width: min(1100px, calc(100% - 32px)); max-height: calc(100dvh - 32px); }
dialog::backdrop { background: #20221f99; backdrop-filter: blur(8px); }
.dialog-toolbar { display: flex; justify-content: space-between; align-items: center; gap: 20px; margin-bottom: 12px; color: var(--muted); }
#close-photo { border: 1px solid var(--line); width: 36px; height: 36px; background: none; color: var(--ink); font-size: 26px; }
#expanded-photo { width: 100%; height: min(70dvh, 780px); object-fit: contain; }
#photo-dialog-caption { font-size: 13px; color: var(--muted); margin-top: 15px; line-height: 1.6; }
.noscript-note { padding: 20px; color: var(--muted); font-size: 12px; text-align: center; }
@media (max-width: 1050px) {
  .shell { width: calc(100% - 48px); }
  .about { gap: 30px; grid-template-columns: 1fr 290px; }
  .about-bottom { flex-wrap: wrap; gap: 7px; }
  .gallery-layout { grid-template-columns: 1fr 1fr; }
  .photo-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-template-rows: repeat(6, 125px); }
  .photo-caption { padding: 14px; }
  .photo-title { font-size: 19px; }
}
@media (max-width: 700px) {
  .shell { width: calc(100% - 32px); }
  .site-header { height: 74px; gap: 12px; }
  .brand { font-size: 30px; }
  .site-header nav { gap: 14px; }
  .site-header nav a { font-size: 10px; }
  .header-actions { gap: 12px; margin-left: 0; }
  .header-actions > .text-link { display: none; }
  .hero { height: auto; margin-top: 35px; margin-bottom: 0; display: flex; flex-direction: column; }
  .hero-topline { position: static; order: 0; font-size: 8px; gap: 12px; }
  .hero-topline > :last-child { display: none; }
  .hero-copy { position: static; order: 1; width: 100%; margin-block: 34px 36px; }
  .hero h1 { font-size: clamp(80px, 21vw, 125px); }
  .hero-photo { position: static; order: 2; width: 100%; height: 340px; object-position: center 62%; }
  .hero-description { font-size: 18px; margin-top: 20px; }
  .hero-link { font-size: 13px; margin-top: 20px; }
  .hero-coordinate { display: none; }
  .about { grid-template-columns: 1fr; gap: 30px; padding-block: 36px 45px; }
  .about-copy > p { font-size: 20px; margin-top: 14px; }
  .about-bottom { gap: 8px; margin-top: 10px; }
  .about-quote { font-size: 11px; }
  .telemetry { padding: 14px 16px; }
  .telemetry-reading { margin-top: 8px; }
  #latency-chart { width: 110px; }
  .telemetry-note { margin-top: 7px; }
  .gallery-header { align-items: start; flex-direction: column; gap: 8px; margin-bottom: 16px; }
  .gallery-header h2 { font-size: 34px; }
  .gallery-header .mono { font-size: 7px; }
  .gallery-controls { justify-content: flex-start; }
  .gallery-layout { grid-template-columns: 1fr; gap: 12px; }
  .featured-photo { min-height: 0; height: 330px; }
  .featured-photo .photo-title { font-size: 28px; }
  .photo-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); grid-template-rows: repeat(4, 135px); gap: 10px; }
  .photo-grid .photo-caption { padding: 5px 0 0; min-height: 40px; }
  .photo-grid .photo-card img { height: calc(100% - 44px); }
  .photo-grid .photo-title { font-size: 10px; }
  .photo-caption { padding: 12px; }
  .photo-caption .mono { font-size: 7px; letter-spacing: .03em; }
  .photo-expand { top: 10px; right: 10px; width: 24px; height: 24px; font-size: 13px; }
  .gallery-footer { flex-direction: column; align-items: start; gap: 12px; margin-top: 16px; }
  .contact { padding-block: 24px 40px; gap: 16px; }
  .contact h2 { font-size: 34px; }
  .contact-link { gap: 10px; font-size: 11px; }
  .contact-link > span[aria-hidden] { width: 34px; height: 34px; font-size: 23px; flex-shrink: 0; }
  .site-footer { flex-wrap: wrap; padding-block: 18px; min-height: 65px; gap: 12px; }
  .site-footer .mono { font-size: 7px; }
  dialog { padding: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
}
