/* Blips marketing site — matches app branding */

:root {
  color-scheme: light dark;

  /* Colors matching Flutter app (from app.dart) */
  --primary: #0E7490;
  --primary-light: #22D3EE;

  /* Dark theme (default — matches app dark mode) */
  --bg: #0F172A;
  --panel: #1E293B;
  --text: #F1F5F9;
  --muted: #94A3B8;
  --border: rgba(148, 163, 184, 0.2);

  --shadow: 0 10px 40px rgba(0, 0, 0, 0.35);
  --radius: 16px;
  --radius-sm: 10px;
  --maxw: 960px;

  --focus: #22D3EE;

  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

@media (prefers-color-scheme: light) {
  :root {
    --bg: #F1F5F9;
    --panel: #FFFFFF;
    --text: #0F172A;
    --muted: #64748B;
    --border: rgba(15, 23, 42, 0.1);
    --shadow: 0 8px 30px rgba(15, 23, 42, 0.08);
    --focus: #0E7490;
  }
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

body {
  margin: 0;
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--primary-light);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

a:focus-visible,
button:focus-visible,
[role="button"]:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Skip link for accessibility */
.skip-link {
  position: absolute;
  top: -100%;
  left: 16px;
  background: var(--primary);
  color: #fff;
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  z-index: 100;
  font-weight: 600;
}

.skip-link:focus {
  top: 16px;
}

/* Layout */
.container {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 20px;
}

/* Header */
.header {
  position: sticky;
  top: 0;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  z-index: 50;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 0;
  gap: 16px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--text);
}

.brand:hover {
  text-decoration: none;
}

.logo {
  width: 36px;
  height: 36px;
  border-radius: 8px;
}

.brand-title {
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  align-items: center;
}

.nav a {
  color: var(--muted);
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  font-weight: 500;
}

.nav a:hover {
  color: var(--text);
  background: var(--panel);
  text-decoration: none;
}

@media (max-width: 600px) {
  .header-inner {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }

  .nav {
    width: 100%;
    gap: 2px;
  }

  .nav a {
    padding: 8px 10px;
    font-size: 0.85rem;
  }
}

/* Hero */
.hero {
  padding: 48px 0 32px;
  text-align: center;
}

.hero-logo {
  width: 72px;
  height: 72px;
  border-radius: 16px;
  margin: 0 auto 20px;
  box-shadow: var(--shadow);
}

.hero h1 {
  font-size: clamp(1.6rem, 4vw, 2.2rem);
  font-weight: 700;
  margin: 0 0 12px;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.hero-tagline {
  color: var(--muted);
  font-size: 1.05rem;
  margin: 0 0 24px;
  max-width: 480px;
  margin-left: auto;
  margin-right: auto;
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 18px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 0.9rem;
  text-decoration: none;
  border: 1px solid var(--border);
  background: var(--panel);
  color: var(--text);
  transition: background 0.15s, border-color 0.15s;
}

.button:hover {
  background: var(--border);
  text-decoration: none;
}

.button.primary {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
}

.button.primary:hover {
  background: #0C6980;
  border-color: #0C6980;
}

/* Screenshots */
.screenshots {
  padding: 24px 0;
}

.screenshots h2 {
  font-size: 1.1rem;
  font-weight: 600;
  margin: 0 0 16px;
  text-align: center;
}

.screenshot-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

@media (max-width: 700px) {
  .screenshot-grid {
    grid-template-columns: 1fr;
    max-width: 280px;
    margin: 0 auto;
  }
}

.screenshot-slot {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 12px;
  text-align: center;
}

.screenshot-placeholder {
  background: var(--bg);
  border-radius: var(--radius-sm);
  aspect-ratio: 9 / 16;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  font-size: 0.8rem;
  border: 1px dashed var(--border);
}

.screenshot-slot figcaption {
  margin-top: 8px;
  color: var(--muted);
  font-size: 0.8rem;
}

/* Section */
.section {
  padding: 32px 0;
}

.section h2 {
  font-size: 1.2rem;
  font-weight: 600;
  margin: 0 0 16px;
}

/* Card */
.card {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
}

.card h3 {
  font-size: 1rem;
  font-weight: 600;
  margin: 0 0 6px;
}

.card p {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

@media (max-width: 700px) {
  .grid-3 {
    grid-template-columns: 1fr;
  }
}

/* Footer */
.footer {
  padding: 32px 0 48px;
  border-top: 1px solid var(--border);
  margin-top: 24px;
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-start;
  gap: 20px;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 10px;
}

.footer-brand img {
  width: 28px;
  height: 28px;
  border-radius: 6px;
}

.footer-brand span {
  font-weight: 600;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}

.footer-links a {
  color: var(--muted);
  font-size: 0.9rem;
}

.footer-links a:hover {
  color: var(--text);
}

.footer-copy {
  width: 100%;
  margin-top: 16px;
  color: var(--muted);
  font-size: 0.8rem;
}

@media (max-width: 600px) {
  .footer-inner {
    flex-direction: column;
  }
}

/* Utility */
.muted {
  color: var(--muted);
}

.small {
  font-size: 0.85rem;
}

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

/* Prose (policy pages) */
.prose {
  max-width: 640px;
  margin: 0 auto;
}

.card.prose {
  padding: 32px;
  max-width: 100%;
}

.prose h1 {
  font-size: 1.6rem;
  font-weight: 700;
  margin: 0 0 8px;
  color: var(--text);
}

.prose h2 {
  font-size: 1.1rem;
  font-weight: 600;
  margin: 24px 0 8px;
  color: var(--text);
}

.prose p,
.prose li {
  color: var(--muted);
  margin: 0 0 12px;
}

.prose ul {
  padding-left: 20px;
}

.prose a {
  color: var(--primary-light);
}

.prose hr {
  border: 0;
  border-top: 1px solid var(--border);
  margin: 24px 0;
}
