/* Bujit's website (GitHub Pages, served from this repo's root): shared look for every
   page. Colors come from the logo (site-assets/bujit-logo.svg): its pink background
   (the header, so the logo sits in it seamlessly), the snout's hot-pink rim for
   buttons and links, with light and dark versions. */

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

:root {
  --logo-bg:     #F495B7;   /* the logo's background */
  --brand:       #DB1867;   /* the snout's rim: buttons (white text, 4.8:1) */
  --header-bg:   var(--logo-bg);
  --header-ink:  #4A0B26;
  --accent:      #C2185B;
  --accent-soft: #FCE4EE;
  --bg:          #FFF7FA;
  --surface:     #FFFFFF;
  --surface-2:   #FDEEF4;
  --ink:         #24121B;
  --ink-2:       #6B4A58;
  --border:      #F3D3E0;
  --code-bg:     #FBEAF1;
  --opt-fg:      #8A5A12;
  --opt-bg:      #FBF3E4;
  --term-bg:     #2A0F1C;
  --term-text:   #F6D9E5;
  --term-tag:    #F495B7;
  --term-opt:    #E3B95A;
  --term-comment:#9A6A80;
  --term-comma:  #7A4A60;
  --radius:      12px;
  --mono: ui-monospace, 'SF Mono', 'Cascadia Code', Consolas, 'Courier New', monospace;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --header-bg:   #3A1426;
    --header-ink:  #FCE4EE;
    --accent:      #F495B7;
    --accent-soft: #3A1C29;
    --bg:          #1A1015;
    --surface:     #24161D;
    --surface-2:   #2E1C25;
    --ink:         #F6E9EF;
    --ink-2:       #C4A6B3;
    --border:      #3F2833;
    --code-bg:     #33202A;
    --opt-fg:      #E3B95A;
    --opt-bg:      #3A2E14;
    --term-bg:     #12080D;
    color-scheme: dark;
  }
}

html { -webkit-text-size-adjust: 100%; }

body {
  font-family: system-ui, -apple-system, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.65;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

a { color: var(--accent); }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 4px; }

code {
  font-family: var(--mono);
  font-size: 0.88em;
  background: var(--code-bg);
  padding: 0.1em 0.35em;
  border-radius: 4px;
}

/* ── Site header (every page) ─────────────────────────────── */
.site-header {
  background: var(--header-bg);
  color: var(--header-ink);
}
.site-header .bar {
  max-width: 880px;
  margin: 0 auto;
  padding: 0.5rem 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.5rem 1.25rem;
}
.brand { display: flex; align-items: center; }
.brand img { height: 60px; width: auto; display: block;
             /* the logo's thin rim fades at this size: a soft outline keeps it crisp */
             filter: drop-shadow(0 0 1px rgba(219, 24, 103, 0.7)) drop-shadow(0 2px 4px rgba(120, 10, 55, 0.18)); }
.site-nav { display: flex; flex-wrap: wrap; gap: 0.25rem; }
.site-nav a {
  color: var(--header-ink);
  opacity: 0.85;
  text-decoration: none;
  font-size: 0.875rem;
  padding: 0.35rem 0.65rem;
  border-radius: 999px;
}
.site-nav a:hover { background: rgba(255, 255, 255, 0.25); opacity: 1; }
.site-nav a[aria-current="page"] { background: rgba(255, 255, 255, 0.4); opacity: 1; font-weight: 600; }
@media (prefers-color-scheme: dark) {
  .site-nav a:hover { background: rgba(244, 149, 183, 0.16); }
  .site-nav a[aria-current="page"] { background: rgba(244, 149, 183, 0.26); }
}

/* ── Page body ────────────────────────────────────────────── */
main {
  flex: 1;
  width: 100%;
  max-width: 880px;
  margin: 0 auto;
  padding: 2.5rem 16px 4rem;
}
main.narrow { max-width: 760px; }

.page-title { font-size: 2rem; line-height: 1.2; letter-spacing: -0.02em; margin-bottom: 0.35rem; }
.page-meta { color: var(--ink-2); font-size: 0.9rem; margin-bottom: 2rem; }
.lead { font-size: 1.05rem; color: var(--ink-2); margin-bottom: 1.5rem; }

/* Long-form pages (privacy policy, data deletion) */
.doc h2 { font-size: 1.15rem; margin: 2.2rem 0 0.5rem; letter-spacing: -0.01em; }
.doc p { margin-bottom: 0.85rem; }
.doc ol, .doc ul { margin: 0.25rem 0 0.85rem 1.4rem; }
.doc li { margin-bottom: 0.35rem; }

.section-label {
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-weight: 700;
  color: var(--ink-2);
  margin: 2.5rem 0 0.9rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.section-label::after { content: ''; flex: 1; height: 1px; background: var(--border); }

.note {
  margin: 2rem 0 0;
  padding: 0.9rem 1.1rem;
  border-left: 4px solid var(--accent);
  background: var(--accent-soft);
  border-radius: 0 8px 8px 0;
  font-size: 0.9rem;
}

/* ── Buttons ──────────────────────────────────────────────── */
.button {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.7rem 1.15rem;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  background: var(--brand);
  color: #fff;
  border: 1px solid transparent;
}
.button:hover { filter: brightness(1.12); }
.button.secondary { background: var(--surface); color: var(--accent); border-color: var(--border); }
.button-row { display: flex; flex-wrap: wrap; gap: 0.75rem; margin: 1.25rem 0 0; }

/* ── Home page ────────────────────────────────────────────── */
.hero { text-align: center; padding: 1rem 0 0.5rem; }
.hero img { width: 220px; height: 220px; border-radius: 48px; display: block; margin: 0 auto;
            box-shadow: 0 12px 32px rgba(219, 24, 103, 0.28); }
.hero h1 { font-size: 2.4rem; letter-spacing: -0.03em; margin-top: 1.4rem; line-height: 1.15; }
.hero .tagline { font-size: 1.15rem; color: var(--ink-2); max-width: 30rem; margin: 0.4rem auto 0; }
.hero .button-row { justify-content: center; }

.features {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.9rem;
  margin-top: 2.5rem;
}
.feature {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.1rem 1.2rem;
}
.feature h3 { font-size: 1rem; margin-bottom: 0.25rem; }
.feature p { font-size: 0.9rem; color: var(--ink-2); }

.card-group {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--surface);
}
.card-row {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem 1.2rem;
  text-decoration: none;
  color: inherit;
  border-bottom: 1px solid var(--border);
}
.card-row:last-child { border-bottom: none; }
.card-row:hover { background: var(--surface-2); }
.card-icon {
  width: 40px; height: 40px; flex-shrink: 0;
  border-radius: 10px;
  background: var(--accent-soft);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.2rem;
}
.card-text { flex: 1; min-width: 0; }
.card-title { font-weight: 600; }
.card-desc { font-size: 0.85rem; color: var(--ink-2); }
.card-chevron { color: var(--ink-2); font-size: 1.2rem; }

/* ── Support page: FAQ and the embedded Google Forms ──────── */
.faq { border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); overflow: hidden; }
.faq details { border-bottom: 1px solid var(--border); }
.faq details:last-child { border-bottom: none; }
.faq summary {
  cursor: pointer;
  list-style: none;
  padding: 0.95rem 2.6rem 0.95rem 1.2rem;
  font-weight: 600;
  position: relative;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: '+';
  position: absolute; right: 1.2rem; top: 50%; transform: translateY(-50%);
  font-size: 1.3rem; font-weight: 400; color: var(--accent);
}
.faq details[open] summary::after { content: '−'; }
.faq summary:hover { background: var(--surface-2); }
.faq details p { padding: 0 1.2rem 1rem; color: var(--ink-2); font-size: 0.95rem; }

.form-tabs { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-bottom: 1rem; }
.form-tabs button {
  font: inherit; font-size: 0.92rem; font-weight: 600;
  padding: 0.55rem 1rem;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--ink);
  cursor: pointer;
}
.form-tabs button:hover { background: var(--surface-2); }
.form-tabs button[aria-selected="true"] { background: var(--brand); border-color: var(--brand); color: #fff; }
.form-panel { margin-bottom: 1.5rem; }
.form-panel iframe {
  display: block; width: 100%; border: 0;
  border-radius: var(--radius);
  background: #fff;   /* Google Forms are light-only; keep them on white in dark mode too */
}
.form-fallback { font-size: 0.85rem; color: var(--ink-2); margin-top: 0.5rem; }

/* ── Site footer (every page) ─────────────────────────────── */
.site-footer {
  border-top: 1px solid var(--border);
  background: var(--surface);
  color: var(--ink-2);
  font-size: 0.82rem;
}
.site-footer .bar {
  max-width: 880px;
  margin: 0 auto;
  padding: 1.5rem 16px 2rem;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}
.site-footer .links { display: flex; flex-wrap: wrap; gap: 0.4rem 1.2rem; }
.site-footer a { color: var(--ink-2); text-decoration: none; }
.site-footer a:hover { color: var(--accent); text-decoration: underline; }

@media (max-width: 600px) {
  .page-title { font-size: 1.6rem; }
  .hero h1 { font-size: 1.9rem; }
  .hero img { width: 180px; height: 180px; border-radius: 40px; }
  .brand img { height: 50px; }
  .features { grid-template-columns: 1fr; }
}
