:root {
  color-scheme: light;
  --bg: #eef1f4;
  --panel: #ffffff;
  --text: #15191f;
  --muted: #68717d;
  --line: #d7dde4;
  --accent: #0d7c66;
  --accent-strong: #075f50;
  --danger: #aa3030;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  font-family: Inter, "Segoe UI", system-ui, sans-serif;
  color: var(--text);
  background: var(--bg);
}

button, input, select { font: inherit; }

a {
  color: inherit;
  text-decoration: none;
}

.site-shell {
  min-height: 100vh;
  background: #f4f6f8;
}

.site-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 18px 28px;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.92);
}

.brand-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
}

.nav-actions,
.hero-actions,
.auth-links {
  display: flex;
  align-items: center;
  gap: 14px;
}

.nav-button,
.primary-link,
.secondary-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 0 16px;
  border-radius: 7px;
  font-weight: 800;
}

.language-select {
  width: auto;
  min-height: 34px;
  padding: 5px 8px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  font-weight: 800;
}

.language-switch-label {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.language-select.compact {
  max-width: 86px;
}

.nav-button,
.primary-link {
  background: var(--accent);
  color: #fff;
}

.secondary-link {
  border: 1px solid var(--line);
  background: #fff;
}

.hero {
  display: grid;
  grid-template-columns: minmax(320px, 0.9fr) minmax(360px, 1.1fr);
  gap: 40px;
  align-items: center;
  max-width: 1180px;
  margin: 0 auto;
  padding: 68px 28px 48px;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--accent-strong);
  font-size: 13px;
  font-weight: 900;
  text-transform: uppercase;
}

.hero h1 {
  margin: 0;
  font-size: clamp(42px, 7vw, 82px);
  line-height: 0.95;
  letter-spacing: 0;
}

.hero-lead {
  max-width: 620px;
  margin: 22px 0 26px;
  color: #4f5a66;
  font-size: 18px;
  line-height: 1.65;
}

.hero-preview {
  position: relative;
  min-height: 430px;
  overflow: hidden;
  border: 1px solid #1d2b35;
  border-radius: 8px;
  background: linear-gradient(135deg, #05080b, #11242c);
  box-shadow: 0 30px 80px rgba(14, 28, 36, 0.28);
}

.preview-lines {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
}

.preview-lines span {
  border-right: 1px solid rgba(120, 230, 220, 0.16);
}

.preview-note {
  position: absolute;
  width: 54px;
  border-radius: 999px;
  box-shadow: 0 0 28px currentColor;
}

.preview-note.n1 { left: 14%; top: 8%; height: 118px; color: #31c6ff; background: #31c6ff; }
.preview-note.n2 { left: 36%; top: 26%; height: 170px; color: #ff6b8a; background: #ff6b8a; }
.preview-note.n3 { left: 58%; top: 14%; height: 138px; color: #8be15a; background: #8be15a; }
.preview-note.n4 { left: 78%; top: 38%; height: 130px; color: #ffb84d; background: #ffb84d; }

.preview-playline {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 26%;
  height: 4px;
  background: #52d6b6;
  box-shadow: 0 0 24px #52d6b6;
}

.feature-band {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  max-width: 1180px;
  margin: 0 auto;
  padding: 24px 28px 70px;
}

.feature-band article,
.price-card,
.auth-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.feature-band article {
  padding: 22px;
}

.feature-band h2 {
  margin: 0 0 8px;
  font-size: 20px;
}

.feature-band p {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(280px, 420px));
  gap: 20px;
  justify-content: center;
  padding: 70px 24px;
}

.price-card {
  display: grid;
  gap: 18px;
  padding: 28px;
}

.price-card.featured {
  border-color: var(--accent);
  box-shadow: 0 18px 50px rgba(13, 124, 102, 0.16);
}

.price-card h1 {
  margin: 0;
  font-size: 32px;
}

.price {
  margin: 0;
  color: var(--accent-strong);
  font-size: 24px;
  font-weight: 900;
}

.price-card ul {
  display: grid;
  gap: 10px;
  margin: 0;
  padding-left: 20px;
  color: #3d4854;
}

.auth-shell {
  display: grid;
  min-height: 100vh;
  place-items: center;
  padding: 24px;
  background: #eef1f4;
}

.auth-card {
  display: grid;
  width: min(100%, 460px);
  gap: 18px;
  padding: 28px;
}

.auth-card h1 {
  margin: 0;
  font-size: 34px;
}

.app-shell {
  display: grid;
  grid-template-columns: minmax(360px, 430px) 1fr;
  min-height: 100vh;
}

.settings-panel {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 22px;
  background: var(--panel);
  border-right: 1px solid var(--line);
  overflow-y: auto;
}

.brand, .account-panel, .preview-toolbar {
  display: flex;
  align-items: center;
}

.brand { gap: 12px; }

.brand-mark {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border-radius: 8px;
  background: #111820;
  color: #fff;
  font-weight: 800;
}

.brand h1 {
  margin: 0;
  font-size: 19px;
  letter-spacing: 0;
}

.brand p, .hint {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.account-panel {
  justify-content: space-between;
  gap: 12px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f9fafb;
}

.account-actions {
  display: flex;
  gap: 8px;
}

.plan-badge {
  display: inline-block;
  margin-right: 8px;
  padding: 4px 7px;
  border-radius: 999px;
  background: #e9edf2;
  color: #35404c;
  font-size: 12px;
  font-weight: 800;
}

.plan-badge.premium {
  background: #102820;
  color: #6df2b8;
}

.panel-section {
  padding-top: 16px;
  border-top: 1px solid var(--line);
}

.section-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
  font-weight: 700;
}

.field-label {
  display: block;
  margin-bottom: 7px;
  color: #2f3741;
  font-size: 13px;
  font-weight: 700;
}

input[type="file"], select, input[type="text"] {
  width: 100%;
  min-height: 38px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
}

input[type="number"],
input[type="range"] {
  width: 100%;
}

.grid-fields, .track-list, .export-box {
  display: grid;
  gap: 12px;
}

.empty-state {
  padding: 14px;
  border: 1px dashed var(--line);
  border-radius: 8px;
  color: var(--muted);
  text-align: center;
}

.track-row {
  display: grid;
  grid-template-columns: 24px 68px minmax(0, 1fr) 44px;
  gap: 8px;
  align-items: center;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfd;
}

.track-row input[type="color"] {
  width: 42px;
  height: 38px;
  padding: 3px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
}

.track-meta {
  grid-column: 2 / -1;
  color: var(--muted);
  font-size: 12px;
}

.effect-list {
  display: grid;
  gap: 10px;
}

.effect-group {
  display: grid;
  gap: 6px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfd;
}

.effect-title {
  color: #2f3741;
  font-size: 12px;
  font-weight: 800;
}

.effect-row {
  display: flex;
  gap: 8px;
  align-items: center;
  min-height: 28px;
  color: #27313c;
  font-size: 13px;
}

.icon-button, .transport-button, .small-button {
  display: inline-grid;
  min-width: 36px;
  height: 36px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  cursor: pointer;
}

.small-button {
  padding: 0 10px;
  white-space: nowrap;
  font-size: 13px;
  font-weight: 700;
}

.small-button.accent {
  border-color: var(--accent);
  color: var(--accent-strong);
}

.primary-button, .secondary-button {
  width: 100%;
  min-height: 42px;
  border-radius: 7px;
  font-weight: 800;
  cursor: pointer;
}

.primary-button {
  border: 0;
  background: var(--accent);
  color: #fff;
}

.secondary-button {
  margin-top: 10px;
  border: 1px solid var(--line);
  background: #f5f7f9;
  color: #17202a;
}

.primary-button:hover { background: var(--accent-strong); }
.secondary-button:hover { background: #edf1f4; }
.primary-button:disabled { cursor: not-allowed; opacity: 0.55; }

.export-formats {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.format-pill {
  padding: 5px 8px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1;
}

.format-pill.active {
  border-color: var(--accent);
  color: var(--accent-strong);
  font-weight: 800;
}

.format-pill.premium::after {
  content: " Pro";
  color: var(--danger);
  font-weight: 800;
}

progress {
  width: 100%;
  height: 10px;
}

.preview-panel {
  display: grid;
  grid-template-rows: auto 1fr;
  min-width: 0;
}

.preview-toolbar {
  display: grid;
  grid-template-columns: auto auto 1fr auto;
  gap: 10px;
  padding: 14px 18px;
  border-bottom: 1px solid var(--line);
  background: #f9fafb;
}

#seekBar { width: 100%; }

#timeLabel {
  color: var(--muted);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.canvas-wrap {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 0;
  padding: 18px;
  background: #cfd6de;
}

#previewCanvas {
  width: min(100%, calc((100vh - 92px) * 16 / 9));
  max-height: calc(100vh - 92px);
  aspect-ratio: 16 / 9;
  border: 1px solid #aeb7c2;
  background: #fff;
}

.preview-caption {
  position: absolute;
  right: 28px;
  bottom: 28px;
  padding: 6px 9px;
  border-radius: 6px;
  background: rgba(17, 24, 32, 0.72);
  color: #fff;
  font-size: 12px;
}

@media (max-width: 940px) {
  .site-nav,
  .nav-actions {
    align-items: flex-start;
    flex-direction: column;
  }

  .hero,
  .feature-band,
  .pricing-grid {
    grid-template-columns: 1fr;
  }

  .hero-preview {
    min-height: 320px;
  }

  .app-shell { grid-template-columns: 1fr; }
  .settings-panel {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }
  .preview-toolbar { grid-template-columns: auto auto 1fr; }
  #timeLabel { grid-column: 1 / -1; }
}
