/* ============================================================
   NSLC Business & Entrepreneurship — Lecture Deck Framework
   Palette: Michigan navy + maize, with per-lecture accent
   ============================================================ */

:root {
  --navy-950: #001226;
  --navy-900: #001A33;
  --navy-800: #00274C;
  --navy-700: #0B3A66;
  --navy-100: #D6E4F5;
  --maize: #FFCB05;
  --maize-deep: #E6B400;
  --sky: #4CC9F0;
  --mint: #2EC4B6;
  --coral: #FF5A5F;
  --paper: #F7F9FC;
  --ink: #10243A;
  --ink-soft: #4A6076;
  --accent: var(--maize);          /* overridden per lecture */
  --accent-ink: #1A1A0A;           /* text color on accent bg */
  --radius: 18px;
  --shadow: 0 12px 40px rgba(0, 18, 38, .25);
  --font-display: 'Space Grotesk', 'Segoe UI', system-ui, sans-serif;
  --font-body: 'Inter', 'Segoe UI', system-ui, sans-serif;
}

body[data-accent="sky"]  { --accent: var(--sky);  --accent-ink: #04222E; }
body[data-accent="mint"] { --accent: var(--mint); --accent-ink: #05221F; }

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

html, body { height: 100%; }

body {
  font-family: var(--font-body);
  background: var(--navy-900);
  color: var(--paper);
  overflow: hidden;
}

/* ---------- Deck & slides ---------- */

.deck { position: fixed; inset: 0; }

.slide {
  position: absolute; inset: 0;
  display: flex; flex-direction: column; justify-content: center;
  padding: 7vh 6vw 10vh;
  opacity: 0; visibility: hidden;
  transform: translateY(24px);
  transition: opacity .45s ease, transform .45s ease, visibility .45s;
  overflow-y: auto;
}
.slide.active { opacity: 1; visibility: visible; transform: none; z-index: 2; }

.slide.light { background: var(--paper); color: var(--ink); }
.slide.dark  { background:
  radial-gradient(1200px 600px at 85% -10%, rgba(76, 201, 240, .12), transparent 60%),
  radial-gradient(900px 500px at -10% 110%, rgba(255, 203, 5, .10), transparent 55%),
  var(--navy-900);
}

/* ---------- Typography ---------- */

.kicker {
  font-family: var(--font-display);
  font-size: clamp(12px, 1.4vw, 17px);
  letter-spacing: .22em; text-transform: uppercase;
  color: var(--accent); font-weight: 700;
  margin-bottom: 1.2rem;
}
.slide.light .kicker { color: var(--navy-700); }

h1 {
  font-family: var(--font-display);
  font-size: clamp(34px, 5.6vw, 76px);
  line-height: 1.04; letter-spacing: -.015em;
  margin-bottom: 1.6rem;
}
h2 {
  font-family: var(--font-display);
  font-size: clamp(26px, 3.8vw, 50px);
  line-height: 1.08; margin-bottom: 1.4rem;
}
h3 { font-family: var(--font-display); font-size: clamp(18px, 2vw, 26px); margin-bottom: .5rem; }

p, li { font-size: clamp(15px, 1.55vw, 21px); line-height: 1.55; }
.lead { font-size: clamp(18px, 2vw, 26px); line-height: 1.5; max-width: 46ch; }
.muted { opacity: .72; }
.hl { color: var(--accent); font-weight: 700; }
.slide.light .hl { color: var(--navy-700); background: linear-gradient(transparent 62%, rgba(255,203,5,.55) 62%); padding: 0 .1em; }

ul.clean { list-style: none; }
ul.spaced li { margin-bottom: .7em; }

/* ---------- Layout helpers ---------- */

.two-col { display: grid; grid-template-columns: 1.1fr 1fr; gap: 4vw; align-items: center; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.2vw; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.2vw; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.2vw; }
.center { text-align: center; align-items: center; }
.stack { display: flex; flex-direction: column; gap: 1rem; }

/* ---------- Cards ---------- */

.card {
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: var(--radius);
  padding: clamp(14px, 1.8vw, 26px);
  backdrop-filter: blur(4px);
}
.slide.light .card {
  background: #fff; border: 1px solid #E3EAF3;
  box-shadow: 0 6px 24px rgba(16, 36, 58, .08);
}
.card .icon { font-size: clamp(24px, 2.6vw, 38px); margin-bottom: .5rem; display: block; }
.card h3 { color: var(--accent); }
.slide.light .card h3 { color: var(--navy-800); }
.card p { font-size: clamp(13px, 1.25vw, 17px); }

.big-stat { font-family: var(--font-display); font-size: clamp(48px, 7vw, 110px); font-weight: 700; color: var(--accent); line-height: 1; }
.big-stat + .stat-label { font-size: clamp(14px, 1.5vw, 20px); opacity: .8; margin-top: .4rem; }

/* ---------- Story slot (Danny fills these in) ---------- */

.story-card {
  position: relative;
  background: linear-gradient(135deg, var(--navy-800), var(--navy-950));
  border: 2px dashed var(--maize);
  border-radius: var(--radius);
  padding: clamp(18px, 2.2vw, 30px);
  box-shadow: var(--shadow);
}
.story-card .chip {
  display: inline-flex; align-items: center; gap: .45em;
  background: var(--maize); color: #1A1A0A;
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(11px, 1.1vw, 14px); letter-spacing: .08em; text-transform: uppercase;
  padding: .35em .9em; border-radius: 999px; margin-bottom: .9rem;
}
.story-card .prompt { font-size: clamp(16px, 1.8vw, 24px); font-weight: 600; color: #fff; margin-bottom: .6rem; }
.story-card .beats { list-style: none; }
.story-card .beats li { font-size: clamp(13px, 1.3vw, 17px); opacity: .78; padding-left: 1.2em; position: relative; margin-bottom: .3em; }
.story-card .beats li::before { content: "→"; position: absolute; left: 0; color: var(--maize); }

/* ---------- Media placeholders ---------- */

.media-slot {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .5rem;
  min-height: clamp(160px, 26vh, 320px);
  border: 2px dashed rgba(255,255,255,.35);
  border-radius: var(--radius);
  background: rgba(255,255,255,.04);
  color: rgba(255,255,255,.65);
  text-align: center; padding: 1rem;
  font-size: clamp(13px, 1.3vw, 17px);
}
.slide.light .media-slot { border-color: #B9C7D8; background: #EEF3F9; color: var(--ink-soft); }
.media-slot .icon { font-size: clamp(30px, 3.4vw, 52px); opacity: .8; }
.media-slot strong { font-family: var(--font-display); letter-spacing: .05em; }

/* ---------- Fragments (step-by-step reveals) ---------- */

.fragment { opacity: 0; transform: translateY(14px); transition: opacity .4s ease, transform .4s ease; }
.fragment.visible { opacity: 1; transform: none; }

/* ---------- Branch buttons & branch slides ---------- */

.branch-btn {
  display: inline-flex; align-items: center; gap: .5em;
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(13px, 1.3vw, 17px);
  color: var(--accent-ink); background: var(--accent);
  border: none; border-radius: 999px;
  padding: .65em 1.3em; cursor: pointer;
  box-shadow: 0 6px 18px rgba(0,0,0,.25);
  transition: transform .15s ease, box-shadow .15s ease;
}
.branch-btn:hover { transform: translateY(-2px); box-shadow: 0 10px 24px rgba(0,0,0,.3); }
.branch-btn.ghost {
  background: transparent; color: var(--accent);
  border: 2px solid var(--accent); box-shadow: none;
}
.slide.light .branch-btn.ghost { color: var(--navy-800); border-color: var(--navy-800); }

.slide.branch::before {
  content: "DEEPER DIVE";
  position: absolute; top: 3.2vh; right: 6vw;
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(10px, 1vw, 13px); letter-spacing: .25em;
  color: var(--accent); opacity: .9;
}
.back-btn {
  position: absolute; top: 3vh; left: 6vw; z-index: 5;
  display: inline-flex; align-items: center; gap: .4em;
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(12px, 1.2vw, 15px);
  background: rgba(255,255,255,.1); color: inherit;
  border: 1px solid rgba(255,255,255,.3);
  border-radius: 999px; padding: .5em 1.1em; cursor: pointer;
}
.slide.light .back-btn { background: #fff; border-color: #C9D6E5; color: var(--ink); }
.back-btn:hover { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }

/* ---------- Interactive: polls ---------- */

.poll { display: flex; flex-direction: column; gap: .8rem; width: 100%; max-width: 720px; }
.poll-option {
  position: relative; overflow: hidden;
  display: flex; justify-content: space-between; align-items: center; gap: 1rem;
  font: inherit; font-size: clamp(15px, 1.6vw, 21px); font-weight: 600;
  text-align: left; color: inherit;
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.18);
  border-radius: 14px; padding: .85em 1.2em; cursor: pointer;
  transition: border-color .2s;
}
.slide.light .poll-option { background: #fff; border-color: #DCE5F0; }
.poll-option:hover { border-color: var(--accent); }
.poll-option .bar {
  position: absolute; inset: 0 auto 0 0; width: 0%;
  background: linear-gradient(90deg, rgba(255,203,5,.32), rgba(255,203,5,.12));
  transition: width .6s cubic-bezier(.2,.8,.2,1);
  z-index: 0;
}
.poll-option .label, .poll-option .count { position: relative; z-index: 1; }
.poll-option .count { font-family: var(--font-display); color: var(--accent); min-width: 2ch; text-align: right; }
.slide.light .poll-option .count { color: var(--navy-700); }

/* ---------- Interactive: flip cards ---------- */

.flip-card { perspective: 1200px; cursor: pointer; min-height: clamp(130px, 19vh, 220px); }
.flip-inner {
  position: relative; width: 100%; height: 100%;
  transform-style: preserve-3d; transition: transform .55s cubic-bezier(.3,.8,.3,1);
}
.flip-card.flipped .flip-inner { transform: rotateY(180deg); }
.flip-face {
  position: absolute; inset: 0; backface-visibility: hidden;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .4rem;
  border-radius: var(--radius); padding: 1rem 1.1rem; text-align: center;
}
.flip-front {
  background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.16);
  font-family: var(--font-display); font-weight: 700; font-size: clamp(15px, 1.6vw, 21px);
}
.slide.light .flip-front { background: #fff; border: 1px solid #DCE5F0; color: var(--navy-800); }
.flip-front .icon { font-size: clamp(26px, 2.8vw, 42px); }
.flip-back {
  transform: rotateY(180deg);
  background: var(--accent); color: var(--accent-ink);
  font-size: clamp(12px, 1.25vw, 16px); line-height: 1.4; font-weight: 500;
}

/* ---------- Interactive: sorter game ---------- */

.sorter { display: flex; flex-direction: column; gap: 1.4rem; width: 100%; }
.sorter-pool { display: flex; flex-wrap: wrap; gap: .7rem; justify-content: center; min-height: 3em; }
.sorter-item {
  font: inherit; font-size: clamp(13px, 1.35vw, 18px); font-weight: 600; color: inherit;
  background: rgba(255,255,255,.09); border: 2px solid rgba(255,255,255,.25);
  border-radius: 999px; padding: .5em 1.1em; cursor: pointer;
  transition: transform .15s, border-color .15s, opacity .3s;
}
.slide.light .sorter-item { background: #fff; border-color: #C9D6E5; }
.sorter-item.selected { border-color: var(--accent); transform: scale(1.07); box-shadow: 0 0 0 4px rgba(255,203,5,.25); }
.sorter-item.placed { opacity: 0; pointer-events: none; position: absolute; }
.sorter-buckets { display: grid; grid-template-columns: 1fr 1fr; gap: 1.2rem; }
.bucket {
  min-height: clamp(110px, 18vh, 200px);
  border: 2px dashed rgba(255,255,255,.35); border-radius: var(--radius);
  padding: .9rem; cursor: pointer; transition: border-color .2s, background .2s;
}
.slide.light .bucket { border-color: #B9C7D8; }
.bucket:hover { border-color: var(--accent); background: rgba(255,203,5,.06); }
.bucket h3 { text-align: center; }
.bucket .bucket-items { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: .6rem; justify-content: center; }
.bucket .chip-placed {
  font-size: clamp(12px, 1.2vw, 15px); font-weight: 600;
  border-radius: 999px; padding: .35em .9em;
  animation: pop .3s ease;
}
.chip-placed.correct { background: var(--mint); color: #04302B; }
.chip-placed.wrong   { background: var(--coral); color: #fff; }
@keyframes pop { from { transform: scale(.6); } to { transform: scale(1); } }

/* ---------- Interactive: quiz options ---------- */

.quiz-option {
  font: inherit; font-size: clamp(14px, 1.5vw, 19px); font-weight: 600;
  color: inherit; text-align: left;
  background: rgba(255,255,255,.07); border: 2px solid rgba(255,255,255,.18);
  border-radius: 14px; padding: .8em 1.1em; cursor: pointer; width: 100%;
  transition: border-color .2s, background .2s;
}
.slide.light .quiz-option { background: #fff; border-color: #DCE5F0; }
.quiz-option:hover { border-color: var(--accent); }
.quiz-option.correct { background: var(--mint); border-color: var(--mint); color: #04302B; }
.quiz-option.wrong { background: var(--coral); border-color: var(--coral); color: #fff; animation: shake .35s ease; }
@keyframes shake { 25% { transform: translateX(-6px); } 75% { transform: translateX(6px); } }

/* ---------- Interactive: sliders / calculators ---------- */

.calc { display: grid; gap: 1rem; }
.calc-row { display: flex; align-items: center; gap: 1rem; }
.calc-row label { font-weight: 600; font-size: clamp(13px, 1.35vw, 18px); flex: 0 0 clamp(150px, 16vw, 230px); }
.calc-row output { font-family: var(--font-display); font-weight: 700; color: var(--accent); font-size: clamp(15px, 1.6vw, 22px); min-width: 5ch; }
.slide.light .calc-row output { color: var(--navy-700); }
input[type="range"] {
  flex: 1; appearance: none; height: 8px; border-radius: 99px;
  background: rgba(255,255,255,.2); outline: none; cursor: pointer;
}
.slide.light input[type="range"] { background: #D5DFEC; }
input[type="range"]::-webkit-slider-thumb {
  appearance: none; width: 24px; height: 24px; border-radius: 50%;
  background: var(--accent); border: 3px solid #fff;
  box-shadow: 0 3px 10px rgba(0,0,0,.3);
}
.formula {
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(18px, 2.4vw, 34px);
  background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.15);
  border-radius: var(--radius); padding: .7em 1em; text-align: center;
}
.slide.light .formula { background: #fff; border-color: #DCE5F0; color: var(--navy-800); }
.formula .op { color: var(--accent); margin: 0 .3em; }
.slide.light .formula .op { color: var(--maize-deep); }

/* ---------- Timeline ---------- */

.timeline { display: flex; align-items: flex-start; gap: 0; width: 100%; margin-top: 1.5rem; }
.tl-node { flex: 1; text-align: center; cursor: pointer; position: relative; padding-top: 34px; }
.tl-node::before {
  content: ""; position: absolute; top: 8px; left: 50%; transform: translateX(-50%);
  width: 18px; height: 18px; border-radius: 50%;
  background: var(--navy-100); border: 4px solid var(--accent);
  transition: transform .2s, background .2s; z-index: 1;
}
.tl-node::after {
  content: ""; position: absolute; top: 15px; left: 50%; width: 100%; height: 4px;
  background: rgba(255,255,255,.25);
}
.tl-node:last-child::after { display: none; }
.tl-node:hover::before, .tl-node.open::before { background: var(--accent); transform: translateX(-50%) scale(1.25); }
.tl-node .tl-year { font-family: var(--font-display); font-weight: 700; color: var(--accent); font-size: clamp(13px, 1.4vw, 18px); }
.tl-node .tl-label { font-size: clamp(11px, 1.15vw, 15px); opacity: .85; }
.tl-detail {
  margin-top: 1.6rem; min-height: 5em;
  font-size: clamp(14px, 1.5vw, 19px); line-height: 1.5;
}

/* ---------- SWOT grid ---------- */

.swot-grid { display: grid; grid-template-columns: 1fr 1fr; grid-template-rows: 1fr 1fr; gap: 1rem; width: 100%; }
.swot-cell {
  border-radius: var(--radius); padding: 1rem 1.2rem; cursor: pointer;
  min-height: clamp(110px, 17vh, 190px);
  transition: transform .2s, filter .2s;
}
.swot-cell:hover { transform: translateY(-3px); filter: brightness(1.1); }
.swot-cell h3 { display: flex; align-items: center; gap: .5em; color: inherit; }
.swot-cell .swot-hidden { opacity: 0; max-height: 0; overflow: hidden; transition: opacity .4s, max-height .4s; font-size: clamp(12px, 1.25vw, 16px); }
.swot-cell.open .swot-hidden { opacity: 1; max-height: 12em; }
.swot-s { background: #144D3A; color: #C9F2DF; }
.swot-w { background: #5B1F2E; color: #FBD5DD; }
.swot-o { background: #123F5C; color: #CBE7FA; }
.swot-t { background: #4D3A10; color: #F7E6B4; }

/* ---------- Chrome: progress, nav, counter ---------- */

.progress { position: fixed; top: 0; left: 0; height: 5px; width: 0%; background: var(--accent); z-index: 50; transition: width .3s ease; }

.deck-nav {
  position: fixed; bottom: 2.4vh; right: 2vw; z-index: 50;
  display: flex; gap: .5rem; align-items: center;
}
.deck-nav button {
  width: 44px; height: 44px; border-radius: 50%;
  border: 1px solid rgba(255,255,255,.3);
  background: rgba(0, 26, 51, .65); color: #fff;
  font-size: 18px; cursor: pointer; backdrop-filter: blur(6px);
}
.deck-nav button:hover { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }

.slide-counter {
  position: fixed; bottom: 3vh; left: 2vw; z-index: 50;
  font-family: var(--font-display); font-size: 13px; letter-spacing: .1em;
  color: rgba(255,255,255,.55);
}

.brand-tag {
  position: fixed; top: 2.4vh; right: 2vw; z-index: 40;
  font-family: var(--font-display); font-weight: 700;
  font-size: 12px; letter-spacing: .2em; text-transform: uppercase;
  color: rgba(255,255,255,.4); text-decoration: none;
}
.brand-tag:hover { color: var(--accent); }

.help-hint {
  position: fixed; bottom: 3vh; left: 50%; transform: translateX(-50%); z-index: 40;
  font-size: 12px; color: rgba(255,255,255,.4); letter-spacing: .05em;
  pointer-events: none; transition: opacity 1s;
}

/* ---------- Overview grid ---------- */

.overview {
  position: fixed; inset: 0; z-index: 60;
  background: rgba(0, 12, 26, .96); backdrop-filter: blur(8px);
  display: none; padding: 5vh 5vw; overflow-y: auto;
}
.overview.show { display: block; }
.overview h2 { color: var(--maize); margin-bottom: 1.2rem; }
.overview-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: .9rem; }
.overview-item {
  font: inherit; text-align: left; color: #fff;
  background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.16);
  border-radius: 12px; padding: .9rem; cursor: pointer;
}
.overview-item:hover, .overview-item.current { border-color: var(--accent); background: rgba(255,203,5,.1); }
.overview-item .num { font-family: var(--font-display); color: var(--accent); font-weight: 700; font-size: 13px; }
.overview-item .t { display: block; font-size: 14px; font-weight: 600; margin-top: .3em; }

/* ---------- Speaker notes drawer ---------- */

aside.notes { display: none; }
.notes-drawer {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 55;
  background: #0A1F35; border-top: 3px solid var(--accent);
  padding: 1.1rem 5vw 1.4rem; max-height: 34vh; overflow-y: auto;
  transform: translateY(100%); transition: transform .3s ease;
  font-size: 15px; line-height: 1.55; color: #D9E4F0;
}
.notes-drawer.show { transform: none; }
.notes-drawer .nd-label { font-family: var(--font-display); font-weight: 700; color: var(--accent); letter-spacing: .15em; font-size: 11px; text-transform: uppercase; display: block; margin-bottom: .4rem; }

/* ---------- Decorative animations ---------- */

@keyframes floaty { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-16px); } }
.floaty { animation: floaty 5s ease-in-out infinite; }

@keyframes drawline { to { stroke-dashoffset: 0; } }

.pulse-dot { display: inline-block; width: .55em; height: .55em; border-radius: 50%; background: var(--accent); animation: pulse 1.6s infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(255,203,5,.5); } 70% { box-shadow: 0 0 0 14px rgba(255,203,5,0); } 100% { box-shadow: 0 0 0 0 rgba(255,203,5,0); } }

/* ---------- Responsive ---------- */

@media (max-width: 900px) {
  .two-col { grid-template-columns: 1fr; gap: 3vh; }
  .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .slide { padding: 6vh 6vw 12vh; justify-content: flex-start; }
}
