/* sentit — editorial paper & ink, with a single vermilion accent. */
@font-face {
  font-family: "Instrument Sans";
  font-style: normal;
  font-display: swap;
  font-weight: 400 700;
  src: url(/fonts/instrument-sans-latin-wght-normal.woff2) format("woff2");
  unicode-range:
    U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC,
    U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212,
    U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Instrument Sans";
  font-style: normal;
  font-display: swap;
  font-weight: 400 700;
  src: url(/fonts/instrument-sans-latin-ext-wght-normal.woff2) format("woff2");
  unicode-range:
    U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304,
    U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB,
    U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Instrument Serif";
  font-style: normal;
  font-display: swap;
  font-weight: 400;
  src: url(/fonts/instrument-serif-latin-400-normal.woff2) format("woff2");
  unicode-range:
    U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC,
    U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212,
    U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Instrument Serif";
  font-style: normal;
  font-display: swap;
  font-weight: 400;
  src: url(/fonts/instrument-serif-latin-ext-400-normal.woff2) format("woff2");
  unicode-range:
    U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304,
    U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB,
    U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Instrument Serif";
  font-style: italic;
  font-display: swap;
  font-weight: 400;
  src: url(/fonts/instrument-serif-latin-400-italic.woff2) format("woff2");
}

:root {
  color-scheme: light;
  --bg: #f5f4f0;
  --surface: #ffffff;
  --surface-2: #fbfaf7;
  --sunken: #ecebe5;
  --field: #ffffff;
  --ink: #141413;
  --ink-2: #3b3a36;
  --muted: #67665f;
  --faint: #a4a39c;
  --line: rgb(20 20 19 / 8%);
  --line-strong: rgb(20 20 19 / 15%);
  --accent: #ff4f1a;
  --accent-ink: #ffffff;
  --accent-soft: rgb(255 79 26 / 14%);
  --accent-text: #d63d0b;
  /* Interactive fills and focus rings that must meet contrast. */
  --accent-strong: #c93809;
  --on-accent: #ffffff;
  --focus: #c93809;
  --live: #17733f;
  --live-soft: rgb(31 138 76 / 12%);
  --warn: #8a5200;
  --warn-soft: rgb(214 140 18 / 15%);
  --danger: #c4321b;
  --danger-soft: rgb(196 50 27 / 10%);
  --shadow-sm: 0 1px 2px rgb(20 20 19 / 5%), 0 1px 1px rgb(20 20 19 / 3%);
  --shadow-md:
    0 2px 4px rgb(20 20 19 / 4%), 0 8px 24px -6px rgb(20 20 19 / 12%);
  --shadow-lg:
    0 4px 8px rgb(20 20 19 / 4%), 0 24px 64px -12px rgb(20 20 19 / 24%);
  --sans:
    "Instrument Sans", ui-sans-serif, system-ui, -apple-system, "Segoe UI",
    Roboto, "Helvetica Neue", Arial, sans-serif;
  --serif:
    "Instrument Serif", "Iowan Old Style", "Apple Garamond", Baskerville,
    Georgia, serif;
  --mono: ui-monospace, "SF Mono", SFMono-Regular, Menlo, Consolas, monospace;
  --radius-sm: 10px;
  --radius: 16px;
  --radius-lg: 22px;
  --gutter: clamp(16px, 4vw, 48px);
  --page-width: 1040px;
  --header: 64px;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
  /* File-type tiles. */
  --tile-image: #f7e2d6;
  --tile-image-ink: #9b4419;
  --tile-video: #e6e0f6;
  --tile-video-ink: #5a3fa6;
  --tile-audio: #dcefe4;
  --tile-audio-ink: #1d6b47;
  --tile-document: #dde7f4;
  --tile-document-ink: #2a5a90;
  --tile-design: #f5dde6;
  --tile-design-ink: #9f3159;
  --tile-archive: #efe6d2;
  --tile-archive-ink: #775e1d;
  --tile-font: #e7e6e0;
  --tile-font-ink: #3f3e39;
  --tile-code: #dfe4e9;
  --tile-code-ink: #374759;
  --tile-other: #ecebe5;
  --tile-other-ink: #6b6a64;
  --tile-edge: #ffffff;
}

/* Base */
* {
  box-sizing: border-box;
}
[hidden] {
  display: none !important;
}
html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}
body {
  margin: 0;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--ink);
  font: 15px/1.55 var(--sans);
  font-optical-sizing: auto;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}
::selection {
  background: var(--accent-soft);
}
a {
  color: inherit;
  text-decoration: none;
}
button,
input,
textarea,
select {
  font: inherit;
  color: inherit;
}
button {
  cursor: pointer;
}
button:disabled {
  cursor: default;
}
img {
  max-width: 100%;
}
.icon,
.mark {
  flex-shrink: 0;
  display: block;
}
:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
}
h1,
h2,
h3,
p,
dl,
dd,
ol,
ul {
  margin: 0;
}
h1 {
  font: 400 clamp(40px, 4.6vw, 62px) / 1.02 var(--serif);
  letter-spacing: -0.012em;
  overflow-wrap: anywhere;
  text-wrap: balance;
}
h2 {
  font-size: 15px;
  font-weight: 600;
  line-height: 1.35;
  letter-spacing: -0.005em;
}
h3 {
  font-size: 15px;
  font-weight: 600;
  line-height: 1.35;
}
strong,
b {
  font-weight: 600;
}
p {
  color: var(--muted);
  text-wrap: pretty;
}
.eyebrow {
  display: inline-block;
  font: 500 11px/1.4 var(--mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  overflow-wrap: anywhere;
}
.lede {
  font-size: 16px;
  margin-top: 12px;
  max-width: 62ch;
}
.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
}
.skip-link {
  position: absolute;
  left: 12px;
  top: -60px;
  z-index: 100;
  padding: 10px 16px;
  border-radius: 999px;
  background: var(--ink);
  color: var(--bg);
}
.skip-link:focus {
  top: 12px;
}

/* Header, content and footer use the same page frame across the site and app. */
.public-actions {
  grid-column: 3;
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 16px;
}
.public-actions .text-link[aria-current="page"] {
  color: var(--muted);
}
.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: color-mix(in srgb, var(--bg) 84%, transparent);
  -webkit-backdrop-filter: saturate(160%) blur(16px);
  backdrop-filter: saturate(160%) blur(16px);
  border-bottom: 1px solid var(--line);
}
.site-header-inner {
  width: min(100% - 2 * var(--gutter), var(--page-width));
  height: var(--header);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 24px;
  position: relative;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  width: fit-content;
  color: var(--ink);
}
.brand-mark circle {
  fill: var(--accent);
}
.brand-mark path {
  fill: none;
  stroke: var(--accent-ink);
  stroke-width: 2.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.brand-word {
  font: 400 26px/1 var(--serif);
  letter-spacing: -0.01em;
  transform: translateY(-1px);
}
.brand:hover .brand-mark {
  transform: rotate(-12deg);
}
.brand-mark {
  transition: transform 0.35s var(--ease);
}
.main-nav {
  display: inline-flex;
  gap: 2px;
  padding: 4px;
  border-radius: 999px;
  background: var(--sunken);
  border: 1px solid var(--line);
}
.main-nav a {
  padding: 6px 14px;
  border-radius: 999px;
  font-size: 13.5px;
  font-weight: 500;
  color: var(--muted);
  transition:
    color 0.15s,
    background 0.15s;
}
.main-nav a:hover {
  color: var(--ink);
}
.main-nav a.selected,
.main-nav a[aria-current="page"] {
  background: var(--surface);
  color: var(--ink);
  box-shadow: var(--shadow-sm);
}
.header-actions {
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 12px;
}
.header-note {
  grid-column: 3;
  justify-self: end;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12.5px;
  color: var(--muted);
}
.account-menu,
.mobile-menu {
  position: relative;
}
.account-menu summary,
.mobile-menu summary {
  list-style: none;
  cursor: pointer;
}
.account-menu summary::-webkit-details-marker,
.mobile-menu summary::-webkit-details-marker {
  display: none;
}
.avatar {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--ink);
  color: var(--bg);
  font: 400 18px/1 var(--serif);
  transition: box-shadow 0.15s;
}
.account-avatar {
  position: relative;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  --usage-color: var(--accent);
}
.avatar-usage {
  position: absolute;
  inset: 0;
  transform: rotate(-90deg);
  fill: none;
  stroke-width: 2.5;
}
.avatar-usage-track {
  stroke: var(--line-strong);
}
.avatar-usage-fill {
  stroke: var(--usage-color);
}
.account-menu summary {
  border-radius: 50%;
}
.account-menu[open] .account-avatar,
.account-menu summary:hover .account-avatar {
  box-shadow: 0 0 0 4px var(--accent-soft);
}
.menu-panel,
.mobile-menu-panel {
  position: absolute;
  right: 0;
  top: calc(100% + 10px);
  z-index: 50;
  width: 260px;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-lg);
  animation: pop 0.16s var(--ease);
}
.menu-panel {
  width: min(300px, calc(100vw - 2 * var(--gutter)));
  max-height: calc(100dvh - var(--header) - 24px);
  overflow-y: auto;
}
.menu-panel > form,
.mobile-menu-panel > form {
  margin: 0;
  padding: 0;
}
.menu-identity {
  display: flex;
  flex-direction: column;
  padding: 10px 10px 14px;
  margin: 0;
  border-bottom: 1px solid var(--line);
  overflow-wrap: anywhere;
}
.menu-identity strong {
  color: var(--ink);
  font-size: 14px;
}
.menu-identity span {
  font-size: 12.5px;
}
.menu-plan {
  padding: 14px 10px;
  margin-bottom: 4px;
  border-bottom: 1px solid var(--line);
}
.menu-plan-heading,
.menu-plan-name,
.menu-usage-heading,
.menu-billing {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.menu-plan-name {
  justify-content: flex-start;
  font-size: 13px;
  font-weight: 600;
}
.menu-plan-name .icon {
  color: var(--accent-text);
}
.menu-plan-status {
  padding: 3px 7px;
  border-radius: 6px;
  background: var(--sunken);
  color: var(--muted);
  font-size: 10px;
  font-weight: 600;
}
.menu-plan-status[data-attention="true"] {
  background: var(--warn-soft);
  color: var(--warn);
}
.menu-subscription {
  margin-top: 5px;
  font-size: 12px;
}
.menu-usage {
  display: block;
  margin: 16px 0;
  border-radius: 3px;
  --usage-color: var(--accent);
}
[data-usage-tone="high"] {
  --usage-color: var(--warn);
}
[data-usage-tone="full"] {
  --usage-color: var(--danger);
}
.menu-usage-heading {
  margin-bottom: 8px;
  font-size: 12px;
  color: var(--ink-2);
}
.menu-usage-heading > :last-child {
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.menu-usage progress {
  display: block;
  width: 100%;
  height: 5px;
  border: 0;
  border-radius: 999px;
  overflow: hidden;
  appearance: none;
  background: var(--sunken);
  color: var(--usage-color);
}
.menu-usage progress::-webkit-progress-bar {
  background: var(--sunken);
}
.menu-usage progress::-webkit-progress-value {
  border-radius: 999px;
  background: var(--usage-color);
}
.menu-usage progress::-moz-progress-bar {
  border-radius: 999px;
  background: var(--usage-color);
}
.menu-usage-caption,
.menu-usage-warning {
  display: block;
  margin-top: 7px;
  color: var(--muted);
  font-size: 11.5px;
}
.menu-usage-caption strong {
  color: var(--ink-2);
  font-weight: 500;
}
.menu-usage-warning {
  color: var(--danger);
}
.menu-free-space {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: -2px 0 14px;
  color: var(--ink-2);
  font-size: 12px;
  line-height: 1.5;
}
.menu-free-space .icon {
  flex-shrink: 0;
}
.menu-upgrade {
  gap: 8px;
  min-height: 38px;
  padding: 8px 10px;
  font-size: 12px;
}
.menu-upgrade .icon:last-child {
  margin-left: auto;
}
.menu-upgrade-caption {
  margin-top: 7px;
  text-align: center;
  font-size: 10.5px;
}
.menu-billing {
  padding: 4px 0;
  font-size: 12px;
  font-weight: 500;
  color: var(--accent-text);
}
.menu-billing:hover {
  text-decoration: underline;
}
.menu-item {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  min-height: 40px;
  padding: 8px 10px;
  border: 0;
  border-radius: var(--radius-sm);
  background: transparent;
  font-size: 14px;
  text-align: left;
  color: var(--ink-2);
}
.menu-item:hover {
  background: var(--sunken);
  color: var(--ink);
}
.mobile-menu {
  display: none;
}
@keyframes pop {
  from {
    opacity: 0;
    transform: translateY(-4px) scale(0.98);
  }
}

/* Page frame */
.main,
.recipient-main,
.auth-main {
  flex: 1;
  width: min(100% - 2 * var(--gutter), var(--page-width));
  margin: 0 auto;
  padding: 48px 0 96px;
}
.page-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 32px;
}
.page-heading > div {
  min-width: 0;
}
.page-heading .pill {
  margin-bottom: 14px;
}
.back-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 20px;
  padding: 6px 12px 6px 8px;
  margin-left: -8px;
  border-radius: 999px;
  color: var(--muted);
  font-size: 13.5px;
  font-weight: 500;
  overflow-wrap: anywhere;
  transition:
    background 0.15s,
    color 0.15s;
}
.back-link:hover {
  background: var(--sunken);
  color: var(--ink);
}
.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  padding: 24px;
}
.card > h2 + p {
  margin-top: 6px;
}

/* Controls */
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 42px;
  padding: 9px 20px;
  border: 1px solid transparent;
  border-radius: 999px;
  background: var(--ink);
  color: var(--bg);
  font-size: 14px;
  font-weight: 550;
  line-height: 1.2;
  text-align: center;
  white-space: nowrap;
  transition:
    background 0.18s var(--ease),
    color 0.18s var(--ease),
    border-color 0.18s,
    transform 0.18s var(--ease),
    box-shadow 0.18s;
}
.button:hover:not(:disabled) {
  background: var(--accent-strong);
  color: var(--on-accent);
}
.button:active:not(:disabled) {
  transform: scale(0.98);
}
.button.primary {
  background: var(--accent-strong);
  color: var(--on-accent);
}
.button.primary:hover:not(:disabled) {
  background: var(--ink);
  color: var(--bg);
}
.button:disabled {
  opacity: 0.45;
}
.button.ghost,
.button.secondary {
  background: transparent;
  color: var(--ink);
  border-color: var(--line-strong);
}
.button.ghost:hover:not(:disabled),
.button.secondary:hover:not(:disabled) {
  background: var(--sunken);
  color: var(--ink);
}
.button.small {
  min-height: 34px;
  padding: 6px 14px;
  font-size: 13px;
}
.button.wide {
  width: 100%;
}
.text-button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 36px;
  padding: 6px 2px;
  border: 0;
  background: transparent;
  color: var(--muted);
  font-size: 13.5px;
  font-weight: 500;
  text-align: left;
  transition: color 0.15s;
}
.text-button:hover:not(:disabled) {
  color: var(--ink);
}
.text-button:disabled {
  opacity: 0.45;
}
.text-button.danger:hover:not(:disabled) {
  color: var(--danger);
}
.link-button {
  display: inline;
  padding: 0;
  border: 0;
  background: none;
  color: var(--ink);
  font-weight: 550;
  text-decoration: underline;
  text-decoration-color: var(--accent);
  text-decoration-thickness: 1.5px;
  text-underline-offset: 4px;
}
.link-button:hover {
  color: var(--accent-text);
}
.text-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--ink);
  font-size: 13.5px;
  font-weight: 550;
}
.text-link:hover {
  color: var(--accent-text);
}
.icon-button {
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--muted);
  transition:
    background 0.15s,
    color 0.15s;
}
.icon-button:hover:not(:disabled) {
  background: var(--sunken);
  color: var(--ink);
}
.icon-button:disabled {
  opacity: 0.35;
}
.icon-button.is-copied {
  color: var(--live);
}
.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 24px;
  padding: 0 10px;
  border-radius: 999px;
  background: var(--sunken);
  color: var(--ink-2);
  font-size: 12px;
  font-weight: 550;
  white-space: nowrap;
}
.pill::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
  opacity: 0.7;
}
.pill[data-tone="live"] {
  background: var(--live-soft);
  color: var(--live);
}
.pill[data-tone="live"]::before {
  opacity: 1;
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--live) 25%, transparent);
  animation: pulse 2.4s ease-in-out infinite;
}
.pill[data-tone="warn"] {
  background: var(--warn-soft);
  color: var(--warn);
}
.pill[data-tone="expired"] {
  background: var(--danger-soft);
  color: var(--danger);
}
.pill[data-tone="draft"],
.pill[data-tone="archived"] {
  color: var(--muted);
}
@keyframes pulse {
  50% {
    box-shadow: 0 0 0 5px color-mix(in srgb, var(--live) 0%, transparent);
  }
}
.chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 34px;
  padding: 0 14px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: transparent;
  color: var(--ink-2);
  font-size: 13.5px;
  font-weight: 500;
  transition:
    background 0.15s,
    color 0.15s,
    border-color 0.15s;
}
.chip span {
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.chip:hover {
  border-color: var(--ink-2);
}
.chip[aria-pressed="true"] {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--bg);
}
.chip[aria-pressed="true"] span {
  color: color-mix(in srgb, var(--bg) 60%, transparent);
}

/* Forms */
label {
  display: block;
  margin: 18px 0 8px;
  font-size: 13px;
  font-weight: 550;
  color: var(--ink-2);
}
label span {
  margin-left: 4px;
  color: var(--muted);
  font-weight: 400;
}
input,
textarea,
select {
  display: block;
  width: 100%;
  min-width: 0;
  min-height: 44px;
  padding: 10px 14px;
  border: 1px solid var(--line-strong);
  border-radius: 12px;
  background: var(--field);
  color: var(--ink);
  box-shadow: none;
  transition:
    border-color 0.15s,
    box-shadow 0.15s;
}
input:hover,
textarea:hover {
  border-color: color-mix(in srgb, var(--ink) 28%, transparent);
}
input:focus,
textarea:focus,
select:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 4px var(--accent-soft);
}
textarea {
  resize: vertical;
  line-height: 1.6;
}
input::placeholder,
textarea::placeholder {
  color: var(--muted);
  opacity: 1;
}
input[aria-invalid="true"],
textarea[aria-invalid="true"] {
  border-color: var(--danger);
}
input[aria-invalid="true"]:focus {
  box-shadow: 0 0 0 4px var(--danger-soft);
}
input[readonly] {
  background: var(--surface-2);
}
input[type="date"] {
  font-variant-numeric: tabular-nums;
}
input[type="checkbox"] {
  display: inline-block;
  width: 18px;
  height: 18px;
  min-height: 0;
  padding: 0;
  margin: 0;
  border-radius: 5px;
  accent-color: var(--accent);
  flex-shrink: 0;
  box-shadow: none;
}
input[type="search"] {
  padding-left: 40px;
  background: var(--field)
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' fill='none' stroke='%23999890' stroke-width='1.6' stroke-linecap='round' viewBox='0 0 24 24'%3E%3Cpath d='M11 4a7 7 0 1 0 0 14 7 7 0 0 0 0-14zM20 20l-4-4'/%3E%3C/svg%3E")
    no-repeat 14px center;
}
.fine-print {
  margin-top: 10px;
  font-size: 12.5px;
  line-height: 1.5;
}
.fine-details {
  margin-top: 8px;
  font-size: 12.5px;
  color: var(--muted);
}
.fine-details summary {
  width: fit-content;
  cursor: pointer;
  color: var(--ink-2);
  font-weight: 500;
}
.fine-details summary:hover {
  color: var(--ink);
}
.fine-details p {
  margin-top: 6px;
  line-height: 1.5;
}
.status-message {
  margin-top: 12px;
  font-size: 13px;
  overflow-wrap: anywhere;
}
.status-message:empty {
  display: none;
}
.field-error {
  margin-top: 8px;
  color: var(--danger);
  font-size: 12.5px;
}

/* Notices (sign-in steps, errors) */
.auth-main {
  display: grid;
  place-items: center;
  padding: 40px 0 72px;
}
.narrow {
  width: min(100%, 460px);
  margin: 0 auto;
}
.notice {
  padding: 40px 36px 36px;
  text-align: center;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 28px;
  box-shadow: var(--shadow-md);
}
.notice h1 {
  font-size: clamp(34px, 5vw, 44px);
  margin: 10px 0 0;
}
.notice p {
  margin: 14px auto 0;
  max-width: 38ch;
}
.notice .button {
  margin-top: 24px;
}
.notice .text-button,
.notice .text-link {
  margin-top: 16px;
}
.notice-icon {
  width: 52px;
  height: 52px;
  margin: 0 auto 16px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--accent-text);
}
.notice form {
  margin-top: 8px;
}

/* Sign in */
/* A warm wash behind the page; the noise layer keeps the gradient from banding. */
.auth-glow {
  --glow: rgb(255 79 26 / 22%);
  --glow-rose: rgb(255 61 110 / 14%);
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.05'/%3E%3C/svg%3E"),
    radial-gradient(540px 440px at 90% 16%, var(--glow), transparent 70%),
    radial-gradient(480px 380px at 58% 92%, var(--glow-rose), transparent 70%),
    radial-gradient(380px 320px at 0% 0%, var(--glow-rose), transparent 70%);
}

.auth-split {
  width: 100%;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  align-items: center;
  gap: clamp(32px, 6vw, 96px);
}
.auth-headline {
  margin-top: 18px;
  font: 400 clamp(36px, 7.4vw, 82px) / 1.04 var(--serif);
  letter-spacing: -0.005em;
  color: var(--ink);
  text-wrap: balance;
}
.auth-headline em {
  color: var(--accent);
}
.auth-lede {
  margin-top: 28px;
  max-width: 440px;
  color: var(--ink-2);
  font-size: clamp(17px, 1.5vw, 19px);
  line-height: 1.45;
}
.auth-point-number {
  font: 500 11px/1 var(--mono);
  color: var(--accent-text);
  font-variant-numeric: tabular-nums;
}
.auth-plan-link {
  margin-top: 8px;
  font-size: 13px;
}
.auth-side {
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 28px;
  background: color-mix(in srgb, var(--surface) 78%, transparent);
  -webkit-backdrop-filter: saturate(140%) blur(24px);
  backdrop-filter: saturate(140%) blur(24px);
  box-shadow: var(--shadow-lg);
}
.chat-bubble {
  justify-self: start;
  max-width: 80%;
  padding: 9px 15px;
  border-radius: 20px 20px 20px 6px;
  background: color-mix(in srgb, var(--surface) 78%, transparent);
  -webkit-backdrop-filter: saturate(140%) blur(24px);
  backdrop-filter: saturate(140%) blur(24px);
  box-shadow: var(--shadow-sm);
  color: var(--ink);
  font-size: 15px;
  line-height: 1.35;
  transform-origin: bottom left;
  animation: bubble 0.55s var(--ease) 0.6s backwards;
}
.chat-bubble.mine {
  justify-self: end;
  transform-origin: bottom right;
  border-radius: 20px 20px 6px 20px;
  background: var(--accent-strong);
  color: var(--on-accent);
  font-weight: 500;
  animation-delay: 1.8s;
}
@keyframes bubble {
  from {
    opacity: 0;
    transform: translateY(8px) scale(0.96);
  }
}
.login-form {
  min-width: 0;
  padding: 36px;
}
.login-form h1 {
  font: 400 40px/1.15 var(--serif);
  letter-spacing: -0.012em;
  text-align: left;
  text-wrap: pretty;
}
.login-intro p {
  margin-top: 8px;
}
.login-form > p {
  margin-top: 10px;
}
.login-form > .fine-print {
  margin-top: 20px;
  color: var(--muted);
  text-align: left;
}
.login-form > .fine-print a:hover {
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.login-form > .fine-print a:focus-visible {
  border-radius: 3px;
  color: var(--ink);
}
.login-form .button {
  margin-top: 18px;
  min-height: 48px;
}

/* Clerk sign-in, matched to the app's own fields and buttons. The ID scope
   outranks Clerk's attribute-qualified rules. */
#clerk-sign-in {
  width: 100%;
  min-width: 0;
  margin-top: 24px;
  text-align: left;
}
#clerk-sign-in .cl-cardBox,
#clerk-sign-in .cl-card,
#clerk-sign-in .cl-main,
#clerk-sign-in .cl-form {
  width: 100%;
  min-width: 0;
  max-width: none;
  gap: 24px;
  text-align: left;
}
#clerk-sign-in .cl-cardBox {
  gap: 0;
}
#clerk-sign-in .cl-form {
  margin: 0;
}
#clerk-sign-in .cl-footer:has(.cl-footerAction) {
  margin-top: 24px;
  padding: 0;
  gap: 0;
}
#clerk-sign-in .cl-footerAction {
  justify-content: flex-start;
  text-align: left;
}
/* A later Clerk step owns its heading. With no rendered header (including
   loading and unavailable states), the application's introduction stays visible. */
.login-form:has(#clerk-sign-in .cl-card:not(.cl-signIn-start) .cl-header)
  .login-intro {
  display: none;
}
.login-form:has(#clerk-sign-in .cl-card:not(.cl-signIn-start) .cl-header)
  #clerk-sign-in {
  margin-top: 0;
}
/* The page heading already introduces the first step. */
#clerk-sign-in .cl-signIn-start .cl-header {
  display: none;
}
#clerk-sign-in .cl-header {
  width: 100%;
  gap: 0;
  align-items: flex-start;
  text-align: left;
}
#clerk-sign-in .cl-header > div {
  width: 100%;
  min-width: 0;
  gap: 0;
}
#clerk-sign-in .cl-headerTitle {
  margin: 0;
  font: 400 40px/1.15 var(--serif);
  letter-spacing: -0.012em;
  text-align: left;
  text-wrap: pretty;
}
#clerk-sign-in .cl-headerSubtitle {
  margin-top: 8px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.5;
  text-align: left;
}
#clerk-sign-in .cl-identityPreview {
  width: 100%;
  min-width: 0;
  margin-top: 8px;
  gap: 8px;
  justify-content: flex-start;
  align-items: flex-start;
}
#clerk-sign-in .cl-identityPreviewText {
  min-width: 0;
  overflow-wrap: anywhere;
  white-space: normal;
  text-align: left;
  color: var(--ink-2);
  line-height: 1.5;
}
#clerk-sign-in .cl-identityPreviewEditButton {
  flex-shrink: 0;
}
#clerk-sign-in .cl-identityPreviewEditButton,
#clerk-sign-in .cl-formResendCodeLink {
  color: var(--accent-text);
}
#clerk-sign-in .cl-form:has(.cl-otpCodeField) {
  gap: 12px;
}
#clerk-sign-in .cl-otpCodeField,
#clerk-sign-in .cl-otpCodeFieldInputContainer {
  width: 100%;
  min-width: 0;
  gap: 0;
  align-items: stretch;
}
#clerk-sign-in .cl-otpCodeFieldInputContainer {
  max-width: none;
  align-self: flex-start;
}
#clerk-sign-in .cl-otpCodeFieldInputContainer > div {
  width: 100%;
}
#clerk-sign-in .cl-otpCodeFieldInputs {
  width: 100%;
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 8px;
}
/* Clerk's transparent input extends beyond the cells; contain that overlay
   without clipping the visible cells' focus rings. */
#clerk-sign-in .cl-otpCodeFieldInputs + div {
  overflow: clip;
}
#clerk-sign-in .cl-otpCodeFieldInput {
  width: 100%;
  min-width: 0;
  max-width: none;
  height: auto;
  min-height: 0;
  max-height: none;
  aspect-ratio: 1;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid color-mix(in srgb, var(--ink) 30%, var(--field));
  border-radius: 10px;
  background: var(--field);
  box-shadow: none;
  color: var(--ink);
  font-size: 20px;
  text-align: center;
}
#clerk-sign-in .cl-otpCodeFieldInput[data-focus-within="true"] {
  border-color: var(--accent);
  box-shadow: 0 0 0 4px var(--accent-soft);
}
#clerk-sign-in .cl-formResendCodeLink {
  align-self: flex-start;
  justify-content: flex-start;
  text-align: left;
  white-space: normal;
  line-height: 1.5;
}
#clerk-sign-in .cl-formResendCodeLink:disabled,
#clerk-sign-in .cl-formResendCodeLink[aria-disabled="true"] {
  color: var(--muted);
  opacity: 1;
}
#clerk-sign-in .cl-formFieldErrorText,
#clerk-sign-in .cl-otpCodeFieldErrorText {
  color: var(--danger);
  width: 100%;
  left: 0;
  transform: none;
  justify-content: flex-start;
  text-align: left;
}
#clerk-sign-in .cl-formFieldLabel {
  margin: 0;
  color: var(--ink-2);
  font-size: 13px;
  font-weight: 550;
}
#clerk-sign-in .cl-formFieldInput {
  min-height: 44px;
  max-height: none;
  padding: 10px 14px;
  border: 1px solid var(--line-strong);
  border-radius: 12px;
  background: var(--field);
  box-shadow: none;
  font-size: 15px;
}
#clerk-sign-in .cl-formFieldInput:hover {
  border-color: color-mix(in srgb, var(--ink) 28%, transparent);
}
#clerk-sign-in .cl-formFieldInput:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 4px var(--accent-soft);
}
#clerk-sign-in .cl-formFieldInput[aria-invalid="true"],
#clerk-sign-in .cl-otpCodeFieldInput[aria-invalid="true"],
#clerk-sign-in .cl-otpCodeFieldInput[data-feedback="error"] {
  border-color: var(--danger);
}
#clerk-sign-in .cl-formButtonPrimary {
  width: 100%;
  min-height: 48px;
  justify-content: center;
  text-align: center;
  border-radius: 999px;
  background: var(--ink);
  color: var(--bg);
  box-shadow: none;
  font-size: 14px;
  font-weight: 550;
  transition:
    background 0.18s var(--ease),
    color 0.18s var(--ease),
    transform 0.18s var(--ease);
}
#clerk-sign-in .cl-formButtonPrimary:hover:not(:disabled) {
  background: var(--accent-strong);
  color: var(--on-accent);
}
#clerk-sign-in .cl-formButtonPrimary:active:not(:disabled) {
  transform: scale(0.98);
}
#clerk-sign-in .cl-formButtonPrimary:focus-visible {
  box-shadow: none;
  outline: 2px solid var(--focus);
  outline-offset: 2px;
}
/* No gradient sheen, arrow glyph, "Secured by Clerk" or development badge. */
#clerk-sign-in .cl-formButtonPrimary::after,
#clerk-sign-in .cl-buttonArrowIcon,
#clerk-sign-in .cl-footerItem,
#clerk-sign-in .cl-footer:not(:has(.cl-footerAction)) {
  display: none;
}

/* Deliveries */
.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 24px;
}
.delivery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(268px, 1fr));
  gap: 20px;
}
.delivery-card {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 8px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  transition:
    transform 0.25s var(--ease),
    box-shadow 0.25s var(--ease),
    border-color 0.25s;
}
.delivery-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: var(--line-strong);
}
.delivery-card:has(.delivery-link:focus-visible) {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
}
.delivery-cover {
  aspect-ratio: 16 / 10;
  border-radius: 15px;
  overflow: hidden;
  background: var(--sunken);
  /* Decorative tiles must not intercept the card's stretched link. */
  pointer-events: none;
}
.delivery-cover.mosaic {
  display: grid;
  gap: 2px;
}
.delivery-cover.mosaic .file-thumb {
  width: 100%;
  height: 100%;
  border-radius: 0;
}
.delivery-cover.mosaic img {
  transition: transform 0.6s var(--ease);
}
.delivery-card:hover .delivery-cover.mosaic img {
  transform: scale(1.04);
}
.delivery-cover[data-count="2"] {
  grid-template-columns: 1fr 1fr;
}
.delivery-cover[data-count="3"] {
  grid-template-columns: 1.6fr 1fr;
  grid-template-rows: 1fr 1fr;
}
.delivery-cover[data-count="3"] > :first-child {
  grid-row: span 2;
}
.delivery-cover[data-count="4"] {
  grid-template-columns: 1fr 1fr;
  grid-template-rows: 1fr 1fr;
}
.delivery-cover.stack {
  display: flex;
  align-items: center;
  justify-content: center;
  background:
    radial-gradient(
      circle at 50% 120%,
      color-mix(in srgb, var(--accent) 8%, transparent),
      transparent 60%
    ),
    var(--sunken);
}
.delivery-cover.stack .file-thumb {
  width: 64px;
  height: 80px;
  border-radius: 10px;
  margin: 0 -10px;
  box-shadow: var(--shadow-md);
  border: 2px solid var(--tile-edge);
  transition: transform 0.35s var(--ease);
}
.delivery-cover.stack[data-count="2"] .file-thumb:first-child,
.delivery-cover.stack[data-count="3"] .file-thumb:first-child {
  transform: rotate(-8deg) translateY(4px);
}
.delivery-cover.stack .file-thumb:nth-child(2) {
  z-index: 1;
  transform: translateY(-4px);
}
.delivery-cover.stack .file-thumb:nth-child(3) {
  transform: rotate(8deg) translateY(4px);
}
.delivery-card:hover .delivery-cover.stack .file-thumb:first-child {
  transform: rotate(-12deg) translate(-6px, 4px);
}
.delivery-card:hover .delivery-cover.stack .file-thumb:nth-child(3) {
  transform: rotate(12deg) translate(6px, 4px);
}
.delivery-cover.empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
  background:
    repeating-linear-gradient(
      -45deg,
      transparent 0 10px,
      var(--line) 10px 11px
    ),
    var(--surface-2);
}
.delivery-body {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: 14px 8px 4px;
}
.delivery-topline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.delivery-when {
  font-size: 12.5px;
  color: var(--muted);
  text-align: right;
}
.delivery-card h3 {
  margin-top: 12px;
  font-size: 16px;
  line-height: 1.3;
  overflow-wrap: anywhere;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.delivery-link::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
}
.delivery-link:focus-visible {
  outline: none;
}
.delivery-meta {
  margin-top: 4px;
  font-size: 13px;
}
.delivery-foot {
  margin-top: auto;
  padding-top: 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 44px;
}
.delivery-activity {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12.5px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.row-actions {
  position: relative;
  z-index: 1;
  display: flex;
  gap: 2px;
}
.filter-empty {
  padding: 48px 0;
  text-align: center;
}
.empty-state {
  padding: 72px 24px;
  text-align: center;
  border: 1px dashed var(--line-strong);
  border-radius: 28px;
  background: var(--surface-2);
}
.empty-state h2 {
  font: 400 clamp(34px, 4vw, 48px) / 1.05 var(--serif);
  letter-spacing: -0.01em;
}
.empty-state p {
  max-width: 46ch;
  margin: 14px auto 0;
}
.empty-state form {
  margin-top: 28px;
}
.empty-state.compact {
  padding: 48px 24px;
}
.empty-state.compact h2 {
  font-size: 32px;
}
.empty-art {
  display: flex;
  justify-content: center;
  margin-bottom: 28px;
}
.empty-art span {
  width: 54px;
  height: 68px;
  margin: 0 -8px;
  border-radius: 10px;
  border: 2px solid var(--tile-edge);
  box-shadow: var(--shadow-md);
}
.empty-art span:nth-child(1) {
  background: var(--tile-image);
  transform: rotate(-10deg) translateY(6px);
}
.empty-art span:nth-child(2) {
  z-index: 1;
  background: var(--accent);
}
.empty-art span:nth-child(3) {
  background: var(--tile-document);
  transform: rotate(10deg) translateY(6px);
}

/* File tiles */
.file-thumb {
  --tile: var(--tile-other);
  --tile-ink: var(--tile-other-ink);
  position: relative;
  display: grid;
  place-items: center;
  overflow: hidden;
  flex-shrink: 0;
  border-radius: 12px;
  background: var(--tile);
  color: var(--tile-ink);
}
.file-thumb[data-kind="image"] {
  --tile: var(--tile-image);
  --tile-ink: var(--tile-image-ink);
}
.file-thumb[data-kind="video"] {
  --tile: var(--tile-video);
  --tile-ink: var(--tile-video-ink);
}
.file-thumb[data-kind="audio"] {
  --tile: var(--tile-audio);
  --tile-ink: var(--tile-audio-ink);
}
.file-thumb[data-kind="document"] {
  --tile: var(--tile-document);
  --tile-ink: var(--tile-document-ink);
}
.file-thumb[data-kind="design"] {
  --tile: var(--tile-design);
  --tile-ink: var(--tile-design-ink);
}
.file-thumb[data-kind="archive"] {
  --tile: var(--tile-archive);
  --tile-ink: var(--tile-archive-ink);
}
.file-thumb[data-kind="font"] {
  --tile: var(--tile-font);
  --tile-ink: var(--tile-font-ink);
}
.file-thumb[data-kind="code"] {
  --tile: var(--tile-code);
  --tile-ink: var(--tile-code-ink);
}
.file-ext {
  font: 600 10.5px/1 var(--mono);
  letter-spacing: 0.06em;
}
.file-thumb img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.provider-badge {
  position: absolute;
  right: 4px;
  bottom: 4px;
  z-index: 1;
  display: grid;
  place-items: center;
  width: 20px;
  height: 20px;
  border-radius: 7px;
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

/* Composer */
.composer-heading {
  margin-bottom: 32px;
}
.composer-state {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
}
.composer-hint {
  font-size: 13px;
  color: var(--muted);
}
.composer-title {
  max-width: 22ch;
}
.composer-title[data-empty] {
  color: var(--muted);
  font-style: italic;
}
.composer-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(300px, 380px);
  gap: clamp(28px, 4vw, 56px);
  align-items: start;
}
.staging,
.details {
  min-width: 0;
}
.drop-zone {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 210px;
  padding: 32px 24px;
  text-align: center;
  border: 1.5px dashed var(--line-strong);
  border-radius: var(--radius-lg);
  background:
    radial-gradient(
      ellipse at 50% 0%,
      color-mix(in srgb, var(--accent) 6%, transparent),
      transparent 70%
    ),
    var(--surface-2);
  cursor: pointer;
  transition:
    border-color 0.2s,
    background-color 0.2s,
    transform 0.2s var(--ease);
}
.drop-zone:hover {
  border-color: color-mix(in srgb, var(--accent) 60%, var(--line-strong));
}
.drop-zone.dragging {
  border-color: var(--accent);
  background-color: var(--accent-soft);
  transform: scale(1.01);
}
.drop-icon {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  margin-bottom: 14px;
  border-radius: 50%;
  background: var(--surface);
  color: var(--accent);
  box-shadow: var(--shadow-md);
  transition: transform 0.3s var(--ease);
}
.drop-zone:hover .drop-icon,
.drop-zone.dragging .drop-icon {
  transform: translateY(-3px);
}
.drop-title {
  color: var(--ink);
  font: 400 26px/1.15 var(--serif);
}
.drop-sub {
  margin-top: 6px;
  font-size: 14px;
}
.source-buttons {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 14px 0 36px;
}
.source-buttons > span {
  margin-right: 4px;
  font-size: 13px;
  color: var(--muted);
}
.source-button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 38px;
  padding: 0 16px 0 12px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: var(--surface);
  color: var(--ink);
  font-size: 13.5px;
  font-weight: 550;
  box-shadow: var(--shadow-sm);
  transition:
    border-color 0.15s,
    transform 0.15s var(--ease);
}
.source-button:hover:not(:disabled) {
  border-color: var(--ink-2);
  transform: translateY(-1px);
}
.source-button:disabled {
  opacity: 0.5;
}
.package-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}
.package-header h2 {
  font-size: 15px;
}
#file-summary {
  margin-left: 6px;
  font-weight: 400;
  color: var(--muted);
}
.view-toggle {
  display: inline-flex;
  padding: 3px;
  border-radius: 999px;
  background: var(--sunken);
  border: 1px solid var(--line);
}
.view-toggle button {
  display: grid;
  place-items: center;
  width: 32px;
  height: 28px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
}
.view-toggle button[aria-pressed="true"] {
  background: var(--surface);
  color: var(--ink);
  box-shadow: var(--shadow-sm);
}
.file-list {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}
.file-list:empty {
  display: none;
}
.file-empty {
  display: none;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  font-size: 14px;
  text-align: center;
}
.file-list:empty + .file-empty {
  display: block;
}
.file-row {
  position: relative;
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 72px;
  padding: 10px 10px 10px 12px;
  background: var(--surface);
  transition: background 0.15s;
}
.file-row + .file-row {
  border-top: 1px solid var(--line);
}
.file-row:hover {
  background: var(--surface-2);
}
.file-row[draggable="true"] {
  cursor: grab;
}
.file-row.is-dragging {
  opacity: 0.4;
}
.file-row .file-thumb {
  width: 52px;
  height: 52px;
}
.file-row[data-state="uploading"] .file-thumb img,
.file-row[data-state="failed"] .file-thumb,
.file-row[data-state="unavailable"] .file-thumb {
  opacity: 0.55;
}
.file-description {
  flex: 1;
  min-width: 0;
}
.file-description strong {
  display: block;
  font-size: 14.5px;
  font-weight: 550;
  overflow-wrap: anywhere;
}
/* Names read as editable: the pencil always shows, hover and focus add a tint. */
.file-name {
  display: inline-block;
  max-width: calc(100% + 12px);
  margin: -2px -6px;
  padding: 2px 6px;
  border: 0;
  border-radius: 6px;
  background: none;
  font-weight: inherit;
  text-align: left;
  cursor: text;
  transition: background 0.15s;
}
.file-name:hover,
.file-name:focus-visible {
  background: color-mix(in srgb, var(--ink) 6%, var(--line));
}
/* Inline so a wrapped name ends with the pencil after its last word. */
.file-name .icon {
  display: inline-block;
  margin-left: 6px;
  vertical-align: -1px;
  color: var(--muted);
  transition: color 0.15s;
}
.file-name:hover .icon,
.file-name:focus-visible .icon {
  color: var(--ink);
}
.file-rename {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: -6px 0;
}
.file-rename-input {
  min-height: 32px;
  padding: 4px 8px;
  border-radius: 8px;
  font-weight: inherit;
}
.file-rename-ext {
  flex-shrink: 0;
  color: var(--muted);
  font-weight: 400;
}
.file-description small {
  display: block;
  margin-top: 2px;
  font-size: 12.5px;
  color: var(--muted);
  overflow-wrap: anywhere;
  font-variant-numeric: tabular-nums;
}
.file-row[data-state="failed"] .file-description small,
.file-row[data-state="unavailable"] .file-description small {
  color: var(--danger);
}
.file-controls {
  display: flex;
  flex-shrink: 0;
  gap: 0;
  opacity: 0;
  transition: opacity 0.15s;
}
.file-row:hover .file-controls,
.file-row:focus-within .file-controls,
.file-row[data-state="failed"] .file-controls,
.file-row[data-state="unavailable"] .file-controls {
  opacity: 1;
}
/* A row shows Preview and Remove. Download original lives in the viewer, so
   it takes Preview's place only for files that have no preview. */
.file-controls > .preview-action:not([hidden]) ~ .download-original {
  display: none;
}
/* Pointer users reorder by dragging. The arrows stay for keyboard users,
   appearing once focus reaches the row's controls, and for touch screens. */
@media (hover: hover) {
  .file-controls:not(:has(:focus-visible)) > :is(.move-up, .move-down) {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip-path: inset(50%);
  }
}
.file-controls .remove-file:hover,
.file-controls .cancel-upload:hover {
  color: var(--danger);
  background: var(--danger-soft);
}
.file-progress {
  display: none;
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 0;
  height: 2px;
  overflow: hidden;
  border-radius: 2px;
  background: var(--line);
}
.file-row[data-state="uploading"] .file-progress {
  display: block;
}
.file-progress::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--accent);
  transform-origin: left;
  transform: scaleX(var(--progress, 0));
  transition: transform 0.25s linear;
}
.file-row:not([data-progress]) .file-progress::after {
  width: 35%;
  transform: none;
  animation: indeterminate 1.1s ease-in-out infinite;
}
@keyframes indeterminate {
  from {
    left: -35%;
  }
  to {
    left: 100%;
  }
}
/* Grid layout of the same rows. */
.file-list[data-view="grid"] {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 12px;
  border: 0;
  background: none;
  box-shadow: none;
  overflow: visible;
}
.file-list[data-view="grid"]:empty {
  display: none;
}
.file-list[data-view="grid"] .file-row {
  flex-direction: column;
  align-items: stretch;
  gap: 10px;
  padding: 6px 6px 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}
.file-list[data-view="grid"] .file-row + .file-row {
  border-top: 1px solid var(--line);
}
.file-list[data-view="grid"] .file-thumb {
  width: 100%;
  height: auto;
  aspect-ratio: 1;
  border-radius: 11px;
}
.file-list[data-view="grid"] .file-ext {
  font-size: 13px;
}
.file-list[data-view="grid"] .file-description {
  padding: 0 4px;
}
.file-list[data-view="grid"] .file-description strong,
.file-list[data-view="grid"] .file-name-text {
  font-size: 13px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
/* Clip the name text, not the button, so the pencil and focus ring stay. */
.file-list[data-view="grid"]
  .file-description
  strong:has(.file-name, .file-rename) {
  overflow: visible;
}
.file-list[data-view="grid"] .file-name {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.file-list[data-view="grid"] .file-name-text {
  min-width: 0;
}
.file-list[data-view="grid"] .file-name .icon {
  margin-left: 0;
}
.file-list[data-view="grid"] .file-controls {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  padding: 2px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--surface) 92%, transparent);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  box-shadow: var(--shadow-md);
}
.file-list[data-view="grid"] .file-controls .icon-button {
  width: 28px;
  height: 28px;
}
.file-list[data-view="grid"] .move-up .icon,
.file-list[data-view="grid"] .move-down .icon {
  transform: rotate(-90deg);
}
.file-list[data-view="grid"] .file-progress {
  left: 10px;
  right: 10px;
  bottom: 6px;
}
.details {
  position: sticky;
  top: calc(var(--header) + 24px);
  display: grid;
  gap: 16px;
}
.details-card label:first-child {
  margin-top: 0;
}
.form-actions {
  display: grid;
  gap: 8px;
  margin-top: 22px;
}
.form-actions .button {
  min-height: 46px;
}
.access-note {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  font-size: 12.5px;
}
#save-status {
  text-align: center;
}
.share-card {
  border-color: color-mix(in srgb, var(--live) 30%, var(--line));
  background:
    linear-gradient(
      180deg,
      color-mix(in srgb, var(--live) 7%, transparent),
      transparent 70%
    ),
    var(--surface);
}
.share-head {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
}
.share-head label {
  margin: 0;
}
.live-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--live);
  box-shadow: 0 0 0 4px var(--live-soft);
}
.share-field {
  display: flex;
  gap: 6px;
  padding: 4px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: var(--field);
}
.share-field input {
  min-height: 34px;
  padding: 6px 10px;
  border: 0;
  background: transparent;
  font: 12.5px/1.2 var(--mono);
  color: var(--ink-2);
  text-overflow: ellipsis;
}
.share-field input:focus {
  box-shadow: none;
}
.share-field:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 4px var(--accent-soft);
}
.share-card .text-link {
  margin-top: 12px;
}
.composer-branding {
  padding: 20px;
  background: var(--surface-2);
  box-shadow: none;
}
.composer-branding h2 {
  font: 600 15px/1.4 var(--sans);
  letter-spacing: normal;
}
.composer-branding p {
  margin-top: 8px;
  font-size: 13px;
  line-height: 1.6;
}
.composer-branding .text-link {
  margin-top: 12px;
  font-size: 13px;
}
.composer-branding-settings {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 0 8px;
  color: var(--muted);
  font-size: 13px;
}
.danger-actions {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  padding: 0 8px;
}
.drop-overlay {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: grid;
  place-items: center;
  padding: 16px;
  pointer-events: none;
  opacity: 0;
  background: color-mix(in srgb, var(--bg) 70%, transparent);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  transition: opacity 0.2s;
}
.drop-overlay span {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  padding: 40px 56px;
  border: 2px dashed var(--accent);
  border-radius: 28px;
  background: var(--surface);
  color: var(--ink);
  font: 400 30px/1.1 var(--serif);
  box-shadow: var(--shadow-lg);
  transform: scale(0.96);
  transition: transform 0.25s var(--ease);
}
.drop-overlay .icon {
  color: var(--accent);
}
body.dropping .drop-overlay {
  opacity: 1;
}
body.dropping .drop-overlay span {
  transform: none;
}

/* Archive */
.list-card {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}
.list-row {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr) auto auto 16px;
  align-items: center;
  gap: 18px;
  padding: 14px 18px;
  transition: background 0.15s;
}
.list-row + .list-row {
  border-top: 1px solid var(--line);
}
.list-row:hover {
  background: var(--surface-2);
}
.list-icon {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: var(--sunken);
  color: var(--muted);
}
.list-main {
  min-width: 0;
}
.list-main strong {
  display: block;
  overflow-wrap: anywhere;
}
.list-main small,
.list-meta {
  font-size: 12.5px;
  color: var(--muted);
}
.list-meta {
  display: flex;
  flex-direction: column;
  text-align: right;
}
.list-count {
  flex-direction: row;
  gap: 4px;
  color: var(--ink-2);
}
.list-count span {
  color: var(--muted);
}
.list-chevron {
  color: var(--faint);
}
.pager {
  margin-top: 20px;
}
.archive-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(280px, 1fr);
  gap: 20px;
  align-items: start;
}
.facts {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 16px;
}
.facts div {
  padding: 12px 14px;
  border-radius: 14px;
  background: var(--surface-2);
  border: 1px solid var(--line);
}
.facts dt {
  font-size: 12px;
  color: var(--muted);
}
.facts dd {
  margin-top: 2px;
  font: 400 26px/1.1 var(--serif);
}
.archived-file-list {
  list-style: none;
  padding: 0;
  margin-top: 20px;
}
.archived-file-list li {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
  padding: 10px 0;
  border-top: 1px solid var(--line);
  overflow-wrap: anywhere;
}
.archived-file-list .file-thumb {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  opacity: 0.7;
}
.archived-file-list .provider-badge {
  right: 2px;
  bottom: 2px;
  width: 15px;
  height: 15px;
  border-radius: 5px;
}
.archived-file-list .provider-badge .mark {
  width: 10px;
  height: 10px;
}
.archived-file-list strong {
  font-weight: 500;
  font-size: 14px;
}
.archived-file-list span:last-child {
  font-size: 12.5px;
  color: var(--muted);
}
.restore-card p {
  margin-top: 8px;
  font-size: 14px;
}
.restore-card form {
  margin-top: 20px;
}
.restore-card .fine-print {
  margin-top: 12px;
}

/* Connections */
.storage-notice {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-bottom: 20px;
  padding: 16px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: var(--surface-2);
  color: var(--ink-2);
}
.storage-notice > .icon {
  align-self: flex-start;
  margin-top: 2px;
  color: var(--warn);
}
.storage-notice[data-tone="full"] > .icon {
  color: var(--danger);
}
.storage-notice-copy {
  flex: 1 1 200px;
  min-width: 0;
  font-size: 13px;
  line-height: 1.5;
}
.storage-notice-copy strong {
  color: var(--ink);
  font-size: 14px;
}
.storage-notice-copy p {
  margin: 4px 0 0;
}
.storage-notice .button {
  gap: 8px;
  font-size: 12px;
}
.settings-storage .storage-notice {
  margin-top: 16px;
}
.notice-banner {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 20px;
  padding: 12px 16px;
  border-radius: 14px;
  background: var(--surface);
  border: 1px solid var(--line);
  color: var(--ink-2);
  font-size: 14px;
}
.notice-banner[data-tone="success"] {
  background: var(--live-soft);
  border-color: transparent;
  color: var(--live);
}
.notice-banner[data-tone="error"] {
  background: var(--danger-soft);
  border-color: transparent;
  color: var(--danger);
}
.connection-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
}
.provider-card {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.provider-head {
  display: flex;
  align-items: center;
  gap: 14px;
}
.provider-logo {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  border-radius: 16px;
  background: var(--surface-2);
  border: 1px solid var(--line);
}
.provider-head h2 {
  font-size: 17px;
}
.provider-head .pill {
  margin-top: 4px;
}
.provider-card > p {
  font-size: 14px;
}
.provider-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-top: auto;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}
.provider-actions form {
  margin: 0;
}
.provider-actions .fine-print {
  margin: 0;
}
.fallback-browser {
  display: grid;
  gap: 4px;
  margin: 20px 0;
}
.fallback-browser > p,
.fallback-browser label {
  margin: 0;
}
.fallback-browser label,
.fallback-browser a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 500;
  color: var(--ink);
}
.fallback-browser label:hover,
.fallback-browser a:hover {
  background: var(--sunken);
}

/* Settings */
.settings-heading {
  align-items: center;
  padding-bottom: 28px;
  margin-bottom: 28px;
  border-bottom: 1px solid var(--line-strong);
}
.settings-heading h1 {
  margin-top: 10px;
}
.settings-heading .lede {
  margin-top: 10px;
  font-size: 15px;
}
.settings-account {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  font-size: 13px;
  overflow-wrap: anywhere;
}
.settings-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr);
  gap: 24px;
  align-items: start;
}
.settings-main,
.settings-sidebar {
  display: grid;
  gap: 20px;
  min-width: 0;
}
.settings-card {
  padding: 28px;
  border-radius: 18px;
  box-shadow: none;
  min-width: 0;
  scroll-margin-top: calc(var(--header) + 24px);
}
.settings-card p {
  font-size: 14px;
}
.settings-card .fine-print {
  font-size: 12.5px;
  line-height: 1.6;
}
.settings-section-heading {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 24px;
}
.settings-section-heading > div {
  flex: 1;
  min-width: 0;
}
.settings-section-heading h2 {
  font-size: 16px;
}
.settings-section-heading p {
  margin-top: 3px;
  font-size: 13px;
}
.settings-section-icon {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface-2);
  color: var(--ink-2);
}
.settings-badge {
  flex-shrink: 0;
  padding: 4px 9px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  font-size: 10.5px;
  font-weight: 550;
  line-height: 1.4;
}
.settings-badge.premium {
  border-color: transparent;
  background: var(--accent-soft);
  color: var(--accent-text);
}
.settings-sender-form label {
  margin: 0 0 8px;
  font-size: 13px;
}
.inline-form {
  display: flex;
  gap: 10px;
}
.inline-form input {
  flex: 1;
  min-width: 0;
}
.settings-sender-form .fine-print {
  margin-top: 8px;
}
.sender-preview {
  margin-top: 18px;
  padding: 18px 20px;
  border-radius: 12px;
  background: var(--surface-2);
  border: 1px solid var(--line);
  overflow-wrap: anywhere;
}
.sender-preview .eyebrow {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 10px;
}
.sender-preview p {
  margin-top: 10px;
  color: var(--ink);
  font: 400 27px/1.2 var(--serif);
}
.sender-preview .brand-logo {
  margin: 12px 0 0;
}
.settings-brand-features {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 24px;
  list-style: none;
  padding: 0;
  margin-bottom: 16px;
}
.settings-brand-features li {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--ink-2);
  font-size: 13px;
}
.settings-brand-features .icon {
  color: var(--muted);
}
.settings-brand-form {
  display: grid;
  gap: 10px;
  margin-top: 20px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}
.settings-brand-form .button {
  justify-self: start;
}
.settings-brand-form label {
  margin: 0;
  font-size: 13px;
}
.brand-upload-label {
  font-size: 13px;
  font-weight: 550;
  color: var(--ink-2);
}
.brand-logo-drop {
  min-height: 224px;
  padding: 24px 20px;
  gap: 0;
  font-weight: 400;
}
.brand-logo-drop span {
  margin-left: 0;
}
.brand-logo-drop .drop-title {
  color: var(--ink);
  font-size: 26px;
}
.brand-logo-drop .drop-icon {
  color: var(--accent);
  margin: 0;
}
.brand-logo-art {
  display: grid;
  place-items: center;
  margin-bottom: 14px;
}
.brand-logo-art img {
  padding: 10px;
  width: 80px;
  height: 80px;
  object-fit: contain;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: conic-gradient(
      var(--surface) 25%,
      var(--sunken) 0 50%,
      var(--surface) 0 75%,
      var(--sunken) 0
    )
    0 0 / 12px 12px;
  box-shadow: var(--shadow-sm);
}
.brand-logo-drop .brand-logo-browse {
  color: var(--accent-text);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.brand-logo-help {
  margin-top: 12px;
  font-size: 12px;
  color: var(--muted);
}
#brand-logo:focus-visible + .brand-logo-drop {
  outline: 2px solid var(--focus);
  outline-offset: 3px;
}
#brand-logo.visually-hidden {
  min-height: 0;
  padding: 0;
  border: 0;
}
.brand-logo-form .brand-logo-sources {
  margin: 4px 0 0;
}
.brand-logo-sources .source-button {
  height: 36px;
  padding: 0 12px;
  font-size: 13px;
}
.brand-logo-sources .source-button:disabled {
  cursor: default;
  opacity: 0.5;
}
.brand-logo-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px;
}
.brand-logo-actions:not(:has(> :not([hidden]))) {
  display: none;
}
.setting-switch-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
}
.setting-switch-copy {
  display: grid;
  gap: 6px;
  min-width: 0;
}
.setting-switch-copy p {
  margin: 0;
}
input.switch {
  appearance: none;
  position: relative;
  width: 40px;
  height: 24px;
  margin-top: -2px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: var(--sunken);
  cursor: pointer;
  transition:
    background-color 0.15s,
    border-color 0.15s;
}
input.switch::before {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--muted);
  box-shadow: var(--shadow-sm);
  transition:
    transform 0.18s ease,
    background-color 0.15s;
}
input.switch:checked {
  border-color: var(--accent-strong);
  background: var(--accent-strong);
}
input.switch:checked::before {
  transform: translateX(16px);
  background: var(--accent-ink);
}
input.switch:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
}
input.switch:disabled {
  cursor: default;
  opacity: 0.5;
}
.setting-label-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 12px;
  min-height: 20px;
}
.save-state {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--muted);
  font-size: 12.5px;
  line-height: 1.3;
}
.save-state:empty {
  display: none;
}
.save-state-mark {
  display: inline-grid;
  place-items: center;
  width: 14px;
  height: 14px;
  flex: none;
}
.save-state[data-state="saving"] .save-state-mark::before {
  content: "";
  width: 11px;
  height: 11px;
  border: 1.5px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  animation: save-spin 0.7s linear infinite;
}
.save-state[data-state="saved"] {
  color: var(--ink-2);
  animation: save-fade 2.4s ease-in forwards;
}
.save-state[data-state="error"] {
  color: var(--danger);
  overflow-wrap: anywhere;
}
@keyframes save-spin {
  to {
    transform: rotate(360deg);
  }
}
@keyframes save-fade {
  0%,
  65% {
    opacity: 1;
  }
  100% {
    opacity: 0;
  }
}
.brand-logo-form[aria-busy="true"] .brand-logo-drop {
  pointer-events: none;
  opacity: 0.7;
}
.settings-domain .domain-settings {
  margin: 0;
  padding: 0;
  border: 0;
}
.settings-domain .domain-settings form .button {
  justify-self: start;
}
.settings-domain-example {
  color: var(--ink-2);
  overflow-wrap: anywhere;
}
.settings-plan {
  background: linear-gradient(145deg, var(--surface-2), var(--surface));
  border-color: var(--line-strong);
}
.settings-plan-heading,
.settings-storage-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.settings-plan-name {
  margin-top: 16px;
  font: 400 38px/1.1 var(--serif);
}
.settings-plan-limits {
  display: grid;
  gap: 12px;
  margin: 24px 0 16px;
  font-size: 13px;
}
.settings-plan-limits > div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}
.settings-plan-limits dt {
  color: var(--muted);
}
.settings-plan-limits dd {
  font-weight: 550;
  text-align: right;
}
.settings-plan-description,
.settings-plan > p[role="status"],
.settings-plan > form,
.settings-plan > p {
  margin-top: 16px;
}
.settings-notice {
  padding: 12px;
  border-radius: 10px;
  background: var(--accent-soft);
  color: var(--ink-2);
}
.settings-notice-pending {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}
.settings-spinner {
  flex: none;
  width: 16px;
  height: 16px;
  margin-top: 3px;
  border: 2px solid color-mix(in srgb, var(--accent) 25%, transparent);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
.settings-spinner[hidden] {
  display: none;
}
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}
.settings-upgrade {
  margin-top: 24px;
  padding: 18px;
  border: 1px solid color-mix(in srgb, var(--accent) 18%, var(--line));
  border-radius: 12px;
  background: color-mix(in srgb, var(--accent) 5%, var(--surface));
}
.settings-upgrade-title {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--accent-text);
  font-size: 13px;
}
.settings-upgrade p {
  margin-top: 8px;
  font-size: 12.5px;
}
.settings-upgrade-price {
  display: block;
  margin-top: 12px;
  font-size: 22px;
  font-weight: 550;
}
.settings-upgrade-price > span {
  font-size: 12px;
  font-weight: 400;
  color: var(--muted);
}
.settings-card-link {
  margin-top: 22px;
}
.settings-storage-heading > .icon {
  color: var(--muted);
}
.storage-figure {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 22px;
}
.storage-figure strong {
  color: var(--ink);
  font: 400 44px/1 var(--serif);
  letter-spacing: -0.01em;
}
.storage-figure > span {
  color: var(--muted);
  font-size: 12.5px;
}
.storage-meter {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 16px 0;
}
.storage-meter span {
  font-size: 12px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.storage-meter progress {
  flex: 1;
  min-width: 0;
  appearance: none;
  -webkit-appearance: none;
  height: 6px;
  border: 0;
  border-radius: 999px;
  overflow: hidden;
  background: var(--sunken);
}
.storage-meter progress::-webkit-progress-bar {
  background: var(--sunken);
}
.storage-meter progress::-webkit-progress-value {
  border-radius: 999px;
  background: var(--accent);
}
.storage-meter progress::-moz-progress-bar {
  border-radius: 999px;
  background: var(--accent);
}
.settings-daily-limit {
  display: grid;
  gap: 4px;
  margin-top: 20px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  font-size: 12.5px;
}
.settings-daily-limit > span,
.settings-daily-limit strong > span {
  color: var(--muted);
  font-weight: 400;
}
.settings-details {
  margin-top: 18px;
  font-size: 12.5px;
}
.settings-details summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 32px;
  color: var(--muted);
  list-style: none;
  cursor: pointer;
}
.settings-details summary::-webkit-details-marker {
  display: none;
}
.settings-details summary:hover,
.settings-details[open] summary {
  color: var(--ink);
}
.settings-details[open] summary .icon {
  transform: rotate(180deg);
}
.settings-details p {
  margin-top: 10px;
  font-size: 12.5px;
  line-height: 1.7;
}
@media (max-width: 900px) {
  .settings-layout {
    grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
    gap: 20px;
  }
  .settings-card {
    padding: 22px;
  }
  .settings-section-heading {
    flex-wrap: wrap;
  }
  .settings-section-heading .settings-badge {
    margin-left: 52px;
  }
  .settings-sender-form .inline-form {
    flex-direction: column;
  }
  .settings-sender-form .button {
    align-self: start;
  }
}
@media (max-width: 700px) {
  .settings-heading {
    align-items: start;
    flex-direction: column;
    gap: 20px;
  }
  .settings-account {
    max-width: 100%;
  }
  .settings-layout {
    grid-template-columns: minmax(0, 1fr);
  }
  .settings-section-heading .settings-badge {
    margin-left: 0;
  }
  .settings-sender-form .inline-form {
    flex-direction: row;
  }
}
@media (max-width: 440px) {
  .settings-card {
    padding: 20px;
  }
  .settings-section-heading {
    display: grid;
    grid-template-columns: 34px minmax(0, 1fr);
    gap: 10px;
    margin-bottom: 20px;
  }
  .settings-section-icon {
    width: 34px;
    height: 34px;
    border-radius: 10px;
  }
  .settings-section-heading .settings-badge {
    grid-column: 2;
    justify-self: start;
    margin-left: 0;
  }
  .settings-sender-form .inline-form {
    flex-direction: column;
  }
  .settings-sender-form .button {
    align-self: stretch;
  }
  .sender-preview {
    padding: 16px;
  }
}

/* Recipient */
.recipient-main {
  padding-top: clamp(40px, 7vw, 88px);
}
.recipient-intro {
  max-width: 860px;
  margin-bottom: 48px;
}
.recipient-intro .brand-logo {
  margin-bottom: 3rem;
}
.recipient-intro h1 {
  margin-top: 16px;
  font-size: clamp(46px, 7.5vw, 104px);
  line-height: 0.96;
  letter-spacing: -0.02em;
}
.recipient-intro .back-link {
  margin-bottom: 8px;
}
.recipient-message {
  max-width: 62ch;
  margin-top: 24px;
  color: var(--ink-2);
  font-size: 18px;
  line-height: 1.6;
  white-space: pre-line;
  overflow-wrap: anywhere;
}
.contents-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  list-style: none;
  padding: 0;
  margin: 28px 0 24px;
}
.contents-summary li {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 30px;
  padding: 0 12px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  color: var(--ink-2);
  font-size: 13px;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
}
.download-all {
  min-height: 54px;
  padding: 12px 26px 12px 22px;
  font-size: 15.5px;
  box-shadow: var(--shadow-md);
}
.download-all > span {
  margin-left: 6px;
  padding-left: 12px;
  border-left: 1px solid color-mix(in srgb, currentColor 30%, transparent);
  font-size: 13px;
  font-weight: 500;
  opacity: 0.8;
}
.download-warning {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  max-width: 60ch;
  padding: 14px 16px;
  border-radius: 14px;
  background: var(--warn-soft);
  color: var(--warn);
  font-size: 14px;
}
.download-warning .icon {
  margin-top: 2px;
}
.recipient-files {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}
.recipient-file {
  display: flex;
  align-items: center;
  gap: 16px;
  min-height: 76px;
  padding: 12px 18px 12px 12px;
  transition: background 0.15s;
}
.recipient-file + .recipient-file {
  border-top: 1px solid var(--line);
}
/* The card wraps the download link so Preview can sit beside it as a sibling
   control. A one-cell grid stretches the link to the card's full height. */
.recipient-file-card {
  position: relative;
  display: grid;
  min-width: 0;
}
.recipient-files:not(.gallery) > * + * {
  border-top: 1px solid var(--line);
}
/* Preview sits just left of the download arrow, so arrows stay in one column. */
.recipient-file-card > .preview-action {
  position: absolute;
  top: 50%;
  /* Row padding + download arrow + gap. */
  right: calc(18px + 38px + 8px);
  width: 38px;
  height: 38px;
  margin-top: -19px;
  border: 1px solid var(--line-strong);
  color: var(--ink);
}
.recipient-file-card:has(> .preview-action:not([hidden])) .recipient-file-text {
  margin-right: 46px;
}
/* Over a gallery thumbnail, Preview is the same frosted chip as in Dropbox. */
.gallery .recipient-file-card > .preview-action {
  top: 12px;
  right: 12px;
  z-index: 2;
  width: 30px;
  height: 30px;
  margin: 0;
  border-color: var(--line);
  background: color-mix(in srgb, var(--surface) 88%, transparent);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  color: var(--ink);
  opacity: 0;
  transition:
    opacity 0.15s,
    border-color 0.15s,
    transform 0.25s var(--ease);
}
.gallery .recipient-file-card:hover > .preview-action,
.gallery .recipient-file-card:focus-within > .preview-action {
  opacity: 1;
}
.gallery .recipient-file-card:hover > .preview-action {
  transform: translateY(-3px);
}
.gallery .recipient-file-card > .preview-action:hover {
  border-color: var(--line-strong);
  background: color-mix(in srgb, var(--surface) 88%, transparent);
}
.gallery .recipient-file-card:has(> .preview-action) .recipient-file-text {
  margin-right: 0;
}
.recipient-file .file-thumb {
  width: 52px;
  height: 52px;
}
a.recipient-file:hover {
  background: var(--surface-2);
}
.recipient-file-text {
  flex: 1;
  min-width: 0;
}
.recipient-file strong {
  display: block;
  font-weight: 550;
  overflow-wrap: anywhere;
}
.recipient-file small {
  display: block;
  margin-top: 2px;
  font-size: 12.5px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.download-arrow {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  color: var(--ink);
  transition:
    background 0.18s,
    color 0.18s,
    border-color 0.18s,
    transform 0.18s var(--ease);
}
a.recipient-file:hover .download-arrow {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--bg);
  transform: translateY(1px);
}
.recipient-file.unavailable {
  opacity: 0.6;
}
.recipient-file.unavailable small {
  color: var(--danger);
}
.recipient-file.unavailable .download-arrow {
  display: none;
}
.recipient-files.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 18px;
  border: 0;
  background: none;
  box-shadow: none;
  overflow: visible;
}
.gallery .recipient-file {
  position: relative;
  flex-direction: column;
  align-items: stretch;
  gap: 0;
  padding: 6px;
  min-height: 0;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
  transition:
    transform 0.25s var(--ease),
    box-shadow 0.25s var(--ease);
}
.gallery .recipient-file + .recipient-file {
  border-top: 1px solid var(--line);
}
.gallery a.recipient-file:hover,
.gallery .recipient-file-card:hover > a.recipient-file {
  background: var(--surface);
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}
.gallery .file-thumb {
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 3;
  border-radius: 16px;
}
.gallery .file-ext {
  font-size: 15px;
}
.gallery .file-thumb img {
  transition: transform 0.6s var(--ease);
}
.gallery a.recipient-file:hover .file-thumb img,
.gallery .recipient-file-card:hover .file-thumb img {
  transform: scale(1.04);
}
.gallery .recipient-file-text {
  padding: 12px 52px 8px 10px;
}
.recipient-files.gallery .recipient-file strong {
  font-size: 14px;
  white-space: normal;
  overflow-wrap: anywhere;
}
.gallery .download-arrow {
  position: absolute;
  right: 12px;
  bottom: 12px;
  width: 34px;
  height: 34px;
}
.recipient-bottom {
  margin-top: 28px;
  font-size: 13px;
}
.site-footer {
  width: min(100% - 2 * var(--gutter), var(--page-width));
  margin: 0 auto;
  padding: 28px 0 40px;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 12.5px;
}
.site-footer > span:first-child {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.site-footer .brand-word {
  font-size: 18px;
}
.site-footer .brand-mark {
  width: 18px;
  height: 18px;
}
.site-footer:has(> .legal-links:only-child) {
  justify-content: center;
}
.legal-links {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.legal-links a {
  color: inherit;
}
.pricing-fine-print a,
.site-faq a {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.legal-links a:hover {
  color: var(--ink);
}
.legal {
  max-width: 68ch;
  margin: 0 auto;
  color: var(--ink-2);
  font-size: 15.5px;
  line-height: 1.65;
  overflow-wrap: anywhere;
}
.legal h1 {
  font-size: clamp(36px, 6vw, 52px);
  line-height: 1.05;
  color: var(--ink);
}
.legal-updated {
  margin-top: 10px;
  color: var(--muted);
  font-size: 13px;
}
.legal h2 {
  margin: 36px 0 8px;
  color: var(--ink);
  font-size: 18px;
  line-height: 1.3;
}
.legal header + p {
  margin-top: 28px;
}
.legal p + p {
  margin-top: 12px;
}
.legal ul {
  margin: 8px 0 0;
  padding-left: 1.25em;
}
.legal li + li {
  margin-top: 6px;
}
.legal ul + p {
  margin-top: 12px;
}
.legal a {
  color: var(--accent-text);
  text-underline-offset: 3px;
}
/* Cloud browsing and review dialogs */
.dropbox-browser {
  width: min(1040px, calc(100vw - 32px));
  max-height: min(88dvh, 920px);
  padding: 0 28px;
  border: 1px solid var(--line);
  border-radius: 26px;
  background: var(--surface);
  color: var(--ink);
  box-shadow: var(--shadow-lg);
  overflow-y: auto;
  overscroll-behavior: contain;
}
.dropbox-browser[open] {
  animation: pop 0.2s var(--ease);
}
.dropbox-browser:focus-visible {
  outline: none;
}
.dropbox-browser::backdrop {
  background: rgb(10 10 9 / 45%);
  -webkit-backdrop-filter: blur(4px);
  backdrop-filter: blur(4px);
}
body.drive-picker-open {
  overflow: hidden;
}
.drive-picker {
  position: fixed !important;
  inset: 0 !important;
  margin: auto !important;
  width: min(1040px, calc(100vw - 32px)) !important;
  max-width: calc(100vw - 32px) !important;
  height: min(88dvh, 650px) !important;
  max-height: calc(100dvh - 32px) !important;
  z-index: 1001 !important;
  display: flex;
  flex-direction: column;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 26px;
  background: var(--surface);
  color: var(--ink);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  overscroll-behavior: contain;
  animation: pop 0.2s var(--ease);
}
.drive-picker .db-header {
  flex: none;
  margin: 0;
}
.drive-picker-content,
.drive-picker iframe {
  width: 100% !important;
  height: 100% !important;
  min-width: 0;
  min-height: 0;
  border: 0;
}
.drive-picker > .drive-picker-content,
.drive-picker > iframe {
  flex: 1;
  height: 0 !important;
}
.drive-picker iframe {
  display: block;
}
.drive-picker-native-chrome,
.drive-picker-shim {
  display: none !important;
}
.drive-picker-backdrop {
  position: fixed !important;
  inset: 0 !important;
  width: 100% !important;
  height: 100% !important;
  z-index: 1000 !important;
  opacity: 1 !important;
  background: rgb(10 10 9 / 45%);
  -webkit-backdrop-filter: blur(4px);
  backdrop-filter: blur(4px);
}
.drive-picker-focus-guard {
  position: fixed !important;
  inset: 0 auto auto 0 !important;
}
.db-header {
  position: sticky;
  top: 0;
  z-index: 3;
  margin: 0 -28px;
  padding: 22px 28px 14px;
  background: var(--surface);
}
.db-header,
.db-toolbar,
.db-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.db-header h2 {
  display: flex;
  align-items: center;
  gap: 10px;
  font: 400 32px/1.1 var(--serif);
  letter-spacing: -0.01em;
}
.db-toolbar {
  flex-wrap: wrap;
  margin: 4px 0 12px;
}
.db-toolbar label {
  flex: 1;
  min-width: 0;
  margin: 0;
  font-size: 0;
}
.db-toolbar label input {
  font-size: 14.5px;
}
.db-toolbar > .text-button {
  padding: 6px 14px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  min-height: 38px;
}
.db-breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 2px;
  font-size: 13.5px;
  color: var(--muted);
}
.db-breadcrumbs .text-button {
  min-height: 30px;
  padding: 4px 8px;
  border-radius: 8px;
}
.db-breadcrumbs .text-button:hover {
  background: var(--sunken);
}
.db-breadcrumbs .text-button:last-of-type {
  color: var(--ink);
}
.db-status {
  min-height: 22px;
  margin-top: 6px;
  font-size: 12.5px;
}
.db-status:empty {
  display: none;
}
.db-error {
  margin: 14px 0 18px;
  padding: 44px 24px;
  text-align: center;
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius-lg);
  background: var(--surface-2);
}
.db-error-icon {
  display: inline-grid;
  place-items: center;
  width: 48px;
  height: 48px;
  margin-bottom: 14px;
  border-radius: 50%;
  background: var(--danger-soft);
  color: var(--danger);
}
.db-error h3 {
  font: 400 26px/1.15 var(--serif);
  letter-spacing: -0.01em;
}
.db-error p {
  max-width: 44ch;
  margin: 8px auto 0;
  color: var(--muted);
  font-size: 14px;
}
.db-error-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 8px 18px;
  margin-top: 20px;
}
.db-error.is-inline {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 4px 14px;
  padding: 14px 18px;
  text-align: left;
}
.db-error.is-inline .db-error-icon {
  grid-row: span 2;
  width: 36px;
  height: 36px;
  margin: 0;
}
.db-error.is-inline h3 {
  font: 600 14px/1.3 var(--sans);
  letter-spacing: 0;
}
.db-error.is-inline p {
  grid-column: 2;
  margin: 0;
  font-size: 13px;
}
.db-error.is-inline .db-error-actions {
  grid-column: 3;
  grid-row: 1 / span 2;
  margin: 0;
}

/* Connect a storage account before importing */
.connect-prompt {
  width: min(440px, calc(100vw - 32px));
  padding: 36px 32px 24px;
  border: 1px solid var(--line);
  border-radius: 26px;
  background: var(--surface);
  color: var(--ink);
  box-shadow: var(--shadow-lg);
  text-align: center;
}
.connect-prompt[open] {
  animation: pop 0.2s var(--ease);
}
.connect-prompt::backdrop {
  background: rgb(10 10 9 / 45%);
  -webkit-backdrop-filter: blur(4px);
  backdrop-filter: blur(4px);
}
.connect-art {
  position: relative;
  width: 72px;
  margin: 0 auto 20px;
}
.connect-tile {
  display: grid;
  place-items: center;
  width: 72px;
  height: 72px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: var(--surface-2);
}
.connect-badge {
  position: absolute;
  right: -8px;
  bottom: -8px;
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border: 3px solid var(--surface);
  border-radius: 50%;
  background: var(--accent-strong);
  color: var(--on-accent);
}
.connect-prompt h2 {
  font: 400 32px/1.1 var(--serif);
  letter-spacing: -0.01em;
}
.connect-prompt p {
  max-width: 34ch;
  margin: 10px auto 0;
  color: var(--muted);
  font-size: 14.5px;
}
.connect-prompt .connect-error {
  margin-top: 16px;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  background: var(--danger-soft);
  color: var(--danger);
  font-size: 13.5px;
}
.connect-prompt form .button {
  width: 100%;
  margin-top: 24px;
}
.connect-secondary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 14px;
}
.connect-secondary .text-button {
  min-height: 36px;
  color: var(--muted);
}
.connect-secondary .text-button:hover {
  color: var(--ink);
}
.db-entries {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(168px, 1fr));
  gap: 14px;
  margin: 14px 0 18px;
}
.db-card {
  position: relative;
  display: flex;
  flex-direction: column;
  min-width: 0;
  padding: 6px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface-2);
  transition:
    border-color 0.15s,
    box-shadow 0.15s,
    transform 0.2s var(--ease);
}
.db-card:hover {
  border-color: var(--line-strong);
}
.db-card.selected {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}
.db-card.selected::after {
  content: "";
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 2;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--accent)
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' fill='none' stroke='white' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round' viewBox='0 0 24 24'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E")
    no-repeat center;
  box-shadow: 0 0 0 2px var(--surface);
}
.db-select {
  display: flex;
  flex-direction: column;
  gap: 2px;
  width: 100%;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  text-align: left;
}
.db-select strong {
  margin-top: 8px;
  padding: 0 4px;
  font-size: 13px;
  font-weight: 550;
  line-height: 1.35;
  overflow-wrap: anywhere;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.db-select small {
  padding: 0 4px;
  font-size: 12px;
  color: var(--muted);
  overflow-wrap: anywhere;
}
.db-select:disabled {
  cursor: not-allowed;
}
.db-select:disabled .db-visual,
.db-select:disabled strong {
  opacity: 0.5;
}
.db-visual {
  position: relative;
  display: grid;
  place-items: center;
  width: 100%;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border-radius: 11px;
}
.db-visual.file-thumb {
  border-radius: 11px;
}
.db-icon {
  font: 600 13px/1 var(--mono);
  letter-spacing: 0.06em;
}
.db-icon .icon {
  width: 30px;
  height: 30px;
}
.db-icon-hidden {
  visibility: hidden;
}
.db-visual img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.db-card > button {
  align-self: flex-start;
  min-height: 30px;
  margin: 4px 0 0;
  padding: 2px 4px;
  font-size: 12.5px;
}
/* Why a file can't be added: a short accent label in line with the card's
   text. Its tooltip, anchored to the card so it never overflows the dialog,
   gives the full reason on hover, focus or tap. */
.db-reason {
  display: inline-flex;
  align-self: flex-start;
  align-items: center;
  gap: 4px;
  margin-top: 3px;
  padding: 0 4px;
  border-radius: 6px;
  color: var(--accent-text);
  font-size: 12px;
  font-weight: 550;
  line-height: 1.4;
  cursor: help;
}
.db-tip {
  position: absolute;
  left: 6px;
  right: 6px;
  bottom: 30px;
  z-index: 4;
  padding: 8px 10px;
  border-radius: var(--radius-sm);
  background: var(--ink);
  color: var(--bg);
  font-size: 12px;
  font-weight: 500;
  line-height: 1.4;
  box-shadow: var(--shadow-md);
  opacity: 0;
  visibility: hidden;
  transform: translateY(2px);
  pointer-events: none;
  transition:
    opacity 0.15s,
    transform 0.15s var(--ease),
    visibility 0.15s;
}
.db-reason:is(:hover, :focus) .db-tip {
  opacity: 1;
  visibility: visible;
  transform: none;
}
/* Preview sits on the thumbnail as an icon chip, out of the card's text flow. */
.db-card > .db-peek {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 30px;
  min-height: 30px;
  margin: 0;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: color-mix(in srgb, var(--surface) 88%, transparent);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  color: var(--ink);
  opacity: 0;
  transition:
    opacity 0.15s,
    border-color 0.15s;
}
.db-card:hover > .db-peek,
.db-card:focus-within > .db-peek {
  opacity: 1;
}
.db-card > .db-peek:hover {
  border-color: var(--line-strong);
}
.db-more {
  display: flex;
  width: fit-content;
  margin: 0 auto 22px;
}
.db-list {
  grid-template-columns: 1fr;
  gap: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}
.db-list .db-card {
  flex-direction: row;
  align-items: center;
  gap: 12px;
  padding: 8px 14px 8px 8px;
  border: 0;
  border-radius: 0;
  background: var(--surface);
}
.db-list .db-card + .db-card {
  border-top: 1px solid var(--line);
}
.db-list .db-card.selected {
  box-shadow: inset 3px 0 0 var(--accent);
  background: color-mix(in srgb, var(--accent) 5%, var(--surface));
}
.db-list .db-card.selected::after {
  top: 50%;
  left: auto;
  right: 14px;
  transform: translateY(-50%);
}
.db-list .db-select {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  column-gap: 12px;
  align-items: center;
  flex: 1;
  min-width: 0;
}
.db-list .db-visual {
  grid-row: 1 / span 3;
  width: 44px;
  height: 44px;
  aspect-ratio: auto;
  border-radius: 10px;
}
.db-list .db-icon {
  font-size: 9.5px;
}
.db-list .db-icon .icon {
  width: 20px;
  height: 20px;
}
.db-list .db-select strong {
  margin: 0;
  -webkit-line-clamp: 1;
}
.db-list .db-card > button {
  margin: 0;
  flex-shrink: 0;
}
.db-list .db-card > .db-peek {
  order: 1;
  position: static;
  align-self: center;
  margin: 0;
  opacity: 1;
}
/* In a row the label sits before Preview, so the chips stay in one column,
   and its tooltip opens above the row's right end. */
.db-list .db-reason {
  flex-shrink: 0;
  align-self: center;
  margin: 0;
  white-space: nowrap;
}
.db-list .db-tip {
  left: auto;
  right: 6px;
  bottom: calc(100% - 4px);
  width: max-content;
  max-width: min(260px, 100% - 12px);
  white-space: normal;
}
.db-list .db-card.selected > button:last-of-type {
  margin-right: 30px;
}
/* Folders stay compact in the grid so previews surface sooner. Folders are
   listed first and files start a new row, so each row holds one kind of card
   and every card in it is the same height. */
.db-entries:not(.db-list) .db-card.is-folder {
  padding: 8px 8px 4px;
}
.db-entries:not(.db-list) .is-folder + .db-card:not(.is-folder) {
  grid-column-start: 1;
}
.db-entries:not(.db-list) .is-folder .db-select {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr);
  column-gap: 10px;
  align-items: center;
}
.db-entries:not(.db-list) .is-folder .db-visual {
  grid-row: span 2;
  width: 40px;
  height: 40px;
  aspect-ratio: auto;
  border-radius: 10px;
}
.db-entries:not(.db-list) .is-folder .db-icon .icon {
  width: 20px;
  height: 20px;
}
.db-entries:not(.db-list) .is-folder .db-select strong {
  margin: 0;
  padding: 0;
  -webkit-line-clamp: 1;
}
.db-entries:not(.db-list) .is-folder .db-select small {
  padding: 0;
}
.db-preview {
  margin: 8px 0 16px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface-2);
  overflow-wrap: anywhere;
}
.db-preview h3 {
  margin-top: 12px;
  font: 400 26px/1.15 var(--serif);
}
.db-preview p {
  font-size: 13px;
}
.db-preview img {
  display: block;
  max-width: 100%;
  max-height: 50dvh;
  margin: 16px auto 0;
  border-radius: 12px;
  object-fit: contain;
  box-shadow: var(--shadow-md);
}
.db-footer {
  position: sticky;
  bottom: 0;
  z-index: 3;
  flex-wrap: wrap;
  margin: 0 -28px;
  padding: 14px 28px 18px;
  background: color-mix(in srgb, var(--surface) 94%, transparent);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  border-top: 1px solid var(--line);
}
.db-footer > strong {
  font-size: 14px;
  font-variant-numeric: tabular-nums;
}
.db-footer > .button {
  margin-left: auto;
}
.db-selected {
  order: 4;
  flex-basis: 100%;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  max-height: 84px;
  overflow: auto;
}
.db-selected:empty {
  display: none;
}
.db-selected button {
  max-width: 100%;
  min-height: 28px;
  padding: 3px 10px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: var(--surface-2);
  font-size: 12px;
  overflow-wrap: anywhere;
  text-align: left;
}
.cloud-review {
  width: min(760px, calc(100vw - 32px));
}
.cloud-review .db-status {
  margin-top: 0;
}
.cloud-review .db-entries {
  margin-bottom: 12px;
}
.cloud-review .db-entries:focus {
  outline: none;
}
/* One text column centred against the icon, however many lines it has. */
.cloud-review .db-visual {
  grid-row: auto;
}
.cloud-review-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.cloud-review .db-select :is(strong, small) {
  margin: 0;
  padding: 0;
}
/* The review list has room for the full reason, so it stays inline text. */
.cloud-review .db-reason {
  display: block;
  color: var(--accent-text);
  margin: 0;
  padding: 0;
  font-weight: 500;
  cursor: auto;
}
.cloud-review-pager {
  display: flex;
  gap: 8px;
  margin-bottom: 18px;
}
.cloud-review-pager:not(:has(:not([hidden]))) {
  display: none;
}
.cloud-review-pager .button:last-child {
  margin-left: auto;
}
.cloud-review-note {
  margin: 0;
  font-size: 13px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.cloud-review-note.is-over {
  color: var(--danger);
}
.db-visual[data-kind="folder"] {
  background: color-mix(in srgb, var(--accent) 9%, var(--surface-2));
  color: var(--accent-text);
}
.file-row img,
.db-visual img {
  -webkit-user-drag: none;
  user-select: none;
}

/* Confirmation dialog and toast */
.confirm-dialog {
  width: min(420px, calc(100vw - 32px));
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: var(--surface);
  color: var(--ink);
  box-shadow: var(--shadow-lg);
}
.confirm-dialog[open] {
  animation: pop 0.18s var(--ease);
}
.confirm-dialog::backdrop {
  background: rgb(10 10 9 / 45%);
  -webkit-backdrop-filter: blur(4px);
  backdrop-filter: blur(4px);
}
.confirm-dialog h2 {
  font: 400 30px/1.1 var(--serif);
  letter-spacing: -0.01em;
}
.confirm-dialog p {
  margin-top: 10px;
  font-size: 14.5px;
}
.confirm-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 24px;
}
.button.danger {
  background: var(--danger);
  color: var(--bg);
}
.button.danger:hover:not(:disabled) {
  background: color-mix(in srgb, var(--danger) 85%, var(--ink));
  color: var(--bg);
}
.toast {
  position: fixed;
  left: 50%;
  bottom: 24px;
  z-index: 80;
  max-width: calc(100vw - 32px);
  padding: 11px 18px;
  border-radius: 999px;
  background: var(--ink);
  color: var(--bg);
  font-size: 14px;
  font-weight: 500;
  box-shadow: var(--shadow-lg);
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 12px);
  transition:
    opacity 0.2s,
    transform 0.25s var(--ease);
}
.toast:empty {
  display: none;
}
.toast.visible {
  opacity: 1;
  transform: translate(-50%, 0);
}

/* Responsive */
@media (max-width: 1080px) {
  .site-header-inner {
    grid-template-columns: auto 1fr auto;
  }
  .main-nav {
    justify-self: center;
  }
}
@media (max-width: 920px) {
  .composer-grid {
    grid-template-columns: 1fr;
  }
  .details {
    position: static;
  }
  .archive-grid {
    grid-template-columns: 1fr;
  }
  .auth-split {
    grid-template-columns: 1fr;
    max-width: 560px;
    margin: 0 auto;
  }
}
@media (max-width: 760px) {
  :root {
    --header: 58px;
  }
  .site-header-inner {
    grid-template-columns: 1fr auto;
  }
  .main-nav,
  .header-actions {
    display: none;
  }
  .header-note {
    grid-column: 2;
  }
  .mobile-menu {
    display: block;
  }
  .mobile-menu summary {
    display: grid;
    place-items: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid var(--line-strong);
    background: var(--surface);
  }
  .mobile-menu[open] summary {
    background: var(--ink);
    color: var(--bg);
  }
  .mobile-menu-panel {
    width: min(300px, calc(100vw - 2 * var(--gutter)));
    padding: 10px;
    max-height: calc(100dvh - var(--header) - 24px);
    overflow-y: auto;
  }
  .mobile-menu nav {
    display: flex;
    flex-direction: column;
    padding-bottom: 8px;
    margin-bottom: 10px;
    border-bottom: 1px solid var(--line);
  }
  .mobile-menu nav a {
    padding: 11px 12px;
    border-radius: var(--radius-sm);
    font-size: 16px;
    font-weight: 500;
  }
  .mobile-menu nav a:hover {
    background: var(--sunken);
  }
  .mobile-menu nav a[aria-current="page"] {
    background: var(--sunken);
    color: var(--ink);
  }
  .mobile-menu form + form {
    margin-top: 6px;
  }
  .main,
  .recipient-main {
    padding: 28px 0 64px;
  }
  .page-heading {
    flex-wrap: wrap;
    align-items: flex-start;
    margin-bottom: 24px;
  }
  .delivery-grid {
    grid-template-columns: 1fr;
    gap: 14px;
  }
  .drop-zone {
    min-height: 168px;
    padding: 24px 16px;
  }
  .drop-title {
    font-size: 23px;
  }
  .file-row {
    gap: 12px;
    padding: 10px 6px 10px 10px;
  }
  .file-row .file-thumb {
    width: 46px;
    height: 46px;
  }
  .file-list[data-view="grid"] {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .list-row {
    grid-template-columns: 40px minmax(0, 1fr) 16px;
  }
  .list-row .list-meta {
    display: none;
  }
  .facts {
    grid-template-columns: 1fr 1fr 1fr;
    gap: 8px;
  }
  .facts div {
    padding: 10px;
  }
  .card {
    padding: 20px;
  }
  .login-form {
    padding: 26px 22px;
  }
  .login-form h1,
  #clerk-sign-in .cl-headerTitle {
    font-size: 36px;
  }
  .notice {
    padding: 32px 22px 28px;
  }
  .inline-form {
    flex-direction: column;
  }
  .recipient-intro {
    margin-bottom: 32px;
  }
  .recipient-intro .brand-logo {
    margin-bottom: 1.5rem;
  }
  .recipient-message {
    font-size: 16.5px;
  }
  .download-all {
    width: 100%;
  }
  .recipient-files:not(.gallery) .recipient-file {
    gap: 12px;
    padding: 10px 12px 10px 10px;
  }
  .recipient-files:not(.gallery) .recipient-file-card > .preview-action {
    right: calc(12px + 38px + 8px);
  }
  .recipient-files:not(.gallery) .file-thumb {
    width: 46px;
    height: 46px;
  }
  .recipient-files.gallery {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }
  .gallery .recipient-file-text {
    padding: 10px 6px 4px;
  }
  .gallery .recipient-file strong {
    font-size: 13px;
  }
  .gallery .download-arrow {
    display: none;
  }
  .site-footer {
    flex-direction: column;
    align-items: flex-start;
  }
}
@media (max-width: 600px) {
  .dropbox-browser {
    width: 100vw;
    max-width: 100vw;
    height: 100dvh;
    max-height: 100dvh;
    margin: 0;
    padding: 0 16px;
    border: 0;
    border-radius: 0;
  }
  .db-header,
  .db-footer {
    margin: 0 -16px;
    padding-left: 16px;
    padding-right: 16px;
  }
  .db-header h2,
  .cloud-review > h2 {
    font-size: 26px;
  }
  .cloud-review {
    padding-top: 18px;
  }
  .db-toolbar {
    gap: 8px;
  }
  .db-toolbar label {
    flex-basis: 100%;
  }
  .db-entries {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }
  .db-entries.db-list {
    grid-template-columns: 1fr;
  }
  .db-list .db-card {
    flex-wrap: wrap;
  }
  .db-footer > .button {
    width: 100%;
  }
  .connect-prompt {
    padding: 30px 20px 18px;
  }
}
@media (hover: none) {
  .file-controls,
  .db-card > .db-peek,
  .gallery .recipient-file-card > .preview-action {
    opacity: 1;
  }
  .delivery-card:hover,
  .gallery a.recipient-file:hover,
  .gallery .recipient-file-card:hover > a.recipient-file,
  .gallery .recipient-file-card:hover > .preview-action {
    transform: none;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  /* The timer still clears "Saved"; don't fade it out instantly. */
  .save-state[data-state="saved"] {
    animation: none !important;
  }
}

/* Curated recipient accents. Light text colours and filled controls meet AA
   against paper/white; dark text colours meet AA against ink surfaces. */
.brand-vermilion {
  --accent: #b8320a;
  --accent-text: #b8320a;
  --accent-strong: #b8320a;
  --focus: #b8320a;
  --accent-soft: #b8320a18;
}
.brand-blue {
  --accent: #2456a6;
  --accent-text: #2456a6;
  --accent-strong: #2456a6;
  --focus: #2456a6;
  --accent-soft: #2456a618;
}
.brand-forest {
  --accent: #246542;
  --accent-text: #246542;
  --accent-strong: #246542;
  --focus: #246542;
  --accent-soft: #24654218;
}
.brand-violet {
  --accent: #6b3fa0;
  --accent-text: #6b3fa0;
  --accent-strong: #6b3fa0;
  --focus: #6b3fa0;
  --accent-soft: #6b3fa018;
}
.brand-rose {
  --accent: #a52b59;
  --accent-text: #a52b59;
  --accent-strong: #a52b59;
  --focus: #a52b59;
  --accent-soft: #a52b5918;
}
.brand-slate {
  --accent: #45566b;
  --accent-text: #45566b;
  --accent-strong: #45566b;
  --focus: #45566b;
  --accent-soft: #45566b18;
}

.brand-logo {
  display: block;
  width: auto;
  max-width: min(144px, 100%);
  height: 48px;
  object-fit: contain;
  object-position: left center;
  margin-bottom: 1.5rem;
}
.expiry-toggle {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.6rem;
}
.expiry-toggle input {
  width: auto;
  margin: 0;
}
#branding form + form {
  margin-top: 1.25rem;
}
#branding input[type="file"] {
  max-width: 100%;
}
.brand-select {
  position: relative;
  min-width: 0;
}
.brand-select select,
.brand-select-trigger {
  appearance: none;
  min-height: 68px;
  padding: 12px 16px;
  border: 1px solid var(--line-strong);
  border-radius: 14px;
  background: linear-gradient(145deg, var(--surface-2), var(--surface));
  color: var(--ink);
  font: inherit;
  font-size: 14px;
  box-shadow: var(--shadow-sm);
  transition:
    border-color 0.15s,
    box-shadow 0.15s;
  cursor: pointer;
}
.brand-select select {
  padding-left: 52px;
  padding-right: 44px;
}
.brand-select-trigger,
.brand-select-option {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  text-align: left;
}
.brand-select-trigger:hover:not(:disabled),
.brand-select select:hover:not(:disabled) {
  border-color: color-mix(in srgb, var(--ink) 28%, transparent);
}
.brand-select-trigger:disabled {
  cursor: default;
  background: var(--sunken);
  opacity: 0.75;
}
.brand-select-trigger:focus-visible,
.brand-select-trigger[aria-expanded="true"] {
  outline: none;
  border-color: var(--focus);
  box-shadow: 0 0 0 4px var(--accent-soft);
}
.brand-select-mark {
  display: grid;
  place-items: center;
  flex: 0 0 24px;
  width: 24px;
  height: 24px;
  color: var(--ink-2);
}
.brand-select-swatch {
  flex-basis: 20px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow:
    inset 0 0 0 1px rgb(0 0 0 / 12%),
    0 0 0 4px var(--surface);
  margin: 0 2px;
}
.brand-select > .brand-select-mark {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  pointer-events: none;
}
.brand-select-chevron {
  position: absolute;
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--muted);
  pointer-events: none;
}
.brand-select-copy {
  display: grid;
  gap: 3px;
  flex: 1;
  min-width: 0;
}
.brand-select-copy > span {
  font-weight: 550;
}
.brand-select-copy small {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.4;
}
.brand-select-trigger > .icon {
  flex-shrink: 0;
  color: var(--muted);
  transition: transform 0.15s;
}
.brand-select-trigger[aria-expanded="true"] > .icon {
  transform: rotate(180deg);
}
.brand-select-menu {
  position: absolute;
  z-index: 30;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  max-height: 310px;
  overflow-y: auto;
  padding: 6px;
  border: 1px solid var(--line-strong);
  border-radius: 16px;
  background: var(--surface);
  box-shadow: var(--shadow-lg);
}
.brand-select-option {
  min-height: 48px;
  padding: 10px;
  border-radius: 10px;
  color: var(--ink);
  font-size: 14px;
  cursor: pointer;
}
.brand-select-option:hover,
.brand-select-option.is-active {
  background: var(--surface-2);
}
.brand-select-option[aria-selected="true"] {
  background: color-mix(in srgb, var(--accent-soft) 50%, var(--surface));
}
.brand-select-option > .icon {
  flex-shrink: 0;
  visibility: hidden;
  color: var(--accent-text);
}
.brand-select-option[aria-selected="true"] > .icon {
  visibility: visible;
}
.brand-select-option[aria-disabled="true"] {
  opacity: 0.5;
  cursor: default;
}
/* Pricing */
.recipient-main:has(> .pricing) {
  padding-top: clamp(40px, 5vw, 64px);
}
.pricing {
  position: relative;
  isolation: isolate;
  max-width: 1040px;
  margin: 0 auto;
}
.pricing::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: -120px calc(-1 * var(--gutter)) auto;
  height: 640px;
  background:
    radial-gradient(
      50% 60% at 50% 30%,
      color-mix(in srgb, var(--accent) 22%, transparent),
      transparent 70%
    ),
    radial-gradient(
      30% 40% at 78% 55%,
      color-mix(in srgb, #ffb36b 14%, transparent),
      transparent 70%
    );
  filter: blur(8px);
  pointer-events: none;
}
.pricing-hero {
  max-width: 680px;
  margin: 0 auto;
  text-align: center;
}
.pricing-hero h1 {
  font-size: clamp(44px, 7vw, 76px);
  line-height: 1;
}
.pricing-hero .lede {
  margin: 18px auto 0;
  font-size: 17px;
}
.pricing-grid {
  margin-top: 32px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(340px, 100%), 1fr));
  gap: 24px;
  align-items: stretch;
}
.plan-card {
  display: flex;
  flex-direction: column;
  padding: clamp(28px, 4vw, 40px);
  border: 1px solid var(--line-strong);
  border-radius: 28px;
  background: var(--surface);
  box-shadow: var(--shadow-md);
}
.plan-card h2 {
  font: 600 15px/1.3 var(--sans);
  letter-spacing: 0;
}
.plan-tagline {
  margin-top: 6px;
  font-size: 14.5px;
}
.plan-price {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px 10px;
  margin-top: 28px;
  color: var(--muted);
  font-size: 14.5px;
}
.plan-price strong {
  color: var(--ink);
  font: 400 64px/0.95 var(--serif);
  letter-spacing: -0.02em;
}
.plan-cta {
  width: 100%;
  min-height: 48px;
  margin-top: 28px;
  font-size: 15px;
}
.plan-card > form {
  display: flex;
  margin: 0;
}
.plan-features {
  display: grid;
  gap: 14px;
  margin-top: 28px;
  padding: 28px 0 0;
  border-top: 1px solid var(--line);
  list-style: none;
  font-size: 15px;
  color: var(--ink-2);
}
.plan-features li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}
.plan-features .icon {
  flex: none;
  margin-top: 3px;
  color: var(--muted);
}
.plan-card.featured {
  position: relative;
  border-color: transparent;
  background:
    radial-gradient(
        120% 70% at 100% 0%,
        color-mix(in srgb, var(--accent) 16%, transparent),
        transparent 60%
      )
      padding-box,
    linear-gradient(var(--surface), var(--surface)) padding-box,
    linear-gradient(
        150deg,
        var(--accent),
        color-mix(in srgb, var(--accent) 25%, var(--line-strong)) 45%,
        var(--line-strong)
      )
      border-box;
  box-shadow:
    var(--shadow-lg),
    0 24px 80px -32px color-mix(in srgb, var(--accent) 45%, transparent);
}
.plan-card.featured .plan-features .icon {
  color: var(--accent);
}
.pricing-fine-print {
  margin-top: 40px;
  text-align: center;
}

.layout-public[class*="brand-"] .download-all {
  background: var(--accent-strong);
  color: var(--on-accent);
}

/* Recipient identity and the independent no-JavaScript branding preference. */
.recipient-intro h1,
.recipient-sender,
.recipient-intro .back-link,
.recipient-error-sender {
  overflow-wrap: anywhere;
}
.recipient-error-sender {
  margin-bottom: 24px;
}
.recipient-unbranded .recipient-main,
.recipient-unbranded .auth-main {
  padding-top: clamp(32px, 5vw, 64px);
}
.privacy-footer > span:first-child {
  display: block;
}
.privacy-footer {
  line-height: 1.6;
}
.recipient-unbranded .brand-logo {
  height: auto;
  max-height: 48px;
}
.recipient-unbranded .auth-main {
  display: block;
}

.domain-settings {
  display: grid;
  gap: 20px;
  border-top: 1px solid var(--line);
  margin-top: 1.5rem;
  padding-top: 1.5rem;
}
.domain-settings > .settings-section-heading {
  margin-bottom: 0;
}
.domain-registration,
.domain-dns {
  display: grid;
  gap: 12px;
  min-width: 0;
}
.domain-status {
  display: grid;
  gap: 4px;
  min-width: 0;
}
.domain-status > strong {
  color: var(--ink);
  font-size: 15px;
  overflow-wrap: anywhere;
}
.domain-notice {
  padding: 10px 12px;
  border-left: 2px solid var(--warn);
  border-radius: 0 8px 8px 0;
  background: var(--warn-soft);
  color: var(--ink-2);
}
.domain-settings p,
.domain-record dd,
.share-fallback {
  overflow-wrap: anywhere;
  min-width: 0;
}
.domain-settings form {
  display: grid;
  gap: 0.75rem;
  margin: 0;
}
.domain-settings form label {
  margin: 0;
}
.domain-settings input {
  min-width: 0;
  max-width: 100%;
}
.domain-records {
  display: grid;
  gap: 12px;
  min-width: 0;
}
.domain-record {
  display: grid;
  grid-template-columns: 84px minmax(0, 1fr);
  align-items: baseline;
  gap: 12px;
  margin: 0;
  padding: 1rem;
  border: 1px solid var(--line);
  border-radius: 0.5rem;
  background: var(--surface-2);
}
.domain-record dt {
  color: var(--muted);
  font-size: 12px;
}
.domain-record dd {
  margin: 0;
}
.domain-record code {
  white-space: normal;
  font-size: 0.85rem;
}
.domain-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
}
.domain-checks {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  padding: 16px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  list-style: none;
}
.domain-checks li {
  display: grid;
  gap: 4px;
  min-width: 0;
  overflow-wrap: anywhere;
  font-size: 12px;
  color: var(--muted);
}
.domain-checks strong {
  font-size: 13px;
  font-weight: 500;
  color: var(--ink-2);
}
.domain-checks .domain-check-complete {
  color: var(--live);
}
.domain-settings > .settings-details {
  margin-top: 0;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}
.domain-actions .domain-feedback {
  flex: 1 1 140px;
  margin: 0;
}
.domain-actions .domain-feedback[data-state="error"] {
  flex-basis: 100%;
}
.domain-feedback[data-state="error"] {
  color: var(--danger);
}
@media (max-width: 440px) {
  .domain-record {
    grid-template-columns: minmax(0, 1fr);
    gap: 4px;
  }
  .domain-record dd + dt {
    margin-top: 8px;
  }
  .domain-actions form,
  .domain-actions > .button,
  .settings-domain .domain-actions form .button {
    width: 100%;
  }
  .domain-actions .domain-feedback {
    flex-basis: 100%;
  }
}
.share-fallback {
  font-size: 0.8rem;
}
/* Download all, enhanced by /recipient.js. Hidden on touch devices until the
   real-device test confirms they save every file; the list stays. */
.download-all-enhanced {
  display: grid;
  justify-items: start;
  gap: 0.5rem;
}
.download-all-enhanced[hidden] {
  display: none;
}
.download-all-enhanced .fine-print,
.download-all-status {
  margin: 0;
}
@media (pointer: coarse) {
  .download-all-enhanced {
    display: none;
  }
}
.plan-offer {
  margin-top: 18px;
}
.plan-offer-details {
  display: grid;
  gap: 6px;
  margin-bottom: 16px;
  padding: 14px 16px;
  border: 1px solid var(--accent);
  border-radius: var(--radius);
  background: var(--accent-soft);
  font-size: 14px;
}
.plan-offer-details span {
  color: var(--muted);
}
.checkout-consent {
  color: var(--muted);
}
.checkout-consent a {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* Public site: homepage, blog and articles. They share the pricing page's
   header, footer and paper-and-ink palette. */
.recipient-main:has(> .home),
.recipient-main:has(> .blog),
.recipient-main:has(> .article) {
  padding-top: clamp(32px, 5vw, 64px);
}
.public-actions .text-link[aria-current="page"] {
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 6px;
  text-decoration-color: var(--accent);
}
.home-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr);
  align-items: center;
  gap: clamp(32px, 6vw, 80px);
}
.home-hero h1 {
  margin-top: 16px;
  font-size: clamp(44px, 6.2vw, 76px);
  line-height: 1.02;
}
.home-hero h1 em,
.home-section-title em {
  color: var(--accent);
}
.home-lede {
  margin-top: 24px;
  max-width: 520px;
  color: var(--ink-2);
  font-size: clamp(17px, 1.5vw, 19px);
  line-height: 1.5;
}
.home-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-top: 28px;
}
.home-actions .button {
  min-height: 46px;
  padding-inline: 20px;
}
.home-hero .fine-print {
  margin-top: 14px;
}
/* The fictional sample delivery: the recipient page in miniature. */
.home-sample {
  position: relative;
  margin: 0;
  min-width: 0;
}
.home-sample-chat {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 6px;
  width: min(290px, 86%);
  margin: 0 -12px -18px auto;
}
.home-sample-page {
  padding: clamp(22px, 3vw, 30px);
  border: 1px solid var(--line);
  border-radius: 28px;
  background: color-mix(in srgb, var(--surface) 88%, transparent);
  -webkit-backdrop-filter: saturate(140%) blur(24px);
  backdrop-filter: saturate(140%) blur(24px);
  box-shadow: var(--shadow-lg);
}
.home-sample-title {
  margin-top: 10px;
  color: var(--ink);
  font: 400 clamp(30px, 3.4vw, 40px) / 1.05 var(--serif);
  letter-spacing: -0.01em;
}
.home-sample-message {
  margin-top: 10px;
  font-size: 14.5px;
}
.home-sample .contents-summary {
  margin: 16px 0 0;
}
.home-sample-download {
  width: 100%;
  margin-top: 18px;
  pointer-events: none;
}
.home-sample-download span {
  opacity: 0.75;
  font-weight: 500;
}
.home-sample-files {
  display: grid;
  gap: 10px;
  margin: 18px 0 0;
  padding: 16px 0 0;
  border-top: 1px solid var(--line);
  list-style: none;
}
.home-sample-files li {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
}
.home-sample-files .file-thumb {
  width: 42px;
  height: 42px;
  border-radius: 11px;
}
.home-sample-files .file-ext {
  font-size: 9.5px;
}
.home-sample-files strong {
  display: block;
  overflow: hidden;
  color: var(--ink);
  font-size: 13.5px;
  font-weight: 500;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.home-sample-files small {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: var(--muted);
  font-size: 12.5px;
}
.home-section-title {
  color: var(--ink);
  font: 400 clamp(30px, 3.6vw, 44px) / 1.08 var(--serif);
  letter-spacing: -0.01em;
  text-wrap: balance;
}
.home-features,
.home-pricing,
.home-guides {
  margin-top: clamp(64px, 9vw, 112px);
}
.home-feature-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0 clamp(20px, 3vw, 40px);
  margin-top: 28px;
  padding: 0;
  list-style: none;
}
.home-feature-list li {
  padding-top: 20px;
  border-top: 1px solid var(--line-strong);
}
.home-feature-list h3 {
  margin-top: 14px;
  color: var(--ink);
  font-size: 17px;
}
.home-feature-list p {
  margin-top: 8px;
  font-size: 15px;
}
.home-pricing {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  align-items: center;
  gap: clamp(24px, 4vw, 56px);
  padding: clamp(24px, 4vw, 44px);
  border: 1px solid var(--line);
  border-radius: 28px;
  background: var(--surface);
  box-shadow: var(--shadow-md);
}
.home-pricing > div > .text-link {
  margin-top: 16px;
}
.home-plans {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}
.home-plans > div {
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--surface-2);
}
.home-plans > .featured {
  border-color: color-mix(in srgb, var(--accent) 40%, var(--line));
  background: color-mix(in srgb, var(--accent-soft) 45%, var(--surface));
}
.home-plans dt {
  color: var(--ink);
  font-weight: 600;
}
.home-plan-price {
  margin-top: 8px;
  color: var(--ink);
  font: 400 44px/1 var(--serif);
  letter-spacing: -0.02em;
}
.home-plan-price span {
  color: var(--muted);
  font: 13px var(--sans);
  letter-spacing: 0;
}
.home-plans dd + dd {
  margin-top: 10px;
  color: var(--muted);
  font-size: 14.5px;
}
.home-guides-heading {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}
.article-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr));
  gap: 16px;
  margin-top: 24px;
}
.article-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: var(--surface);
  box-shadow: var(--shadow-sm);
  transition:
    border-color 0.2s var(--ease),
    box-shadow 0.2s var(--ease);
}
.article-card:hover {
  border-color: var(--line-strong);
  box-shadow: var(--shadow-md);
}
.article-card h2,
.article-card h3 {
  color: var(--ink);
  font: 400 26px/1.12 var(--serif);
  letter-spacing: -0.005em;
  text-wrap: balance;
}
/* The whole card follows its heading link. */
.article-card a::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
}
.article-card a:focus-visible {
  outline: none;
}
.article-card:has(a:focus-visible) {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
}
.article-card p {
  max-width: 68ch;
  font-size: 14.5px;
}
.article-card time {
  margin-top: auto;
  padding-top: 6px;
  color: var(--muted);
  font: 500 11px/1.4 var(--mono);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.blog {
  max-width: 880px;
  margin: 0 auto;
}
.blog-hero h1 {
  margin-top: 12px;
  font-size: clamp(40px, 6vw, 64px);
}
.article-list {
  display: grid;
  gap: 16px;
  margin-top: 40px;
}
.article-list .article-card h2 {
  font-size: clamp(26px, 3vw, 32px);
}
.blog-missing h1 {
  margin-top: 12px;
}
.blog-missing .button {
  margin-top: 28px;
}
.article {
  max-width: 720px;
  margin: 0 auto;
}
.breadcrumbs ol {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 0;
  list-style: none;
  color: var(--muted);
  font-size: 13px;
}
.breadcrumbs li + li::before {
  content: "/";
  margin-right: 6px;
  color: var(--faint);
}
.breadcrumbs a:hover {
  color: var(--ink);
}
.breadcrumbs [aria-current] {
  color: var(--ink-2);
}
.article-header .eyebrow {
  margin-top: 28px;
}
.article-header h1 {
  margin-top: 12px;
  font-size: clamp(38px, 5.6vw, 60px);
  line-height: 1.04;
}
.article-header .lede {
  color: var(--ink-2);
  font-size: 18px;
}
.article-byline {
  margin-top: 18px;
  font-size: 13.5px;
}
.prose {
  margin-top: 36px;
  padding-top: 32px;
  border-top: 1px solid var(--line);
  color: var(--ink-2);
  font-size: 17px;
  line-height: 1.7;
  overflow-wrap: break-word;
}
.prose p {
  color: inherit;
}
.prose > * + * {
  margin-top: 18px;
}
.prose h2 {
  margin-top: 44px;
  color: var(--ink);
  font: 400 clamp(26px, 3vw, 32px) / 1.15 var(--serif);
  letter-spacing: -0.005em;
}
.prose h2 + * {
  margin-top: 12px;
}
.prose ul,
.prose ol {
  padding-left: 1.3em;
}
.prose li + li {
  margin-top: 8px;
}
.prose li::marker {
  color: var(--accent-text);
}
.prose strong {
  color: var(--ink);
}
.prose a {
  color: var(--accent-text);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}
.prose code {
  padding: 2px 6px;
  border-radius: 6px;
  background: var(--sunken);
  color: var(--ink);
  font: 0.84em var(--mono);
  overflow-wrap: anywhere;
}
.prose ol.checklist {
  padding: 0;
  list-style: none;
}
.prose ol.checklist li {
  position: relative;
  padding-left: 34px;
}
.prose ol.checklist li::before {
  content: "";
  position: absolute;
  top: 5px;
  left: 0;
  width: 20px;
  height: 20px;
  border: 1.5px solid var(--line-strong);
  border-radius: 6px;
  background: var(--surface);
}
.article-cta {
  margin-top: 56px;
  padding: clamp(24px, 4vw, 36px);
  border: 1px solid var(--line);
  border-radius: 24px;
  background: color-mix(in srgb, var(--accent-soft) 40%, var(--surface));
}
.article-cta h2 {
  color: var(--ink);
  font: 400 clamp(26px, 3vw, 32px) / 1.1 var(--serif);
}
.article-cta p {
  margin-top: 8px;
}
.article-cta .home-actions {
  margin-top: 20px;
}
.related {
  max-width: 1040px;
  margin: clamp(56px, 8vw, 96px) auto 0;
}
.auth-links {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 20px;
  margin-top: 20px;
}
/* The composer's read-only preview of the live delivery's share card. */
.share-preview {
  margin: 16px 0 0;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}
.share-preview figcaption {
  color: var(--ink-2);
  font-size: 12.5px;
  font-weight: 550;
}
.share-preview img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 1200 / 630;
  margin-top: 10px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--sunken);
}
.share-preview .fine-print {
  margin-top: 8px;
}
@media (max-width: 920px) {
  .home-hero,
  .home-pricing {
    grid-template-columns: minmax(0, 1fr);
  }
  .home-sample {
    max-width: 520px;
  }
}
@media (max-width: 760px) {
  .home-feature-list {
    grid-template-columns: minmax(0, 1fr);
  }
  .home-feature-list li + li {
    margin-top: 24px;
  }
  .public-actions {
    gap: 12px;
  }
}
@media (max-width: 520px) {
  .home-plans {
    grid-template-columns: minmax(0, 1fr);
  }
  .home-actions .button {
    flex: 1;
  }
  .home-sample-chat {
    margin-right: 0;
  }
}

/* Audience handoffs reuse the public site's sample, features and plan cards. */
.sample-caption {
  position: relative;
  margin-top: 12px;
  color: var(--muted);
  font-size: 12px;
  text-align: center;
}
.marketing-footer {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 24px 32px;
  width: 100%;
}
.site-footer:has(> .marketing-footer) {
  padding-block: 36px;
}
.footer-group h2 {
  margin-bottom: 12px;
  color: var(--muted);
  font: 600 12px/1.4 var(--sans);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.footer-group ul {
  list-style: none;
  padding: 0;
  margin: 0;
}
.footer-group a {
  display: flex;
  align-items: center;
  min-height: 28px;
  width: fit-content;
  color: var(--ink-2);
  font-size: 14px;
  line-height: 1.5;
}
.footer-group a:hover {
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 4px;
}
@media (max-width: 700px) {
  .marketing-footer {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 28px 24px;
  }
}
.audience .home-hero h1 {
  font-size: clamp(42px, 5.3vw, 64px);
}
.audience .home-sample-files strong {
  white-space: normal;
  overflow-wrap: anywhere;
}
.site-faq {
  margin-top: clamp(64px, 9vw, 112px);
  max-width: 800px;
}
.site-faq dl {
  margin-top: 28px;
}
.site-faq dl > div {
  padding: 24px 0;
  border-top: 1px solid var(--line);
}
.site-faq dt {
  color: var(--ink);
  font-weight: 600;
}
.site-faq dd {
  margin: 8px 0 0;
}
.site-faq dd p + p {
  margin-top: 16px;
}
.pricing-faq {
  margin-inline: auto;
}
.plan-comparison {
  max-width: 800px;
  margin: 64px auto 0;
}
.plan-comparison h2 {
  scroll-margin-top: 88px;
}
.comparison-table {
  width: 100%;
  table-layout: fixed;
  border-collapse: collapse;
  text-align: left;
  font-size: 14px;
  line-height: 1.5;
}
.comparison-table caption {
  text-align: left;
  color: var(--muted);
  margin: 16px 0;
}
.comparison-table th,
.comparison-table td {
  padding: 14px 10px;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
  overflow-wrap: anywhere;
}
.comparison-table th {
  font-weight: 600;
  color: var(--ink);
}
.plan-comparison .comparison-table th:first-child {
  width: 40%;
}
.plan-comparison .fine-print {
  margin-top: 16px;
}
.handoff-template {
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface);
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.prose .handoff-template code {
  padding: 0;
  background: transparent;
}
@media (max-width: 520px) {
  .comparison-table th,
  .comparison-table td {
    padding: 12px 6px;
  }
  .public-actions {
    gap: 10px;
    font-size: 13px;
    grid-column: 2;
  }
  .layout-site .site-header-inner {
    gap: 12px;
  }
}
@media (max-width: 360px) {
  .layout-site .site-header-inner {
    height: auto;
    min-height: var(--header);
    grid-template-columns: 1fr;
    gap: 10px;
    padding-block: 12px;
  }
  .layout-site .public-actions {
    grid-column: 1;
    justify-self: start;
  }
}
.audience .home-pricing .fine-print {
  margin-top: 16px;
}

/* Original file viewer, shared by sender and recipient pages. Its frame,
   backdrop and entrance match the Dropbox browser and confirmation dialogs. */
.file-viewer {
  width: min(1100px, calc(100vw - 32px));
  max-width: none;
  max-height: calc(100dvh - 32px);
  padding: 22px 28px 20px;
  border: 1px solid var(--line);
  border-radius: 26px;
  background: var(--surface);
  color: var(--ink);
  box-shadow: var(--shadow-lg);
}
.file-viewer[open] {
  display: flex;
  flex-direction: column;
  gap: 14px;
  animation: pop 0.2s var(--ease);
}
.file-viewer::backdrop {
  background: rgb(10 10 9 / 45%);
  -webkit-backdrop-filter: blur(4px);
  backdrop-filter: blur(4px);
}
.file-viewer header {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 2px 16px;
  align-items: start;
}
.file-viewer h2 {
  font: 400 26px/1.15 var(--serif);
  letter-spacing: -0.01em;
  overflow-wrap: anywhere;
}
.file-viewer header p {
  grid-column: 1;
  color: var(--muted);
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}
.file-viewer header button {
  grid-column: 2;
  grid-row: 1 / 3;
}
/* Media centres with auto margins rather than flex alignment, so an
   actual-size image larger than the stage scrolls from its edges instead of
   being clipped on the top and left. */
.file-viewer-stage {
  display: flex;
  height: 64dvh;
  min-height: 0;
  overflow: auto;
  overscroll-behavior: contain;
  background: var(--bg);
  border-radius: var(--radius);
}
.file-viewer-stage > * {
  margin: auto;
}
.file-viewer-stage img,
.file-viewer-stage video {
  display: block;
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
}
.file-viewer-stage audio {
  width: min(100% - 32px, 700px);
}
.file-viewer-stage.actual-size img {
  flex: none;
  max-width: none;
  max-height: none;
}
.file-viewer > p {
  color: var(--muted);
  font-size: 13.5px;
}
.file-viewer > p:empty {
  display: none;
}
.file-viewer footer {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.file-viewer-position {
  margin-right: auto;
  padding-left: 4px;
  color: var(--muted);
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}
@media (max-width: 600px) {
  .file-viewer {
    width: 100vw;
    max-width: 100vw;
    height: 100dvh;
    max-height: 100dvh;
    margin: 0;
    padding: 18px 16px 16px;
    border: 0;
    border-radius: 0;
  }
  .file-viewer h2 {
    font-size: 22px;
  }
  .file-viewer-stage {
    flex: 1;
    height: auto;
  }
  /* Previous and Next keep their arrows; the words stay for assistive tech. */
  .file-viewer-step {
    width: 42px;
    padding: 0;
  }
  .file-viewer-step span {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
  }
  .file-viewer footer a {
    flex-basis: 100%;
  }
}

/* Links to the branded delivery demo. */
.home-feature-list p a {
  color: var(--accent-text);
  font-weight: 550;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}
.plan-demo-link {
  margin-top: 20px;
}

/* Branded delivery demo: the real recipient page in a browser frame, with
   controls that restyle it and its share card in place. */
.brand-demo-hero {
  max-width: 720px;
}
.brand-demo-hero h1 {
  margin-top: 16px;
  font-size: clamp(44px, 6.2vw, 76px);
  line-height: 1.02;
}
.brand-demo-hero h1 em {
  color: var(--accent);
}
.brand-demo-hero .fine-print {
  margin-top: 14px;
}
.brand-demo-caption {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--ink-2);
}
.brand-demo-stage {
  margin-top: clamp(40px, 6vw, 72px);
}
.brand-demo-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
}
.demo-segmented {
  display: inline-flex;
  min-width: 0;
  margin: 0;
  padding: 4px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: var(--surface);
}
.demo-segmented input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
  min-height: 0;
  margin: 0;
  padding: 0;
  pointer-events: none;
}
.demo-segmented label {
  margin: 0;
  padding: 7px 16px;
  border-radius: 999px;
  color: var(--muted);
  font-size: 13.5px;
  font-weight: 550;
  cursor: pointer;
  transition:
    background 0.15s,
    color 0.15s;
}
.demo-segmented label:hover {
  color: var(--ink);
}
.demo-segmented input:checked + label {
  background: var(--ink);
  color: var(--bg);
}
.demo-segmented input:focus-visible + label {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
}
.brand-demo-workspace {
  display: grid;
  gap: 24px;
}
.brand-demo-workspace > * {
  min-width: 0;
}
@media (min-width: 1024px) {
  .brand-demo-workspace:has(> .brand-demo-panel:not([hidden])) {
    grid-template-columns: minmax(0, 1fr) 340px;
    align-items: start;
  }
  .brand-demo-panel {
    position: sticky;
    top: 16px;
  }
}
.demo-browser {
  margin: 0;
  overflow: hidden;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow-lg);
}
.demo-browser-tabs {
  display: flex;
  align-items: flex-end;
  gap: 14px;
  padding: 10px 14px 0;
  background: var(--sunken);
}
.demo-browser-dots {
  display: flex;
  gap: 6px;
  padding-bottom: 12px;
}
.demo-browser-dots span {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--line-strong);
}
.demo-browser-tab {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  max-width: 280px;
  padding: 8px 14px;
  border-radius: 10px 10px 0 0;
  background: var(--surface);
  color: var(--ink-2);
  font-size: 12.5px;
}
.demo-tab-icon {
  flex-shrink: 0;
  width: 16px;
  height: 16px;
  object-fit: contain;
}
.demo-tab-dot {
  flex-shrink: 0;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--faint);
}
.demo-tab-title {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.demo-browser-bar {
  padding: 8px 12px;
  border-bottom: 1px solid var(--line);
}
.demo-address {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  padding: 7px 14px;
  border-radius: 999px;
  background: var(--sunken);
  color: var(--ink-2);
  font: 12.5px/1.4 var(--mono);
}
.demo-address > span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.demo-browser-viewport {
  position: relative;
  height: clamp(460px, 72vh, 680px);
  overflow: hidden;
  background: var(--sunken);
}
.demo-browser-viewport iframe {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
  background: var(--bg);
}
/* /brand-demo.js lays the page out at a desktop or phone width, then scales
   it to the frame. */
.demo-browser-viewport[data-scaled] iframe {
  position: absolute;
  top: 0;
  left: calc((100% - var(--demo-frame-width) * var(--demo-scale)) / 2);
  width: var(--demo-frame-width);
  height: calc(100% / var(--demo-scale));
  transform: scale(var(--demo-scale));
  transform-origin: 0 0;
}
.demo-browser[data-device="phone"] .demo-browser-viewport {
  height: clamp(560px, 82vh, 760px);
}
.demo-browser[data-device="phone"] .demo-browser-viewport iframe {
  border-inline: 1px solid var(--line-strong);
}
.demo-browser .sample-caption {
  padding: 10px 16px;
  border-top: 1px solid var(--line);
}
.brand-demo-panel h2 {
  color: var(--ink);
  font: 400 26px/1.1 var(--serif);
  letter-spacing: -0.01em;
}
.brand-demo-panel > label:first-of-type {
  margin-top: 20px;
}
.demo-premium {
  min-width: 0;
  margin: 24px 0 0;
  padding: 20px 0 0;
  border: 0;
  border-top: 1px solid var(--line);
}
.demo-premium legend {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0;
  float: left;
  width: 100%;
  color: var(--ink);
  font-weight: 600;
}
.demo-premium legend + * {
  clear: both;
}
.demo-premium:disabled > :not(legend):not(.demo-premium-note) {
  opacity: 0.5;
}
.demo-premium-note {
  padding-top: 4px;
  color: var(--ink-2);
}
.demo-field-label {
  display: block;
  margin: 18px 0 8px;
  color: var(--ink-2);
  font-size: 13px;
  font-weight: 550;
}
.demo-logo-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
}
.demo-logo-preview {
  display: grid;
  place-items: center;
  width: 112px;
  height: 48px;
  padding: 6px 8px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface-2);
}
.demo-logo-preview img {
  max-width: 100%;
  max-height: 32px;
  object-fit: contain;
}
.demo-logo-preview span {
  color: var(--muted);
  font-size: 12.5px;
}
.brand-demo-panel .demo-logo-choose {
  gap: 6px;
  margin: 0;
  cursor: pointer;
}
.demo-premium:disabled .demo-logo-choose {
  cursor: default;
}
#demo-logo:focus-visible + .demo-logo-choose {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
}
.demo-switch-row {
  margin-top: 20px;
}
.demo-switch-row label {
  margin: 0;
}
.demo-reset {
  margin-top: 24px;
}
.brand-demo-share {
  margin-top: clamp(64px, 9vw, 112px);
}
.brand-demo-share-intro {
  max-width: 62ch;
  margin-top: 12px;
}
.demo-unfurls {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr));
  gap: 20px;
  margin-top: 28px;
}
/* Generic chat apps keep their own colours, whatever the page theme. */
.demo-unfurl {
  --chat-bg: #eceae4;
  --chat-bubble: #ffffff;
  --chat-ink: #141413;
  --chat-muted: #67665f;
  --chat-link: #2456a6;
  --chat-line: rgb(20 20 19 / 8%);
  margin: 0;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--chat-bg);
  color: var(--chat-ink);
}
.demo-unfurl.is-dark {
  --chat-bg: #19191b;
  --chat-bubble: #2a2a2d;
  --chat-ink: #f3f2ec;
  --chat-muted: #a3a29a;
  --chat-link: #8ab4ff;
  --chat-line: rgb(243 242 236 / 10%);
}
.demo-unfurl-label {
  margin-bottom: 12px;
  color: var(--chat-muted);
  font: 500 11px/1.4 var(--mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.demo-unfurl-message {
  max-width: 440px;
  padding: 8px;
  border-radius: 18px 18px 18px 6px;
  background: var(--chat-bubble);
  box-shadow: 0 1px 2px rgb(0 0 0 / 8%);
}
.demo-unfurl-message > p {
  padding: 4px 6px 10px;
  color: var(--chat-ink);
  font-size: 14px;
}
.demo-unfurl-link {
  color: var(--chat-link);
  overflow-wrap: anywhere;
}
.demo-unfurl-preview {
  overflow: hidden;
  border: 1px solid var(--chat-line);
  border-radius: 12px;
}
.demo-unfurl-image {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 1200 / 630;
  object-fit: cover;
}
.demo-unfurl-meta {
  display: grid;
  gap: 2px;
  padding: 10px 12px 12px;
  color: var(--chat-muted);
  font-size: 12.5px;
}
.demo-unfurl-meta strong {
  color: var(--chat-ink);
  font-size: 14px;
  overflow-wrap: anywhere;
}
.demo-unfurl-meta span {
  overflow-wrap: anywhere;
}
/* An HTML copy of the delivery share card. Card pixels map to cqw, with
   1200 px across, so it scales like the image. */
.share-card-mock {
  container-type: inline-size;
  display: flex;
  flex-direction: column;
  aspect-ratio: 1200 / 630;
  overflow: hidden;
  /* The card's glows, as percentages: a container cannot use its own cqw. */
  background:
    radial-gradient(48.8% 93% at 94% 6%, var(--card-wash-a), transparent),
    radial-gradient(43.4% 82.7% at 56% 118%, var(--card-wash-b), transparent),
    radial-gradient(38.4% 73.2% at 0 0, var(--card-wash-c), transparent),
    var(--card-paper);
  color: var(--card-ink);
  font-family: var(--sans);
}
.share-card-mock > * {
  margin-inline: 6cqw;
}
.scm-top {
  display: flex;
  align-items: center;
  height: 8cqw;
  margin-top: 5.333cqw;
}
.scm-logo {
  width: auto;
  max-width: 25cqw;
  height: 8cqw;
  object-fit: contain;
  object-position: left center;
}
.scm-monogram {
  display: grid;
  place-items: center;
  width: 7cqw;
  height: 7cqw;
  border-radius: 50%;
  background: var(--card-monogram);
  color: var(--card-on-monogram);
  font: 400 4.333cqw/1 var(--serif);
}
.scm-brand {
  display: inline-flex;
  align-items: center;
  gap: 1.1cqw;
  color: var(--card-ink);
  font-size: 3cqw;
  font-weight: 600;
  letter-spacing: -0.01em;
}
.scm-brand svg {
  width: 3.667cqw;
  height: 3.667cqw;
}
.scm-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  justify-content: center;
  gap: 1.5cqw;
  min-height: 0;
}
.scm-eyebrow {
  color: var(--card-eyebrow);
  font-size: 1.75cqw;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.scm-title {
  display: -webkit-box;
  overflow: hidden;
  padding-bottom: 0.12em;
  color: var(--card-ink);
  font: 400 var(--card-title-size) / 1.12 var(--serif);
  letter-spacing: -0.01em;
  overflow-wrap: anywhere;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  line-clamp: 3;
}
.scm-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 5.333cqw;
  padding-top: 1.833cqw;
  border-top: 1px solid var(--card-line);
  color: var(--card-muted);
  font-size: 1.833cqw;
}
.scm-delivered {
  display: inline-flex;
  align-items: center;
  gap: 0.833cqw;
}
.scm-delivered .scm-brand {
  gap: 0.65cqw;
  color: var(--card-ink-2);
  font-size: 1.78cqw;
}
.scm-delivered .scm-brand svg {
  width: 2.167cqw;
  height: 2.167cqw;
}
@media (max-width: 600px) {
  .brand-demo-toolbar {
    justify-content: flex-start;
  }
  .demo-browser-tabs {
    padding-inline: 10px;
  }
  .demo-browser-dots {
    display: none;
  }
  .demo-unfurl {
    padding: 12px;
  }
}

/* Integration and alternative pages share the public site's paper-and-ink frame. */
.acquisition {
  max-width: 1040px;
  margin-inline: auto;
}
.acquisition-cta em {
  color: var(--accent);
}
.acquisition-section {
  margin-top: clamp(48px, 7vw, 80px);
}
.acquisition-section h2,
.acquisition-cta h2 {
  font: 400 clamp(28px, 3.5vw, 38px)/1.15 var(--serif);
  color: var(--ink);
  text-wrap: balance;
}
.acquisition-section > p,
.acquisition-choice p {
  margin-top: 16px;
  max-width: 78ch;
}
.acquisition-choice {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 28px;
}
.acquisition-section > .acquisition-choice {
  margin-top: 24px;
}
.acquisition-choice > div {
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--surface);
}
.acquisition-choice h3 {
  font-size: 18px;
  color: var(--ink);
}
.acquisition-details {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-top: 40px;
}
.acquisition-details > div:first-child {
  padding-right: 32px;
}
.acquisition-details > div + div {
  padding-left: 32px;
  border-left: 1px solid var(--line-strong);
}
.acquisition-details h2 {
  font: 600 18px/1.4 var(--sans);
  text-wrap: initial;
}
.acquisition-details p {
  margin-top: 12px;
  font-size: 15px;
  line-height: 1.65;
}
.acquisition-comparison th:first-child {
  width: 22%;
}
.acquisition-comparison td {
  color: var(--ink-2);
}
.acquisition-comparison a,
.acquisition-sources a,
.acquisition-faq a {
  color: var(--accent-text);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.comparison-source {
  white-space: nowrap;
}
.acquisition-sources {
  margin-top: 20px;
  font-size: 13px;
  color: var(--muted);
  line-height: 1.6;
}
.acquisition-sources ol {
  padding-left: 20px;
  margin-block: 10px;
}
.acquisition-facts {
  margin-top: 24px;
}
.acquisition-facts > div {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 2.5fr);
  gap: 20px;
  padding-block: 16px;
  border-bottom: 1px solid var(--line);
}
.acquisition-facts dt {
  font-weight: 600;
  color: var(--ink);
}
.acquisition-facts dd {
  color: var(--ink-2);
}
.acquisition-faq {
  margin-top: 24px;
}
.acquisition-faq details {
  padding: 20px 0;
  border-bottom: 1px solid var(--line);
}
.acquisition-faq summary {
  cursor: pointer;
  color: var(--ink);
  font-weight: 600;
}
.acquisition-faq details p {
  margin-top: 12px;
  max-width: 78ch;
}
.acquisition-steps {
  padding-left: 28px;
  margin-top: 24px;
}
.acquisition-steps li {
  padding: 0 0 24px 8px;
}
.acquisition-steps li::marker {
  color: var(--accent-text);
  font-weight: 600;
}
.acquisition-steps li:last-child {
  padding-bottom: 0;
}
.acquisition-steps h3 {
  color: var(--ink);
  font-size: 18px;
}
.acquisition-steps p {
  margin-top: 8px;
  max-width: 78ch;
}
.acquisition-cta {
  margin-top: 80px;
  padding: clamp(24px, 4vw, 44px);
  border: 1px solid var(--line);
  border-radius: 28px;
  background: var(--surface);
}
.acquisition-cta h2 {
  margin-top: 12px;
}
.acquisition-cta > p:not(.eyebrow) {
  margin-top: 16px;
}
.acquisition-provider-context {
  margin-top: 32px;
}
.acquisition-related-transfer {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 28px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--surface);
}
.acquisition-related-transfer h2 {
  color: var(--ink);
  font: 400 clamp(26px, 3vw, 32px)/1.15 var(--serif);
}
.acquisition-related-transfer p {
  margin-top: 10px;
  max-width: 68ch;
  font-size: 15px;
  line-height: 1.6;
}
.acquisition-related-transfer .button {
  font-size: 15px;
  white-space: normal;
}
.acquisition-provider-context > .acquisition-provider-note {
  margin-top: 20px;
  color: var(--muted);
}
.acquisition-provider-note a {
  text-decoration: underline;
  text-underline-offset: 3px;
}
@media (max-width: 700px) {
  .acquisition-details {
    grid-template-columns: minmax(0, 1fr);
    gap: 24px;
  }
  .acquisition-details > div:first-child {
    padding-right: 0;
  }
  .acquisition-details > div + div {
    padding: 24px 0 0;
    border-left: 0;
    border-top: 1px solid var(--line-strong);
  }
  .acquisition-related-transfer {
    grid-template-columns: minmax(0, 1fr);
    gap: 20px;
  }
  .acquisition-related-transfer .button {
    justify-self: start;
  }
  .acquisition-choice {
    grid-template-columns: minmax(0, 1fr);
    gap: 24px;
  }
  .acquisition-facts > div {
    grid-template-columns: minmax(0, 1fr);
    gap: 8px;
  }
  .acquisition-comparison {
    font-size: 13px;
  }
}
@media (max-width: 520px) {
  .acquisition-comparison thead {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip-path: inset(50%);
  }
  .acquisition-comparison tbody {
    display: block;
  }
  .acquisition-comparison tr {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    margin-bottom: 20px;
    border: 1px solid var(--line);
    border-radius: 14px;
    overflow: hidden;
  }
  .acquisition-comparison th:first-child {
    grid-column: 1 / -1;
    width: auto;
    background: var(--surface);
    padding: 12px;
  }
  .acquisition-comparison td {
    padding: 12px;
    border-bottom: 0;
  }
  .acquisition-comparison td + td {
    border-left: 1px solid var(--line);
  }
  .acquisition-comparison td::before {
    content: attr(data-label);
    display: block;
    margin-bottom: 8px;
    color: var(--ink);
    font-weight: 600;
  }
}

.acquisition-hero {
  margin-top: 40px;
  gap: clamp(28px, 4vw, 56px);
}
.acquisition-hero h1 {
  font-size: clamp(40px, 5vw, 64px);
}
.acquisition-hero .home-lede {
  max-width: 520px;
}
.acquisition-story {
  max-width: 760px;
}
.acquisition-story h2 {
  margin-top: 12px;
}
.acquisition-story p:not(.eyebrow) {
  margin-top: 16px;
  line-height: 1.65;
}
.acquisition-story .text-link {
  margin-top: 20px;
  font-size: 15px;
}
.acquisition-branding {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  align-items: center;
  gap: clamp(28px, 4vw, 48px);
  padding-top: 56px;
  border-top: 1px solid var(--line);
}
.acquisition-branding-copy > h2 {
  margin-top: 12px;
}
.acquisition-branding-copy > h2 em {
  color: var(--accent);
}
.acquisition-branding-copy > p {
  margin-top: 16px;
}
.acquisition-branding-copy > .text-link {
  margin-top: 16px;
}
.branding-preview-controls {
  margin-top: 24px;
}
.branding-preview-controls > .fine-print {
  margin-top: 12px;
}
.branding-preview-fields {
  border: 0;
  padding: 0;
  margin: 18px 0 0;
  min-width: 0;
}
.branding-preview-fields > label:first-of-type {
  margin: 0 0 8px;
}
.branding-preview-fields > select {
  width: 100%;
}
.branding-preview-fields > .demo-segmented {
  margin-block: 16px;
}
.branding-preview-fields:disabled {
  opacity: 0.5;
}
.branding-preview-toggle {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-block: 12px;
  font-size: 14px;
}
.branding-preview-toggle input {
  width: 18px;
  min-height: 18px;
  margin: 0;
  accent-color: var(--accent-strong);
}
.branding-preview-reset {
  margin-top: 10px;
  font-size: 13px;
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
}
.branding-preview-browser {
  min-width: 0;
  width: 100%;
}
.branding-preview-viewport {
  height: 620px;
}
.branding-preview-viewport iframe {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
  background: var(--bg);
}
@media (max-width: 920px) {
  .acquisition-branding {
    grid-template-columns: minmax(0, 1fr);
  }
  .acquisition-branding-copy {
    max-width: 600px;
  }
  .branding-preview-browser {
    max-width: 620px;
  }
}
@media (max-width: 520px) {
  .branding-preview-viewport {
    height: 540px;
  }
}

.acquisition-limit-details {
  margin: 20px 0;
}
.acquisition-limit-details summary {
  cursor: pointer;
  font-weight: 600;
}
.acquisition-limit-details p {
  margin-top: 12px;
  line-height: 1.65;
}
.acquisition-inline-links a {
  display: inline-block;
  margin: 0 16px 8px 0;
  text-decoration: underline;
  text-underline-offset: 3px;
}
