:root {
  --bio-navy: #10263f;
  --bio-blue: #176b89;
  --bio-teal: #0f8f89;
  --bio-green: #6cab43;
  --bio-lime: #b9d640;
  --bio-orange: #f28c28;
  --bio-cream: #f7f9fd;
  --bio-white: #ffffff;
  --bio-text: #17212b;
  --bio-muted: #5d6874;
  --bio-border: #dbe7e0;
  --bio-danger: #b42318;
  --shadow-soft: 0 18px 45px rgba(16, 38, 63, 0.14);
  --shadow-card: 0 10px 30px rgba(16, 38, 63, 0.09);
}

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

[hidden] {
  display: none !important;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--bio-text);
  font-family: "Inter", "Segoe UI", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 1rem;
  line-height: 1.6;
  background: var(--bio-cream);
}

button,
input {
  font: inherit;
}

a {
  color: var(--bio-blue);
}

img,
iframe {
  max-width: 100%;
}

.container {
  width: min(100% - 2rem, 1180px);
  margin-inline: auto;
}

.skip-link {
  position: fixed;
  z-index: 2000;
  top: 0.75rem;
  left: 0.75rem;
  padding: 0.7rem 1rem;
  color: #fff;
  background: var(--bio-navy);
  border-radius: 0.5rem;
  transform: translateY(-150%);
}

.skip-link:focus {
  transform: translateY(0);
}

.site-header {
  position: sticky;
  z-index: 100;
  top: 0;
  background: rgba(255, 255, 255, 0.95);
  border-bottom: 1px solid rgba(16, 38, 63, 0.08);
  backdrop-filter: blur(14px);
}

.header-inner {
  display: flex;
  min-height: 68px;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.brand {
  display: inline-flex;
  min-width: 0;
  align-items: center;
  gap: 0.7rem;
  color: var(--bio-navy);
  line-height: 1.15;
  text-decoration: none;
}

.brand img {
  width: 42px;
  height: 42px;
  flex: 0 0 auto;
  object-fit: cover;
  border-radius: 50%;
  box-shadow: 0 0 0 2px #fff, 0 0 0 3px rgba(15, 143, 137, 0.28);
}

.brand strong,
.brand small {
  display: block;
}

.brand strong {
  font-size: 0.92rem;
  font-weight: 900;
}

.brand small {
  display: none;
  color: var(--bio-muted);
  font-size: 0.75rem;
}

.header-link {
  display: inline-flex;
  min-height: 44px;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  padding: 0.58rem 0.82rem;
  color: var(--bio-navy);
  font-size: 0.9rem;
  font-weight: 800;
  text-decoration: none;
  border: 1px solid var(--bio-teal);
  border-radius: 0.5rem;
  background: #fff;
}

.header-link:hover,
.header-link:focus-visible {
  color: #fff;
  background: var(--bio-teal);
}

.eyebrow {
  margin: 0 0 0.75rem;
  color: var(--bio-teal);
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0.075em;
  text-transform: uppercase;
}

.eyebrow.light {
  color: var(--bio-lime);
}

.access-main {
  position: relative;
  min-height: calc(100vh - 68px);
  overflow: hidden;
  padding: 2.2rem 0 3rem;
  background:
    radial-gradient(circle at 88% 12%, rgba(185, 214, 64, 0.3), transparent 24rem),
    linear-gradient(145deg, var(--bio-navy), var(--bio-teal));
}

.access-main::after {
  position: absolute;
  right: -6rem;
  bottom: -10rem;
  width: 22rem;
  height: 22rem;
  content: "";
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 50%;
  box-shadow: 0 0 0 3rem rgba(255, 255, 255, 0.035), 0 0 0 7rem rgba(255, 255, 255, 0.025);
  pointer-events: none;
}

.access-grid {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 1.5rem;
}

.access-intro {
  color: #fff;
}

.access-intro h1 {
  max-width: 760px;
  margin: 0 0 1rem;
  font-size: clamp(2rem, 10vw, 4.25rem);
  line-height: 1.02;
  font-weight: 900;
  letter-spacing: -0.035em;
}

.access-intro h1 span {
  display: block;
  color: var(--bio-lime);
}

.access-intro > p:not(.eyebrow) {
  max-width: 680px;
  margin: 0;
  color: rgba(255, 255, 255, 0.88);
  font-size: 1.05rem;
}

.access-points {
  display: grid;
  gap: 0.7rem;
  margin: 1.4rem 0 0;
  padding: 0;
  list-style: none;
}

.access-points li {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  color: rgba(255, 255, 255, 0.9);
  font-weight: 700;
}

.access-points svg {
  width: 20px;
  height: 20px;
  flex: 0 0 auto;
  margin-top: 0.18rem;
  color: var(--bio-lime);
}

.access-card {
  padding: 1.35rem;
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 1rem;
  background: #fff;
  box-shadow: var(--shadow-soft);
}

.access-card h2 {
  margin: 0 0 0.35rem;
  color: var(--bio-navy);
  font-size: 1.55rem;
  line-height: 1.15;
  font-weight: 900;
}

.access-card > p {
  margin: 0 0 1.25rem;
  color: var(--bio-muted);
}

.form-group + .form-group {
  margin-top: 1rem;
}

.form-group label {
  display: inline-block;
  margin-bottom: 0.4rem;
  color: var(--bio-navy);
  font-size: 0.9rem;
  font-weight: 800;
}

.required {
  color: var(--bio-orange);
}

.input-control {
  width: 100%;
  min-height: 50px;
  padding: 0.75rem 0.9rem;
  color: var(--bio-text);
  border: 1.5px solid #cad8d1;
  border-radius: 0.55rem;
  outline: none;
  background: #fff;
  transition: border-color 0.18s ease, box-shadow 0.18s ease;
}

.input-control:focus {
  border-color: var(--bio-teal);
  box-shadow: 0 0 0 4px rgba(15, 143, 137, 0.14);
}

.input-control[aria-invalid="true"] {
  border-color: var(--bio-danger);
}

.code-input {
  font-size: 1.2rem;
  font-weight: 900;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.field-hint {
  display: block;
  margin-top: 0.35rem;
  color: var(--bio-muted);
  font-size: 0.8rem;
}

.form-alert {
  margin: 1rem 0 0;
  padding: 0.75rem 0.85rem;
  color: #7a271a;
  font-size: 0.9rem;
  font-weight: 700;
  border: 1px solid #fecdca;
  border-radius: 0.55rem;
  background: #fef3f2;
}

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

.submit-button {
  display: inline-flex;
  width: 100%;
  min-height: 50px;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  margin-top: 1.25rem;
  padding: 0.72rem 1rem;
  color: #231305;
  font-weight: 900;
  border: 1px solid var(--bio-orange);
  border-radius: 0.55rem;
  background: var(--bio-orange);
  box-shadow: 0 8px 22px rgba(242, 140, 40, 0.28);
  cursor: pointer;
  transition: transform 0.18s ease, background 0.18s ease, box-shadow 0.18s ease;
}

.submit-button:hover,
.submit-button:focus-visible {
  color: #fff;
  background: #d97212;
  transform: translateY(-1px);
  box-shadow: 0 11px 26px rgba(242, 140, 40, 0.35);
}

.submit-button:disabled {
  opacity: 0.7;
  cursor: wait;
  transform: none;
}

.spinner {
  width: 18px;
  height: 18px;
  border: 2px solid rgba(16, 38, 63, 0.3);
  border-top-color: var(--bio-navy);
  border-radius: 50%;
  animation: spin 0.75s linear infinite;
}

.spinner[hidden] {
  display: none;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.support-note {
  margin: 1rem 0 0;
  color: var(--bio-muted);
  font-size: 0.86rem;
  text-align: center;
}

.support-note a {
  font-weight: 800;
}

.materials-hero {
  position: relative;
  overflow: hidden;
  padding: 2.75rem 0 3rem;
  color: #fff;
  background:
    radial-gradient(circle at 92% 12%, rgba(185, 214, 64, 0.3), transparent 24rem),
    linear-gradient(145deg, var(--bio-navy), var(--bio-teal));
}

.materials-hero h1 {
  max-width: 900px;
  margin: 0 0 0.9rem;
  font-size: clamp(2rem, 9vw, 4.2rem);
  line-height: 1.04;
  font-weight: 900;
  letter-spacing: -0.035em;
}

.materials-hero .lead {
  max-width: 760px;
  margin: 0;
  color: rgba(255, 255, 255, 0.88);
  font-size: 1.05rem;
}

.materials-summary {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
  margin-top: 1.5rem;
}

.summary-item {
  padding: 0.85rem;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 0.8rem;
  background: rgba(255, 255, 255, 0.09);
}

.summary-item strong,
.summary-item span {
  display: block;
}

.summary-item strong {
  color: var(--bio-lime);
  font-size: 1.35rem;
  font-weight: 900;
}

.summary-item span {
  color: rgba(255, 255, 255, 0.82);
  font-size: 0.78rem;
  font-weight: 700;
}

.materials-main {
  padding: 2rem 0 3.5rem;
}

.materials-heading {
  max-width: 760px;
  margin-bottom: 1.4rem;
}

.materials-heading h2 {
  margin: 0 0 0.55rem;
  color: var(--bio-navy);
  font-size: clamp(1.75rem, 7vw, 2.7rem);
  line-height: 1.1;
  font-weight: 900;
}

.materials-heading p:last-child {
  margin: 0;
  color: var(--bio-muted);
}

.talk-list {
  display: grid;
  gap: 1.25rem;
}

.talk-card {
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--bio-border);
  border-radius: 1rem;
  background: #fff;
  box-shadow: var(--shadow-card);
}

.talk-copy {
  padding: 1.15rem;
}

.talk-meta {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  margin-bottom: 0.8rem;
}

.talk-number {
  display: grid;
  width: 2.5rem;
  height: 2.5rem;
  flex: 0 0 auto;
  place-items: center;
  color: #fff;
  font-size: 0.85rem;
  font-weight: 900;
  border-radius: 0.65rem;
  background: var(--bio-teal);
}

.talk-speaker {
  margin: 0;
  color: var(--bio-teal);
  font-size: 0.9rem;
  font-weight: 900;
  letter-spacing: 0.02em;
}

.talk-card h3 {
  margin: 0;
  color: var(--bio-navy);
  font-size: 1.2rem;
  line-height: 1.25;
  font-weight: 900;
}

.video-frame {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  background: #071827;
}

.video-frame iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

.video-loading {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 1rem;
  color: rgba(255, 255, 255, 0.82);
  font-size: 0.9rem;
  text-align: center;
}

.downloads {
  display: grid;
  gap: 0.65rem;
  padding: 1rem 1.15rem 1.15rem;
  border-top: 1px solid var(--bio-border);
  background: #fbfdfc;
}

.download-link {
  display: flex;
  min-height: 48px;
  min-width: 0;
  align-items: center;
  gap: 0.75rem;
  padding: 0.65rem 0.75rem;
  color: var(--bio-navy);
  font-size: 0.88rem;
  font-weight: 800;
  line-height: 1.3;
  text-decoration: none;
  border: 1px solid #cce0d7;
  border-radius: 0.65rem;
  background: #fff;
  transition: border-color 0.18s ease, color 0.18s ease, transform 0.18s ease;
}

.download-link:hover,
.download-link:focus-visible {
  color: var(--bio-teal);
  border-color: var(--bio-teal);
  transform: translateY(-1px);
}

.download-icon {
  display: grid;
  width: 2rem;
  height: 2rem;
  flex: 0 0 auto;
  place-items: center;
  color: #fff;
  border-radius: 0.5rem;
  background: var(--bio-orange);
}

.download-icon svg {
  width: 18px;
  height: 18px;
}

.download-text {
  min-width: 0;
  overflow-wrap: anywhere;
}

.download-text small {
  display: block;
  color: var(--bio-muted);
  font-size: 0.74rem;
  font-weight: 700;
}

.complementary-title {
  margin: 0.25rem 0 0;
  color: var(--bio-muted);
  font-size: 0.75rem;
  font-weight: 900;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.site-footer {
  padding: 2.2rem 0;
  color: rgba(255, 255, 255, 0.78);
  background: #071827;
}

.footer-inner {
  display: grid;
  gap: 0.45rem;
}

.site-footer strong {
  color: #fff;
}

.site-footer p {
  margin: 0;
  font-size: 0.88rem;
}

:focus-visible {
  outline: 3px solid var(--bio-lime);
  outline-offset: 3px;
}

@media (min-width: 480px) {
  .brand small {
    display: block;
  }

  .access-card {
    padding: 1.7rem;
  }
}

@media (min-width: 700px) {
  .container {
    width: min(100% - 3rem, 1180px);
  }

  .access-main {
    padding: 3.5rem 0 4rem;
  }

  .materials-summary {
    max-width: 500px;
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .talk-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .talk-card {
    display: flex;
    min-height: 100%;
    flex-direction: column;
  }

  .downloads {
    margin-top: auto;
  }
}

@media (min-width: 960px) {
  .access-grid {
    grid-template-columns: minmax(0, 1.25fr) minmax(340px, 0.75fr);
    align-items: center;
    gap: 3.5rem;
  }

  .access-intro h1 {
    font-size: clamp(3.25rem, 5.3vw, 4.8rem);
  }

  .materials-hero {
    padding: 4.2rem 0;
  }

  .materials-main {
    padding: 3.25rem 0 5rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}

/* ------------------------------------------------------------------
 * Campus: agregados sobre la hoja de material-congreso
 * ------------------------------------------------------------------ */

.brand-campus img {
  width: auto;
  height: 40px;
  max-width: 190px;
  object-fit: contain;
  border-radius: 0;
  box-shadow: none;
}

.materials-hero h1 span {
  color: var(--bio-lime);
}

.access-expiry {
  display: inline-block;
  margin: 0.5rem 0 0;
  padding: 0.45rem 0.8rem;
  color: #fff;
  font-size: 0.9rem;
  font-weight: 700;
  overflow-wrap: anywhere;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 0.5rem;
  background: rgba(255, 255, 255, 0.1);
}

.talk-card.is-pending {
  border-style: dashed;
  box-shadow: none;
}

.pending-note {
  margin: 0;
  padding: 0 1.15rem 1.15rem;
  color: var(--bio-muted);
}

.course-grid {
  display: grid;
  gap: 1rem;
}

.course-link {
  display: grid;
  gap: 0.4rem;
  padding: 1.25rem;
  color: var(--bio-text);
  text-decoration: none;
  border: 1px solid var(--bio-border);
  border-radius: 1rem;
  background: #fff;
  box-shadow: var(--shadow-card);
}

.course-link strong {
  color: var(--bio-navy);
  font-size: 1.1rem;
  line-height: 1.3;
}

.course-link span {
  color: var(--bio-muted);
}

.course-link em {
  color: var(--bio-teal);
  font-style: normal;
  font-weight: 800;
}

.course-link:hover,
.course-link:focus-visible {
  border-color: var(--bio-teal);
}

.site-footer a {
  color: inherit;
}

.campus-error {
  padding: 3rem 0;
}

@media (min-width: 700px) {
  .course-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* Progreso, evaluación y certificado */

.module-block + .module-block {
  margin-top: 3rem;
}

.course-progress {
  display: grid;
  max-width: 500px;
  gap: 0.35rem;
  margin-top: 1rem;
  color: #fff;
}

.course-progress label {
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.course-progress progress {
  width: 100%;
  height: 0.7rem;
  overflow: hidden;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  appearance: none;
}

.course-progress progress::-webkit-progress-bar {
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
}

.course-progress progress::-webkit-progress-value {
  border-radius: 999px;
  background: var(--bio-lime);
}

.course-progress progress::-moz-progress-bar {
  border-radius: 999px;
  background: var(--bio-lime);
}

.course-progress p {
  margin: 0;
  font-weight: 700;
}

.lesson-check {
  margin-top: auto;
  padding: 0.85rem 1.15rem 1.15rem;
  border-top: 1px solid var(--bio-border);
  background: #fbfdfc;
}

.lesson-button {
  min-height: 44px;
  padding: 0.55rem 0.95rem;
  color: var(--bio-navy);
  font-weight: 800;
  cursor: pointer;
  border: 1px solid var(--bio-teal);
  border-radius: 0.5rem;
  background: #fff;
}

.lesson-button:hover,
.lesson-button:focus-visible {
  background: #eef6f2;
}

.lesson-button.is-done {
  color: #fff;
  border-color: var(--bio-green);
  background: var(--bio-green);
}

.lesson-button:disabled {
  opacity: 0.6;
  cursor: wait;
}

.cert-panel {
  max-width: 760px;
  margin-top: 3.5rem;
  padding: 1.5rem;
  border: 1px solid var(--bio-border);
  border-radius: 1rem;
  background: #fff;
  box-shadow: var(--shadow-card);
}

.cert-panel h2 {
  margin: 0 0 0.6rem;
  color: var(--bio-navy);
  font-size: clamp(1.5rem, 5vw, 2rem);
  line-height: 1.15;
}

.cert-panel[data-estado="aprobada"] {
  border-color: var(--bio-green);
}

.cert-lock {
  color: var(--bio-muted);
}

.cert-form {
  display: grid;
  gap: 0.2rem;
}

.cert-form .form-group {
  margin-top: 0.75rem;
}

.cert-check {
  display: flex;
  gap: 0.6rem;
  align-items: flex-start;
  margin: 1rem 0 0.5rem;
  font-size: 0.95rem;
}

.cert-check input {
  width: 1.15rem;
  height: 1.15rem;
  margin-top: 0.2rem;
  flex: 0 0 auto;
}

.cert-button {
  display: inline-flex;
  width: auto;
  text-decoration: none;
}

.cert-datos {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.35rem 1rem;
  margin: 1rem 0;
}

.cert-datos dt {
  color: var(--bio-muted);
  font-weight: 700;
}

.cert-datos dd {
  margin: 0;
  overflow-wrap: anywhere;
}

.verify-wrap {
  max-width: 560px;
}

.verify-title {
  margin: 0 0 1rem;
  color: var(--bio-navy);
  font-size: 1.8rem;
  line-height: 1.15;
}

.verify-result {
  margin-bottom: 1.25rem;
  padding: 1rem;
  border: 1px solid var(--bio-green);
  border-radius: 0.75rem;
  background: #f2f8ec;
}

.verify-result strong {
  color: #3d6b1f;
}
