:root { --paper:#f4f0e8; --ink:#20201e; --muted:#77746d; --line:#d8d2c8; --orange:#ec6437; --card:#faf8f3; --shadow:0 20px 60px rgba(49,42,32,.08); }
* { box-sizing:border-box; }
html { background:var(--paper); color:var(--ink); font-family:Inter,"Segoe UI",sans-serif; }
body { margin:0; min-height:100vh; background:radial-gradient(circle at 90% 5%,rgba(236,100,55,.10),transparent 27rem),var(--paper); }
button,input,textarea { font:inherit; }
button { cursor:pointer; }
main { width:min(1040px,calc(100% - 40px)); margin:auto; }
[hidden] { display:none!important; }
.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; }
.eyebrow { margin:0 0 15px; color:var(--orange); font:700 11px/1 Inter,"Segoe UI",sans-serif; letter-spacing:.18em; }
h1,h2 { font-family:Inter,"Segoe UI",sans-serif; letter-spacing:-.055em; }
.auth-view { min-height:100vh; max-width:620px; display:flex; flex-direction:column; justify-content:center; padding:80px 0; }
.brand-mark,.wordmark span { display:grid; place-items:center; background:var(--orange); color:white; font:700 16px/1 Inter,"Segoe UI",sans-serif; border-radius:9px; transform:rotate(-4deg); }
.brand-mark { width:46px; height:46px; margin-bottom:64px; font-size:22px; border-radius:13px; }
.auth-view h1 { margin:0; font-size:clamp(50px,8vw,84px); line-height:.98; }
.intro { max-width:480px; color:var(--muted); font-size:18px; line-height:1.6; }
.auth-view form { display:grid; gap:10px; max-width:420px; margin-top:28px; }
.auth-view input { width:100%; border:1px solid var(--line); border-radius:12px; padding:14px; background:white; }
.primary,.auth-view form button { width:max-content; border:0; border-radius:999px; padding:14px 22px; background:var(--ink); color:white; margin-top:22px; }
.muted { color:var(--muted); }
header { height:90px; display:flex; align-items:center; justify-content:space-between; border-bottom:1px solid var(--line); }
.header-actions { display:flex; gap:8px; }
.wordmark { display:flex; align-items:center; gap:12px; color:var(--ink); text-decoration:none; font:700 18px/1 Inter,"Segoe UI",sans-serif; }
.wordmark span { width:30px; height:30px; }
.quiet { border:1px solid var(--line); background:transparent; color:var(--ink); border-radius:999px; padding:9px 14px; }
.composer { margin-top:48px; background:var(--card); border:1px solid rgba(32,32,30,.08); border-radius:22px; padding:9px; box-shadow:var(--shadow); }
.mode-tabs { display:flex; gap:2px; padding:4px; }
.mode-tabs button { border:0; background:transparent; color:var(--muted); padding:9px 14px; border-radius:9px; }
.mode-tabs button.active { color:var(--ink); background:#ebe6dd; }
#text-compose { display:flex; align-items:flex-end; gap:12px; padding:16px; }
textarea { flex:1; resize:vertical; min-height:56px; max-height:180px; border:0; outline:0; background:transparent; font-size:18px; color:var(--ink); }
.send-button { flex:none; border:0; background:var(--orange); color:white; padding:13px 18px; border-radius:999px; }
.send-button span { margin-left:8px; }
.drop-zone { margin:10px 4px 4px; border:1px dashed #bdb5a8; border-radius:15px; min-height:140px; display:grid; place-items:center; text-align:center; }
.drop-zone input { position:absolute; opacity:0; pointer-events:none; }
.drop-zone label { cursor:pointer; display:grid; gap:8px; padding:35px; }
.drop-zone span { color:var(--muted); font-size:14px; }
.drop-zone.dragging { border-color:var(--orange); background:rgba(236,100,55,.05); }
.inbox-section { padding:70px 0 100px; }
.section-heading { display:flex; justify-content:space-between; align-items:end; margin-bottom:22px; }
.section-heading h2 { margin:0; font-size:30px; }
.storage { color:var(--muted); font-size:13px; }
.inbox { border-top:1px solid var(--line); }
.completed-section { margin-top:34px; }
.completed-section summary { display:flex; justify-content:space-between; padding:14px 6px; border-bottom:1px solid var(--line); color:var(--muted); cursor:pointer; font-weight:600; }
.completed-section .item { opacity:.72; }
.account-status { display:flex; justify-content:space-between; align-items:center; gap:16px; padding:18px 0; border-top:1px solid var(--line); border-bottom:1px solid var(--line); }
.account-status p { margin:0; color:var(--ink); }
.account-status span { color:var(--muted); font-size:12px; }
#owner-controls { display:block; margin-top:24px; }
#invite-actions,#invite-result { margin-top:14px; }
#invite-result { display:block; }
.item { display:grid; grid-template-columns:48px minmax(0,1fr) auto; gap:18px; align-items:center; padding:20px 6px; border-bottom:1px solid var(--line); }
.item-icon { width:44px; height:44px; border:1px solid var(--line); border-radius:12px; display:grid; place-items:center; color:var(--orange); font-weight:600; }
.item-main { min-width:0; }
.item-title { color:var(--ink); text-decoration:none; font-size:16px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; display:block; }
.item-meta { margin:6px 0 0; color:var(--muted); font-size:12px; }
.item-actions { display:flex; gap:7px; }
.item-actions button,.item-actions a { border:0; background:transparent; color:var(--muted); text-decoration:none; padding:8px; border-radius:8px; }
.item-actions :hover { background:#eae4db; color:var(--ink); }
.photo-thumb-button { width:44px; height:44px; padding:0; border:0; border-radius:12px; background:#ddd; overflow:hidden; }
.photo-thumb-button:focus-visible { outline:3px solid rgba(236,100,55,.45); outline-offset:3px; }
.photo-thumb { width:100%; height:100%; display:block; object-fit:cover; }
.empty { padding:55px 0; color:var(--muted); text-align:center; }
.toast { position:fixed; bottom:24px; left:50%; transform:translate(-50%,20px); padding:11px 16px; border-radius:999px; background:var(--ink); color:white; opacity:0; pointer-events:none; transition:.2s; box-shadow:var(--shadow); }
.toast.show { opacity:1; transform:translate(-50%,0); }
dialog { border:0; border-radius:18px; padding:26px; background:var(--card); box-shadow:var(--shadow); }
dialog::backdrop { background:rgba(32,32,30,.3); backdrop-filter:blur(2px); }
dialog h2 { margin:0 0 6px; }
dialog p { color:var(--muted); }
dialog div { display:flex; justify-content:flex-end; gap:8px; margin-top:22px; }
.photo-viewer { width:100%; height:100%; max-width:none; max-height:none; margin:0; padding:0; border-radius:0; overflow:hidden; background:#10100f; color:white; }
.photo-viewer[open] { position:fixed; inset:0; display:flex; flex-direction:column; }
.photo-viewer::backdrop { background:#10100f; }
.photo-viewer .viewer-header { position:absolute; z-index:2; inset:0 0 auto; height:72px; padding:max(14px,env(safe-area-inset-top)) max(18px,env(safe-area-inset-right)) 12px max(18px,env(safe-area-inset-left)); display:flex; align-items:center; justify-content:space-between; border:0; background:linear-gradient(#10100f,rgba(16,16,15,.82)); }
.photo-viewer .viewer-caption { min-width:0; display:grid; justify-content:start; gap:4px; margin:0; }
.viewer-caption strong { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; font-size:14px; }
.viewer-caption span { color:#aaa8a3; font-size:12px; }
.photo-viewer .viewer-actions { display:flex; align-items:center; gap:8px; margin:0; }
.viewer-button { display:grid; place-items:center; min-height:40px; padding:0 14px; border:1px solid #44423e; border-radius:999px; background:#242321; color:white; text-decoration:none; }
#close-viewer { width:40px; padding:0; font-size:25px; }
.photo-viewer .viewer-stage { position:relative; flex:1 1 auto; min-width:0; min-height:0; margin:0; overflow:hidden; touch-action:pan-y; }
.viewer-stage img { position:absolute; inset:12px 64px max(12px,env(safe-area-inset-bottom)); display:block; width:calc(100% - 128px); height:calc(100% - 24px); object-fit:contain; object-position:50% 50%; user-select:none; -webkit-user-drag:none; }
.viewer-arrow { position:absolute; top:50%; translate:0 -50%; width:46px; height:64px; border:0; border-radius:999px; background:rgba(45,44,41,.82); color:white; font-size:38px; line-height:1; }
.viewer-arrow:disabled { opacity:.18; cursor:default; }
.viewer-previous { left:12px; }
.viewer-next { right:12px; }
.danger { border:0; border-radius:999px; background:#b63827; color:white; padding:10px 16px; }
.setup-dialog { width:min(620px,calc(100% - 28px)); max-height:min(760px,calc(100vh - 28px)); overflow:auto; }
.setup-dialog>p.muted { line-height:1.55; }
.dialog-close { position:absolute; top:14px; right:14px; width:34px; height:34px; border:0; border-radius:50%; background:#ebe6dd; color:var(--ink); font-size:22px; }
.key-warning { margin:22px 0 8px; color:#9a3e25; font-size:13px; }
.key-row { display:flex; align-items:center; gap:8px; padding:10px; border-radius:12px; background:#ebe6dd; }
.key-row code { flex:1; min-width:0; overflow-wrap:anywhere; font-size:12px; }
.setup-steps { margin:26px 0; padding-left:22px; color:var(--muted); line-height:1.5; }
.setup-steps li { margin:9px 0; padding-left:5px; }
.setup-steps code { color:var(--ink); overflow-wrap:anywhere; }
.key-list-heading h3 { margin:0 0 8px; font-size:14px; }
.device-key { display:flex; justify-content:space-between; align-items:center; gap:10px; padding:12px 0; border-top:1px solid var(--line); }
.device-key p { margin:0; font-size:14px; }
.device-key span { color:var(--muted); font-size:11px; }
.device-key button { border:0; background:transparent; color:#a43a28; }
@media(max-width:700px){ main{width:min(100% - 28px,1040px)} header{height:74px}.header-actions #sign-out{display:none}.header-actions{gap:4px}.header-actions button{padding:8px 10px}.composer{margin-top:28px;border-radius:17px}.item{grid-template-columns:42px minmax(0,1fr);gap:12px}.item-actions{grid-column:2}.section-heading{align-items:start}.storage{max-width:100px;text-align:right}.auth-view{padding:50px 4px}.brand-mark{margin-bottom:50px}.setup-dialog{padding:24px 20px}.key-row{align-items:stretch;flex-direction:column}.key-row button{align-self:flex-end}.photo-viewer .viewer-header{height:66px}.viewer-stage img{inset:8px;width:calc(100% - 16px);height:calc(100% - 16px)}.viewer-arrow{top:auto;bottom:max(18px,env(safe-area-inset-bottom));width:48px;height:48px;font-size:32px}.viewer-previous{left:18px}.viewer-next{right:18px} }
@media(prefers-reduced-motion:reduce){*{scroll-behavior:auto!important;transition:none!important}}
