:root {
  color-scheme: dark;
  --bg: #070b10;
  --panel: #101822;
  --panel-soft: #142130;
  --text: #f3f7fb;
  --muted: #9fb0bf;
  --line: rgba(255, 255, 255, 0.11);
  --green: #75f0b8;
  --cyan: #6bd9ff;
  --orange: #ffb86b;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.36);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at 8% 0%, rgba(117, 240, 184, 0.18), transparent 30rem),
    radial-gradient(circle at 95% 20%, rgba(107, 217, 255, 0.13), transparent 28rem),
    linear-gradient(145deg, #070b10 0%, #101722 54%, #071016 100%);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

button,
input,
textarea {
  font: inherit;
}

.shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 36px 0 56px;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(360px, 1.05fr);
  gap: 28px;
  align-items: stretch;
  min-height: 420px;
}

.hero-copy {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  padding: 12px 0 30px;
}

.logo {
  width: 86px;
  height: 86px;
  object-fit: contain;
  margin-bottom: 30px;
  filter: drop-shadow(0 16px 32px rgba(117, 240, 184, 0.18));
}

.eyebrow,
.label {
  margin: 0;
  color: var(--green);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  max-width: 780px;
  margin-bottom: 18px;
  font-size: clamp(2.45rem, 5.1vw, 4.35rem);
  line-height: 0.96;
  letter-spacing: 0;
}

.lede {
  max-width: 600px;
  color: var(--muted);
  font-size: 1.08rem;
  line-height: 1.7;
}

.panel,
.results,
.summary,
.toolbar {
  border: 1px solid var(--line);
  background: rgba(16, 24, 34, 0.78);
  box-shadow: var(--shadow);
  backdrop-filter: blur(22px);
}

.panel {
  border-radius: 8px;
  padding: 22px;
}

.input-panel {
  display: flex;
  flex-direction: column;
  min-height: 460px;
}

.panel-head,
.results-head,
.toolbar,
.actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.panel h2,
.results h2 {
  margin: 4px 0 0;
  font-size: 1.28rem;
}

.ghost-button {
  min-height: 40px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.04);
  cursor: pointer;
}

textarea {
  flex: 1;
  width: 100%;
  min-height: 280px;
  margin: 20px 0;
  padding: 18px;
  resize: vertical;
  border: 1px solid rgba(117, 240, 184, 0.2);
  border-radius: 8px;
  outline: none;
  color: var(--text);
  background: rgba(4, 8, 12, 0.62);
  line-height: 1.55;
}

textarea:focus,
input:focus {
  border-color: rgba(117, 240, 184, 0.72);
  box-shadow: 0 0 0 4px rgba(117, 240, 184, 0.09);
}

.actions button {
  min-height: 46px;
  padding: 0 18px;
  border: 0;
  border-radius: 8px;
  color: #03100b;
  background: linear-gradient(135deg, var(--green), var(--cyan));
  font-weight: 800;
  cursor: pointer;
}

#statusText,
#resultsMeta {
  margin: 0;
  color: var(--muted);
  font-size: 0.92rem;
}

.summary {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  margin: 28px 0 16px;
  border-radius: 8px;
  overflow: hidden;
}

.stat {
  min-height: 112px;
  padding: 22px;
  background: rgba(255, 255, 255, 0.025);
}

.stat span {
  display: block;
  margin-bottom: 8px;
  font-size: 2rem;
  font-weight: 850;
}

.stat p {
  margin: 0;
  color: var(--muted);
}

.stat.accent span {
  color: var(--green);
}

.toolbar {
  margin-bottom: 16px;
  padding: 14px;
  border-radius: 8px;
}

.tabs {
  display: flex;
  gap: 8px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.2);
}

.tab {
  min-height: 38px;
  padding: 0 16px;
  border: 0;
  border-radius: 6px;
  color: var(--muted);
  background: transparent;
  cursor: pointer;
}

.tab.active {
  color: #06100d;
  background: var(--green);
  font-weight: 800;
}

.search {
  display: grid;
  gap: 6px;
  min-width: min(320px, 100%);
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
}

.search input {
  min-height: 42px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  outline: none;
  color: var(--text);
  background: rgba(0, 0, 0, 0.22);
}

.results {
  border-radius: 8px;
  padding: 22px;
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 16px;
  margin-top: 20px;
}

.card {
  min-height: 100%;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: inherit;
  background: rgba(255, 255, 255, 0.035);
  transition: transform 160ms ease, border-color 160ms ease, background 160ms ease;
}

.card:hover {
  transform: translateY(-3px);
  border-color: rgba(117, 240, 184, 0.48);
  background: rgba(255, 255, 255, 0.06);
}

.cover-wrap {
  position: relative;
  display: block;
  aspect-ratio: 16 / 9;
  background: var(--panel-soft);
  text-decoration: none;
}

.cover-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.badge {
  position: absolute;
  left: 12px;
  top: 12px;
  padding: 6px 10px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 999px;
  color: #06100d;
  background: rgba(117, 240, 184, 0.92);
  font-size: 0.73rem;
  font-weight: 850;
  text-transform: uppercase;
}

.card-body {
  padding: 16px;
}

.title-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: start;
  margin-bottom: 14px;
}

.title-link {
  color: var(--text);
  font-size: 1rem;
  font-weight: 800;
  line-height: 1.35;
  text-decoration: none;
}

.title-link:hover {
  color: var(--green);
}

.copy-button {
  min-height: 30px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 7px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.045);
  font-size: 0.74rem;
  font-weight: 800;
  cursor: pointer;
}

.copy-button:hover,
.copy-button.copied {
  border-color: rgba(117, 240, 184, 0.52);
  color: #06100d;
  background: var(--green);
}

.meta-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
  font-size: 0.86rem;
}

.empty {
  margin-top: 20px;
  padding: 42px 22px;
  border: 1px dashed rgba(255, 255, 255, 0.18);
  border-radius: 8px;
  text-align: center;
  background: rgba(255, 255, 255, 0.025);
}

.empty h3 {
  margin-bottom: 8px;
}

.empty p {
  margin-bottom: 0;
  color: var(--muted);
}

.hidden {
  display: none;
}

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

  .summary {
    grid-template-columns: 1fr;
  }

  .toolbar,
  .panel-head,
  .results-head,
  .actions {
    align-items: stretch;
    flex-direction: column;
  }

  .tabs,
  .actions button,
  .ghost-button {
    width: 100%;
  }

  .tab {
    flex: 1;
  }
}

@media (max-width: 520px) {
  .shell {
    width: min(100% - 20px, 1180px);
    padding-top: 18px;
  }

  h1 {
    font-size: 2.32rem;
  }

  .grid {
    grid-template-columns: 1fr;
  }
}
