:root {
  --bg: #121212;
  --panel: #1a1a1a;
  --text: #e8e8e8;
  --muted: #ababab;
  --line: #333;
  --field: #242424;
  --button: #3b3737;
  --button-hover: #4a4444;
  --error: #ffb6b6;
  --radius: 18px;
  --max: 560px;
}

* { box-sizing: border-box; }

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

.wrap {
  width: min(100%, var(--max));
  margin: 8vh auto 0;
}

.card {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
}

.section { padding: 22px; }

h1 {
  margin: 0;
  font-size: 1.4rem;
  line-height: 1.35;
}

h2 {
  margin: 26px 0 0;
  font-size: 1.08rem;
  line-height: 1.4;
}

p {
  margin: 12px 0 0;
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.55;
}

form { margin-top: 22px; }

label {
  display: block;
  font-size: 1rem;
  line-height: 1.4;
}

input[type="text"],
input[type="email"],
textarea {
  display: block;
  width: 100%;
  margin-top: 8px;
  padding: 13px 14px;
  border: 1px solid #494949;
  border-radius: 11px;
  background: var(--field);
  color: var(--text);
  font: inherit;
}

textarea {
  min-height: 150px;
  resize: vertical;
}

input[type="text"]:focus-visible,
input[type="email"]:focus-visible,
textarea:focus-visible,
button:focus-visible,
a:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 2px;
}

.consent {
  display: grid;
  grid-template-columns: 20px 1fr;
  gap: 10px;
  align-items: start;
  margin-top: 16px;
  color: var(--muted);
}

.consent input {
  width: 18px;
  height: 18px;
  margin: 2px 0 0;
}

button {
  width: 100%;
  margin-top: 18px;
  padding: 13px 16px;
  border: 1px solid #555;
  border-radius: 12px;
  background: var(--button);
  color: var(--text);
  font: inherit;
  font-weight: 650;
  cursor: pointer;
}

button:hover { background: var(--button-hover); }

.test-note {
  margin-top: 18px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
  font-size: .9rem;
}

.privacy-note {
  margin-top: 14px;
  font-size: .9rem;
}

a { color: #d7d7d7; }

.legal-list {
  margin: 10px 0 0;
  padding-left: 22px;
  color: var(--muted);
  line-height: 1.55;
}

.legal-list li + li { margin-top: 6px; }

.back-link {
  display: inline-block;
  margin-top: 18px;
  color: var(--muted);
}

.error { color: var(--error); }

.hp-field {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

@media (max-width: 420px) {
  .wrap { margin-top: 3vh; }
  .section { padding: 18px; }
}

.prototype-page .wrap {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-top: 0;
}

.prototype-page .section { padding: 16px; }

.prototype-page .banner {
  width: 100%;
  aspect-ratio: 4 / 2;
  overflow: hidden;
  background: #000;
}

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

.prototype-page .intro { text-align: center; }

.prototype-page .intro h1 {
  font-size: 1.24rem;
  font-weight: 650;
}

.prototype-page .intro p { font-size: .94rem; }

.prototype-page .section-title {
  margin: 10px 2px 0;
  font-size: 1.18rem;
}

.prototype-page .card h2 {
  margin: 0;
  font-size: 1.08rem;
}

.prototype-page .email-form { margin-top: 16px; }

.email-row {
  display: grid;
  grid-template-columns: minmax(60px, .75fr) minmax(100px, 1.25fr) auto;
  gap: 7px;
}

.email-row input[type="text"],
.email-row input[type="email"] {
  min-width: 0;
  margin: 0;
}

.email-row button {
  width: auto;
  min-width: 82px;
  margin: 0;
}

.prototype-page .consent {
  grid-template-columns: 18px 1fr;
  gap: 9px;
  margin-top: 13px;
  font-size: .82rem;
}

.prototype-page .consent input {
  width: 16px;
  height: 16px;
}

.prototype-page .privacy-note {
  margin-top: 11px;
  font-size: .8rem;
}

.form-status {
  margin-top: 16px;
  padding: 16px;
  border: 1px solid #486a53;
  border-radius: 12px;
  background: #1c2a20;
  color: var(--text);
  font-size: 1rem;
  line-height: 1.5;
}

.form-status.error {
  border-color: #744747;
  background: #2b1d1d;
  color: var(--error);
}

.form-status[hidden] { display: none; }

.email-form[aria-busy="true"] {
  opacity: .7;
}

.message-form { margin-top: 16px; }

.message-form textarea {
  width: 100%;
  margin: 0;
}

.message-reply-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 9px;
  margin-top: 9px;
}

.message-reply-row input[type="email"] {
  min-width: 0;
  margin: 0;
}

.message-reply-row button {
  width: auto;
  min-width: 82px;
  margin: 0;
}

.message-form[aria-busy="true"] { opacity: .7; }

.channel-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 16px;
}

.channel-button {
  display: flex;
  min-height: 62px;
  align-items: center;
  gap: 11px;
  padding: 8px;
  border-radius: 14px;
  background: var(--button);
  color: var(--muted);
  font-weight: 650;
  text-decoration: none;
}

.channel-button.is-placeholder { cursor: default; }

.channel-button[href]:hover,
.channel-button[href]:focus-visible {
  background: var(--button-hover);
  color: var(--text);
}

.channel-icon {
  display: inline-flex;
  width: 46px;
  height: 46px;
  flex: 0 0 46px;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
}

.channel-icon svg {
  width: 34px;
  height: 34px;
  fill: none;
  stroke: #fff;
  stroke-width: 1.4;
}

.telegram-icon { background: #229ed9; }
.whatsapp-icon { background: #25d366; }

.rss-note {
  display: inline-block;
  margin-top: 12px;
  padding: 5px 9px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  font-size: .76rem;
}

.course-banner {
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: #000;
}

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

.course-intro { text-align: center; }

.course-button {
  display: flex;
  width: 100%;
  min-height: 58px;
  align-items: center;
  justify-content: center;
  gap: 11px;
  margin-top: 0;
  padding: 9px 16px;
  border-radius: 14px;
  background: var(--button);
  color: var(--text);
  text-decoration: none;
}

.course-button:hover,
.course-button:focus-visible {
  background: var(--button-hover);
}

.course-arrow-icon {
  display: inline-flex;
  width: 46px;
  height: 46px;
  flex: 0 0 46px;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  background: #ed872d;
}

.course-arrow-icon svg {
  width: 38px;
  height: 38px;
  fill: none;
  stroke: #fff;
  stroke-width: 3;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.donation-button {
  display: flex;
  width: 100%;
  min-height: 64px;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: 18px;
  padding: 10px 16px;
  border: 1px solid #6f6031;
  border-radius: 14px;
  background: #3a3424;
  color: var(--text);
  line-height: 1.35;
  text-align: center;
  text-decoration: none;
}

.donation-button:hover,
.donation-button:focus-visible {
  background: #48402a;
}

.coin-icon {
  display: inline-flex;
  width: 42px;
  height: 42px;
  flex: 0 0 42px;
  align-items: center;
  justify-content: center;
  border: 2px solid #ffe39a;
  border-radius: 50%;
  background: #c79b2c;
  box-shadow: inset 0 0 0 3px #e6bd55;
  color: #2a210e;
  font-size: .88rem;
  font-weight: 800;
}

.prototype-footer {
  padding: 4px 0 2px;
  color: var(--muted);
  font-size: .76rem;
  line-height: 1.5;
  text-align: center;
}

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