/* ============================================================
   CENTRO JURÍDICO RIOSECO ABOGADOS — MÓDULO LEGAL TECH
   Estilos específicos de tech.html (hereda css/styles.css)
   ============================================================ */

/* ---------- Navegación: estado activo del módulo ---------- */
.nav-link.active { color: var(--brown); }
.nav-link.active::after { width: 100%; }

.nav-cta.is-current {
  background: var(--brown-dark);
  color: var(--gold-light);
  border-color: var(--gold);
}
.nav-cta.is-current:hover {
  background: var(--brown-mid);
  border-color: var(--gold-light);
  box-shadow: 0 8px 24px rgba(46, 33, 22, 0.3);
}

/* ---------- Hero Legal Tech ---------- */
.tech-hero {
  position: relative;
  min-height: 84vh;
  display: flex;
  align-items: center;
  overflow: hidden;
  background: var(--brown-dark);
}
.tech-hero-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0.22;
  filter: saturate(0.55) brightness(0.85);
  animation: heroZoom 18s ease-out forwards;
}
.tech-hero-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(184, 152, 96, 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(184, 152, 96, 0.06) 1px, transparent 1px);
  background-size: 46px 46px;
  pointer-events: none;
}
.tech-hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(100deg,
    rgba(36, 25, 16, 0.97) 0%,
    rgba(46, 33, 22, 0.9) 48%,
    rgba(88, 48, 40, 0.6) 100%);
}
.tech-hero-content {
  position: relative;
  z-index: 2;
  color: var(--cream-light);
  padding-top: 96px;
  padding-bottom: 84px;
  max-width: 800px;
  margin-left: 0;
}
.tech-hero .hero-sub { margin-bottom: 34px; }

.tech-kpis {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-top: 48px;
  padding-top: 30px;
  border-top: 1px solid rgba(245, 241, 230, 0.2);
}
.tech-kpi { padding-left: 16px; border-left: 2px solid var(--gold); }
.tech-kpi strong {
  display: block;
  font-family: 'Playfair Display', serif;
  font-size: clamp(19px, 2vw, 24px);
  font-weight: 600;
  color: var(--gold-light);
  line-height: 1.15;
}
.tech-kpi span {
  display: block;
  margin-top: 6px;
  font-size: 13.5px;
  color: rgba(245, 241, 230, 0.75);
}

/* ---------- Pilares normativos ---------- */
.pillars-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 26px;
}
.pillar-card {
  background: var(--white);
  border: 1px solid var(--cream-deep);
  border-top: 3px solid var(--gold);
  border-radius: var(--radius);
  padding: 34px 28px;
  box-shadow: var(--shadow);
  transition: var(--transition);
}
.pillar-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}
.pillar-num {
  font-family: 'Playfair Display', serif;
  font-size: 40px;
  font-weight: 700;
  color: var(--gold-pale);
  line-height: 1;
  margin-bottom: 14px;
}
.pillar-card h3 { font-size: 21px; margin-bottom: 12px; }
.pillar-card p { color: var(--ink-soft); font-size: 15.5px; }
.pillar-card strong { color: var(--brown); }

/* ---------- Caso crítico: hallazgos ---------- */
.tech-findings { display: grid; gap: 18px; margin-bottom: 34px; }
.tech-finding {
  display: grid;
  grid-template-columns: 52px 1fr;
  gap: 20px;
  background: rgba(251, 248, 241, 0.04);
  border: 1px solid rgba(245, 241, 230, 0.12);
  border-radius: var(--radius);
  padding: 24px 26px;
  transition: var(--transition);
}
.tech-finding:hover {
  border-color: rgba(184, 152, 96, 0.5);
  transform: translateX(4px);
}
.tech-finding-num {
  width: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--gold);
  border-radius: 50%;
  font-family: 'Playfair Display', serif;
  font-size: 20px;
  font-weight: 700;
  color: var(--gold-light);
}
.tech-finding h3 { font-size: 19px; color: var(--cream-light); margin-bottom: 6px; }
.tech-finding p { color: rgba(245, 241, 230, 0.75); font-size: 15.5px; }
.tech-finding strong { color: var(--gold-light); font-weight: 600; }

.tech-verdict {
  display: flex;
  gap: 18px;
  align-items: flex-start;
  background: rgba(184, 152, 96, 0.1);
  border-left: 4px solid var(--gold);
  border-radius: var(--radius);
  padding: 26px 30px;
}
.tech-verdict-icon { flex: 0 0 auto; color: var(--gold-light); margin-top: 2px; }
.tech-verdict p { color: rgba(245, 241, 230, 0.88); font-size: 16.5px; }
.tech-verdict strong { color: var(--gold-light); }
.tech-verdict a { color: var(--gold-light); text-decoration: underline; text-underline-offset: 3px; }
.tech-verdict a:hover { color: var(--cream-light); }

/* ---------- Requisitos por plataforma ---------- */
.platform-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px;
  align-items: start;
}
.platform-card {
  background: var(--white);
  border: 1px solid var(--cream-deep);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.platform-head {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 22px 28px;
  border-bottom: 1px solid var(--cream-deep);
  background: var(--cream);
}
.platform-head svg { color: var(--gold); flex: 0 0 auto; }
.platform-head h3 { font-size: 21px; line-height: 1.25; }
.platform-head span {
  display: block;
  font-size: 13.5px;
  color: var(--ink-soft);
  font-weight: 400;
  font-family: 'Source Sans 3', sans-serif;
  margin-top: 2px;
}
.platform-body { padding: 26px 28px; }

.tech-list li {
  position: relative;
  padding: 7px 0 7px 24px;
  color: var(--ink-soft);
  font-size: 15.5px;
  border-bottom: 1px solid var(--cream-deep);
}
.tech-list li:last-child { border-bottom: none; }
.tech-list li::before {
  content: "";
  position: absolute;
  left: 4px; top: 15px;
  width: 8px; height: 8px;
  border: 1.5px solid var(--gold);
  transform: rotate(45deg);
}
.tech-list strong { color: var(--brown); }
.tech-list code {
  padding: 1px 5px;
  border-radius: 3px;
  background: var(--cream-deep);
  color: var(--brown-dark);
  font-size: 0.9em;
}
.platform-note { margin-top: 24px; font-size: 14.5px; color: var(--ink-soft); }
.platform-note strong { color: var(--brown); }

/* ---------- Matriz de riesgos ---------- */
.risk-wrap {
  background: var(--white);
  border: 1px solid var(--cream-deep);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow-x: auto;
}
.risk-table { width: 100%; border-collapse: collapse; min-width: 760px; }
.risk-table th {
  background: var(--brown-dark);
  color: var(--cream-light);
  text-align: left;
  padding: 16px 20px;
  font-family: 'Source Sans 3', sans-serif;
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.risk-table th:nth-child(1) { width: 27%; }
.risk-table th:nth-child(2) { width: 38%; }
.risk-table th:nth-child(3) { width: 16%; }
.risk-table td {
  padding: 18px 20px;
  border-bottom: 1px solid var(--cream-deep);
  vertical-align: top;
  font-size: 15px;
  color: var(--ink-soft);
}
.risk-table tbody tr:last-child td { border-bottom: none; }
.risk-table tbody tr:hover { background: var(--cream-light); }
.risk-vector { font-weight: 600; color: var(--brown-dark); }
.risk-level {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 2px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  background: var(--gold-pale);
  color: var(--brown-dark);
  white-space: nowrap;
}
.risk-amount { font-weight: 700; color: var(--brown); white-space: nowrap; }

.risk-warning {
  margin-top: 26px;
  border-left: 4px solid var(--brown);
  background: var(--cream);
  padding: 22px 26px;
  box-shadow: inset 0 0 0 1px var(--cream-deep);
}
.risk-warning p { color: var(--ink-soft); font-size: 15.5px; }
.risk-warning strong { color: var(--brown-dark); }

/* ---------- Protocolo 72 horas ---------- */
.roadmap { display: flex; flex-direction: column; }
.roadmap-step {
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: 30px;
  padding: 26px 0;
  border-bottom: 1px dashed rgba(245, 241, 230, 0.16);
}
.roadmap-step:last-child { border-bottom: none; }
.roadmap-hours {
  font-family: 'Playfair Display', serif;
  font-size: 19px;
  font-weight: 600;
  color: var(--gold-light);
  line-height: 1.3;
}
.roadmap-body h3 { font-size: 20px; color: var(--cream-light); margin-bottom: 8px; }
.roadmap-body p { color: rgba(245, 241, 230, 0.75); font-size: 15.5px; }
.roadmap-body strong { color: var(--gold-light); font-weight: 600; }
.roadmap-cta { margin-top: 36px; display: flex; gap: 14px; flex-wrap: wrap; }

/* ---------- Calculadora ---------- */
.calc-card {
  max-width: 880px;
  margin: 0 auto;
  background: var(--white);
  border: 1px solid var(--cream-deep);
  border-top: 3px solid var(--gold);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  padding: 52px 48px;
}
.calc-fields {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 26px;
}
.calc-field label {
  display: block;
  font-weight: 600;
  font-size: 15px;
  color: var(--brown);
  margin-bottom: 10px;
}
.calc-field small {
  display: block;
  color: var(--ink-soft);
  font-weight: 400;
  margin-top: 7px;
  font-size: 13.5px;
}
.calc-select, .calc-input {
  width: 100%;
  padding: 13px 15px;
  border: 1px solid var(--cream-deep);
  border-radius: var(--radius);
  background: var(--cream-light);
  color: var(--ink);
  font-family: 'Source Sans 3', sans-serif;
  font-size: 16px;
  transition: var(--transition);
}
.calc-select:focus, .calc-input:focus {
  outline: none;
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(184, 152, 96, 0.2);
}
.calc-results {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
  margin-top: 32px;
}
.calc-out {
  background: var(--brown-dark);
  border-left: 3px solid var(--gold);
  border-radius: var(--radius);
  padding: 24px 26px;
}
.calc-out-label {
  display: block;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold-light);
  margin-bottom: 8px;
}
.calc-out-value {
  font-family: 'Playfair Display', serif;
  font-size: clamp(24px, 3vw, 32px);
  font-weight: 700;
  color: var(--cream-light);
  line-height: 1.15;
  word-break: break-word;
}
.calc-out-value.clp { color: var(--gold-light); }
.calc-note {
  margin-top: 24px;
  border-left: 4px solid var(--gold);
  background: var(--cream);
  padding: 18px 22px;
}
.calc-note p { color: var(--ink-soft); font-size: 15px; }
.calc-note strong { color: var(--brown-dark); }
.calc-disclaimer {
  margin-top: 18px;
  font-size: 13px;
  color: var(--ink-soft);
  opacity: 0.85;
}

/* ---------- Formulario de diagnóstico ---------- */
.diag-card {
  max-width: 880px;
  margin: 0 auto;
  background: rgba(251, 248, 241, 0.04);
  border: 1px solid rgba(245, 241, 230, 0.14);
  border-top: 3px solid var(--gold);
  border-radius: var(--radius);
  padding: 52px 48px;
}
.diag-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
}
.diag-field label {
  display: block;
  font-weight: 600;
  font-size: 15px;
  color: var(--cream-light);
  margin-bottom: 9px;
}
.diag-input {
  width: 100%;
  padding: 13px 15px;
  border: 1px solid rgba(245, 241, 230, 0.2);
  border-radius: var(--radius);
  background: rgba(251, 248, 241, 0.06);
  color: var(--cream-light);
  font-family: 'Source Sans 3', sans-serif;
  font-size: 16px;
  transition: var(--transition);
}
.diag-input::placeholder { color: rgba(245, 241, 230, 0.4); }
.diag-input:focus {
  outline: none;
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(184, 152, 96, 0.22);
}
.diag-full { grid-column: 1 / -1; }
.diag-check {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  margin-top: 4px;
}
.diag-check input[type="checkbox"] {
  flex: 0 0 auto;
  width: 18px;
  height: 18px;
  margin-top: 3px;
  accent-color: var(--gold);
}
.diag-check label {
  font-weight: 400;
  font-size: 14.5px;
  color: rgba(245, 241, 230, 0.85);
  line-height: 1.55;
}
.diag-check a { color: var(--gold-light); text-decoration: underline; text-underline-offset: 2px; }
.diag-check a:hover { color: var(--cream-light); }
.form-error {
  display: none;
  margin-top: 22px;
  padding: 14px 18px;
  border-left: 4px solid #C9705A;
  background: rgba(201, 112, 90, 0.12);
  color: #F2C6B8;
  font-size: 14.5px;
}
.form-error.visible { display: block; }
.form-ok {
  display: none;
  margin-top: 22px;
  padding: 14px 18px;
  border-left: 4px solid var(--gold);
  background: rgba(184, 152, 96, 0.12);
  color: var(--gold-pale);
  font-size: 14.5px;
}
.form-ok.visible { display: block; }
.diag-submit {
  margin-top: 28px;
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  align-items: center;
}
.diag-alt { font-size: 14px; color: rgba(245, 241, 230, 0.7); }
.diag-alt a { color: var(--gold-light); text-decoration: underline; text-underline-offset: 2px; }
.diag-legal {
  margin-top: 26px;
  padding-top: 22px;
  border-top: 1px solid rgba(245, 241, 230, 0.14);
  font-size: 13.5px;
  color: rgba(245, 241, 230, 0.65);
  line-height: 1.65;
}
.diag-legal a { color: var(--gold-light); text-decoration: underline; text-underline-offset: 2px; }

/* ---------- Sección Auditoría Digital Express ---------- */
.audit-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
  margin-bottom: 44px;
  align-items: stretch;
}
.audit-card {
  background: rgba(251, 248, 241, 0.04);
  border: 1px solid rgba(245, 241, 230, 0.12);
  border-top: 3px solid var(--gold);
  border-radius: var(--radius);
  padding: 38px 34px;
  display: flex;
  flex-direction: column;
  transition: var(--transition);
}
.audit-card:hover {
  border-color: rgba(184, 152, 96, 0.45);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.28);
  transform: translateY(-2px);
}
.audit-card-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 22px;
  padding-bottom: 18px;
  border-bottom: 1px solid rgba(245, 241, 230, 0.12);
}
.audit-card-num {
  font-family: 'Playfair Display', serif;
  font-size: 28px;
  font-weight: 700;
  color: var(--gold-light);
  line-height: 1;
}
.audit-card-header h3 {
  font-size: 24px;
  color: var(--cream-light);
  margin: 0;
}
.audit-card-body {
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}
.audit-intro {
  font-size: 16px;
  color: rgba(245, 241, 230, 0.88);
  margin-bottom: 14px;
  line-height: 1.65;
}
.audit-intro strong {
  color: var(--gold-light);
  font-weight: 600;
}
.audit-subintro {
  font-size: 15px;
  color: rgba(245, 241, 230, 0.75);
  margin-bottom: 18px;
  line-height: 1.6;
}
.audit-subintro strong {
  color: var(--cream-light);
  font-weight: 600;
}
.audit-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-bottom: 22px;
}
.audit-list li {
  position: relative;
  padding-left: 24px;
  color: rgba(245, 241, 230, 0.78);
  font-size: 15px;
  line-height: 1.6;
}
.audit-list li::before {
  content: "";
  position: absolute;
  left: 4px;
  top: 9px;
  width: 7px;
  height: 7px;
  border: 1.5px solid var(--gold);
  transform: rotate(45deg);
}
.audit-list strong {
  color: var(--gold-light);
  font-weight: 600;
}
.audit-credit-callout {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: auto;
  padding: 16px 20px;
  background: rgba(184, 152, 96, 0.1);
  border-left: 3px solid var(--gold);
  border-radius: var(--radius);
  color: var(--gold-pale);
  font-size: 14.5px;
}
.audit-credit-callout svg {
  flex: 0 0 auto;
  color: var(--gold-light);
}
.audit-credit-callout strong {
  color: var(--cream-light);
}
.audit-cta-banner {
  background: linear-gradient(135deg, rgba(88, 48, 40, 0.4) 0%, rgba(46, 33, 22, 0.75) 100%);
  border: 1px solid var(--gold);
  border-radius: var(--radius);
  padding: 38px 46px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 32px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.28);
}
.audit-cta-info h3 {
  font-size: 24px;
  color: var(--cream-light);
  margin-bottom: 8px;
}
.audit-cta-info p {
  font-size: 15.5px;
  color: rgba(245, 241, 230, 0.78);
  max-width: 600px;
}
.audit-cta-actions {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}
.audit-btn {
  padding: 15px 32px;
  font-size: 15px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.audit-cta-url {
  font-size: 12.5px;
  letter-spacing: 0.04em;
  color: var(--gold-pale);
  opacity: 0.85;
  word-break: break-all;
}

/* ============================================================
   RESPONSIVE DEL MÓDULO
   ============================================================ */
@media (max-width: 1024px) {
  .pillars-grid { grid-template-columns: 1fr 1fr; }
  .pillar-card:last-child { grid-column: 1 / -1; }
  .roadmap-step { grid-template-columns: 130px 1fr; gap: 22px; }
  .calc-card, .diag-card { padding: 40px 34px; }
}

@media (max-width: 860px) {
  .tech-hero { min-height: auto; }
  .tech-kpis { grid-template-columns: 1fr 1fr; gap: 20px; }
  .pillars-grid, .platform-grid, .calc-fields, .diag-grid, .audit-grid { grid-template-columns: 1fr; }
  .pillar-card:last-child { grid-column: auto; }
  .calc-results { grid-template-columns: 1fr; }
  .roadmap-step { grid-template-columns: 1fr; gap: 10px; }
  .tech-finding { grid-template-columns: 44px 1fr; gap: 16px; }
  .tech-finding-num { width: 44px; height: 44px; font-size: 17px; }
  .audit-cta-banner { flex-direction: column; text-align: center; padding: 32px 24px; }
  .audit-cta-info p { margin: 0 auto; }
}

@media (max-width: 560px) {
  .tech-kpis { grid-template-columns: 1fr; }
  .calc-card, .diag-card { padding: 30px 22px; }
  .audit-card { padding: 28px 20px; }
  .audit-cta-banner { padding: 24px 16px; }
  .audit-btn { width: 100%; justify-content: center; }
}
