:root{
  --bg: #0b0b0d;
  --panel: #151519;
  --panel-2: #e6e6e6; /* gris claro para contraste */
  --text: #f3f3f3;
  --muted: #c8c8c8;
  --gold: #d4af37;
  --line: rgba(255,255,255,.12);
  --shadow: 0 18px 50px rgba(0,0,0,.35);
  --radius: 18px;
  --radius-sm: 14px;
  --max: 1100px;
}

*{ box-sizing: border-box; }
html{ scroll-behavior: smooth; }
body{
  margin:0;
  font-family: Inter, system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  background: radial-gradient(1200px 700px at 20% -10%, rgba(212,175,55,.12), transparent 55%),
              radial-gradient(900px 600px at 110% 10%, rgba(255,255,255,.06), transparent 55%),
              var(--bg);
  color: var(--text);
  line-height: 1.6;
}

a{ color: inherit; text-decoration: none; }
.container{ width: min(var(--max), calc(100% - 48px)); margin: 0 auto; }

.skip-link{
  position:absolute;
  left:-999px;
  top: 12px;
  background: var(--gold);
  color: #111;
  padding: 10px 12px;
  border-radius: 10px;
  font-weight: 700;
  z-index: 9999;
}
.skip-link:focus{ left: 12px; }

.site-header{
  position: sticky;
  top:0;
  z-index: 1000;
  backdrop-filter: blur(10px);
  background: rgba(11,11,13,.75);
  border-bottom: 1px solid var(--line);
}
.header-inner{
  display:flex;
  align-items:center;
  justify-content: space-between;
  padding: 14px 0;
  gap: 18px;
}
.header-divider{ height: 1px; background: transparent; }

.brand-link{
  display:flex;
  align-items:center;
  gap: 12px;
}
.brand-mark{
  width: 14px;
  height: 14px;
  border: 2px solid var(--gold);
  border-radius: 999px;
  position: relative;
}
.brand-mark::after{
  content:"";
  position:absolute;
  right:-12px;
  top:50%;
  width: 10px;
  height: 2px;
  background: var(--gold);
  transform: translateY(-50%);
  opacity: .9;
}
.brand-text{ display:flex; flex-direction: column; }
.brand-name{
  font-weight: 800;
  letter-spacing: .2px;
}
.brand-sub{
  color: var(--muted);
  font-size: 12.5px;
  margin-top: -2px;
}

.nav{
  display:flex;
  align-items:center;
  gap: 16px;
}
.nav-link{
  font-weight: 600;
  color: var(--muted);
  padding: 8px 10px;
  border-radius: 10px;
  transition: transform .15s ease, background .15s ease, color .15s ease;
}
.nav-link:hover{
  background: rgba(255,255,255,.06);
  color: var(--text);
  transform: translateY(-1px);
}
.nav-link.is-active{
  color: var(--text);
  background: rgba(212,175,55,.12);
  border: 1px solid rgba(212,175,55,.25);
}

.nav-toggle{
  display:none;
  width: 44px;
  height: 40px;
  border-radius: 12px;
  background: rgba(255,255,255,.06);
  border: 1px solid var(--line);
  align-items:center;
  justify-content:center;
  gap: 6px;
  cursor:pointer;
}
.nav-toggle-bar{
  width: 18px;
  height: 2px;
  background: var(--text);
  opacity: .9;
  display:block;
}

/* HERO */
.hero{ padding: 54px 0 22px; }
.hero-inner{ padding: 18px 0 0; }
.kicker{
  color: var(--muted);
  font-weight: 600;
  letter-spacing: .4px;
  text-transform: uppercase;
  font-size: 12px;
  margin: 0 0 10px;
}
.hero-title{
  margin: 0;
  font-family: "Playfair Display", serif;
  letter-spacing: .2px;
  font-size: clamp(28px, 3.2vw, 44px);
  line-height: 1.15;
}
.hero-accent{
  display:block;
  margin-top: 10px;
  color: rgba(255,255,255,.88);
  font-family: Inter, system-ui, sans-serif;
  font-weight: 700;
  font-size: clamp(16px, 1.6vw, 18px);
}
.hero-lead{
  margin: 18px 0 22px;
  max-width: 70ch;
  color: rgba(255,255,255,.82);
}

.hero-actions{ display:flex; gap: 12px; flex-wrap: wrap; }
.btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap: 10px;
  padding: 11px 14px;
  border-radius: 14px;
  border: 1px solid var(--line);
  cursor:pointer;
  font-weight: 700;
  transition: transform .15s ease, background .15s ease, border-color .15s ease;
  user-select:none;
}
.btn:active{ transform: translateY(1px); }
.btn-primary{
  background: rgba(212,175,55,.15);
  border-color: rgba(212,175,55,.35);
}
.btn-primary:hover{
  background: rgba(212,175,55,.22);
  border-color: rgba(212,175,55,.55);
}
.btn-ghost{
  background: rgba(255,255,255,.06);
}
.btn-ghost:hover{
  background: rgba(255,255,255,.10);
}

.hero-meta{
  margin-top: 22px;
  display:flex;
  gap: 10px;
  flex-wrap: wrap;
}
.meta-pill{
  display:flex;
  align-items:center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 999px;
  background: rgba(255,255,255,.05);
  border: 1px solid var(--line);
  color: rgba(255,255,255,.80);
  font-size: 13px;
}
.dot{
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: var(--gold);
  box-shadow: 0 0 0 4px rgba(212,175,55,.15);
}

/* SECTIONS */
.section{ padding: 40px 0 52px; }
.section-alt{
  background: linear-gradient(180deg, rgba(230,230,230,.10), rgba(230,230,230,.06));
  border-top: 1px solid rgba(255,255,255,.10);
  border-bottom: 1px solid rgba(255,255,255,.10);
}
.section-head{ margin-bottom: 18px; }
.section-title{
  margin: 0 0 8px;
  color: var(--gold);
  font-weight: 800;
  letter-spacing: .2px;
  font-size: 26px;
}
.section-subtitle{
  margin: 0;
  color: rgba(255,255,255,.80);
  max-width: 80ch;
}

/* Tools */
.tools{
  margin-top: 18px;
  display:flex;
  align-items:flex-end;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.search{
  display:flex;
  flex-direction: column;
  gap: 8px;
}
.search-label{
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .35px;
}
.search input{
  width: min(520px, 90vw);
  background: rgba(255,255,255,.06);
  border: 1px solid var(--line);
  color: var(--text);
  padding: 12px 12px;
  border-radius: 14px;
  outline: none;
}
.search input:focus{
  border-color: rgba(212,175,55,.55);
  box-shadow: 0 0 0 4px rgba(212,175,55,.12);
}

.chips{ display:flex; gap: 8px; flex-wrap: wrap; }
.chip{
  padding: 9px 10px;
  border-radius: 999px;
  background: rgba(255,255,255,.06);
  border: 1px solid var(--line);
  color: rgba(255,255,255,.82);
  cursor:pointer;
  font-weight: 700;
  font-size: 13px;
  transition: background .15s ease, border-color .15s ease, transform .15s ease;
}
.chip:hover{ background: rgba(255,255,255,.10); transform: translateY(-1px); }
.chip.is-active{
  background: rgba(212,175,55,.18);
  border-color: rgba(212,175,55,.45);
  color: var(--text);
}

/* Cards */
.cards{
  margin-top: 22px;
  display:grid;
  grid-template-columns: 1fr;
  gap: 14px;
}
.card{
  display:flex;
  gap: 16px;
  padding: 18px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: rgba(255,255,255,.05);
  box-shadow: var(--shadow);
  transform: translateY(0);
  transition: transform .16s ease, background .16s ease, border-color .16s ease;
}
.card:hover{
  transform: translateY(-2px);
  background: rgba(255,255,255,.07);
  border-color: rgba(212,175,55,.25);
}
.card:focus{
  outline: 3px solid rgba(212,175,55,.25);
  outline-offset: 2px;
}
.card-icon{
  min-width: 50px;
  height: 50px;
  border-radius: 16px;
  display:grid;
  place-items:center;
  font-weight: 800;
  color: #111;
  background: linear-gradient(135deg, rgba(212,175,55,.95), rgba(212,175,55,.55));
}
.card-title{
  margin: 0 0 6px;
  font-weight: 900;
  letter-spacing: .2px;
  color: var(--gold);
}
.card-text{
  margin: 0 0 12px;
  color: rgba(255,255,255,.82);
}
.card-details summary{
  cursor:pointer;
  font-weight: 800;
  color: rgba(255,255,255,.88);
  list-style: none;
}
.card-details summary::-webkit-details-marker{ display:none; }
.card-details summary::before{
  content:"＋";
  display:inline-block;
  width: 22px;
  color: var(--gold);
}
.card-details[open] summary::before{ content:"－"; }
.card-details ul{
  margin: 10px 0 0 22px;
  color: rgba(255,255,255,.80);
}
.card-foot{
  margin-top: 14px;
  display:flex;
  align-items:center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}
.pill{
  display:inline-flex;
  align-items:center;
  gap: 10px;
  padding: 7px 10px;
  border-radius: 999px;
  border: 1px solid rgba(212,175,55,.35);
  background: rgba(212,175,55,.10);
  font-weight: 800;
  font-size: 12px;
}
.link{
  color: rgba(255,255,255,.88);
  font-weight: 800;
  border-bottom: 1px solid rgba(212,175,55,.45);
  padding-bottom: 2px;
}
.link:hover{
  color: var(--text);
  border-bottom-color: rgba(212,175,55,.85);
}

.note{
  margin-top: 16px;
  padding: 14px 16px;
  border-radius: var(--radius-sm);
  background: rgba(255,255,255,.05);
  border: 1px solid var(--line);
  color: rgba(255,255,255,.78);
}

/* Profile */
.profile{
  margin-top: 18px;
  display:grid;
  grid-template-columns: 1.6fr .9fr;
  gap: 14px;
}
.profile-card{
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: rgba(255,255,255,.06);
  box-shadow: var(--shadow);
  padding: 18px;
}
.profile-top{
  display:flex;
  align-items:center;
  gap: 14px;
  margin-bottom: 12px;
}
.avatar{
  width: 56px; height: 56px;
  border-radius: 18px;
  display:grid;
  place-items:center;
  font-weight: 900;
  color: #111;
  background: linear-gradient(135deg, rgba(212,175,55,.95), rgba(212,175,55,.55));
}
.profile-name{
  margin: 0;
  font-size: 18px;
  font-weight: 900;
  color: var(--gold);
}
.profile-roles{
  margin: 2px 0 0;
  color: rgba(255,255,255,.82);
  font-weight: 700;
  font-size: 13.5px;
}
.profile-body p{
  margin: 0 0 12px;
  color: rgba(255,255,255,.82);
}
.profile-actions{
  display:flex;
  align-items:center;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 10px;
}
.copy-status{
  color: rgba(255,255,255,.75);
  font-weight: 700;
  font-size: 13px;
}

.aside{
  display:flex;
  flex-direction: column;
  gap: 14px;
}
.aside-card{
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: rgba(255,255,255,.05);
  box-shadow: var(--shadow);
  padding: 18px;
}
.aside-title{
  margin: 0 0 8px;
  color: var(--gold);
  font-weight: 900;
}
.aside-list{
  margin: 0;
  padding-left: 18px;
  color: rgba(255,255,255,.80);
}
.aside-text{ margin: 0; color: rgba(255,255,255,.80); }

/* Contact */
.contact{
  margin-top: 18px;
  display:grid;
  grid-template-columns: 1.5fr .9fr;
  gap: 14px;
}
.form{
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: rgba(255,255,255,.06);
  box-shadow: var(--shadow);
  padding: 18px;
}
.form label{
  display:flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 12px;
}
.form span{
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .35px;
}
.form input, .form textarea{
  background: rgba(255,255,255,.06);
  border: 1px solid var(--line);
  color: var(--text);
  padding: 12px 12px;
  border-radius: 14px;
  outline: none;
}
.form input:focus, .form textarea:focus{
  border-color: rgba(212,175,55,.55);
  box-shadow: 0 0 0 4px rgba(212,175,55,.12);
}
.row{
  display:grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.form-actions{
  display:flex;
  align-items:center;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 6px;
}
.form-hint{
  margin: 0;
  color: rgba(255,255,255,.78);
  font-weight: 700;
}

.contact-card{
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: rgba(255,255,255,.05);
  box-shadow: var(--shadow);
  padding: 18px;
}
.contact-title{
  margin: 0 0 10px;
  color: var(--gold);
  font-weight: 900;
}
.contact-links{ display:flex; gap: 8px; flex-wrap: wrap; }
.mini{
  padding: 9px 10px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,.06);
  color: rgba(255,255,255,.86);
  cursor:pointer;
  font-weight: 800;
}
.mini:hover{ background: rgba(255,255,255,.10); }

.divider{ height: 1px; background: var(--line); margin: 14px 0; }
.muted{ margin: 0; color: rgba(255,255,255,.72); }

/* Footer */
.footer{
  border-top: 1px solid var(--line);
  padding: 22px 0;
}
.footer-inner{
  display:flex;
  align-items:center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}
.footer-text{ margin: 0; color: rgba(255,255,255,.72); font-weight: 700; }
.footer-link{
  color: rgba(255,255,255,.86);
  font-weight: 900;
  border-bottom: 1px solid rgba(212,175,55,.45);
  padding-bottom: 2px;
}

/* Responsive */
@media (max-width: 900px){
  .profile, .contact{ grid-template-columns: 1fr; }
}
@media (max-width: 760px){
  .nav{ display:none; }
  .nav.is-open{
    display:flex;
    width: 100%;
    flex-direction: column;
    align-items:flex-start;
    gap: 6px;
    padding: 10px 0 6px;
  }
  .nav-toggle{ display:flex; }
  .header-inner{ flex-wrap: wrap; }
  .row{ grid-template-columns: 1fr; }
}
/* ===== Ambiente (biblioteca + modal) ===== */
.lib-meta{
  display:flex;
  gap: 8px;
  flex-wrap: wrap;
  margin: 10px 0 10px;
}
.lib-summary .lib-p{
  margin: 0 0 10px;
  color: rgba(255,255,255,.82);
}

.lib-pdf{
  margin-top: 12px;
  display:flex;
  flex-direction: column;
  gap: 12px;
}
.pdf-frame{
  width: 100%;
  height: 520px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255,255,255,.04);
}
.lib-actions{
  display:flex;
  gap: 10px;
  flex-wrap: wrap;
}

/* Modal */
.modal{
  position: fixed;
  inset: 0;
  display: none;
  z-index: 2000;
}
.modal.is-open{ display: block; }

.modal-backdrop{
  position:absolute;
  inset:0;
  background: rgba(0,0,0,.62);
  backdrop-filter: blur(6px);
}
.modal-panel{
  position: relative;
  width: min(980px, calc(100% - 28px));
  margin: 26px auto;
  border-radius: 18px;
  border: 1px solid var(--line);
  background: rgba(20,20,24,.96);
  box-shadow: 0 25px 70px rgba(0,0,0,.55);
  overflow: hidden;
}
.modal-head{
  display:flex;
  align-items:flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 16px 10px;
  border-bottom: 1px solid var(--line);
}
.modal-kicker{
  margin:0;
  color: var(--muted);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .35px;
  font-size: 12px;
}
.modal-title{
  margin: 6px 0 0;
  color: var(--gold);
  font-weight: 900;
}
.modal-close{
  border: 1px solid var(--line);
  background: rgba(255,255,255,.06);
  color: var(--text);
  border-radius: 12px;
  padding: 8px 10px;
  cursor:pointer;
  font-weight: 900;
}

.modal-body{ padding: 14px 16px 16px; }
.modal-video{
  width: 100%;
  max-height: 420px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,.04);
}

.quiz{ margin-top: 14px; }
.quiz-q{
  margin: 0 0 12px;
  color: rgba(255,255,255,.88);
  font-weight: 800;
}
.quiz-options{
  display:grid;
  grid-template-columns: 1fr;
  gap: 10px;
}
.option{
  text-align: left;
  padding: 12px 12px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,.06);
  color: rgba(255,255,255,.88);
  cursor:pointer;
  font-weight: 800;
}
.option:hover{ background: rgba(255,255,255,.10); }
.option:disabled{ cursor: not-allowed; opacity: .85; }
.option.is-correct{
  border-color: rgba(212,175,55,.55);
  background: rgba(212,175,55,.18);
}
.option.is-wrong{
  border-color: rgba(255,255,255,.22);
  background: rgba(255,255,255,.08);
}

.quiz-result{
  margin-top: 12px;
  padding: 12px 12px;
  border-radius: 14px;
  border: 1px solid rgba(212,175,55,.25);
  background: rgba(212,175,55,.10);
}
.quiz-result-title{
  margin: 0 0 6px;
  font-weight: 900;
  color: var(--text);
}
.quiz-result-explain{
  margin: 0;
  color: rgba(255,255,255,.86);
}

.modal-foot{
  display:flex;
  justify-content:flex-end;
  gap: 10px;
  flex-wrap: wrap;
  padding: 12px 16px 16px;
  border-top: 1px solid var(--line);
}
