/* ── Variables ───────────────────────────────────────── */
:root {
  --blue-dark:   #061f57;
  --blue:        #004fd6;
  --blue-bright: #0aa7ea;
  --blue-light:  #eaf3ff;
  --muted:       #5f6b82;
}

/* ── Reset ───────────────────────────────────────────── */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* ── Base ────────────────────────────────────────────── */
html,
body {
  width: 100%;
  min-height: 100%;
  font-family: Inter, Arial, Helvetica, sans-serif;
  background: #fff;
  color: var(--blue-dark);
}

/* ── Landing (shared across all pages) ──────────────── */
.landing {
  position: relative;
  min-height: 100vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 40px 28px 72px;
  background:
    radial-gradient(circle at 20% 15%, rgba(10, 167, 234, 0.12), transparent 30%),
    radial-gradient(circle at 80% 20%, rgba(0, 79, 214, 0.10), transparent 32%),
    linear-gradient(180deg, #ffffff 0%, #f8fbff 48%, #eef5ff 100%);
}

.landing::after {
  content: "";
  position: absolute;
  left: -14%;
  right: -14%;
  bottom: -31%;
  height: 48vh;
  background: #eaf3ff;
  border-radius: 50% 50% 0 0 / 100% 100% 0 0;
  z-index: 0;
}

/* gracies & error: center content vertically */
.page-gracies .landing,
.page-error .landing {
  justify-content: center;
  text-align: center;
}

/* ── Topbar ──────────────────────────────────────────── */
.topbar {
  position: relative;
  z-index: 2;
  width: min(100%, 1280px);
  display: flex;
  margin-bottom: 56px;
}

.page-home .topbar {
  justify-content: flex-end;
}

.page-participa .topbar {
  justify-content: flex-start;
}

/* ── Nav: Participa button (home) ────────────────────── */
.participa {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  height: 38px;
  padding: 0 18px;
  border: 1.5px solid var(--blue);
  border-radius: 10px;
  background: rgba(255, 255, 255, .9);
  color: var(--blue);
  text-decoration: none;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -0.02em;
}

/* ── Nav: Back link (participa) ──────────────────────── */
.back-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  text-decoration: none;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: -0.02em;
}

.back-link:hover {
  color: var(--blue);
}

/* ── Hero section ────────────────────────────────────── */
.hero {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.page-home .hero {
  width: min(100%, 980px);
}

.page-participa .hero {
  width: min(100%, 640px);
}

/* ── Logo ─────────────────────────────────────────────── */
.logo {
  height: auto;
  display: block;
}

.page-home .logo {
  width: min(100%, 760px);
  margin: 0 auto 20px;
}

.page-participa .logo {
  width: min(100%, 320px);
  margin: 0 auto 32px;
}

.page-gracies .logo,
.page-error .logo {
  width: min(100%, 240px);
  margin: 0 auto 36px;
}

/* ── h1 (shared gradient, page-specific sizing) ─────── */
h1 {
  font-weight: 900;
  background: linear-gradient(90deg, #041f63 0%, #0057b8 48%, #1097e6 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.page-home h1 {
  max-width: 820px;
  margin: 0 auto 24px;
  font-size: clamp(40px, 5.1vw, 72px);
  line-height: 0.98;
  letter-spacing: -0.055em;
}

.page-home h1 .accent {
  background: linear-gradient(90deg, #0057b8 0%, #1097e6 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.page-participa h1 {
  max-width: 640px;
  margin: 0 auto 12px;
  font-size: clamp(32px, 4vw, 52px);
  line-height: 1;
  letter-spacing: -0.05em;
}

.page-gracies h1,
.page-error h1 {
  font-size: clamp(28px, 4vw, 44px);
  letter-spacing: -0.05em;
  margin-bottom: 14px;
}

/* ── Subtitle ─────────────────────────────────────────── */
.subtitle {
  color: var(--muted);
  font-weight: 500;
  letter-spacing: -0.02em;
}

.page-home .subtitle {
  max-width: 650px;
  margin: 0 auto 34px;
  font-size: clamp(18px, 1.75vw, 24px);
  line-height: 1.35;
}

.page-participa .subtitle {
  max-width: 520px;
  margin: 0 auto 36px;
  font-size: clamp(16px, 1.5vw, 20px);
  line-height: 1.4;
}

/* ── Home: CTA form ───────────────────────────────────── */
.cta-form {
  width: min(100%, 650px);
  display: grid;
  grid-template-columns: 1fr 135px;
  gap: 16px;
  align-items: center;
  margin-bottom: 24px;
}

.email-input {
  width: 100%;
  height: 48px;
  border: 1px solid rgba(6, 31, 87, 0.23);
  border-radius: 9px;
  background: #fff;
  padding: 0 18px;
  color: var(--blue-dark);
  font-size: 16px;
  font-weight: 500;
  outline: none;
  box-shadow: 0 8px 18px rgba(6, 31, 87, 0.05);
}

.email-input::placeholder {
  color: #657189;
}

.email-input:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(0, 79, 214, 0.12);
}

.affiliate {
  height: 48px;
  border: 0;
  border-radius: 9px;
  background: linear-gradient(180deg, #075ef2 0%, #0047c8 100%);
  color: #fff;
  font-size: 17px;
  font-weight: 800;
  letter-spacing: -0.025em;
  cursor: pointer;
  box-shadow: 0 8px 18px rgba(0, 72, 198, 0.20);
}

.note {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  gap: 8px;
  max-width: 690px;
  color: var(--muted);
  font-size: clamp(16px, 1.35vw, 21px);
  line-height: 1.35;
  font-weight: 500;
  letter-spacing: -0.02em;
}

.note svg {
  flex: 0 0 auto;
  margin-top: 4px;
  color: var(--muted);
}

.down {
  position: absolute;
  bottom: 48px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  width: 34px;
  height: 34px;
  color: var(--blue);
}

/* ── Participa: form card ─────────────────────────────── */
.form-card {
  width: 100%;
  background: #fff;
  border: 1px solid rgba(6, 31, 87, 0.10);
  border-radius: 18px;
  padding: 36px 32px;
  box-shadow: 0 12px 40px rgba(6, 31, 87, 0.08);
  text-align: left;
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.form-group.full {
  grid-column: 1 / -1;
}

.form-card label {
  font-size: 14px;
  font-weight: 700;
  color: var(--blue-dark);
  letter-spacing: -0.01em;
}

.form-card label .required {
  color: var(--blue);
  margin-left: 2px;
}

/* Scoped to avoid specificity conflict: input[type] (0,1,1)
   would beat .email-input (0,1,0) on the home page */
.page-participa input[type="text"],
.page-participa input[type="email"],
.page-participa input[type="tel"],
.page-participa select {
  width: 100%;
  height: 46px;
  border: 1px solid rgba(6, 31, 87, 0.20);
  border-radius: 9px;
  background: #fff;
  padding: 0 16px;
  color: var(--blue-dark);
  font-size: 16px;
  font-family: inherit;
  font-weight: 500;
  outline: none;
  box-shadow: 0 2px 8px rgba(6, 31, 87, 0.04);
  transition: border-color 0.15s, box-shadow 0.15s;
  appearance: none;
  -webkit-appearance: none;
}

.page-participa select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%235f6b82' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 40px;
}

.page-participa input::placeholder {
  color: #a0aab8;
  font-weight: 400;
}

.page-participa input:focus,
.page-participa select:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(0, 79, 214, 0.12);
}

.page-participa input.error,
.page-participa select.error {
  border-color: #d93025;
  box-shadow: 0 0 0 3px rgba(217, 48, 37, 0.10);
}

.field-error {
  font-size: 13px;
  color: #d93025;
  font-weight: 500;
  display: none;
}

.field-error.visible {
  display: block;
}

.checkbox-group {
  margin-top: 8px;
}

.checkbox-label {
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 500;
  color: var(--blue-dark);
}

.checkbox-label input[type="checkbox"] {
  width: 18px;
  height: 18px;
  min-width: 18px;
  border: 1px solid rgba(6, 31, 87, 0.30);
  border-radius: 4px;
  accent-color: var(--blue);
  cursor: pointer;
}

/* Honeypot: invisible to humans, traps bots */
.hp-field {
  position: absolute;
  left: -9999px;
  top: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
}

.submit-btn {
  width: 100%;
  height: 50px;
  margin-top: 24px;
  border: 0;
  border-radius: 10px;
  background: linear-gradient(180deg, #075ef2 0%, #0047c8 100%);
  color: #fff;
  font-size: 17px;
  font-weight: 800;
  font-family: inherit;
  letter-spacing: -0.025em;
  cursor: pointer;
  box-shadow: 0 8px 20px rgba(0, 72, 198, 0.22);
  transition: opacity 0.15s, box-shadow 0.15s;
}

.submit-btn:hover {
  opacity: 0.92;
  box-shadow: 0 10px 28px rgba(0, 72, 198, 0.30);
}

.submit-btn:active {
  opacity: 0.85;
}

.privacy-note {
  margin-top: 16px;
  text-align: center;
  color: var(--muted);
  font-size: 13px;
  font-weight: 500;
  line-height: 1.5;
}

.privacy-note a {
  color: var(--blue);
  text-decoration: none;
}

.privacy-note a:hover {
  text-decoration: underline;
}

/* ── Gracies / Error: result pages ───────────────────── */
.inner {
  position: relative;
  z-index: 1;
  max-width: 520px;
}

.icon {
  width: 72px;
  height: 72px;
  margin: 0 auto 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.page-gracies .icon {
  background: linear-gradient(135deg, #075ef2, #0aa7ea);
}

.page-error .icon {
  background: #fff0f0;
  border: 2px solid #fcc;
}

/* Scoped to .inner to avoid overriding .footer p on these pages */
.inner p {
  color: var(--muted);
  font-size: clamp(16px, 1.4vw, 19px);
  line-height: 1.45;
  font-weight: 500;
  letter-spacing: -0.01em;
  margin-bottom: 32px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 46px;
  padding: 0 28px;
  border: 0;
  border-radius: 10px;
  background: linear-gradient(180deg, #075ef2 0%, #0047c8 100%);
  color: #fff;
  text-decoration: none;
  font-size: 16px;
  font-weight: 800;
  font-family: inherit;
  letter-spacing: -0.025em;
  box-shadow: 0 8px 20px rgba(0, 72, 198, .22);
}

/* ── Footer (shared) ──────────────────────────────────── */
.footer {
  position: absolute;
  bottom: 10px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
  color: #5f6b82;
  font-size: 13px;
  font-weight: 500;
}

.footer a {
  color: #5f6b82;
  text-decoration: none;
}

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

/* ── Privacy page ─────────────────────────────────────── */
.privacy-page {
  position: relative;
  z-index: 3;
  width: 100%;
  background: linear-gradient(180deg, #ffffff 0%, #f3f8ff 100%);
  padding: 120px 24px;
}

.privacy-container {
  width: min(100%, 980px);
  margin: 0 auto;
  background: rgba(255, 255, 255, .82);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(0, 79, 214, .08);
  border-radius: 28px;
  padding: 56px;
  box-shadow: 0 20px 60px rgba(6, 31, 87, .08);
}

.privacy-container h2 {
  font-size: clamp(42px, 4vw, 64px);
  line-height: .95;
  letter-spacing: -.05em;
  margin-bottom: 34px;
  background: linear-gradient(90deg, #041f63 0%, #0057b8 48%, #1097e6 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.privacy-container h3 {
  margin-top: 42px;
  margin-bottom: 16px;
  color: #041f63;
  font-size: 26px;
  letter-spacing: -.03em;
}

.privacy-container p,
.privacy-container li {
  color: #5f6b82;
  font-size: 18px;
  line-height: 1.7;
  margin-bottom: 18px;
}

.privacy-container ul {
  padding-left: 22px;
}

.last-update {
  margin-top: 50px;
  font-size: 15px;
  color: #7a869b;
}

/* ── Media queries ────────────────────────────────────── */

/* Home – 760px breakpoint */
@media (max-width: 760px) {
  .page-home .landing {
    padding: 28px 20px 78px;
  }

  .page-home .topbar {
    justify-content: center;
    margin-bottom: 44px;
  }

  .page-home .participa {
    height: 42px;
    font-size: 16px;
  }

  .page-home .logo {
    width: min(100%, 560px);
    margin-bottom: 38px;
  }

  .page-home h1 {
    font-size: clamp(38px, 11vw, 58px);
  }

  .page-home .cta-form {
    grid-template-columns: 1fr;
    max-width: 460px;
  }

  .page-home .affiliate {
    width: 100%;
  }

  /* Privacy page */
  .privacy-page {
    padding: 80px 18px;
  }

  .privacy-container {
    padding: 34px 24px;
  }

  .privacy-container p,
  .privacy-container li {
    font-size: 16px;
  }
}

/* Participa – 600px breakpoint */
@media (max-width: 600px) {
  .page-participa .landing {
    padding: 28px 20px 78px;
  }

  .page-participa .topbar {
    margin-bottom: 36px;
  }

  .form-card {
    padding: 28px 20px;
  }

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

  .form-group.full {
    grid-column: 1;
  }
}
