/* Platform — design system */
:root {
  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --color-bg: #fafbfc;
  --color-surface: #ffffff;
  --color-text: #0f172a;
  --color-text-muted: #64748b;
  --color-accent: #4f46e5;
  --color-accent-hover: #4338ca;
  --color-border: #e2e8f0;
  --color-border-light: #f1f5f9;
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 14px;
  --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.04);
  --shadow-md: 0 4px 12px rgba(15, 23, 42, 0.06);
  --transition: 0.2s ease;
}

html {
  font-size: 15px;
  position: relative;
  height: 100%;
  min-height: 100%;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}


@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

body {
  font-family: var(--font-sans);
  color: var(--color-text);
  background: var(--color-bg);
  margin: 0;
  padding: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  line-height: 1.6;
}

/* Links */
a {
  color: var(--color-accent);
  text-decoration: none;
  transition: color var(--transition);
}

a:hover {
  color: var(--color-accent-hover);
}

/* Buttons */
.btn-primary {
  font-weight: 500;
  color: #fff;
  background: var(--color-accent);
  border: none;
  border-radius: var(--radius-md);
  padding: 0.5rem 1.25rem;
  transition: background var(--transition), transform 0.1s ease;
}

.btn-primary:hover {
  background: var(--color-accent-hover);
  color: #fff;
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus,
.form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.25);
}

/* Form placeholders */
.form-floating > .form-control-plaintext::placeholder,
.form-floating > .form-control::placeholder {
  color: var(--color-text-muted);
  text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder,
.form-floating > .form-control:focus::placeholder {
  text-align: start;
}

/* Page content area (flex: 1 keeps footer at bottom when content is short) */
.app-main {
  flex: 1 0 auto;
  padding-bottom: 5rem;
}

.app-content {
  max-width: 720px;
  margin: 0 auto;
  padding: 2.5rem 1.5rem 4rem;
}

@media (min-width: 768px) {
  .app-content {
    padding: 3.5rem 2rem 5rem;
  }
}

/* Typography helpers */
.page-title {
  font-size: clamp(1.75rem, 4vw, 2.25rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--color-text);
  margin-bottom: 0.5rem;
}

.page-lead {
  font-size: 1.125rem;
  color: var(--color-text-muted);
  margin-bottom: 1.5rem;
}

/* Pills / nav pills */
.nav-pills .nav-link.active,
.nav-pills .show > .nav-link {
  color: #fff;
  background: var(--color-accent);
  border: none;
}

/* Hero (home) */
.hero {
  text-align: center;
  padding: 2rem 0 3rem;
}

.hero-title {
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--color-text);
  margin-bottom: 0.75rem;
  line-height: 1.2;
}

.hero-lead {
  font-size: 1.25rem;
  color: var(--color-text-muted);
  max-width: 36ch;
  margin-left: auto;
  margin-right: auto;
  margin-bottom: 0.5rem;
}

.hero-muted {
  font-size: 0.9375rem;
  color: var(--color-text-muted);
}

.hero-muted a {
  font-weight: 500;
}

/* Content pages (e.g. Privacy) */
.content-page .content-body {
  margin-top: 1rem;
}

.content-body p {
  margin-bottom: 1rem;
}

.content-body p:last-child {
  margin-bottom: 0;
}

/* Error page */
.error-page {
  text-align: center;
  padding: 2rem 0;
}

.error-code {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-accent);
  margin-bottom: 0.5rem;
}

.error-request-id {
  font-size: 0.875rem;
  color: var(--color-text-muted);
}

.error-request-id code {
  font-size: 0.8125rem;
  padding: 0.2em 0.4em;
  background: var(--color-border-light);
  border-radius: var(--radius-sm);
}

.error-dev-note {
  text-align: left;
  padding: 1.25rem;
  background: var(--color-border-light);
  border-radius: var(--radius-md);
  border: 1px solid var(--color-border);
}

/* React root card (Components page) */
.react-root-card {
  min-height: 200px;
  padding: 1.5rem;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
}
