/* Ultimate Notes: the app's own look. SF Pro (the system font), Apple's grays, the app's red as the only accent,
   grouped lists like Settings. Pages: index.html and it/index.html (made by build.py), support.html, privacy.html. */
:root {
  --text: #1d1d1f; --secondary: #6e6e73; --bg: #ffffff; --alt: #f5f5f7; --group: #ffffff;
  --separator: rgba(60, 60, 67, 0.22); --accent: #d70015; --button: #d70015; --bar: rgba(255, 255, 255, 0.78);
  --hairline: rgba(0, 0, 0, 0.1); --private-bg: #000000; --private-text: #f5f5f7; --private-secondary: #a1a1a6;
}
@media (prefers-color-scheme: dark) {
  :root {
    --text: #f5f5f7; --secondary: #a1a1a6; --bg: #000000; --alt: #161617; --group: #1c1c1e;
    --separator: rgba(84, 84, 88, 0.6); --accent: #ff453a; --bar: rgba(22, 22, 23, 0.78);
    --hairline: rgba(255, 255, 255, 0.14); --private-bg: #000000;
  }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 64px; }
body {
  margin: 0; color: var(--text); background: var(--bg);
  font: 17px/1.47 -apple-system, BlinkMacSystemFont, "Helvetica Neue", Helvetica, Arial, sans-serif;
  letter-spacing: -0.022em; -webkit-font-smoothing: antialiased;
}
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 6px; }
img { max-width: 100%; }
h1, h2, h3 { margin: 0; font-weight: 700; text-wrap: balance; }
.sub, .copy p, .lead { text-wrap: balance; }
p { margin: 0; }

/* The bar: thin, translucent, always there. */
.bar {
  position: sticky; top: 0; z-index: 10; background: var(--bar);
  -webkit-backdrop-filter: saturate(180%) blur(20px); backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 0.5px solid var(--hairline);
}
.bar-inner { max-width: 1024px; margin: 0 auto; padding: 0 22px; height: 52px; display: flex; align-items: center; justify-content: space-between; }
.bar .name { display: flex; align-items: center; gap: 10px; color: var(--text); font-weight: 600; font-size: 17px; }
.bar .name img { width: 28px; height: 28px; border-radius: 6.5px; }
.bar .links { display: flex; align-items: center; gap: 24px; font-size: 14px; letter-spacing: -0.01em; }
.bar .links a { color: var(--text); opacity: 0.85; }
.bar .links a:hover { opacity: 1; text-decoration: none; }
.bar .links .get {
  color: #fff; opacity: 1; background: var(--button); border-radius: 999px; padding: 5px 14px; font-weight: 600;
}

/* The hero: the icon, one sentence, the badge, the devices. */
.hero { text-align: center; padding: 72px 22px 120px; overflow: hidden; }
.app-icon { display: block; margin: 0 auto 28px; border-radius: 22.37%; box-shadow: 0 0 0 0.5px var(--hairline); }
.hero h1 { font-size: clamp(44px, 7.2vw, 80px); line-height: 1.05; letter-spacing: -0.015em; max-width: 13ch; margin: 0 auto; }
.sub { color: var(--secondary); font-size: clamp(19px, 2.2vw, 24px); line-height: 1.33; letter-spacing: 0.005em; margin: 18px auto 0; max-width: 34ch; }
.badge { display: inline-block; margin-top: 30px; }
.badge img { display: block; width: 156px; height: 52px; }
.devices { position: relative; max-width: 980px; margin: 64px auto 0; padding-right: 8%; }
.devices .phone { position: absolute; right: 0; bottom: -8%; width: 23%; }

/* Screenshots: the device's own rounded screen, a hairline, no drop shadows. */
.shot { display: block; width: 100%; height: auto; border-radius: 18px; box-shadow: 0 0 0 0.5px var(--hairline); background: var(--alt); }
.shot.phone { border-radius: 13% / 6%; }

/* Chapters: full width, alternating white and gray, centered. */
.chapter { padding: 120px 22px; text-align: center; }
.chapter.alt { background: var(--alt); }
.inner { max-width: 980px; margin: 0 auto; }
.chapter h2, .private h2, .included h2, .questions h2, .end h2 {
  font-size: clamp(36px, 5.4vw, 56px); line-height: 1.07; letter-spacing: -0.005em; max-width: 16ch; margin: 0 auto;
}
.copy { max-width: 640px; margin: 22px auto 0; }
.copy p { color: var(--secondary); font-size: clamp(19px, 2vw, 21px); line-height: 1.38; letter-spacing: 0.011em; }
.copy p + p { margin-top: 12px; }
.hero-shot { margin: 56px auto 0; }
.hero-shot.narrow { max-width: 620px; }
.tiles { display: grid; gap: 40px 24px; margin-top: 72px; text-align: left; }
.tiles.n2 { grid-template-columns: repeat(2, 1fr); }
.tiles.n3 { grid-template-columns: repeat(3, 1fr); }
.tiles.n1 { max-width: 640px; margin-left: auto; margin-right: auto; }
.tiles figure { margin: 0; }
/* Tiles side by side share one frame; a light and a dark shot of the same note show as one, split down the middle. */
.tiles.n2 .pics, .tiles.n3 .pics {
  position: relative; aspect-ratio: 16 / 10; overflow: hidden; border-radius: 18px; box-shadow: 0 0 0 0.5px var(--hairline);
}
.tiles.n2 .pics img, .tiles.n3 .pics img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: left top; border-radius: 0; box-shadow: none;
}
.pics.split img + img { clip-path: inset(0 0 0 50%); }
.tiles img[src$="pdf-dark.jpg"] { object-position: left bottom; }
.tiles figcaption { margin-top: 18px; }
.tiles h3, .private h3 { font-size: 21px; line-height: 1.19; letter-spacing: 0.011em; font-weight: 600; }
.tiles p { color: var(--secondary); margin-top: 6px; }
.phones { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; max-width: 620px; margin: 56px auto 0; }

/* Privacy, Apple's way: dark, big words, nothing else. */
.private { background: var(--private-bg); color: var(--private-text); padding: 140px 22px; text-align: center; }
.private .columns { display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px; margin-top: 72px; text-align: left; }
.private p { color: var(--private-secondary); margin-top: 8px; }

/* Everything included: grouped lists, as in the app's Settings. */
.included, .questions { background: var(--alt); padding: 120px 22px; text-align: center; }
.questions { padding-top: 0; }
.included .lead { color: var(--secondary); font-size: clamp(19px, 2vw, 21px); margin: 18px auto 0; max-width: 40ch; }
.groups { columns: 2 420px; column-gap: 24px; margin-top: 64px; text-align: left; }
.group { break-inside: avoid; margin-bottom: 32px; }
.group h3 { font-size: 20px; letter-spacing: 0.01em; font-weight: 700; margin: 0 0 10px 16px; }
.group ul, .faq { list-style: none; margin: 0; padding: 0; background: var(--group); border-radius: 12px; overflow: hidden; }
.group li { display: block; padding: 11px 16px 12px; position: relative; }
.group li + li::before, .faq details + details::before {
  content: ""; position: absolute; top: 0; left: 16px; right: 0; border-top: 0.5px solid var(--separator);
}
.group strong { display: block; font-weight: 400; font-size: 17px; }
.group span { display: block; color: var(--secondary); font-size: 15px; line-height: 1.33; letter-spacing: -0.01em; margin-top: 1px; }

/* Questions: one grouped list, rows that open. */
.faq { max-width: 720px; margin: 48px auto 0; text-align: left; }
.faq details { position: relative; }
.faq summary { list-style: none; cursor: pointer; padding: 14px 44px 14px 16px; font-size: 17px; position: relative; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {                                    /* the list's chevron, turning down when open */
  content: ""; position: absolute; right: 20px; top: 50%; width: 8px; height: 8px; margin-top: -5px;
  border-right: 2px solid var(--secondary); border-bottom: 2px solid var(--secondary); opacity: 0.6;
  transform: rotate(-45deg); transition: transform 0.2s ease;
}
.faq details[open] summary::after { transform: rotate(45deg); margin-top: -7px; }
.faq details p { color: var(--secondary); padding: 0 44px 16px 16px; }

/* The end: the icon and the badge once more. */
.end { text-align: center; padding: 120px 22px 110px; }
.end .app-icon { margin-bottom: 24px; }

.foot { background: var(--alt); color: var(--secondary); font-size: 12px; line-height: 1.33; letter-spacing: -0.01em; padding: 22px; }
.foot .inner { border-top: 0.5px solid var(--separator); padding-top: 18px; }
.foot nav { display: flex; gap: 20px; flex-wrap: wrap; margin-bottom: 10px; }
.foot nav a { color: var(--text); opacity: 0.8; }

@media (max-width: 820px) {
  .bar .links a:not(.get) { display: none; }
  .chapter, .included { padding: 88px 18px; }
  .private { padding: 100px 18px; }
  .tiles.n2, .tiles.n3, .private .columns { grid-template-columns: 1fr; }
  .private .columns { gap: 28px; margin-top: 48px; }
  .devices { margin-top: 44px; }
  .hero { padding-bottom: 72px; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }

/* Support and Privacy pages: the same type and colors, one column. */
body:not(.home) main { max-width: 720px; margin: 0 auto; padding: 48px 22px 80px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--text); font-weight: 600; font-size: 17px; }
.brand img { width: 32px; height: 32px; border-radius: 7.5px; }
body:not(.home) h1 { font-size: 40px; line-height: 1.1; margin: 32px 0 10px; }
body:not(.home) h2 { font-size: 24px; line-height: 1.17; margin: 40px 0 10px; }
body:not(.home) p, body:not(.home) li { line-height: 1.47; }
body:not(.home) p + p { margin-top: 12px; }
.lead, .date { color: var(--secondary); }
.card { background: var(--alt); border-radius: 12px; padding: 14px 18px; margin: 12px 0; }
body:not(.home) nav { display: flex; gap: 18px; flex-wrap: wrap; margin-top: 20px; }
hr { border: 0; border-top: 0.5px solid var(--separator); margin: 48px 0; }
