/* ════════════════════════════════════════════════════════════════════
   ALGARVE DAILY — The Azulejo Gazette
   Sun-bleached Portuguese broadsheet · cobalt tile geometry · live data
   Fraunces (display+text, variable opsz) · Sometype Mono (data/agate)
   ════════════════════════════════════════════════════════════════════ */

:root {
    --paper: #FAF3E3;
    --paper-deep: #F2E8D0;
    --card: #FFFDF4;
    --ink: #22303A;
    --ink-soft: #6B6049;
    --cobalt: #19549E;
    --cobalt-deep: #0E3567;
    --terracotta: #C24E2D;
    --terracotta-text: #A84527; /* darker shade for small text — WCAG AA on paper */
    --clay-deep: #8C2F1C;
    --sea: #11695A;
    --citrus: #DF9A2E;
    --rule: #D8CBB0;
    --rule-strong: #B7A57F;
    --alert: #BD3326;
    --night: #102542;
    --night-text: #F2E7C9;
    --night-glow: #FFE3A1;
    --glaze: rgba(25, 84, 158, .07);
    --font-display: 'Fraunces', Georgia, 'Times New Roman', serif;
    --font-mono: 'Sometype Mono', 'Courier New', monospace;
    --sheet-w: 1140px;
    --pad: clamp(16px, 4vw, 40px);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

[hidden] { display: none !important; }

html { scroll-behavior: smooth; scroll-padding-top: 64px; }

body {
    font-family: var(--font-display);
    font-optical-sizing: auto;
    background:
        radial-gradient(1200px 480px at 50% -120px, rgba(223, 154, 46, .10), transparent 70%),
        repeating-linear-gradient(0deg, rgba(34, 48, 58, .014) 0 1px, transparent 1px 3px),
        var(--paper);
    color: var(--ink);
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
}

a { color: inherit; }
img { display: block; max-width: 100%; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }

.skip-link {
    position: absolute; left: -9999px; top: 0;
    background: var(--ink); color: var(--paper);
    padding: 10px 18px; z-index: 200; font-family: var(--font-mono); font-size: 13px;
}
.skip-link:focus { left: 12px; top: 12px; }

/* ── Azulejo frieze band ─────────────────────────────────────────── */
.frieze {
    height: 18px;
    border-bottom: 1px solid var(--rule-strong);
    overflow: hidden;
    line-height: 0;
}
.frieze--flip { border-bottom: 0; border-top: 1px solid var(--rule-strong); transform: scaleY(-1); }
.frieze .az-tile { width: 100%; height: 18px; }

/* ════ MASTHEAD ════════════════════════════════════════════════════ */
.masthead {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 18px;
    max-width: var(--sheet-w);
    margin: 0 auto;
    padding: clamp(18px, 3.5vw, 34px) var(--pad) clamp(14px, 2.5vw, 24px);
}

.masthead-ear { font-family: var(--font-mono); font-size: 11px; letter-spacing: .12em; color: var(--ink-soft); }
.masthead-ear--left { text-transform: uppercase; }
.masthead-ear--right { text-align: right; }
.ear-dateline { font-weight: 700; color: var(--ink); }
.ear-sub { margin-top: 3px; }

.ear-live { font-size: 12px; letter-spacing: .06em; white-space: nowrap; }
.live-dot {
    display: inline-block; width: 7px; height: 7px; border-radius: 50%;
    background: var(--sea); margin-right: 6px; vertical-align: 1px;
    animation: pulse 2.4s ease-in-out infinite;
}
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: .35; } }

.ear-social { margin-top: 8px; display: flex; gap: 12px; justify-content: flex-end; }
.ear-social a {
    display: inline-flex; align-items: center; justify-content: center;
    width: 34px; height: 34px;
    border: 1px solid var(--rule-strong); border-radius: 6px;
    color: var(--ink); background: var(--card);
    transition: color .18s, border-color .18s, transform .18s;
}
.ear-social a:hover { color: var(--cobalt); border-color: var(--cobalt); transform: translateY(-2px); }

.masthead-title { text-align: center; }
.masthead-kicker {
    display: block;
    font-family: var(--font-mono); font-size: 10.5px;
    letter-spacing: .34em; text-transform: uppercase;
    color: var(--terracotta-text);
    margin-bottom: 6px;
}
.masthead-name {
    font-size: clamp(44px, 8.5vw, 92px);
    font-weight: 900;
    font-variation-settings: 'opsz' 144;
    letter-spacing: -.015em;
    line-height: .94;
    white-space: nowrap;
}
.masthead-name a { text-decoration: none; }
.masthead-sun {
    display: inline-block;
    width: .14em; height: .14em;
    margin: 0 .085em;
    vertical-align: .32em;
    border-radius: 50%;
    background: var(--citrus);
    box-shadow: 0 0 0 .035em var(--terracotta);
}
.masthead-edition {
    display: inline-block;
    margin-top: 10px;
    font-family: var(--font-mono); font-size: 11px;
    letter-spacing: .18em; text-transform: uppercase;
    color: var(--ink-soft);
    border-top: 1px solid var(--rule-strong);
    border-bottom: 3px double var(--rule-strong);
    padding: 5px 18px 6px;
}

/* ════ INDICATORS RIBBON (ticker) ══════════════════════════════════ */
.ticker {
    border-top: 1px solid var(--rule-strong);
    border-bottom: 1px solid var(--rule-strong);
    background: var(--paper-deep);
    overflow: hidden;
    position: relative;
}
.ticker::before, .ticker::after {
    content: ''; position: absolute; top: 0; bottom: 0; width: 60px; z-index: 2; pointer-events: none;
}
.ticker::before { left: 0; background: linear-gradient(90deg, var(--paper-deep), transparent); }
.ticker::after { right: 0; background: linear-gradient(270deg, var(--paper-deep), transparent); }

.ticker-track { display: flex; width: max-content; animation: ticker 52s linear infinite; }
.ticker:hover .ticker-track, .ticker:focus-within .ticker-track { animation-play-state: paused; }
@keyframes ticker { from { transform: translateX(0); } to { transform: translateX(-50%); } }

.ticker-set { display: flex; flex-shrink: 0; }
.tick {
    display: inline-flex; align-items: baseline; gap: 8px;
    padding: 11px 26px;
    font-family: var(--font-mono); font-size: 12px;
    text-decoration: none; white-space: nowrap;
    border-right: 1px solid var(--rule);
}
.tick:hover .tick-val { color: var(--terracotta); }
.tick-label { text-transform: uppercase; letter-spacing: .14em; font-size: 10.5px; color: var(--ink-soft); }
.tick-val { font-weight: 700; letter-spacing: .04em; color: var(--cobalt-deep); transition: color .15s; }

/* ════ SECTION NAV (paper tabs) ════════════════════════════════════ */
.paper-nav {
    position: sticky; top: 0; z-index: 100;
    display: flex; align-items: center; gap: 14px;
    background: rgba(250, 243, 227, .9);
    backdrop-filter: blur(14px) saturate(150%);
    -webkit-backdrop-filter: blur(14px) saturate(150%);
    border-bottom: 1px solid var(--rule-strong);
    padding: 0 var(--pad);
}
.pnav-mark {
    display: inline-flex; align-items: center; justify-content: center;
    position: relative; width: 34px; height: 34px; flex-shrink: 0;
    border: 1px solid var(--rule-strong); border-radius: 6px; overflow: hidden;
    text-decoration: none;
    opacity: 0; transform: translateY(4px); transition: opacity .25s, transform .25s;
}
.paper-nav.is-stuck .pnav-mark { opacity: 1; transform: none; }
.pnav-mark .az-tile { position: absolute; inset: 0; width: 100%; height: 100%; opacity: .9; }
.pnav-mark span {
    position: relative; font-family: var(--font-display); font-weight: 900; font-size: 14px;
    color: var(--card); text-shadow: 0 1px 4px rgba(14, 53, 103, .9);
}
.pnav-links {
    display: flex; align-items: center; gap: 2px;
    overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch;
}
.pnav-links::-webkit-scrollbar { display: none; }
.pnav-links a {
    font-family: var(--font-mono); font-size: 11.5px;
    letter-spacing: .12em; text-transform: uppercase;
    text-decoration: none; white-space: nowrap;
    padding: 15px 13px 13px;
    border-bottom: 2px solid transparent;
    color: var(--ink-soft);
    transition: color .15s, border-color .15s;
}
.pnav-links a:hover { color: var(--cobalt); border-bottom-color: var(--cobalt); }
.pnav-rule { width: 1px; height: 18px; background: var(--rule-strong); margin: 0 8px; flex-shrink: 0; }

/* ════ SHEET ═══════════════════════════════════════════════════════ */
.sheet { max-width: var(--sheet-w); margin: 0 auto; padding: 0 var(--pad) 60px; }

.db-error {
    margin: 28px 0; padding: 20px;
    border: 2px solid var(--alert); background: var(--card);
}
.db-error .error-text { font-family: var(--font-mono); font-size: 12px; color: var(--alert); margin-top: 8px; }

/* Section flags */
.section-flag {
    display: flex; align-items: baseline; gap: 14px;
    margin: clamp(40px, 6vw, 64px) 0 22px;
}
.section-flag h2 {
    font-size: clamp(24px, 3.2vw, 34px);
    font-weight: 900;
    font-variation-settings: 'opsz' 72;
    letter-spacing: -.01em;
    white-space: nowrap;
}
.section-flag-pt {
    font-family: var(--font-mono); font-size: 11px; font-weight: 700;
    letter-spacing: .22em; text-transform: uppercase;
    color: var(--card); background: var(--cobalt);
    padding: 4px 10px;
    align-self: center;
}
.section-flag-rule { flex: 1; border-top: 1px solid var(--rule-strong); align-self: center; min-width: 30px; }
.section-flag--quiet h2 { font-weight: 700; }
.section-flag-gloss { font-style: italic; font-weight: 400; font-size: .55em; color: var(--ink-soft); letter-spacing: 0; }
.section-flag--quiet::after { content: ''; flex: 1; border-top: 1px solid var(--rule); align-self: center; min-width: 30px; }
.section-flag-note {
    font-family: var(--font-mono); font-size: 11px; letter-spacing: .1em;
    text-transform: uppercase; color: var(--ink-soft); white-space: nowrap;
}
a.section-flag-note { text-decoration: none; color: var(--terracotta-text); }
a.section-flag-note:hover { text-decoration: underline; }

/* Stamps (event type chips) */
.stamp {
    display: inline-block;
    font-family: var(--font-mono); font-size: 10px; font-weight: 700;
    letter-spacing: .16em; text-transform: uppercase;
    padding: 3px 9px;
    color: var(--card);
    background: var(--ink);
}
.stamp--clay { background: var(--terracotta); }
.stamp--sea { background: var(--sea); }
.stamp--brass { background: var(--citrus); color: var(--ink); }
.stamp--cobalt { background: var(--cobalt); }
.stamp--ink { background: var(--ink); }
.stamp--free { background: var(--sea); }

.kicker {
    font-family: var(--font-mono); font-size: 11px; font-weight: 700;
    letter-spacing: .2em; text-transform: uppercase; color: var(--terracotta-text);
}
.kicker--cobalt { color: var(--cobalt); }

/* ════ EDITION NOTE (holiday) ══════════════════════════════════════ */
.edition-note {
    display: flex; gap: 14px; align-items: flex-start;
    margin: 26px 0 0;
    padding: 14px 18px;
    border: 1px solid var(--note-color, var(--rule-strong));
    background: color-mix(in srgb, var(--note-color, var(--terracotta)) 6%, var(--card));
    font-size: 15px;
}
.edition-note-stamp { font-size: 26px; line-height: 1; }
.edition-note-kicker {
    display: block;
    font-family: var(--font-mono); font-size: 10px; letter-spacing: .2em;
    text-transform: uppercase; color: var(--ink-soft); margin-bottom: 3px;
}
.edition-note a { color: var(--cobalt); }

/* ════ FRONT PAGE LEAD ═════════════════════════════════════════════ */
.lead {
    display: grid;
    grid-template-columns: 7fr 5fr;
    grid-template-areas: 'copy art' 'decks decks';
    gap: clamp(20px, 3.5vw, 44px);
    padding: clamp(28px, 4.5vw, 52px) 0 clamp(22px, 3vw, 34px);
    border-bottom: 3px double var(--rule-strong);
}
.lead-copy { grid-area: copy; align-self: center; }
.lead-headline {
    font-size: clamp(32px, 5.2vw, 58px);
    font-weight: 900;
    font-variation-settings: 'opsz' 100;
    line-height: 1.04;
    letter-spacing: -.018em;
    margin: 10px 0 16px;
    text-wrap: balance;
}
.lead-standfirst {
    font-size: clamp(16px, 1.8vw, 19px);
    font-variation-settings: 'opsz' 12;
    color: var(--ink-soft);
    max-width: 56ch;
}
.lead-standfirst::first-letter {
    font-weight: 900; color: var(--terracotta);
    font-size: 2.6em; float: left; line-height: .82;
    padding: 3px 8px 0 0;
}
.lead-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-top: 18px; }
.lead-where { font-family: var(--font-mono); font-size: 11.5px; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-soft); }
.lead-cta {
    display: inline-block; margin-top: 18px;
    font-family: var(--font-mono); font-size: 13px; font-weight: 700;
    letter-spacing: .06em; color: var(--cobalt);
    text-decoration: none;
    background: linear-gradient(var(--cobalt), var(--cobalt)) no-repeat 0 100% / 0% 2px;
    transition: background-size .3s;
    padding-bottom: 3px;
}
.lead-cta:hover { background-size: 100% 2px; }

.lead-art { grid-area: art; position: relative; }
.lead-art img, .lead-art .az-tile {
    width: 100%; aspect-ratio: 4 / 3.4; object-fit: cover;
    border: 1px solid var(--rule-strong);
    box-shadow: 8px 8px 0 var(--glaze), 8px 8px 0 1px var(--rule);
}
.lead-art .az-tile { height: auto; }
.lead-art figcaption {
    margin-top: 10px;
    font-family: var(--font-mono); font-size: 10.5px;
    letter-spacing: .1em; text-transform: uppercase; color: var(--ink-soft);
}

.lead-decks {
    grid-area: decks;
    display: grid; grid-template-columns: 1fr 1fr; gap: 28px;
    border-top: 1px solid var(--rule);
    padding-top: 18px;
}
.deck { position: relative; padding-left: 0; }
.deck + .deck { border-left: 1px solid var(--rule); padding-left: 28px; }
.deck h3 { font-size: 19px; font-weight: 700; line-height: 1.3; margin-top: 6px; text-wrap: balance; }
.deck-link {
    display: inline-block; margin-top: 6px;
    font-family: var(--font-mono); font-size: 11.5px; color: var(--terracotta-text);
    text-decoration: none;
}
.deck-link:hover { text-decoration: underline; }

/* ════ ALMANAQUE ═══════════════════════════════════════════════════ */
.alm-grid {
    display: grid;
    grid-template-columns: 1fr 220px 230px;
    gap: clamp(18px, 2.5vw, 30px);
    align-items: stretch;
}
.alm-week {
    display: grid; grid-template-columns: repeat(7, 1fr);
    border: 1px solid var(--rule-strong);
    background: var(--card);
}
.alm-day {
    text-align: center; padding: 16px 4px 14px;
    border-right: 1px solid var(--rule);
    display: flex; flex-direction: column; gap: 4px; justify-content: center;
}
.alm-day:last-child { border-right: 0; }
.alm-day--today { background: var(--paper-deep); box-shadow: inset 0 3px 0 var(--citrus); }
.alm-day-name { font-family: var(--font-mono); font-size: 10px; letter-spacing: .16em; text-transform: uppercase; color: var(--ink-soft); }
.alm-day-icon { font-size: 21px; line-height: 1.2; }
.alm-day-hi { font-family: var(--font-mono); font-size: 15px; font-weight: 700; }
.alm-day-lo { font-family: var(--font-mono); font-size: 11px; color: var(--ink-soft); }

.alm-side { display: flex; flex-direction: column; justify-content: space-between; gap: 12px; }
.alm-readings {
    border: 1px solid var(--rule-strong); background: var(--card);
    padding: 6px 16px; flex: 1;
    display: flex; flex-direction: column; justify-content: center;
}
.alm-readings > div {
    display: flex; justify-content: space-between; align-items: baseline;
    padding: 7px 0;
    border-bottom: 1px dotted var(--rule);
}
.alm-readings > div:last-child { border-bottom: 0; }
.alm-readings dt { font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-soft); }
.alm-readings dd { font-family: var(--font-mono); font-size: 14px; font-weight: 700; color: var(--cobalt-deep); }
.alm-more {
    font-family: var(--font-mono); font-size: 11.5px; letter-spacing: .06em;
    color: var(--terracotta-text); text-decoration: none;
}
.alm-more:hover { text-decoration: underline; }

.postal {
    position: relative;
    background: #fff;
    padding: 10px 10px 12px;
    border: 1px solid var(--rule-strong);
    box-shadow: 0 8px 18px rgba(34, 48, 58, .12);
    transform: rotate(-1.6deg);
    transition: transform .3s ease;
}
.postal:hover { transform: rotate(0deg) scale(1.015); }
.postal-photo { overflow: hidden; }
.postal-photo img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; }
.postal-mark { position: absolute; top: 16px; right: 16px; text-align: right; }
.postal-stamp {
    display: inline-block; width: 34px; height: 40px;
    background: #fff; padding: 3px;
    border: 1px dashed var(--rule-strong);
    box-shadow: 0 2px 6px rgba(0, 0, 0, .2);
}
.postal-stamp .az-tile { width: 100%; height: 100%; }
.postal-cancel {
    display: inline-block; margin-top: 4px;
    font-family: var(--font-mono); font-size: 9.5px; letter-spacing: .1em;
    color: #FDF7E5; background: rgba(16, 37, 66, .68);
    padding: 2px 6px;
}
.postal figcaption {
    margin-top: 8px;
    font-family: var(--font-mono); font-size: 10px; letter-spacing: .08em;
    text-transform: uppercase; color: var(--ink-soft); text-align: center;
}

/* ════ CARTAZ · WHAT'S ON ══════════════════════════════════════════ */
.date-strip {
    display: flex; gap: 6px;
    overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch;
    padding-bottom: 6px; margin-bottom: 16px;
}
.date-strip::-webkit-scrollbar { display: none; }
.dchip {
    flex: 0 0 auto;
    display: flex; flex-direction: column; align-items: center; gap: 1px;
    min-width: 58px; padding: 9px 8px 7px;
    border: 1px solid var(--rule-strong);
    background: var(--card);
    transition: border-color .15s, background .15s, transform .15s;
}
.dchip:hover { border-color: var(--cobalt); transform: translateY(-2px); }
.dchip--active { background: var(--cobalt-deep); border-color: var(--cobalt-deep); color: var(--card); }
.dchip-dow { font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase; opacity: .8; }
.dchip-num { font-family: var(--font-display); font-size: 21px; font-weight: 900; line-height: 1.1; }
.dchip-dots { display: flex; gap: 3px; height: 5px; margin-top: 3px; }
.dchip-dots i { width: 5px; height: 5px; border-radius: 50%; background: var(--cobalt); }
.dchip--active .dchip-dots i { background: var(--citrus); }
.dchip-dots i.dot-hot { background: var(--terracotta); }

.dstrip-legend {
    font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .06em;
    color: var(--ink-soft); margin: 2px 0 14px;
}
.dstrip-legend i { display: inline-block; width: 5px; height: 5px; border-radius: 50%; background: var(--cobalt); margin: 0 1px; vertical-align: 1px; }
.dstrip-legend i.dot-hot { background: var(--terracotta); }

.cartaz-filters {
    display: flex; flex-wrap: wrap; align-items: center; gap: 10px;
    margin-bottom: 20px;
}
.city-select {
    font-family: var(--font-mono); font-size: 12px;
    padding: 7px 10px;
    border: 1px solid var(--rule-strong); background: var(--card); color: var(--ink);
    max-width: 220px;
}
.city-select:focus { outline: 2px solid var(--cobalt); outline-offset: 1px; }
.type-pills { display: flex; flex-wrap: wrap; gap: 6px; }
.type-pill {
    font-family: var(--font-mono); font-size: 11px; letter-spacing: .08em;
    text-transform: uppercase;
    padding: 6px 12px;
    border: 1px solid var(--rule-strong); background: var(--card);
    transition: all .15s;
}
.type-pill:hover { border-color: var(--cobalt); color: var(--cobalt); }
.type-pill.is-active { background: var(--cobalt); border-color: var(--cobalt); color: var(--card); }
.cartaz-count { margin-left: auto; font-family: var(--font-mono); font-size: 11.5px; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-soft); }

.cards {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 22px;
}
.card {
    position: relative; /* anchors the stretched card link */
    display: flex; flex-direction: column;
    background: var(--card);
    border: 1px solid var(--rule-strong);
    transition: transform .18s ease, box-shadow .18s ease;
}
/* The whole card is the tap target, not just the small Details link */
.card .card-link::after { content: ''; position: absolute; inset: 0; }
.card:hover { transform: translateY(-3px); box-shadow: 0 8px 18px rgba(34, 48, 58, .10); }
.card-art {
    position: relative; aspect-ratio: 16 / 9.5; overflow: hidden;
    border-bottom: 1px solid var(--rule);
}
.card-art img, .card-art .az-tile { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.card-art::after {
    content: ''; position: absolute; inset: 0;
    background: linear-gradient(115deg, transparent 38%, rgba(255, 255, 255, .26) 50%, transparent 62%);
    background-size: 280% 100%; background-position: 110% 0;
    pointer-events: none;
}
.card:hover .card-art::after { transition: background-position .7s ease; background-position: -40% 0; }
.card-art .stamp { position: absolute; top: 10px; left: 10px; z-index: 2; }
.card-art .card-free { left: auto; right: 10px; }
.card-body { display: flex; flex-direction: column; gap: 7px; padding: 14px 16px 16px; flex: 1; }
.card-title { font-size: 17.5px; font-weight: 700; line-height: 1.32; text-wrap: balance; }
.card-agate { font-family: var(--font-mono); font-size: 11.5px; letter-spacing: .08em; color: var(--ink-soft); }
.card-link {
    margin-top: auto; align-self: flex-start;
    font-family: var(--font-mono); font-size: 11.5px; font-weight: 700;
    color: var(--terracotta-text); text-decoration: none;
}
.card-link:hover { text-decoration: underline; }
.cards-empty, .trad-empty, .wire-empty { color: var(--ink-soft); font-style: italic; padding: 24px 0; }

.more-btn {
    display: block; margin: 24px auto 0;
    font-family: var(--font-mono); font-size: 12px; font-weight: 700;
    letter-spacing: .12em; text-transform: uppercase;
    padding: 12px 28px;
    border: 1px solid var(--ink); background: var(--card);
    transition: all .15s;
}
.more-btn:hover { background: var(--ink); color: var(--paper); }

/* ════ AIRPORT BOARD (the one dark surface) ════════════════════════ */
.board { margin-top: clamp(48px, 7vw, 80px); }
.board-frame {
    background: var(--night);
    color: var(--night-text);
    border: 1px solid var(--cobalt-deep);
    outline: 4px solid var(--paper-deep);
    outline-offset: -10px;
    box-shadow: 0 24px 60px rgba(14, 53, 103, .28);
    padding: clamp(22px, 3.5vw, 38px) clamp(18px, 3.5vw, 40px);
}
.board-head {
    display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end;
    gap: 16px;
    border-bottom: 1px solid rgba(242, 231, 201, .22);
    padding-bottom: 18px;
}
.board-kicker {
    font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .26em;
    text-transform: uppercase; color: var(--citrus);
}
.board-head h2 {
    font-size: clamp(26px, 3.6vw, 40px);
    font-weight: 900; font-variation-settings: 'opsz' 96;
    color: #FDF7E5;
    margin-top: 4px;
}
.board-iata {
    font-family: var(--font-mono); font-size: .42em; font-weight: 700;
    letter-spacing: .14em; vertical-align: .5em;
    background: var(--citrus); color: var(--night);
    padding: 3px 8px;
}
.board-queue {
    display: grid; grid-template-columns: auto auto; gap: 2px 14px; align-items: baseline;
    font-family: var(--font-mono);
    text-align: right;
}
.board-queue-label { font-size: 10px; letter-spacing: .18em; text-transform: uppercase; opacity: .65; }
.board-queue-val { font-size: 17px; font-weight: 700; color: var(--night-glow); }
.board-crowd {
    grid-column: 1 / -1; justify-self: end; margin-top: 6px;
    font-size: 10.5px; font-weight: 700; letter-spacing: .16em; text-transform: uppercase;
    padding: 4px 10px;
    background: rgba(242, 231, 201, .12);
    color: var(--night-text);
}
.board-crowd.crowd-hot { background: var(--terracotta); color: #FFF4DE; }
.board-crowd.crowd-ok { background: var(--sea); color: #EFFFF8; }
.board-queue-src { grid-column: 1 / -1; justify-self: end; font-size: 9.5px; letter-spacing: .12em; text-transform: uppercase; opacity: .55; margin-top: 3px; }

.board-flights { display: grid; gap: 1px; margin-top: 18px; }
.board-row {
    display: grid;
    grid-template-columns: 130px 90px 1fr auto;
    gap: 12px; align-items: baseline;
    font-family: var(--font-mono);
    padding: 11px 12px;
    background: rgba(242, 231, 201, .05);
}
.bf-dir { font-size: 10px; letter-spacing: .2em; text-transform: uppercase; opacity: .65; }
.bf-flight { font-size: 13px; font-weight: 700; color: var(--citrus); }
.bf-city { font-size: 13.5px; letter-spacing: .04em; color: #FDF7E5; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bf-time { font-size: 16px; font-weight: 700; color: var(--night-glow); }
.board-row.is-flipping { animation: flip .32s ease; }
@keyframes flip { 0% { transform: rotateX(82deg); opacity: 0; } 100% { transform: rotateX(0); opacity: 1; } }

.board-chart { margin-top: 26px; }
.board-chart-head {
    display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px;
    font-family: var(--font-mono); font-size: 10.5px;
    letter-spacing: .16em; text-transform: uppercase; opacity: .85;
    margin-bottom: 12px;
}
.board-legend { display: inline-flex; align-items: center; gap: 7px; }
.leg-bar { width: 12px; height: 8px; background: linear-gradient(180deg, var(--citrus), var(--terracotta)); display: inline-block; }
.leg-dot { width: 7px; height: 7px; border: 1.5px dotted var(--night-text); border-radius: 50%; display: inline-block; }

.board-bars {
    display: grid; grid-template-columns: repeat(24, 1fr); gap: 3px;
    align-items: end;
    height: 130px;
    border-bottom: 1px solid rgba(242, 231, 201, .3);
    background: repeating-linear-gradient(0deg, rgba(242, 231, 201, .05) 0 1px, transparent 1px 32px);
}
.bbar-col { position: relative; height: 100%; display: flex; align-items: flex-end; }
.bbar {
    display: block; width: 100%; height: 100%;
    transform-origin: bottom;
    transform: scaleY(max(var(--hf, 0), 0.015));
    background: linear-gradient(180deg, var(--citrus), var(--terracotta));
    opacity: .92;
    transition: transform .6s cubic-bezier(.22, 1, .36, 1);
}
.bbar-col.is-now .bbar { box-shadow: 0 0 12px rgba(255, 227, 161, .65); }
.bbar-col.is-now::before {
    content: 'now'; position: absolute; top: -16px; left: 50%; transform: translateX(-50%);
    font-family: var(--font-mono); font-size: 8.5px; letter-spacing: .12em; text-transform: uppercase;
    color: var(--night-glow);
}
.bdot {
    position: absolute; left: 50%; bottom: var(--h, 0%);
    width: 5px; height: 5px; margin-left: -2.5px; margin-bottom: -2px;
    border: 1.5px solid rgba(242, 231, 201, .75); border-radius: 50%;
    background: var(--night);
}
.board-hours {
    display: flex; justify-content: space-between;
    font-family: var(--font-mono); font-size: 10.5px; opacity: .6;
    margin-top: 5px;
}
.board-note { font-family: var(--font-mono); font-size: 11px; opacity: .7; margin-top: 14px; }

.board-outlook { margin-top: 20px; display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.board-outlook-label { font-family: var(--font-mono); font-size: 10px; letter-spacing: .2em; text-transform: uppercase; opacity: .65; }
.board-outlook-chips { display: flex; gap: 8px; flex-wrap: wrap; }
.board-outlook-chips span {
    font-family: var(--font-mono); font-size: 10.5px;
    padding: 5px 10px;
    background: rgba(242, 231, 201, .08);
    border: 1px solid rgba(242, 231, 201, .18);
}
.board-foot {
    display: flex; justify-content: space-between; align-items: baseline; flex-wrap: wrap; gap: 10px;
    margin-top: 24px; padding-top: 14px;
    border-top: 1px solid rgba(242, 231, 201, .22);
    font-family: var(--font-mono); font-size: 11px; letter-spacing: .1em; text-transform: uppercase;
    opacity: .85;
}
.board-foot a { color: var(--citrus); text-decoration: none; }
.board-foot a:hover { text-decoration: underline; }

/* ════ INDICADORES ═════════════════════════════════════════════════ */
.ind-grid {
    display: grid; grid-template-columns: 5fr 7fr; gap: clamp(24px, 4vw, 48px);
    align-items: center;
    background: var(--card);
    border: 1px solid var(--rule-strong);
    padding: clamp(22px, 3.5vw, 40px);
}
.ind-word { display: block; font-size: clamp(18px, 2vw, 24px); font-style: italic; font-weight: 400; color: var(--ink-soft); }
.ind-label {
    display: block;
    font-size: clamp(54px, 7vw, 88px);
    font-weight: 900; font-variation-settings: 'opsz' 144;
    line-height: .95; letter-spacing: -.02em;
    color: var(--terracotta);
    text-transform: uppercase;
    margin: 4px 0 10px;
}
.ind-score { font-family: var(--font-mono); font-size: 12px; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-soft); }
.ind-score b { font-size: 18px; color: var(--cobalt-deep); }
.ind-yoy { margin-top: 14px; font-size: 14.5px; color: var(--ink-soft); max-width: 38ch; }
.ind-yoy .up { color: var(--terracotta-text); font-weight: 700; }
.ind-yoy .down { color: var(--sea); font-weight: 700; }
.ind-components { display: flex; gap: 22px; margin-top: 16px; }
.ind-components div { display: flex; flex-direction: column; gap: 2px; }
.ind-components dt { font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-soft); }
.ind-components dd { font-family: var(--font-mono); font-size: 15px; font-weight: 700; color: var(--cobalt-deep); }

.ind-bars {
    display: grid; grid-template-columns: repeat(12, 1fr); gap: 6px;
    align-items: end; height: 170px;
    border-bottom: 2px solid var(--ink);
    background: repeating-linear-gradient(0deg, rgba(34, 48, 58, .05) 0 1px, transparent 1px 42px);
}
.ibar-col { display: flex; flex-direction: column; justify-content: flex-end; height: 100%; position: relative; }
.ibar {
    display: block; width: 100%; height: 100%;
    transform-origin: bottom;
    transform: scaleY(max(var(--hf, 0.03), 0.02));
    background: var(--cobalt);
    transition: transform .7s cubic-bezier(.22, 1, .36, 1);
}
.ibar-col--future .ibar { opacity: .3; }
.ibar-col--now .ibar { background: var(--citrus); outline: 1.5px solid var(--ink); }
.ibar-col--now::after {
    content: '▾'; position: absolute; top: -20px; left: 50%; transform: translateX(-50%);
    color: var(--terracotta); font-size: 13px;
}
.ibar-m {
    position: absolute; bottom: -22px; left: 0; right: 0; text-align: center;
    font-family: var(--font-mono); font-size: 10.5px; color: var(--ink-soft);
}
.ind-chart figcaption {
    margin-top: 32px;
    font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .1em;
    text-transform: uppercase; color: var(--ink-soft);
}

/* ════ O FIO · NEWS WIRE ═══════════════════════════════════════════ */
.wire { list-style: none; position: relative; max-width: 820px; }
.wire::before {
    content: ''; position: absolute; top: 6px; bottom: 0; left: 92px;
    border-left: 2px solid var(--cobalt);
    opacity: .55;
}
.wire-item {
    display: grid; grid-template-columns: 92px 1fr; gap: 26px;
    padding: 18px 0;
    border-bottom: 1px solid var(--rule);
}
.wire-time {
    position: relative; text-align: right;
    font-family: var(--font-mono); font-size: 11px; color: var(--ink-soft);
    padding-top: 3px;
}
.wire-node {
    position: absolute; right: -6px; top: 7px;
    width: 9px; height: 9px; border-radius: 50%;
    background: var(--paper); border: 2px solid var(--cobalt);
}
.wire-tags { display: flex; gap: 8px; align-items: baseline; margin-bottom: 5px; }
.wire-tag {
    font-family: var(--font-mono); font-size: 9.5px; font-weight: 700;
    letter-spacing: .18em; text-transform: uppercase;
    color: var(--cobalt);
}
.wire-translated {
    font-family: var(--font-mono); font-size: 9px; letter-spacing: .12em; text-transform: uppercase;
    color: var(--sea); border: 1px solid currentColor; padding: 1px 6px;
}
.wire-headline { font-size: 20px; font-weight: 700; line-height: 1.32; text-wrap: balance; }
.wire-headline a {
    text-decoration: none;
    background: linear-gradient(var(--cobalt), var(--cobalt)) no-repeat 0 100% / 0% 2px;
    transition: background-size .3s;
}
.wire-headline a:hover { background-size: 100% 2px; color: var(--cobalt-deep); }
.wire-summary { margin-top: 6px; font-size: 14.5px; color: var(--ink-soft); max-width: 62ch; }
.wire-source {
    display: inline-block; margin-top: 8px;
    font-family: var(--font-mono); font-size: 11px; letter-spacing: .14em; color: var(--ink-soft);
}
.wire-item.is-new { animation: wireIn .5s ease both; }
@keyframes wireIn { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }

.wire-sentinel { height: 60px; display: flex; align-items: center; justify-content: center; }
.wire-loading { display: inline-flex; gap: 6px; }
.wire-loading i {
    width: 8px; height: 8px; border-radius: 50%;
    background: var(--cobalt); animation: dotty 1s ease-in-out infinite;
}
.wire-loading i:nth-child(2) { animation-delay: .15s; }
.wire-loading i:nth-child(3) { animation-delay: .3s; }
@keyframes dotty { 0%, 100% { opacity: .25; transform: translateY(0); } 50% { opacity: 1; transform: translateY(-4px); } }
.wire-end {
    text-align: center; padding: 26px 0 4px;
    font-family: var(--font-mono); font-size: 11px; letter-spacing: .22em;
    text-transform: uppercase; color: var(--ink-soft);
}

/* ════ TRADIÇÕES + A PRAÇA ═════════════════════════════════════════ */
.split { display: grid; grid-template-columns: 7fr 5fr; gap: clamp(28px, 4.5vw, 60px); align-items: start; }
.split .section-flag { margin-top: clamp(40px, 6vw, 64px); }
.praca { position: sticky; top: 64px; }

.trad-list { list-style: none; }
.trad-item {
    display: grid; grid-template-columns: 72px 1fr; gap: 18px;
    padding: 16px 0; border-bottom: 1px solid var(--rule);
}
.trad-date {
    position: relative; width: 72px; height: 72px;
    border: 1px solid var(--rule-strong); overflow: hidden;
    display: flex; align-items: center; justify-content: center;
}
.trad-date .az-tile { position: absolute; inset: 0; width: 100%; height: 100%; opacity: .85; }
.trad-date-text {
    position: relative; z-index: 1;
    font-family: var(--font-mono); font-size: 10.5px; font-weight: 700;
    letter-spacing: .04em; text-align: center; line-height: 1.3;
    color: #FDF7E5; background: rgba(14, 53, 103, .82);
    padding: 3px 6px;
}
.trad-item h3 { font-size: 18px; font-weight: 700; line-height: 1.3; }
.trad-pt { display: block; font-size: 13.5px; color: var(--ink-soft); margin-top: 1px; }
.trad-item p { font-size: 13.5px; color: var(--ink-soft); margin-top: 5px; }
.trad-where {
    display: inline-block; margin-top: 6px;
    font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .12em;
    text-transform: uppercase; color: var(--terracotta-text);
}

.follow-cards { display: grid; gap: 12px; }
.follow {
    display: flex; align-items: center; gap: 14px;
    padding: 16px 18px;
    border: 1px solid var(--rule-strong);
    text-decoration: none;
    background: var(--card);
    transition: transform .18s, box-shadow .18s;
}
.follow:hover { transform: translateY(-2px); box-shadow: 0 12px 26px rgba(34, 48, 58, .12); }
.follow svg { flex-shrink: 0; width: 24px; height: 24px; }
.follow--ig { color: var(--clay-deep); background: color-mix(in srgb, var(--terracotta) 7%, var(--card)); }
.follow--x { color: var(--ink); background: color-mix(in srgb, var(--ink) 5%, var(--card)); }
.follow span { display: flex; flex-direction: column; line-height: 1.3; }
.follow b { font-size: 16.5px; font-weight: 700; }
.follow small { font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .06em; color: var(--ink-soft); margin-top: 2px; }

.dispatches { margin-top: 22px; }
.dispatches-title {
    font-family: var(--font-mono); font-size: 11px; font-weight: 700;
    letter-spacing: .18em; text-transform: uppercase; color: var(--ink-soft);
    margin-bottom: 12px;
}
.dispatch {
    border: 1px solid var(--rule); border-left: 3px solid var(--cobalt);
    background: var(--card);
    padding: 12px 14px; margin-bottom: 10px;
    font-size: 13.5px; line-height: 1.5;
    display: block; text-decoration: none;
    transition: border-color .15s;
}
.dispatch:hover { border-left-color: var(--terracotta); }
.dispatch-head {
    display: flex; justify-content: space-between; gap: 10px;
    font-family: var(--font-mono); font-size: 10px; letter-spacing: .1em;
    text-transform: uppercase; color: var(--ink-soft);
    margin-bottom: 6px;
}
.dispatch-src { color: var(--cobalt); font-weight: 700; }

/* ════ COLOPHON ════════════════════════════════════════════════════ */
.colophon {
    background: var(--night);
    color: var(--night-text);
    text-align: center;
    padding: clamp(36px, 5vw, 56px) var(--pad) clamp(28px, 4vw, 44px);
}
.colophon-name {
    font-family: var(--font-display);
    font-size: clamp(26px, 3.4vw, 38px); font-weight: 900;
    font-variation-settings: 'opsz' 144;
    color: #FDF7E5;
    display: block; margin-bottom: 20px;
}
.colophon-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 0; margin-bottom: 24px; }
.colophon-links a {
    font-family: var(--font-mono); font-size: 11px; letter-spacing: .14em; text-transform: uppercase;
    color: var(--night-text); text-decoration: none;
    padding: 4px 12px;
    border-right: 1px solid rgba(242, 231, 201, .25);
}
.colophon-links a:last-child { border-right: 0; }
.colophon-links a:hover { color: var(--citrus); }
.colophon-social { display: flex; justify-content: center; gap: 22px; margin-bottom: 22px; }
.colophon-social a {
    display: inline-flex; align-items: center; gap: 9px;
    font-family: var(--font-mono); font-size: 12.5px; font-weight: 700;
    color: #FDF7E5; text-decoration: none;
    padding: 9px 16px;
    border: 1px solid rgba(242, 231, 201, .3);
    transition: border-color .15s, color .15s;
}
.colophon-social a:hover { border-color: var(--citrus); color: var(--citrus); }
.colophon-meta { font-family: var(--font-mono); font-size: 11px; letter-spacing: .1em; opacity: .7; }
.colophon-sign { font-style: italic; font-size: 13.5px; margin-top: 8px; opacity: .85; }

/* ════ MOBILE BOTTOM NAV ═══════════════════════════════════════════ */
.bottom-nav {
    display: none;
    position: fixed; bottom: 0; left: 0; right: 0; z-index: 120;
    background: rgba(250, 243, 227, .96);
    backdrop-filter: blur(12px);
    border-top: 1px solid var(--rule-strong);
    padding: 6px 4px calc(6px + env(safe-area-inset-bottom, 0px));
}
.bnav-item {
    display: flex; flex-direction: column; align-items: center; gap: 2px;
    flex: 1; text-decoration: none;
    font-family: var(--font-mono); font-size: 9px; letter-spacing: .08em; text-transform: uppercase;
    color: var(--ink-soft); padding: 4px 2px;
}
.bnav-ico { font-size: 17px; line-height: 1; display: inline-flex; } .bnav-ico svg { width: 18px; height: 18px; }
.bnav-item--active, .bnav-item:hover { color: var(--cobalt-deep); }

/* ════ SCROLL REVEAL ═══════════════════════════════════════════════ */
.rv { opacity: 0; transform: translateY(16px); transition: opacity .55s ease, transform .55s ease; transition-delay: var(--d, 0s); }
.rv.is-set { opacity: 1; transform: none; }

/* ════ RESPONSIVE ══════════════════════════════════════════════════ */
@media (max-width: 1020px) {
    .alm-grid { grid-template-columns: 1fr 220px; }
    .postal { grid-column: 1 / -1; max-width: 340px; justify-self: center; }
    .cards { grid-template-columns: repeat(2, 1fr); }
    .split { grid-template-columns: 1fr; }
    .ind-grid { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
    .masthead { grid-template-columns: 1fr; gap: 10px; text-align: center; padding-bottom: 16px; }
    .masthead-ear--left { order: 2; }
    .masthead-ear--right { order: 3; text-align: center; }
    .ear-social { justify-content: center; }
    .ear-social a { width: 44px; height: 44px; }
    .masthead-name { white-space: normal; }
    .masthead-kicker { letter-spacing: .18em; }

    .section-flag { flex-wrap: wrap; row-gap: 6px; }
    .section-flag h2 { white-space: normal; }
    .section-flag-pt { white-space: nowrap; }
    .section-flag-rule { display: none; }
    .section-flag-note { flex-basis: 100%; order: 4; }

    .paper-nav::after {
        content: ''; position: absolute; top: 0; right: 0; bottom: 0; width: 44px;
        background: linear-gradient(270deg, var(--paper), transparent);
        pointer-events: none;
    }

    .type-pill { padding: 11px 14px; }
    .city-select { padding: 12px 10px; font-size: 16px; }
    .colophon-links a { padding: 10px 12px; }
    .colophon { padding-bottom: calc(clamp(28px, 4vw, 44px) + 64px); }
    .praca { position: static; }

    .lead { grid-template-columns: 1fr; grid-template-areas: 'copy' 'art' 'decks'; }
    .lead-decks { grid-template-columns: 1fr; gap: 14px; }
    .deck + .deck { border-left: 0; padding-left: 0; border-top: 1px solid var(--rule); padding-top: 14px; }

    .alm-grid { grid-template-columns: 1fr; }
    .alm-week { overflow-x: auto; grid-template-columns: repeat(7, minmax(64px, 1fr)); }
    .alm-side { flex-direction: row; align-items: stretch; flex-wrap: wrap; }
    .alm-readings { min-width: 230px; }

    .cards { grid-template-columns: 1fr; }
    .cartaz-count { margin-left: 0; width: 100%; }

    .board-row { grid-template-columns: 86px 1fr auto; }
    .bf-flight { display: none; }
    .board-bars { height: 96px; }

    .wire::before { left: 6px; }
    .wire-item { grid-template-columns: 1fr; gap: 6px; padding-left: 26px; }
    .wire-time { text-align: left; }
    .wire-node { right: auto; left: -24px; }

    .bottom-nav { display: flex; }
    .paper-nav { top: 0; }
}

@media (max-width: 480px) {
    .tick { padding: 11px 16px; }
    .board-frame { outline-offset: -7px; }
    .ind-components { flex-wrap: wrap; gap: 14px; }
}

/* ════ ACCESSIBILITY & MOTION ══════════════════════════════════════ */
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    .ticker { overflow-x: auto; }
    .ticker-track { animation: none; width: auto; }
    .ticker-set + .ticker-set { display: none; }
    .live-dot, .wire-loading i { animation: none; }
    .rv { opacity: 1; transform: none; transition: none; }
    .wire-item.is-new { animation: none; }
    .bbar, .ibar { transition: none; }
    .card, .card:hover, .postal, .postal:hover { transform: none; transition: none; }
    .board-row.is-flipping { animation: none; }
}

:focus-visible { outline: 2px solid var(--cobalt); outline-offset: 2px; }
.board :focus-visible, .colophon :focus-visible { outline-color: var(--night-glow); }

/* Touch devices: the marquee becomes a swipeable strip (WCAG 2.2.2 — no
   unpausable motion); home.js skips cloning under pointer:coarse too. */
@media (pointer: coarse) {
    .ticker { overflow-x: auto; scrollbar-width: none; }
    .ticker::-webkit-scrollbar { display: none; }
    .ticker-track { animation: none; width: max-content; }
}

/* Weather glyph colours — engraved duotone */
.alm-day-icon { color: var(--ink-soft); display: flex; justify-content: center; min-height: 24px; align-items: center; }
.alm-day-icon .wx-sun { color: var(--citrus); }
.alm-day-icon .wx-storm, .alm-day-icon .wx-rain { color: var(--cobalt); }
