/* Me Across Time on the web: the apps' night palette (androidApp ui/Theme.kt). */
:root {
  --bg: #15120E; --raised: #26211B; --line: #3A332B; --ink: #EFE7DA; --muted: #A89E8F;
  --button: #EDE4D5; --gold: #C9A877; --mine: #332A20; --framing: #1E1912; --error: #FF8A80;
  --serif: Georgia, 'EB Garamond', 'Times New Roman', serif;
  --sans: system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; background: var(--bg); color: var(--ink); font-family: var(--sans); font-size: 16px; line-height: 1.45; }
a { color: var(--gold); }
h1, h2, h3 { font-family: var(--serif); font-weight: 400; margin: 0; }
.muted { color: var(--muted); }
.error { color: var(--error); }
.notice { color: var(--gold); }
.hidden { display: none !important; }

/* A page with one of the four photographs behind it, darkened like the apps' (70% unless --dim says). */
.page { min-height: 100vh; min-height: 100dvh; position: relative; display: flex; flex-direction: column; }
.backdrop { background: var(--bg); }
.backdrop::before { content: ''; position: fixed; inset: 0; background: var(--bg-image) center / cover no-repeat; opacity: calc(1 - var(--dim, 0.7)); z-index: 0; }
.backdrop::after { content: ''; position: fixed; inset: 0; z-index: 0;
  background: linear-gradient(to bottom, rgba(21,18,14,.7) 0%, rgba(21,18,14,.25) 35%, rgba(21,18,14,.5) 60%, rgba(21,18,14,.95) 100%); }
.backdrop > * { position: relative; z-index: 1; }

.center { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 32px 16px; gap: 14px; }
.column { width: 100%; max-width: 560px; margin: 0 auto; padding: 24px 16px 40px; display: flex; flex-direction: column; gap: 20px; flex: 1; }
.welcome .logo-large { width: 150px; height: 150px; border-radius: 34px; }
.title { font-size: 44px; }
.heading { font-size: 32px; line-height: 1.2; }
.actions { display: flex; flex-direction: column; align-items: center; gap: 16px; margin-top: 28px; }

.brand { display: flex; align-items: center; justify-content: center; gap: 9px; color: var(--ink); text-decoration: none; font-family: var(--serif); font-size: 18px; }
.brand img { width: 26px; height: 26px; border-radius: 6px; }
.topbar { display: flex; align-items: center; gap: 9px; }
.topbar .brand { justify-content: flex-start; }
.topbar .section { margin-left: auto; color: var(--muted); font-size: 13px; }
.topbar .signout { color: var(--muted); font-size: 13px; text-decoration: none; padding: 6px 0 6px 8px; }
.topbar .signout:hover { color: var(--ink); }

.card { background: rgba(21,18,14,.72); border: 1px solid var(--line); border-radius: 16px; padding: 26px 22px; display: flex; flex-direction: column; gap: 14px; }
.card p { margin: 0; }
.links { font-size: 14px; color: var(--muted); }

label { display: flex; flex-direction: column; gap: 6px; font-size: 14px; color: var(--muted); }
label small { font-size: 12px; }
input, select, textarea { font: inherit; color: var(--ink); background: rgba(21,18,14,.6); border: 1px solid var(--line); border-radius: 10px; padding: 11px 13px; width: 100%; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--ink); }
textarea { resize: none; }

.pill { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 0 30px; border: 0; border-radius: 999px;
  background: var(--button); color: var(--bg); font: 500 16px var(--sans); text-decoration: none; cursor: pointer; }
.pill:disabled { opacity: .45; cursor: default; }
.pill.wide { width: 100%; }
.pill.quiet { background: transparent; color: var(--ink); border: 1px solid var(--line); }
.link { color: var(--muted); background: none; border: 0; font: inherit; cursor: pointer; text-decoration: none; padding: 6px; }
.link:hover { color: var(--ink); }

.spacer { flex: 1; }
.big-name { font-family: var(--serif); font-size: 34px; }
.ages { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; background: rgba(21,18,14,.6); border-radius: 16px; padding: 12px 10px; }
.ages .hint { grid-column: 1 / -1; text-align: center; font-size: 13px; color: var(--muted); }

/* The Time Machine's chat and the chat with Future Me. */
.chat-page { height: 100vh; height: 100dvh; }
.chat-page .column { min-height: 0; padding-bottom: 12px; gap: 12px; }
.messages { flex: 1; overflow-y: auto; display: flex; flex-direction: column; gap: 10px; padding: 4px 2px; }
.bubble { max-width: 85%; padding: 10px 14px; border-radius: 16px; white-space: pre-wrap; word-wrap: break-word; }
.bubble .who { display: block; font-size: 12px; color: var(--muted); margin-bottom: 3px; }
.bubble.theirs { background: var(--raised); align-self: flex-start; border-bottom-left-radius: 4px; }
.bubble.mine { background: var(--mine); align-self: flex-end; border-bottom-right-radius: 4px; }
.bubble.framing { background: var(--framing); border: 1px solid var(--gold); max-width: 100%; align-self: stretch; }
.bubble.framing .who { color: var(--gold); }
.bubble.future { font-family: var(--serif); font-size: 17px; }
.bubble img { display: block; max-width: 220px; border-radius: 10px; margin-top: 6px; }
.processing { color: var(--muted); font-size: 13px; animation: pulse 1.4s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: .35; } }
.composer { display: flex; gap: 2px; align-items: flex-end; background: var(--raised); border-radius: 24px; padding: 4px 4px 4px 6px; }
.composer textarea { flex: 1; min-height: 44px; max-height: 180px; background: transparent; border: 0; padding: 11px 10px; }
.small { font-size: 13px; }
.tiny { font-size: 11px; }
.finish { align-self: center; }

/* Photos. */
.photo-frame { width: 240px; height: 240px; border-radius: 18px; border: 1px solid var(--line); overflow: hidden; background: var(--raised); align-self: center;
  display: flex; align-items: center; justify-content: center; color: var(--muted); font-size: 14px; }
.photo-frame img, .grid img, .portrait img { width: 100%; height: 100%; object-fit: cover; display: block; }
.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.grid .cell { aspect-ratio: 1; border-radius: 12px; border: 1px solid var(--line); overflow: hidden; position: relative; }
.grid .cell button { position: absolute; top: 6px; right: 6px; border: 0; border-radius: 999px; background: rgba(21,18,14,.8); color: var(--error); font-size: 12px; padding: 4px 9px; cursor: pointer; }
.buttons { display: flex; gap: 10px; }
.buttons > * { flex: 1; }
.portrait { width: min(320px, 80vw); aspect-ratio: 1; border-radius: 18px; border: 1px solid var(--line); overflow: hidden; align-self: center; }
.spinner { width: 36px; height: 36px; border-radius: 50%; border: 3px solid var(--line); border-top-color: var(--gold); animation: spin 1s linear infinite; align-self: center; }
@keyframes spin { to { transform: rotate(360deg); } }

/* After onboarding. */
.selves { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; text-align: center; font-size: 15px; }
.selves .face { width: 76px; height: 76px; border-radius: 50%; overflow: hidden; border: 1px solid var(--line); background: var(--raised); margin: 0 auto 6px; }
.selves .face img { width: 100%; height: 100%; object-fit: cover; }
.footer { display: flex; justify-content: space-between; align-items: center; font-size: 13px; color: var(--muted); }
.footer form { margin: 0; }

/* The password strength line (public/js/strength.js), Tarot's meter in the night palette. */
.pw { margin-top: -6px; font-size: 13px; }
.pw[hidden] { display: none; }
.pw-track { display: flex; gap: 5px; margin-bottom: 5px; }
.pw-track span { flex: 1; height: 3px; border-radius: 2px; background: var(--line); }
.pw-label { color: var(--muted); }
.pw[data-score="0"] .pw-track span:nth-child(1) { background: #b4584f; }
.pw[data-score="0"] .pw-label { color: var(--error); }
.pw[data-score="1"] .pw-track span:nth-child(1) { background: #c98a3c; }
.pw[data-score="2"] .pw-track span:nth-child(-n+2) { background: var(--gold); }
.pw[data-score="3"] .pw-track span { background: #7fa86a; }
.pw[data-score="2"] .pw-label, .pw[data-score="3"] .pw-label { color: var(--ink); }

/* The first message page: the future self's portrait, then his message as a messenger shows it. */
.portrait-button { background: none; border: 0; padding: 0; cursor: zoom-in; }
.chat-panel { width: 100%; display: flex; align-items: flex-end; gap: 8px; text-align: left; background: #1C1813; border: 1px solid var(--line); border-radius: 18px; padding: 14px 10px; }
.chat-panel .avatar-img { width: 34px; height: 34px; border-radius: 50%; object-fit: cover; flex: none; cursor: zoom-in; }
.chat-panel .bubble { max-width: none; flex: 1; }
.bubble .time { display: block; text-align: right; font-family: var(--sans); font-size: 11px; color: var(--muted); margin-top: 4px; }
.viewer { position: fixed; inset: 0; z-index: 10; background: rgba(0,0,0,.94); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; padding: 16px; text-align: center; cursor: zoom-out; }
.viewer img { width: 100%; max-width: 900px; max-height: 70vh; object-fit: contain; }

/* ---- Icons, the microphone, small spinners: both looks. ---- */
.icon { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; flex: none; border: 0; border-radius: 50%;
  background: none; color: inherit; cursor: pointer; padding: 0; text-decoration: none; }
.icon:disabled { opacity: .35; cursor: default; }
.icon:not(:disabled):hover { background: rgba(127,110,90,.12); }
.icon.small { width: 32px; height: 32px; }
.icon.small svg { width: 18px; height: 18px; color: var(--muted); }
.icon.back { margin-left: -10px; }
/* The microphone: grey while it connects, red only once it really listens (the apps' rule). */
.mic .square { width: 14px; height: 14px; border-radius: 3px; background: #8E8577; }
.mic.listening .square { background: #E5484D; animation: pulse 1.2s ease-in-out infinite; }
.mini-spinner { display: inline-block; width: 12px; height: 12px; border-radius: 50%; border: 1.5px solid var(--line); border-top-color: var(--muted); animation: spin .9s linear infinite; flex: none; }

/* ---- The Time Machine reopened from More (night). ---- */
.topbar .icon.back { color: var(--ink); }
.topbar span.brand { font-size: 18px; }

/* ---- The temporal link: "establishing connection" (night, full screen). ---- */
.temporal-link { position: fixed; inset: 0; z-index: 50; background: #07080D; color: var(--ink); }
.temporal-link canvas { position: absolute; inset: 0; }
.link-portrait { position: absolute; left: 50%; width: 210px; height: 210px; margin-left: -105px; border-radius: 50%; overflow: hidden;
  border: 1px solid rgba(201,168,119,.7); opacity: 0; }
.link-portrait img { width: 100%; height: 100%; object-fit: cover; display: block; }
.link-portrait .scan { position: absolute; left: 0; right: 0; height: 60px; transform: translateY(-60px);
  background: linear-gradient(to bottom, transparent, rgba(143,180,232,.55)); border-bottom: 2px solid rgba(255,255,255,.9); }
.link-ui { position: relative; height: 100%; max-width: 560px; margin: 0 auto; padding: 18px 22px 24px; display: flex; flex-direction: column; }
.link-brand { display: flex; align-items: center; gap: 9px; font-family: var(--serif); font-size: 18px; }
.link-brand img { width: 26px; height: 26px; border-radius: 6px; }
.log { height: 250px; display: flex; flex-direction: column; justify-content: flex-end; font: 12.5px/18px ui-monospace, Menlo, Consolas, monospace; color: rgba(239,231,218,.8); }
.log .strong { color: var(--gold); letter-spacing: 1.2px; }
.log .lost { color: #E07A5F; letter-spacing: 1.2px; }
.link-actions { min-height: 54px; margin-top: 16px; display: flex; justify-content: center; }

/* ---- The everyday screens: the apps' warm paper (androidApp ui/Theme.kt, Paper). ---- */
body.paper {
  --bg: #F5EFE5; --card: #FCF9F3; --line: #E4DACB; --ink: #1F1B16; --body: #3A332B; --muted: #75695B; --olive: #857A62;
  --bubble: #EAE3D8; --dark: #211C17; --red: #B3261E; --error: #B3261E; --nav-h: 64px;
  color-scheme: light; background: var(--bg); color: var(--ink);
}
body.paper a { color: inherit; }
.paper .shell { min-height: 100vh; min-height: 100dvh; }
.paper .screen { max-width: 640px; margin: 0 auto; padding: 28px 22px 48px; display: flex; flex-direction: column; gap: 18px; }
.paper .row { display: flex; align-items: center; gap: 8px; }
.paper .gap { gap: 12px; }
.paper .grow { flex: 1; min-width: 0; }
.paper .over { font-size: 11px; color: var(--muted); letter-spacing: .04em; }
.paper .title-xl { font-family: var(--serif); font-size: 44px; line-height: 1.1; }
.paper .title-l { font-family: var(--serif); font-size: 36px; line-height: 1.15; }
.paper .title-m { font-family: var(--serif); font-size: 22px; line-height: 1.25; margin: 0; }
.paper .title-s { font-family: var(--serif); font-size: 21px; line-height: 1.25; }
.paper .body { color: var(--body); margin: 0; }
.paper .muted { color: var(--muted); }
.paper .olive { color: var(--olive); }
.paper .one-line { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.paper .center-text { text-align: center; margin-top: 32px; }
.paper section { display: flex; flex-direction: column; gap: 4px; }
.paper hr { border: 0; border-top: 1px solid var(--line); margin: 16px 0 4px; width: 100%; }
.paper .error { color: var(--red); }
.text-button { align-self: flex-start; display: inline-flex; align-items: center; gap: 6px; background: none; border: 0; padding: 8px 2px; font: 500 15px var(--sans);
  color: var(--olive); cursor: pointer; text-decoration: none; border-radius: 8px; }
.text-button:hover { color: var(--ink); }
.text-button:disabled { opacity: .4; cursor: default; }
.text-button svg { width: 18px; height: 18px; }
.text-button.strong { color: var(--ink); font-weight: 600; }
.text-button.danger, .pill.danger { color: var(--red); }
.paper .pill { min-height: 44px; padding: 0 26px; font-size: 15px; align-self: flex-start; }
.paper .pill.dark { background: var(--dark); color: var(--card); }
.paper .pill.outline { background: transparent; color: var(--ink); border: 1px solid var(--line); }
.paper .pill.outline.danger { border-color: var(--red); color: var(--red); }
.avatar { display: inline-block; border-radius: 50%; overflow: hidden; background: #E2D8C6; flex: none; }
.avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* The menu: a bar at the top on a wide screen, the apps' bottom menu on a phone's. */
.tabs { position: sticky; top: 0; z-index: 5; display: flex; align-items: center; gap: 4px; height: var(--nav-h); padding: 0 20px;
  background: var(--bg); border-bottom: 1px solid var(--line); }
.tabs .brand { margin-right: auto; font-size: 18px; color: var(--ink); }
.tab { position: relative; display: flex; align-items: center; gap: 8px; padding: 8px 12px; border-radius: 10px; color: #8E8375; text-decoration: none; font-size: 14px; }
.tab:hover { background: rgba(127,110,90,.08); }
.tab.on { color: var(--ink); font-weight: 600; }
.tab-icon { position: relative; display: inline-flex; }
.tab-icon svg { width: 22px; height: 22px; }
.face { width: 24px; height: 24px; border-radius: 50%; overflow: hidden; display: inline-flex; align-items: center; justify-content: center;
  font-size: 11px; color: var(--ink); background: #E2D8C6; border: .5px solid var(--line); }
.face.future { background: #DDE3EE; }
.tab.on .face { border: 1.5px solid var(--ink); }
.face img { width: 100%; height: 100%; object-fit: cover; }
.dot { position: absolute; top: -2px; right: -3px; width: 10px; height: 10px; border-radius: 50%; background: #E5484D; border: 1.5px solid var(--bg); }
@media (max-width: 759px) {
  body.paper { --nav-h: 0px; }
  .tabs { position: fixed; top: auto; bottom: 0; left: 0; right: 0; height: auto; padding: 8px 0 calc(10px + env(safe-area-inset-bottom)); gap: 0;
    border-bottom: 0; border-top: 1px solid var(--line); }
  .tabs .wide-only { display: none; }
  .tab { flex: 1; flex-direction: column; gap: 4px; padding: 2px 0; font-size: 11px; }
  .tab:hover { background: none; }
  .paper .screen { padding-bottom: 96px; }
  /* The chat is a page of its own on a phone: no menu under it, so the composer sits at the very bottom; Back returns. */
  .in-chat .tabs { display: none; }
  .paper .screen.chat { padding-bottom: 0; }
}

/* Today */
.logo-mark { width: 36px; height: 36px; border-radius: 9px; display: block; }
.selves-row { display: flex; align-items: center; justify-content: space-between; }
.self { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; background: none; border: 0; padding: 0; font: inherit; color: var(--ink); cursor: pointer; text-align: left; }
.self.end { align-items: flex-end; text-align: right; }
.self small { color: var(--muted); font-size: 12px; }
.self .avatar { margin-bottom: 4px; }
.thought { font-family: var(--serif); font-size: 22px; line-height: 1.35; margin: 12px 0 0; }

/* Cards: My Life and My Future */
.cards { display: flex; flex-direction: column; gap: 14px; }
.paper .card { background: var(--card); border: 0; border-radius: 12px; padding: 4px 14px 14px 4px; gap: 8px; display: flex; flex-direction: column; }
.paper .card.post { border-radius: 14px; padding: 16px; gap: 10px; }
.entry-body { padding-left: 10px; display: flex; flex-direction: column; gap: 8px; }
.photo { width: 100%; height: 220px; object-fit: cover; border-radius: 10px; display: block; background: var(--bubble); }
.photo.square { height: auto; aspect-ratio: 1; }
.record { font-family: var(--serif); font-size: 16px; line-height: 1.45; color: var(--body); white-space: pre-wrap; word-wrap: break-word; }
.record.small-record { font-size: 15px; }
.reflection .record { font-size: 14px; }
.record.collapsed { cursor: pointer; }
.record b { font-weight: 700; }
.meta { font-size: 12px; color: var(--muted); }
.empty { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 16px; text-align: center; padding: 48px 8px; }
.empty .title-m { font-size: 26px; }
.empty .pill { align-self: center; }
.menu-wrap { position: relative; }
.popup { position: absolute; top: 34px; left: 0; z-index: 8; min-width: 150px; background: var(--card); border-radius: 10px; padding: 6px 0;
  box-shadow: 0 8px 28px rgba(31,27,22,.18); display: flex; flex-direction: column; }
.popup button { display: flex; align-items: center; gap: 10px; background: none; border: 0; padding: 11px 16px; font: 15px var(--sans); color: var(--ink); cursor: pointer; text-align: left; }
.popup button:hover { background: var(--bubble); }
.popup svg { width: 20px; height: 20px; }
.menu-wrap.up .popup { top: auto; bottom: 48px; }

/* The plan */
.plan-item { display: flex; align-items: flex-start; padding: 6px 0; gap: 0; }
.circle { width: 22px; height: 22px; margin: 2px 12px 0 0; border-radius: 50%; border: 1.5px solid var(--muted); background: none; flex: none;
  display: inline-flex; align-items: center; justify-content: center; padding: 0; cursor: pointer; color: var(--muted); font-size: 13px; }
.circle.done { background: var(--olive); border-color: var(--olive); color: var(--card); }
.circle svg { width: 15px; height: 15px; }
.plan-text { font-size: 15px; line-height: 1.35; color: var(--ink); white-space: pre-wrap; word-wrap: break-word; cursor: pointer; }
.plan-item:not(.open) .plan-text { color: var(--muted); }
.plan-item.dropped .plan-text { text-decoration: line-through; }
/* Two lines at most, the second fading out. */
.plan-text.clamped { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; }
.plan-text.clamped.fades {
  -webkit-mask-image: linear-gradient(to bottom, #000 50%, rgba(0,0,0,.1) 100%); mask-image: linear-gradient(to bottom, #000 50%, rgba(0,0,0,.1) 100%); }
.reflection { margin-top: 10px; background: var(--card); border-radius: 10px; padding: 10px; }
.day { margin: 22px 0 4px; font-size: 12px; color: var(--muted); }
.day.today { color: var(--ink); font-weight: 700; }
.chips { display: flex; gap: 8px; flex-wrap: wrap; }
.chip { align-self: flex-start; display: inline-flex; align-items: center; gap: 6px; height: 34px; padding: 0 14px; border-radius: 8px; border: 1px solid var(--line);
  background: none; font: 500 14px var(--sans); color: var(--body); cursor: pointer; }
.chip.on { background: #E8DFD0; border-color: #E8DFD0; color: var(--ink); }
.chip svg { width: 16px; height: 16px; }

/* The chat with Future Me */
.paper .screen.chat { max-width: 720px; height: calc(100vh - var(--nav-h)); height: calc(100dvh - var(--nav-h)); padding-top: 12px; padding-bottom: 8px; gap: 0; }
.chat-screen { flex: 1; min-height: 0; display: flex; flex-direction: column; }
.chat-head .avatar { margin-left: -4px; }
.messages-p { flex: 1; min-height: 0; overflow-y: auto; display: flex; flex-direction: column; gap: 10px; padding: 16px 2px; }
.msg { display: flex; flex-direction: column; align-items: flex-start; }
.msg.mine { align-items: flex-end; }
.msg-row { display: flex; align-items: flex-end; gap: 6px; max-width: min(85%, 460px); }
.msg-row .mini-spinner { margin-bottom: 4px; }
.bubble-p { background: var(--card); border-radius: 16px 16px 16px 4px; padding: 10px 14px; min-width: 0; }
.bubble-p.mine { background: var(--bubble); border-radius: 16px 16px 4px 16px; }
.bubble-p .who { font-size: 12px; color: var(--muted); }
.msg-text { font-family: var(--serif); font-size: 17px; line-height: 1.4; color: var(--body); white-space: pre-wrap; word-wrap: break-word; }
.attached { display: block; width: 100%; max-width: 300px; height: 180px; object-fit: cover; border-radius: 8px; margin: 4px 0; }
.not-sent { font-size: 12px; color: var(--muted); }
.link-inline { background: none; border: 0; font: 600 12px var(--sans); color: var(--ink); cursor: pointer; padding: 4px 6px; }
.dots { display: flex; gap: 5px; margin-top: 6px; }
.dots i { width: 7px; height: 7px; border-radius: 50%; background: var(--muted); opacity: .35; animation: dot 1.2s linear infinite; }
.dots i:nth-child(2) { animation-delay: .4s; }
.dots i:nth-child(3) { animation-delay: .8s; }
@keyframes dot { 0%, 33% { opacity: .9; } 34%, 100% { opacity: .35; } }
.thumbs { display: flex; gap: 8px; padding-bottom: 8px; }
.thumb, .photo-edit { position: relative; }
.thumb img { width: 64px; height: 64px; object-fit: cover; border-radius: 10px; display: block; }
.x { position: absolute; top: 3px; right: 3px; width: 22px; height: 22px; border-radius: 50%; border: 0; padding: 0; cursor: pointer;
  background: rgba(31,27,22,.7); color: var(--card); display: flex; align-items: center; justify-content: center; }
.x svg { width: 14px; height: 14px; }
.photo-edit img { width: 100%; height: 220px; object-fit: cover; border-radius: 12px; display: block; }
.photo-edit .x { top: 8px; right: 8px; width: 30px; height: 30px; }
.photo-edit .x svg { width: 18px; height: 18px; }
.composer-p { display: flex; align-items: flex-end; background: var(--card); border-radius: 24px; padding: 2px; }
.composer-p textarea, .field-mic textarea { flex: 1; min-height: 44px; max-height: 180px; border: 0; background: transparent; color: var(--ink); padding: 11px 6px; }
.composer-p textarea:focus { border: 0; }
.composer-p .icon { color: var(--muted); }
.composer-p .send { color: var(--ink); }
.suggestion { display: flex; align-items: center; gap: 8px; width: 100%; margin-top: 8px; padding: 10px 12px; border: 0; border-radius: 10px;
  background: rgba(133,122,98,.10); font: inherit; color: var(--ink); text-align: left; cursor: pointer; }
.suggestion .grow { display: flex; flex-direction: column; }
.suggestion .one-line { font-size: 15px; }
.suggestion > .olive { font-size: 22px; }

/* My Future */
.year { font-family: var(--serif); font-size: 28px; }

/* More and Account */
.menu { display: flex; flex-direction: column; }
.menu-row { display: flex; align-items: center; gap: 8px; padding: 16px 0; border-bottom: 1px solid var(--line); text-decoration: none; }
.menu-row:last-child { border-bottom: 0; }
.menu-row .grow { display: flex; flex-direction: column; }
.menu-row .title-s { font-size: 22px; }
.chev { font-size: 24px; }

/* Sheets: a bottom sheet on a phone, a dialog on a wide screen. */
.overlay { position: fixed; inset: 0; z-index: 20; background: rgba(31,27,22,.4); display: flex; align-items: center; justify-content: center; padding: 16px; }
.sheet { width: 100%; max-width: 520px; max-height: calc(100dvh - 32px); overflow-y: auto; background: var(--bg); border-radius: 20px; padding: 22px;
  display: flex; flex-direction: column; gap: 14px; box-shadow: 0 18px 60px rgba(31,27,22,.25); }
.sheet .title-l { font-size: 28px; }
.sheet textarea[data-field="plan"] { background: var(--card); border-color: var(--line); color: var(--ink); }
.field-mic { display: flex; align-items: flex-start; border: 1px solid var(--line); border-radius: 10px; background: var(--card); padding-right: 2px; }
.field-mic textarea { padding: 11px 13px; min-height: 110px; max-height: 360px; }
.field-mic:focus-within { border-color: var(--ink); }
.date-line { position: relative; align-self: flex-start; flex-direction: row; align-items: center; gap: 8px; height: 40px; padding: 0 16px;
  border: 1px solid var(--line); border-radius: 999px; color: var(--ink); font-size: 14px; cursor: pointer; }
.date-line svg { width: 18px; height: 18px; }
.date-line input { position: absolute; inset: 0; opacity: 0; cursor: pointer; padding: 0; border: 0; }
.actions-row { padding-top: 4px; }
.profile-photo { width: 200px; height: 200px; object-fit: cover; border-radius: 12px; }
.clamp4 { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 4; overflow: hidden; }
@media (max-width: 759px) {
  .overlay { align-items: flex-end; padding: 0; }
  .sheet { max-width: none; border-radius: 20px 20px 0 0; max-height: 92dvh; padding-bottom: calc(22px + env(safe-area-inset-bottom)); }
}
html.paper-html { background: #F5EFE5; }

.feed-title { font-size: 30px; }
.attached { width: min(280px, 62vw); }
@media (max-width: 759px) {
  .tab > span:last-child { max-width: 100%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; padding: 0 2px; }
  .feed-title { font-size: 26px; }
}

/* Imported posts: the network's badge, the profile, "Imported from …" (the apps' SourceBadge). */
.source-head { display: flex; align-items: center; gap: 10px; }
.source-profile { font-size: 14px; font-weight: 600; color: var(--ink); }
.source-head .over { letter-spacing: 0; }
.source-badge { width: 34px; height: 34px; border-radius: 8px; flex: none; display: inline-flex; align-items: center; justify-content: center;
  color: #fff; font: 700 16px/1 system-ui, -apple-system, 'Segoe UI', sans-serif; }
.source-badge.src-linkedin { background: #0A66C2; }
.source-badge.src-facebook { background: #1877F2; font-size: 22px; align-items: flex-end; padding-bottom: 1px; }
.source-badge.src-instagram { background: linear-gradient(45deg, #FEDA75, #FA7E1E 30%, #D62976 55%, #962FBF 80%, #4F5BD5); }
.source-badge.src-x { background: #000; }

/* Today (concept A2): the future band, the plan, you today. */
.paper .screen.today { padding: 0 0 48px; gap: 0; }
.future-band { position: relative; padding: 20px 22px; display: flex; flex-direction: column; gap: 10px; color: #EFE7DA;
  background: linear-gradient(to bottom, rgba(21,18,14,.63), rgba(21,18,14,.95)), var(--band-image) center / cover no-repeat, #15120E; }
@media (min-width: 760px) { .future-band { border-radius: 0 0 18px 18px; } }
.future-band a { color: #A89E8F; text-decoration: none; }
.future-band .gold-link, .future-band .gold { color: #C9A877; }
.future-band .text-button { padding-left: 0; }
.band-name { font-family: var(--serif); font-size: 19px; }
.band-date { font-size: 11px; letter-spacing: .06em; color: #C9A877; }
.band-text { margin: 0; font-family: var(--serif); font-size: 18px; line-height: 1.4; }
.band-head { display: flex; align-items: center; gap: 8px; font-size: 12px; color: #A89E8F; }
.band-head .source-badge { width: 20px; height: 20px; border-radius: 5px; font-size: 11px; }
.band-head.gold { font-size: 11px; letter-spacing: .04em; }
.band-post { display: flex; gap: 14px; align-items: flex-start; }
.band-post .grow { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.band-thumb { flex: none; margin-top: 4px; width: 92px; height: 92px; border-radius: 10px; overflow: hidden; border: 1px solid rgba(201,168,119,.6); }
.band-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.band-title { margin: 0; font-family: var(--serif); font-weight: 400; font-size: 21px; }
.future-band a.band-body { font-family: var(--serif); font-size: 15px; line-height: 1.45; color: rgba(239,231,218,.85); }
.band-links { display: flex; gap: 18px; font-size: 14px; padding-top: 2px; }
.band-links .gold-link { font-weight: 600; }
.unread-line { display: flex; align-items: center; gap: 6px; font-size: 13px; }
.red-dot { width: 8px; height: 8px; border-radius: 50%; background: #E5484D; }
.clamp3, .clamp4 { display: -webkit-box; -webkit-box-orient: vertical; overflow: hidden; }
.clamp3 { -webkit-line-clamp: 3; } .clamp4 { -webkit-line-clamp: 4; }
.self-mini { background: none; border: 0; padding: 0; cursor: pointer; display: inline-flex; }
.avatar.gold-ring { border: 1px solid #C9A877; }
.today-plan { padding: 14px 22px 10px; border-bottom: 1px solid var(--line); }
.you-today { padding: 14px 22px; gap: 10px !important; }
.idea-card { display: flex; flex-direction: column; gap: 5px; margin-top: 8px; padding: 10px 12px; border-radius: 12px; background: var(--card); border: 1px solid var(--line); }
.idea-card .over { color: var(--olive); font-size: 10px; }
.idea-title { font-family: var(--serif); font-size: 16px; line-height: 1.3; }
.idea-why { font-family: var(--serif); font-style: italic; font-size: 13px; color: var(--body); }
.idea-card .small-pill { height: 30px; padding: 0 12px; font-size: 13px; }
/* Practices (app.js practicesZone / sheetPracticeCard / viewPractice …), the concept of 29 Nov 2026 */
.p-icon { width: 14px; height: 14px; flex: none; color: var(--olive); vertical-align: -2px; }
.practices-zone { display: flex; flex-direction: column; gap: 6px; padding: 4px 0 6px; box-sizing: border-box; }
.practices-zone.line { padding: 8px 22px; }
.p-line { display: flex; align-items: center; gap: 8px; height: 40px; padding: 0 12px; border: 1px solid var(--line); border-radius: 12px; font-size: 13px; color: var(--body); text-decoration: none; }
.p-tabs { display: flex; align-items: center; gap: 6px; padding-left: 22px; height: 28px; flex: none; }
.p-tabs-row { flex: 1; min-width: 0; display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; }
.p-tabs-row::-webkit-scrollbar { display: none; }
.p-tab { flex: none; height: 28px; padding: 0 11px; border-radius: 14px; border: 1px solid var(--line); background: transparent; font: 12px var(--sans); color: var(--body); cursor: pointer; white-space: nowrap; }
.p-tab.on { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.p-all { flex: none; width: 36px; height: 28px; margin-right: 14px; border-radius: 8px; border: 1px solid var(--line); background: var(--card); display: flex; align-items: center; justify-content: center; cursor: pointer; color: var(--ink); }
.p-all svg { width: 16px; height: 16px; }
.p-card { margin: 0 22px; flex: 1; min-height: 0; display: flex; flex-direction: column; gap: 4px; padding: 8px 14px; border-radius: 14px; background: var(--card); border: 1px solid var(--line); overflow: hidden; cursor: pointer; }
.p-card.discover { border-style: dashed; cursor: default; }
.p-card.page { margin: 10px 0 0; flex: none; gap: 6px; padding: 12px 14px; cursor: default; }
.p-card.page.first { border-color: var(--olive); }
.p-card .over { font-size: 10px; letter-spacing: .08em; color: var(--muted); }
.p-title { font-family: var(--serif); font-size: 16px; line-height: 1.3; flex: 1; min-height: 0; overflow: hidden; }
.p-title.big { font-size: 18px; flex: none; }
.clamp2 { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.italic { font-family: var(--serif); font-style: italic; }
.skeleton { height: 10px; width: 80%; border-radius: 5px; background: var(--bubble); }
.skeleton.short { width: 55%; }
.p-card .small-pill, .sheet .small-pill { height: 28px; padding: 0 10px; font-size: 12px; min-height: 0; }
.p-open-title { font-family: var(--serif); font-weight: 400; font-size: 23px; line-height: 1.28; margin: 4px 0 0; }
.serif { font-family: var(--serif); }
.p-row { width: 100%; background: none; border: 0; text-align: left; font: inherit; color: var(--ink); cursor: pointer; padding: 10px; border-radius: 10px; }
.p-row.on { background: var(--card); }
.p-row .grow { display: flex; flex-direction: column; }
.prompt { display: block; width: 100%; text-align: left; margin-top: 6px; padding: 8px 12px; border: 1px solid var(--line); border-radius: 10px; background: none; font: 14px var(--serif); color: var(--body); cursor: pointer; }
.menu-over { padding: 18px 0 2px; font-size: 11px; letter-spacing: .08em; color: var(--muted); }
.practice-offer { flex-direction: column; align-items: stretch; gap: 4px; cursor: default; }
.practice-offer .small-pill { height: 30px; padding: 0 12px; font-size: 13px; }
.practice-row { cursor: pointer; flex-direction: row; align-items: center; gap: 12px; color: var(--ink); font-size: 16px; }
.practice-icon .p-icon { width: 22px; height: 22px; }
.switch { width: 22px; height: 22px; accent-color: var(--olive); }
.plan-intro { margin: 4px 0; font-size: 14px; color: var(--body); }
.recent { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 12px; background: var(--card); text-decoration: none; }
.recent img { width: 46px; height: 46px; border-radius: 8px; object-fit: cover; flex: none; }
.recent .grow { display: flex; flex-direction: column; gap: 3px; }
.recent-text { font-family: var(--serif); font-size: 14.5px; line-height: 1.4; color: var(--body); display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; }
.ask-field { display: flex; align-items: center; gap: 10px; height: 48px; padding: 0 16px; border: 0; border-radius: 24px; background: var(--card);
  font: 15px var(--sans); color: var(--muted); cursor: pointer; text-align: left; }
.ask-field svg { width: 20px; height: 20px; }
.today-date { font-size: 12px; font-weight: 600; letter-spacing: .04em; color: var(--ink); }

/* ---- The admin console (Controllers\Admin): plain and dense, on the site's dark ground. ---- */
.admin { min-height: 100vh; }
.admin a { color: var(--ink); }
.admin .muted { color: var(--muted); }
.admin-bar { display: flex; align-items: center; gap: 24px; padding: 14px 16px; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.admin-brand { font-weight: 600; text-decoration: none; }
.admin-bar nav { display: flex; gap: 14px; flex: 1; }
.admin-bar nav a, .admin-out { color: var(--muted) !important; text-decoration: none; font-size: 15px; }
.admin-bar nav a.on { color: var(--ink) !important; }
.admin-main { max-width: 1200px; margin: 0 auto; padding: 20px 16px 48px; }
.admin-title { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.admin h1 { font-size: 26px; margin: 8px 0; }
.admin h2 { font-size: 18px; margin: 28px 0 10px; }
.admin-periods { display: flex; gap: 4px; background: var(--raised); border-radius: 10px; padding: 3px; }
.admin-periods a { padding: 6px 12px; border-radius: 8px; text-decoration: none; font-size: 14px; color: var(--muted) !important; }
.admin-periods a.on { background: var(--line); color: var(--ink) !important; }
.admin-tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 10px; margin: 16px 0 20px; }
.admin-tiles div { background: var(--raised); border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; display: flex; flex-direction: column; gap: 2px; }
.admin-tiles span, .admin-tiles small { color: var(--muted); font-size: 13px; }
.admin-tiles b { font-size: 22px; font-variant-numeric: tabular-nums; }
.admin-scroll { overflow-x: auto; border: 1px solid var(--line); border-radius: 12px; }
.admin-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.admin-table th { text-align: left; font-weight: 500; color: var(--muted); background: var(--raised); position: sticky; top: 0; }
.admin-table th, .admin-table td { padding: 8px 12px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.admin-table tr:last-child td { border-bottom: 0; }
.admin-table .n { text-align: right; font-variant-numeric: tabular-nums; }
.admin-table .strong { font-weight: 600; }
.admin .ok { color: #7fb77e; }
.admin .tag { font-style: normal; font-size: 11px; padding: 1px 6px; border-radius: 6px; background: var(--line); color: var(--muted); margin-left: 4px; }
.admin-tabs { display: flex; gap: 4px; flex-wrap: wrap; border-bottom: 1px solid var(--line); margin: 14px 0 18px; }
.admin-tabs a { padding: 8px 14px; text-decoration: none; color: var(--muted) !important; border-bottom: 2px solid transparent; margin-bottom: -1px; }
.admin-tabs a.on { color: var(--ink) !important; border-bottom-color: var(--ink); }
.admin-tabs small { color: var(--muted); margin-left: 4px; }
.admin-chat, .admin-feed { display: flex; flex-direction: column; gap: 12px; max-width: 760px; }
.admin-msg, .admin-post { background: var(--raised); border: 1px solid var(--line); border-radius: 12px; padding: 10px 14px; max-width: 88%; }
.admin-post { max-width: 100%; }
.admin-msg.mine { align-self: flex-end; background: var(--line); }
.admin-msg p.muted, .admin-post p.muted { font-size: 12px; margin: 0 0 6px; overflow-wrap: anywhere; }
.admin-msg code { font-size: 11px; }
.admin-post h3 { margin: 0 0 8px; font-size: 17px; }
.admin-text { line-height: 1.5; overflow-wrap: anywhere; }
.admin-msg img, .admin-post img { display: block; max-width: 100%; max-height: 420px; border-radius: 8px; margin: 4px 0 8px; }
.admin-action { font-size: 14px; margin: 8px 0 0; padding-top: 8px; border-top: 1px solid var(--line); }

/* ---- /privacy/ and /support/ (Controllers\Privacy, Support): a plain readable page. ---- */
.doc { max-width: 720px; margin: 0 auto; padding: 24px 16px 64px; }
.doc a { color: var(--ink); }
.doc h1 { font-family: var(--serif); font-size: 32px; margin: 16px 0 4px; }
.doc h2 { font-size: 19px; margin: 28px 0 8px; }
.doc p, .doc li { color: var(--ink); line-height: 1.55; }
.doc ul { padding-left: 20px; }
.doc .muted, .doc-brand { color: var(--muted); }
.doc-brand a { color: var(--muted); }
.doc hr { border: 0; border-top: 1px solid var(--line); margin: 48px 0 16px; }

/* "Continue with Google / Apple" at the top of the sign-in and sign-up forms (Auth/_external.htm). */
.external { display: flex; flex-direction: column; align-items: center; gap: 12px; margin: 4px 0; }
.external .g_id_signin { min-height: 44px; }
.external .pill.apple { width: 300px; max-width: 100%; min-height: 44px; gap: 8px; background: #fff; color: #000; }
.external .or { margin: 4px 0 0; font-size: 13px; }

/* The public home page (Root/default.htm): hero, what the app does, screenshots, footer. */
.lang-switch { position: absolute; top: 14px; right: 16px; z-index: 2; display: flex; gap: 2px; padding: 3px; border: 1px solid var(--line); border-radius: 999px; background: rgba(21,18,14,.6); font-size: 13px; }
.lang-switch a { padding: 5px 11px; border-radius: 999px; color: var(--muted); text-decoration: none; letter-spacing: .04em; }
.lang-switch a:hover { color: var(--ink); }
.lang-switch a[aria-current] { background: var(--ink); color: var(--bg); }
.landing .hero { min-height: min(92vh, 900px); min-height: min(92dvh, 900px); }
.landing .lead { font-family: var(--serif); font-size: 22px; margin: 0; }
.intro { max-width: 560px; color: var(--ink); opacity: .88; margin: 6px 0 0; }
.features { width: 100%; max-width: 980px; margin: 0 auto; padding: 24px 16px; display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px; }
.feature { background: rgba(21,18,14,.72); border: 1px solid var(--line); border-radius: 16px; padding: 22px 20px; }
.feature h2 { font-size: 22px; color: var(--gold); margin-bottom: 8px; }
.feature p { margin: 0; color: var(--ink); opacity: .88; }
.shots { width: 100%; max-width: 980px; margin: 0 auto; padding: 16px; display: flex; gap: 16px; justify-content: center; overflow-x: auto; }
.shots img { width: 260px; max-width: 75vw; flex: 0 0 auto; border-radius: 18px; border: 1px solid var(--line); }
.note { max-width: 620px; margin: 0 auto; padding: 24px 16px 8px; text-align: center; color: var(--muted); display: flex; flex-direction: column; align-items: center; gap: 18px; }
.note p { margin: 0; }
.site-footer { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 22px; padding: 36px 16px 28px; font-size: 14px; color: var(--muted); }
.site-footer a { color: var(--muted); }
.site-footer a:hover { color: var(--ink); }
.stores { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px; margin-top: 18px; }
.store { display: inline-flex; align-items: center; gap: 12px; min-width: 200px; padding: 12px 24px; border: 1px solid var(--line); border-radius: 16px;
  background: rgba(21,18,14,.75); color: var(--ink); text-decoration: none; text-align: left; }
.store:hover { border-color: var(--ink); }
.store svg { width: 28px; height: 28px; flex: 0 0 auto; }
.store span { display: flex; flex-direction: column; font-size: 20px; font-weight: 500; line-height: 1.15; }
.store small { font-size: 12px; font-weight: 400; color: var(--muted); }
