/* ScholarOS: Sovereign Action & Knowledge Master Engine */
:root {
  --bg-core: #060913;
  --bg-card: rgba(15, 22, 42, 0.8);
  --bg-surface: rgba(30, 41, 59, 0.5);
  --border-subtle: rgba(255, 255, 255, 0.08);
  --border-accent: rgba(245, 158, 11, 0.3);
  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --text-dim: #64748b;
  --amber: #f59e0b;
  --amber-glow: rgba(245, 158, 11, 0.2);
  --cyan: #06b6d4;
  --emerald: #10b981;
  --rose: #f43f5e;
  --indigo: #6366f1;
  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background-color: var(--bg-core);
  background-image: 
    radial-gradient(circle at 15% 15%, rgba(245, 158, 11, 0.04) 0%, transparent 40%),
    radial-gradient(circle at 85% 85%, rgba(6, 182, 212, 0.04) 0%, transparent 40%);
  color: var(--text-main);
  font-family: var(--font-sans);
  min-height: 100vh;
  line-height: 1.6;
  overflow-x: hidden;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
::-webkit-scrollbar-track {
  background: var(--bg-core);
}
::-webkit-scrollbar-thumb {
  background: #1e293b;
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: #334155;
}

/* Header & Nav */
.header-glass {
  background: rgba(6, 9, 19, 0.85);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-subtle);
  position: sticky;
  top: 0;
  z-index: 50;
}

/* Tab Pills */
.nav-pill {
  transition: all 0.2s ease;
}
.nav-pill.active {
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.2), rgba(217, 119, 6, 0.3));
  border-color: rgba(245, 158, 11, 0.6);
  color: #fbbf24;
  box-shadow: 0 0 15px rgba(245, 158, 11, 0.2);
}

/* 3D Flip Flashcard */
.flashcard-scene {
  perspective: 1000px;
}
.flashcard-inner {
  position: relative;
  width: 100%;
  min-height: 280px;
  transform-style: preserve-3d;
  transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
  cursor: pointer;
}
.flashcard-scene.flipped .flashcard-inner {
  transform: rotateY(180deg);
}
.flashcard-front, .flashcard-back {
  position: absolute;
  inset: 0;
  backface-visibility: hidden;
  border-radius: 16px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.flashcard-front {
  background: rgba(15, 23, 42, 0.85);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.5);
}
.flashcard-back {
  background: radial-gradient(circle at top left, #1e293b 0%, #0f172a 100%);
  border: 1px solid rgba(245, 158, 11, 0.4);
  transform: rotateY(180deg);
  box-shadow: 0 10px 30px -5px rgba(245, 158, 11, 0.15);
}

/* RSVP Speed Reader */
.rsvp-stage {
  background: #000000;
  border: 1px solid rgba(6, 182, 212, 0.3);
  border-radius: 16px;
  box-shadow: inset 0 0 30px rgba(6, 182, 212, 0.1);
  height: 180px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}
.rsvp-word {
  font-family: var(--font-mono);
  font-size: 3rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #ffffff;
}
.rsvp-orp {
  color: #06b6d4;
  text-shadow: 0 0 15px rgba(6, 182, 212, 0.6);
}

/* Interactive Card Hover */
.action-card {
  transition: all 0.25s ease;
}
.action-card:hover {
  transform: translateY(-2px);
  border-color: rgba(245, 158, 11, 0.4);
  box-shadow: 0 12px 30px -8px rgba(0, 0, 0, 0.6), 0 0 20px rgba(245, 158, 11, 0.1);
}

/* Custom Checkbox */
.custom-chk {
  appearance: none;
  width: 18px;
  height: 18px;
  border: 2px solid #475569;
  border-radius: 4px;
  background: transparent;
  cursor: pointer;
  display: inline-grid;
  place-content: center;
  transition: all 0.15s ease;
}
.custom-chk:checked {
  background: #10b981;
  border-color: #10b981;
}
.custom-chk:checked::before {
  content: "✓";
  color: #ffffff;
  font-size: 12px;
  font-weight: bold;
}

/* 3D Strangest Secret Goal Card */
.goal-card-scene {
  perspective: 1200px;
}
.goal-card-inner {
  position: relative;
  width: 100%;
  min-height: 220px;
  transform-style: preserve-3d;
  transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
  cursor: pointer;
}
.goal-card-scene.flipped .goal-card-inner {
  transform: rotateY(180deg);
}
.goal-card-front, .goal-card-back {
  position: absolute;
  inset: 0;
  backface-visibility: hidden;
  border-radius: 14px;
  padding: 16px 20px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.goal-card-front {
  background: linear-gradient(145deg, #1e1b18 0%, #0f172a 100%);
  border: 2px solid rgba(245, 158, 11, 0.5);
  box-shadow: 0 10px 30px -5px rgba(245, 158, 11, 0.2), inset 0 0 15px rgba(245, 158, 11, 0.05);
}
.goal-card-back {
  background: linear-gradient(145deg, #0f172a 0%, #1e1b18 100%);
  border: 2px solid rgba(6, 182, 212, 0.5);
  transform: rotateY(180deg);
  box-shadow: 0 10px 30px -5px rgba(6, 182, 212, 0.2), inset 0 0 15px rgba(6, 182, 212, 0.05);
}
