:root {
  color-scheme: light;
  --ink: #241f19;
  --paper: #f7f3ea;
  --paper-strong: #ffffff;
  --accent: #f0a11a;
  --accent-deep: #c56a2b;
  --slate: #49515b;
  --muted: #746b5f;
  --border: #e2dbc8;
  --shadow: 0 20px 45px rgba(22, 18, 12, 0.15);
  --radius-lg: 18px;
  --radius-md: 12px;
  --radius-sm: 8px;
  --font-display: "Iowan Old Style", "Palatino Linotype", "Book Antiqua",
    "URW Palladio L", serif;
  --font-body: "Source Sans 3", "Noto Sans", "Avenir Next", "Segoe UI",
    sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--paper);
}

a {
  color: inherit;
  text-decoration: none;
}

.app {
  max-width: 480px;
  margin: 0 auto;
  background: var(--paper);
  min-height: 100vh;
  box-shadow: var(--shadow);
  position: relative;
  padding-bottom: 72px;
}

.top-bar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: grid;
  align-items: center;
  grid-template-columns: 1fr auto 1fr;
  padding: 18px 18px 12px;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(226, 219, 200, 0.7);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  justify-self: center;
}

.brand-icon {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 6px;
  background: rgba(240, 161, 26, 0.18);
}

.brand-icon svg {
  width: 17px;
  height: 17px;
  fill: #d3871d;
}

.brand-text {
  font-family: var(--font-display);
  font-weight: 700;
  font-style: italic;
  font-size: 1.35rem;
  color: var(--ink);
  letter-spacing: -0.01em;
}

.icon-button {
  width: 34px;
  height: 34px;
  border-radius: 12px;
  border: 1px solid rgba(226, 219, 200, 0.7);
  display: grid;
  place-items: center;
  background: #fff;
}

.icon-button svg {
  width: 16px;
  height: 16px;
  fill: var(--slate);
}

.search-button {
  justify-self: end;
}

.menu {
  position: relative;
  justify-self: start;
}

.menu summary {
  list-style: none;
}

.menu summary::-webkit-details-marker {
  display: none;
}

.menu[open] .icon-button {
  border-color: rgba(196, 182, 160, 0.8);
}

.menu-panel {
  position: absolute;
  top: 46px;
  left: 0;
  min-width: 160px;
  display: grid;
  gap: 6px;
  padding: 12px;
  border-radius: 12px;
  background: #fff;
  border: 1px solid rgba(226, 219, 200, 0.9);
  box-shadow: 0 18px 35px rgba(27, 22, 15, 0.18);
  z-index: 30;
}

.menu-panel a {
  padding: 8px 10px;
  border-radius: 8px;
  color: var(--ink);
  font-size: 0.9rem;
}

.menu-panel a:hover {
  background: rgba(240, 161, 26, 0.15);
}

.hero-card {
  margin: 14px 16px 8px;
  border-radius: var(--radius-lg);
  min-height: 420px;
  padding: 18px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 18px;
  color: #fff;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.05), rgba(0, 0, 0, 0.85)),
    radial-gradient(circle at top, rgba(255, 216, 150, 0.4), transparent 60%),
    linear-gradient(130deg, #3d6a85, #2e3f59);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  box-shadow: var(--shadow);
  transition: background-image 0.6s ease;
  position: relative;
}

.tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  background: rgba(240, 161, 26, 0.95);
  color: #1e1408;
}

.hero-tag {
  align-self: flex-start;
}

.hero-arrow {
  position: absolute;
  top: 18px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.5);
  background: rgba(12, 16, 22, 0.35);
  color: #fff;
  display: grid;
  place-items: center;
  font-size: 1.2rem;
  cursor: pointer;
  backdrop-filter: blur(6px);
}

.hero-arrow span {
  line-height: 1;
}

.hero-prev {
  right: 62px;
}

.hero-next {
  right: 18px;
}

.hero-title {
  font-family: var(--font-display);
  font-size: 2.2rem;
  font-style: italic;
  margin: 0;
}

.hero-title span {
  color: var(--accent);
}

.hero-subtitle {
  font-size: 0.95rem;
  color: rgba(255, 255, 255, 0.85);
  margin: 0;
}

.cta-stack {
  display: grid;
  gap: 10px;
}

.btn {
  height: 48px;
  border-radius: 12px;
  border: none;
  font-weight: 600;
  font-size: 0.95rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
}

.btn-primary {
  background: var(--accent);
  color: #1f160a;
}

.btn-ghost {
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.4);
}

.section {
  padding: 18px;
}

.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.section-title {
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-style: italic;
  margin: 0;
}

.link-muted {
  font-size: 0.85rem;
  color: var(--slate);
}

.scroll-row {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 140px;
  gap: 12px;
  overflow-x: auto;
  padding-bottom: 8px;
}

.story-card {
  display: grid;
  gap: 8px;
}

.story-thumb {
  height: 150px;
  border-radius: var(--radius-md);
  background: linear-gradient(160deg, #222, #567);
  background-size: cover;
  background-position: center;
}

.list-thumb--empty {
  background: linear-gradient(160deg, #1f2730, #3c4a58);
}

.card-surface {
  background: var(--paper-strong);
  border-radius: var(--radius-lg);
  border: 1px solid #efe7d6;
  overflow: hidden;
  box-shadow: 0 10px 24px rgba(40, 33, 23, 0.08);
}

.card-body {
  padding: 16px;
}

.badge {
  display: inline-flex;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 700;
  background: rgba(240, 161, 26, 0.15);
  color: #9a5a24;
}

.badge-float {
  float: right;
  margin: 2px 0 8px 12px;
}

.spotlight-copy::after {
  content: "";
  display: block;
  clear: both;
}

.hero-slides {
  display: none;
}

.spotlight-header {
  display: grid;
  gap: 6px;
  margin-bottom: 8px;
}
.meta-row {
  display: flex;
  gap: 12px;
  font-size: 0.75rem;
  color: var(--slate);
  margin-top: 10px;
}

.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.collection-card {
  height: 130px;
  border-radius: var(--radius-md);
  padding: 12px;
  color: #fff;
  display: flex;
  align-items: flex-end;
  background: linear-gradient(140deg, #414c59, #1d232a);
  background-size: cover;
  background-position: center;
}

.search-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  border-radius: 12px;
  background: #fff;
  border: 1px solid #efe7d6;
}

.search-bar input {
  border: none;
  outline: none;
  font-size: 0.9rem;
  width: 100%;
  background: transparent;
}

.chips {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 12px;
}

.chip {
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid #e3dccb;
  font-size: 0.75rem;
  color: var(--slate);
  background: #fff;
}

.chip.active {
  background: var(--accent);
  color: #1c1307;
  border-color: transparent;
}

.chip-select {
  position: relative;
}

.chip-select > summary {
  list-style: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.chip-select > summary::-webkit-details-marker {
  display: none;
}

.chip-select.active > summary {
  background: var(--accent);
  color: #1c1307;
  border-color: transparent;
}

.chip-count {
  font-size: 0.7rem;
  opacity: 0.7;
}

.chip-panel {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  min-width: 180px;
  padding: 10px;
  border-radius: 12px;
  background: #fff;
  border: 1px solid #efe7d6;
  box-shadow: 0 14px 32px rgba(24, 24, 24, 0.12);
  display: grid;
  gap: 8px;
  z-index: 20;
  max-height: 240px;
  overflow: auto;
}

.chip-option {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.8rem;
  color: var(--slate);
}

.list-card {
  display: grid;
  grid-template-columns: 92px 1fr;
  gap: 12px;
  padding: 12px;
  border-radius: var(--radius-md);
  background: #fff;
  border: 1px solid #efe7d6;
  align-items: center;
}

.list-thumb {
  height: 70px;
  border-radius: var(--radius-sm);
  background: linear-gradient(135deg, #29323f, #4a6a7e);
  background-size: cover;
  background-position: center;
}

.at-a-glance {
  display: grid;
  gap: 10px;
  padding: 14px;
  border-radius: var(--radius-md);
  background: #fff;
  border: 1px solid #efe7d6;
}

.stat-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  font-size: 0.8rem;
  color: var(--slate);
}

.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  background: #fff;
  border-top: 1px solid var(--border);
  padding: 10px 8px 14px;
  font-size: 0.7rem;
}

.bottom-nav a {
  display: grid;
  gap: 6px;
  place-items: center;
  color: var(--muted);
}

.bottom-nav a.active {
  color: var(--ink);
  font-weight: 600;
}

.page-title {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-style: italic;
  margin: 0;
}

.pill {
  display: inline-flex;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 700;
  background: #f2eee4;
  color: var(--muted);
}

.pill.green {
  background: rgba(39, 161, 108, 0.15);
  color: #1f6b4d;
}

.pill.blue {
  background: rgba(66, 122, 198, 0.15);
  color: #2a4b8f;
}

.pill.orange {
  background: rgba(233, 123, 56, 0.2);
  color: #a14d21;
}

.map-panel {
  height: 220px;
  border-radius: var(--radius-md);
  background: linear-gradient(160deg, #d7e4f0, #aac4d8);
  border: 1px solid #c8d8e4;
  position: relative;
  overflow: hidden;
}

.map-pin {
  position: absolute;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--accent);
  border: 2px solid #fff;
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

.section-muted {
  color: var(--muted);
  font-size: 0.85rem;
}

@media (min-width: 720px) {
  .app {
    max-width: 680px;
  }

  .bottom-nav {
    max-width: 680px;
    margin: 0 auto;
  }
}
