:root {
  --bg-start: #0ea5e9; /* sky-400 */
  --bg-end: #6366f1;   /* indigo-500 */
  --surface: rgba(255, 255, 255, 0.08);
  --card: rgba(255, 255, 255, 0.12);
  --border: rgba(255, 255, 255, 0.25);
  --accent: #60a5fa;   /* blue-400 */
  --accent-strong: #3b82f6; /* blue-500 */
  --text: #0b1220;
  --text-strong: #0b1220;
  --muted: rgba(255,255,255,0.8);
}

@media (prefers-color-scheme: dark) {
  :root {
    --text: #e5e7eb;
    --text-strong: #ffffff;
  }
}

* { box-sizing: border-box }

html, body {
  height: 100%;
}

body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, "Apple Color Emoji", "Segoe UI Emoji";
  color: var(--text);
  background: linear-gradient(135deg, var(--bg-start), var(--bg-end));
  background-attachment: fixed;
  position: relative;
}

/* Subtle animated gradient glow */
body::before {
  content: "";
  position: fixed;
  inset: -20% -10% -30% -10%;
  background: radial-gradient(40% 40% at 20% 20%, rgba(255,255,255,0.35), transparent 60%),
              radial-gradient(35% 35% at 80% 30%, rgba(255,255,255,0.25), transparent 60%),
              radial-gradient(25% 25% at 50% 80%, rgba(255,255,255,0.2), transparent 60%);
  filter: blur(48px);
  z-index: 0;
}

.app {
  position: relative;
  z-index: 1;
  width: 980px;
  max-width: 92vw;
  margin: 56px auto;
  padding: 16px 0 32px;
}

header {
  text-align: center;
  margin-bottom: 18px;
}

header .badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  color: var(--muted);
  background: var(--surface);
  border: 1px solid var(--border);
  padding: 6px 12px;
  border-radius: 999px;
  backdrop-filter: blur(10px);
}

header h1 {
  margin: 14px 0 8px;
  font-size: clamp(28px, 5vw, 46px);
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: #fff;
}

header p {
  color: var(--muted);
  margin: 0 0 22px;
}

.search {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  margin: 0 auto 16px;
  width: min(720px, 100%);
}

.search .field {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  backdrop-filter: blur(10px);
  box-shadow: 0 10px 30px rgba(0,0,0,0.15);
}

.search input {
  flex: 1;
  padding: 10px 2px;
  color: #fff;
  background: transparent;
  border: 0;
  outline: none;
  font-size: 16px;
}

.search input::placeholder { color: rgba(255,255,255,0.7) }

.search button {
  padding: 12px 16px;
  font-weight: 600;
  color: #0b1220;
  background: linear-gradient(135deg, #fff, #dbeafe);
  border: 0;
  border-radius: 14px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.18);
  cursor: pointer;
  transition: transform .12s ease, box-shadow .12s ease;
}

.search button:hover { transform: translateY(-1px); box-shadow: 0 14px 32px rgba(0,0,0,0.22) }
.search button:active { transform: translateY(0) }
.search button:disabled { opacity: .7; cursor: not-allowed }

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  margin: 6px 0 20px;
}

.chip {
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid var(--border);
  color: #fff;
  background: rgba(255,255,255,0.08);
  backdrop-filter: blur(10px);
  cursor: pointer;
  transition: background .12s ease;
}
.chip:hover { background: rgba(255,255,255,0.15) }

.error {
  color: #ffe1e1;
  background: rgba(255, 67, 67, 0.15);
  border: 1px solid rgba(255, 67, 67, 0.35);
  border-radius: 12px;
  padding: 10px 12px;
  margin: 10px auto;
  width: min(720px, 100%);
}

.card {
  width: min(720px, 100%);
  margin: 12px auto 0;
  background: linear-gradient(180deg, rgba(255,255,255,0.18), rgba(255,255,255,0.08));
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 18px;
  box-shadow: 0 18px 48px rgba(0,0,0,0.25);
  backdrop-filter: blur(12px);
  color: #fff;
  animation: fadeIn .3s ease;
}

.row { display: grid; grid-template-columns: auto 1fr; gap: 16px; align-items: center }
.big { font-size: 62px; font-weight: 800; letter-spacing: -0.02em }
.meta { color: rgba(255,255,255,0.9) }
.meta .grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-top: 6px }

.iconWrap {
  width: 72px; height: 72px; border-radius: 50%;
  display: grid; place-items: center;
  background: linear-gradient(180deg, rgba(255,255,255,0.45), rgba(255,255,255,0.15));
  border: 1px solid rgba(255,255,255,0.45);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.6);
}

footer {
  margin-top: 18px;
  text-align: center;
  color: rgba(255,255,255,0.85);
}

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

/* Responsive tweaks */
@media (max-width: 520px) {
  .row { grid-template-columns: 1fr; }
  .big { font-size: 48px; }
}
