:root {
  --accent: #86afc0;
  --accent-dark: #6e97a8;
  --black: #000000;
  --grey-dark: #2a2a2a;
  --grey-mid: #4a4a4a;
  --grey-soft: #f2f2f2;
  --grey-80: #333333;
  --text: #1a1a1a;
  --text-light: #f5f5f5;
  --white: #ffffff;
  --radius-pill: 50px;
  --max: 720px;
  --font-body: "Open Sans", system-ui, sans-serif;
  --font-display: "Montserrat", system-ui, sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--text);
  background: var(--grey-soft);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

img {
  max-width: 100%;
  height: auto;
}

a {
  color: var(--accent-dark);
}

a:hover {
  color: var(--accent);
}

.site-header {
  background: var(--black);
  padding: 1rem 1.25rem;
  text-align: center;
}

.site-header .logo {
  display: inline-block;
  transition: opacity 0.35s ease;
}

.site-header .logo:hover {
  opacity: 0.85;
}

.site-header .logo img {
  height: 42px;
  width: auto;
}

.sandbox-banner {
  background: #5c4033;
  color: #fff8f0;
  text-align: center;
  font-size: 0.85rem;
  padding: 0.55rem 1rem;
}

.sandbox-banner.warn {
  background: #8a3b2c;
}

.hero {
  background: var(--black);
  color: var(--text-light);
  padding: 3.5rem 1.25rem 3rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(134, 175, 192, 0.18), transparent 55%);
  pointer-events: none;
}

.hero > * {
  position: relative;
  z-index: 1;
}

.hero h1 {
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: 0.04em;
  font-size: clamp(1.6rem, 4vw, 2.4rem);
  margin: 0 0 1rem;
  animation: fadeUp 0.8s ease both;
}

.hero p {
  max-width: 36rem;
  margin: 0 auto 1.5rem;
  opacity: 0.92;
  animation: fadeUp 0.8s ease 0.15s both;
}

.amount-pill {
  display: inline-block;
  border: 2px solid var(--white);
  border-radius: var(--radius-pill);
  padding: 0.65rem 1.4rem;
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: 0.03em;
  animation: fadeUp 0.8s ease 0.3s both;
}

.amount-pill strong {
  color: var(--accent);
  font-size: 1.25rem;
}

.main {
  flex: 1;
  width: 100%;
  position: relative;
  z-index: 2;
}

.card {
  background: var(--white);
  padding: 2rem 1.5rem;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.08);
  animation: fadeUp 0.7s ease 0.2s both;
  width: min(100% - 2rem, var(--max));
  margin: 2rem auto 3rem;
}

.card h2 {
  font-family: var(--font-display);
  font-size: 1.25rem;
  margin: 0 0 1rem;
}

.muted {
  color: var(--grey-mid);
  font-size: 0.95rem;
}

.form-group {
  margin-bottom: 1.15rem;
}

.form-group label {
  display: block;
  font-weight: 600;
  margin-bottom: 0.35rem;
  font-size: 0.92rem;
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group textarea {
  width: 100%;
  padding: 0.75rem 0.9rem;
  border: 1px solid #cfd8dc;
  border-radius: 8px;
  font: inherit;
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(134, 175, 192, 0.35);
}

.form-group.has-error input,
.form-group.has-error textarea {
  border-color: #c62828;
}

.field-error {
  color: #c62828;
  font-size: 0.88rem;
  margin: 0.35rem 0 0;
}

.form-group.has-error .checkbox {
  outline: 1px solid #c62828;
  outline-offset: 4px;
  border-radius: 4px;
}

.form-group textarea {
  min-height: 5rem;
  resize: vertical;
}

.checkbox {
  display: flex;
  gap: 0.65rem;
  align-items: flex-start;
  font-size: 0.92rem;
  margin-bottom: 0.9rem;
}

.checkbox-double {
  margin-left: 0.35rem;
  padding: 0.75rem 0.85rem;
  background: #eef4f7;
  border-left: 3px solid var(--accent);
}

.checkbox input {
  margin-top: 0.25rem;
  accent-color: var(--accent);
}

.btn {
  display: inline-block;
  border: 2px solid transparent;
  border-radius: var(--radius-pill);
  padding: 0.85rem 1.6rem;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.03em;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.25s ease, color 0.25s ease, border-color 0.25s ease, transform 0.2s ease;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn-primary {
  background: var(--accent);
  color: var(--black);
  border-color: var(--accent);
  width: 100%;
  text-align: center;
}

.btn-primary:hover {
  background: var(--accent-dark);
  border-color: var(--accent-dark);
  color: var(--black);
}

.btn-outline {
  background: transparent;
  color: var(--white);
  border-color: var(--white);
}

.btn-outline-dark {
  background: transparent;
  color: var(--black);
  border-color: var(--black);
}

.btn-outline-dark:hover {
  background: var(--black);
  color: var(--white);
}

.alert {
  padding: 0.9rem 1rem;
  border-radius: 8px;
  margin-bottom: 1.25rem;
  font-size: 0.95rem;
}

.alert-error {
  background: #fdecea;
  color: #8a1f11;
}

.alert-ok {
  background: #e8f5e9;
  color: #1b5e20;
}

.alert-info {
  background: #e8f1f4;
  color: #1f4e5f;
}

.legal-box {
  max-height: 220px;
  overflow: auto;
  border: 1px solid #dde3e6;
  padding: 0.9rem 1rem;
  margin-bottom: 0.75rem;
  background: #fafbfc;
  font-size: 0.85rem;
}

.legal-box h2 {
  font-size: 1rem;
  margin: 0.75rem 0 0.35rem;
}

.legal-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}

.section-divider {
  height: 4px;
  width: 72px;
  background: var(--accent);
  margin: 0.5rem 0 1.25rem;
}

.module-prices {
  margin: 1.25rem 0 0.25rem;
  padding: 1rem 1.1rem;
  background: #eef4f7;
  border-left: 4px solid var(--accent);
}

.module-prices h3 {
  font-family: var(--font-display);
  font-size: 1rem;
  margin: 0 0 0.65rem;
}

.module-prices ul {
  margin: 0;
  padding-left: 1.15rem;
}

.module-prices li {
  margin: 0.35rem 0;
  font-size: 0.95rem;
}

.site-footer {
  background: var(--black);
  color: #bbb;
  padding: 2rem 1.25rem;
  text-align: center;
  font-size: 0.85rem;
}

.site-footer a {
  color: var(--accent);
  text-decoration: none;
  margin: 0 0.45rem;
}

.site-footer a:hover {
  text-decoration: underline;
}

.site-footer .footer-links {
  margin-bottom: 0.75rem;
}

.readonly {
  background: #f0f0f0;
}

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

.payment-element {
  margin: 1rem 0 1.5rem;
  min-height: 120px;
}

#pay-button:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none;
}
