/* ============================================
   VARIABLES & RESET
   ============================================ */
:root {
  --bg: #0a0e27;
  --bg-light: #111738;
  --bg-card: #161d45;
  --bg-card-hover: #1c2555;
  --text: #e8eaf6;
  --text-muted: #9fa8da;
  --text-dim: #5c6bc0;
  --accent: #5c6bc0;
  --accent-bright: #7c8cf0;
  --accent-glow: rgba(92, 107, 192, 0.3);
  --green: #66bb6a;
  --green-bg: rgba(102, 187, 106, 0.1);
  --red: #ef5350;
  --red-bg: rgba(239, 83, 80, 0.1);
  --yellow: #fdd835;
  --yellow-bg: rgba(253, 216, 53, 0.1);
  --blue: #42a5f5;
  --blue-bg: rgba(66, 165, 245, 0.1);
  --orange: #ffa726;
  --orange-bg: rgba(255, 167, 38, 0.1);
  --purple: #ab47bc;
  --purple-bg: rgba(171, 71, 188, 0.1);
  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 4px 24px rgba(0, 0, 0, 0.4);
  --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --font: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --mono: 'JetBrains Mono', 'Fira Code', monospace;
}

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

html { font-size: 16px; scroll-behavior: smooth; }

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  overflow: hidden;
  height: 100vh;
  width: 100vw;
  -webkit-font-smoothing: antialiased;
}

/* ============================================
   PROGRESS BAR
   ============================================ */
.progress-bar {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--accent), var(--accent-bright), var(--purple));
  z-index: 1000;
  transition: width 0.4s ease;
  border-radius: 0 2px 2px 0;
  box-shadow: 0 0 10px var(--accent-glow);
}

/* ============================================
   NAVIGATION
   ============================================ */
.nav-controls {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(22, 29, 69, 0.9);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(92, 107, 192, 0.2);
  padding: 8px 16px;
  border-radius: 50px;
  z-index: 100;
  box-shadow: var(--shadow);
}

.nav-btn {
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 8px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.nav-btn:hover {
  color: var(--text);
  background: rgba(92, 107, 192, 0.2);
}

.slide-counter {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-weight: 500;
  min-width: 60px;
  text-align: center;
  font-variant-numeric: tabular-nums;
}

/* ============================================
   SIDE MENU
   ============================================ */
.side-menu {
  position: fixed;
  top: 0;
  right: -360px;
  width: 360px;
  height: 100vh;
  background: rgba(16, 21, 50, 0.98);
  backdrop-filter: blur(20px);
  border-left: 1px solid rgba(92, 107, 192, 0.15);
  z-index: 200;
  transition: right 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  overflow-y: auto;
  box-shadow: -8px 0 32px rgba(0, 0, 0, 0.5);
}

.side-menu.open { right: 0; }

.menu-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 24px;
  border-bottom: 1px solid rgba(92, 107, 192, 0.1);
}

.menu-header h3 {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text);
}

.menu-close {
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 1.5rem;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: var(--radius-sm);
  transition: var(--transition);
}

.menu-close:hover { color: var(--text); background: rgba(92, 107, 192, 0.15); }

.menu-list {
  list-style: none;
  padding: 12px;
}

.menu-list li {
  padding: 10px 16px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: var(--transition);
  font-size: 0.9rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 12px;
}

.menu-list li:hover {
  background: rgba(92, 107, 192, 0.1);
  color: var(--text);
}

.menu-list li.active {
  background: rgba(92, 107, 192, 0.15);
  color: var(--accent-bright);
  font-weight: 500;
}

.menu-list li .menu-num {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-dim);
  min-width: 24px;
}

.menu-list li.separator {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-dim);
  padding-top: 16px;
  cursor: default;
}

.menu-list li.separator:hover { background: transparent; color: var(--text-dim); }

.menu-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: 199;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.menu-overlay.visible { opacity: 1; pointer-events: all; }

/* ============================================
   SLIDES CONTAINER
   ============================================ */
.slides-container {
  width: 100vw;
  height: 100vh;
  position: relative;
}

.slide {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transform: translateX(60px);
  pointer-events: none;
  transition: opacity 0.5s ease, transform 0.5s ease;
  padding: 40px 60px 100px;
}

.slide.active {
  opacity: 1;
  transform: translateX(0);
  pointer-events: all;
}

.slide.exit-left {
  opacity: 0;
  transform: translateX(-60px);
}

.slide-inner {
  max-width: 1200px;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  position: relative;
}

/* ============================================
   COVER SLIDE
   ============================================ */
.slide-cover {
  padding: 0;
}

.cover-bg {
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 30% 50%, rgba(92, 107, 192, 0.15) 0%, transparent 60%),
              radial-gradient(ellipse at 70% 80%, rgba(171, 71, 188, 0.1) 0%, transparent 50%);
  overflow: hidden;
}

.cover-particles {
  position: absolute;
  inset: 0;
}

.cover-content {
  position: relative;
  z-index: 1;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
  padding: 40px;
}

.cover-university { margin-bottom: 30px; }

.uni-logo {
  height: 100px;
  width: auto;
  margin-bottom: 10px;
  filter: drop-shadow(0 2px 12px rgba(92, 107, 192, 0.3));
}

.uni-badge {
  display: inline-block;
  background: linear-gradient(135deg, var(--accent), var(--purple));
  color: white;
  font-weight: 800;
  font-size: 1.1rem;
  padding: 8px 24px;
  border-radius: 50px;
  letter-spacing: 2px;
  margin-bottom: 8px;
}

.cover-university p {
  color: var(--text-muted);
  font-size: 0.95rem;
}

.cover-title {
  margin-bottom: 32px;
}

.title-accent {
  display: block;
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 900;
  background: linear-gradient(135deg, var(--accent-bright), var(--purple), var(--blue));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1.1;
  margin-bottom: 12px;
}

.title-sub {
  display: block;
  font-size: clamp(1rem, 2vw, 1.5rem);
  font-weight: 400;
  color: var(--text-muted);
}

.cover-subject {
  font-size: 1rem;
  color: var(--accent-bright);
  font-weight: 500;
  margin-bottom: 24px;
}

.cover-team {
  display: flex;
  gap: 20px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 20px;
}

.team-member {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.95rem;
  color: var(--text);
}

.team-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
}

.cover-prof {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 4px;
}

.cover-date {
  font-size: 0.85rem;
  color: var(--text-dim);
}

.cover-arrow {
  position: absolute;
  bottom: 40px;
  cursor: pointer;
  color: var(--text-dim);
  animation: bounce 2s infinite;
  transition: var(--transition);
}

.cover-arrow:hover { color: var(--accent-bright); }

@keyframes bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(8px); }
}

/* ============================================
   COMMON SLIDE ELEMENTS
   ============================================ */
.section-label {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--accent);
  font-weight: 600;
  margin-bottom: 8px;
}

.slide-title {
  font-size: clamp(1.5rem, 3vw, 2.2rem);
  font-weight: 800;
  margin-bottom: 28px;
  line-height: 1.2;
  background: linear-gradient(135deg, var(--text), var(--accent-bright));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.subtitle {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--accent-bright);
  margin-bottom: 12px;
}

.speaker-badge {
  position: absolute;
  top: 12px;
  right: 0;
  background: rgba(92, 107, 192, 0.15);
  border: 1px solid rgba(92, 107, 192, 0.25);
  color: var(--accent-bright);
  font-size: 0.8rem;
  font-weight: 500;
  padding: 6px 16px;
  border-radius: 50px;
}

/* ============================================
   TWO COLUMN LAYOUT
   ============================================ */
.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: start;
  flex: 1;
}

.col-text, .col-visual {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* ============================================
   REVEAL ANIMATIONS
   ============================================ */
.reveal-item {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.reveal-item.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ============================================
   BOXES & CARDS
   ============================================ */
.highlight-box {
  background: var(--blue-bg);
  border-left: 4px solid var(--blue);
  padding: 16px 20px;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-size: 0.95rem;
  line-height: 1.6;
}

.callout-box {
  background: var(--green-bg);
  border-left: 4px solid var(--green);
  padding: 16px 20px;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-size: 0.9rem;
  line-height: 1.6;
}

.problem-box {
  background: var(--red-bg);
  border-left: 4px solid var(--red);
  padding: 16px 20px;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

.problem-box h4 { color: var(--red); margin-bottom: 6px; }

.solution-box {
  background: var(--green-bg);
  border-left: 4px solid var(--green);
  padding: 16px 20px;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

.solution-box h4 { color: var(--green); margin-bottom: 6px; }

.quote-box {
  background: rgba(171, 71, 188, 0.1);
  border-left: 4px solid var(--purple);
  padding: 20px 24px;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-style: italic;
  font-size: 1rem;
  line-height: 1.6;
  color: var(--text);
  margin-top: 8px;
}

.fun-fact {
  background: var(--yellow-bg);
  border: 1px solid rgba(253, 216, 53, 0.2);
  padding: 14px 18px;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  line-height: 1.5;
  margin-top: 12px;
}

/* ============================================
   STYLED LIST
   ============================================ */
.styled-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.styled-list.compact { gap: 8px; }

.styled-list li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 0.92rem;
  line-height: 1.5;
  color: var(--text);
}

.styled-list li::before {
  content: '';
  width: 6px;
  height: 6px;
  min-width: 6px;
  border-radius: 50%;
  background: var(--accent);
  margin-top: 8px;
}

.styled-list li .list-icon {
  font-size: 1.1rem;
  min-width: 24px;
}

.styled-list li .list-icon + * { margin-left: 0; }
.styled-list li:has(.list-icon)::before { display: none; }

/* ============================================
   AGENDA
   ============================================ */
.agenda-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  flex: 1;
  align-content: center;
}

.agenda-card {
  background: var(--bg-card);
  border: 1px solid rgba(92, 107, 192, 0.1);
  border-radius: var(--radius);
  padding: 20px;
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  gap: 16px;
  align-items: flex-start;
}

.agenda-card:hover {
  background: var(--bg-card-hover);
  border-color: rgba(92, 107, 192, 0.3);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}

.agenda-num {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--accent);
  line-height: 1;
  min-width: 40px;
}

.agenda-info h4 {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 4px;
}

.agenda-info p {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.agenda-speaker {
  font-size: 0.75rem;
  color: var(--accent-bright);
  background: rgba(92, 107, 192, 0.1);
  padding: 3px 10px;
  border-radius: 50px;
}

/* ============================================
   INFO CARDS
   ============================================ */
.cards-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  flex: 1;
  align-content: center;
}

.cards-row.two-cards { grid-template-columns: repeat(2, 1fr); }

.info-card {
  background: var(--bg-card);
  border: 1px solid rgba(92, 107, 192, 0.1);
  border-radius: var(--radius);
  padding: 24px;
  transition: var(--transition);
}

.info-card:hover {
  border-color: rgba(92, 107, 192, 0.25);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
}

.info-card .card-icon {
  font-size: 2rem;
  margin-bottom: 12px;
  display: block;
}

.info-card h4 {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 8px;
}

.info-card p {
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.6;
}

.info-card.large p { margin-bottom: 8px; }

.inner-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.inner-list li {
  font-size: 0.85rem;
  color: var(--text-muted);
  line-height: 1.5;
  padding-left: 16px;
  position: relative;
}

.inner-list li::before {
  content: '›';
  position: absolute;
  left: 0;
  color: var(--accent);
  font-weight: bold;
}

/* ============================================
   APPLICATION HUB (Intro slide)
   ============================================ */
.app-hub {
  position: relative;
  width: 100%;
  height: 380px;
}

.hub-center {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 120px;
  height: 120px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), var(--purple));
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  font-size: 0.85rem;
  font-weight: 700;
  color: white;
  box-shadow: 0 0 40px var(--accent-glow);
  z-index: 2;
}

.hub-item {
  position: absolute;
  background: var(--bg-card);
  border: 1px solid rgba(92, 107, 192, 0.2);
  padding: 10px 16px;
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  text-align: center;
  font-weight: 600;
  color: var(--text);
  transition: var(--transition);
}

.hub-item small { display: block; font-weight: 400; color: var(--text-muted); font-size: 0.72rem; }
.hub-item:hover { border-color: var(--accent); box-shadow: 0 0 16px var(--accent-glow); }

.hub-1 { top: 10%; left: 5%; }
.hub-2 { top: 10%; right: 5%; }
.hub-3 { bottom: 10%; right: 5%; }
.hub-4 { bottom: 10%; left: 5%; }
.hub-5 { bottom: 42%; left: 50%; transform: translateX(-50%) translateY(130px); }

/* ============================================
   CODE BLOCK
   ============================================ */
.code-block {
  background: #1a1e36;
  border: 1px solid rgba(92, 107, 192, 0.15);
  border-radius: var(--radius);
  overflow: hidden;
}

.code-header {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 10px 16px;
  background: rgba(0, 0, 0, 0.2);
}

.code-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

.code-dot.red { background: #ef5350; }
.code-dot.yellow { background: #fdd835; }
.code-dot.green { background: #66bb6a; }
.code-lang {
  margin-left: auto;
  font-size: 0.75rem;
  color: var(--text-dim);
  font-weight: 500;
}

.code-block pre {
  padding: 16px;
  overflow-x: auto;
}

.code-block code {
  font-family: var(--mono);
  font-size: 0.85rem;
  line-height: 1.7;
  color: var(--text);
}

.code-comment { color: var(--text-dim); }
.code-keyword { color: var(--purple); }

code.formula {
  background: rgba(92, 107, 192, 0.15);
  padding: 2px 8px;
  border-radius: 4px;
  font-family: var(--mono);
  font-size: 0.9em;
}

.examples code {
  background: rgba(92, 107, 192, 0.1);
  padding: 2px 6px;
  border-radius: 4px;
  font-family: var(--mono);
  font-size: 0.88em;
}

/* ============================================
   FORMULA HERO
   ============================================ */
.formula-hero {
  text-align: center;
  padding: 28px;
  background: var(--bg-card);
  border: 1px solid rgba(92, 107, 192, 0.2);
  border-radius: var(--radius);
  margin-bottom: 20px;
}

.formula-hero.small { padding: 18px; margin-bottom: 16px; }

.formula-big {
  font-family: var(--mono);
  font-size: 2rem;
  font-weight: 700;
  color: var(--accent-bright);
  margin-bottom: 8px;
}

.formula-hero.small .formula-big { font-size: 1.5rem; }

.formula-equiv {
  font-size: 0.9rem;
  color: var(--text-muted);
}

/* ============================================
   CYCLE GRID (Powers of i)
   ============================================ */
.cycle-grid {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}

.cycle-card {
  padding: 18px 24px;
  border-radius: var(--radius);
  text-align: center;
  min-width: 130px;
}

.cycle-1 { background: var(--blue-bg); border: 1px solid rgba(66, 165, 245, 0.3); }
.cycle-2 { background: var(--red-bg); border: 1px solid rgba(239, 83, 80, 0.3); }
.cycle-3 { background: var(--purple-bg); border: 1px solid rgba(171, 71, 188, 0.3); }
.cycle-4 { background: var(--green-bg); border: 1px solid rgba(102, 187, 106, 0.3); }

.cycle-power {
  font-family: var(--mono);
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 4px;
}

.cycle-angle {
  font-size: 0.78rem;
  color: var(--text-muted);
}

.cycle-arrow {
  font-size: 1.5rem;
  color: var(--text-dim);
}

/* ============================================
   OPERATIONS GRID
   ============================================ */
.ops-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  flex: 1;
  align-content: center;
}

.op-big-card {
  padding: 20px;
  border-radius: var(--radius);
  border: 1px solid;
}

.op-big-card h4 { font-size: 1rem; margin-bottom: 8px; }

.op-big-card.sum { background: var(--blue-bg); border-color: rgba(66, 165, 245, 0.2); }
.op-big-card.sum h4 { color: var(--blue); }
.op-big-card.sub { background: var(--red-bg); border-color: rgba(239, 83, 80, 0.2); }
.op-big-card.sub h4 { color: var(--red); }
.op-big-card.mul { background: var(--green-bg); border-color: rgba(102, 187, 106, 0.2); }
.op-big-card.mul h4 { color: var(--green); }
.op-big-card.div { background: var(--orange-bg); border-color: rgba(255, 167, 38, 0.2); }
.op-big-card.div h4 { color: var(--orange); }

.op-formula {
  font-family: var(--mono);
  font-size: 0.9rem;
  color: var(--text);
  margin-bottom: 8px;
}

.op-example {
  font-size: 0.82rem;
  color: var(--text-muted);
}

.op-example small { color: var(--text-dim); }

/* Operations mini cards */
.ops-cards { display: flex; flex-direction: column; gap: 10px; }

.op-card {
  background: var(--bg-card);
  border: 1px solid rgba(92, 107, 192, 0.1);
  padding: 12px 16px;
  border-radius: var(--radius-sm);
}

.op-card h5 { font-size: 0.85rem; color: var(--accent-bright); margin-bottom: 4px; }
.op-card code { font-family: var(--mono); font-size: 0.9rem; color: var(--text); display: block; margin-bottom: 4px; }
.op-card p { font-size: 0.8rem; color: var(--text-muted); }

/* Forms list */
.forms-list { display: flex; flex-direction: column; gap: 8px; margin-top: 8px; }

.form-item {
  font-size: 0.88rem;
  color: var(--text);
  padding: 6px 0;
}

.form-item code {
  font-family: var(--mono);
  background: rgba(92, 107, 192, 0.1);
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 0.85em;
}

/* ============================================
   TRANSITION SLIDES
   ============================================ */
.slide-transition {
  background: radial-gradient(ellipse at center, rgba(92, 107, 192, 0.1) 0%, transparent 70%);
}

.transition-content {
  text-align: center;
}

.transition-number {
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 3px;
  color: var(--accent);
  font-weight: 600;
  margin-bottom: 16px;
}

.transition-title {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 900;
  background: linear-gradient(135deg, var(--text), var(--accent-bright));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 16px;
  line-height: 1.2;
}

.transition-sub {
  font-size: 1.1rem;
  color: var(--text-muted);
  max-width: 600px;
  margin: 0 auto;
}

.transition-speaker {
  margin-top: 32px;
  font-size: 0.9rem;
  color: var(--accent-bright);
  font-weight: 500;
}

/* ============================================
   FFT DIAGRAM
   ============================================ */
.fft-diagram {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.fft-box {
  background: var(--bg-card);
  border: 1px solid rgba(92, 107, 192, 0.15);
  border-radius: var(--radius);
  padding: 16px;
  text-align: center;
  width: 100%;
}

.fft-label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--accent-bright);
  margin-bottom: 8px;
}

.wave-svg {
  width: 100%;
  height: 60px;
  margin-bottom: 4px;
}

.fft-box small { font-size: 0.75rem; color: var(--text-dim); }

.fft-arrow-container { display: flex; align-items: center; justify-content: center; }

.fft-process {
  background: linear-gradient(135deg, var(--accent), var(--purple));
  color: white;
  padding: 12px 24px;
  border-radius: var(--radius-sm);
  font-weight: 700;
  font-size: 0.9rem;
  text-align: center;
  box-shadow: 0 4px 16px var(--accent-glow);
}

.fft-process small { display: block; font-weight: 400; font-size: 0.75rem; opacity: 0.9; }

.freq-bars {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: 8px;
  height: 60px;
  margin-bottom: 4px;
}

.freq-bar {
  width: 20px;
  background: linear-gradient(to top, var(--green), var(--blue));
  border-radius: 3px 3px 0 0;
  animation: barPulse 2s ease-in-out infinite alternate;
}

.freq-bar:nth-child(2) { animation-delay: 0.3s; }
.freq-bar:nth-child(3) { animation-delay: 0.6s; }
.freq-bar:nth-child(4) { animation-delay: 0.9s; }
.freq-bar:nth-child(5) { animation-delay: 1.2s; }
.freq-bar:nth-child(6) { animation-delay: 1.5s; }

@keyframes barPulse {
  0% { opacity: 0.7; }
  100% { opacity: 1; }
}

/* ============================================
   COMPLEX PLANE
   ============================================ */
.complex-plane {
  background: var(--bg-card);
  border: 1px solid rgba(92, 107, 192, 0.15);
  border-radius: var(--radius);
  padding: 16px;
  text-align: center;
}

.plane-title {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--accent-bright);
  margin-bottom: 8px;
}

.plane-caption {
  font-size: 0.78rem;
  color: var(--text-dim);
  margin-top: 8px;
}

/* ============================================
   MANDELBROT
   ============================================ */
.mandelbrot-container {
  background: var(--bg-card);
  border: 1px solid rgba(92, 107, 192, 0.15);
  border-radius: var(--radius);
  padding: 16px;
  text-align: center;
}

#mandelbrotCanvas {
  border-radius: var(--radius-sm);
  width: 100%;
  height: auto;
}

/* ============================================
   STEPS LIST
   ============================================ */
.steps-list { display: flex; flex-direction: column; gap: 12px; }

.step-item {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  font-size: 0.9rem;
  line-height: 1.5;
}

.step-num {
  background: var(--accent);
  color: white;
  min-width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.8rem;
}

.step-item.warning .step-num { background: var(--orange); }

/* ============================================
   CRYPTO FLOW
   ============================================ */
.crypto-flow {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.crypto-box {
  background: var(--bg-card);
  border: 1px solid rgba(92, 107, 192, 0.15);
  border-radius: var(--radius);
  padding: 24px;
  width: 100%;
  text-align: center;
}

.crypto-box h4 { margin-bottom: 8px; font-size: 1.1rem; }
.crypto-box p { font-size: 0.88rem; color: var(--text-muted); }

.crypto-current { border-color: rgba(66, 165, 245, 0.3); }
.crypto-future { border-color: rgba(102, 187, 106, 0.3); }

.crypto-arrow {
  font-size: 1rem;
  font-weight: 700;
  color: var(--orange);
  padding: 8px 20px;
  background: var(--orange-bg);
  border-radius: 50px;
}

/* ============================================
   COMPARE CARDS
   ============================================ */
.compare-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }

.compare-card {
  background: var(--bg-card);
  border: 1px solid rgba(92, 107, 192, 0.15);
  border-radius: var(--radius);
  padding: 16px;
}

.compare-card.accent { border-color: rgba(171, 71, 188, 0.3); }

.compare-card h5 {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--accent-bright);
  margin-bottom: 10px;
}

.compare-card.accent h5 { color: var(--purple); }

.compare-card ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 10px;
}

.compare-card ul li {
  font-size: 0.82rem;
  color: var(--text-muted);
  padding-left: 12px;
  position: relative;
}

.compare-card ul li::before {
  content: '›';
  position: absolute;
  left: 0;
  color: var(--accent);
  font-weight: bold;
}

.compare-used {
  font-size: 0.78rem;
  color: var(--text-dim);
  border-top: 1px solid rgba(92, 107, 192, 0.1);
  padding-top: 8px;
  margin-top: 4px;
}

/* ============================================
   FLOW SIMPLE
   ============================================ */
.flow-simple {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
  padding: 16px;
  background: var(--bg-card);
  border: 1px solid rgba(92, 107, 192, 0.1);
  border-radius: var(--radius);
  margin-top: 8px;
}

.flow-step {
  background: rgba(92, 107, 192, 0.1);
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  font-weight: 500;
  text-align: center;
}

.flow-step.accent {
  background: linear-gradient(135deg, var(--accent), var(--purple));
  color: white;
  font-weight: 600;
}

.flow-step small { display: block; font-size: 0.72rem; font-weight: 400; opacity: 0.8; }

.flow-arrow { color: var(--text-dim); font-size: 1.2rem; }

/* ============================================
   TELECOM FLOW
   ============================================ */
.telecom-flow {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 24px;
  background: var(--bg-card);
  border: 1px solid rgba(92, 107, 192, 0.1);
  border-radius: var(--radius);
  flex-wrap: wrap;
  margin-bottom: 16px;
}

.telecom-step {
  text-align: center;
  padding: 16px;
  background: rgba(92, 107, 192, 0.08);
  border-radius: var(--radius-sm);
  min-width: 140px;
}

.telecom-step.accent { background: linear-gradient(135deg, rgba(92, 107, 192, 0.2), rgba(171, 71, 188, 0.15)); }

.telecom-icon { font-size: 1.8rem; margin-bottom: 6px; }

.telecom-step h5 { font-size: 0.85rem; font-weight: 600; color: var(--text); margin-bottom: 2px; }
.telecom-step small { font-size: 0.75rem; color: var(--text-muted); }

.telecom-arrow { color: var(--text-dim); font-size: 1.3rem; }

.tech-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
}

.tech-tag {
  background: rgba(92, 107, 192, 0.1);
  border: 1px solid rgba(92, 107, 192, 0.15);
  color: var(--text-muted);
  padding: 6px 14px;
  border-radius: 50px;
  font-size: 0.8rem;
  font-weight: 500;
  transition: var(--transition);
}

.tech-tag:hover {
  background: rgba(92, 107, 192, 0.2);
  color: var(--accent-bright);
}

/* ============================================
   CONTROL DIAGRAM
   ============================================ */
.control-diagram {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 24px;
}

.ctrl-box {
  padding: 14px 20px;
  border-radius: var(--radius-sm);
  text-align: center;
  font-size: 0.85rem;
  font-weight: 600;
  width: 180px;
}

.ctrl-box small { display: block; font-weight: 400; font-size: 0.75rem; color: var(--text-muted); }

.ctrl-input { background: var(--green-bg); border: 1px solid rgba(102, 187, 106, 0.3); }
.ctrl-pid { background: var(--orange-bg); border: 1px solid rgba(255, 167, 38, 0.3); }
.ctrl-system { background: var(--blue-bg); border: 1px solid rgba(66, 165, 245, 0.3); }
.ctrl-output { background: var(--purple-bg); border: 1px solid rgba(171, 71, 188, 0.3); }

.ctrl-arrow { color: var(--text-dim); font-size: 1.2rem; }

.ctrl-feedback {
  font-size: 0.78rem;
  color: var(--red);
  margin-top: 8px;
  padding: 8px;
  border: 1px dashed rgba(239, 83, 80, 0.3);
  border-radius: var(--radius-sm);
  width: 100%;
  text-align: center;
}

/* ============================================
   ROTATION DEMO
   ============================================ */
.rotation-demo {
  background: var(--bg-card);
  border: 1px solid rgba(92, 107, 192, 0.15);
  border-radius: var(--radius);
  padding: 16px;
  text-align: center;
}

#rotationCanvas {
  width: 100%;
  height: auto;
  border-radius: var(--radius-sm);
}

/* ============================================
   CANVAS DEMO (reusable for all animated canvases)
   ============================================ */
.canvas-demo {
  background: var(--bg-card);
  border: 1px solid rgba(92, 107, 192, 0.15);
  border-radius: var(--radius);
  padding: 16px;
  text-align: center;
}

.canvas-demo canvas {
  width: 100%;
  height: auto;
  border-radius: var(--radius-sm);
}

.canvas-demo-wide {
  margin-top: 12px;
}

.canvas-demo-wide canvas {
  max-height: 280px;
}

/* ============================================
   MANDELBROT BUILD SLIDE
   ============================================ */
.mandelbrot-build-layout {
  display: flex;
  gap: 24px;
  align-items: flex-start;
}

.mandelbrot-build-center {
  flex: 1;
  text-align: center;
}

.mandelbrot-build-center canvas {
  width: 100%;
  height: auto;
  border-radius: var(--radius);
  border: 1px solid rgba(92, 107, 192, 0.2);
}

.mandelbrot-build-info {
  display: flex;
  justify-content: space-between;
  margin-top: 8px;
  font-size: 0.8rem;
  color: var(--accent);
  font-family: 'JetBrains Mono', monospace;
}

.mandelbrot-build-legend {
  width: 260px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.build-step-card {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  background: var(--bg-card);
  border: 1px solid rgba(92, 107, 192, 0.12);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
}

.build-step-num {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--accent);
  color: white;
  font-weight: 700;
  font-size: 0.8rem;
}

.build-step-card p {
  font-size: 0.82rem;
  line-height: 1.4;
  color: var(--text-dim);
}

@media (max-width: 1024px) {
  .mandelbrot-build-layout {
    flex-direction: column;
  }
  .mandelbrot-build-legend {
    width: 100%;
    flex-direction: row;
    flex-wrap: wrap;
  }
  .build-step-card {
    flex: 1 1 45%;
  }
}

/* ============================================
   FRACTAL TREE
   ============================================ */
.fractal-tree-layout {
  display: flex;
  gap: 20px;
  align-items: flex-start;
}

.fractal-tree-canvas-wrap {
  flex: 1;
  text-align: center;
}

.fractal-tree-canvas-wrap canvas {
  width: 100%;
  height: auto;
  border-radius: var(--radius);
  border: 1px solid rgba(92, 107, 192, 0.2);
  background: #0a0e27;
}

.fractal-tree-info {
  display: flex;
  justify-content: space-between;
  margin-top: 6px;
  font-size: 0.75rem;
  color: var(--text-dim);
  font-family: 'JetBrains Mono', monospace;
}

.fractal-tree-controls {
  width: 230px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.tree-params-label {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: var(--text-dim);
  text-transform: uppercase;
  margin-top: 4px;
}

.tree-control-card {
  background: var(--bg-card);
  border: 1px solid rgba(92, 107, 192, 0.1);
  border-radius: var(--radius-sm);
  padding: 8px 12px;
}

.tree-slider-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
}

.tree-slider-header span:first-child {
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--text-muted);
}

.tree-slider-header span:last-child {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--accent-bright);
  font-family: 'JetBrains Mono', monospace;
}

.tree-control-card input[type="range"] {
  width: 100%;
  height: 5px;
  -webkit-appearance: none;
  appearance: none;
  background: rgba(92, 107, 192, 0.2);
  border-radius: 3px;
  outline: none;
  cursor: pointer;
}

.tree-control-card input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #66bb6a;
  border: 2px solid #0a0e27;
  cursor: pointer;
  box-shadow: 0 0 6px rgba(102, 187, 106, 0.5);
  transition: transform 0.15s;
}

.tree-control-card input[type="range"]::-webkit-slider-thumb:hover {
  transform: scale(1.25);
}

.tree-control-card input[type="range"]::-moz-range-thumb {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #66bb6a;
  border: 2px solid #0a0e27;
  cursor: pointer;
  box-shadow: 0 0 6px rgba(102, 187, 106, 0.5);
}

.tree-color-row {
  display: flex;
  gap: 6px;
  padding: 4px 0;
}

.tree-color-btn {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 2px solid transparent;
  background: none;
  cursor: pointer;
  padding: 2px;
  transition: border-color 0.2s, transform 0.15s;
}

.tree-color-btn span {
  display: block;
  width: 100%;
  height: 100%;
  border-radius: 50%;
}

.tree-color-btn:hover {
  transform: scale(1.15);
}

.tree-color-btn.active {
  border-color: #66bb6a;
  box-shadow: 0 0 8px rgba(102, 187, 106, 0.4);
}

.tree-toggle-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.78rem;
  color: var(--text-muted);
  font-weight: 500;
}

.tree-switch {
  position: relative;
  display: inline-block;
  width: 40px;
  height: 22px;
}

.tree-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.tree-switch-slider {
  position: absolute;
  cursor: pointer;
  inset: 0;
  background: rgba(92, 107, 192, 0.25);
  border-radius: 22px;
  transition: 0.25s;
}

.tree-switch-slider::before {
  content: '';
  position: absolute;
  height: 16px;
  width: 16px;
  left: 3px;
  bottom: 3px;
  background: #9fa8da;
  border-radius: 50%;
  transition: 0.25s;
}

.tree-switch input:checked + .tree-switch-slider {
  background: rgba(102, 187, 106, 0.4);
}

.tree-switch input:checked + .tree-switch-slider::before {
  transform: translateX(18px);
  background: #66bb6a;
  box-shadow: 0 0 6px rgba(102, 187, 106, 0.5);
}

.tree-formula-card {
  background: var(--bg-card);
  border-left: 3px solid rgba(102, 187, 106, 0.4);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
}

.tree-formula-card p {
  font-size: 0.75rem;
  color: var(--text-dim);
  line-height: 1.5;
  margin: 0;
}

@media (max-width: 1024px) {
  .fractal-tree-layout { flex-direction: column-reverse; }
  .fractal-tree-controls { width: 100%; flex-direction: row; flex-wrap: wrap; gap: 6px; }
  .tree-control-card { flex: 1 1 45%; }
  .tree-formula-card { flex: 1 1 100%; }
  .tree-color-row { flex: 1 1 100%; }
}

/* ============================================
   TABLE
   ============================================ */
.table-wrapper {
  overflow-x: auto;
}

.styled-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--bg-card);
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid rgba(92, 107, 192, 0.15);
}

.styled-table thead {
  background: linear-gradient(135deg, rgba(92, 107, 192, 0.2), rgba(171, 71, 188, 0.1));
}

.styled-table th {
  padding: 14px 20px;
  text-align: left;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--accent-bright);
  border-bottom: 1px solid rgba(92, 107, 192, 0.15);
}

.styled-table td {
  padding: 12px 20px;
  font-size: 0.88rem;
  color: var(--text-muted);
  border-bottom: 1px solid rgba(92, 107, 192, 0.06);
}

.styled-table tbody tr:hover { background: rgba(92, 107, 192, 0.05); }
.styled-table tbody tr:last-child td { border-bottom: none; }

/* ============================================
   CONCLUSIONS
   ============================================ */
.conclusions-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin-bottom: 16px;
}

.conclusion-card {
  background: var(--bg-card);
  border: 1px solid rgba(92, 107, 192, 0.1);
  border-radius: var(--radius);
  padding: 18px;
  display: flex;
  gap: 14px;
  align-items: flex-start;
  transition: var(--transition);
}

.conclusion-card:hover {
  border-color: rgba(92, 107, 192, 0.25);
}

.conc-num {
  background: linear-gradient(135deg, var(--accent), var(--purple));
  color: white;
  min-width: 30px;
  height: 30px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.85rem;
}

.conclusion-card p { font-size: 0.85rem; color: var(--text-muted); line-height: 1.5; }

/* ============================================
   END SLIDE
   ============================================ */
.slide-end {
  background: radial-gradient(ellipse at center, rgba(92, 107, 192, 0.12) 0%, transparent 60%);
}

.end-content {
  text-align: center;
}

.end-icon {
  font-size: 4rem;
  margin-bottom: 16px;
}

.end-title {
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 900;
  background: linear-gradient(135deg, var(--accent-bright), var(--purple));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 12px;
}

.end-sub {
  font-size: 1.2rem;
  color: var(--text-muted);
  margin-bottom: 32px;
}

.end-team {
  display: flex;
  gap: 20px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 24px;
}

.end-member {
  background: rgba(92, 107, 192, 0.1);
  border: 1px solid rgba(92, 107, 192, 0.2);
  padding: 10px 24px;
  border-radius: 50px;
  font-weight: 500;
  font-size: 0.95rem;
}

.end-info p {
  font-size: 0.85rem;
  color: var(--text-dim);
  margin-bottom: 4px;
}

.btn-home {
  margin-top: 24px;
  background: rgba(92, 107, 192, 0.15);
  border: 1px solid rgba(92, 107, 192, 0.3);
  color: var(--accent-bright);
  padding: 10px 28px;
  border-radius: 50px;
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  transition: var(--transition);
  font-family: var(--font);
}

.btn-home:hover {
  background: rgba(92, 107, 192, 0.25);
}

/* ============================================
   KEYBOARD HINTS
   ============================================ */
.keyboard-hints {
  position: fixed;
  bottom: 70px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 16px;
  font-size: 0.72rem;
  color: var(--text-dim);
  z-index: 50;
  transition: opacity 0.3s ease;
}

.keyboard-hints.hidden { opacity: 0; pointer-events: none; }

.keyboard-hints span {
  background: rgba(22, 29, 69, 0.6);
  padding: 4px 10px;
  border-radius: 4px;
  border: 1px solid rgba(92, 107, 192, 0.1);
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 1024px) {
  .slide { padding: 30px 40px 100px; }
  .two-col { grid-template-columns: 1fr; gap: 24px; }
  .agenda-grid { grid-template-columns: repeat(2, 1fr); }
  .cards-row { grid-template-columns: 1fr; }
  .cards-row.two-cards { grid-template-columns: 1fr; }
  .conclusions-grid { grid-template-columns: repeat(2, 1fr); }
  .ops-grid { grid-template-columns: 1fr; }
  .compare-cards { grid-template-columns: 1fr; }
  .cycle-grid { gap: 8px; }
  .cycle-card { min-width: 100px; padding: 12px 16px; }
}

@media (max-width: 768px) {
  .slide { padding: 20px 20px 100px; }
  .agenda-grid { grid-template-columns: 1fr; }
  .conclusions-grid { grid-template-columns: 1fr; }
  .cover-team { flex-direction: column; align-items: center; }
  .keyboard-hints { display: none; }
  .side-menu { width: 300px; right: -300px; }
  .telecom-flow { flex-direction: column; }
  .telecom-arrow { transform: rotate(90deg); }
}

/* ============================================
   SCROLLBAR
   ============================================ */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--text-dim); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--accent); }

/* ============================================
   INTERACTIVE INPUTS (Complex Plane)
   ============================================ */
.interactive-inputs {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-bottom: 12px;
  padding: 10px;
  background: rgba(92, 107, 192, 0.08);
  border-radius: var(--radius-sm);
}

.interactive-inputs label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-muted);
}

.interactive-inputs input[type="number"] {
  width: 65px;
  padding: 6px 8px;
  background: var(--bg-light);
  border: 1px solid rgba(92, 107, 192, 0.3);
  border-radius: 6px;
  color: var(--accent-bright);
  font-family: var(--mono);
  font-size: 0.95rem;
  font-weight: 600;
  text-align: center;
  outline: none;
  transition: var(--transition);
}

.interactive-inputs input[type="number"]:focus {
  border-color: var(--accent-bright);
  box-shadow: 0 0 0 3px rgba(92, 107, 192, 0.15);
}

.input-plus {
  font-size: 1.1rem;
  color: var(--text-dim);
  font-weight: 600;
}

.plane-info {
  margin-top: 8px;
  padding: 8px 12px;
  background: rgba(92, 107, 192, 0.06);
  border-radius: 6px;
  font-size: 0.78rem;
  font-family: var(--mono);
  color: var(--text-muted);
  text-align: center;
  min-height: 28px;
}

/* ============================================
   INTERACTIVE CALCULATOR (Operations)
   ============================================ */
.calc-panel {
  background: var(--bg-card);
  border: 1px solid rgba(92, 107, 192, 0.2);
  border-radius: var(--radius);
  padding: 20px;
}

.calc-title {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--accent-bright);
  margin-bottom: 16px;
  text-align: center;
}

.calc-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  justify-content: center;
}

.calc-label {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text);
  min-width: 30px;
  font-family: var(--mono);
}

.calc-input {
  width: 60px;
  padding: 8px 6px;
  background: var(--bg-light);
  border: 1px solid rgba(92, 107, 192, 0.25);
  border-radius: 6px;
  color: var(--accent-bright);
  font-family: var(--mono);
  font-size: 1rem;
  font-weight: 600;
  text-align: center;
  outline: none;
  transition: var(--transition);
}

.calc-input:focus {
  border-color: var(--accent-bright);
  box-shadow: 0 0 0 3px rgba(92, 107, 192, 0.15);
}

.calc-op {
  font-size: 1.1rem;
  color: var(--text-dim);
  font-weight: 600;
}

.calc-i {
  font-size: 1rem;
  font-style: italic;
  font-weight: 600;
  color: var(--accent-bright);
}

.calc-hint {
  font-size: 0.75rem;
  color: var(--text-dim);
  text-align: center;
  margin-top: 4px;
}

/* Operations grid compact (for calculator layout) */
.ops-grid-compact {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.ops-grid-compact .op-big-card { padding: 14px; }
.ops-grid-compact .op-big-card h4 { font-size: 0.9rem; margin-bottom: 4px; }
.ops-grid-compact .op-formula { font-size: 0.78rem; margin-bottom: 6px; }

.op-result {
  font-family: var(--mono);
  font-size: 1rem;
  font-weight: 700;
  color: var(--accent-bright);
  padding: 6px 10px;
  background: rgba(92, 107, 192, 0.08);
  border-radius: 6px;
  text-align: center;
}

/* ============================================
   MANDELBROT INTERACTIVE INFO
   ============================================ */
.mandelbrot-info {
  margin-top: 8px;
  padding: 10px 12px;
  background: rgba(92, 107, 192, 0.06);
  border-radius: 6px;
  font-size: 0.8rem;
  font-family: var(--mono);
  color: var(--text-muted);
  min-height: 40px;
  line-height: 1.5;
}

#mandelbrotCanvas {
  cursor: crosshair;
}

/* ============================================
   SLIDE IMAGES
   ============================================ */
.slide-image {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid rgba(92, 107, 192, 0.15);
  background: linear-gradient(135deg, var(--bg-card), var(--bg-light));
  height: 200px;
}

.slide-image.compact { height: 160px; }
.slide-image.wide { width: 100%; height: 180px; margin-bottom: 12px; }
.slide-image.short { height: 140px; }

.slide-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease;
}

.slide-image:hover img { transform: scale(1.03); }

.slide-image::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(10, 14, 39, 0.7) 0%, transparent 60%);
  pointer-events: none;
}

.img-overlay-label {
  position: absolute;
  bottom: 10px;
  left: 12px;
  right: 12px;
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.9);
  z-index: 2;
  font-weight: 500;
  text-shadow: 0 1px 3px rgba(0,0,0,0.5);
}

/* Fallback when image fails to load */
.slide-image.img-fallback img { display: none; }

.slide-image.img-fallback {
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, rgba(92, 107, 192, 0.15), rgba(171, 71, 188, 0.1));
}

.img-fallback-content {
  display: none;
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-dim);
  text-align: center;
}

.slide-image.img-fallback .img-fallback-content { display: block; }
.slide-image.img-fallback::after { display: none; }
.slide-image.img-fallback .img-overlay-label { display: none; }

/* Remove spinner arrows from number inputs */
input[type="number"]::-webkit-inner-spin-button,
input[type="number"]::-webkit-outer-spin-button {
  -webkit-appearance: none;
  margin: 0;
}
input[type="number"] { -moz-appearance: textfield; }
