/* Source of truth: Ark/docs/DESIGN.md, Design/Palette.swift, Design/Theme.swift,
   and Design/Styles.swift. Keep brand fills separate from readable accent text. */
:root {
  color-scheme: light dark;
  --petronas: #00a19b;
  --petronas-bright: #00d2be;
  --brand-gradient: linear-gradient(to right, var(--petronas), var(--petronas-bright));
  --on-petronas: #000;
  --accent: #00756f;
  --subtext: #565f64;
  --silver: #c8ccce;
  --graphite-top: #3a4145;
  --graphite-bottom: #121517;
  --background: #fff;
  --surface: #f2f2f7;
  --raised: #fff;
  --label: #000;
  --line: #c8ccce;
  --glass: rgb(255 255 255 / 92%);
  --card-corner: 16px;
  --card-spacing: 12px;
  --thumb-corner: 8px;
  --grid-spacing: 1.5px;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root {
    --accent: #00d2be;
    --subtext: #a5acb0;
    --background: #000;
    --surface: #1c1c1e;
    --raised: #2c2c2e;
    --label: #fff;
    --line: #565f64;
    --glass: rgb(28 28 30 / 92%);
  }
}
@media (prefers-contrast: more) {
  :root { --accent: #005e59; --subtext: #3e464a; --line: #565f64; --glass: var(--background); }
}
@media (prefers-color-scheme: dark) and (prefers-contrast: more) {
  :root { --accent: #66e4d8; --subtext: #c8ccce; --line: #c8ccce; }
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 32px; }
body { margin: 0; background: var(--background); color: var(--label); -webkit-font-smoothing: antialiased; }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
a, summary { -webkit-tap-highlight-color: transparent; }
a:focus-visible, summary:focus-visible { outline: 3px solid var(--accent); outline-offset: 5px; }
.wrap { width: min(1120px, calc(100% - 96px)); margin-inline: auto; }
.skip { position: fixed; top: -100px; left: 20px; z-index: 10; padding: 16px; background: var(--raised); border: 1px solid var(--label); border-radius: var(--thumb-corner); }
.skip:focus { top: 12px; }
header, footer { border-block: 1px solid var(--line); }
header { border-top: 0; }
.nav { min-height: 104px; display: flex; align-items: center; gap: 32px; }
.brand { display: inline-flex; align-items: center; gap: 14px; min-height: 44px; }
.brand img { width: 56px; height: 56px; border-radius: 13px; }
.brand > span { font-size: 2.25rem; line-height: 1; font-weight: 700; letter-spacing: -.06em; }
.brand-dot { color: var(--accent); }
nav { display: flex; align-items: center; gap: 28px; font-size: .9375rem; font-weight: 500; }
.nav nav { margin-left: auto; }
nav a { display: inline-flex; align-items: center; min-height: 44px; }
nav a:hover, nav a[aria-current] { color: var(--accent); }
.nav-cta { min-height: 48px; display: inline-flex; align-items: center; gap: 10px; background: var(--label); color: var(--background); border-radius: 12px; padding: 7px 18px 7px 14px; transition: opacity .12s ease-out; }
.nav-cta:hover { opacity: .8; }
.nav-cta .apple { width: 24px; height: 24px; flex-shrink: 0; }
.nav-cta span { display: flex; flex-direction: column; line-height: 1.05; text-align: left; }
.nav-cta small { font-size: .625rem; font-weight: 500; }
.nav-cta b { font-size: 1.125rem; font-weight: 600; letter-spacing: -.01em; }
/* Line icons, tinted by the surrounding text color. */
.i-shield, .i-pattern, .i-user-slash, .i-photo, .i-key, .i-clock, .i-cloud, .i-phone, .i-lock, .i-search, .i-eyeoff { --symbol: none; }
.i-shield { --symbol: url('assets/i-shield.svg'); }
.i-pattern { --symbol: url('assets/i-pattern.svg'); }
.i-user-slash { --symbol: url('assets/i-user-slash.svg'); }
.i-photo { --symbol: url('assets/i-photo.svg'); }
.i-key { --symbol: url('assets/i-key.svg'); }
.i-clock { --symbol: url('assets/i-clock.svg'); }
.i-cloud { --symbol: url('assets/i-cloud.svg'); }
.i-phone { --symbol: url('assets/i-phone.svg'); }
.i-lock { --symbol: url('assets/i-lock.svg'); }
.i-search { --symbol: url('assets/i-search.svg'); }
.i-eyeoff { --symbol: url('assets/i-eyeoff.svg'); }
.chip { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; flex-shrink: 0; background: var(--brand-gradient); color: var(--on-petronas); margin-bottom: 20px; }
.chip .symbol { width: 24px; height: 24px; }
.eyebrow .symbol, .micro .symbol { display: inline-block; width: 16px; height: 16px; margin-right: 8px; vertical-align: -3px; color: var(--accent); }
.principles .symbol { display: inline-block; width: 22px; height: 22px; margin-right: 10px; vertical-align: -6px; color: var(--accent); }
.notes-points li { display: flex; gap: 16px; align-items: flex-start; }
.notes-points .chip { width: 36px; height: 36px; border-radius: 10px; margin: 0; }
.notes-points .chip .symbol { width: 20px; height: 20px; }
.privacy-chips { list-style: none; margin: 8px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 10px; }
.privacy-chips li { display: inline-flex; align-items: center; gap: 8px; padding: 9px 14px; background: var(--raised); border: 1px solid var(--line); border-radius: 999px; font-size: .875rem; font-weight: 500; }
.privacy-chips .symbol { width: 18px; height: 18px; color: var(--accent); }
.hero { display: grid; grid-template-columns: 1.1fr 1fr; gap: 48px; align-items: center; padding-block: 72px 64px; }
.hero-copy { padding-block: 20px; }
.eyebrow { display: block; color: var(--subtext); font-size: .875rem; line-height: 1.5; font-weight: 600; }
h1, h2, h3, p { margin-top: 0; }
h1 { font-size: clamp(3.25rem, 5.7vw, 5rem); font-weight: 700; line-height: 1.05; letter-spacing: -.055em; margin-block: 20px 24px; }
h1 > span { color: var(--accent); }
.lead { font-size: 1.125rem; line-height: 1.65; color: var(--subtext); max-width: 430px; }
.hero-actions { display: flex; gap: 20px; align-items: center; margin-top: 30px; flex-wrap: wrap; }
.button { display: inline-flex; align-items: center; justify-content: center; min-height: 50px; padding: 12px 22px; border-radius: 14px; font-size: 1.0625rem; font-weight: 600; }
.primary { background: var(--brand-gradient); color: var(--on-petronas); transition: opacity .12s ease-out; }
.primary:hover, .primary:active { opacity: .72; }
.micro { font-size: .875rem; line-height: 1.5; color: var(--subtext); }
.micro { margin-top: 24px; }
/* Pre-launch status. Deliberately not shaped like a button: there is nothing to press yet. */
.availability { display: inline-flex; align-items: center; gap: 10px; color: var(--subtext); font-size: .9375rem; font-weight: 500; line-height: 1.5; }
.availability::before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: var(--petronas); flex-shrink: 0; }
.hero-art { display: flex; flex-direction: column; align-items: center; gap: 20px; margin: 0; }
/* An explicitly illustrated preview. The hierarchy mirrors MainTabView and LibraryHome. */
.phone { width: 300px; height: 610px; position: relative; overflow: hidden; border: 6px solid var(--graphite-bottom); border-radius: 46px; background: var(--background); box-shadow: 0 0 0 1px var(--silver), 0 18px 36px rgb(0 0 0 / 10%); color: var(--label); }
.phone-top { height: 52px; display: flex; align-items: center; justify-content: space-between; padding: 0 22px; font-size: .75rem; font-weight: 600; font-variant-numeric: tabular-nums; }
.island { position: absolute; top: 12px; left: 50%; transform: translateX(-50%); width: 86px; height: 24px; border-radius: 20px; background: #000; }
.phone-top .battery { width: 20px; height: 10px; border: 1px solid var(--label); border-radius: 3px; position: relative; }
.battery::after { content: ''; position: absolute; inset: 2px; background: var(--label); border-radius: 1px; }
.app-toolbar { display: flex; justify-content: space-between; align-items: center; padding: 4px 14px 12px; gap: 10px; }
.app-toolbar > picture { width: 22px; flex-shrink: 0; }
.app-toolbar > picture img { width: 22px; height: 22px; }
.app-toolbar > .symbol { width: 24px; height: 24px; }
.app-segments { display: flex; flex: 1; background: var(--surface); border-radius: 8px; padding: 2px; font-size: .6875rem; text-align: center; font-weight: 600; }
.app-segments span { flex: 1; padding: 6px 7px; }
.app-segments .active { border-radius: 6px; background: var(--raised); box-shadow: 0 1px 3px rgb(0 0 0 / 12%); }
.app-header { font-size: 1.875rem; font-weight: 700; letter-spacing: -.04em; padding: 0 16px 14px; }
.symbol { display: block; background: currentColor; mask: var(--symbol) center / contain no-repeat; }
.icon-plus { --symbol: url('assets/symbol-plus.png'); }
.icon-ellipsis { --symbol: url('assets/symbol-ellipsis.png'); }
.icon-note-text { --symbol: url('assets/symbol-note.text.png'); }
.icon-gearshape { --symbol: url('assets/symbol-gearshape.png'); }
.icon-magnifyingglass { --symbol: url('assets/symbol-magnifyingglass.png'); }
.icon-library { --symbol: url('assets/albums-selected.svg'); }
.icon-albums { --symbol: url('assets/albums.svg'); }
.icon-folder { --symbol: url('assets/symbol-folder.png'); }
.icon-heart { --symbol: url('assets/symbol-heart.png'); }
.icon-chevron-left { --symbol: url('assets/symbol-chevron.left.png'); }
.icon-eye { --symbol: url('assets/symbol-eye.png'); }
.icon-eye-slash { --symbol: url('assets/symbol-eye.slash.png'); }
.icon-copy { --symbol: url('assets/symbol-doc.on.doc.png'); }
.icon-copy-fill { --symbol: url('assets/symbol-doc.on.doc.fill.png'); }
.app-toolbar > .symbol { color: var(--accent); }
.photo-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--grid-spacing); }
.photo-grid > img { width: 100%; height: 106px; object-fit: cover; }
.app-bottom { position: absolute; bottom: 22px; left: 9px; right: 9px; display: flex; justify-content: space-around; align-items: center; gap: 6px; padding: 10px 6px; background: var(--glass); border: 1px solid var(--line); border-radius: 28px; backdrop-filter: blur(16px); }
.app-bottom > span { display: flex; flex-direction: column; align-items: center; min-width: 45px; color: var(--subtext); }
.app-bottom .symbol { width: 26px; height: 26px; }
.app-bottom .selected { color: var(--accent); }
.app-bottom small { font-size: .5625rem; margin-top: 2px; font-weight: 500; }
.home-indicator { position: absolute; bottom: 7px; left: 50%; transform: translateX(-50%); width: 100px; height: 4px; border-radius: 4px; background: var(--label); }
.preview-caption { color: var(--subtext); font-size: .75rem; line-height: 1.5; text-align: center; }
.principles { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 24px; border-block: 1px solid var(--line); padding-block: 26px; font-size: .9375rem; color: var(--subtext); }
.section { padding-block: 88px; }
.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 48px; margin-bottom: 32px; }
h2 { font-size: clamp(2rem, 3.5vw, 2.75rem); font-weight: 700; line-height: 1.12; letter-spacing: -.04em; margin-block: 14px 0; }
.section-heading > p { max-width: 320px; margin-bottom: 0; color: var(--subtext); font-size: 1rem; line-height: 1.65; }
.feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--card-spacing); }
.feature { background: var(--surface); padding: 28px; border-radius: var(--card-corner); display: flex; flex-direction: column; }
.feature-number::before { content: ''; display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--petronas-bright); margin-right: 8px; vertical-align: 1px; }
.feature-number { color: var(--subtext); font-size: .8125rem; font-weight: 600; }
h3 { font-size: 1.5rem; line-height: 1.2; font-weight: 600; letter-spacing: -.025em; margin-block: 24px 12px; }
.feature p { color: var(--subtext); font-size: 1rem; line-height: 1.6; margin-bottom: 24px; }
.collection-art { display: grid; grid-template-columns: 1fr 1fr; gap: var(--grid-spacing); border-radius: var(--thumb-corner); overflow: hidden; margin-top: auto; }
.collection-art img { width: 100%; height: 112px; object-fit: cover; }
.folder-art { background: linear-gradient(var(--graphite-top), var(--graphite-bottom)); display: flex; gap: 20px; align-items: center; justify-content: center; min-height: 112px; border-radius: var(--thumb-corner); margin-top: auto; }
.folder-art .symbol { width: 44px; height: 44px; color: var(--petronas-bright); }
.pattern { display: grid; grid-template-columns: repeat(3, 7px); gap: 22px; padding: 23px; width: max-content; margin: auto auto 0; position: relative; }
.pattern i { height: 7px; width: 7px; background: var(--subtext); border-radius: 50%; }
.pattern svg { position: absolute; width: 65px; height: 65px; top: 23px; left: 23px; fill: none; stroke: var(--accent); stroke-width: 2; }
/* Notes read mode, mirroring NoteScreen and QuickCopyRow in the app. */
.notes { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: center; padding-top: 0; }
.notes-copy > p { color: var(--subtext); font-size: 1rem; line-height: 1.7; max-width: 460px; margin-block: 24px 28px; }
.notes-points { list-style: none; margin: 0; padding: 0; max-width: 460px; }
.notes-points li { border-top: 1px solid var(--line); padding-block: 16px; color: var(--subtext); font-size: .9375rem; line-height: 1.6; }
.notes-points strong { color: var(--label); font-weight: 600; }
.note-art { margin: 0; display: flex; flex-direction: column; align-items: center; gap: 20px; background: var(--surface); border-radius: var(--card-corner); padding: 40px 28px 24px; }
.note-screen { width: 100%; max-width: 360px; position: relative; padding: 16px 16px 76px; background: var(--background); border: 1px solid var(--line); border-radius: 28px; color: var(--label); }
.note-bar { display: flex; justify-content: space-between; align-items: center; color: var(--accent); font-size: .9375rem; margin-bottom: 14px; }
.note-back { display: inline-flex; align-items: center; gap: 4px; }
.note-bar .symbol { width: 20px; height: 20px; }
.note-title { font-size: 1.625rem; font-weight: 700; letter-spacing: -.03em; }
.note-date { color: var(--subtext); font-size: .8125rem; margin: 2px 0 16px; }
.copy-row { display: flex; align-items: center; gap: 6px; padding: 8px 6px 8px 12px; margin-bottom: 8px; background: var(--surface); border-radius: 10px; }
.copy-row > div { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.copy-row small { color: var(--subtext); font-size: .75rem; }
.copy-row code { font: 1rem ui-monospace, SFMono-Regular, Menlo, monospace; }
.copy-row > .symbol { width: 22px; height: 22px; margin: 9px; color: var(--accent); flex-shrink: 0; }
.note-text { font-size: .9375rem; line-height: 1.6; margin: 14px 2px 0; }
.toast { position: absolute; left: 50%; bottom: 18px; transform: translateX(-50%); display: flex; align-items: center; gap: 8px; white-space: nowrap; padding: 10px 16px; background: var(--glass); border: 1px solid var(--line); border-radius: 999px; font-size: .8125rem; font-weight: 600; backdrop-filter: blur(16px); box-shadow: 0 6px 18px rgb(0 0 0 / 10%); }
.toast .symbol { width: 16px; height: 16px; color: var(--accent); }
.questions a { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
.privacy-band { background: var(--surface); }
.privacy-layout { display: grid; grid-template-columns: .65fr 1fr; align-items: center; gap: 72px; padding-block: 72px; }
.privacy-symbol img { width: 144px; height: 144px; border-radius: 32px; margin-inline: auto; }
.privacy-layout p { color: var(--subtext); max-width: 490px; font-size: 1rem; line-height: 1.7; margin-block: 24px 16px; }
.text-link { display: inline-flex; align-items: center; min-height: 44px; gap: 12px; color: var(--accent); font-size: 1rem; font-weight: 500; text-decoration: underline; text-underline-offset: 4px; }
.text-link:hover { text-decoration-thickness: 2px; }
.faq { display: grid; grid-template-columns: 1fr 1.3fr; gap: 64px; }
.questions { border-top: 1px solid var(--line); }
details { border-bottom: 1px solid var(--line); }
summary { min-height: 60px; padding-block: 22px; display: flex; align-items: center; justify-content: space-between; gap: 24px; cursor: pointer; list-style: none; font-size: 1rem; line-height: 1.5; font-weight: 600; }
summary::-webkit-details-marker { display: none; }
summary > span { font-size: 1.5rem; color: var(--accent); font-weight: 400; }
details[open] summary > span { transform: rotate(45deg); }
details p { font-size: 1rem; line-height: 1.7; color: var(--subtext); margin: 0 28px 24px 0; }
.closing { text-align: center; padding-block: 64px 80px; border-top: 1px solid var(--line); }
.closing > img { width: 56px; height: 56px; border-radius: 13px; margin: 0 auto 20px; }
.closing p { color: var(--subtext); line-height: 1.6; margin-block: 24px; }
.footer-top { display: flex; align-items: center; gap: 24px; padding-block: 28px; }
.footer-top > span { font-size: .875rem; color: var(--subtext); }
.footer-top nav { margin-left: auto; font-size: .875rem; }
.footer-bottom { border-top: 1px solid var(--line); padding-block: 22px; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 20px; color: var(--subtext); font-size: .8125rem; line-height: 1.5; }
.document { max-width: 850px; padding-block: 72px 88px; }
.document h1 { font-size: clamp(2.75rem, 6vw, 4rem); }
.document .lead { max-width: 650px; }
.document section { border-top: 1px solid var(--line); margin-top: 36px; padding-top: 26px; }
.document section h2 { font-size: 1.75rem; margin-block: 0 16px; }
.document section p { color: var(--subtext); font-size: 1rem; line-height: 1.7; }
.document > .text-link { margin-top: 32px; }
.draft-label { display: inline-block; padding: 14px 16px; border: 1px solid var(--line); border-radius: var(--thumb-corner); color: var(--subtext); background: var(--surface); font-size: .875rem; line-height: 1.5; }
.document .support-note { border: 0; background: var(--surface); padding: 28px; border-radius: var(--card-corner); }
.support-note .eyebrow { margin-bottom: 16px; }
@media (max-width: 960px) {
  .wrap { width: calc(100% - 64px); }
  .hero { gap: 24px; }
  .notes { gap: 40px; }
  .feature { padding: 24px; }
  .footer-top { flex-wrap: wrap; }
  .footer-top nav { margin-left: 0; }
}
@media (max-width: 720px) {
  .wrap { width: calc(100% - 40px); }
  .nav { flex-wrap: wrap; gap: 8px 20px; padding-block: 12px; }
  .nav nav { gap: 16px; font-size: .875rem; }
  .nav-cta { margin-left: auto; min-height: 44px; }
  .brand img { width: 44px; height: 44px; border-radius: 10px; }
  .brand > span { font-size: 1.875rem; }
  .hero { grid-template-columns: 1fr; padding-block: 40px; gap: 32px; }
  .hero-copy { padding: 0; }
  h1 { font-size: clamp(3rem, 10vw, 4.5rem); }
  .lead { font-size: 1.0625rem; }
  .hero-art { margin-top: 8px; }
  .principles { flex-direction: column; gap: 14px; }
  .section { padding-block: 56px; }
  .section-heading { display: block; }
  .section-heading > p { margin-top: 20px; }
  .feature-grid { grid-template-columns: 1fr; }
  .notes { grid-template-columns: 1fr; gap: 32px; }
  .note-art { padding: 28px 16px 20px; }
  .feature { padding: 28px; }
  .feature p { max-width: 440px; }
  .collection-art { max-width: 340px; width: 100%; }
  .folder-art { justify-content: start; padding-inline: 24px; }
  .pattern { margin: 0; }
  .privacy-layout { grid-template-columns: 1fr; gap: 32px; padding-block: 48px; }
  .privacy-symbol img { width: 88px; height: 88px; border-radius: 20px; margin: 0; }
  .faq { grid-template-columns: 1fr; gap: 28px; }
  .closing { padding-block: 48px 56px; }
  .footer-top { gap: 16px; }
  .footer-top nav { width: 100%; }
  .document { padding-block: 48px 64px; }
}
@media (max-width: 359px) {
  .phone { width: 280px; }
  .nav nav { width: 100%; margin-left: 0; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
}

/* Public content and optional analytics retain Ark's existing palette. */
[hidden] { display: none !important; }
button { font-family: inherit; cursor: pointer; }
button:focus-visible { outline: 3px solid var(--accent); outline-offset: 5px; }
button.button { color: var(--label); background: var(--surface); border: 1px solid var(--line); }
button:disabled { opacity: .6; cursor: wait; }
.post { border-top: 1px solid var(--line); padding-block: 32px; }
.post time { display: block; color: var(--subtext); font-size: .875rem; margin-bottom: 16px; }
.post h2 { font-size: 1.75rem; letter-spacing: -.025em; }
.post p { color: var(--subtext); line-height: 1.7; white-space: pre-line; overflow-wrap: anywhere; }
.post img, .post video { width: 100%; max-height: 560px; object-fit: contain; border-radius: var(--card-corner); background: var(--surface); margin-top: 24px; }
.analytics-settings { border: 0; padding: 0; background: none; color: var(--accent); font-size: inherit; text-align: left; }
.analytics-preferences { position: fixed; bottom: 20px; right: 20px; left: 20px; z-index: 20; margin-inline: auto; max-width: 680px; padding: 24px; border: 1px solid var(--line); border-radius: var(--card-corner); background: var(--raised); box-shadow: 0 8px 32px rgb(0 0 0 / 15%); display: flex; flex-wrap: wrap; gap: 12px; }
.analytics-preferences p { flex-basis: 100%; margin: 0; line-height: 1.6; color: var(--subtext); }
