/* ClearNote — clearnote.app
 *
 * One stylesheet. No framework, no webfont, no third-party request of any kind — the privacy
 * page says the site has none, and that has to stay true.
 *
 * The display face is `ui-serif`, which is New York on Apple platforms and Georgia elsewhere.
 * ClearNote's readers are, by definition, Mac and iPhone users, so the typography they see is
 * a real editorial serif that costs nothing to load. Body text stays in the system sans, which
 * is what the app itself uses.
 */

:root {
  --paper:      #FBFAF7;
  --paper-warm: #F4F0E9;
  --card:       #FFFFFF;
  --ink:        #141A19;
  --ink-2:      #4A5A58;
  --ink-3:      #5F6E6C;
  --petrol:     #1B4A5A;
  --petrol-2:   #12333E;
  /* The dark band's field. Fixed in both themes: `--petrol` is the *accent*, and it flips to
     a light blue in dark mode, which would turn the band light-on-light. */
  --field:      #1B4A5A;
  --field-2:    #0F2C36;
  --on-petrol:  #EAF2F4;
  --on-petrol-2:#9FBDC7;
  --rule:       rgba(20, 26, 25, 0.10);
  --rule-soft:  rgba(20, 26, 25, 0.06);
  --shadow:     0 1px 2px rgba(18, 51, 62, .05), 0 18px 44px -14px rgba(18, 51, 62, .22);

  --serif: ui-serif, "New York", "Iowan Old Style", Georgia, "Times New Roman", serif;
  --sans: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto,
          "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, monospace;

  --wrap: 68rem;
  --measure: 34rem;
  --radius: 14px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper:      #0F1416;
    --paper-warm: #141B1E;
    --card:       #171F22;
    --ink:        #E9EDEC;
    --ink-2:      #A9B6B4;
    --ink-3:      #7B8C8A;
    --petrol:     #7FC7D9;
    --petrol-2:   #0B2229;
    --field:      #163D4A;
    --field-2:    #0A2028;
    --on-petrol:  #EAF2F4;
    --on-petrol-2:#9FBDC7;
    --rule:       rgba(233, 237, 236, 0.13);
    --rule-soft:  rgba(233, 237, 236, 0.07);
    --shadow:     0 1px 2px rgba(0,0,0,.4), 0 24px 60px -18px rgba(0,0,0,.6);
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 17px/1.62 var(--sans);
  font-feature-settings: "kern", "liga";
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

.wrap { width: min(var(--wrap), 100% - 2.75rem); margin-inline: auto; }
.narrow { max-width: var(--measure); }

.skip { position: absolute; left: -9999px; }
.skip:focus {
  left: 0; top: 0; z-index: 20;
  background: var(--petrol); color: var(--paper);
  padding: .7rem 1.1rem; border-radius: 0 0 var(--radius) 0;
}

/* ── Header ─────────────────────────────────────────────────────────────────────────── */

.site-header {
  position: sticky; top: 0; z-index: 10;
  border-bottom: 1px solid var(--rule-soft);
  background: color-mix(in srgb, var(--paper) 86%, transparent);
  backdrop-filter: saturate(180%) blur(16px);
  -webkit-backdrop-filter: saturate(180%) blur(16px);
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1.5rem; padding: .9rem 0; flex-wrap: wrap;
}
.wordmark {
  display: inline-flex; align-items: baseline; gap: .48rem;
  color: var(--ink); text-decoration: none;
}
.wordmark svg { width: 1.06em; height: 1.06em; color: var(--petrol); align-self: center; flex: none; }
.wordmark span {
  font: 400 1.4rem/1 var(--serif);
  letter-spacing: -0.014em;
}
.site-header nav { display: flex; gap: 1.4rem; flex-wrap: wrap; align-items: center; }
.site-header nav a {
  color: var(--ink-2); text-decoration: none; font-size: .93rem;
  padding-bottom: 3px; border-bottom: 1.5px solid transparent;
}
.site-header nav a:hover { color: var(--ink); }
.site-header nav a[aria-current="page"] { color: var(--ink); border-bottom-color: var(--petrol); }

/* ── Type ───────────────────────────────────────────────────────────────────────────── */

h1, h2, .display {
  font-family: var(--serif); font-weight: 400;
  letter-spacing: -0.021em; line-height: 1.08; margin: 0;
}
h1 { font-size: clamp(2.55rem, 1.5rem + 4.4vw, 4.3rem); }
h2 { font-size: clamp(1.7rem, 1.25rem + 1.8vw, 2.45rem); line-height: 1.14; margin: 0 0 .6rem; }
h3 {
  font: 600 1.02rem/1.4 var(--sans); letter-spacing: -0.006em;
  margin: 0 0 .3rem; color: var(--ink);
}
p { margin: 1rem 0; max-width: var(--measure); color: var(--ink-2); }
h2 + p, h3 + p { margin-top: .4rem; }
strong { color: var(--ink); font-weight: 600; }
em { font-style: italic; }
a { color: var(--petrol); text-underline-offset: 2px; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
code {
  font-family: var(--mono); font-size: .86em;
  background: color-mix(in srgb, var(--petrol) 10%, transparent);
  padding: .1em .36em; border-radius: 4px; color: var(--ink);
}
pre {
  background: var(--card); border: 1px solid var(--rule);
  border-radius: var(--radius); padding: 1.05rem 1.2rem;
  overflow-x: auto; font-size: .82rem; line-height: 1.6; max-width: 100%;
}
pre code { background: none; padding: 0; font-size: inherit; }

.eyebrow {
  font: 600 .74rem/1 var(--sans); letter-spacing: .13em; text-transform: uppercase;
  color: var(--ink-3); margin: 0 0 1.15rem; max-width: none;
}
.lede {
  font-size: clamp(1.08rem, 1rem + 0.4vw, 1.26rem);
  color: var(--ink-2); max-width: 42ch; margin-top: 1.35rem;
}

/* ── Sections ───────────────────────────────────────────────────────────────────────── */

section { padding: clamp(2.8rem, 5vw, 4.6rem) 0; }
section + section { border-top: 1px solid var(--rule-soft); }
section.warm { background: var(--paper-warm); border-top-color: transparent; }
section.warm + section { border-top-color: transparent; }
section.dark {
  background: linear-gradient(160deg, var(--field) 0%, var(--field-2) 100%);
  color: var(--on-petrol); border-top: none;
}
section.dark p { color: var(--on-petrol-2); }
section.dark strong { color: var(--on-petrol); }
section.dark a { color: #fff; }
section.dark .eyebrow { color: var(--on-petrol-2); }

.hero { padding: clamp(3.2rem, 8vw, 6rem) 0 0; border-top: none; }
/* The line breaks in the hero are deliberate, so the heading needs room for its
   longest line rather than a character-count cap that would rewrap it. */
.hero h1 { max-width: none; text-wrap: pretty; }
.hero-shot { margin-top: clamp(2.6rem, 5vw, 4rem); }

.actions { display: flex; gap: .7rem; flex-wrap: wrap; margin-top: 2rem; max-width: none; }
.button {
  display: inline-block; padding: .68rem 1.3rem; border-radius: 999px;
  background: var(--petrol); color: var(--paper); text-decoration: none;
  font: 550 .95rem/1.35 var(--sans); border: 1px solid var(--petrol);
}
.button:hover { filter: brightness(1.1); text-decoration: none; }
.button.ghost { background: transparent; color: var(--petrol); }
.button.ghost:hover { background: color-mix(in srgb, var(--petrol) 9%, transparent); filter: none; }
section.dark .button { background: var(--on-petrol); color: var(--field-2); border-color: var(--on-petrol); }
section.dark .button.ghost { background: transparent; color: var(--on-petrol); }

/* ── Screenshots ────────────────────────────────────────────────────────────────────── */

.shot { margin: 0; }
.shot picture { display: block; }
.shot img {
  display: block; width: 100%; height: auto;
  border-radius: 11px; filter: drop-shadow(0 24px 48px rgba(18, 51, 62, .20));
}
@media (prefers-color-scheme: dark) {
  .shot picture { display: block; }
.shot img { filter: drop-shadow(0 24px 56px rgba(0, 0, 0, .65)); }
}
.shot figcaption {
  font: .82rem/1.5 var(--sans); color: var(--ink-3);
  margin-top: .85rem; text-align: center;
}
.shot.phone img { max-width: 260px; margin-inline: auto; border-radius: 26px; }

/* ── Feature rows ───────────────────────────────────────────────────────────────────── */

.rows { display: grid; gap: clamp(2.4rem, 4vw, 3.6rem); }
.row {
  display: grid; gap: clamp(1.4rem, 3vw, 3rem); align-items: center;
  grid-template-columns: 1fr;
}
@media (min-width: 62rem) {
  .row { grid-template-columns: minmax(0, 0.86fr) minmax(0, 1.14fr); }
  .row.reverse > :first-child { order: 2; }
}
.row .prose p { max-width: 38ch; }
.row h2 { font-size: clamp(1.45rem, 1.2rem + 1vw, 2rem); }

/* ── Cards and lists ────────────────────────────────────────────────────────────────── */

.grid {
  display: grid; margin-top: 2.2rem;
  column-gap: clamp(1.6rem, 3vw, 2.8rem); row-gap: 2rem;
  grid-template-columns: repeat(auto-fit, minmax(14rem, 1fr));
}
.grid > div { border-top: 1px solid var(--rule); padding-top: .95rem; }
.grid p { margin: 0; font-size: .93rem; max-width: none; }

.promises { display: grid; gap: clamp(1.8rem, 3vw, 3rem); margin-top: 2.2rem;
            grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr)); }
.promises h3 { font: 400 1.32rem/1.2 var(--serif); letter-spacing: -0.014em; margin-bottom: .4rem; }
.promises p { margin: 0; font-size: .95rem; max-width: none; }

.steps { counter-reset: step; list-style: none; padding: 0; margin: 1.6rem 0; max-width: var(--measure); }
.steps li {
  counter-increment: step; display: grid; grid-template-columns: 1.8rem 1fr;
  gap: .15rem .95rem; padding: .8rem 0; border-top: 1px solid var(--rule-soft);
}
.steps li::before {
  content: counter(step); grid-row: span 2;
  width: 1.8rem; height: 1.8rem; border-radius: 50%;
  background: color-mix(in srgb, var(--petrol) 12%, transparent); color: var(--petrol);
  display: grid; place-items: center; font: 650 .8rem/1 var(--sans);
}
.steps strong { font-weight: 600; }
.steps span { color: var(--ink-2); font-size: .95rem; }

.checks { list-style: none; padding: 0; margin: 1.2rem 0; max-width: var(--measure); }
.checks li { position: relative; padding-left: 1.55rem; margin: .6rem 0; color: var(--ink-2); }
.checks li::before {
  content: ""; position: absolute; left: .3rem; top: .66em;
  width: .4rem; height: .4rem; border-radius: 50%; background: var(--petrol);
}

.note {
  font-size: .93rem; color: var(--ink-2);
  border-left: 2px solid var(--petrol); padding-left: 1rem; margin: 1.5rem 0;
}
section.dark .note { border-left-color: var(--on-petrol-2); }

.statement {
  font: 400 clamp(1.4rem, 1.05rem + 1.5vw, 2.1rem)/1.32 var(--serif);
  letter-spacing: -0.017em; max-width: 26ch; color: var(--on-petrol);
}
.statement-grid { display: grid; gap: clamp(1.6rem, 4vw, 3.4rem); align-items: start;
                  grid-template-columns: 1fr; }
@media (min-width: 56rem) { .statement-grid { grid-template-columns: 1fr 1fr; } }

.spec { width: 100%; border-collapse: collapse; margin-top: 1.4rem; font-size: .93rem; }
.spec th, .spec td { text-align: left; padding: .62rem 0; border-bottom: 1px solid var(--rule-soft); }
.spec th { font-weight: 500; color: var(--ink-2); width: 45%; }
.spec td { color: var(--ink); font-variant-numeric: tabular-nums; }

.status { border: 1px solid var(--rule); border-radius: var(--radius); padding: 1.5rem 1.6rem;
          background: var(--card); }
.status h2 { margin-top: 0; }
.entry { border-top: 1px solid var(--rule-soft); padding-top: 1.5rem; }
.entry h2 { margin-top: 0; }

/* ── Footer ─────────────────────────────────────────────────────────────────────────── */

.site-footer { border-top: 1px solid var(--rule-soft); padding: 2.6rem 0 3.4rem; background: var(--paper-warm); }
.footer-inner { display: flex; gap: 2rem; flex-wrap: wrap; justify-content: space-between; }
.footer-links { display: flex; gap: 1.3rem; flex-wrap: wrap; max-width: none; margin: 0; }
.footer-links a { color: var(--ink-2); text-decoration: none; font-size: .91rem; }
.footer-links a:hover { color: var(--ink); text-decoration: underline; }
.fine { font-size: .82rem; color: var(--ink-2); max-width: 62ch; margin: 1.6rem 0 0; }

@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; } }
