/* ─────────────────────────────────────────────────────────────
   KROK PO KROKU – DESIGN SYSTEM 2.0
   Aesthetic: Cinematic Minimalism / The Scribe
   Principles: High Contrast, Bold Type, Staggered Motion
───────────────────────────────────────────────────────────── */

:root {
  /* Surfaces — Deep Obsidian (OKLCH) */
  --bg:        oklch(12% 0.01 260);
  --surface:   oklch(16% 0.02 260);
  --surface-2: oklch(20% 0.02 260);
  --border:    oklch(25% 0.02 260);
  
  /* Accents — Glowing Amber */
  --amber:     oklch(78% 0.16 75);
  --amber-low: oklch(35% 0.08 75 / 0.3);
  --amber-bg:  oklch(78% 0.16 75 / 0.1);
  
  /* Text — High Contrast Readability */
  --text:      oklch(96% 0.01 260);
  --text-sub:  oklch(75% 0.01 260);
  --text-dim:  oklch(50% 0.01 260);
  
  /* Typography */
  --font-display: 'Lexend', system-ui, sans-serif;
  --font-ui:      'Nunito', system-ui, sans-serif;
  
  /* Spacing & Radii */
  --radius: 24px;
  --radius-sm: 12px;
  --gap: 2rem;
}

/* ── Reset ────────────────────────────────────────────────────── */
* { box-sizing: border-box; margin: 0; padding: 0; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-ui);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* ── Layout ─────────────────────────────────────────────────── */
.app-container {
  max-width: 800px;
  margin: 0 auto;
  padding: 1.5rem;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
}

/* ── Nav (Minimalist Header) ─────────────────────────────────── */
.site-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--gap);
  padding: 1rem 0;
}
.brand {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.25rem;
  letter-spacing: -0.03em;
  color: var(--amber);
}
.nav-pills {
  display: flex;
  gap: 0.5rem;
  background: var(--surface);
  padding: 0.4rem;
  border-radius: 999px;
  border: 1px solid var(--border);
}
.nav-pill {
  padding: 0.5rem 1rem;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-dim);
  transition: all 0.2s ease;
  cursor: pointer;
}
.nav-pill.active {
  background: var(--amber);
  color: var(--bg);
}

/* ── Card Hero (The Study View) ──────────────────────────────── */
.study-viewport {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 2rem;
}

.flashcard-main {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 3rem 2rem;
  text-align: center;
  position: relative;
  overflow: hidden;
  box-shadow: 0 20px 50px oklch(0 0 0 / 0.5);
  animation: card-reveal 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes card-reveal {
  from { opacity: 0; transform: translateY(20px) scale(0.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.word-pl {
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 8vw, 4rem);
  font-weight: 800;
  color: var(--text);
  margin-bottom: 0.5rem;
  letter-spacing: -0.04em;
}
.word-meta {
  font-size: 0.9rem;
  color: var(--amber);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 800;
}

/* ── Minimalist Add Card (The Note) ─────────────────────────── */
.note-editor {
  background: var(--surface);
  border: 2px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}
.note-input {
  background: transparent;
  border: none;
  font-family: var(--font-display);
  font-size: 1.5rem;
  color: var(--text);
  outline: none;
  width: 100%;
}
.note-input::placeholder { color: var(--text-dim); }
.note-textarea {
  background: transparent;
  border: none;
  font-family: var(--font-ui);
  font-size: 1.1rem;
  color: var(--text-sub);
  outline: none;
  width: 100%;
  resize: none;
  min-height: 120px;
}

/* ── Utilities ───────────────────────────────────────────────── */
.hidden { display: none !important; }
.btn-primary {
  background: var(--amber);
  color: var(--bg);
  padding: 1rem 2rem;
  border-radius: var(--radius-sm);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  transition: transform 0.1s ease;
}
.btn-primary:active { transform: scale(0.96); }
