/* ============================================================
   AXIOM RESEARCH GROUP — Components (buttons, cards, forms, accordion, badges)
   ============================================================ */

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--sp-2);
  min-height: 48px;
  padding: 12px 24px;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  font-family: var(--font-body);
  font-size: var(--fs-body);
  font-weight: 600;
  letter-spacing: 0.5px;
  cursor: pointer;
  text-align: center;
  transition: all var(--dur-fast) ease;
}

.btn:disabled,
.btn[aria-disabled="true"] {
  opacity: 0.5;
  cursor: not-allowed;
}

.btn-primary {
  background: var(--navy-deep);
  color: var(--white);
}
.btn-primary:hover {
  background: var(--navy-mid);
  color: var(--white);
  box-shadow: var(--shadow-hover);
}
.btn-primary:active { background: #0A1F40; }

.btn-secondary {
  background: var(--navy-mid);
  color: var(--white);
}
.btn-secondary:hover {
  background: var(--navy-deep);
  color: var(--white);
  box-shadow: var(--shadow-hover);
}

.btn-outline-navy {
  background: transparent;
  border-color: var(--navy-deep);
  color: var(--navy-deep);
}
.btn-outline-navy:hover {
  background: var(--navy-pale);
  color: var(--navy-deep);
}

.btn-outline-white {
  background: transparent;
  border-color: var(--white);
  color: var(--white);
}
.btn-outline-white:hover {
  background: rgba(255, 255, 255, 0.12);
  color: var(--white);
}

.btn-call {
  background: linear-gradient(135deg, var(--gold-2), var(--gold-1));
  color: var(--navy-deep);
  border-radius: 999px;
}
.btn-call:hover {
  color: var(--navy-deep);
  box-shadow: var(--shadow-hover);
}

/* Text link with arrow */
.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  font-weight: 600;
  color: var(--navy-deep);
}
.link-arrow svg { transition: transform var(--dur-fast) ease; }
.link-arrow:hover svg { transform: translateX(4px); }

/* ---------- Cards ---------- */
.protocol-card {
  background: var(--navy-pale);
  border: 1px solid var(--navy-deep);
  border-radius: var(--radius-xs);
  padding: var(--card-pad);
  transition: transform var(--dur-fast) ease, box-shadow var(--dur-fast) ease;
  display: flex;
  flex-direction: column;
  gap: var(--sp-3);
}
.protocol-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-medium);
}
.protocol-card__meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--sp-3);
}
.protocol-card h3 {
  font-size: var(--fs-h4);
  font-family: var(--font-body);
  font-weight: 600;
}
.protocol-card__excerpt {
  color: var(--slate);
  font-size: var(--fs-small);
  flex-grow: 1;
}
.protocol-card__criteria {
  border-top: 1px solid var(--line);
  padding-top: var(--sp-3);
  font-size: var(--fs-small);
  color: var(--slate);
}
.protocol-card__criteria ul { list-style: none; }
.protocol-card__criteria li {
  padding-left: var(--sp-5);
  position: relative;
  margin-bottom: var(--sp-1);
}
.protocol-card__criteria li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 8px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--gold-1);
}

.feature-card {
  background: var(--white);
  border: 1px solid var(--navy-pale);
  border-radius: var(--radius-sm);
  padding: var(--card-pad);
  transition: box-shadow var(--dur-fast) ease;
}
.feature-card:hover { box-shadow: var(--shadow-medium); }
.feature-card__icon {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--navy-pale);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--sp-4);
  color: var(--navy-deep);
}
.feature-card h3 {
  font-family: var(--font-body);
  font-size: var(--fs-h4);
  font-weight: 600;
  margin-bottom: var(--sp-2);
}
.feature-card p {
  color: var(--slate);
  font-size: var(--fs-small);
}

.stat-card {
  background: var(--navy-deep);
  color: var(--gold-2);
  text-align: center;
  padding: var(--sp-8);
  border-radius: var(--radius-xs);
}
.stat-card__value {
  font-family: var(--font-display);
  font-size: var(--fs-h3);
  font-weight: 500;
  display: block;
}
.stat-card__label {
  color: rgba(255, 255, 255, 0.75);
  font-size: var(--fs-small);
  margin-top: var(--sp-1);
  display: block;
}

.benefit-card { text-align: left; }
.benefit-card .feature-card__icon { background: var(--paper); }

/* ---------- Badges ---------- */
.badge {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-1);
  font-family: var(--font-mono);
  font-size: var(--fs-label);
  font-weight: 500;
  letter-spacing: 0.04em;
  padding: 4px 10px;
  border-radius: 999px;
  white-space: nowrap;
}
.badge--code {
  background: var(--navy-deep);
  color: var(--gold-2);
}
.badge--enrolling {
  background: #E7F2E9;
  color: #1F6B3A;
  border: 1px solid #BAD9C3;
}
.badge--soon {
  background: var(--paper);
  color: var(--slate);
  border: 1px solid var(--line);
}

/* Phase dots */
.phase-dots {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-family: var(--font-mono);
  font-size: var(--fs-label);
  color: var(--slate);
}
.phase-dots i {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--line);
}
.phase-dots i.on { background: var(--gold-1); }

/* Compliance badge */
.compliance-badge {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--sp-2);
  text-align: center;
  color: var(--white);
}
.compliance-badge__ring {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  border: 2px solid var(--gold-1);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gold-2);
}
.compliance-badge strong {
  font-family: var(--font-mono);
  letter-spacing: 0.08em;
}
.compliance-badge span {
  font-size: var(--fs-small);
  color: rgba(255, 255, 255, 0.72);
  max-width: 260px;
}

/* ---------- Dictionary block ---------- */
.dictionary-block {
  background: var(--white);
  border: 1px solid var(--line);
  border-left: 4px solid var(--gold-1);
  border-radius: var(--radius-xs);
  padding: var(--card-pad);
  box-shadow: var(--shadow-subtle);
}
.dictionary-block__word {
  font-family: var(--font-display);
  font-size: var(--fs-h3);
  font-weight: 500;
}
.dictionary-block__phon {
  font-family: var(--font-mono);
  color: var(--slate);
  font-size: var(--fs-small);
  margin: var(--sp-1) 0 var(--sp-3);
}
.dictionary-block__type {
  font-style: italic;
  color: var(--gold-1);
  font-size: var(--fs-small);
}
.dictionary-block ol {
  margin-top: var(--sp-3);
  list-style: none;
  counter-reset: def;
}
.dictionary-block ol li {
  counter-increment: def;
  padding-left: var(--sp-6);
  position: relative;
  margin-bottom: var(--sp-2);
  color: var(--slate);
}
.dictionary-block ol li::before {
  content: counter(def) ".";
  position: absolute;
  left: 0;
  font-family: var(--font-mono);
  color: var(--navy-deep);
  font-weight: 500;
}

/* ---------- Forms ---------- */
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--sp-6);
}
@media (max-width: 640px) {
  .form-row {
    grid-template-columns: 1fr;
    gap: var(--sp-4);
  }
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: var(--sp-2);
  margin-bottom: var(--sp-4);
}

.form-group label {
  font-size: var(--fs-label);
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--slate);
}

.form-group input,
.form-group textarea,
.form-group select {
  font-family: var(--font-body);
  font-size: var(--fs-body);
  color: var(--ink);
  background: var(--white);
  border: 1px solid var(--navy-deep);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  min-height: 48px;
  width: 100%;
  transition: box-shadow var(--dur-fast) ease;
}

.form-group textarea {
  min-height: 140px;
  resize: vertical;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: 3px solid var(--navy-mid);
  outline-offset: 0;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: var(--slate);
  opacity: 0.6;
}

.form-group input.is-invalid,
.form-group textarea.is-invalid,
.form-group select.is-invalid {
  border-color: #B3261E;
}

.form-error {
  color: #B3261E;
  font-size: var(--fs-small);
  display: none;
}
.form-error.is-visible { display: block; }

/* Custom checkbox */
.form-check {
  display: flex;
  align-items: flex-start;
  gap: var(--sp-3);
  margin-bottom: var(--sp-5);
  cursor: pointer;
}
.form-check input[type="checkbox"] {
  appearance: none;
  -webkit-appearance: none;
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  margin-top: 2px;
  border: 1px solid var(--navy-deep);
  border-radius: 4px;
  background: var(--white);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.form-check input[type="checkbox"]:checked {
  background: var(--navy-deep);
}
.form-check input[type="checkbox"]:checked::after {
  content: "";
  width: 10px;
  height: 6px;
  border-left: 2px solid var(--white);
  border-bottom: 2px solid var(--white);
  transform: rotate(-45deg) translateY(-1px);
}
.form-check span {
  font-size: var(--fs-small);
  color: var(--slate);
}

.form-success {
  display: none;
  background: #E7F2E9;
  border: 1px solid #BAD9C3;
  border-radius: var(--radius-sm);
  padding: var(--card-pad);
  text-align: center;
}
.form-success.is-visible { display: block; }
.form-success h3 {
  font-family: var(--font-body);
  font-size: var(--fs-h4);
  font-weight: 600;
  color: #1F6B3A;
  margin-bottom: var(--sp-2);
}

/* ---------- Accordion (FAQ) ---------- */
.accordion {
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--white);
  overflow: hidden;
}
.accordion__item + .accordion__item {
  border-top: 1px solid var(--line);
}
.accordion__trigger {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-4);
  background: transparent;
  border: 0;
  padding: var(--sp-5) var(--sp-6);
  font-family: var(--font-body);
  font-size: var(--fs-body);
  font-weight: 600;
  color: var(--ink);
  text-align: left;
  cursor: pointer;
  transition: background var(--dur-fast) ease;
}
.accordion__trigger:hover { background: var(--navy-pale); }
.accordion__trigger svg {
  flex-shrink: 0;
  color: var(--navy-deep);
  transition: transform var(--dur-normal) ease;
}
.accordion__trigger[aria-expanded="true"] svg {
  transform: rotate(180deg);
}
.accordion__panel {
  max-height: 0;
  overflow: hidden;
  transition: max-height var(--dur-normal) ease;
}
.accordion__panel-inner {
  padding: 0 var(--sp-6) var(--sp-5);
  color: var(--slate);
}

/* ---------- Partnership lockup ---------- */
.partner-lockup {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--sp-8);
  flex-wrap: wrap;
}
.partner-lockup img {
  width: 150px;
  height: auto;
}
.partner-lockup__divider {
  width: 1px;
  height: 72px;
  background: var(--line);
}
@media (max-width: 640px) {
  .partner-lockup { gap: var(--sp-5); }
  .partner-lockup img { width: 110px; }
  .partner-lockup__divider { height: 48px; }
}

/* ---------- Process steps / timeline ---------- */
.steps-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--sp-6);
  counter-reset: step;
}
.steps-grid--3 { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 1024px) {
  .steps-grid, .steps-grid--3 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
  .steps-grid, .steps-grid--3 { grid-template-columns: 1fr; }
}

.step-card {
  counter-increment: step;
  background: var(--white);
  border: 1px solid var(--navy-pale);
  border-radius: var(--radius-sm);
  padding: var(--card-pad);
  position: relative;
}
.step-card__num {
  font-family: var(--font-mono);
  font-size: var(--fs-label);
  color: var(--gold-1);
  letter-spacing: 0.08em;
  display: block;
  margin-bottom: var(--sp-3);
}
.step-card__icon {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--navy-pale);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--navy-deep);
  margin-bottom: var(--sp-4);
}
.step-card h3 {
  font-family: var(--font-body);
  font-size: var(--fs-h4);
  font-weight: 600;
  margin-bottom: var(--sp-2);
}
.step-card p {
  font-size: var(--fs-small);
  color: var(--slate);
}

/* ---------- Team / bio card ---------- */
.bio-card {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: var(--grid-gap);
  align-items: center;
  background: var(--white);
  border: 1px solid var(--navy-pale);
  border-radius: var(--radius-sm);
  padding: var(--card-pad);
}
@media (max-width: 1024px) {
  .bio-card { grid-template-columns: 1fr; }
  .bio-card__photo { order: -1; }
}
.bio-card__photo {
  border-radius: var(--radius-xs);
  overflow: hidden;
}
.bio-card h3 { margin-bottom: var(--sp-1); }
.bio-card__role {
  font-family: var(--font-mono);
  font-size: var(--fs-label);
  color: var(--gold-1);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  display: block;
  margin-bottom: var(--sp-4);
}

/* ---------- Protocol card: image strip + CTA ---------- */
.protocol-card {
  display: flex;
  flex-direction: column;
}
.protocol-card__img {
  margin: calc(-1 * var(--sp-8)) calc(-1 * var(--sp-8)) var(--sp-5);
  overflow: hidden;
  border-bottom: 1px solid var(--line);
}
.protocol-card__img img {
  width: 100%;
  height: 160px;
  object-fit: cover;
  display: block;
  filter: saturate(0.85);
  transition: transform 0.4s ease;
}
.protocol-card:hover .protocol-card__img img {
  transform: scale(1.04);
}
.protocol-card__cta {
  margin-top: auto;
  padding-top: var(--sp-5);
}

/* ---------- Carousel (scroll-snap) ---------- */
.carousel {
  position: relative;
}
.carousel__track {
  display: flex;
  gap: var(--sp-5);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding: var(--sp-1) var(--sp-1) var(--sp-3);
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}
.carousel__track::-webkit-scrollbar { display: none; }
.carousel__track > * {
  flex: 0 0 85%;
  scroll-snap-align: start;
}
@media (min-width: 700px) {
  .carousel__track > * { flex-basis: 380px; }
}
@media (min-width: 1024px) {
  /* Exactamente 3 visibles: sin flechas hoy; aparecen solas con más estudios */
  .carousel__track > * { flex-basis: calc((100% - 2 * var(--sp-5)) / 3); }
}
.carousel__btn {
  position: absolute;
  top: 42%;
  transform: translateY(-50%);
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: none;
  background: var(--navy-deep);
  color: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: var(--shadow-medium);
  z-index: 2;
  transition: background 0.2s ease, opacity 0.2s ease;
}
.carousel__btn:hover:not(:disabled) { background: var(--navy-mid); }
.carousel__btn:disabled { opacity: 0.3; cursor: default; }
.carousel__btn--prev { left: -14px; }
.carousel__btn--prev svg { transform: rotate(180deg); }
.carousel__btn--next { right: -14px; }
@media (max-width: 640px) {
  .carousel__btn { width: 40px; height: 40px; }
  .carousel__btn--prev { left: -6px; }
  .carousel__btn--next { right: -6px; }
}

/* ---------- Why participate: photo + rows ---------- */
.why-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--sp-10);
  align-items: center;
}
@media (min-width: 1024px) {
  .why-grid { grid-template-columns: 0.9fr 1.1fr; gap: var(--sp-14); }
}
.photo-duotone--tall img {
  width: 100%;
  height: 100%;
  min-height: 320px;
  max-height: 560px;
  object-fit: cover;
}
.feature-row {
  display: flex;
  gap: var(--sp-4);
  align-items: flex-start;
  padding: var(--sp-4) 0;
  border-bottom: 1px solid var(--line);
}
.feature-row:last-child { border-bottom: 0; }
.feature-row .feature-card__icon { flex-shrink: 0; }
.feature-row h3 { margin-bottom: var(--sp-1); font-size: 18px; }
.feature-row p { margin: 0; color: var(--slate); }

/* ---------- Transport band (beneficio destacado) ---------- */
.transport-band {
  background: linear-gradient(120deg, var(--gold-2) 0%, var(--gold-1) 100%);
  padding: var(--sp-10) 0;
}
.transport-band__inner {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: var(--sp-8);
  align-items: center;
}
.transport-band__icon {
  width: 84px;
  height: 84px;
  border-radius: 50%;
  background: var(--navy-deep);
  color: var(--gold-2);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.transport-band .eyebrow { color: var(--navy-mid); }
.transport-band h2 { color: var(--navy-deep); margin-bottom: var(--sp-2); }
.transport-band p { color: var(--ink); max-width: 640px; margin: 0; }
.transport-band__cta { white-space: nowrap; }
@media (max-width: 860px) {
  .transport-band__inner {
    grid-template-columns: 1fr;
    text-align: center;
    justify-items: center;
    gap: var(--sp-5);
  }
  .transport-band p { text-align: center; }
}

/* ---------- CTA band: peak watermark ---------- */
.cta-band {
  position: relative;
  overflow: hidden;
}
.cta-band::after {
  content: "";
  position: absolute;
  right: -70px;
  bottom: -50px;
  width: 460px;
  height: 372px;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 520 420' fill='none'><polygon points='260,52 470,392 402,392 265,158 255,158 118,392 50,392' stroke='rgba(255,255,255,0.09)' stroke-width='3'/><polygon points='260,212 329,333 363,392 297,392 266,333 254,333 223,392 157,392 191,333' stroke='rgba(255,255,255,0.09)' stroke-width='3'/></svg>");
  background-repeat: no-repeat;
  background-size: contain;
  pointer-events: none;
}
.cta-band .container { position: relative; z-index: 1; }

/* ---------- Map embed ---------- */
.map-embed {
  border: 1px solid var(--line);
  border-radius: var(--radius-xs);
  overflow: hidden;
  box-shadow: var(--shadow-subtle);
}
.map-embed iframe {
  display: block;
  width: 100%;
}

/* ---------- Form: honeypot + send error ---------- */
.hp-field {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}
.form-error--send {
  display: none;
  margin-top: var(--sp-4);
  padding: var(--sp-3) var(--sp-4);
  background: rgba(178, 58, 58, 0.08);
  border: 1px solid rgba(178, 58, 58, 0.35);
  border-radius: var(--radius-sm);
}
.form-error--send.is-visible {
  display: block;
}

/* ---------- Plain photo (no duotone: real people) ---------- */
.photo-plain {
  border-radius: var(--radius-xs);
  overflow: hidden;
  border: 1px solid var(--line);
  box-shadow: var(--shadow-subtle);
  background: var(--white);
}
.photo-plain img {
  width: 100%;
  height: auto;
  display: block;
}

/* ---------- Info block (contact) ---------- */
.info-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: var(--sp-4);
}
.info-list li {
  display: flex;
  gap: var(--sp-3);
  align-items: flex-start;
}
.info-list li svg {
  flex-shrink: 0;
  color: var(--gold-1);
  margin-top: 3px;
}
.info-list li strong {
  display: block;
  font-size: var(--fs-small);
}
.info-list li span {
  color: var(--slate);
  font-size: var(--fs-small);
}

/* ---------- Legal text ---------- */
.legal-content {
  max-width: 800px;
}
.legal-content h2 {
  font-size: var(--fs-h4);
  font-family: var(--font-body);
  font-weight: 600;
  margin: var(--sp-8) 0 var(--sp-3);
}
.legal-content p, .legal-content li {
  color: var(--slate);
}
.legal-content ul {
  margin-bottom: var(--sp-4);
  padding-left: var(--sp-2);
}
.legal-note {
  background: var(--navy-pale);
  border-left: 4px solid var(--gold-1);
  padding: var(--sp-4) var(--sp-5);
  border-radius: var(--radius-xs);
  font-size: var(--fs-small);
  color: var(--slate);
  margin-bottom: var(--sp-8);
}
