/* LeadSheets website — plain CSS, no framework */

:root {
  --bg: #f5f7fb;
  --bg-alt: #ffffff;
  --surface: #ffffff;
  --line: #dbe2ee;
  --text: #0d1a33;
  --muted: #55647f;
  --accent: #0a8ea3;
  --accent-strong: #067587;
  --accent-soft: #e0f6f9;
  --hero-bg: #0a1428;
  --hero-text: #e8eef8;
  --hero-muted: #9aaccb;
  --glow: #45e3f2;
  --radius: 14px;
  --maxw: 1080px;
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0a1428;
    --bg-alt: #0d1930;
    --surface: #111f3a;
    --line: #22325a;
    --text: #e8eef8;
    --muted: #9aaccb;
    --accent: #45e3f2;
    --accent-strong: #7cecf6;
    --accent-soft: #10304a;
  }
}

* { box-sizing: border-box; }

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 17px/1.6 -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

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

a { color: var(--accent); text-decoration-thickness: 1px; text-underline-offset: 2px; }
a:hover { color: var(--accent-strong); }

h1, h2, h3 { line-height: 1.2; letter-spacing: -0.01em; text-wrap: balance; }
h1 { font-size: clamp(2rem, 5vw, 3.2rem); margin: 0 0 .4em; }
h2 { font-size: clamp(1.5rem, 3vw, 2rem); margin: 0 0 .6em; }
h3 { font-size: 1.15rem; margin: 1.6em 0 .4em; }
p { margin: 0 0 1em; }

.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 20px; }
.narrow { max-width: 760px; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 10;
  background: rgba(10, 20, 40, .92);
  backdrop-filter: saturate(160%) blur(12px);
  -webkit-backdrop-filter: saturate(160%) blur(12px);
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; height: 60px; }
.brand { display: flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; font-weight: 650; font-size: 1.05rem; }
.brand img { width: 30px; height: 30px; border-radius: 7px; }
.brand:hover { color: #fff; }
.nav { display: flex; gap: 4px; flex-wrap: nowrap; }
.nav a {
  color: #c4d1e8; text-decoration: none; font-size: .95rem;
  padding: 6px 10px; border-radius: 8px; white-space: nowrap;
}
.nav a:hover { color: #fff; background: rgba(255,255,255,.07); }
.nav a[aria-current="page"] { color: var(--glow); }

.menu-toggle { display: none; }

@media (max-width: 640px) {
  .menu-toggle {
    display: block; background: none; border: 0; color: #fff; padding: 8px; cursor: pointer;
  }
  .nav {
    display: none; position: absolute; top: 60px; left: 0; right: 0;
    flex-direction: column; background: #0a1428; padding: 8px 12px 14px;
    border-bottom: 1px solid rgba(255,255,255,.08);
  }
  .nav.open { display: flex; }
  .nav a { padding: 10px 12px; }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 12px 20px; border-radius: 999px; font-weight: 600; text-decoration: none;
  border: 1px solid transparent; font-size: 1rem;
}
.btn-primary { background: var(--glow); color: #04202a; }
.btn-primary:hover { background: #8af0f8; color: #04202a; }
.btn-ghost { border-color: rgba(255,255,255,.25); color: #e8eef8; }
.btn-ghost:hover { border-color: var(--glow); color: #fff; }
.btn-row { display: flex; gap: 12px; flex-wrap: wrap; }

/* ---------- Hero ---------- */
.hero {
  background:
    radial-gradient(ellipse 60% 70% at 80% 30%, rgba(69,227,242,.14), transparent 70%),
    var(--hero-bg);
  color: var(--hero-text);
  padding: 72px 0 80px;
  overflow: hidden;
}
.hero .wrap { display: grid; grid-template-columns: 1.1fr .9fr; gap: 48px; align-items: center; }
.hero .eyebrow { color: var(--glow); font-weight: 600; letter-spacing: .06em; text-transform: uppercase; font-size: .8rem; margin-bottom: 12px; }
.hero p.lead { color: var(--hero-muted); font-size: 1.2rem; max-width: 34em; margin-bottom: 28px; }
.hero-icon { width: 104px; height: 104px; border-radius: 24px; margin-bottom: 24px; box-shadow: 0 10px 40px rgba(69,227,242,.25); }

/* Chord-chart illustration (pure HTML, no screenshot needed) */
.chart-card {
  background: #fdfcf8; color: #1a1a1a; border-radius: 16px;
  padding: 26px 26px 22px; box-shadow: 0 30px 80px rgba(0,0,0,.45);
  font-family: "SF Mono", ui-monospace, Menlo, Consolas, monospace; font-size: .92rem; line-height: 1.25;
  transform: rotate(1.5deg);
}
.chart-card .t { font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; font-weight: 700; font-size: 1.1rem; margin-bottom: 2px; }
.chart-card .a { font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; color: #666; font-size: .85rem; margin-bottom: 14px; }
.chart-card .sec { display: inline-block; border: 1.5px solid #1a1a1a; padding: 1px 6px; font-family: -apple-system, sans-serif; font-weight: 700; font-size: .75rem; margin: 10px 0 6px; }
.chart-card .ch { color: #0a7f92; font-weight: 700; white-space: pre; }
.chart-card .ly { white-space: pre; margin-bottom: 6px; }
.chart-card .rep { color: #e07a00; font-weight: 700; }
.chart-card .grid { display: grid; grid-template-columns: repeat(4, 1fr); border-left: 2px solid #1a1a1a; margin-top: 4px; }
.chart-card .grid span { border-right: 2px solid #1a1a1a; padding: 4px 8px; color: #0a7f92; font-weight: 700; }

@media (max-width: 820px) {
  .hero { padding: 48px 0 56px; }
  .hero .wrap { grid-template-columns: 1fr; gap: 40px; }
  .chart-card { transform: none; }
}

/* ---------- Sections ---------- */
section { padding: 72px 0; }
section.alt { background: var(--bg-alt); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.section-intro { color: var(--muted); font-size: 1.1rem; max-width: 40em; margin-bottom: 36px; }

.features { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 18px; }
.feature {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 22px 22px 18px;
}
.feature h3 { margin: 10px 0 6px; }
.feature p { color: var(--muted); margin: 0; font-size: .97rem; }
.feature .ico {
  width: 40px; height: 40px; border-radius: 10px; background: var(--accent-soft); color: var(--accent);
  display: grid; place-items: center;
}
.feature .ico svg { width: 22px; height: 22px; }
.badge-new {
  display: inline-block; font-size: .7rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase;
  color: var(--accent); background: var(--accent-soft); border-radius: 999px; padding: 2px 8px; vertical-align: 2px; margin-left: 4px;
}

.whatsnew { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 14px 28px; list-style: none; padding: 0; margin: 0; }
.whatsnew li { border-left: 3px solid var(--accent); padding: 2px 0 2px 14px; }
.whatsnew strong { display: block; }
.whatsnew span { color: var(--muted); font-size: .95rem; }

.platforms { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 24px; }
.platforms span { border: 1px solid rgba(255,255,255,.2); border-radius: 999px; padding: 4px 12px; font-size: .85rem; color: var(--hero-muted); }

/* Screenshots */
.shots { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 18px; }
.shots figure { margin: 0; }
.shots img { border-radius: 12px; border: 1px solid var(--line); display: block; }
.shots figcaption { color: var(--muted); font-size: .9rem; margin-top: 8px; }

.cta { text-align: center; }
.cta .btn-row { justify-content: center; }
.cta .btn-ghost { border-color: var(--line); color: var(--text); }

/* ---------- Page header (inner pages) ---------- */
.page-head { background: var(--hero-bg); color: var(--hero-text); padding: 48px 0 40px; }
.page-head p { color: var(--hero-muted); margin: 0; font-size: 1.1rem; }

/* ---------- Manual ---------- */
.manual-layout { display: grid; grid-template-columns: 230px 1fr; gap: 48px; padding: 48px 20px 80px; }
.toc { position: sticky; top: 84px; align-self: start; font-size: .93rem; }
.toc p { font-weight: 700; color: var(--muted); text-transform: uppercase; font-size: .75rem; letter-spacing: .06em; margin-bottom: 8px; }
.toc ol { list-style: none; padding: 0; margin: 0; }
.toc a { display: block; padding: 5px 10px; border-radius: 8px; color: var(--text); text-decoration: none; }
.toc a:hover { background: var(--accent-soft); color: var(--accent); }

.doc { min-width: 0; }
.doc h2 { margin-top: 2.2em; padding-top: 1em; border-top: 1px solid var(--line); scroll-margin-top: 80px; }
.doc h2:first-child { margin-top: 0; padding-top: 0; border-top: 0; }
.doc h3 { scroll-margin-top: 80px; }
.doc ul, .doc ol { padding-left: 1.3em; }
.doc li { margin-bottom: .4em; }
.doc .new { color: var(--accent); font-weight: 600; font-size: .85em; }
.note { background: var(--accent-soft); border-radius: var(--radius); padding: 14px 18px; }

.table-wrap { overflow-x: auto; margin: 0 0 1.2em; border: 1px solid var(--line); border-radius: 10px; }
table { border-collapse: collapse; width: 100%; font-size: .95rem; }
th, td { text-align: left; padding: 8px 14px; border-bottom: 1px solid var(--line); vertical-align: top; }
tr:last-child td { border-bottom: 0; }
th { background: var(--bg-alt); font-weight: 650; }
td:first-child, td.k { white-space: nowrap; }
kbd {
  font-family: "SF Mono", ui-monospace, Menlo, monospace; font-size: .85em;
  background: var(--bg-alt); border: 1px solid var(--line); border-bottom-width: 2px; border-radius: 5px; padding: 1px 6px;
}

@media (max-width: 820px) {
  .manual-layout { grid-template-columns: 1fr; gap: 24px; padding-top: 28px; }
  .toc { position: static; border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; }
}

/* ---------- Prose pages ---------- */
.prose { padding: 48px 20px 80px; }
.prose h2 { margin-top: 1.8em; font-size: 1.35rem; }

.contact-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 16px; margin: 8px 0 32px; }
.contact-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }
.contact-card h3 { margin: 0 0 6px; }
.contact-card p { color: var(--muted); font-size: .95rem; }

details { border: 1px solid var(--line); border-radius: 10px; padding: 12px 16px; margin-bottom: 10px; background: var(--surface); }
summary { cursor: pointer; font-weight: 600; }
details p { margin: 10px 0 0; color: var(--muted); }

/* ---------- Footer ---------- */
.site-footer { background: var(--hero-bg); color: var(--hero-muted); padding: 36px 0; font-size: .9rem; }
.site-footer .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px; }
.site-footer a { color: var(--hero-text); text-decoration: none; }
.site-footer a:hover { color: var(--glow); }
.site-footer nav { display: flex; gap: 18px; flex-wrap: wrap; }

/* Inline app icons in the manual */
.doc .i {
  display: inline-block; color: var(--accent); margin: 0 2px;
  /* size and alignment are set per icon, in em, on each icon in manual.html */
}

/* Hero screenshot */
.hero-shot {
  display: block; width: 100%; height: auto;
  background: #fff; padding: 10px; border-radius: 18px;
  box-shadow: 0 30px 80px rgba(0,0,0,.45);
  transform: rotate(1deg);
}
@media (max-width: 820px) { .hero-shot { transform: none; padding: 6px; border-radius: 12px; } }

/* Hero screenshots: two images that cross-fade */
.hero-slides { display: grid; }
.hero-slides img {
  grid-area: 1 / 1; width: 100%; height: 100%;
  object-fit: contain; object-position: center top; background: #fff;
}
.hero-slides img + img { animation: hero-fade 10s ease-in-out infinite; }
@keyframes hero-fade {
  0%, 40%  { opacity: 0; }
  50%, 90% { opacity: 1; }
  100%     { opacity: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .hero-slides img + img { animation: none; opacity: 0; }
}

/* ChordPro+ examples */
.doc h4 { margin: 1.2em 0 .4em; font-size: 1rem; }
.doc code, .doc pre.code { font-family: "SF Mono", ui-monospace, Menlo, Consolas, monospace; font-size: .88em; }
.doc code { background: var(--bg-alt); border: 1px solid var(--line); border-radius: 5px; padding: 0 5px; white-space: nowrap; }
.doc pre.code { background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 14px 16px; overflow-x: auto; line-height: 1.6; margin: 0 0 1.2em; }
.c-chd { color: #c2410c; font-weight: 700; }
.c-com { color: #ea8a1a; font-style: italic; }
.c-drm { color: #16a34a; font-weight: 700; }
.c-hid { color: var(--muted); font-style: italic; }

/* ChordPro+ results per view */
.views { display: grid; grid-template-columns: 1fr; gap: 14px; margin: 0 0 1em; }
.view { margin: 0; }
.view figcaption { font-weight: 650; font-size: .95rem; margin-bottom: 6px; }
.view figcaption .i { color: var(--accent); }
.sheet { background: #fff; color: #1d1d1f; border: 1px solid var(--line); border-radius: 10px; padding: 12px 0 14px; overflow-x: auto; }
.sh-sec { background: #edf2f7; color: #1e3a6e; font-weight: 700; font-size: .85rem; letter-spacing: .02em; padding: 5px 16px; margin-bottom: 10px; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; }
.sheet pre.sh { margin: 0; padding: 0 16px 0 28px; font-family: "SF Mono", ui-monospace, Menlo, Consolas, monospace; font-size: .82rem; line-height: 1.5; color: #1d1d1f; }
.sh .g { color: #a3261c; font-weight: 700; }
.sh .c { color: #1e3a6e; font-weight: 700; }
.sh .x { color: #ea8a1a; font-weight: 900; }
.sh .n { color: #ea8a1a; font-weight: 700; font-style: italic; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; }
.sh .d { color: #16a34a; font-weight: 700; }
.sh .sp { line-height: .6; }
.small-note { color: var(--muted); font-size: .93rem; }
.sh .ts { display: inline-block; width: 2ch; }
