/* ═══════════════════════════════════════════════════════
   GRANDOTE — Criptografía Interactiva
   styles.css
═══════════════════════════════════════════════════════ */
@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@300;400;600;700;900&family=JetBrains+Mono:wght@400;600&display=swap');

/* ── Variables ────────────────────────────────────────── */
:root {
  --primary:      #FFAE23;
  --primary-dim:  rgba(255,174,35,.18);
  --primary-glow: rgba(255,174,35,.4);
  --bg-dark:      #080D1E;
  --bg-navy:      #0F1A35;
  --bg-card:      rgba(15,26,53,.95);
  --bg-glass:     rgba(255,255,255,.04);
  --blue:         #1565C0;
  --blue-light:   #64B5F6;
  --cyan:         #00E5FF;
  --green:        #00C853;
  --danger:       #FF1744;
  --border:       rgba(255,174,35,.22);
  --text:         #FFFFFF;
  --text-muted:   rgba(255,255,255,.62);
  --font:         'Montserrat', sans-serif;
  --mono:         'JetBrains Mono', 'Consolas', monospace;
  --radius:       12px;
  --radius-lg:    20px;
  --shadow:       0 6px 40px rgba(0,0,0,.55);
  --shadow-gold:  0 0 35px rgba(255,174,35,.14);
}

/* ── Reset & Base ─────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font);
  background: var(--bg-dark);
  color: var(--text);
  overflow-x: hidden;
  line-height: 1.6;
}
::-webkit-scrollbar { width: 5px; }
::-webkit-scrollbar-track { background: var(--bg-dark); }
::-webkit-scrollbar-thumb { background: var(--primary); border-radius: 3px; }
::selection { background: var(--primary); color: #000; }

/* ── Navbar ───────────────────────────────────────────── */
#mainNav {
  background: transparent;
  transition: all .35s ease;
  padding: 1.3rem 0;
  z-index: 1040;
}
#mainNav.scrolled {
  background: rgba(8,13,30,.96) !important;
  backdrop-filter: blur(20px);
  padding: .6rem 0;
  border-bottom: 1px solid var(--border);
  box-shadow: var(--shadow);
}
.navbar-brand img { height: 38px; filter: drop-shadow(0 0 12px rgba(255,174,35,.5)); }
.nav-link {
  color: rgba(255,255,255,.82) !important;
  font-weight: 600;
  font-size: .82rem;
  letter-spacing: .6px;
  text-transform: uppercase;
  padding: .5rem .9rem !important;
  position: relative;
  transition: color .2s;
}
.nav-link::after {
  content: '';
  position: absolute; bottom: 0; left: 50%;
  width: 0; height: 2px;
  background: var(--primary);
  transform: translateX(-50%);
  transition: width .3s ease;
}
.nav-link:hover, .nav-link.active {
  color: var(--primary) !important;
}
.nav-link:hover::after, .nav-link.active::after { width: 60%; }
.navbar-toggler { border-color: var(--border); }
.navbar-toggler-icon { filter: invert(1); }

/* ── Hero ─────────────────────────────────────────────── */
#hero {
  position: relative;
  min-height: 100vh;
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
  background: var(--bg-dark);
}
#heroCanvas {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  pointer-events: none;
}
.hero-overlay {
  position: absolute; inset: 0;
  background: radial-gradient(ellipse 80% 60% at 50% 40%,
    rgba(255,174,35,.07) 0%, rgba(8,13,30,.88) 70%);
}
.hero-content {
  position: relative; z-index: 10;
  text-align: center; padding: 2rem;
  max-width: 800px;
}
.hero-logo {
  width: 170px; height: auto;
  margin-bottom: 2.2rem;
  filter: drop-shadow(0 0 40px rgba(255,174,35,.55));
  opacity: 0; transform: translateY(-30px);
}
.hero-eyebrow {
  display: inline-block;
  background: var(--primary-dim);
  border: 1px solid var(--border);
  color: var(--primary);
  padding: .3rem 1.1rem;
  border-radius: 100px;
  font-size: .78rem; font-weight: 700;
  letter-spacing: 1.5px; text-transform: uppercase;
  margin-bottom: 1.2rem;
  opacity: 0;
}
.hero-title {
  font-size: clamp(2.4rem, 5.5vw, 4.5rem);
  font-weight: 900; line-height: 1.1;
  color: var(--text); opacity: 0;
}
.hero-title .hi { color: var(--primary); }
.hero-subtitle {
  font-family: var(--mono);
  font-size: clamp(.9rem, 2vw, 1.05rem);
  color: var(--text-muted);
  margin: 1.6rem 0 2.8rem;
  min-height: 1.4em;
  opacity: 0;
}
.typed-cursor {
  display: inline-block;
  width: 2px; height: .9em;
  background: var(--primary);
  animation: blink 1s infinite;
  vertical-align: middle; margin-left: 3px;
}
@keyframes blink { 0%,100%{opacity:1} 50%{opacity:0} }
.hero-cta { opacity: 0; display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }

/* Buttons */
.btn-gold {
  background: var(--primary); color: #000 !important;
  font-weight: 700; font-size: .88rem;
  padding: .75rem 2.2rem; border-radius: 100px;
  border: none; letter-spacing: .4px;
  transition: all .3s ease;
  box-shadow: 0 4px 20px rgba(255,174,35,.4);
}
.btn-gold:hover {
  background: #ffe06b; transform: translateY(-3px);
  box-shadow: 0 8px 30px rgba(255,174,35,.55);
}
.btn-outline-gold {
  background: transparent;
  color: var(--primary) !important;
  border: 2px solid var(--primary);
  font-weight: 700; font-size: .88rem;
  padding: .75rem 2.2rem; border-radius: 100px;
  transition: all .3s ease;
}
.btn-outline-gold:hover {
  background: var(--primary); color: #000 !important;
  transform: translateY(-3px);
}
.scroll-indicator {
  position: absolute; bottom: 2rem; left: 50%;
  transform: translateX(-50%);
  color: var(--primary); font-size: 1.6rem;
  animation: bounce 2.2s ease-in-out infinite; z-index: 10;
  opacity: .7;
}
@keyframes bounce {
  0%,100%{ transform: translateX(-50%) translateY(0); }
  50%{ transform: translateX(-50%) translateY(10px); }
}

/* ── Stats Bar ────────────────────────────────────────── */
#stats {
  padding: 55px 0;
  background: var(--bg-navy);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.stat-card { text-align: center; padding: 1rem; }
.stat-num {
  display: block;
  font-size: 2.8rem; font-weight: 900;
  font-family: var(--mono);
  color: var(--primary);
  line-height: 1;
}
.stat-label {
  font-size: .8rem; color: var(--text-muted);
  text-transform: uppercase; letter-spacing: 1px;
  margin-top: .4rem;
}

/* ── Section Generic ──────────────────────────────────── */
section { padding: 100px 0; }
.section-navy { background: var(--bg-navy); }
.section-dark { background: var(--bg-dark); }
.section-badge {
  display: inline-block;
  background: var(--primary-dim);
  border: 1px solid var(--border);
  color: var(--primary);
  padding: .3rem 1rem;
  border-radius: 100px;
  font-size: .78rem; font-weight: 700;
  letter-spacing: 1px; text-transform: uppercase;
  margin-bottom: 1rem;
}
.section-title {
  font-size: clamp(1.9rem, 4vw, 2.7rem);
  font-weight: 900; color: var(--text);
  line-height: 1.15;
}
.section-title .hi { color: var(--primary); }
.divider { width: 55px; height: 4px; background: var(--primary); border-radius: 2px; margin: 1rem 0 1.5rem; }
.divider-center { margin-left: auto; margin-right: auto; }
.section-desc { color: var(--text-muted); font-size: 1rem; max-width: 580px; }

/* ── Model Cards ──────────────────────────────────────── */
.model-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 2.5rem 2rem;
  height: 100%;
  transition: all .4s ease;
  position: relative; overflow: hidden;
}
.model-card::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, transparent, var(--primary), transparent);
  opacity: 0; transition: opacity .3s;
}
.model-card:hover {
  transform: translateY(-10px);
  border-color: rgba(255,174,35,.5);
  box-shadow: var(--shadow-gold), var(--shadow);
}
.model-card:hover::before { opacity: 1; }
.card-icon-wrap {
  width: 68px; height: 68px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.9rem;
  margin-bottom: 1.5rem;
  border: 2px solid;
}
.i-yellow { background: rgba(255,174,35,.12); border-color: var(--primary); color: var(--primary); }
.i-blue   { background: rgba(100,181,246,.12); border-color: var(--blue-light); color: var(--blue-light); }
.i-cyan   { background: rgba(0,229,255,.12); border-color: var(--cyan); color: var(--cyan); }
.card-title-sm { font-size: 1.22rem; font-weight: 800; margin-bottom: .8rem; }
.card-body-text { color: var(--text-muted); font-size: .9rem; line-height: 1.75; }
.card-tag {
  display: inline-block;
  background: var(--primary-dim);
  color: var(--primary);
  border: 1px solid var(--border);
  font-size: .72rem; font-weight: 700;
  padding: .2rem .7rem; border-radius: 100px;
  margin-top: 1rem;
}

/* ── Sim Panels ───────────────────────────────────────── */
.sim-panel {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow);
}
.sim-topbar {
  background: rgba(8,13,30,.95);
  border-bottom: 1px solid var(--border);
  padding: 1rem 1.5rem;
  display: flex; align-items: center; gap: .7rem;
}
.dot { width: 11px; height: 11px; border-radius: 50%; display: inline-block; }
.dot-r { background: #ff5f57; }
.dot-y { background: #febc2e; }
.dot-g { background: #28c840; }
.sim-topbar-title { font-family: var(--mono); font-size: .82rem; color: var(--text-muted); margin-left: .4rem; }
.sim-body { padding: 2rem; }

/* Terminal */
.terminal {
  background: #020409;
  border: 1px solid rgba(255,174,35,.12);
  border-radius: var(--radius);
  padding: 1.4rem 1.5rem;
  font-family: var(--mono); font-size: .84rem;
  min-height: 130px; overflow-x: auto;
  line-height: 1.7;
}
.t-prompt { color: var(--primary); }
.t-key    { color: var(--cyan); }
.t-val    { color: var(--text); }
.t-ok     { color: var(--green); }
.t-err    { color: var(--danger); }
.t-info   { color: var(--blue-light); }
.t-dim    { color: #444; }

/* Form controls */
.sim-label {
  font-size: .78rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .6px;
  color: var(--text-muted); margin-bottom: .4rem;
  display: block;
}
.sim-input {
  background: var(--bg-dark);
  border: 1px solid var(--border);
  color: var(--text);
  border-radius: 8px;
  padding: .7rem 1rem;
  font-family: var(--mono); font-size: .9rem;
  width: 100%; transition: border-color .25s, box-shadow .25s;
}
.sim-input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(255,174,35,.1);
  background: var(--bg-dark); color: var(--text);
}
.form-range { accent-color: var(--primary); width: 100%; }
.shift-val {
  font-family: var(--mono); font-size: 1.5rem;
  font-weight: 700; color: var(--primary);
  min-width: 2ch; display: inline-block; text-align: center;
}

/* ── Caesar Wheel ─────────────────────────────────────── */
.cipher-wheel {
  display: flex; flex-wrap: nowrap;
  overflow-x: auto; gap: 0;
  padding-bottom: .5rem; margin-top: 1rem;
  scrollbar-width: thin; scrollbar-color: var(--primary) transparent;
}
.cipher-cell {
  min-width: 30px; text-align: center;
  border-right: 1px solid rgba(255,255,255,.06);
}
.cipher-cell:last-child { border-right: none; }
.cc-top {
  background: rgba(255,174,35,.1);
  color: var(--primary);
  font-family: var(--mono); font-size: .82rem; font-weight: 700;
  padding: .25rem .1rem;
  border-bottom: 1px solid var(--border);
}
.cc-bottom {
  background: rgba(0,229,255,.08);
  color: var(--cyan);
  font-family: var(--mono); font-size: .82rem;
  padding: .25rem .1rem;
}
.cc-top.hl  { background: var(--primary); color: #000; }
.cc-bottom.hl { background: var(--cyan); color: #000; }

/* ── DH Visual ────────────────────────────────────────── */
.dh-grid {
  display: grid;
  grid-template-columns: 1fr 60px 1fr;
  gap: 1rem; align-items: start;
  margin: 1.5rem 0;
}
.dh-party {
  background: var(--bg-glass);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.2rem; text-align: center;
}
.dh-party-name { font-size: 1.05rem; font-weight: 800; color: var(--primary); margin-bottom: .9rem; }
.key-row {
  display: flex; align-items: baseline; gap: .4rem;
  margin: .35rem 0;
  font-family: var(--mono); font-size: .8rem; text-align: left;
}
.key-row .k { color: var(--text-muted); }
.key-row .v { color: var(--primary); font-weight: 700; }
.key-row .vi{ color: var(--blue-light); font-weight: 700; }
.dh-mid {
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  padding-top: 2rem; gap: .5rem; color: var(--blue-light);
}
.shared-box {
  background: rgba(0,200,83,.08);
  border: 2px solid var(--green);
  border-radius: var(--radius);
  padding: 1rem; text-align: center; margin-top: 1.2rem;
}
.shared-box .lbl { color: var(--text-muted); font-size: .8rem; text-transform: uppercase; letter-spacing: 1px; }
.shared-box .val { font-family: var(--mono); font-size: 1.5rem; font-weight: 900; color: var(--green); }

/* ── RSA ──────────────────────────────────────────────── */
.rsa-step {
  background: var(--bg-glass);
  border-left: 3px solid var(--primary);
  border-radius: 0 var(--radius) var(--radius) 0;
  padding: 1rem 1.2rem; margin-bottom: 1rem;
  opacity: 0; transform: translateX(-15px);
  transition: all .4s ease;
}
.rsa-step.show { opacity: 1; transform: none; }
.rsa-step-label { font-size: .72rem; font-weight: 800; color: var(--primary); text-transform: uppercase; letter-spacing: 1px; }
.rsa-formula { font-family: var(--mono); font-size: .9rem; color: var(--cyan); margin: .3rem 0; }
.rsa-result  { font-family: var(--mono); font-size: .85rem; color: var(--text); }

/* ── Lattice Canvas ───────────────────────────────────── */
#latticeCanvas {
  width: 100%; max-width: 580px; height: 340px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: #020409;
  display: block; margin: 0 auto;
  cursor: crosshair;
}
.lattice-legend {
  display: flex; flex-wrap: wrap; gap: 1.2rem;
  margin-top: 1rem; justify-content: center;
}
.legend-item {
  display: flex; align-items: center; gap: .4rem;
  font-size: .8rem; color: var(--text-muted);
}
.legend-dot {
  width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0;
}

/* ── Timeline ─────────────────────────────────────────── */
.tl-wrap { position: relative; padding-left: 28px; }
.tl-wrap::before {
  content: ''; position: absolute;
  left: 12px; top: 0; bottom: 0; width: 2px;
  background: linear-gradient(to bottom, var(--primary), var(--blue-light));
}
.tl-item { position: relative; margin-bottom: 2.5rem; padding-left: 1.5rem; }
.tl-dot {
  position: absolute; left: -22px; top: 4px;
  width: 14px; height: 14px; border-radius: 50%;
  background: var(--primary);
  border: 2px solid var(--bg-dark);
  box-shadow: 0 0 12px var(--primary-glow);
}
.tl-year  { color: var(--primary); font-weight: 800; font-family: var(--mono); font-size: .82rem; letter-spacing: 1px; }
.tl-title { font-weight: 700; font-size: 1rem; margin-top: .15rem; }
.tl-body  { color: var(--text-muted); font-size: .88rem; margin-top: .3rem; line-height: 1.65; }

/* ── Footer ───────────────────────────────────────────── */
footer {
  background: #040811;
  border-top: 1px solid var(--border);
  padding: 3.5rem 0 1.5rem;
}
.footer-logo { height: 46px; filter: drop-shadow(0 0 12px rgba(255,174,35,.4)); margin-bottom: .8rem; }
.footer-desc { color: var(--text-muted); font-size: .85rem; line-height: 1.7; }
.footer-heading { font-size: .78rem; font-weight: 800; text-transform: uppercase; letter-spacing: 1.5px; color: var(--primary); margin-bottom: 1rem; }
.footer-link { display: block; color: var(--text-muted); font-size: .85rem; text-decoration: none; margin-bottom: .5rem; transition: color .2s; }
.footer-link:hover { color: var(--primary); }
.footer-hr { border-color: var(--border); margin: 2rem 0 1.2rem; }
.footer-copy { color: #3a3f55; font-size: .78rem; }

/* ── AES-256-GCM Banking Sim ─────────────────────────── */
.txn-card {
  background: linear-gradient(135deg, rgba(10,22,40,.92), rgba(18,40,80,.88));
  border: 1px solid rgba(100,181,246,.28);
  border-radius: var(--radius); padding: 1.4rem;
  position: relative; overflow: hidden;
}
.txn-card::after {
  content: '';
  position: absolute; top: -50%; left: -50%; width: 200%; height: 200%;
  background: radial-gradient(ellipse at 60% 30%, rgba(100,181,246,.04), transparent 55%);
  pointer-events: none;
}
.txn-row {
  display: flex; justify-content: space-between; align-items: center;
  padding: .3rem 0; border-bottom: 1px solid rgba(255,255,255,.05);
  font-size: .85rem; gap: .5rem;
}
.txn-row:last-child { border-bottom: none; }
.txn-lbl { color: var(--text-muted); font-size: .72rem; text-transform: uppercase; letter-spacing: .5px; white-space: nowrap; }
.txn-val { font-family: var(--mono); color: var(--text); font-size: .82rem; text-align: right; }
.txn-amount { font-size: 1.1rem; font-weight: 900; color: var(--primary); }

/* Process steps */
.aes-step {
  display: flex; gap: .9rem; align-items: flex-start;
  padding: .75rem 1rem;
  background: var(--bg-glass);
  border-left: 3px solid rgba(255,255,255,.1);
  border-radius: 0 var(--radius) var(--radius) 0;
  margin-bottom: .5rem;
  opacity: 0; transform: translateX(-12px);
  transition: all .4s ease;
}
.aes-step.show { opacity: 1; transform: none; }
.aes-step-num {
  width: 26px; height: 26px; flex-shrink: 0;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: .72rem; font-weight: 800;
}
.aes-step-title { font-weight: 700; font-size: .84rem; margin-bottom: .2rem; }
.aes-step-hex {
  font-family: var(--mono); font-size: .67rem;
  word-break: break-all; line-height: 1.75; margin-top: .25rem;
}
.aes-step-note { font-size: .71rem; color: var(--text-muted); margin-top: .2rem; }

/* Round pipeline */
.aes-pipeline { display: flex; gap: 2px; margin: .5rem 0; }
.aes-round {
  flex: 1; min-width: 0;
  padding: .45rem .05rem;
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 4px; text-align: center;
  font-family: var(--mono); font-size: .58rem;
  color: rgba(255,255,255,.25);
  transition: all .2s ease; line-height: 1.3;
}
.aes-round.active {
  border-color: var(--primary); color: var(--primary);
  background: rgba(255,174,35,.15);
  box-shadow: 0 0 8px rgba(255,174,35,.28);
  transform: scaleY(1.12);
}
.aes-round.done {
  border-color: rgba(0,200,83,.4); color: var(--green);
  background: rgba(0,200,83,.07);
}
.aes-round-lbl { font-size: .52rem; opacity: .7; display: block; }

/* Auth tag */
.auth-tag-box {
  background: rgba(0,229,255,.05);
  border: 1px solid rgba(0,229,255,.28);
  border-radius: var(--radius); padding: .8rem 1rem;
}
.auth-tag-lbl {
  font-size: .7rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: .8px; color: var(--cyan); margin-bottom: .3rem;
}
.auth-tag-val {
  font-family: var(--mono); font-size: .74rem;
  color: var(--cyan); word-break: break-all;
}

/* Cipher hex block */
.cipher-hex {
  background: #020409;
  border: 1px solid rgba(100,181,246,.15);
  border-radius: var(--radius); padding: .8rem 1rem;
  font-family: var(--mono); font-size: .7rem;
  color: rgba(100,181,246,.7);
  max-height: 70px; overflow-y: auto;
  word-break: break-all; line-height: 1.85;
}

/* Tag badges */
.tag-ok {
  display: inline-flex; align-items: center; gap: .35rem;
  background: rgba(0,200,83,.15); border: 1px solid var(--green);
  color: var(--green); font-size: .75rem; font-weight: 700;
  padding: .25rem .8rem; border-radius: 100px;
}
.tag-err {
  display: inline-flex; align-items: center; gap: .35rem;
  background: rgba(255,23,68,.15); border: 1px solid var(--danger);
  color: var(--danger); font-size: .75rem; font-weight: 700;
  padding: .25rem .8rem; border-radius: 100px;
}

/* ── Ransomware Sim ───────────────────────────────────── */
.i-red { background: rgba(255,23,68,.12); border-color: var(--danger); color: var(--danger); }

.drop-zone {
  border: 2px dashed rgba(255,174,35,.3);
  border-radius: var(--radius);
  padding: 2.2rem 1.5rem;
  text-align: center;
  cursor: pointer;
  transition: all .3s;
  background: var(--bg-glass);
  position: relative;
}
.drop-zone.drag-over  { border-color: var(--danger); background: rgba(255,23,68,.06); }
.drop-zone.has-file   { border-color: var(--green);  background: rgba(0,200,83,.05); border-style: solid; }
.drop-icon  { font-size: 2.4rem; color: var(--text-muted); margin-bottom: .7rem; }
.drop-label { font-size: .9rem;  color: var(--text-muted); }
.drop-sub   { font-size: .74rem; color: #444; margin-top: .3rem; }
.file-badge {
  background: rgba(0,200,83,.15); border: 1px solid var(--green);
  padding: .2rem .7rem; border-radius: 100px;
  font-size: .75rem; color: var(--green);
}

/* Attack animation */
.attack-progress-bar {
  height: 4px; border-radius: 2px; width: 0%;
  background: linear-gradient(90deg, var(--danger), #ff6b4a);
  box-shadow: 0 0 10px rgba(255,23,68,.5);
  transition: width .5s ease;
}
.attack-spinner {
  width: 18px; height: 18px; flex-shrink: 0;
  border: 2px solid rgba(255,23,68,.3);
  border-top-color: var(--danger);
  border-radius: 50%;
  animation: spin .7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* Hex dump */
.hex-dump {
  background: #020409;
  border: 1px solid rgba(255,23,68,.18);
  border-radius: var(--radius);
  padding: 1rem 1.2rem;
  font-family: var(--mono); font-size: .7rem;
  color: rgba(255,110,110,.75);
  height: 130px; overflow-y: auto;
  word-break: break-all; line-height: 1.85;
  white-space: pre-wrap;
}

/* Ransom note */
.ransom-note {
  background: linear-gradient(135deg, #1a0000, #2b0606);
  border: 2px solid var(--danger);
  border-radius: var(--radius);
  padding: 1.4rem;
  box-shadow: 0 0 40px rgba(255,23,68,.2);
  animation: pulse-red 2.2s ease-in-out infinite;
}
@keyframes pulse-red {
  0%,100% { box-shadow: 0 0 30px rgba(255,23,68,.18); }
  50%      { box-shadow: 0 0 55px rgba(255,23,68,.42); }
}
.ransom-skull  { font-size: 2.4rem; margin-bottom: .4rem; }
.ransom-title  {
  font-size: 1.05rem; font-weight: 900; color: var(--danger);
  text-transform: uppercase; letter-spacing: 1px; margin-bottom: .7rem;
}
.ransom-body   { font-size: .83rem; color: rgba(255,255,255,.8); line-height: 1.65; }
.ransom-amount {
  font-family: var(--mono); font-size: 1.3rem; font-weight: 900;
  color: #ff4444; text-align: center;
  margin: .8rem 0; padding: .5rem;
  background: rgba(255,0,0,.1); border-radius: 8px;
}
.ransom-timer  {
  font-family: var(--mono); font-size: 1rem;
  color: #ff5555; text-align: center; margin-top: .4rem;
}
.ransom-edu-badge {
  background: rgba(0,200,83,.15); border: 1px solid var(--green);
  border-radius: 8px; padding: .4rem .8rem;
  font-size: .72rem; color: var(--green);
  text-align: center; margin-top: .8rem;
}

/* Key display */
.key-intercepted {
  font-family: var(--mono); font-size: .68rem;
  color: rgba(255,100,100,.6); word-break: break-all;
  padding: .4rem .8rem;
  background: rgba(255,0,0,.04);
  border-radius: 6px; margin-top: .4rem;
}

/* Restored banner */
.restored-banner {
  background: rgba(0,200,83,.08);
  border: 2px solid var(--green);
  border-radius: var(--radius);
  padding: 1rem 1.3rem; margin-bottom: 1.2rem;
}
.restored-banner .r-title { font-weight: 800; color: var(--green); font-size: 1rem; }
.restored-banner .r-body  { font-size: .83rem; color: var(--text-muted); margin-top: .3rem; }

/* Extra buttons */
.btn-danger-red {
  background: var(--danger); color: #fff !important;
  font-weight: 700; font-size: .88rem;
  padding: .75rem 2rem; border-radius: 100px;
  border: none; letter-spacing: .4px;
  transition: all .3s ease;
  box-shadow: 0 4px 20px rgba(255,23,68,.38);
}
.btn-danger-red:hover {
  background: #ff3d5c; transform: translateY(-3px);
  box-shadow: 0 8px 30px rgba(255,23,68,.55);
}
.btn-success-green {
  background: var(--green); color: #000 !important;
  font-weight: 700; font-size: .88rem;
  padding: .75rem 2rem; border-radius: 100px;
  border: none; letter-spacing: .4px;
  transition: all .3s ease;
}
.btn-success-green:hover {
  background: #00e676; transform: translateY(-3px);
  box-shadow: 0 6px 24px rgba(0,200,83,.4);
}

/* ── Responsive ───────────────────────────────────────── */
@media (max-width: 768px) {
  section { padding: 70px 0; }
  .dh-grid { grid-template-columns: 1fr; }
  .dh-mid { flex-direction: row; padding-top: 0; }
  .hero-title { font-size: 2rem; }
  #latticeCanvas { height: 240px; }
  .sim-body { padding: 1.2rem; }
}
