/* --------------------------------------------------------------------------
   Editorial edition
   A deliberately flatter, more typographic language than a component library.
   -------------------------------------------------------------------------- */

@media screen {
  :root {
    --paper: #f3eddf;
    --surface: #fbf7ee;
    --surface-2: #e9e2d3;
    --ink: #172621;
    --ink-soft: #3f514b;
    --muted: #68766f;
    --line: #cfc5b3;
    --line-strong: #a99d89;
    --radius-sm: 3px;
    --radius-md: 5px;
    --radius-lg: 8px;
    --radius-xl: 10px;
    --shadow-sm: none;
    --shadow-md: none;
    --shadow-lg: none;
  }

  body {
    background: var(--paper);
  }

  .topbar {
    border-bottom: 2px solid var(--ink);
    background: color-mix(in srgb, var(--paper) 96%, transparent);
    backdrop-filter: none;
  }

  .brand-mark {
    width: 39px;
    height: 39px;
    border: 2px solid var(--ink);
    border-radius: 0;
    background: var(--coral);
    box-shadow: 4px 4px 0 var(--ink);
  }

  .brand-mark svg { display:none; }
  .brand-mark::before { color:#fff; content:"LT"; font-family:var(--serif); font-size:15px; font-weight:800; }
  .brand-mark > span { display:none; }

  .desktop-nav {
    padding: 0;
    border: 1px solid var(--ink);
    border-radius: 0;
    background: transparent;
  }

  .nav-link {
    border-right: 1px solid var(--ink);
    border-radius: 0;
  }

  .nav-link:last-child { border-right:0; }
  .nav-link:hover,
  .nav-link.is-active { background:var(--ink); color:#fff; box-shadow:none; }

  .hero {
    border: 2px solid var(--ink);
    border-radius: 8px;
    box-shadow: 8px 8px 0 color-mix(in srgb, var(--ink) 88%, transparent);
  }

  .hero-kicker,
  .confirmed-label,
  .eyebrow {
    letter-spacing: .035em;
    text-transform: none;
  }

  .hero-kicker {
    padding-bottom: 5px;
    border-bottom: 2px solid #ffca68;
    font-family: var(--serif);
    font-size: 14px;
    font-style: italic;
  }

  .live-dot { display:none; }

  .hero-meta {
    gap: 0;
    border-top: 1px solid rgba(255,255,255,.58);
  }

  .hero-meta span {
    padding: 9px 14px 0 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    backdrop-filter: none;
  }

  .hero-meta span + span {
    margin-left: 14px;
    padding-left: 14px;
    border-left: 1px solid rgba(255,255,255,.5);
  }

  .concert-card {
    border: 2px solid #fff;
    border-radius: 3px;
    background: #142622;
    box-shadow: 6px 6px 0 rgba(0,0,0,.36);
    backdrop-filter: none;
  }

  .concert-date {
    border: 1px solid #fff;
    border-radius: 0;
  }

  .trip-strip {
    border-width: 2px 0;
    border-color: var(--ink);
    border-radius: 0;
    background: transparent;
    box-shadow: none;
  }

  .trip-strip-item--attention { border-radius:0; background:transparent; }
  .trip-strip-icon { border:1px solid var(--ink); border-radius:0; background:transparent; }

  .eyebrow {
    color: var(--ink-soft);
    font-family: var(--serif);
    font-size: 15px;
    font-style: italic;
    font-weight: 700;
  }

  .section-heading h2 { border-bottom:4px solid var(--coral); padding-bottom:8px; }

  .button {
    min-height: 42px;
    border-radius: 3px;
  }

  .button--dark,
  .button--quiet {
    border: 1px solid var(--ink);
    background: transparent;
    color: var(--ink);
    box-shadow: none;
  }

  .button--dark:hover,
  .button--quiet:hover { background:var(--ink); color:#fff; }

  .day-tabs { gap:0; border:2px solid var(--ink); }

  .day-tab {
    min-height: 84px;
    border: 0;
    border-right: 1px solid var(--ink);
    border-radius: 0;
    background: transparent;
    box-shadow: none;
  }

  .day-tab:last-child { border-right:0; }
  .day-tab:hover { border-color:var(--ink); box-shadow:none; transform:none; }
  .day-tab.is-active { background:var(--day-tab-tint); box-shadow:none; }
  .day-tab.is-active::after { height:5px; }

  .day-tab-date {
    border: 1px solid var(--ink);
    border-radius: 0;
    background: transparent;
    box-shadow: none;
  }

  .day-tab-count { border-radius:0; background:transparent; }

  .planner-grid {
    border: 2px solid var(--ink);
    border-radius: 0;
    background: var(--surface);
    box-shadow: 7px 7px 0 color-mix(in srgb, var(--ink) 16%, transparent);
  }

  .itinerary-panel { border-right:2px solid var(--ink); }
  .day-overview { border-bottom:1px solid var(--line-strong); }
  .pace-pill { border-radius:0; background:transparent; }

  .day-computed {
    display:flex;
    flex-wrap:wrap;
    margin-top:11px;
    border-top:1px solid var(--ink);
    border-bottom:1px solid var(--ink);
  }

  .day-computed > span {
    display:grid;
    min-width:92px;
    flex:1;
    grid-template-columns:18px minmax(0,1fr);
    align-items:center;
    gap:0 6px;
    padding:8px 9px;
    border-right:1px solid var(--line-strong);
  }

  .day-computed > span:last-child { border-right:0; }
  .day-computed svg { grid-row:1 / span 2; width:15px; height:15px; color:var(--day-color); }
  .day-computed small { color:var(--muted); font-size:7px; font-weight:900; letter-spacing:.08em; text-transform:uppercase; }
  .day-computed strong { color:var(--ink); font-size:10px; }

  .next-up {
    border: 0;
    border-left: 5px solid var(--day-color);
    border-radius: 0;
    background: color-mix(in srgb, var(--day-tint) 62%, var(--surface));
  }

  .next-up button { border-radius:2px; }

  .editorial-chapter-heading {
    border-bottom: 1px solid var(--ink);
    padding-bottom: 5px;
  }

  .editorial-chapter-heading i { display:none; }

  .chapter-refresh {
    min-height: 30px;
    padding: 2px 0;
    border: 0;
    border-bottom: 1px solid currentColor;
    border-radius: 0;
    background: transparent;
  }

  .chapter-refresh:hover,
  .chapter-refresh:focus-visible { background:transparent; }

  .activity-card {
    border: 0;
    border-bottom: 1px solid var(--line);
    border-radius: 0;
    background: transparent;
    box-shadow: none;
  }

  .activity-card:hover { background:color-mix(in srgb,var(--day-tint) 38%,transparent); }
  .activity-card.is-selected { border-color:var(--day-color); background:var(--day-tint); box-shadow:none; }
  .activity-category {
    width:52px;
    height:52px;
    border:1px solid var(--ink);
    border-radius:0;
    background-position:center;
    background-size:cover;
    box-shadow:3px 3px 0 color-mix(in srgb,var(--day-color) 58%,var(--ink));
  }

  .activity-category svg { width:19px; height:19px; filter:drop-shadow(0 1px 2px rgba(0,0,0,.45)); }

  .status-badge,
  .cost-badge {
    padding: 2px 0;
    border: 0;
    border-bottom: 2px solid currentColor;
    border-radius: 0;
    background: transparent;
  }

  .show-more-stops {
    border: 1px solid var(--ink);
    border-radius: 0;
    background: transparent;
    color: var(--ink);
  }

  .wildcard-tray {
    border: 1px solid var(--ink);
    border-radius: 0;
    background: #f1dcb9;
    box-shadow: 5px 5px 0 var(--day-color);
  }

  .wildcard-option {
    border: 0;
    border-top: 1px solid var(--ink);
    border-radius: 0;
    background: transparent;
  }

  .wildcard-option-icon {
    width:100%;
    height:46px;
    margin-bottom:8px;
    border:1px solid var(--ink);
    border-radius:0;
    background-position:center;
    background-size:cover;
    box-shadow:2px 2px 0 color-mix(in srgb,var(--day-color) 70%,var(--ink));
  }

  .wildcard-option.category-food .wildcard-option-icon,
  .wildcard-option.category-shop .wildcard-option-icon { background-image:linear-gradient(rgba(18,31,28,.24),rgba(18,31,28,.24)),url("./assets/category-food.webp"); }
  .wildcard-option.category-history .wildcard-option-icon,
  .wildcard-option.category-art .wildcard-option-icon { background-image:linear-gradient(rgba(18,31,28,.24),rgba(18,31,28,.24)),url("./assets/category-culture.webp"); }
  .wildcard-option.category-view .wildcard-option-icon,
  .wildcard-option.category-wander .wildcard-option-icon,
  .wildcard-option.category-transit .wildcard-option-icon { background-image:linear-gradient(rgba(18,31,28,.24),rgba(18,31,28,.24)),url("./assets/category-outdoors.webp"); }
  .wildcard-option.category-show .wildcard-option-icon,
  .wildcard-option.category-concert .wildcard-option-icon { background-image:linear-gradient(rgba(18,31,28,.24),rgba(18,31,28,.24)),url("./assets/category-night.webp"); }
  .wildcard-option-icon svg { width:18px; height:18px; filter:drop-shadow(0 1px 2px rgba(0,0,0,.55)); }
  .wildcard-option button { border-radius:2px; }

  .wildcard-options { grid-template-columns:repeat(3,minmax(0,1fr)); gap:6px; }

  .wildcard-option {
    position:relative;
    grid-template-columns:1fr;
    grid-template-rows:auto 1fr auto;
    align-content:start;
    padding:9px;
    overflow:hidden;
    animation:wildcard-deal 420ms cubic-bezier(.2,.8,.2,1) both;
    animation-delay:calc(var(--deal-index) * 75ms);
  }

  @keyframes wildcard-deal {
    from { opacity:0; transform:translateY(-8px) rotate(-.6deg); }
    to { opacity:1; transform:translateY(0) rotate(0); }
  }

  .wildcard-number {
    position:absolute;
    top:7px;
    right:8px;
    color:color-mix(in srgb,var(--day-color) 48%,transparent);
    font-family:var(--serif);
    font-size:12px;
    font-weight:800;
  }

  .wildcard-option-icon { width:100%; height:46px; margin-bottom:7px; }
  .wildcard-option-copy strong { display:-webkit-box; margin-top:5px; padding-right:14px; overflow:hidden; font-family:var(--serif); font-size:13px; line-height:1.12; -webkit-box-orient:vertical; -webkit-line-clamp:3; }
  .wildcard-option-copy small { display:-webkit-box; padding-right:12px; overflow:hidden; font-size:7px; letter-spacing:.05em; text-transform:uppercase; -webkit-box-orient:vertical; -webkit-line-clamp:2; }
  .wildcard-option-copy em { display:none; }
  .wildcard-cost { display:inline-block; margin-top:7px; border-bottom:1px solid currentColor; color:var(--day-color); font-size:8px; font-weight:900; }
  .wildcard-option button { grid-column:1; align-self:end; justify-self:stretch; justify-content:center; min-height:36px; margin-top:9px; padding:7px 5px; font-size:9px; }

  .wildcard-empty { margin:4px 0 0; padding:18px 10px 10px; border-top:1px solid var(--ink); color:var(--ink-soft); font-family:var(--serif); font-size:16px; text-align:center; }

  .activity-facts {
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:8px;
    margin-top:12px;
    padding:10px 0;
    border-top:1px solid var(--line);
    border-bottom:1px solid var(--line);
  }

  .activity-facts > span { display:grid; grid-template-columns:17px minmax(0,1fr); column-gap:6px; align-items:start; }
  .activity-facts > span > svg { grid-row:1 / span 2; width:14px; height:14px; color:var(--day-color); }
  .activity-facts small { color:var(--muted); font-size:8px; font-weight:900; letter-spacing:.08em; text-transform:uppercase; }
  .activity-facts strong { margin-top:2px; color:var(--ink); font-size:10px; line-height:1.3; }
  .activity-facts .activity-address { grid-column:1 / -1; }

  .activity-card.is-selected .place-actions { display:flex; flex-wrap:wrap; gap:6px; margin-top:11px; }
  .activity-card.is-selected .place-actions a { display:inline-flex; min-height:38px; align-items:center; gap:5px; padding:7px 9px; border:1px solid var(--ink); color:var(--ink); font-size:9px; font-weight:900; text-decoration:none; text-transform:uppercase; }
  .activity-card.is-selected .place-actions a:first-child { background:var(--ink); color:#fff; }
  .activity-card.is-selected .place-actions svg { width:12px; height:12px; }

  .day-deck-trigger {
    display:inline-flex;
    align-items:center;
    gap:8px;
    margin-top:11px;
    padding:8px 10px;
    border:1px solid var(--ink);
    border-radius:0;
    background:var(--surface);
    color:var(--ink);
    cursor:pointer;
    text-align:left;
  }
  .day-deck-trigger > svg { width:16px; height:16px; color:var(--coral); }
  .day-deck-trigger span,.day-deck-trigger strong,.day-deck-trigger small { display:block; }
  .day-deck-trigger strong { font-size:10px; text-transform:uppercase; }
  .day-deck-trigger small { margin-top:2px; color:var(--muted); font-size:8px; }

  .day-deck-warning { display:grid; grid-template-columns:22px 1fr; gap:3px 9px; margin:0 26px 14px !important; padding:11px; border:1px solid var(--coral); background:var(--coral-soft); }
  .day-deck-warning svg { grid-row:1 / span 2; width:18px; height:18px; color:var(--coral-deep); }
  .day-deck-warning strong { font-size:10px; }
  .day-deck-warning span { color:var(--ink-soft); font-size:9px; }
  .day-deck-preview { margin:0 26px !important; }
  .day-deck-card { padding:15px; border:2px solid var(--ink); background:#f1dcb9; box-shadow:5px 5px 0 var(--day-color); }
  .day-deck-card-top { display:flex; justify-content:space-between; gap:8px; color:var(--day-color); font-size:8px; font-weight:900; letter-spacing:.07em; text-transform:uppercase; }
  .day-deck-card h3 { margin:10px 0 4px; font-family:var(--serif); font-size:25px; line-height:1; }
  .day-deck-card > p { margin:7px 0 0; color:var(--ink-soft); font-size:10px; line-height:1.4; }
  .day-deck-area { display:flex; align-items:center; gap:5px; color:var(--day-color) !important; font-weight:850; }
  .day-deck-area svg { width:13px; height:13px; }
  .day-deck-card ol { margin:13px 0 0; padding:0; border-top:1px solid var(--ink); list-style:none; }
  .day-deck-card li { display:grid; grid-template-columns:42px 1fr; gap:8px; padding:7px 0; border-bottom:1px solid color-mix(in srgb,var(--ink) 22%,transparent); }
  .day-deck-card li time { color:var(--day-color); font-size:9px; font-weight:900; }
  .day-deck-card li strong { font-size:10px; line-height:1.25; }
  .day-deck-more { display:block; margin-top:8px; color:var(--muted); font-size:9px; font-weight:800; }
  .day-deck-actions { grid-template-columns:auto auto 1fr; margin:18px 26px 24px; }
  .day-deck-actions .button--coral { justify-self:end; }

  @media (prefers-reduced-motion: reduce) {
    .wildcard-option { animation:none; }
    .activity-expand-button,
    .activity-expand-button svg { transition:none; }
  }

  .map-panel { border-radius:0; }
  .map-toolbar { border-bottom:2px solid var(--ink); }
  .map-quick-actions { border-radius:0; }
  .map-quick-action { border:1px solid var(--ink); border-radius:0; background:var(--surface); }
  .route-stat-icon { border:1px solid var(--ink); border-radius:0; background:transparent; }

  .detail-card {
    border: 2px solid var(--ink);
    border-radius: 0;
    box-shadow: 6px 6px 0 color-mix(in srgb,var(--ink) 12%,transparent);
  }

  .details-heading-actions { display:flex; align-items:center; gap:8px; }
  .details-toggle { display:none; }

  .detail-icon,
  .resource-badge,
  .reminder-check { border-radius:0; }
  .concert-detail-card { background:#e7e5d8; }
  .concert-poster { border:2px solid var(--ink); border-radius:0; box-shadow:5px 5px 0 var(--ink); }

  .modal {
    border: 2px solid var(--ink);
    border-radius: 0;
    box-shadow: 10px 10px 0 rgba(23,38,33,.32);
  }

  .toast {
    border: 1px solid #fff;
    border-radius: 0;
    background: var(--ink);
    box-shadow: 5px 5px 0 var(--coral);
  }

  .toast-icon,
  .icon-button,
  .maplibregl-ctrl-group { border-radius:0 !important; }

  .table-tools a,
  .table-tools button,
  .stop-table,
  .field input,
  .field select,
  .field textarea { border-radius:0; }

  .table-status {
    padding: 2px 0;
    border-radius: 0;
    background: transparent;
    text-decoration: underline;
    text-decoration-thickness: 2px;
    text-underline-offset: 3px;
  }

  .table-actions button { border-radius:0; }
}

@media screen and (max-width: 640px) {
  .topbar { border-bottom-width:1px; }

  .brand-mark {
    width: 35px;
    height: 35px;
    box-shadow: 3px 3px 0 var(--ink);
  }

  .hero {
    margin-top: 8px;
    min-height:330px;
    border-radius: 3px;
    box-shadow: 5px 5px 0 var(--ink);
  }

  .concert-card { border-radius:0; box-shadow:4px 4px 0 rgba(0,0,0,.42); }
  .trip-strip { margin-top:14px; border-radius:0; }
  .trip-strip-item { min-height:62px; }

  .section-heading h2 { padding-bottom:7px; }
  .day-tabs { border-width:1px; }
  .day-tab { min-width:190px; border-right:1px solid var(--ink); border-radius:0; }
  .planner-grid { border-width:1px; box-shadow:4px 4px 0 color-mix(in srgb,var(--ink) 18%,transparent); }
  .itinerary-panel { padding:14px 8px 24px; border-right:0; }

  .day-overview { padding:2px 4px 13px; }
  .day-overview h3 { font-size:27px; }
  .day-overview p { display:-webkit-box; overflow:hidden; font-size:11px; line-height:1.35; -webkit-box-orient:vertical; -webkit-line-clamp:1; }
  .day-computed { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); margin-top:8px; }
  .day-computed > span { min-width:0; padding:7px 6px; border-bottom:1px solid var(--line); }
  .day-computed > span:nth-child(2n) { border-right:0; }
  .day-computed > span:nth-child(n + 3) { border-bottom:0; }
  .day-computed > span:last-child:nth-child(odd) { grid-column:1 / -1; border-right:0; }
  .day-computed small { font-size:7px; }
  .day-computed strong { font-size:10px; }
  .next-up { display:none; }
  .day-deck-trigger { width:100%; justify-content:center; margin-top:9px; min-height:44px; }
  .day-deck-trigger span { display:flex; align-items:baseline; gap:6px; }
  .day-deck-trigger small { margin:0; }

  .editorial-chapter-heading { margin:20px 4px 8px 48px; }
  .editorial-chapter-heading span { font-size:20px; }
  .editorial-chapter-heading small { display:none; }
  .wildcard-tray { margin-left:0; box-shadow:4px 4px 0 var(--day-color); }
  .wildcard-tray-head { align-items:flex-start; }
  .wildcard-tray-head small { max-width:145px; text-align:right; }
  .wildcard-options { grid-template-columns:repeat(3,minmax(0,1fr)); gap:5px; }
  .wildcard-option { grid-template-columns:1fr; grid-template-rows:auto 1fr auto; min-height:176px; padding:7px 6px 8px; }
  .wildcard-option-icon { width:100%; height:50px; margin-bottom:7px; }
  .wildcard-option-copy strong { padding-right:8px; font-size:13px; line-height:1.08; }
  .wildcard-option-copy small { padding-right:7px; font-size:6.5px; }
  .wildcard-cost { font-size:8px; }
  .wildcard-option button { grid-column:1; grid-row:auto; justify-self:stretch; justify-content:center; min-height:44px; padding:6px 3px; font-size:10px; }
  .wildcard-option button svg { display:none; }

  .activity-row { grid-template-columns:37px 11px minmax(0,1fr); gap:4px; }
  .activity-time { padding-top:12px; font-size:11px; letter-spacing:-.02em; }
  .activity-rail i { top:14px; width:10px; height:10px; border-width:2px; }
  .activity-card { gap:11px; min-height:106px; margin-bottom:8px; padding:13px 9px 14px; }
  .activity-category { width:70px; height:70px; font-size:18px; box-shadow:4px 4px 0 color-mix(in srgb,var(--day-color) 62%,var(--ink)); }
  .activity-category svg { width:22px; height:22px; }
  .activity-title { font-size:17px; line-height:1.12; -webkit-line-clamp:3; }
  .activity-meta { gap:4px 7px; margin-top:4px; font-size:10px; }
  .activity-note { margin-top:6px; font-size:11px; line-height:1.4; -webkit-line-clamp:2; }
  .activity-badges { margin-top:6px; }
  .activity-card:not(.is-selected) .activity-badges { margin-top:5px; }
  .activity-facts { grid-template-columns:1fr 1fr; gap:8px 6px; margin-top:8px; padding:8px 0; }
  .activity-facts strong { font-size:11px; }
  .activity-card.is-selected .place-actions { display:grid; grid-template-columns:1fr 1fr; }
  .activity-card.is-selected .place-actions a { min-height:44px; justify-content:center; text-align:center; }
  .activity-card.is-selected .place-actions a:last-child { grid-column:1 / -1; }

  .day-deck-warning { margin:0 16px 12px !important; }
  .day-deck-preview { margin:0 16px !important; }
  .day-deck-card { padding:13px; box-shadow:4px 4px 0 var(--day-color); }
  .day-deck-card h3 { font-size:23px; }
  .day-deck-card li { grid-template-columns:38px 1fr; padding:6px 0; }
  .day-deck-actions { grid-template-columns:1fr 1fr; margin:16px; }
  .day-deck-actions .button { min-height:44px; }
  .day-deck-actions .button--coral { grid-column:1 / -1; grid-row:1; justify-self:stretch; }

  .travel-leg { min-height:20px; grid-template-columns:48px minmax(0,1fr); gap:4px; margin:-2px 0; }
  .travel-leg-line::before { left:42px; }
  .travel-leg-copy { gap:4px; padding-left:0; font-size:9px; }
  .travel-leg-copy svg { width:10px; height:10px; }
  .travel-leg-copy em { display:none; }
  .show-more-stops { width:calc(100% - 52px); margin:8px 0 6px 52px; }

  .map-panel { border-radius:0; }
  .detail-card { border-width:1px; box-shadow:4px 4px 0 color-mix(in srgb,var(--ink) 14%,transparent); }

  .details-section { padding-top:32px; }
  .details-section .section-heading { align-items:center; }
  .details-section.is-collapsed { padding-bottom:24px; }
  .details-section.is-collapsed .details-grid { display:none; }
  .details-section.is-collapsed .section-heading { margin-bottom:0; }
  .details-heading-actions { gap:6px; }
  .details-toggle {
    display:inline-flex;
    min-height:44px;
    align-items:center;
    gap:6px;
    padding:8px 10px;
    border:1px solid var(--ink);
    border-radius:0;
    background:var(--surface);
    color:var(--ink);
    cursor:pointer;
    font-size:9px;
    font-weight:900;
    text-transform:uppercase;
  }
  .details-toggle svg { width:13px; height:13px; transition:transform 160ms ease; }
  .details-toggle[aria-expanded="true"] svg { transform:rotate(180deg); }

  .mobile-tabbar {
    right: 0;
    bottom: 0;
    left: 0;
    height: calc(68px + env(safe-area-inset-bottom));
    padding: 5px 8px env(safe-area-inset-bottom);
    border: 0;
    border-top: 2px solid var(--ink);
    border-radius: 0;
    background: var(--surface);
    box-shadow: 0 -4px 0 rgba(23,38,33,.08);
    backdrop-filter: none;
  }

  .mobile-tabbar button {
    border-radius: 0;
    color: var(--muted);
  }

  .mobile-tabbar button.is-active {
    border-bottom: 4px solid var(--coral);
    background: transparent;
    color: var(--ink);
  }

  .mobile-add {
    width: 32px;
    height: 32px;
    margin-top: 0;
    border: 1px solid var(--ink);
    border-radius: 0;
    box-shadow: 3px 3px 0 var(--ink);
  }
}
