:root {
  --gallery-landscape-ratio: 16 / 9;
  /* Visible Safari viewport from Playwright's iPhone 13 device profile. */
  --gallery-mobile-ratio: 390 / 664;
  color-scheme: light;
  --paper: #f5f2ea; --ink: #181914; --linen: #eae5da; --rule: #cbc5b9;
  --moss: #68705e; --clay: #9a4438; --veil: #10110eee; --white: #ffffff;
  --display: "Source Serif 4", Georgia, serif;
  --ui: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --fast: 120ms; --base: 220ms; --slow: 420ms;
  --space-0: 0px; --space-1: 4px; --space-2: 8px; --space-3: 12px; --space-4: 16px;
  --space-5: 20px; --space-6: 24px; --space-7: 32px; --space-8: 40px; --space-9: 48px;
  --space-10: 64px; --space-11: 80px; --space-12: 112px; --space-13: 160px;
  --radius-control: 2px; --radius-panel: 4px; --radius-pill: 999px;
  --border-hairline: 1px; --border-focus: 2px;
  --content-max: 1560px; --control-min: 44px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; background: var(--paper); color: var(--ink); }
body { margin: 0; font: 16px/1.5 var(--ui); min-width: 320px; }
button, input { font: inherit; color: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 4px; }
button { cursor: pointer; }
button:disabled { cursor: not-allowed; opacity: .48; }
:focus-visible { outline: 2px solid var(--moss); outline-offset: 2px; }
.visually-hidden { position: absolute !important; width: 1px !important; height: 1px !important; padding: 0 !important; margin: -1px !important; overflow: hidden !important; clip: rect(0, 0, 0, 0) !important; white-space: nowrap !important; border: 0 !important; }
svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.5; }
.skip-link { position: fixed; z-index: 100; left: 12px; top: 12px; padding: 12px 16px; background: var(--ink); color: var(--paper); transform: translateY(-150%); }
.skip-link:focus { transform: translateY(0); }
.app-shell { min-height: 100svh; display: flex; flex-direction: column; }
.owner-header { height: 80px; padding: 0 40px; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; border-bottom: 1px solid var(--rule); }
.wordmark { display: inline-flex; width: min-content; flex-direction: column; font: 20px/.78 var(--display); text-decoration: none; letter-spacing: -.04em; }
.wordmark span + span { padding-left: 12px; }
.owner-header nav { display: flex; align-items: stretch; height: 100%; gap: 32px; }
.owner-header nav a { display: grid; place-items: center; text-decoration: none; font-size: 14px; position: relative; }
.owner-header nav a[aria-current]::after { content: ''; position: absolute; bottom: -1px; left: 0; right: 0; height: 2px; background: var(--ink); }
.profile-menu { position: relative; justify-self: end; }
.profile { cursor: pointer; list-style: none; min-height: 44px; border: 0; background: none; display: inline-flex; align-items: center; gap: 10px; }
.profile > span:first-child { display: grid; place-items: center; width: 36px; height: 36px; border: 1px solid var(--ink); border-radius: 50%; font-size: 11px; }
.profile::-webkit-details-marker { display: none; }
.profile-panel { position: absolute; z-index: 5; inset: 100% 0 auto auto; width: min(280px, calc(100vw - 40px)); padding: 16px; background: var(--paper); border: 1px solid var(--rule); box-shadow: 0 8px 24px #18191415; overflow-wrap: anywhere; }
.profile-panel > span { display: block; margin-top: 4px; font-size: 14px; }
.profile-panel > button { width: 100%; min-height: 44px; margin-top: 12px; padding: 8px 0; border: 0; border-top: 1px solid var(--rule); background: none; text-align: left; }
main:not(.auth-layout, .client-gallery) { flex: 1; }
.owner-footer { margin-top: auto; min-height: 64px; padding: 0 40px; border-top: 1px solid var(--rule); display: flex; justify-content: space-between; align-items: center; gap: 24px; font-size: 12px; color: #57594f; }
.owner-footer nav, .client-footer nav, .legal-footer nav { display: flex; flex-wrap: wrap; gap: 12px 22px; }
.session-banner { padding: 12px 40px; background: var(--linen); border-bottom: 1px solid var(--rule); text-align: center; }
.session-banner button { border: 0; padding: 8px; background: none; text-decoration: underline; min-height: 44px; }

.dashboard, .editor-page { width: min(100%, 1560px); margin-inline: auto; padding: 80px clamp(32px, 6vw, 96px) 112px; }
.dashboard-heading { display: flex; justify-content: space-between; align-items: end; gap: 40px; margin-bottom: 64px; }
.eyebrow { margin: 0 0 12px; text-transform: uppercase; letter-spacing: .14em; font-size: 12px; font-weight: 650; }
h1, h2, p { margin-top: 0; }
h1, h2 { font-family: var(--display); font-weight: 400; letter-spacing: -.035em; }
.dashboard h1, .editor-heading h1 { margin: 0; font-size: clamp(48px, 7vw, 88px); line-height: .98; }
.lead { max-width: 560px; margin: 20px 0 0; font-size: 18px; color: #52544c; }
.button { min-height: 48px; display: inline-flex; align-items: center; justify-content: center; gap: 20px; border: 1px solid var(--ink); border-radius: 2px; padding: 12px 22px; background: var(--ink); color: var(--paper); text-decoration: none; transition: background var(--fast), color var(--fast); }
.button:hover:not(:disabled) { background: var(--moss); border-color: var(--moss); }
.button.secondary { background: transparent; color: var(--ink); }
.button.secondary:hover { background: var(--linen); border-color: var(--ink); }
.icon-button { display: grid; place-items: center; min-width: 44px; min-height: 44px; border: 1px solid var(--rule); background: transparent; }
.icon-button:hover { background: var(--linen); }
.text-button { min-height: 44px; padding: 8px 0; border: 0; background: none; text-decoration: underline; text-underline-offset: 4px; }
.usage { margin-bottom: 80px; padding: 20px 0; display: grid; grid-template-columns: 220px 1fr; gap: 32px; align-items: center; border-block: 1px solid var(--rule); font-size: 13px; }
.usage > div { display: flex; justify-content: space-between; gap: 20px; }
progress { width: 100%; height: 4px; border: 0; accent-color: var(--moss); }
.gallery-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 72px 28px; margin-bottom: 64px; }
.gallery-card { min-width: 0; }
.card-art { position: relative; aspect-ratio: var(--gallery-landscape-ratio); display: flex; align-items: flex-end; justify-content: space-between; padding: 18px; text-decoration: none; overflow: hidden; }
.card-art img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.card-index, .placeholder-label { position: relative; z-index: 1; padding: 6px 8px; background: #f5f2eae6; font-size: 11px; text-transform: uppercase; letter-spacing: .1em; }
.card-meta { display: flex; justify-content: space-between; align-items: start; gap: 20px; padding-top: 18px; border-top: 1px solid var(--ink); }
.card-meta h2 { margin: 4px 0 6px; font-size: clamp(26px, 3vw, 40px); line-height: 1.05; }
.card-meta h2 a { text-decoration: none; }
.card-meta p { margin-bottom: 0; color: #5c5e55; font-size: 13px; }
.status { display: flex; gap: 7px; align-items: center; text-transform: uppercase; letter-spacing: .1em; font-size: 10px !important; }
.status-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--moss); }
.empty-state { min-height: 400px; border: 1px solid var(--rule); display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 48px 20px; }
.empty-state h2 { font-size: clamp(38px, 5vw, 64px); margin-bottom: 12px; }
.empty-state > p:not(.eyebrow) { max-width: 440px; color: #57594f; }
.empty-mark { width: 64px; height: 64px; border: 1px solid var(--rule); border-radius: 50%; display: grid; place-items: center; margin-bottom: 24px; }
.skeleton-list > div { height: 360px; background: linear-gradient(100deg, var(--linen) 20%, #f0ece3 38%, var(--linen) 56%); background-size: 200% 100%; animation: shimmer 1.2s linear infinite; }
@keyframes shimmer { to { background-position: -200% 0; } }

.auth-layout { min-height: 100svh; display: grid; grid-template-columns: minmax(320px, .95fr) minmax(420px, 1.05fr); }
.auth-editorial { container-type: inline-size; min-height: 100svh; padding: 48px clamp(32px, 6vw, 96px); background: var(--ink); color: var(--paper); display: flex; flex-direction: column; justify-content: space-between; }
.wordmark.inverse { color: var(--paper); }
.auth-editorial h1 { max-width: 720px; margin-bottom: 28px; font-size: clamp(54px, 8vw, 120px); line-height: .84; }
.auth-editorial h1.auth-register-title { font-size: clamp(26px, 10cqi, 76px); line-height: 1; overflow-wrap: anywhere; }
.auth-editorial > div > p:last-child { max-width: 460px; color: #c9c6bc; font-size: 18px; }
.auth-footnote { color: #9e9e94; font-size: 12px; }
.auth-form-wrap { display: grid; place-items: center; padding: 40px; }
.auth-form { width: min(100%, 430px); }
.auth-form h2 { margin-bottom: 40px; font-size: clamp(36px, 5vw, 54px); }
label { display: grid; gap: 8px; margin-bottom: 24px; font-size: 14px; font-weight: 600; }
label > span { color: #6a6c64; font-size: 12px; font-weight: 400; }
input { width: 100%; min-height: 48px; padding: 11px 12px; border: 1px solid #888a80; border-radius: 2px; background: #faf8f2; }
select { width: 100%; min-height: 48px; padding: 11px 12px; border: 1px solid #888a80; border-radius: 2px; background: #faf8f2; color: var(--ink); font: inherit; }
input:disabled { color: #63655e; background: var(--linen); }
select:disabled { color: #63655e; background: var(--linen); }
.auth-form .button { width: 100%; margin-top: 8px; }
.auth-code-actions { display: flex; flex-wrap: wrap; gap: 12px 24px; margin-top: 12px; }
.auth-switch { margin-top: 28px; color: #57594f; font-size: 13px; }
.auth-legal { margin-top: 18px; color: #6a6c64; font-size: 11px; }
.auth-consent { grid-template-columns: auto 1fr; align-items: start; gap: 10px; margin-bottom: 12px; }
.auth-consent input { width: 18px; min-height: 18px; margin: 2px 0 0; accent-color: var(--ink); }
.auth-consent > span { color: #57594f; font-size: 13px; }
.form-error { margin: -8px 0 20px; padding: 12px; border-left: 3px solid var(--clay); background: #f2e5df; font-size: 14px; }

.back-link { display: inline-block; margin-bottom: 48px; font-size: 14px; }
.editor-heading { display: flex; justify-content: space-between; align-items: end; gap: 32px; padding-bottom: 40px; border-bottom: 1px solid var(--rule); }
.step { font-size: 12px; text-transform: uppercase; letter-spacing: .1em; }
.editor-layout { margin-top: 40px; display: grid; grid-template-columns: minmax(320px, 1fr) minmax(360px, 1fr); gap: 24px; }
.panel { min-height: 460px; padding: clamp(28px, 4vw, 56px); border: 1px solid var(--rule); }
.panel h2, .upload-list h2 { margin-bottom: 32px; font-size: clamp(32px, 4vw, 48px); }
.metadata-form { display: flex; flex-direction: column; }
.metadata-form .button { align-self: flex-start; margin-top: auto; }
.next-step { display: grid; grid-template-columns: auto 1fr; gap: 32px; background: var(--linen); }
.step-number { font: 54px/1 var(--display); color: var(--moss); }
.next-step p:not(.eyebrow) { max-width: 470px; color: #57594f; }
.editor-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.share-link { min-width: 0; margin: 24px 0 0; }
.share-link input { font-weight: 400; cursor: text; }
.owner-photo-toolbar { display: flex; justify-content: space-between; align-items: end; flex-wrap: wrap; gap: 16px; padding-top: 24px; }
.owner-view-tabs { display: flex; gap: 28px; margin-top: 30px; border-bottom: 1px solid var(--rule); }
.owner-view-tabs button { min-height: 48px; padding: 0 2px; border: 0; border-bottom: 2px solid transparent; background: transparent; color: #64665e; font: inherit; }
.owner-view-tabs button[aria-pressed="true"] { border-bottom-color: var(--ink); color: var(--ink); }
.owner-photo-tabs { display: flex; flex-wrap: wrap; gap: 8px; }
.owner-photo-tabs button { min-height: 44px; padding: 9px 16px; border: 1px solid var(--rule); background: transparent; }
.owner-photo-tabs button[aria-pressed="true"] { border-color: var(--ink); background: var(--ink); color: var(--paper); }
.owner-preview-status { padding: 24px 0 12px; color: #57594f; }
.owner-preview-hero { margin: 0 0 28px; padding: 24px; background: var(--linen); text-align: center; }
.owner-preview-hero img { display: block; width: auto; max-width: 100%; max-height: min(72svh, 900px); height: auto; margin: auto; object-fit: contain; }
.owner-preview-hero figcaption { display: flex; justify-content: center; align-items: center; flex-wrap: wrap; gap: 8px 18px; margin-top: 16px; font-size: 13px; overflow-wrap: anywhere; }
.owner-preview-hero figcaption strong { font: 11px var(--ui); letter-spacing: .08em; text-transform: uppercase; }
.owner-photo-actions { display: flex; align-items: center; flex-wrap: wrap; justify-content: center; gap: 18px; }
.text-button.danger { color: var(--clay); }
.owner-preview-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); align-items: start; gap: 16px; }
.owner-preview-tile { min-width: 0; height: fit-content; padding: 8px; border: 1px solid var(--rule); background: transparent; text-align: left; }
.owner-preview-tile.is-selected { border-color: var(--ink); outline: 2px solid var(--ink); outline-offset: 2px; background: var(--linen); }
.owner-preview-tile img { display: block; width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: contain; background: var(--linen); }
.owner-preview-tile span { display: block; padding-top: 6px; font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.move-controls { display: grid; gap: 16px; margin: 24px 0; padding: 20px; border: 1px solid var(--ink); background: var(--linen); }
.move-selection, .move-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 12px 20px; }
.move-controls label { display: grid; gap: 8px; max-width: 420px; font-size: 13px; }
.move-controls select { min-height: 44px; padding: 8px; font: inherit; }
.move-controls progress { width: min(100%, 420px); }
.owner-preview-tile { position: relative; cursor: pointer; }
.owner-preview-tile .move-check { position: absolute; top: 16px; left: 16px; display: grid; place-items: center; width: 28px; height: 28px; padding: 0; border: 1px solid rgba(255,255,255,.88); border-radius: 50%; background: rgba(20,20,17,.32); color: var(--paper); font-size: 18px; line-height: 1; box-shadow: 0 2px 12px rgba(0,0,0,.12); }
.owner-preview-tile.is-selected .move-check { background: var(--ink); color: var(--paper); }
.favorite-count { display: block; padding-top: 5px; color: #8b3f43; font-size: 12px; }
.favorite-folder-group + .favorite-folder-group { margin-top: 44px; }
.favorite-folder-heading { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; margin-bottom: 16px; padding-bottom: 10px; border-bottom: 1px solid var(--rule); }
.favorite-folder-heading h2 { margin: 0; font: 24px/1.15 var(--display); }
.favorite-folder-heading span { color: #777970; font-size: 12px; }
.cover-badge { display: block; padding-top: 5px; color: var(--moss); font: 11px var(--ui); letter-spacing: .06em; text-transform: uppercase; }
.batch-photo-actions { position: fixed; z-index: 20; left: 50%; bottom: 24px; display: flex; align-items: center; flex-wrap: wrap; gap: 12px 20px; width: max-content; max-width: calc(100vw - 40px); padding: 14px 18px; border: 1px solid #33332e; border-radius: 6px; background: #242421; color: var(--paper); box-shadow: 0 14px 38px rgba(0,0,0,.22); transform: translateX(-50%); }
.batch-photo-actions .text-button { color: inherit; }
.batch-photo-actions .danger { color: #ff8f91; }
.batch-photo-actions select { min-height: 38px; max-width: 220px; padding: 7px 34px 7px 10px; border-color: #67675f; background: #242421; color: var(--paper); font: inherit; }
.batch-close { width: 32px; height: 32px; padding: 0; border: 0; background: transparent; color: inherit; font-size: 24px; line-height: 1; }
.batch-status { flex-basis: 100%; color: #d7d7cf; font-size: 12px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.inline-note, .prototype-note { padding: 16px; border-left: 3px solid var(--moss); background: var(--linen); font-size: 14px; }
.drop-zone { min-height: 360px; border: 1px dashed #8d8e85; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 32px; cursor: pointer; transition: background var(--fast), border-color var(--fast); }
.drop-zone:hover, .drop-zone:focus-within { border-color: var(--ink); background: var(--linen); }
.drop-zone.is-drag-over { border-color: var(--moss); background: #e8e8de; }
.workspace-photo-area.is-drag-over { outline: 2px dashed var(--moss); outline-offset: 8px; background: #e8e8de; }
.drop-zone.is-busy { cursor: wait; }
.drop-zone h2 { font-size: clamp(36px, 5vw, 60px); margin-bottom: 8px; }
.upload-overall { margin-top: 20px; padding: 18px 20px; background: var(--linen); border: 1px solid var(--line); }
.upload-overall > div { display: flex; justify-content: space-between; gap: 16px; margin-bottom: 10px; }
.upload-overall span { color: var(--muted); text-align: right; }
.fine-print { margin: 16px 0 0; font-size: 12px; color: #61635b; }
.upload-list { margin-top: 64px; }
.section-heading { display: flex; justify-content: space-between; align-items: baseline; border-bottom: 1px solid var(--ink); }
.upload-row { min-height: 96px; display: grid; grid-template-columns: 72px 1fr auto; align-items: center; gap: 20px; border-bottom: 1px solid var(--rule); }
.thumb { width: 64px; height: 64px; }
.upload-row > div:nth-child(2) { display: grid; gap: 4px; }
.upload-row span { font-size: 12px; color: #62645c; }
.state-mark { font-size: 18px !important; color: var(--moss) !important; }
.state-mark.upload-failed { color: var(--clay) !important; }
.prototype-note { max-width: 680px; margin-top: 48px; }
.prototype-note p { margin: 4px 0 0; }

.dialog-backdrop { position: fixed; z-index: 20; inset: 0; padding: 24px; display: grid; place-items: center; background: var(--veil); }
.dialog { position: relative; width: min(100%, 600px); max-height: calc(100svh - 48px); overflow: auto; padding: clamp(32px, 6vw, 64px); background: var(--paper); }
.dialog h2 { margin-bottom: 8px; font-size: clamp(38px, 6vw, 60px); }
.dialog > p:not(.eyebrow) { margin-bottom: 36px; color: #5c5e56; }
.dialog-close { position: absolute; top: 18px; right: 18px; }
.dialog-actions { display: flex; justify-content: flex-end; gap: 12px; padding-top: 16px; }
.toast { position: fixed; z-index: 30; right: 24px; bottom: 24px; max-width: 340px; background: var(--ink); color: var(--paper); padding: 14px 18px; transform: translateY(calc(100% + 40px)); transition: transform var(--base); }
.toast:not(:empty) { transform: translateY(0); }
.not-found { display: grid; place-items: start; align-content: center; min-height: 70svh; }

.client-gallery { background: var(--paper); }
.client-access { min-height: 100svh; display: grid; place-items: center; padding: 32px; background: var(--linen); }
.client-access > section { width: min(100%, 520px); padding: clamp(32px, 7vw, 72px); background: var(--paper); border: 1px solid var(--rule); }
.client-access h1 { margin: 36px 0; font-size: clamp(48px, 8vw, 82px); line-height: .9; }
.client-access form { display: grid; gap: 24px; }
.gallery-cover {
  --cover-ratio: var(--gallery-landscape-ratio);
  position: relative; aspect-ratio: var(--cover-ratio); display: flex; align-items: flex-end;
  padding: clamp(24px, 7vw, 112px); color: var(--white); background: var(--ink);
}
.gallery-cover[data-cover-device="mobile"] { --cover-ratio: var(--gallery-mobile-ratio); }
/* Keep the crop fixed even if a long title needs more height than the image. */
.gallery-cover-image { position: absolute; inset: 0 0 auto; width: 100%; aspect-ratio: var(--cover-ratio); object-fit: cover; object-position: var(--cover-desktop-position, 50% 50%); }
.gallery-cover[data-cover-device="mobile"] .gallery-cover-image { object-position: var(--cover-mobile-position, 50% 50%); }
.gallery-cover::after { content: ''; position: absolute; inset: 0; background: linear-gradient(15deg, #090b08c7, transparent 68%), linear-gradient(180deg, #00000014, #0000008f); pointer-events: none; }
.cover-copy, .scroll-cue { position: relative; z-index: 1; }
.cover-copy { min-width: 0; overflow-wrap: anywhere; }
.cover-copy p, .cover-copy span { text-transform: uppercase; letter-spacing: .13em; font-size: 11px; }
.cover-copy h1 { margin: 12px 0 28px; font-size: clamp(52px, 10vw, 144px); line-height: .76; color: var(--white); }
.scroll-cue { position: absolute; right: clamp(24px, 7vw, 112px); bottom: clamp(24px, 7vw, 112px); min-height: 44px; display: flex; align-items: center; color: var(--white); }
.client-gallery {
  --gallery-bar-height: 72px;
  --gallery-tab-height: 58px;
  --gallery-sticky-height: var(--gallery-bar-height);
}
.client-gallery:has(.client-section-tabs) {
  --gallery-sticky-height: calc(var(--gallery-bar-height) + var(--gallery-tab-height) + 1px);
}
.gallery-bar { min-height: var(--gallery-bar-height); padding: 0 clamp(20px, 5vw, 80px); display: grid; grid-template-columns: 1fr auto auto auto auto; gap: 24px; align-items: center; border-bottom: 1px solid var(--rule); position: sticky; top: 0; z-index: 5; background: #f5f2eaf2; backdrop-filter: blur(12px); }
.gallery-bar > span { font-family: var(--display); font-size: 18px; }
.gallery-bar button { justify-self: end; min-height: 44px; display: flex; align-items: center; gap: 8px; border: 0; background: none; }
.download-all-status { margin: 0; padding: 10px clamp(20px, 5vw, 80px); border-bottom: 1px solid var(--rule); color: #5b5d55; font-size: 13px; text-align: right; }
.client-section-tabs { position: sticky; top: var(--gallery-bar-height); z-index: 4; display: flex; gap: 30px; overflow-x: auto; padding: 0 clamp(20px, 6vw, 96px); border-bottom: 1px solid var(--rule); background: #f5f2eaf2; backdrop-filter: blur(12px); scrollbar-width: none; }
.client-section-tabs::-webkit-scrollbar { display: none; }
.client-section-tabs button { flex: 0 0 auto; min-height: var(--gallery-tab-height); padding: 2px 0 0; border: 0; border-bottom: 2px solid transparent; background: none; color: #66675f; font: 13px var(--ui); cursor: pointer; }
.client-section-tabs button[aria-pressed="true"] { border-bottom-color: var(--ink); color: var(--ink); }
.client-section-tabs button span { margin-left: 5px; color: #85867e; font-size: 11px; }
.series { max-width: 1560px; margin-inline: auto; padding: 112px clamp(20px, 6vw, 96px) 160px; }
.section-title { display: grid; grid-template-columns: auto 1fr auto auto; align-items: center; gap: 24px; margin-bottom: 64px; text-transform: uppercase; letter-spacing: .13em; font-size: 11px; }
.section-title::after { content: ''; grid-column: 2; grid-row: 1; height: 1px; background: var(--rule); }
.section-title p { margin: 0; }
.section-download { display: inline-flex; align-items: center; gap: 8px; padding: 8px 0; border: 0; border-bottom: 1px solid currentColor; background: transparent; color: inherit; font: inherit; letter-spacing: inherit; text-transform: inherit; cursor: pointer; }
.section-download svg { width: 14px; height: 14px; }
.section-download:disabled { border-bottom-color: transparent; color: #77786f; cursor: wait; }
.gallery-section + .gallery-section { padding-top: 0; }
.folder-panel { align-content: start; }
.folder-list { list-style: none; margin: 8px 0 24px; padding: 0; border-top: 1px solid var(--rule); }
.folder-list li { min-height: 48px; display: flex; align-items: center; justify-content: space-between; gap: 16px; border-bottom: 1px solid var(--rule); }
.folder-list small { color: var(--muted); text-transform: uppercase; letter-spacing: .08em; }
.folder-actions { display: flex; align-items: center; gap: 12px; }
.upload-folder { display: grid; gap: 8px; max-width: 520px; margin: 28px 0; }
.client-photo-grid {
  --grid-photo-height: max(320px, calc(100svh - var(--gallery-sticky-height) - 24px));
  columns: 2; column-gap: 16px;
}
.client-photo-grid article {
  position: relative; break-inside: avoid; margin: 0 auto 16px;
  width: min(100%, calc(var(--grid-photo-height) * var(--photo-aspect)));
}
.client-photo-open { display: block; width: 100%; padding: 0; border: 0; background: transparent; cursor: zoom-in; }
.client-photo-open:focus-visible { outline-offset: -3px; }
.client-photo-grid img { display: block; width: 100%; height: auto; background: var(--linen); }
.photo-download { position: absolute; right: 14px; bottom: 14px; width: 44px; min-height: 44px; padding: 0; display: grid; place-items: center; border: 1px solid #ffffffc7; border-radius: 50%; background: #11130f24; color: var(--white); box-shadow: 0 2px 14px #11130f38; backdrop-filter: blur(4px); transition: opacity var(--fast), transform var(--fast), background var(--fast), color var(--fast); }
.photo-download:hover { border-color: var(--paper); background: var(--paper); color: var(--ink); }
.photo-download svg { width: 19px; height: 19px; }
@media (hover: hover) and (pointer: fine) {
  .photo-download { opacity: 0; transform: translateY(4px); pointer-events: none; }
  .client-photo-grid article:hover .photo-download, .photo-download:focus-visible { opacity: 1; transform: translateY(0); pointer-events: auto; }
}
.photo-favorite { position: absolute; right: 12px; top: 12px; width: 46px; height: 46px; border: 0; border-radius: 50%; background: #f5f2eae8; color: #77786f; font-size: 24px; }
.photo-favorite.is-selected { color: #9a3439; background: #fffaf3f2; }
.favorite-summary { justify-self: end; font: 12px var(--ui) !important; letter-spacing: .08em; text-transform: uppercase; }
html:has(.client-photo-viewer[open]) { overflow: hidden; }
.client-photo-viewer {
  position: fixed; inset: 0; width: 100%; height: 100dvh; max-width: none; max-height: none;
  margin: 0; padding: max(8px, env(safe-area-inset-top)) max(12px, env(safe-area-inset-right))
    max(8px, env(safe-area-inset-bottom)) max(12px, env(safe-area-inset-left));
  border: 0; background: #141512; color: var(--paper); overflow: hidden;
}
.client-photo-viewer[open] { display: grid; grid-template-rows: auto minmax(0, 1fr) auto auto; }
.client-viewer-header { display: flex; justify-content: flex-end; gap: 8px; padding-bottom: 8px; }
.client-viewer-image { display: block; width: 100%; height: 100%; object-fit: contain; }
.client-viewer-status { margin: 0; text-align: center; font-size: 14px; }
.client-viewer-status:not(:empty) { padding-top: 8px; }
.client-viewer-nav { display: grid; grid-template-columns: auto minmax(80px, 1fr) auto; align-items: center; justify-self: center; padding-top: 8px; }
.client-viewer-counter { margin: 0; text-align: center; font-size: 13px; font-variant-numeric: tabular-nums; }
.client-viewer-control { display: grid; place-items: center; width: 44px; height: 44px; padding: 0; border: 1px solid #ffffff40; border-radius: 50%; background: transparent; color: inherit; }
.client-viewer-control:hover { background: #ffffff18; }
.client-viewer-control:focus-visible { outline-color: var(--paper); }
.client-viewer-control[aria-disabled="true"] { opacity: .38; cursor: default; }
.client-viewer-control svg { width: 20px; height: 20px; }
.client-viewer-control.previous svg { transform: rotate(180deg); }
.client-viewer-favorite { font-size: 22px; }
.client-viewer-favorite.is-selected { color: #ff9298; }
.client-footer { padding: 80px clamp(20px, 6vw, 96px); background: var(--ink); color: var(--paper); display: flex; justify-content: space-between; align-items: end; }
.client-footer p { margin: 0; font: clamp(34px, 5vw, 64px)/1 var(--display); }
.client-footer nav { justify-content: flex-end; font-size: 12px; color: #c9c6bc; }
.legal-shell { min-height: 100svh; display: flex; flex-direction: column; }
.legal-header { min-height: 80px; padding: 18px clamp(20px, 5vw, 64px); display: flex; justify-content: space-between; align-items: center; gap: 32px; border-bottom: 1px solid var(--rule); }
.legal-header nav { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 12px 28px; font-size: 13px; }
.legal-header nav a { text-decoration: none; }
.legal-header nav a[aria-current] { text-decoration: underline; text-underline-offset: 6px; }
.legal-page { width: min(100%, 1180px); margin: 0 auto; padding: 80px clamp(20px, 6vw, 80px) 120px; }
.legal-hero { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(280px, .7fr); gap: 48px; align-items: end; padding-bottom: 56px; border-bottom: 1px solid var(--ink); }
.legal-hero h1 { max-width: 760px; margin: 0; font-size: clamp(52px, 8vw, 104px); line-height: .86; }
.legal-hero > p { margin: 0; color: #55574f; font-size: 17px; }
.legal-draft { margin: 24px 0 72px; padding: 18px 20px; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px; border: 1px solid var(--rule); background: var(--linen); font-size: 13px; }
.legal-draft span { color: #5d5f57; }
.legal-content { margin-left: min(20vw, 220px); }
.legal-content section { display: grid; grid-template-columns: minmax(180px, .45fr) minmax(0, 1fr); column-gap: 48px; padding: 36px 0; border-top: 1px solid var(--rule); }
.legal-content section:first-child { border-top-color: var(--ink); }
.legal-content h2 { margin: 0; font: 28px/1.05 var(--display); }
.legal-content p, .legal-content ul { grid-column: 2; color: #44463f; }
.legal-content p:last-child, .legal-content ul:last-child { margin-bottom: 0; }
.legal-content li + li { margin-top: 8px; }
.legal-content code { padding: 1px 4px; background: var(--linen); }
.legal-footer { margin-top: auto; padding: 32px clamp(20px, 5vw, 64px); display: flex; justify-content: space-between; gap: 32px; border-top: 1px solid var(--rule); color: #57594f; font-size: 12px; }
.tone-umber { background: linear-gradient(135deg, #3f352f, #a9856d 62%, #d6b797); }.tone-sage { background: linear-gradient(145deg, #334039, #82927b 56%, #d3cbb6); }.tone-slate { background: linear-gradient(140deg, #2d353a, #687c81 55%, #c6bfb0); }.tone-sand { background: linear-gradient(145deg, #9b795e, #d2b68f 50%, #eee0c7); }.tone-night { background: linear-gradient(125deg, #17201e, #45534c 50%, #9a8a72); }.tone-rose { background: linear-gradient(130deg, #5d3e3d, #ad7770 55%, #ddbaa8); }

@media (max-width: 1023px) {
  .owner-header { padding-inline: 28px; }
  .dashboard, .editor-page { padding: 64px 40px 96px; }
  .editor-layout { grid-template-columns: 1fr; }
  .panel { min-height: 390px; }
}

@media (max-width: 767px) {
  .owner-photo-toolbar > .button, .move-actions .button { width: 100%; justify-content: center; }
  .move-controls { margin-inline: -4px; padding: 16px; }
  .move-controls label, .move-controls select { width: 100%; max-width: none; }
  .batch-photo-actions { right: 12px; bottom: 12px; left: 12px; width: auto; max-width: none; transform: none; }
  .batch-photo-actions .batch-destination { flex: 1 1 180px; }
  .batch-photo-actions select { width: 100%; max-width: none; }
  .owner-header { height: 68px; padding-inline: 20px; grid-template-columns: 1fr auto; }
  .owner-header nav { display: none; }
  .profile-name { display: none; }
  .dashboard, .editor-page { padding: 48px 20px 80px; }
  .dashboard-heading { align-items: stretch; flex-direction: column; margin-bottom: 40px; }
  .dashboard-heading .button { width: 100%; }
  .usage { grid-template-columns: 1fr; gap: 14px; margin-bottom: 48px; }
  .gallery-list { grid-template-columns: 1fr; gap: 56px; }
  .owner-footer { padding-inline: 20px; }
  .owner-footer nav { display: none; }
  .auth-layout { display: block; background: var(--paper); }
  .auth-editorial { min-height: 260px; padding: 28px 20px; }
  .auth-editorial h1 { margin-bottom: 16px; font-size: 52px; }
  .auth-editorial > div > p:last-child, .auth-footnote { display: none; }
  .auth-form-wrap { padding: 48px 20px; }
  .editor-heading { align-items: start; flex-direction: column; }
  .editor-layout { margin-top: 20px; }
  .panel { min-height: 0; padding: 28px 20px; }
  .next-step { grid-template-columns: 1fr; }
  .dialog-backdrop { padding: 0; align-items: end; }
  .dialog { width: 100%; height: 100svh; max-height: none; padding: 72px 20px 24px; }
  .dialog-actions { margin-top: auto; display: grid; grid-template-columns: 1fr 1fr; }
  .upload-row { grid-template-columns: 56px 1fr auto; gap: 12px; }
  .thumb { width: 52px; height: 64px; }
  .gallery-bar { grid-template-columns: 1fr auto; }
  .gallery-bar > span { display: none; }
  .client-section-tabs { gap: 24px; padding-inline: 20px; }
  .gallery-cover { padding: 24px 20px 80px; }
  .gallery-cover[data-cover-device="auto"] { --cover-ratio: var(--gallery-mobile-ratio); }
  .gallery-cover[data-cover-device="auto"] .gallery-cover-image { object-position: var(--cover-mobile-position, 50% 50%); }
  .scroll-cue { right: 20px; bottom: 20px; }
  .series { padding: 72px 16px; }
  .client-footer { padding: 64px 20px; align-items: start; flex-direction: column; gap: 28px; }
  .client-footer nav { justify-content: flex-start; }
  .client-photo-grid { columns: 1; }
  .legal-header { align-items: flex-start; flex-direction: column; }
  .legal-header nav { justify-content: flex-start; }
  .legal-page { padding-top: 56px; }
  .legal-hero { grid-template-columns: 1fr; gap: 28px; }
  .legal-draft { margin-bottom: 48px; }
  .legal-content { margin-left: 0; }
  .legal-content section { grid-template-columns: 1fr; gap: 20px; }
  .legal-content p, .legal-content ul { grid-column: 1; }
  .legal-footer { align-items: flex-start; flex-direction: column; }
}

@media (max-width: 359px) {
  .dialog-actions { grid-template-columns: 1fr; }
}

.gallery-workspace { max-width: 1560px; margin: auto; padding: 24px 48px 180px; }
.gallery-workspace .back-link { margin: 0 0 18px; font-size: 12px; color: #64665e; }
.workspace-heading, .workspace-title, .workspace-delivery, .workspace-photo-heading, .workspace-photo-heading > div, .workspace-photo-tools { display: flex; align-items: center; gap: 16px; }
.workspace-heading, .workspace-photo-heading { justify-content: space-between; }
.workspace-title { min-width: 0; flex-wrap: wrap; gap: 10px 20px; }
.workspace-title h1 { margin: 0; font: 44px/1.15 var(--display); letter-spacing: -.025em; overflow-wrap: anywhere; }
.workspace-state { display: inline-flex; align-items: center; gap: 7px; color: #57594f; font-size: 12px; }
.workspace-state i { width: 6px; height: 6px; border-radius: 50%; background: var(--moss); }
.gallery-workspace .button { min-height: 42px; padding: 10px 18px; font-size: 13px; }
.workspace-summary { margin: 10px 0 0; color: #64665e; font-size: 12px; }
.workspace-summary > span { margin: 0 6px; }
.gallery-workspace .owner-view-tabs { gap: 30px; margin-top: 22px; overflow-x: auto; }
.gallery-workspace .owner-view-tabs button { flex-shrink: 0; font-size: 14px; }
.owner-view-tabs button > span { padding-left: 6px; font-size: 11px; color: #64665e; }
.workspace-folder-row { display: flex; align-items: center; gap: 18px; padding: 24px 0; }
.gallery-workspace .owner-photo-tabs { flex-wrap: nowrap; overflow-x: auto; padding: 2px; }
.gallery-workspace .owner-photo-tabs button { flex-shrink: 0; display: flex; align-items: center; gap: 16px; min-height: 54px; min-width: 130px; padding: 12px 16px; border-radius: 3px; font-size: 13px; }
.gallery-workspace .owner-photo-tabs button[aria-pressed="true"] { background: #e8e8de; color: var(--ink); border-color: var(--moss); }
.owner-photo-tabs button > span { font-size: 11px; opacity: .75; margin-left: auto; }
.add-folder { white-space: nowrap; min-height: 44px; font-size: 13px; }
.workspace-photo-heading h2 { margin: 0; font: 22px/1.25 var(--display); overflow-wrap: anywhere; }
.workspace-photo-heading > div > span { color: #64665e; font-size: 12px; white-space: nowrap; }
.workspace-photo-heading { margin: 2px 0 4px; }
.workspace-photo-tools { flex-shrink: 0; gap: 10px; max-width: 100%; }
.gallery-workspace .owner-preview-status { padding: 0; font-size: 12px; }
.owner-preview-status p { margin: 8px 0; }
.workspace-selection-hint { color: #64665e; font-size: 12px; margin: 0 0 22px; }
.gallery-workspace .owner-preview-grid { grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 28px 20px; }
.workspace-photo { min-width: 0; position: relative; }
.gallery-workspace .owner-preview-tile { width: 100%; padding: 4px; border-color: transparent; border-radius: 3px; background: transparent; }
.gallery-workspace .owner-preview-tile:hover { background: #eae8e0; }
.gallery-workspace .owner-preview-tile img { height: 240px; aspect-ratio: auto; object-fit: contain; background: transparent; }
.gallery-workspace .owner-preview-tile.is-selected { outline: 1px solid var(--moss); outline-offset: 0; border-color: var(--moss); background: #e8e8de; }
.gallery-workspace .owner-preview-tile .photo-filename { padding: 10px 5px 4px; color: #57594f; font-size: 11px; }
.gallery-workspace .owner-preview-tile .move-check { top: 10px; left: 10px; width: 24px; height: 24px; border-radius: 3px; background: var(--paper); color: var(--ink); border-color: #9a9d91; box-shadow: none; opacity: 0; }
.gallery-workspace .owner-preview-tile:hover .move-check, .gallery-workspace .owner-preview-tile:focus-visible .move-check, .gallery-workspace .owner-preview-tile.is-selected .move-check { opacity: 1; }
.gallery-workspace .owner-preview-tile.is-selected .move-check { background: var(--moss); color: white; }
.gallery-workspace .cover-badge, .gallery-workspace .favorite-count { display: inline-block; margin: 0 5px; padding: 0; font-size: 10px; }
.photo-inspect { position: absolute; right: 4px; top: 4px; width: 44px; height: 44px; border: 0; background: var(--paper); font-size: 22px; opacity: 0; }
.workspace-photo:hover .photo-inspect, .workspace-photo:focus-within .photo-inspect { opacity: 1; }
.folder-menu { position: relative; font-size: 13px; }
.folder-menu summary { cursor: pointer; list-style: none; min-width: 44px; min-height: 44px; display: grid; place-items: center; }
.folder-menu summary::-webkit-details-marker { display: none; }
.folder-menu > div { position: absolute; z-index: 5; top: 100%; left: 0; width: 230px; padding: 6px; background: var(--paper); border: 1px solid var(--rule); box-shadow: 0 8px 24px #18191415; }
.folder-menu button, .folder-menu span { display: block; width: 100%; padding: 12px; border: 0; background: none; text-align: left; font-size: 12px; }
.folder-menu button:hover { background: var(--linen); }
.workspace-empty { display: grid; justify-items: center; text-align: center; padding: 70px 24px; margin-top: 24px; border: 1px dashed var(--rule); }
.workspace-empty > svg { width: 32px; height: 32px; color: var(--moss); }
.workspace-empty h3 { font: 30px var(--display); margin: 20px 0 8px; }
.workspace-empty p { max-width: 410px; color: #64665e; font-size: 14px; margin: 0 0 22px; }
.workspace-settings, .workspace-design { padding-top: 38px; display: grid; grid-template-columns: minmax(180px, 1fr) minmax(280px, 2fr); gap: 60px; max-width: 1100px; }
.workspace-section-intro h2 { margin: 0 0 12px; font: 30px var(--display); }
.workspace-section-intro p { color: #64665e; font-size: 14px; max-width: 280px; }
.workspace-settings fieldset { border: 0; border-bottom: 1px solid var(--rule); padding: 0 0 28px; margin: 0 0 24px; display: grid; gap: 20px; }
.workspace-settings legend { padding: 0 0 20px; font-weight: 600; font-size: 14px; }
.workspace-save { display: flex; gap: 16px; flex-wrap: wrap; align-items: center; }
.workspace-save > span { color: #64665e; font-size: 12px; }
.workspace-design { grid-template-columns: minmax(190px, 1fr) minmax(0, 3fr); grid-template-rows: auto 1fr; align-items: start; row-gap: 12px; }
.workspace-design .workspace-section-intro .button { margin: 0 8px 10px 0; }
.cover-empty { padding: 32px; border: 1px dashed var(--rule); }
.cover-previews { grid-column: 2; grid-row: 1 / span 2; display: grid; grid-template-columns: minmax(0, 1fr) minmax(110px, 26%); gap: 16px; align-items: start; }
.cover-previews figure { margin: 0; container-type: inline-size; }
.cover-previews figcaption { margin-bottom: 8px; font-size: 13px; }
.gallery-cover-preview { min-height: 0; overflow: hidden; padding: 7cqw; }
.gallery-cover-preview .cover-copy p { margin: 0; font-size: 2.2cqw; }
.gallery-cover-preview h3 { margin: 2cqw 0 4cqw; font: 10cqw/.82 var(--display); color: inherit; }
.gallery-cover-preview .scroll-cue { right: 7cqw; bottom: 3cqw; min-height: 0; font-size: 2.2cqw; }
.cover-preview-mobile .gallery-cover-preview { padding: 5cqw 5cqw 20cqw; }
.cover-preview-mobile h3 { font-size: 13cqw; }
.cover-preview-mobile p, .cover-preview-mobile .scroll-cue { font-size: 2.8cqw; }
.gallery-cover-preview[data-cover-drag] { touch-action: none; cursor: grab; user-select: none; }
.gallery-cover-preview[data-cover-drag]:active { cursor: grabbing; }
.cover-editor { grid-column: 1; margin-top: 6px; }
.cover-editor > p { margin: 0 0 14px; font-size: 13px; }
.cover-editor fieldset { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 8px 16px; border: 0; padding: 0; margin: 0 0 12px; }
.cover-editor legend { padding: 0; margin-bottom: 8px; font-size: 13px; font-weight: 600; }
.cover-editor label { display: grid; gap: 4px; font-size: 13px; }
.cover-editor input { width: 100%; margin: 0; accent-color: var(--ink); }
.cover-editor-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.workspace-share { display: flex; gap: 20px; align-items: end; max-width: 680px; margin-top: 18px; }
.workspace-share label { flex: 1; min-width: 0; font-size: 12px; }
.workspace-share input { width: 100%; }
.workspace-processing, .workspace-upload-progress { display: flex; justify-content: space-between; gap: 16px; padding: 12px 16px; margin-top: 16px; background: var(--linen); font-size: 12px; }
.photo-viewer-backdrop { padding: 20px; }
.dialog.photo-viewer { width: min(1200px, 100%); max-width: none; padding: 16px; }
.photo-viewer header { display: flex; justify-content: space-between; align-items: center; gap: 16px; }
.photo-viewer h2 { font: 14px var(--ui); margin: 0; overflow-wrap: anywhere; }
.photo-viewer img { display: block; width: 100%; height: calc(90svh - 100px); object-fit: contain; }
@media (hover: none) {
  .photo-inspect, .gallery-workspace .owner-preview-tile .move-check { opacity: 1; }
}
@media (max-width: 900px) {
  .gallery-workspace { padding: 24px 24px 220px; }
  .workspace-settings, .workspace-design { column-gap: 30px; }
  .workspace-photo-heading { align-items: flex-start; }
  .workspace-photo-heading, .workspace-photo-tools { flex-wrap: wrap; }
}
@media (max-width: 599px) {
  .gallery-workspace { padding: 20px 16px 260px; }
  .workspace-heading { flex-wrap: wrap; gap: 14px; }
  .workspace-title { width: 100%; }
  .workspace-title h1 { font-size: 36px; }
  .workspace-delivery { gap: 10px; }
  .gallery-workspace .owner-view-tabs { gap: 22px; margin-top: 16px; }
  .workspace-folder-row { gap: 8px; padding: 18px 0 10px; }
  .add-folder { flex-shrink: 0; width: 44px; font-size: 0; text-decoration: none; }
  .add-folder::after { content: '+'; font-size: 24px; }
  .gallery-workspace .owner-photo-tabs button { min-width: 108px; }
  .gallery-workspace .owner-preview-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px 10px; }
  .gallery-workspace .owner-preview-tile img { height: 180px; }
  .workspace-photo-heading > div { gap: 10px; }
  .workspace-photo-heading h2 { font-size: 22px; }
  .workspace-photo-tools { gap: 8px; }
  .workspace-photo-tools [data-action="upload-folder"] { order: -1; }
  .workspace-photo-tools [data-action="download-owner-section"] { width: 44px; padding: 10px; }
  .workspace-photo-tools [data-action="download-owner-section"] span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
  .workspace-selection-hint { margin-bottom: 16px; }
  .workspace-settings, .workspace-design { display: block; padding-top: 24px; }
  .workspace-section-intro { margin-bottom: 26px; }
  .cover-editor { margin-top: 18px; }
  .workspace-share { flex-wrap: wrap; gap: 8px; }
  .workspace-processing { flex-wrap: wrap; }
  .workspace-photo-heading { position: relative; }
  .folder-menu { position: static; }
  .folder-menu > div { left: 0; right: auto; max-width: calc(100vw - 40px); }
  .photo-viewer-backdrop { padding: 8px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: 1ms !important; animation-iteration-count: 1 !important; transition-duration: 1ms !important; }
}

.auth-form [data-email-code-status] { font-size: 14px; }
.auth-form textarea { width: 100%; padding: 11px 12px; border: 1px solid #888a80; border-radius: 2px; background: #faf8f2; font: inherit; resize: vertical; }

.workspace-upload-progress { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px 24px; }
.upload-preview { display: flex; flex-direction: column; justify-content: flex-end; }
.upload-preview > img { width: 100%; height: 240px; object-fit: contain; }
.upload-preview-status { display: block; font-size: 12px; color: var(--moss); padding-top: 6px; }
.upload-row .thumb img { width: 100%; height: 100%; object-fit: cover; }

/* Billing controls remain readable and independent of the provider's widget. */
.billing-form { width: 100%; max-width: 640px; display: grid; gap: 0; margin: 30px 0; }
.billing-card { border: 1px solid var(--rule); padding: 28px; background: #faf8f2; min-width: 0; }
.billing-card h2 { font-size: 30px; margin: 0 0 5px; }
.billing-card-description { font-size: 14px; color: #66685d; margin: 0 0 26px; }
.billing-periods { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px; border: 0; background: var(--linen); padding: 5px; margin: 0 0 30px; min-width: 0; }
.billing-period { margin: 0; min-width: 0; position: relative; cursor: pointer; font-weight: 400; }
.billing-period input { position: absolute; width: 1px; height: 1px; min-height: 0; padding: 0; opacity: 0; }
.billing-period span { display: grid; place-items: center; min-height: 44px; padding: 10px 6px; color: #66685d; font-size: 14px; }
.billing-period input:checked + span { background: #faf8f2; color: var(--ink); box-shadow: 0 1px 5px #18191412; }
.billing-period input:focus-visible + span { outline: 2px solid var(--ink); outline-offset: 2px; }
.billing-period input:disabled + span { opacity: .6; cursor: default; }
.billing-details { display: grid; gap: 20px; margin: 0; }
.billing-details div { display: flex; justify-content: space-between; align-items: baseline; gap: 20px; }
.billing-details dt { font-size: 14px; color: #66685d; }
.billing-details dd { margin: 0; font-size: 15px; text-align: right; overflow-wrap: anywhere; }
.billing-total { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; border-top: 1px solid var(--rule); margin-top: 25px; padding-top: 24px; font-size: 17px; }
.billing-total strong { font-size: 28px; font-weight: 500; }
.billing-form button[type=submit] { width: 100%; margin-top: 24px; }
.billing-caption { font-size: 12px; color: #64665b; line-height: 1.65; margin: 14px 0 0; }
.billing-test-note { font-size: 11px; color: #77796e; margin: 12px 0 0; }
@media (max-width: 400px) { .billing-card { padding: 22px; } }
.billing-history { padding-left: 20px; line-height: 2; }
.billing > p { margin: 20px 0; }
.billing .billing-support { color: #66685d; font-size: 12px; }

.cookie-notice {
  position: fixed;
  z-index: 10;
  inset: auto 16px max(16px, env(safe-area-inset-bottom)) auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 16px;
  width: min(420px, calc(100% - 32px));
  padding: 14px 16px;
  border: 1px solid var(--rule);
  border-radius: 6px;
  background: var(--paper);
  color: var(--ink);
  box-shadow: 0 6px 24px #18191422;
  font: 14px/1.45 var(--ui);
}
.cookie-notice p { flex: 1 1 230px; margin: 0; }
.cookie-notice a { display: block; margin-top: 4px; text-decoration: underline; }
.cookie-notice .button { min-height: 44px; padding: 8px 14px; font-size: 14px; }

.support-launch.button.secondary {
  position: fixed; bottom: max(16px, env(safe-area-inset-bottom)); left: 16px; z-index: 9;
  background: var(--paper); box-shadow: 0 2px 12px #18191422;
}
.support-dialog {
  position: fixed;
  inset: auto max(16px, env(safe-area-inset-right)) max(16px, env(safe-area-inset-bottom)) auto;
  margin: 0; width: min(420px, calc(100% - 32px)); max-width: none;
  max-height: calc(100dvh - 32px); padding: 18px; border: 1px solid var(--rule);
  border-radius: 6px; color: var(--ink); background: var(--paper);
}
.support-dialog::backdrop { background: #18191446; }
.support-dialog header, .support-inbox header { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.support-dialog h2 { margin: 0; font-size: 27px; line-height: 1.1; }
.support-intro, .support-status { margin: 8px 0; font-size: 14px; }
.support-messages { display: flex; flex-direction: column; gap: 10px; max-height: min(40dvh, 360px); overflow: auto; padding: 0; margin: 12px 0; list-style: none; }
.support-messages li { width: fit-content; max-width: 92%; padding: 8px 12px; background: var(--linen); border-radius: 5px; }
.support-messages .support-message-own { align-self: flex-end; background: #dce2d4; }
.support-messages strong { font-size: 12px; }
.support-messages p { margin: 4px 0 0; font-size: 14px; white-space: pre-wrap; overflow-wrap: anywhere; }
.support-composer { display: grid; gap: 8px; justify-items: start; }
.support-composer[hidden] { display: none; }
.support-composer label { display: grid; gap: 4px; width: 100%; font-size: 14px; }
.support-composer textarea { width: 100%; padding: 8px; resize: vertical; border: 1px solid var(--rule);
  color: inherit; background: var(--white); font: inherit; }
.support-inbox { max-width: 850px; margin: 0 auto; padding: 32px 20px 80px; }
.support-inbox-threads { list-style: none; padding: 0; }
.support-inbox-threads button { width: 100%; padding: 10px; text-align: left; color: var(--ink);
  border: 1px solid var(--rule); background: var(--paper); overflow-wrap: anywhere; }
@media (max-width: 620px) {
  body:has(> .cookie-notice) .support-launch { bottom: max(174px, calc(env(safe-area-inset-bottom) + 154px)); }
}
