/* Uitvlucht — mobile-first, dark by default */

:root {
  --bg: #1a1030;
  --bg-deep: #13092a;
  --fg: #f5f0fa;
  --muted: #a89dc4;
  --accent: #f5c518;
  --accent-deep: #c89e10;
  --card: #2c1854;
  --card-soft: #3a2167;
  --radius: 18px;
  --tap: 44px;
  --safe-top: env(safe-area-inset-top, 0);
  --safe-bottom: env(safe-area-inset-bottom, 0);
}

@media (prefers-color-scheme: light) {
  :root {
    --bg: #faf6ff;
    --bg-deep: #ece4f5;
    --fg: #1a1030;
    --muted: #5a5070;
    --accent: #c89e10;
    --accent-deep: #a07d04;
    --card: #ffffff;
    --card-soft: #f4ebff;
  }
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: radial-gradient(circle at top, var(--card) 0%, var(--bg) 60%, var(--bg-deep) 100%);
  color: var(--fg);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  min-height: 100vh;
  min-height: 100dvh;
  overflow-x: hidden;
}

.app {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  padding: calc(1.25rem + var(--safe-top)) 1.25rem calc(1.25rem + var(--safe-bottom));
  max-width: 600px;
  margin: 0 auto;
  min-height: 100vh;
  min-height: 100dvh;
}

.top h1 {
  margin: 0;
  font-size: clamp(2rem, 8vw, 3rem);
  font-weight: 900;
  letter-spacing: -0.03em;
  background: linear-gradient(135deg, var(--fg), var(--accent));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.tagline {
  margin: 0.25rem 0 0;
  color: var(--muted);
  font-size: 0.95rem;
  font-style: italic;
}

.card {
  background: var(--card);
  border: 1px solid rgba(245, 197, 24, 0.18);
  border-radius: var(--radius);
  padding: 1.5rem 1.25rem;
  min-height: 12rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  box-shadow: 0 8px 30px -10px rgba(0, 0, 0, 0.5);
}

.cat-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
}

.cat-emoji { font-size: 1.5rem; }
.cat-label {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
}

.excuse {
  margin: 0;
  font-size: clamp(1.1rem, 4vw, 1.4rem);
  line-height: 1.5;
  font-weight: 500;
  transition: opacity 200ms ease;
}

.excuse.shake { animation: shake 320ms; }

@keyframes shake {
  0%, 100% { transform: translateX(0); }
  20% { transform: translateX(-4px); }
  40% { transform: translateX(4px); }
  60% { transform: translateX(-2px); }
  80% { transform: translateX(2px); }
}

.primary {
  appearance: none;
  border: none;
  background: linear-gradient(135deg, var(--accent), var(--accent-deep));
  color: #1a1030;
  font-weight: 900;
  font-size: 1.1rem;
  padding: 1.1rem 1.25rem;
  border-radius: 14px;
  min-height: var(--tap);
  cursor: pointer;
  box-shadow: 0 6px 18px -4px var(--accent);
  transition: transform 80ms ease, box-shadow 80ms ease;
}

.primary:hover { transform: translateY(-1px); box-shadow: 0 10px 22px -4px var(--accent); }
.primary:active { transform: translateY(1px); box-shadow: 0 3px 10px -2px var(--accent); }

.filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  justify-content: center;
}

.chip {
  appearance: none;
  background: transparent;
  border: 1px solid rgba(245, 197, 24, 0.35);
  color: var(--muted);
  padding: 0.45rem 0.85rem;
  border-radius: 999px;
  font-size: 0.85rem;
  cursor: pointer;
  transition: background 100ms ease, color 100ms ease;
}

.chip.is-on {
  background: var(--accent);
  color: #1a1030;
  border-color: var(--accent);
  font-weight: 700;
}

.actions {
  display: flex;
  gap: 0.5rem;
  justify-content: center;
}

.ghost {
  appearance: none;
  background: transparent;
  border: 1px solid var(--card-soft);
  color: var(--fg);
  padding: 0.65rem 1.1rem;
  border-radius: 999px;
  font-size: 0.9rem;
  cursor: pointer;
}

.foot {
  margin-top: auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--muted);
  font-size: 0.75rem;
  padding-top: 1rem;
}

.offline { color: var(--accent); font-weight: 700; }
.offline.hidden { display: none; }

@media (prefers-reduced-motion: reduce) {
  .excuse.shake { animation: none; }
  .primary { transition: none; }
}
