/* Brain Buddy — landing page
 * Mirrors the SPA design tokens from resources/scss/_properties.scss
 * Self-contained: fonts in /fonts, images in /images.
 */

@font-face {
  font-family: 'Rubik';
  font-style: normal;
  font-weight: 300 900;
  font-display: swap;
  src: url('fonts/rubik-latin.woff2') format('woff2');
}
@font-face {
  font-family: 'Rubik';
  font-style: italic;
  font-weight: 300 900;
  font-display: swap;
  src: url('fonts/rubik-italic-latin.woff2') format('woff2');
}

:root {
  --color-bg: #FFF8F0;
  --color-bg-soft: #FEEFE0;
  --color-surface: #FFFFFF;
  --color-text: #1A1322;
  --color-text-muted: #6B5E7A;
  --color-border: #F0E1D2;
  --color-border-strong: #E5D3BF;

  --color-mandatory: #FF6B47;
  --color-mandatory-soft: #FFE4DA;
  --color-regular: #3DD9C7;
  --color-regular-soft: #D4F5F2;
  --color-optional: #A78BFA;
  --color-optional-soft: #EDE9FE;

  --color-primary: #AE70E0;
  --color-primary-deep: #5f3284;

  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-xl: 32px;
  --radius-pill: 999px;

  --shadow-sm: 0 2px 6px -1px rgba(124, 58, 237, 0.06);
  --shadow-md: 0 3px 0 rgba(0,0,0,0.12);
  --shadow-warm: 0 12px 32px -8px rgba(255, 107, 71, 0.22);
  --shadow-mint: 0 12px 32px -8px rgba(61, 217, 199, 0.22);
  --shadow-lavender: 0 12px 32px -8px rgba(167, 139, 250, 0.22);

  --font-display: "Rubik", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, system-ui, sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root {
    --color-bg: #1A1322;
    --color-bg-soft: #251935;
    --color-surface: #2A1F3D;
    --color-text: #FAF5EE;
    --color-text-muted: #B8A8CB;
    --color-border: #3D2D54;
    --color-border-strong: #4F3B6B;
  }
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }

body {
  font-family: var(--font-display);
  background: var(--color-bg);
  color: var(--color-text);
  -webkit-font-smoothing: antialiased;
  line-height: 1.55;
  overflow-x: hidden;
  min-height: 100vh;
  position: relative;
}

body::before,
body::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.55;
  pointer-events: none;
  z-index: 0;
}
body::before {
  width: 420px; height: 420px;
  background: var(--color-mandatory-soft);
  top: -120px; right: -120px;
}
body::after {
  width: 520px; height: 520px;
  background: var(--color-regular-soft);
  top: 320px; left: -200px;
}

a { color: var(--color-primary-deep); }

.container {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 1.25rem;
  position: relative;
  z-index: 1;
}

/* ── Top bar ────────────────────────────────────────────────────────── */
.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 0;
}
.topbar__brand {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  text-decoration: none;
  color: inherit;
  font-weight: 700;
}
.topbar__brand img {
  width: 36px; height: 36px;
}
.lang {
  display: inline-flex;
  gap: 0.25rem;
  padding: 0.25rem;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-pill);
  box-shadow: var(--shadow-sm);
  font-size: 0.85rem;
}
.lang a {
  padding: 0.35rem 0.75rem;
  border-radius: var(--radius-pill);
  text-decoration: none;
  color: var(--color-text-muted);
  font-weight: 600;
}
.lang a[aria-current="page"] {
  background: var(--color-primary);
  color: white;
}

/* ── Hero ───────────────────────────────────────────────────────────── */
.hero {
  text-align: center;
  padding: 3rem 0 2.5rem;
}
.hero__icon {
  width: 96px;
  height: 96px;
  margin: 0 auto 1.25rem;
  display: block;
}
@media (min-width: 720px) {
  .hero__icon { width: 384px; height: 384px; }
}
.hero__brand {
  display: block;
  font-weight: 800;
  font-size: clamp(2.2rem, 5vw + 1rem, 3.8rem);
  line-height: 1;
  letter-spacing: -0.035em;
  margin: 0 0 1.25rem;
}
.hero__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.35rem 0.85rem;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-pill);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--color-text-muted);
  box-shadow: var(--shadow-sm);
  margin-bottom: 1.5rem;
}
.hero__eyebrow-dot {
  width: 0.5rem; height: 0.5rem;
  border-radius: 50%;
  background: var(--color-mandatory);
  box-shadow: 0 0 0 4px var(--color-mandatory-soft);
}
.hero__title {
  font-weight: 800;
  font-size: clamp(2.2rem, 5vw + 1rem, 3.8rem);
  line-height: 1.04;
  letter-spacing: -0.035em;
  margin: 0 0 1rem;
}
.hero__title em {
  font-style: italic;
  font-weight: 700;
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-mandatory) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.hero__sub {
  font-size: 1.1rem;
  color: var(--color-text-muted);
  margin: 0 auto 1.75rem;
  max-width: 40ch;
}

/* ── Store badges ───────────────────────────────────────────────────── */
.stores {
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  flex-wrap: wrap;
}
.store-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.7rem 1.15rem;
  background: #000;
  color: #fff;
  border-radius: var(--radius-md);
  text-decoration: none;
  min-width: 180px;
  box-shadow: var(--shadow-md);
  transition: transform 120ms ease;
}
.store-btn:hover { transform: translateY(-2px); }
.store-btn--soon {
  opacity: 0.6;
  cursor: not-allowed;
  pointer-events: none;
  position: relative;
}
.store-btn--soon::after {
  content: attr(data-soon);
  position: absolute;
  top: -10px;
  right: -10px;
  background: var(--color-primary);
  color: #fff;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 0.15rem 0.55rem;
  border-radius: var(--radius-pill);
  box-shadow: var(--shadow-sm);
}
.store-btn svg { flex: 0 0 auto; }
.store-btn__text {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}
.store-btn__pre {
  font-size: 0.65rem;
  opacity: 0.85;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.store-btn__name {
  font-size: 1.05rem;
  font-weight: 700;
}

/* ── Product Hunt badge ─────────────────────────────────────────────── */
.producthunt {
  display: flex;
  justify-content: center;
  margin-top: 1.25rem;
}
.producthunt img {
  display: block;
  transition: transform 120ms ease;
}
.producthunt a:hover img { transform: translateY(-2px); }

/* ── Highlights (value props) ───────────────────────────────────────── */
.highlights {
  display: grid;
  gap: 1rem;
  grid-template-columns: 1fr;
  margin: 2.5rem auto 0;
}
@media (min-width: 720px) {
  .highlights { grid-template-columns: 1fr 1fr; gap: 1.25rem; }
}

.highlight {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 1.75rem 1.5rem;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}
.highlight__badge {
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  transform: rotate(-4deg);
  margin: 0.25rem auto 0.6rem;
}
.highlight__badge svg { width: 1.4rem; height: 1.4rem; }
.highlight__badge img { width: 4.5rem; height: 4.5rem; object-fit: contain; }
.highlight h2 {
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.015em;
  margin: 0;
}
.highlight p {
  color: var(--color-text-muted);
  font-size: 0.97rem;
  margin: 0;
}
.highlight em {
  font-style: italic;
  color: var(--color-primary-deep);
  font-weight: 600;
}
.highlight--free .highlight__badge {
  transform: rotate(3deg);
}

/* ── Sign-off ───────────────────────────────────────────────────────── */
.signoff {
  margin: 2.5rem auto 0;
  text-align: center;
  font-style: italic;
  color: var(--color-text-muted);
  font-size: 1.05rem;
}

/* ── Features ───────────────────────────────────────────────────────── */
.features {
  display: grid;
  gap: 1rem;
  grid-template-columns: 1fr;
  margin: 3rem auto 0;
}
@media (min-width: 720px) {
  .features { grid-template-columns: repeat(3, 1fr); gap: 1.25rem; }
}

.feature {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 1.5rem 1.25rem 1.4rem;
  box-shadow: var(--shadow-sm);
}
.feature__badge {
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0.5rem auto 1.1rem;
  transform: rotate(-4deg);
  color: white;
}
.feature__badge svg { width: 1.4rem; height: 1.4rem; }
.feature__badge img { width: 4.5rem; height: 4.5rem; object-fit: contain; }
.feature h2 {
  font-size: 1.2rem;
  font-weight: 700;
  margin: 0 0 0.4rem;
  letter-spacing: -0.015em;
}
.feature p {
  color: var(--color-text-muted);
  font-size: 0.97rem;
  margin: 0;
}

.feature--mandatory { background: var(--color-mandatory-soft); border-color: transparent; }

.feature--regular { background: var(--color-regular-soft); border-color: transparent; }
.feature--regular .feature__badge { transform: rotate(3deg); }

.feature--optional { background: var(--color-optional-soft); border-color: transparent; }
.feature--optional .feature__badge { transform: rotate(-2deg); }

/* ── Screenshots ────────────────────────────────────────────────────── */
.shots {
  margin: 4rem auto 0;
  text-align: center;
}
.shots h2 {
  font-size: 1.6rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin: 0 0 0.4rem;
}
.shots__sub {
  color: var(--color-text-muted);
  margin: 0 0 2rem;
}
.shots__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
  justify-items: center;
}
@media (min-width: 720px) {
  .shots__grid { grid-template-columns: repeat(3, 1fr); gap: 1.5rem; align-items: start; }
}
.shot {
  margin: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  max-width: 300px;
}
.shot__caption {
  margin-top: 0.9rem;
  font-size: 0.92rem;
  line-height: 1.4;
  color: var(--color-text-muted);
  text-align: center;
  max-width: 28ch;
}
.phone {
  width: 100%;
  max-width: 300px;
  aspect-ratio: 414 / 788;
  border-radius: 36px;
  background: var(--color-surface);
  border: 8px solid var(--color-text);
  box-shadow: var(--shadow-md);
  overflow: hidden;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}
.phone img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.phone__placeholder {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-text-muted);
  font-size: 0.85rem;
  padding: 1rem;
  text-align: center;
  background: linear-gradient(180deg, var(--color-bg) 0%, var(--color-bg-soft) 100%);
}

/* ── CTA strip ──────────────────────────────────────────────────────── */
.cta-strip {
  margin: 4rem auto 0;
  padding: 2.5rem 1.5rem;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  text-align: center;
  box-shadow: var(--shadow-sm);
}
.cta-strip h2 {
  font-size: 1.6rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin: 0 0 0.5rem;
}
.cta-strip p {
  color: var(--color-text-muted);
  margin: 0 0 1.5rem;
}

/* ── Prose (privacy page) ───────────────────────────────────────────── */
.prose {
  max-width: 680px;
  margin: 2.5rem auto 4rem;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 2rem 1.75rem;
  box-shadow: var(--shadow-sm);
}
.prose h1 {
  font-size: clamp(1.8rem, 3.5vw + 0.5rem, 2.4rem);
  font-weight: 800;
  letter-spacing: -0.025em;
  margin: 0 0 1rem;
}
.prose h2 {
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  margin: 1.75rem 0 0.6rem;
}
.prose h3 {
  font-size: 1.05rem;
  font-weight: 700;
  margin: 1.25rem 0 0.5rem;
}
.prose p {
  margin: 0 0 0.85rem;
  color: var(--color-text);
}
.prose ul {
  margin: 0 0 0.85rem;
  padding-left: 1.25rem;
}
.prose li { margin-bottom: 0.3rem; }
.prose hr {
  border: 0;
  border-top: 1px solid var(--color-border);
  margin: 2rem 0;
}
.prose a {
  color: var(--color-primary-deep);
  text-decoration: underline;
}
.prose code {
  background: var(--color-bg-soft);
  padding: 0.05em 0.35em;
  border-radius: 4px;
  font-size: 0.92em;
}
.prose table {
  width: 100%;
  border-collapse: collapse;
  margin: 0.5rem 0 1rem;
  font-size: 0.95rem;
}
.prose th,
.prose td {
  text-align: left;
  padding: 0.5rem 0.6rem;
  border-bottom: 1px solid var(--color-border);
}
.prose th { font-weight: 700; background: var(--color-bg-soft); }

/* ── Footer ─────────────────────────────────────────────────────────── */
footer {
  margin: 3rem auto 2rem;
  text-align: center;
  color: var(--color-text-muted);
  font-size: 0.85rem;
}
footer a {
  color: inherit;
  text-decoration: none;
  margin: 0 0.5rem;
}
footer a:hover { color: var(--color-primary-deep); }
.footer__badge {
  margin-bottom: 1.25rem;
}
.footer__badge img {
  display: inline-block;
  vertical-align: middle;
}

/* Blog */
.topbar__blog {
  margin-left: auto;
  margin-right: 1rem;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--color-text);
  text-decoration: none;
}
.topbar__blog:hover { text-decoration: underline; }
.blog-post__back { margin: 0 0 1.25rem; font-size: 0.9rem; }
.blog-post__back a { text-decoration: none; }
.blog-post__meta {
  color: var(--color-text-muted, #6b7280);
  font-size: 0.9rem;
  margin: -0.5rem 0 1.5rem;
}
.blog-post blockquote {
  margin: 1rem 0;
  padding: 0.25rem 1rem;
  border-left: 3px solid var(--color-border);
  color: var(--color-text-muted, #6b7280);
}
.blog-post hr { border: 0; border-top: 1px solid var(--color-border); margin: 1.75rem 0; }
.blog-card { padding: 1.25rem 0; border-top: 1px solid var(--color-border); }
.blog-card:first-of-type { border-top: 0; }
.blog-card h2 { margin: 0 0 0.4rem; }
.blog-card h2 a { text-decoration: none; color: inherit; }
.blog-card h2 a:hover { text-decoration: underline; }
.blog-card__more { margin: 0.4rem 0 0; font-weight: 600; }
.blog-card__more a { text-decoration: none; }

