:root {
  --bg: #07111f;
  --panel: rgba(9, 20, 36, 0.88);
  --panel-soft: rgba(255, 255, 255, 0.035);
  --text: #f2f7fb;
  --muted: #9caec0;
  --accent: #28d7a1;
  --accent-2: #1ba7ff;
  --border: rgba(154, 178, 201, 0.16);
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Tahoma", "Arial", sans-serif;
  background:
    radial-gradient(circle at 15% 5%, rgba(27, 167, 255, 0.17), transparent 28%),
    radial-gradient(circle at 85% 20%, rgba(40, 215, 161, 0.12), transparent 26%),
    linear-gradient(145deg, #030912, var(--bg) 55%, #071725);
  color: var(--text);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: 0.35;
  background-image: linear-gradient(rgba(255,255,255,.025) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.025) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: linear-gradient(to bottom, black, transparent 78%);
}

.shell {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 44px 20px;
}

.card {
  position: relative;
  width: min(900px, 100%);
  padding: clamp(24px, 5vw, 48px);
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 30px;
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.45), inset 0 1px rgba(255, 255, 255, 0.04);
  backdrop-filter: blur(22px);
  overflow: hidden;
}

.card::after {
  content: "";
  position: absolute;
  width: 240px;
  height: 240px;
  top: -150px;
  left: -110px;
  border-radius: 50%;
  background: rgba(40, 215, 161, 0.12);
  filter: blur(8px);
  pointer-events: none;
}

.hero { text-align: center; }

.status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 13px;
  border: 1px solid rgba(40, 215, 161, 0.2);
  border-radius: 999px;
  background: rgba(40, 215, 161, 0.07);
  color: #9df5d8;
  font-size: 0.82rem;
  font-weight: 700;
}

.status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 5px rgba(40, 215, 161, 0.1);
}

h1 {
  margin: 18px 0 0;
  font-size: clamp(2.35rem, 7vw, 4.4rem);
  line-height: 1.08;
  letter-spacing: -0.045em;
}

h1 span {
  color: transparent;
  background: linear-gradient(90deg, var(--accent), #6ddcff);
  background-clip: text;
  -webkit-background-clip: text;
}

.lead {
  max-width: 580px;
  margin: 18px auto 0;
  color: var(--muted);
  line-height: 1.8;
  font-size: 1.02rem;
}

.form {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  margin-top: 34px;
  padding: 9px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: rgba(1, 7, 14, 0.55);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.03);
}

.quality-picker {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin: 0;
  padding: 0 2px 3px;
  border: 0;
}

.quality-picker[hidden] { display: none; }

.quality-picker legend {
  width: 100%;
  margin-bottom: 3px;
  color: #7890a5;
  font-size: .72rem;
  font-weight: 700;
}

.quality-option {
  position: relative;
  width: auto;
  height: auto;
  overflow: visible;
  clip: auto;
  cursor: pointer;
}

.quality-option input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.quality-option span {
  display: block;
  padding: 7px 12px;
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 999px;
  background: rgba(255,255,255,.035);
  color: #8499ac;
  font-size: .74rem;
  font-weight: 800;
  transition: .2s ease;
}

.quality-option input:checked + span {
  border-color: rgba(40,215,161,.3);
  background: rgba(40,215,161,.11);
  color: #a1f7dc;
}

label {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
}

.input-wrap { position: relative; min-width: 0; }

input {
  width: 100%;
  height: 56px;
  padding: 0 16px 0 100px;
  border-radius: 12px;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--text);
  font-size: 1rem;
}

input::placeholder { color: #61768b; }
input:focus { background: rgba(255,255,255,.025); }

.download-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-width: 165px;
  padding: 0 22px;
  border: 0;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--accent), #4fd6ff);
  color: #001814;
  font-weight: 800;
  font-size: 1rem;
  cursor: pointer;
  box-shadow: 0 8px 25px rgba(40, 215, 161, 0.18);
  transition: transform .2s ease, box-shadow .2s ease;
}

.download-button:hover { transform: translateY(-2px); box-shadow: 0 12px 30px rgba(40, 215, 161, 0.28); }
.download-button:disabled { cursor: wait; opacity: .72; transform: none; }

.download-button svg,
.stat-icon svg {
  width: 19px;
  height: 19px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.paste-button {
  position: absolute;
  z-index: 2;
  top: 50%;
  left: 8px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-width: 76px;
  height: 40px;
  padding: 0 12px;
  transform: translateY(-50%);
  border: 1px solid rgba(40, 215, 161, .18);
  border-radius: 10px;
  background: rgba(40, 215, 161, .08);
  color: #9df5d8;
  font-family: inherit;
  font-weight: 800;
  cursor: pointer;
  transition: background .2s ease, border-color .2s ease;
}

.paste-button:hover { background: rgba(40, 215, 161, .14); border-color: rgba(40, 215, 161, .3); }
.paste-button svg {
  width: 15px;
  height: 15px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.alert {
  margin-top: 18px;
  padding: 14px 16px;
  border-radius: 12px;
  background: rgba(248, 113, 113, 0.15);
  border: 1px solid rgba(248, 113, 113, 0.35);
  color: #fecaca;
}

.processing-note {
  margin: 13px 0 0;
  color: #91a6b9;
  text-align: center;
  font-size: .78rem;
}

.processing-note span {
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-left: 6px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 5px rgba(40,215,161,.08);
  animation: pulse 1.1s ease-in-out infinite;
}

@keyframes pulse { 50% { opacity: .35; transform: scale(.8); } }

.download-stat {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 11px;
  width: fit-content;
  margin: 22px auto 0;
  padding: 10px 15px;
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 14px;
  background: rgba(255,255,255,.035);
}

.stat-icon {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 10px;
  background: linear-gradient(135deg, rgba(40,215,161,.2), rgba(27,167,255,.16));
  color: var(--accent);
  font-weight: 900;
}

.download-stat p { margin: 0; }
.download-stat strong { display: block; color: #fff; font-size: 1rem; line-height: 1; }
.download-stat small { display: block; margin-top: 4px; color: #758a9f; font-size: .68rem; }

.supported {
  margin-top: 42px;
  padding-top: 30px;
  border-top: 1px solid var(--border);
}

.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.section-kicker {
  margin: 0 0 5px;
  color: var(--accent);
  font-size: .76rem;
  font-weight: 800;
}

h2 { margin: 0; font-size: 1.45rem; }

.live-badge {
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(255,255,255,.05);
  color: var(--muted);
  font-size: .75rem;
}

.platform-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.platform {
  display: flex;
  align-items: center;
  gap: 11px;
  min-width: 0;
  padding: 14px 12px;
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 15px;
  background: var(--panel-soft);
  transition: border-color .2s ease, transform .2s ease, background .2s ease;
}

.platform:hover { transform: translateY(-3px); border-color: rgba(255,255,255,.17); background: rgba(255,255,255,.055); }

.platform-icon {
  display: grid;
  place-items: center;
  flex: 0 0 36px;
  width: 36px;
  height: 36px;
  border-radius: 11px;
  background: rgba(255,255,255,.07);
  font-family: Arial, sans-serif;
  font-size: 1.05rem;
  font-weight: 900;
}

.platform-icon svg {
  width: 21px;
  height: 21px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.platform-icon svg .fill-icon { fill: currentColor; stroke: none; }

.platform div { min-width: 0; }
.platform strong, .platform small { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.platform strong { font-size: .86rem; }
.platform small { margin-top: 4px; color: #70869b; font-size: .68rem; }
.youtube .platform-icon { color: #ff5d68; background: rgba(255, 61, 75, .1); }
.tiktok .platform-icon { color: #65f5e5; background: rgba(68, 244, 224, .09); }
.instagram .platform-icon { color: #ff7ec4; background: rgba(255, 79, 167, .1); }
.facebook .platform-icon { color: #71a8ff; background: rgba(56, 129, 246, .1); }
.twitter .platform-icon { color: #fff; }
.vimeo .platform-icon { color: #5dccff; background: rgba(29, 185, 238, .1); }
.soundcloud .platform-icon { color: #ff9653; background: rgba(255, 103, 31, .1); }
.twitch .platform-icon { color: #b993ff; background: rgba(145, 70, 255, .1); }

.support-note {
  margin: 15px 0 0;
  color: #71869a;
  font-size: .75rem;
  text-align: center;
}

.note {
  margin: 28px 0 -12px;
  color: #64798d;
  line-height: 1.7;
  text-align: center;
  font-size: .73rem;
}

@media (max-width: 720px) {
  .shell { padding: 16px 12px; align-items: start; }
  .card { padding: 25px 17px; border-radius: 24px; }
  .form { grid-template-columns: 1fr; }
  .download-button { height: 54px; }
  .platform-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

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