/*
  Jot Wheel — Base Styles
  Purpose:
  - Define typography, colors, and layout primitives
  - Apple-like, neutral, iOS-friendly defaults
  - Dark-mode first
*/

/* =========================
   Font: Inter (Google Fonts)
   ========================= */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

/* =========================
   CSS Variables (Theme)
   ========================= */

:root {
  /* Colors — Apple-inspired dark UI */
  --color-bg: #000000;
  --color-surface: #111111;
  --color-surface-elevated: #1c1c1e;

  --color-text-primary: #ffffff;
  --color-text-secondary: #a1a1a6;
  --color-text-tertiary: #6e6e73;

  --color-accent: #0a84ff; /* iOS system blue */
  --color-divider: rgba(255, 255, 255, 0.08);

  /* Typography */
  --font-family: 'Inter', -apple-system, BlinkMacSystemFont,
    'SF Pro Text', 'SF Pro Display', system-ui, sans-serif;

  /* Sizing */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;

  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 24px;
  --space-6: 32px;

  /* Shadows (subtle, Apple-like) */
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.4);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.5);
}

/* =========================
   Base Body Styles
   ========================= */

body {
  font-family: var(--font-family);
  background-color: #111111;
  color: var(--color-text-primary);
  font-size: 16px;
  font-weight: 400;
}

/* =========================
   Headings (Apple-like scale)
   ========================= */

h1 {
  font-size: 28px;
  font-weight: 700;
  letter-spacing: -0.02em;
}

h2 {
  font-size: 22px;
  font-weight: 600;
  letter-spacing: -0.015em;
}

h3 {
  font-size: 18px;
  font-weight: 600;
}

p {
  font-size: 15px;
  color: var(--color-text-secondary);
}

/* =========================
   Layout Helpers
   ========================= */

.container {
  padding: var(--space-4);
}

.divider {
  height: 1px;
  background-color: var(--color-divider);
  margin: var(--space-4) 0;
}

/* =========================
   Buttons (System-like)
   ========================= */

button {
  font-family: inherit;
  font-size: 15px;
  font-weight: 600;
}

.button-primary {
  background-color: var(--color-accent);
  color: #ffffff;
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius-md);
}

.button-secondary {
  background-color: var(--color-surface-elevated);
  color: var(--color-text-primary);
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius-md);
}

/* =========================
   Cards (used everywhere)
   ========================= */

.card {
  background-color: var(--color-surface);
  border-radius: var(--radius-lg);
  padding: var(--space-3);
  box-shadow: var(--shadow-sm);
}

/* =========================
   Text Utilities
   ========================= */

.text-primary {
  color: var(--color-text-primary);
}

.text-secondary {
  color: var(--color-text-secondary);
}

.text-tertiary {
  color: var(--color-text-tertiary);
}

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

/* =========================
   Touch & Selection
   ========================= */

::selection {
  background-color: rgba(10, 132, 255, 0.3);
}

/* =========================
   Safe Area Support (iOS)
   ========================= */

.safe-area {
  padding-bottom: env(safe-area-inset-bottom);
  
}

/* =========================
   App Shell (Desktop Centering)
   ========================= */

.app-shell {
  max-width: 420px; /* iPhone Pro width sweet spot */
  margin: 0 auto;
  min-height: 100vh;
  background-color: var(--color-bg);
}

/* Ensure hidden attribute always works */
[hidden] {
  display: none !important;
}

.env-badge {
  position: fixed;
  top: 8px;
  right: 8px;
  z-index: 1000;

  background: #ffcc00;
  color: #000;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.05em;

  padding: 4px 8px;
  border-radius: 6px;

  opacity: 0.85;
}

