:root {
  --ink: #071416;
  --deep: #0b1f24;
  --panel: rgba(14, 42, 48, 0.72);
  --line: rgba(180, 220, 210, 0.16);
  --text: #e8f4f1;
  --muted: #9db8b2;
  --accent: #e8a04a;
  --accent-2: #3ecfad;
  --bad: #c96b6b;
  --good: #3ecfad;
  --font-display: 'Source Serif 4', Georgia, serif;
  --font-ui: 'Outfit', 'Avenir Next', sans-serif;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
}

body {
  font-family: var(--font-ui);
  color: var(--text);
  background: var(--ink);
  line-height: 1.45;
}

.atmosphere {
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(1200px 700px at 12% -10%, rgba(62, 207, 173, 0.18), transparent 55%),
    radial-gradient(900px 600px at 90% 10%, rgba(232, 160, 74, 0.14), transparent 50%),
    linear-gradient(165deg, #071416 0%, #0d2a30 48%, #08181c 100%);
}

.atmosphere::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)' opacity='0.05'/%3E%3C/svg%3E");
  opacity: 0.35;
  pointer-events: none;
}

a {
  color: var(--accent-2);
}

.top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.25rem clamp(1rem, 4vw, 2.5rem) 0;
}

.brand {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.15rem;
  color: var(--text);
  text-decoration: none;
  letter-spacing: -0.02em;
}

.tag {
  margin: 0;
  color: var(--muted);
  font-size: 0.85rem;
}

main {
  width: min(1100px, calc(100% - 2rem));
  margin: 0 auto;
  padding-bottom: 4rem;
}

.hero {
  padding: clamp(2.5rem, 8vh, 5rem) 0 1.5rem;
  animation: rise 700ms ease-out both;
}

.brand-hero {
  margin: 0 0 0.6rem;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(3rem, 9vw, 5.4rem);
  letter-spacing: -0.04em;
  line-height: 0.95;
  background: linear-gradient(120deg, #f4fff9 10%, #3ecfad 55%, #e8a04a 120%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.lede {
  margin: 0 0 1.5rem;
  max-width: 34rem;
  color: var(--muted);
  font-size: 1.1rem;
}

.search-form {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  max-width: 28rem;
}

input,
button {
  font: inherit;
}

input[type='text'],
input[type='number'],
input:not([type]),
#zip,
#radius {
  background: rgba(5, 16, 18, 0.65);
  border: 1px solid var(--line);
  color: var(--text);
  border-radius: 10px;
  padding: 0.85rem 1rem;
  min-width: 8rem;
}

#zip {
  flex: 1;
  min-width: 10rem;
  font-size: 1.15rem;
  letter-spacing: 0.04em;
}

button {
  border: 0;
  border-radius: 10px;
  padding: 0.85rem 1.2rem;
  background: var(--accent);
  color: #1a1208;
  font-weight: 600;
  cursor: pointer;
  transition: transform 160ms ease, filter 160ms ease;
}

button:hover {
  filter: brightness(1.05);
  transform: translateY(-1px);
}

button:active {
  transform: translateY(0);
}

button.secondary {
  background: var(--accent-2);
  color: #042018;
}

button.ghost {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--line);
}

.hint,
.lede-sm,
.meta {
  color: var(--muted);
  font-size: 0.92rem;
}

.filters {
  display: grid;
  gap: 0.75rem;
  margin: 1.25rem 0 2rem;
  animation: rise 800ms 80ms ease-out both;
}

.filter-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.chip {
  appearance: none;
  background: transparent;
  border: 1px solid var(--line);
  color: var(--muted);
  border-radius: 999px;
  padding: 0.45rem 0.85rem;
  font-size: 0.88rem;
  font-weight: 500;
  cursor: pointer;
}

.chip[aria-pressed='true'] {
  color: var(--ink);
  background: var(--text);
  border-color: var(--text);
}

.results,
.alerts,
.events {
  margin-top: 2.5rem;
  padding: 1.25rem 0;
  border-top: 1px solid var(--line);
  animation: rise 700ms 120ms ease-out both;
}

.results-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.5rem;
  margin-bottom: 1rem;
}

h2 {
  margin: 0 0 0.5rem;
  font-family: var(--font-display);
  font-size: 1.55rem;
  font-weight: 600;
  letter-spacing: -0.02em;
}

.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--panel);
  backdrop-filter: blur(10px);
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.86rem;
}

th,
td {
  padding: 0.7rem 0.65rem;
  text-align: center;
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}

th:first-child,
td:first-child {
  text-align: left;
  position: sticky;
  left: 0;
  background: rgba(8, 28, 32, 0.95);
  min-width: 11rem;
}

th {
  color: var(--muted);
  font-weight: 500;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.store-name {
  font-weight: 600;
}

.store-meta {
  display: block;
  color: var(--muted);
  font-size: 0.75rem;
  font-weight: 400;
  white-space: normal;
  max-width: 14rem;
}

.avail {
  font-weight: 600;
}

.avail.yes {
  color: var(--good);
}

.avail.no {
  color: var(--bad);
  opacity: 0.75;
}

.buy-link {
  display: inline-block;
  margin-top: 0.25rem;
  font-size: 0.75rem;
}

.alert-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  align-items: end;
  margin: 1rem 0 0.5rem;
}

.alert-controls label {
  display: grid;
  gap: 0.35rem;
  color: var(--muted);
  font-size: 0.85rem;
}

.alert-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.event-list {
  list-style: none;
  margin: 0.75rem 0 0;
  padding: 0;
  display: grid;
  gap: 0.5rem;
}

.event-list li {
  padding: 0.75rem 0.9rem;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(8, 24, 28, 0.45);
  font-size: 0.9rem;
}

.event-list .in {
  color: var(--good);
}

.event-list .out {
  color: var(--bad);
}

.footer {
  width: min(1100px, calc(100% - 2rem));
  margin: 0 auto 2.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.85rem;
}

.footer strong {
  color: var(--text);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 640px) {
  .top .tag {
    display: none;
  }

  th,
  td {
    padding: 0.55rem 0.45rem;
  }
}
