/* Notchify site
   Palette comes straight from the app icon: aluminum ground, the mascot's
   teal line, the marigold "+" bubble, and a true-black notch. */
:root {
  --alu: #e7eaec;
  --alu-deep: #d6dbde;
  --paper: #f6f7f8;
  --ink: #1b2a31;
  --ink-soft: #4a5a62;
  --teal: #1f6f8b;
  --teal-deep: #175a71;
  --marigold: #f2a33a;
  --notch: #000;

  --display: "Fredoka", ui-rounded, "SF Pro Rounded", system-ui, sans-serif;
  --body: "Atkinson Hyperlegible Next", "Atkinson Hyperlegible", system-ui, -apple-system, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;

  --bar-h: 40px;
  --notch-w: 196px;
  --notch-h: 32px;
  --drawer-w: min(468px, calc(100vw - 16px));
  --drawer-h: 236px;
  --ease-drawer: cubic-bezier(.32, .72, 0, 1);

  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--bar-h) + 24px); }
body {
  margin: 0;
  background: var(--alu);
  color: var(--ink);
  font: 400 17px/1.6 var(--body);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg, video { display: block; }
[hidden] { display: none !important; }
a { color: var(--teal); text-underline-offset: 3px; }
a:hover { color: var(--teal-deep); }
:focus-visible { outline: 3px solid var(--marigold); outline-offset: 3px; border-radius: 6px; }
h1, h2, h3 { font-family: var(--display); font-weight: 500; margin: 0; letter-spacing: -0.01em; }
p { margin: 0; }
code { font-family: var(--mono); font-size: 0.9em; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--ink); color: #fff; padding: 8px 14px; border-radius: 8px; }
.skip:focus { top: 52px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 14px 22px;
  border-radius: 14px;
  background: var(--teal);
  color: #fff;
  font: 700 17px/1 var(--body);
  text-decoration: none;
  border: 2px solid var(--teal);
  transition: background-color .15s ease, border-color .15s ease;
}
.btn svg { width: 20px; height: 20px; }
.btn:hover { background: var(--teal-deep); border-color: var(--teal-deep); color: #fff; }
.btn-quiet { background: transparent; color: var(--ink); border-color: var(--alu-deep); }
.btn-quiet:hover { background: var(--paper); border-color: var(--ink-soft); color: var(--ink); }
.btn-small { padding: 7px 12px; font-size: 14px; border-radius: 10px; gap: 6px; }
.btn-small svg { width: 16px; height: 16px; }

/* ---------- Menu bar ---------- */
.menubar {
  position: fixed; inset: 0 0 auto 0; z-index: 20;
  height: var(--bar-h);
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  padding: 0 16px;
  background: rgb(231 234 236 / .84);
  backdrop-filter: saturate(1.4) blur(14px);
  -webkit-backdrop-filter: saturate(1.4) blur(14px);
  border-bottom: 1px solid var(--alu-deep);
}
.brand {
  display: inline-flex; align-items: center; gap: 8px;
  color: var(--ink); text-decoration: none;
  font: 600 18px/1 var(--display);
  grid-column: 1; grid-row: 1;
  justify-self: start;
}
.brand img { border-radius: 7px; }
/* Links sit left of the notch, like app menus do. */
.menubar-links {
  grid-column: 1; grid-row: 1;
  justify-self: start;
  margin-left: 128px;
  display: flex; gap: 22px;
}
.menubar-links a, .menubar-github {
  color: var(--ink); text-decoration: none; font-size: 15px; font-weight: 500;
}
.menubar-links a:hover, .menubar-github:hover { color: var(--teal); }
.menubar-right { grid-column: 3; justify-self: end; display: flex; align-items: center; gap: 18px; }
.menubar-github { display: inline-flex; align-items: center; gap: 6px; }
.menubar-github svg { width: 18px; height: 18px; }

/* ---------- Notch + drawer ---------- */
.notch-wrap {
  position: fixed; top: 0; left: 0; right: 0; z-index: 30;
  display: flex; justify-content: center;
  pointer-events: none;
}
.notch {
  position: relative;
  pointer-events: auto;
  width: var(--notch-w);
  height: var(--notch-h);
  background: var(--notch);
  border-radius: 0 0 14px 14px;
  overflow: hidden;
  transition:
    width .46s var(--ease-drawer),
    height .46s var(--ease-drawer),
    border-radius .46s var(--ease-drawer);
}
/* Inverted top corners so the notch melts into the top edge like hardware. */
.notch::before, .notch::after {
  content: ""; position: absolute; top: 0; width: 10px; height: 10px; pointer-events: none;
}
.notch.is-open { width: var(--drawer-w); height: var(--drawer-h); border-radius: 0 0 26px 26px; box-shadow: 0 18px 40px -18px rgb(0 0 0 / .45); }
.notch.has-activity:not(.is-open) { width: calc(var(--notch-w) + 104px); }

.notch-handle {
  position: absolute; inset: 0 0 auto 0;
  height: var(--notch-h);
  width: 100%;
  background: transparent; border: 0; padding: 0 14px; margin: 0;
  cursor: pointer; color: #fff;
  display: flex; align-items: center; justify-content: space-between;
  z-index: 2;
}
.notch-handle:focus-visible { outline-offset: -3px; }
.ear { display: inline-flex; align-items: center; gap: 6px; font: 700 13px/1 var(--mono); opacity: 0; transition: opacity .2s ease; }
.notch.has-activity:not(.is-open) .ear { opacity: 1; transition-delay: .2s; }
.ear svg { width: 16px; height: 16px; }
.ear .is-orange { color: var(--marigold); }
.ear .is-green { color: #6fd38c; }

.drawer {
  position: absolute; left: 0; right: 0; top: var(--notch-h);
  padding: 4px 12px 12px;
  opacity: 0;
  transition: opacity .18s ease;
  color: #fff;
}
.notch.is-open .drawer { opacity: 1; transition: opacity .25s ease .16s; }
.notch:not(.is-open) .drawer { visibility: hidden; transition: opacity .12s ease, visibility 0s linear .12s; }

.drawer-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 8px;
  height: calc(var(--drawer-h) - var(--notch-h) - 16px);
}
.drawer-grid[data-tab="notes"] { grid-template-columns: 1fr; }
.drawer-grid[data-tab="notes"] .col-right { display: none; }
.col {
  background: rgb(255 255 255 / .065);
  border: 1px solid rgb(255 255 255 / .08);
  border-radius: 14px;
  padding: 6px;
  display: flex; flex-direction: column; gap: 6px;
  min-width: 0;
}
.drawer-grid[data-tab="notes"] .col-left { flex-direction: row; flex-wrap: wrap; align-content: flex-start; height: auto; }
.drawer-grid[data-tab="notes"] .col-left .pane { display: none; }

.actions { display: flex; gap: 5px; }
.act {
  flex: 1; height: 28px; border-radius: 8px;
  background: rgb(255 255 255 / .09); border: 1px solid rgb(255 255 255 / .06);
  color: rgb(255 255 255 / .88); cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center; gap: 5px;
  font: 700 12px/1 var(--mono);
}
.act svg { width: 15px; height: 15px; }
.act:hover { border-color: rgb(255 255 255 / .28); }
.act.is-running { background: rgb(242 163 58 / .2); color: var(--marigold); }
.act.is-break { background: rgb(111 211 140 / .2); color: #6fd38c; }

.tabs { display: flex; gap: 5px; }
.tabs button {
  width: 34px; height: 26px; border-radius: 999px; border: 0;
  background: rgb(255 255 255 / .05); color: rgb(255 255 255 / .55);
  display: inline-flex; align-items: center; justify-content: center; cursor: pointer;
}
.tabs button svg { width: 15px; height: 15px; }
.tabs button[aria-selected="true"] { background: rgb(255 255 255 / .22); color: #fff; }
.tabs button:hover { color: #fff; }

.pane { flex: 1; min-height: 0; border-radius: 10px; }
.pane-files { display: flex; flex-direction: column; justify-content: space-between; padding: 2px; }
.pane-files.is-target, .pane-airdrop.is-target { background: rgb(255 255 255 / .1); outline: 1px dashed rgb(255 255 255 / .5); }
.shelf-list { list-style: none; margin: 0; padding: 0; display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; }
.file { width: 52px; flex: none; display: flex; flex-direction: column; align-items: center; gap: 3px; }
.thumb {
  width: 38px; height: 38px; border-radius: 8px;
  display: grid; place-items: center;
  font: 700 9px/1 var(--body); letter-spacing: .02em; color: #fff;
  border: 1px solid rgb(255 255 255 / .1);
}
.thumb-img { background: linear-gradient(160deg, #f6c66b 0%, #e9784b 55%, #5a3d6b 100%); }
.thumb-pdf { background: #c8463d; }
.thumb-key { background: #3f7fd9; }
.thumb-any { background: rgb(255 255 255 / .14); }
.fname { font-size: 10px; line-height: 1.2; color: rgb(255 255 255 / .75); max-width: 52px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.shelf-hint { font-size: 11px; color: rgb(255 255 255 / .45); padding: 0 2px 2px; }

.pane-airdrop { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; background: rgb(255 255 255 / .04); text-align: center; padding: 8px; }
.pane-airdrop svg { width: 26px; height: 26px; color: #7fc4ff; }
.pane-airdrop p { font-size: 12px; line-height: 1.35; color: rgb(255 255 255 / .7); max-width: 22ch; }

.music {
  display: flex; align-items: center; gap: 8px;
  background: rgb(255 255 255 / .06); border-radius: 9px; padding: 5px 6px;
}
.art { width: 28px; height: 28px; border-radius: 6px; flex: none; background: linear-gradient(135deg, var(--teal) 0%, #7cc4c9 50%, var(--marigold) 100%); }
.track { flex: 1; min-width: 0; display: flex; flex-direction: column; line-height: 1.2; }
.track strong { font-size: 12px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.track span { font-size: 11px; color: rgb(255 255 255 / .55); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.play { width: 26px; height: 26px; border-radius: 50%; border: 0; background: rgb(255 255 255 / .14); color: #fff; display: grid; place-items: center; cursor: pointer; flex: none; }
.play svg { width: 12px; height: 12px; }
.play:hover { background: rgb(255 255 255 / .24); }

.mirror { position: relative; flex: 1; min-height: 0; border-radius: 10px; overflow: hidden; background: rgb(255 255 255 / .04); }
.mirror video { width: 100%; height: 100%; object-fit: cover; transform: scaleX(-1); }
.mirror-off { height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; padding: 6px; text-align: center; }
.mirror-off svg { width: 22px; height: 22px; color: rgb(255 255 255 / .5); }
.mirror-off button {
  border: 0; border-radius: 999px; padding: 6px 12px; cursor: pointer;
  background: #fff; color: #000; font: 700 12px/1 var(--body);
}
.mirror-off small { font-size: 10.5px; line-height: 1.3; color: rgb(255 255 255 / .5); max-width: 24ch; }
.mirror-stop {
  position: absolute; top: 6px; right: 6px;
  border: 0; border-radius: 999px; padding: 4px 9px; cursor: pointer;
  background: rgb(0 0 0 / .6); color: #fff; font: 700 11px/1 var(--body);
}

.pane-notes { grid-column: 1 / -1; display: flex; }
.pane-notes textarea {
  flex: 1; resize: none; border: 1px solid rgb(255 255 255 / .08); border-radius: 12px;
  background: rgb(255 255 255 / .05); color: rgb(255 255 255 / .92);
  font: 400 14px/1.5 var(--body); padding: 10px 12px;
}
.pane-notes textarea::placeholder { color: rgb(255 255 255 / .35); }
.pane-notes textarea:focus-visible { outline: 2px solid var(--marigold); outline-offset: 0; }
.drawer-grid[data-tab="notes"] { grid-template-rows: auto 1fr; }

/* ---------- Page sections ---------- */
main { display: block; }
main > section { padding-inline: 20px; }
.section-lede { color: var(--ink-soft); margin-top: 12px; }

.hero {
  padding-top: calc(var(--drawer-h) + 72px);
  padding-bottom: 96px;
  text-align: center;
  display: flex; flex-direction: column; align-items: center;
}
.hero h1 {
  font-size: clamp(44px, 7.4vw, 100px);
  line-height: .98;
  letter-spacing: -0.025em;
  max-width: 18ch;
  text-wrap: balance;
}
.lede { margin-top: 24px; max-width: 46ch; font-size: clamp(17px, 1.6vw, 20px); color: var(--ink-soft); }
.cta { margin-top: 32px; display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; }
.fineprint { margin-top: 16px; font-size: 14px; color: var(--ink-soft); }
.demo-hint { margin-top: 40px; font-size: 14px; color: var(--teal); }

.closed {
  background: var(--paper);
  border-block: 1px solid var(--alu-deep);
  padding-block: 88px;
}
.closed h2, .features h2, .install h2, .faq h2 {
  font-size: clamp(32px, 4.2vw, 52px); line-height: 1.05; text-wrap: balance;
}
.closed > *, .features > *, .install > *, .faq > * { max-width: 1080px; margin-inline: auto; }
/* Full-width box for alignment, but keep the line length readable. */
.closed .section-lede { padding-right: max(0px, calc(100% - 54ch)); }
.closed-row {
  list-style: none; padding: 0; margin-top: 48px;
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px;
}
.closed-row li {
  border-top: 10px solid #000;
  padding-top: 0;
}
.closed-row p { margin-top: 18px; color: var(--ink-soft); font-size: 15px; max-width: 30ch; }
.closed-row strong { display: block; color: var(--ink); font-family: var(--display); font-weight: 600; font-size: 20px; margin-bottom: 2px; }
/* The black rule above is the top edge of the screen; the notch hangs from it. */
.mini-notch {
  width: 120px; height: 30px; margin: 0 auto;
  background: #000; border-radius: 0 0 12px 12px;
  display: flex; align-items: center; justify-content: space-between; padding: 0 12px;
  color: #fff;
}
.mini-wide { width: 210px; }
.mini-icon { width: 16px; height: 16px; }
.mini-icon.is-orange { color: var(--marigold); }
.mini-time { font: 700 13px/1 var(--mono); }
.mini-art { width: 18px; height: 18px; border-radius: 5px; background: linear-gradient(135deg, var(--teal), var(--marigold)); }
.bars { display: inline-flex; align-items: flex-end; gap: 2px; height: 14px; }
.bars i { width: 3px; background: #fff; border-radius: 2px; height: 40%; animation: bar 1.1s ease-in-out infinite; }
.bars i:nth-child(2) { animation-delay: -.3s; }
.bars i:nth-child(3) { animation-delay: -.6s; }
.bars i:nth-child(4) { animation-delay: -.9s; }
@keyframes bar { 0%, 100% { height: 30%; } 50% { height: 100%; } }

.features { padding-block: 104px; }
.groups { margin-top: 56px; }
.group {
  display: grid; grid-template-columns: minmax(180px, 300px) 1fr; gap: 32px;
  padding-block: 36px;
  border-top: 2px solid var(--alu-deep);
}
.group:last-child { border-bottom: 2px solid var(--alu-deep); }
.group h3 { font-size: 28px; color: var(--teal); line-height: 1.1; }
.group dl { margin: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 24px 36px; }
.group dt { font-weight: 700; font-size: 18px; }
.group dd { margin: 4px 0 0; color: var(--ink-soft); }

.install { padding-block: 104px; background: var(--paper); border-top: 1px solid var(--alu-deep); }
.steps {
  list-style: none; padding: 0; margin-top: 48px;
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px;
  counter-reset: step;
}
.steps li { counter-increment: step; }
.steps li::before {
  content: counter(step);
  display: grid; place-items: center;
  width: 48px; height: 48px; border-radius: 50%;
  background: var(--marigold); color: var(--ink);
  font: 600 24px/1 var(--display);
  margin-bottom: 18px;
}
.steps h3 { font-size: 22px; line-height: 1.2; }
.steps p { margin-top: 6px; color: var(--ink-soft); max-width: 32ch; }

.gatekeeper {
  margin-top: 64px;
  display: grid; grid-template-columns: 1fr minmax(0, 460px); gap: 32px; align-items: center;
  padding: 28px;
  border-radius: 20px;
  background: var(--alu);
  border: 1px solid var(--alu-deep);
}
.gatekeeper h3 { font-size: 22px; line-height: 1.2; }
.gatekeeper p { margin-top: 8px; color: var(--ink-soft); max-width: 52ch; }
.cmd {
  display: flex; align-items: center; gap: 12px;
  background: #000; color: #fff; border-radius: 14px; padding: 12px 12px 12px 18px;
  min-width: 0;
}
.cmd code { flex: 1; font-size: 14.5px; white-space: nowrap; overflow-x: auto; scrollbar-width: none; }
.copy {
  flex: none; display: inline-flex; align-items: center; gap: 6px;
  border: 0; border-radius: 10px; padding: 8px 12px; cursor: pointer;
  background: rgb(255 255 255 / .14); color: #fff; font: 700 14px/1 var(--body);
}
.copy svg { width: 16px; height: 16px; }
.copy:hover { background: rgb(255 255 255 / .24); }
.copy.is-done { background: var(--marigold); color: var(--ink); }

.faq { padding-block: 104px; }
.faq-list { margin-top: 40px; border-top: 2px solid var(--alu-deep); }
.faq details { border-bottom: 2px solid var(--alu-deep); }
.faq summary {
  list-style: none; cursor: pointer;
  display: flex; justify-content: space-between; align-items: center; gap: 24px;
  padding: 22px 4px;
  font: 600 21px/1.3 var(--display);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ""; flex: none; width: 14px; height: 14px;
  background:
    linear-gradient(var(--teal), var(--teal)) center / 14px 2.5px no-repeat,
    linear-gradient(var(--teal), var(--teal)) center / 2.5px 14px no-repeat;
  transition: transform .2s ease;
}
.faq details[open] summary::after { transform: rotate(45deg); }
.faq summary:hover { color: var(--teal); }
.faq details p { padding: 0 4px 24px; max-width: 64ch; color: var(--ink-soft); }

.footer {
  padding: 56px 20px 64px;
  border-top: 1px solid var(--alu-deep);
  display: flex; flex-direction: column; align-items: center; gap: 14px; text-align: center;
  font-size: 15px; color: var(--ink-soft);
}
.footer img { border-radius: 10px; }
.footer nav { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 22px; }

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
  .menubar-links { display: none; }
  .gatekeeper { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  .closed-row, .steps { grid-template-columns: 1fr; gap: 40px; }
  .group { grid-template-columns: 1fr; gap: 16px; }
  .menubar-github span { display: none; }
}
@media (max-width: 520px) {
  :root { --notch-w: 128px; --drawer-h: 300px; }
  .brand span { display: none; }
  .drawer-grid { grid-template-columns: 1fr; grid-template-rows: auto auto; }
  .col-right { flex-direction: row; }
  .col-right .music { flex: 1; }
  .mirror { display: none; }
  .notch.has-activity:not(.is-open) { width: calc(var(--notch-w) + 96px); }
  .hero { padding-top: calc(var(--drawer-h) + 48px); }
  .btn { padding: 13px 18px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .notch, .drawer, .ear, .faq summary::after { transition: none !important; }
  .bars i { animation: none; height: 70%; }
}

@media (max-width: 640px) {
  .br-wide { display: none; }
}
