:root {
  color-scheme: dark;
  --bg: #07090c;
  --bg-soft: #0b1014;
  --panel: #11171d;
  --panel-top: #151d24;
  --panel-soft: #1a232b;
  --border: #25313a;
  --border-bright: #3a4a55;
  --text: #f2f5f7;
  --muted: #8b98a3;
  --faint: #5e6b75;
  --accent: #35e6b5;
  --accent-strong: #7ff5d4;
  --accent-dim: rgba(53, 230, 181, 0.12);
  --price: #ffd166;
  --warn: #ffb454;
  --warn-dim: rgba(255, 180, 84, 0.12);
  --error: #ff5c7a;
  --error-dim: rgba(255, 92, 122, 0.13);
}

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

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  background:
    radial-gradient(circle at 14% -8%, rgba(53, 230, 181, 0.12), transparent 30rem),
    linear-gradient(180deg, var(--bg-soft), var(--bg) 22rem);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 42px 24px 30px;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background: repeating-linear-gradient(0deg, transparent, transparent 3px, rgba(255, 255, 255, 0.018) 3px, rgba(255, 255, 255, 0.018) 4px);
  pointer-events: none;
  z-index: 10;
}

.shell,
footer {
  width: min(1220px, 100%);
}

.topbar {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  padding-bottom: 22px;
  border-bottom: 1px solid var(--border);
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--accent);
  font-family: "IBM Plex Mono", monospace;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

h1 {
  margin: 0;
  color: var(--text);
  font-size: clamp(36px, 5vw, 58px);
  font-weight: 800;
  letter-spacing: 0;
  line-height: 0.95;
}

.status,
.toolbar,
.environment-description,
.pill,
.source,
.price,
footer {
  font-family: "IBM Plex Mono", monospace;
}

.status {
  color: var(--muted);
  font-size: 11px;
  text-align: right;
  text-transform: lowercase;
  white-space: nowrap;
}

.toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 20px 0 26px;
  color: var(--muted);
  font-size: 11px;
}

button {
  appearance: none;
  border: 1px solid var(--accent);
  border-radius: 4px;
  background: var(--accent);
  color: #06100d;
  cursor: pointer;
  font: inherit;
  font-weight: 700;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  padding: 11px 16px;
  transition: background 0.15s, border-color 0.15s, opacity 0.15s;
}

button:hover {
  background: var(--accent-strong);
  border-color: var(--accent-strong);
}

button:disabled {
  cursor: wait;
  opacity: 0.45;
}

.dashboard {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  align-items: start;
}

.environment {
  min-width: 0;
}

.environment-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  min-height: 58px;
  margin-bottom: 12px;
}

.environment h2 {
  margin: 0;
  font-size: 22px;
  font-weight: 700;
  letter-spacing: 0;
}

.environment-description {
  margin: 7px 0 0;
  color: var(--muted);
  font-size: 11px;
}

.restaurant-list {
  display: grid;
  gap: 14px;
}

.restaurant {
  border: 1px solid var(--border);
  border-radius: 6px;
  background: linear-gradient(180deg, var(--panel-top), var(--panel));
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.18);
  overflow: hidden;
  transition: border-color 0.2s, transform 0.2s;
}

.restaurant:hover {
  border-color: var(--border-bright);
}

.restaurant.has-error {
  border-color: rgba(255, 92, 122, 0.7);
  background: linear-gradient(180deg, var(--error-dim), var(--panel));
}

.restaurant-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  padding: 18px 18px 15px;
  border-bottom: 1px solid var(--border);
}

.restaurant h3 {
  margin: 0;
  font-size: 19px;
  font-weight: 700;
  line-height: 1.18;
}

.meta {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 12px;
}

.pill {
  border: 1px solid rgba(139, 152, 163, 0.16);
  border-radius: 4px;
  background: var(--panel-soft);
  color: var(--muted);
  font-size: 11px;
  line-height: 1;
  padding: 6px 8px;
}

.pill.warn {
  border-color: rgba(255, 180, 84, 0.34);
  background: var(--warn-dim);
  color: var(--warn);
}

.pill.error {
  border-color: rgba(255, 92, 122, 0.42);
  background: var(--error-dim);
  color: var(--error);
}

.source {
  color: var(--accent);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.13em;
  text-decoration: none;
  text-transform: uppercase;
  white-space: nowrap;
}

.source:hover {
  color: var(--accent-strong);
}

.offers {
  display: grid;
  gap: 0;
  margin: 0;
  padding: 0;
  list-style: none;
}

.offer {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  padding: 15px 18px;
  border-bottom: 1px solid var(--border);
}

.offer:last-child {
  border-bottom: 0;
}

.offer-text {
  min-width: 0;
  color: #e9eef1;
  font-size: 15px;
  font-weight: 400;
  line-height: 1.44;
  overflow-wrap: anywhere;
}

.price {
  color: var(--price);
  font-size: 14px;
  font-weight: 600;
  white-space: nowrap;
}

.footer-note,
.empty,
.error-text {
  margin: 0;
  padding: 14px 18px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.error-text {
  color: var(--error);
}

.skeleton {
  min-height: 190px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: linear-gradient(90deg, var(--panel) 25%, var(--border-bright) 50%, var(--panel) 75%);
  background-size: 220% 100%;
  animation: shimmer 1.5s linear infinite;
}

@keyframes shimmer {
  from {
    background-position: 100% 0;
  }
  to {
    background-position: -100% 0;
  }
}

footer {
  border-top: 1px solid var(--border);
  padding-top: 20px;
  margin: 34px auto 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  font-size: 11px;
  color: var(--muted);
  text-align: center;
  flex-wrap: wrap;
}

footer a {
  color: var(--muted);
  text-decoration: none;
  border-bottom: 1px solid var(--border-bright);
  padding-bottom: 1px;
  transition: color 0.15s, border-color 0.15s;
}

footer a:hover {
  color: var(--accent);
  border-color: var(--accent);
}

.sep {
  color: var(--border-bright);
}

@media (max-width: 1050px) {
  .dashboard {
    grid-template-columns: 1fr;
  }

  .environment-header {
    min-height: 0;
  }
}

@media (max-width: 640px) {
  body {
    padding: 26px 14px;
  }

  .topbar,
  .toolbar {
    align-items: flex-start;
    flex-direction: column;
  }

  .status {
    text-align: left;
    white-space: normal;
  }

  .restaurant-head,
  .offer {
    grid-template-columns: 1fr;
  }

  .source,
  .price {
    white-space: normal;
  }
}

@media (max-width: 480px) {
  footer {
    flex-direction: column;
    gap: 10px;
  }

  .sep {
    display: none;
  }
}
