/* Fonts are bundled locally because Google Fonts is often unreachable from Iran. Persian uses Vazirmatn; the English font is set by --font-en below. */
@font-face { font-family: "Vazirmatn"; font-weight: 400; font-display: swap; src: url(fonts/vazirmatn-arabic-400-normal.woff2) format("woff2"); unicode-range: U+0600-06FF, U+200C-200E, U+FB50-FDFF, U+FE70-FEFF; }
@font-face { font-family: "Vazirmatn"; font-weight: 500; font-display: swap; src: url(fonts/vazirmatn-arabic-500-normal.woff2) format("woff2"); unicode-range: U+0600-06FF, U+200C-200E, U+FB50-FDFF, U+FE70-FEFF; }
@font-face { font-family: "Vazirmatn"; font-weight: 700; font-display: swap; src: url(fonts/vazirmatn-arabic-700-normal.woff2) format("woff2"); unicode-range: U+0600-06FF, U+200C-200E, U+FB50-FDFF, U+FE70-FEFF; }
@font-face { font-family: "Vazirmatn"; font-weight: 800; font-display: swap; src: url(fonts/vazirmatn-arabic-800-normal.woff2) format("woff2"); unicode-range: U+0600-06FF, U+200C-200E, U+FB50-FDFF, U+FE70-FEFF; }
@font-face { font-family: "Vazirmatn"; font-weight: 400; font-display: swap; src: url(fonts/vazirmatn-latin-400-normal.woff2) format("woff2"); unicode-range: U+0000-00FF, U+2013-2022; }
@font-face { font-family: "Vazirmatn"; font-weight: 500; font-display: swap; src: url(fonts/vazirmatn-latin-500-normal.woff2) format("woff2"); unicode-range: U+0000-00FF, U+2013-2022; }
@font-face { font-family: "Vazirmatn"; font-weight: 700; font-display: swap; src: url(fonts/vazirmatn-latin-700-normal.woff2) format("woff2"); unicode-range: U+0000-00FF, U+2013-2022; }
@font-face { font-family: "Vazirmatn"; font-weight: 800; font-display: swap; src: url(fonts/vazirmatn-latin-800-normal.woff2) format("woff2"); unicode-range: U+0000-00FF, U+2013-2022; }
@font-face { font-family: "Plus Jakarta Sans"; font-weight: 400; font-display: swap; src: url(fonts/plus-jakarta-sans-latin-400-normal.woff2) format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Plus Jakarta Sans"; font-weight: 500; font-display: swap; src: url(fonts/plus-jakarta-sans-latin-500-normal.woff2) format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Plus Jakarta Sans"; font-weight: 700; font-display: swap; src: url(fonts/plus-jakarta-sans-latin-700-normal.woff2) format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Plus Jakarta Sans"; font-weight: 800; font-display: swap; src: url(fonts/plus-jakarta-sans-latin-800-normal.woff2) format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }

/* Colours sampled from the Figma design screens. */
:root {
  --bg: #FDFAF6;
  --surface: #FFFFFF;
  --surface-2: #FBF0E6;
  --peach: #F9EBDB;
  --text: #3B2A20;
  --muted: #7D6B5E;
  --line: #EFE5DA;
  --primary: #C96A2E;
  --primary-text: #D06A1C;
  --teal: #6FB3A6;
  --danger: #D64545;
  --grad: linear-gradient(100deg, #C66B3B 0%, #9C8862 50%, #6FB3A6 100%);
  --grad-tile: linear-gradient(135deg, #C66B3B 0%, #6FB3A6 100%);
  --hero: linear-gradient(250deg, #F9F1D2 0%, #E8F4F8 55%, #DDF1F2 100%);
  --shadow: 0 4px 18px rgba(90, 60, 30, .06);
  --radius: 24px;
  --nav-h: 68px;
  --font-en: "Plus Jakarta Sans";
  --on-primary: #fff;
  color-scheme: light;
}
/* Colour themes picked in Profile > Settings (orange is the default above). */
:root[data-accent="pink"] { --bg: #FFF9FB; --surface-2: #FCEFF4; --peach: #FCE4EE; --line: #F3E1E8; --primary: #D6517D; --primary-text: #C23F6C; --teal: #E58FB0; --grad: linear-gradient(100deg, #C2416E 0%, #E0739B 100%); --grad-tile: linear-gradient(135deg, #C2416E 0%, #EE9DBA 100%); --hero: linear-gradient(250deg, #FDE7EF 0%, #FFF3F7 55%, #F6E9FA 100%); }
:root[data-accent="blue"] { --bg: #F8FBFE; --surface-2: #EEF4FC; --peach: #E2EDFB; --line: #E0E8F2; --primary: #2F6FD0; --primary-text: #2563C4; --teal: #4FA3D9; --grad: linear-gradient(100deg, #2C63C4 0%, #4FA3D9 100%); --grad-tile: linear-gradient(135deg, #2C63C4 0%, #6CC0E6 100%); --hero: linear-gradient(250deg, #E3EEFB 0%, #EEF7FC 55%, #E8EEFF 100%); }
:root[data-accent="green"] { --bg: #F8FCF9; --surface-2: #EEF7F1; --peach: #E1F2E7; --line: #DEECE3; --primary: #2E8B57; --primary-text: #23794A; --teal: #5DB38A; --grad: linear-gradient(100deg, #26784B 0%, #5DB38A 100%); --grad-tile: linear-gradient(135deg, #26784B 0%, #7CCB9F 100%); --hero: linear-gradient(250deg, #E8F5E3 0%, #F1F9EE 55%, #E2F3EE 100%); }
:root[data-accent="yellow"] { --bg: #FFFCF3; --surface-2: #FCF6E3; --peach: #FBF0D2; --line: #F1E7CB; --primary: #D9A21B; --primary-text: #9A6F00; --teal: #E8C14A; --grad: linear-gradient(100deg, #F0B92A 0%, #F7D864 100%); --grad-tile: linear-gradient(135deg, #EFB421 0%, #F8DC6E 100%); --hero: linear-gradient(250deg, #FBF0C9 0%, #FFF8E2 55%, #F6F0D4 100%); --on-primary: #3B2A20; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #141414; --surface: #1F1F1F; --surface-2: #2A2A2A; --peach: #33302D; --text: #F7F4F1; --muted: #C2BAB3;
    --line: #363636; --primary: #E08A52; --primary-text: #F09A5C; --teal: #7CC4B6;
    --hero: linear-gradient(250deg, #3A3322 0%, #1F3036 55%, #1C3433 100%);
    --shadow: 0 4px 18px rgba(0,0,0,.35); color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #141414; --surface: #1F1F1F; --surface-2: #2A2A2A; --peach: #33302D; --text: #F7F4F1; --muted: #C2BAB3;
  --line: #363636; --primary: #E08A52; --primary-text: #F09A5C; --teal: #7CC4B6;
  --hero: linear-gradient(250deg, #3A3322 0%, #1F3036 55%, #1C3433 100%);
  --shadow: 0 4px 18px rgba(0,0,0,.35); color-scheme: dark;
}

/* Colour themes in dark mode: keep the dark surfaces, brighten the accent. */
:root[data-theme="dark"][data-accent="pink"] { --primary: #F07FA6; --primary-text: #F58DB1; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"])[data-accent="pink"] { --primary: #F07FA6; --primary-text: #F58DB1; } }
:root[data-theme="dark"][data-accent="blue"] { --primary: #6FA8F0; --primary-text: #82B5F5; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"])[data-accent="blue"] { --primary: #6FA8F0; --primary-text: #82B5F5; } }
:root[data-theme="dark"][data-accent="green"] { --primary: #6CC596; --primary-text: #7DD1A5; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"])[data-accent="green"] { --primary: #6CC596; --primary-text: #7DD1A5; } }
:root[data-theme="dark"][data-accent="yellow"] { --primary: #F2C230; --primary-text: #F5CC4A; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"])[data-accent="yellow"] { --primary: #F2C230; --primary-text: #F5CC4A; } }

/* Text size chosen by the user in Profile > Settings; most sizes are in rem so they scale. */
:root[data-text-size="sm"] { font-size: 90%; }
:root[data-text-size="lg"] { font-size: 112.5%; }
:root[data-text-size="xl"] { font-size: 125%; }

* { box-sizing: border-box; }
html, body { margin: 0; }
/* Keep the page locked to the phone's width: no sideways panning, no double-tap zoom, no automatic text enlarging. */
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; touch-action: manipulation; overflow-x: clip; }
body { overflow-x: clip; max-width: 100vw; }
input, select, textarea { font-size: max(16px, 1em); }
body {
  font-family: Vazirmatn, Tahoma, system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
  padding-bottom: calc(var(--nav-h) + 12px + env(safe-area-inset-bottom));
}
html[lang="en"] body { font-family: var(--font-en), Vazirmatn, system-ui, sans-serif; }
button, input, select, textarea { font: inherit; color: inherit; }
a { color: inherit; text-decoration: none; }
h1, h2, h3 { line-height: 1.45; margin: 0; }
.ic { width: 22px; height: 22px; flex: none; stroke: currentColor; fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.ic.sm { width: 18px; height: 18px; }
html[dir="ltr"] .flip { transform: scaleX(-1); }

/* Header */
.topbar {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; gap: 12px;
  padding: 12px 16px;
  background: color-mix(in srgb, var(--bg) 90%, transparent);
  backdrop-filter: blur(12px);
}
.brand { display: flex; align-items: center; gap: 12px; }
.logo-tile { display: grid; place-items: center; width: 52px; height: 52px; border-radius: 16px; background: var(--grad-tile); color: var(--on-primary); box-shadow: 0 6px 16px rgba(110, 120, 100, .25); transform: rotate(-4deg); }
.logo-tile .ic { width: 26px; height: 26px; stroke-width: 2; }
.brand-text b { display: block; font-size: 1.3rem; font-weight: 800; line-height: 1.2; }
.brand-text span { font-size: .8rem; color: var(--muted); }
.top-actions { display: flex; gap: 10px; margin-inline-start: auto; }
.pill-btn { display: inline-flex; align-items: center; gap: 6px; height: 48px; padding: 0 14px; border-radius: 16px; border: 1px solid var(--line); background: var(--surface); cursor: pointer; color: var(--primary-text); font-weight: 800; }
.pill-btn.square { width: 48px; padding: 0; justify-content: center; color: var(--text); position: relative; }
.pill-btn .dot { position: absolute; top: 11px; inset-inline-end: 12px; width: 7px; height: 7px; border-radius: 50%; background: var(--danger); border: 2px solid var(--surface); }
.topnav { display: none; gap: 4px; margin-inline-start: 24px; }
.topnav a { display: inline-flex; align-items: center; gap: 6px; padding: 9px 16px; border-radius: 14px; color: var(--muted); font-weight: 500; }
.topnav a.active { background: var(--surface-2); color: var(--primary-text); font-weight: 700; }

/* Bottom tab bar */
.bottomnav {
  position: fixed; inset-inline: 14px; bottom: calc(6px + env(safe-area-inset-bottom)); z-index: 20;
  display: flex; justify-content: space-between; align-items: center; gap: 4px;
  padding: 8px; border-radius: 28px;
  background: var(--surface); border: 1px solid var(--line);
  box-shadow: 0 12px 32px rgba(90, 60, 30, .16);
}
.bottomnav a { flex: 1 1 0; display: flex; align-items: center; justify-content: center; gap: 6px; padding: 10px 12px; border-radius: 20px; font-size: .8rem; white-space: nowrap; min-width: 0; font-weight: 500; color: var(--muted); }
.bottomnav a .ic { width: 24px; height: 24px; }
/* Only the open tab shows its name; the others keep it for screen readers. */
.bottomnav a:not(.active) > span:last-child { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.bottomnav .ic-wrap { position: relative; display: grid; }
@media (max-width: 359px) { .bottomnav { inset-inline: 8px; padding: 6px; gap: 2px; } .bottomnav a.active { padding-inline: 10px; } }
.bottomnav .count, .count { position: absolute; top: -6px; inset-inline-end: -10px; min-width: 16px; height: 16px; padding: 0 4px; border-radius: 99px; background: var(--danger); color: #fff; font-size: .65rem; font-weight: 800; line-height: 16px; text-align: center; border: 2px solid var(--surface); box-sizing: content-box; }
.count.inline { position: static; display: inline-block; margin-inline-start: 4px; border: 0; }
.bottomnav a.active { flex: 0 0 auto; padding-inline: 14px; background: var(--grad); color: var(--on-primary); font-weight: 700; }

.fab {
  position: fixed; z-index: 21; inset-inline-start: 16px; bottom: calc(var(--nav-h) + 20px + env(safe-area-inset-bottom));
  display: grid; place-items: center; width: 56px; height: 56px; border-radius: 18px; border: 0; cursor: pointer;
  background: var(--grad-tile); color: var(--on-primary); box-shadow: 0 8px 20px rgba(150, 110, 70, .35);
}
.fab .ic { width: 26px; height: 26px; stroke-width: 2.2; }
.fab[hidden] { display: none; }

/* Layout */
main { max-width: 1100px; margin: 0 auto; padding: 4px 16px 16px; outline: none; }
.feed-layout { display: grid; gap: 22px; grid-template-columns: minmax(0, 1fr); }
.side { display: none; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.stack { display: grid; gap: 16px; }
.grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.muted { color: var(--muted); }
.small { font-size: .85rem; }
.accent { color: var(--primary-text); }

.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin: 28px 0 14px; }
.section-head h2 { font-size: 1.35rem; font-weight: 800; }
.section-head a, .link { color: var(--primary-text); font-weight: 700; font-size: .95rem; cursor: pointer; background: none; border: 0; padding: 0; }
.page-head { margin: 12px 0 16px; display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.page-head h1 { font-size: 1.5rem; font-weight: 800; }
.page-head p { margin: 0; color: var(--muted); font-size: .92rem; }

/* Hero greeting */
.hero {
  position: relative; overflow: hidden; display: flex; align-items: center; gap: 16px;
  padding: 28px 24px; border-radius: 30px; background: var(--hero); border: 1px solid var(--line); margin-top: 8px;
}
.hero::after { content: ""; position: absolute; width: 110px; height: 110px; border-radius: 50%; border: 22px solid rgba(255,255,255,.45); inset-inline-end: -40px; bottom: -50px; }
.hero .txt { flex: 1; }
.hero .hi { color: var(--primary-text); font-weight: 500; }
.hero h1 { font-size: 1.75rem; font-weight: 800; }
.hero .pet-photo { width: 112px; height: 112px; font-size: 3.6rem; border: 4px solid #fff; box-shadow: 0 6px 16px rgba(0,0,0,.08); z-index: 1; }

.photo { display: grid; place-items: center; overflow: hidden; background-size: cover; background-position: center; }
.photo img { width: 100%; height: 100%; object-fit: cover; }
.pet-photo { border-radius: 50%; flex: none; }

/* Home extras */
.shortcuts { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-top: 18px; }
.shortcut { display: grid; justify-items: center; gap: 6px; padding: 14px 4px 12px; border-radius: 20px; background: var(--surface); border: 1px solid var(--line); font-size: .85rem; font-weight: 700; text-align: center; }
.shortcut span { display: grid; place-items: center; width: 48px; height: 48px; border-radius: 16px; background: var(--peach); font-size: 1.4rem; }
.reminder { display: flex; align-items: center; gap: 14px; padding: 14px 16px; margin-top: 14px; }
.reminder .grow { flex: 1; min-width: 0; }
.rem-ic { display: grid; place-items: center; width: 46px; height: 46px; border-radius: 14px; background: color-mix(in srgb, var(--teal) 18%, transparent); font-size: 1.3rem; flex: none; }
.adopt-hero { flex-wrap: wrap; }
.adopt-hero .btn { position: relative; z-index: 1; }
.adopt-hero .txt { min-width: 200px; }
.hscroll { display: flex; gap: 12px; overflow-x: auto; padding-bottom: 6px; scrollbar-width: none; }
.hscroll::-webkit-scrollbar { display: none; }
.adopt-mini { flex: none; width: 150px; overflow: hidden; }
.adopt-mini .photo { aspect-ratio: 1; font-size: 3.4rem; }
.adopt-mini .info { display: grid; padding: 10px 12px 12px; line-height: 1.5; }
.stories { display: flex; gap: 14px; overflow-x: auto; padding: 2px 2px 14px; scrollbar-width: none; }
.stories::-webkit-scrollbar { display: none; }
.story { flex: none; display: grid; justify-items: center; gap: 4px; width: 72px; font-size: .8rem; font-weight: 500; text-align: center; border: 0; background: none; padding: 0; cursor: pointer; }
.story .ring { padding: 3px; border-radius: 50%; background: var(--grad-tile); }
.story .ring.add { background: var(--line); }
.story .pet-photo { width: 62px; height: 62px; font-size: 1.9rem; border: 3px solid var(--bg); background: var(--surface); color: var(--muted); }

/* Events */
.event { overflow: hidden; }
.ev-main { display: flex; min-height: 200px; }
.ev-photo { display: flex; width: 40%; max-width: 260px; }
.ev-photo .photo { width: 100%; }
.event .info { flex: 1; padding: 20px 22px; display: grid; align-content: center; gap: 6px; }
.when { color: var(--primary-text); font-weight: 700; font-size: .95rem; }
.event h3 { font-size: 1.2rem; font-weight: 800; }
.event .place { display: flex; align-items: center; gap: 6px; color: var(--muted); }
.when-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.price { padding: 1px 10px; border-radius: 999px; font-size: .8rem; font-weight: 700; white-space: nowrap; }
.price.free { background: color-mix(in srgb, var(--teal) 18%, transparent); color: color-mix(in srgb, var(--teal) 65%, var(--text)); }
.price.paid { background: var(--peach); color: var(--primary-text); }
.organizer { display: flex; border-radius: 14px; padding: 4px; margin-inline: -4px; align-items: center; gap: 10px; margin: 4px 0 2px; color: var(--muted); line-height: 1.5; }
.organizer b { color: var(--text); font-weight: 700; font-size: .95rem; }
a.organizer:hover { background: var(--surface-2); }
.organizer > .ic { margin-inline-start: auto; color: var(--muted); }
.org-ic { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; background: var(--surface-2); font-size: 1.05rem; flex: none; }
.organizer .small { white-space: nowrap; }
.org-t { color: color-mix(in srgb, var(--teal) 70%, var(--text)); font-weight: 700; }
.person-t { color: var(--primary-text); font-weight: 700; }
.event .left { color: var(--primary-text); font-weight: 700; font-size: .95rem; }
.event .photo { font-size: 4.5rem; }
.ev-actions { display: flex; gap: 8px; padding: 12px 14px; border-top: 1px solid var(--line); flex-wrap: wrap; }
.ev-actions .btn { flex: 1; }
.event h3 a:hover { color: var(--primary-text); }
.progress { height: 6px; border-radius: 99px; background: var(--surface-2); overflow: hidden; }
.progress i { display: block; height: 100%; background: var(--grad); border-radius: 99px; }

/* Posts */
.post { overflow: hidden; }
.post-head { display: flex; gap: 14px; align-items: center; padding: 20px 22px 6px; }
.post-head .pet-photo { width: 58px; height: 58px; font-size: 1.9rem; }
.post-head .who { flex: 1; min-width: 0; }
.post-head .name { font-weight: 800; font-size: 1.15rem; }
.post-head .owner { font-size: .92rem; font-weight: 600; color: var(--text); opacity: .8; line-height: 1.4; }
.post-head .meta { color: var(--muted); font-size: .9rem; }
.icon-only { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 12px; border: 0; background: none; cursor: pointer; color: var(--muted); }
.icon-only:hover { background: var(--surface-2); }
.post-body { padding: 8px 22px 16px; font-size: 1.05rem; white-space: pre-wrap; }
.post > .photo { aspect-ratio: 4 / 3; max-height: 420px; width: 100%; font-size: 7rem; }
.tags { display: flex; gap: 8px; flex-wrap: wrap; padding: 12px 22px 0; }
.tag { color: var(--teal); font-size: .88rem; font-weight: 500; }
.actions { display: flex; gap: 4px; padding: 8px 14px; }
.act { display: inline-flex; align-items: center; gap: 6px; padding: 8px 12px; border-radius: 14px; border: 0; background: none; cursor: pointer; color: var(--muted); font-weight: 500; }
.act:hover { background: var(--surface-2); }
.act.liked { color: #E0566E; }
.act.liked .ic { fill: currentColor; animation: pop .3s ease; }
@keyframes pop { 50% { transform: scale(1.3); } }
.comments { display: grid; gap: 8px; padding: 0 22px 4px; }
.comment { display: flex; gap: 8px; align-items: flex-start; }
.avatar { flex: none; display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: var(--surface-2); font-size: 1.1rem; }
.comment .bubble { background: var(--surface-2); border-radius: 16px; padding: 6px 14px; font-size: .92rem; }
.comment .bubble b { display: block; font-size: .8rem; }
.comment-form { display: flex; gap: 8px; padding: 10px 22px 20px; }

/* Controls */
.chips { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px; margin-bottom: 16px; scrollbar-width: none; }
.chips::-webkit-scrollbar { display: none; }
.chip { flex: none; display: inline-flex; align-items: center; gap: 6px; padding: 8px 16px; border-radius: 14px; border: 1px solid var(--line); background: var(--surface); cursor: pointer; white-space: nowrap; font-weight: 500; }
.chip.on { background: var(--peach); border-color: var(--primary); color: var(--primary-text); font-weight: 700; }
.toolbar { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 16px; }
.input { width: 100%; padding: 11px 16px; border-radius: 16px; border: 1px solid var(--line); background: var(--surface); outline: none; }
.input:focus { border-color: var(--primary); box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 20%, transparent); }
.toolbar .input { flex: 1 1 180px; width: auto; }
.btn { white-space: nowrap; display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 10px 20px; border-radius: 16px; border: 1px solid var(--line); background: var(--surface); cursor: pointer; font-weight: 700; }
.btn.primary { background: var(--grad); border: 0; color: var(--on-primary); box-shadow: 0 6px 16px rgba(150, 120, 90, .25); }
.btn.soft { background: var(--peach); border-color: transparent; color: var(--primary-text); }
.btn.ghost { border-color: transparent; background: transparent; color: var(--muted); font-weight: 500; }
.btn.sm { padding: 6px 14px; font-size: .88rem; border-radius: 12px; }
.btn.block { width: 100%; padding: 16px; font-size: 1.1rem; border-radius: 20px; }
.badge { display: inline-block; padding: 1px 10px; border-radius: 999px; font-size: .76rem; font-weight: 500; background: var(--surface-2); color: var(--muted); }
.badge.ok { background: color-mix(in srgb, var(--teal) 18%, transparent); color: color-mix(in srgb, var(--teal) 70%, var(--text)); }
.badge.warn { background: color-mix(in srgb, var(--danger) 13%, transparent); color: var(--danger); }
.sample-tag { display: inline-block; vertical-align: middle; margin-inline-start: 6px; padding: 1px 8px; border-radius: 999px; font-size: .7rem; font-weight: 600; line-height: 1.6; white-space: nowrap; background: color-mix(in srgb, var(--danger) 13%, transparent); color: var(--danger); }
.badge.pri { background: var(--peach); color: var(--primary-text); }

/* Services & cards */
.svc { padding: 18px 20px; display: grid; gap: 8px; }
.svc-top { display: flex; gap: 12px; align-items: center; }
.svc-icon { display: grid; place-items: center; width: 52px; height: 52px; border-radius: 16px; background: var(--peach); font-size: 1.5rem; flex: none; }
.svc h3 { font-size: 1.05rem; font-weight: 800; }
.stars { color: #DDA21A; font-weight: 700; }
.svc-foot { display: flex; gap: 8px; margin-top: 4px; }
.svc-foot .btn { flex: 1; }
.pet-card { overflow: hidden; display: grid; }
.pet-card .photo { aspect-ratio: 4 / 3; font-size: 4.5rem; position: relative; }
.pet-card .info { padding: 14px 18px 18px; display: grid; gap: 6px; }
.pet-card h3 { font-size: 1.1rem; font-weight: 800; display: flex; align-items: center; gap: 8px; }
.pet-card .row { display: flex; gap: 6px; flex-wrap: wrap; }
.fav { position: absolute; top: 12px; inset-inline-end: 12px; display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; border: 0; background: rgba(255,255,255,.92); cursor: pointer; color: #E0566E; }
.fav.on .ic { fill: currentColor; }

/* Map */
.map { position: relative; height: 380px; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); background: #EEF1E6; direction: ltr; isolation: isolate; }
#leaflet { position: absolute; inset: 0; background: #EEF1E6; font-family: inherit; }
.leaflet-control-attribution { font-size: 10px; }
.leaflet-bar a { color: #3B2A20; }
.pin { position: absolute; left: 0; top: 0; transform: translate(-50%, -100%); display: grid; justify-items: center; cursor: pointer; border: 0; background: none; padding: 0; font-family: var(--font); }
.pin .bubble { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50% 50% 50% 0; transform: rotate(-45deg); box-shadow: 0 4px 10px rgba(0,0,0,.18); border: 3px solid #fff; }
.pin .bubble span { transform: rotate(45deg); font-size: 1.05rem; }
.pin.ev .bubble { border-color: #fff; outline: 2px solid rgba(124,92,190,.35); }
.pin.me { transform: translate(-50%, -50%); cursor: default; }
.pin.me .bubble { width: 20px; height: 20px; border-radius: 50%; transform: none; background: #3B82F6; box-shadow: 0 0 0 8px rgba(59,130,246,.22); }
.pin label { margin-top: 4px; padding: 0 8px; border-radius: 8px; background: rgba(255,255,255,.94); color: #3B2A20; font-size: .72rem; font-weight: 700; white-space: nowrap; max-width: 150px; overflow: hidden; text-overflow: ellipsis; cursor: inherit; }
.map-me { position: absolute; z-index: 500; top: 10px; right: 10px; background: #fff; color: #3B2A20; border-radius: 10px; box-shadow: 0 2px 8px rgba(0,0,0,.15); width: 38px; height: 38px; }
.map-pop { position: absolute; z-index: 600; left: 10px; right: 10px; bottom: 10px; display: grid; gap: 6px; justify-items: start; padding: 14px 16px; border-radius: 16px; background: var(--surface); color: var(--text); box-shadow: 0 8px 24px rgba(0,0,0,.18); direction: var(--dir, rtl); text-align: start; }
:root[dir="ltr"] .map-pop { direction: ltr; }
:root[dir="rtl"] .map-pop { direction: rtl; }
.map-pop .x { position: absolute; top: 8px; inset-inline-end: 8px; width: 32px; height: 32px; }
.map-pop .pop-t { font-size: 1.02rem; padding-inline-end: 34px; }
.map-pop[hidden] { display: none; }
.map.z-low .pin:not(.me) label { display: none; }
.map.z-low .pin .bubble { width: 34px; height: 34px; }
.field-row { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 12px; }
.create-pick { display: grid; gap: 10px; }
.create-pick .list-row { width: 100%; border: 1px solid var(--line); box-shadow: none; cursor: pointer; font: inherit; color: inherit; text-align: start; background: var(--surface); }
.legend { display: flex; gap: 14px; flex-wrap: wrap; margin: 10px 2px 0; font-size: .85rem; color: var(--muted); }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 50%; margin-inline-end: 6px; }
.list-row { display: flex; gap: 14px; align-items: center; padding: 14px 16px; }
.list-row .pet-photo { width: 54px; height: 54px; font-size: 1.7rem; }
.list-row .grow { flex: 1; min-width: 0; }

/* Profile */
.profile-head { padding: 24px; display: flex; gap: 18px; align-items: center; flex-wrap: wrap; background: var(--hero); }
.profile-head .who { flex: 1; min-width: 160px; }
.profile-head h1 { font-size: 1.4rem; font-weight: 800; }
.profile-head .pet-photo { width: 88px; height: 88px; font-size: 2.6rem; background: var(--surface); border: 4px solid #fff; }
.stats { display: grid; grid-template-columns: repeat(4, minmax(0, auto)); justify-content: start; gap: 8px 14px; margin-top: 10px; }
.stats .small { font-size: .76rem; line-height: 1.35; display: block; }
.stats b { display: block; font-size: 1.15rem; }
.mini-pet { display: flex; gap: 12px; align-items: center; padding: 14px; }
.mini-pet .pet-photo { width: 56px; height: 56px; font-size: 1.8rem; }
.settings .row { display: flex; flex-wrap: wrap; gap: 8px; justify-content: space-between; align-items: center; padding: 14px 18px; border-top: 1px solid var(--line); }
.settings .row:first-child { border-top: 0; }
.seg { display: inline-flex; flex-wrap: wrap; padding: 3px; border-radius: 12px; background: var(--surface-2); }
.seg button { white-space: nowrap; border: 0; background: none; padding: 4px 14px; border-radius: 10px; cursor: pointer; color: var(--muted); font-weight: 500; }
.seg button.on { background: var(--surface); color: var(--primary-text); font-weight: 700; box-shadow: var(--shadow); }

/* Pet detail */
.detail { display: grid; gap: 16px; }
.detail .cover { aspect-ratio: 16 / 9; max-height: 360px; border-radius: var(--radius); font-size: 7rem; }
.facts { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 10px; }
.fact { padding: 12px 14px; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; font-weight: 700; }
.fact span { display: block; color: var(--muted); font-size: .8rem; font-weight: 400; }
.timeline { display: grid; gap: 12px; padding: 18px 20px; }
.timeline .ev { display: flex; gap: 12px; align-items: center; }
.timeline .dot { width: 10px; height: 10px; border-radius: 50%; background: var(--primary); flex: none; }

.detail-title { font-size: 1.5rem; font-weight: 800; margin-top: 4px; }
.sub-h { font-size: 1.1rem; font-weight: 800; margin-bottom: 4px; }
.meet { display: flex; gap: 14px; align-items: flex-start; padding: 16px 18px; background: var(--peach); border-color: transparent; }
.meet p { margin: 2px 0 0; }
.meet-ic { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 14px; background: var(--surface); color: var(--primary-text); flex: none; }
.detail-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.detail-actions .btn { flex: 1; }
.ic.filled { fill: currentColor; color: #E0566E; }
.review { display: flex; gap: 12px; padding: 14px 16px; }
.review p { margin: 4px 0 0; }

/* Inbox */
.inbox { overflow: hidden; }
.inbox-row { display: flex; align-items: center; gap: 12px; padding: 14px 16px; border-top: 1px solid var(--line); }
.inbox-row:first-child { border-top: 0; }
.inbox-row:hover { background: var(--surface-2); }
.inbox-row .avatar { width: 50px; height: 50px; font-size: 1.5rem; }
.inbox-row .grow { flex: 1; min-width: 0; }
.inbox-row .top { display: flex; justify-content: space-between; gap: 8px; }
.inbox-row .preview { color: var(--muted); font-size: .9rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.inbox-row.unread .preview { color: var(--text); font-weight: 500; }
.unread-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--primary); flex: none; }
.msg-line { display: flex; align-items: center; gap: 8px; margin-top: 14px; padding: 10px 14px; border-radius: 16px; background: var(--peach); color: var(--primary-text); font-weight: 700; font-size: .92rem; }
.msg-line span { flex: 1; }
.msg-strip { display: flex; align-items: center; gap: 14px; padding: 12px 16px; margin-top: 14px; background: var(--peach); border-color: transparent; }
.msg-strip .grow { flex: 1; min-width: 0; }
.msg-strip .rem-ic, .list-row .rem-ic { background: var(--surface); color: var(--primary-text); }

.inbox-row .kind { font-size: .72rem; font-weight: 500; color: var(--muted); background: var(--surface-2); padding: 0 8px; border-radius: 99px; margin-inline-start: 4px; }
.real { display: block; font-size: .78rem; font-weight: 400; color: var(--muted); line-height: 1.4; }
.inbox-row .top .real, .list-row .real { display: inline; margin-inline-start: 4px; }
.avatar img { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; }
.big-av { width: 50px; height: 50px; font-size: 1.5rem; }
.friends-row { display: flex; gap: 12px; overflow-x: auto; padding-bottom: 6px; scrollbar-width: none; }
.friends-row::-webkit-scrollbar { display: none; }
.friend { flex: none; width: 120px; display: grid; justify-items: center; gap: 8px; padding: 14px 10px; background: var(--surface); border: 1px solid var(--line); border-radius: 20px; text-align: center; }
.friend > a:first-child { display: grid; justify-items: center; gap: 2px; }
.friend .big-av { margin-bottom: 4px; }
.friend .big-av { width: 60px; height: 60px; font-size: 1.9rem; }

/* Chat */
.chat { display: flex; flex-direction: column; min-height: calc(100vh - 180px); max-width: 720px; margin: 0 auto; }
.chat-head { display: flex; align-items: center; gap: 8px; padding: 8px 0 12px; border-bottom: 1px solid var(--line); }
.chat-who { display: flex; align-items: center; gap: 10px; }
.chat-who > span:last-child { display: grid; line-height: 1.4; }
.chat-who .avatar { width: 44px; height: 44px; font-size: 1.4rem; }
.chat-body { flex: 1; display: flex; flex-direction: column; gap: 8px; padding: 16px 0; }
.chat-note { align-self: center; text-align: center; max-width: 320px; margin: 0 0 8px; padding: 6px 14px; border-radius: 14px; background: var(--surface-2); color: var(--muted); font-size: .8rem; }
.bubble-row { display: flex; }
.bubble-row.me { justify-content: flex-end; }
.bubble-row.host { justify-content: flex-start; }
.msg { max-width: 78%; padding: 9px 14px; border-radius: 20px; background: var(--surface); border: 1px solid var(--line); white-space: pre-wrap; }
.bubble-row.me .msg { background: var(--grad); color: var(--on-primary); border: 0; border-start-end-radius: 6px; }
.bubble-row.host .msg { border-start-start-radius: 6px; }
.typing { display: flex; gap: 4px; padding: 14px; }
.typing i { width: 7px; height: 7px; border-radius: 50%; background: var(--muted); animation: blink 1s infinite; }
.typing i:nth-child(2) { animation-delay: .2s; } .typing i:nth-child(3) { animation-delay: .4s; }
@keyframes blink { 50% { opacity: .25; } }
.chat-form { position: sticky; bottom: calc(var(--nav-h) + 8px + env(safe-area-inset-bottom)); display: flex; gap: 8px; padding: 10px 0; background: var(--bg); }
@media (min-width: 900px) { .chat-form { bottom: 0; } }

.empty { text-align: center; padding: 40px 16px; color: var(--muted); }
.empty .big { font-size: 3rem; }

/* Dialogs & language sheet */
dialog {
  width: min(560px, calc(100vw - 32px)); max-height: calc(100vh - 48px); padding: 0;
  border: 1px solid var(--line); border-radius: 28px; background: var(--bg); color: var(--text); box-shadow: 0 20px 60px rgba(0,0,0,.25);
}
dialog::backdrop { background: rgba(60, 70, 60, .45); backdrop-filter: blur(6px); }
@media (max-width: 600px) { dialog.sheet { margin: auto 16px 16px; width: auto; max-width: none; } }
.modal-head { display: flex; justify-content: space-between; align-items: center; padding: 16px 20px; border-bottom: 1px solid var(--line); }
.modal-head h2 { font-size: 1.15rem; font-weight: 800; }
.modal-body { padding: 18px 20px; display: grid; gap: 12px; }
.modal-foot { display: flex; gap: 8px; justify-content: flex-end; padding: 0 20px 20px; }
label.field { display: grid; gap: 4px; font-size: .9rem; font-weight: 500; }
.pick { display: flex; gap: 8px; flex-wrap: wrap; }
.lang-sheet { padding: 28px 24px 24px; display: grid; gap: 6px; }
.lang-sheet .logo-tile { margin-bottom: 14px; width: 64px; height: 64px; border-radius: 20px; }
.lang-sheet h2 { font-size: 1.7rem; font-weight: 800; }
.lang-sheet p { margin: 0 0 18px; color: var(--muted); }
.lang-opts { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-bottom: 20px; }
.lang-opt { text-align: start; padding: 22px 20px; border-radius: 22px; border: 1.5px solid var(--line); background: var(--surface); cursor: pointer; }
.lang-opt b { display: block; font-size: 1.3rem; font-weight: 800; }
.lang-opt span { color: var(--muted); font-size: .9rem; }
.lang-opt:focus { outline: none; }
.lang-opt:focus-visible { outline: 2px solid var(--teal); outline-offset: 2px; }
.lang-opt.on { background: var(--peach); border: 2px solid var(--primary); }

#toast {
  position: fixed; z-index: 50; left: 50%; bottom: calc(var(--nav-h) + 96px); transform: translate(-50%, 20px);
  padding: 10px 18px; border-radius: 14px; background: var(--text); color: var(--bg); opacity: 0; pointer-events: none; transition: .25s;
}
#toast.show { opacity: 1; transform: translate(-50%, 0); }

/* Desktop */
@media (min-width: 900px) {
  body { padding-bottom: 0; }
  .bottomnav { display: none; }
  .topnav { display: flex; }
  .topbar { padding: 14px 28px; border-bottom: 1px solid var(--line); }
  .fab { bottom: 28px; inset-inline-start: 28px; }
  #toast { bottom: 40px; }
  main { padding: 20px 28px; }
  .feed-layout { grid-template-columns: minmax(0, 1fr) 340px; align-items: start; }
  .side { display: grid; gap: 16px; position: sticky; top: 104px; }
  .side .card { padding: 18px 20px; }
  .side h3 { font-size: 1.05rem; font-weight: 800; margin-bottom: 10px; }
  .map { height: 520px; }
}
@media (max-width: 420px) {
  .topbar { gap: 8px; }
  .top-actions { gap: 6px; }
  .pill-btn { height: 44px; padding: 0 10px; }
  .pill-btn.square { width: 44px; }
  .logo-tile { width: 46px; height: 46px; }
  .brand { gap: 10px; min-width: 0; }
  .brand-text { min-width: 0; }
  .brand-text span { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .ev-photo { width: 32%; }
  .event .organizer > .ic { display: none; }
  .hero h1 { font-size: 1.45rem; }
  .hero .pet-photo { width: 92px; height: 92px; font-size: 3rem; }
  .event { min-height: 170px; }
  .event .info { padding: 16px; }
  .event h3 { font-size: 1.05rem; }
}

/* Likes, dislikes and comments on map places and events */
.votes { display: flex; gap: 8px; flex-wrap: wrap; }
.vote { display: inline-flex; align-items: center; gap: 6px; padding: 8px 16px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); color: var(--text); font: inherit; font-size: .95rem; cursor: pointer; }
.vote b { font-weight: 700; }
.vote.on.up { background: #E3F2DC; border-color: #9CCB8A; color: #2F5E22; }
.vote.on.down { background: #FBE3E3; border-color: #E8A0A0; color: #8A2E2E; }
.vote.static { cursor: default; }
.pop-counts { display: flex; gap: 14px; font-size: .9rem; color: var(--muted); }
.place-head { display: flex; gap: 16px; align-items: center; padding: 18px 20px; }
.place-head .pet-photo { width: 64px; height: 64px; font-size: 2rem; flex: none; }
.place-head .detail-title { margin: 0 0 4px; }
.place-comments .comments { padding: 16px 22px 0; }
.place-comments .comment-form { padding: 14px 22px 18px; }
:root[data-theme="dark"] .vote.on.up { background: #24361E; color: #BFE3B0; }
:root[data-theme="dark"] .vote.on.down { background: #3A2020; color: #F0B8B8; }
.vote-sum { display: flex; gap: 16px; font-size: .9rem; color: var(--muted); padding: 2px 0; text-decoration: none; }
.vote-sum span { display: inline-flex; gap: 4px; align-items: center; }
.svc-foot .btn { flex: 1; }
.contact { display: grid; gap: 14px; padding: 18px 20px; }
.c-row { display: flex; gap: 12px; align-items: flex-start; }
.c-row > div { display: grid; gap: 2px; }
.c-ic { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 12px; background: var(--peach); flex: none; }

.edit-btn { margin-top: 10px; justify-self: start; }
.swatches { display: flex; gap: 10px; flex-wrap: wrap; }
.swatch { width: 34px; height: 34px; border-radius: 50%; border: 3px solid var(--surface); background: var(--sw); box-shadow: 0 0 0 1px var(--line); cursor: pointer; padding: 0; }
.swatch.on { box-shadow: 0 0 0 2px var(--primary); }

/* Sign up with identity check */
body.gate .topbar, body.gate .bottomnav, body.gate #fab { display: none !important; }
body.gate { padding-bottom: 0 !important; }
body.gate main#view { padding-top: 0; }
.signup { min-height: 100vh; display: grid; place-items: center; padding: 24px 0; }
.su-card { width: min(100%, 440px); display: grid; gap: 14px; padding: 28px 24px; }
.su-card .logo-tile { margin-bottom: 4px; }
.su-card h1 { margin: 0; font-size: 1.5rem; font-weight: 800; }
.su-card > p, .su-card h1 + p { margin: 0; }
.su-form { display: grid; gap: 14px; }
.su-form .btn.primary { justify-content: center; padding-block: 14px; }
.su-steps { display: flex; gap: 6px; }
.su-steps i { flex: 1; height: 6px; border-radius: 99px; background: var(--line); }
.su-steps i.on { background: var(--grad); }
.su-err { margin: 0; padding: 10px 14px; border-radius: 12px; background: #FBE3E3; color: #8A2E2E; font-size: .9rem; }
.code-input { text-align: center; font-size: 1.6rem; letter-spacing: .5em; font-weight: 700; }
.field-row.even { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.su-wait, .su-done { display: grid; justify-items: center; gap: 12px; text-align: center; padding: 18px 0; }
.spinner { width: 44px; height: 44px; border-radius: 50%; border: 4px solid var(--line); border-top-color: var(--primary); animation: spin 0.9s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.big-ok { display: grid; place-items: center; width: 72px; height: 72px; border-radius: 50%; background: #E3F2DC; color: #2F7A22; font-size: 2.2rem; font-weight: 800; }
.verified { display: inline-flex; align-items: center; gap: 4px; padding: 2px 10px; border-radius: 99px; background: #E3F2DC; color: #2F6B22; font-size: .78rem; font-weight: 700; width: fit-content; }
.verified.sm { font-size: .72rem; padding: 1px 8px; }
.input.locked { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; background: var(--surface-2); color: var(--text); }
.su-top { display: flex; align-items: center; justify-content: space-between; }
.su-types { display: grid; gap: 10px; }
.su-types .list-row, .doc { width: 100%; border: 1px solid var(--line); box-shadow: none; cursor: pointer; font: inherit; color: inherit; text-align: start; background: var(--surface); }
.doc { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 16px; border-style: dashed; cursor: default; }
.doc-btns { display: flex; gap: 8px; width: 100%; }
.doc-btns .btn { flex: 1; justify-content: center; cursor: pointer; }
.doc.has { border-style: solid; border-color: #9CCB8A; }
.doc .grow { display: grid; gap: 2px; min-width: 0; }
.doc .grow .small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.doc-thumb { display: grid; place-items: center; width: 56px; height: 42px; border-radius: 10px; background: var(--surface-2); overflow: hidden; flex: none; font-size: 1.3rem; }
.doc-thumb img { width: 100%; height: 100%; object-fit: cover; }
.big-ok.pending { background: #FBF0D2; color: #8A6400; }
.badge.pend { background: #FBF0D2; color: #8A6400; white-space: nowrap; }
.biz-card { box-shadow: none; border: 1px solid var(--line); }
.since { margin-top: 2px; }
.profile-head > .stats { flex-basis: 100%; grid-template-columns: repeat(4, minmax(0, 1fr)); margin-top: 0; padding-top: 14px; border-top: 1px solid color-mix(in srgb, var(--text) 8%, transparent); text-align: center; }

/* Care calendar */
.cal-layout { display: grid; gap: 18px; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 900px) { .cal-layout { grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); align-items: start; } }
.cal { padding: 16px; display: grid; gap: 12px; }
.cal-head { display: flex; align-items: center; justify-content: space-between; }
.cal-head b { font-size: 1.1rem; }
.cal-grid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 4px; }
.cal-wd { text-align: center; font-size: .78rem; color: var(--muted); padding: 4px 0; }
.cal-day { position: relative; display: grid; place-items: center; aspect-ratio: 1; border: 0; border-radius: 12px; background: none; font: inherit; color: var(--text); cursor: pointer; padding: 0; }
.cal-day.empty { cursor: default; }
.cal-day:not(.empty):hover { background: var(--surface-2); }
.cal-day.today span { color: var(--primary-text); font-weight: 800; }
.cal-day.today { box-shadow: inset 0 0 0 1.5px var(--primary); }
.cal-day.sel { background: var(--peach); }
.cal-day .dots { position: absolute; bottom: 5px; display: flex; gap: 2px; }
.cal-day .dots b { width: 5px; height: 5px; border-radius: 50%; }
.cal-sel { border-top: 1px solid var(--line); padding-top: 12px; display: grid; gap: 10px; }
.cal-sel-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.stack-sm { display: grid; gap: 10px; }
.care-list { padding: 14px 16px; }
.care-row { display: flex; align-items: center; gap: 12px; }
.care-row .grow { min-width: 0; }
.care-row.done b { text-decoration: line-through; color: var(--muted); }
.care-ic { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 14px; flex: none; font-size: 1.2rem; }
.care-row .soon, .list-row .soon { color: var(--primary-text); font-weight: 700; }
.care-row .late, .list-row .late { color: var(--danger); font-weight: 700; }
.care-row .btn { flex: none; }
.date-row { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.4fr) minmax(0, 1fr); gap: 8px; }
a.card.reminder { color: inherit; text-decoration: none; }
.vax-card { padding: 14px 16px; display: grid; gap: 10px; }
.vax-row { display: flex; align-items: center; gap: 12px; }
.vax-ic { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; font-weight: 800; flex: none; }
.vax-row.ok .vax-ic { background: #E3F2DC; color: #2F6B22; }
.vax-row.exp .vax-ic { background: #FBF0D2; color: #8A6400; }
.vax-row.miss .vax-ic { background: var(--surface-2); color: var(--muted); }
.vax-row.exp .small { color: #8A6400; }
.vax-row.miss .small { color: var(--muted); }
.mini-pet .badge { margin-top: 4px; display: inline-block; font-size: .72rem; }
.vax-pick[hidden] { display: none; }
.neut-sel { padding: 6px 10px; font-size: .9rem; margin-top: 4px; height: auto; }
.proof-line { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-top: 4px; }
.proof { display: inline-flex; align-items: center; gap: 4px; padding: 1px 9px; border-radius: 99px; font-size: .72rem; font-weight: 700; }
.proof.ok { background: #E3F2DC; color: #2F6B22; }
.proof.pend { background: #FBF0D2; color: #8A6400; }
.proof.own { background: var(--surface-2); color: var(--muted); }
.proof-up { padding: 3px 10px; font-size: .75rem; cursor: pointer; }

/* Sitters & walkers */
.mode-seg { display: flex; width: 100%; margin-top: 12px; margin-bottom: 18px; }
.mode-seg button { flex: 1; padding: 10px 8px; font-size: .95rem; }
.hub-seg { margin-top: 0; margin-bottom: 12px; }
.hub-seg + .mode-seg { margin-top: 0; }
.hub-seg a { flex: 1; text-align: center; white-space: nowrap; padding: 10px 8px; border-radius: 10px; color: var(--muted); font-weight: 500; font-size: .95rem; }
.hub-seg a.on { background: var(--surface); color: var(--primary-text); font-weight: 700; box-shadow: var(--shadow); }
.sitter { display: grid; gap: 10px; padding: 18px; }
.sit-top { display: flex; gap: 12px; align-items: center; color: inherit; text-decoration: none; }
.sit-top h3 { margin: 0; font-size: 1.08rem; font-weight: 800; }
.sit-top .grow { min-width: 0; display: grid; gap: 2px; }
.sit-av { display: grid; place-items: center; width: 60px; height: 60px; border-radius: 50%; background: var(--surface-2); font-size: 2rem; flex: none; }
.sit-kinds { display: flex; flex-wrap: wrap; gap: 6px; }
.sit-kind { padding: 4px 10px; border-radius: 10px; background: var(--peach); color: var(--text); font-size: .82rem; }
.sit-kind b { color: var(--primary-text); }
.sit-meta { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; font-size: .85rem; }
.sit-meta > span:first-child { margin-inline-end: 4px; }
.vote-sum .muted { margin-inline-start: auto; }
.offer-cta { display: flex; align-items: center; gap: 12px; padding: 16px; margin: 4px 0 14px; background: var(--hero); }
.offer-cta .big { font-size: 2rem; }
.price-list { padding: 6px 16px; }
.pl-row { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 12px 0; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.pl-row:last-child { border-bottom: 0; }
.week { display: flex; gap: 4px; flex-wrap: wrap; }
.week i { font-style: normal; display: grid; place-items: center; min-width: 26px; height: 26px; padding: 0 4px; border-radius: 8px; background: var(--surface-2); color: var(--muted); font-size: .75rem; }
.week i.on { background: var(--primary); color: var(--on-primary); font-weight: 700; }
.offer-kinds { display: grid; gap: 8px; }
.ok-row { display: grid; grid-template-columns: auto minmax(0, 1fr) minmax(0, 120px); align-items: center; gap: 8px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 14px; }
.ok-row .small { grid-column: 3; text-align: end; margin-top: -4px; }
.ok-row .input { padding: 8px 10px; }
.fact.wide { grid-column: 1 / -1; }
.fact .week { display: flex; flex-direction: row; margin-top: 6px; }

/* free first service + secure payment */
.free-trial { display: inline-flex; align-self: start; padding: 4px 10px; border-radius: 999px; background: #E3F4E1; color: #24622A; font-weight: 700; font-size: .85rem; }
.free-trial.big { display: grid; gap: 2px; padding: 12px 16px; border-radius: 16px; font-size: 1rem; }
.free-trial.big .muted { color: #3C6E40; font-weight: 400; }
.free-opt { grid-template-columns: auto minmax(0, 1fr); background: #F1F9F0; border-color: #CBE7C7; }
.free-opt div { font-weight: 400; }
.pay-opt { display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; border: 1px solid var(--line); border-radius: 14px; margin-top: 6px; cursor: pointer; }
.pay-opt:has(input:checked) { border-color: var(--primary); background: var(--surface-2); }
.pay-opt input { margin-top: 4px; accent-color: var(--primary); }
.pay-total { border: 1px solid var(--line); border-radius: 14px; padding: 2px 14px; }
.pay-total .pl-row { padding: 8px 0; }
.ok-txt { color: #2E7D32; }
.pay-how { padding: 14px 16px; background: var(--hero); }
.pay-how ol { margin: 8px 0 0; padding-inline-start: 20px; display: grid; gap: 4px; }
.bk-row { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; padding: 12px 0; border-bottom: 1px solid var(--line); }
.bk-row:last-child { border-bottom: 0; }
.bk-act { display: flex; gap: 6px; flex-wrap: wrap; width: 100%; }
@media (prefers-color-scheme: dark) { :root:not([data-theme=light]) .free-trial, :root:not([data-theme=light]) .free-opt { background: #1E3420; color: #A8DDA6; border-color: #2F5232; } :root:not([data-theme=light]) .free-trial.big .muted { color: #8CC28A; } }
:root[data-theme=dark] .free-trial, :root[data-theme=dark] .free-opt { background: #1E3420; color: #A8DDA6; border-color: #2F5232; }
:root[data-theme=dark] .free-trial.big .muted { color: #8CC28A; }
.free-opt.field { display: block; }
.free-pick { margin-top: 8px; }
.ask-opt { grid-template-columns: auto minmax(0, 1fr); }
[data-paybox][hidden] { display: none; }

/* dashboards */
.dash-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; margin: 14px 0; }
.dash-stats .card { padding: 12px 14px; display: grid; gap: 4px; min-width: 0; }
.dash-stats b { font-size: 1.15rem; overflow-wrap: anywhere; }
@media (max-width: 640px) { .dash-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.note-card { padding: 14px 16px; background: var(--hero); display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-top: 12px; }
.pause-row { display: flex; gap: 12px; align-items: flex-start; padding: 12px 16px; cursor: pointer; }
.pause-row input { margin-top: 5px; accent-color: var(--primary); width: 18px; height: 18px; }
.req-row { display: flex; flex-wrap: wrap; gap: 10px; align-items: flex-start; padding: 12px 0; border-bottom: 1px solid var(--line); }
.req-row:last-child { border-bottom: 0; }
.req-pet { font-size: 1.6rem; width: 44px; height: 44px; border-radius: 14px; background: var(--surface-2); display: grid; place-items: center; flex: none; }
.req-row .grow { min-width: 0; flex: 1 1 200px; }
.req-meta { display: flex; flex-wrap: wrap; gap: 6px 10px; align-items: center; margin-top: 4px; }
.badge.pend { background: color-mix(in srgb, #E0A800 18%, transparent); color: #8A6400; }
.price-list > p.muted { padding: 12px 0; margin: 0; }
.review { padding: 12px 14px; display: grid; gap: 8px; }
.review .comment { padding: 0; }
.biz-reply { margin-inline-start: 44px; padding: 10px 12px; border-radius: 12px; background: var(--surface-2); font-size: .92rem; }
.biz-reply b { color: var(--primary-text); display: block; font-size: .85rem; }
.review .comment-form { padding: 0; }
.review-foot { display: flex; justify-content: flex-end; }
.dash-row { margin-top: 14px; }
.dash-row .count.inline { position: static; }
/* safety */
.menu-list { display: grid; gap: 8px; }
.menu-item { width: 100%; text-align: start; font: inherit; color: var(--text); cursor: pointer; padding: 14px 16px; }
.danger-txt { color: var(--danger); font-weight: 700; }
.btn.danger { background: var(--danger); color: #fff; border-color: var(--danger); }
.btn.icon-btn { padding-inline: 12px; }
.hidden-post { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 14px 16px; }
.chat-head { position: relative; }
.chat-menu { margin-inline-start: auto; }
.chat-blocked { padding: 14px 16px; text-align: center; margin: 0; }
.rules { margin: 0 0 12px; padding-inline-start: 20px; display: grid; gap: 8px; }
/* search */
.search-box { position: relative; margin: 6px 0 4px; }
.search-box .ic { position: absolute; inset-inline-start: 14px; top: 50%; transform: translateY(-50%); color: var(--muted); pointer-events: none; }
.search-box .input { padding-inline-start: 44px; height: 52px; font-size: 1rem; }
.sr-list { padding: 4px 0; }
.sr-row { display: flex; align-items: center; gap: 12px; padding: 10px 14px; border-bottom: 1px solid var(--line); color: inherit; text-decoration: none; }
.sr-row:last-child { border-bottom: 0; }
.sr-row .grow { display: grid; min-width: 0; }
.sr-row .grow span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sr-art { width: 40px; height: 40px; border-radius: 12px; background: var(--surface-2); display: grid; place-items: center; font-size: 1.3rem; flex: none; }
.sr-row .ic { color: var(--muted); }
/* post photos and videos */
.media-pick { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; margin: 6px 0 8px; }
.media-pick:empty { display: none; }
.mp-item { position: relative; aspect-ratio: 1; border-radius: 12px; overflow: hidden; background: var(--surface-2); }
.mp-item img, .mp-item video { width: 100%; height: 100%; object-fit: cover; display: block; }
.mp-x { position: absolute; top: 4px; inset-inline-end: 4px; width: 24px; height: 24px; border-radius: 50%; border: 0; background: rgba(0,0,0,.6); color: #fff; font-size: .75rem; cursor: pointer; }
.mp-tag { position: absolute; bottom: 4px; inset-inline-start: 6px; font-size: .9rem; }
.pet-rule { padding: 10px 14px; border-radius: 14px; background: var(--surface-2); font-size: .9rem; }
.media-grid { display: grid; gap: 4px; margin: 0 16px; border-radius: 18px; overflow: hidden; }
.media-grid.n2, .media-grid.n4 { grid-template-columns: 1fr 1fr; }
.media-grid.n3 { grid-template-columns: 1fr 1fr; }
.media-grid.n3 > :first-child { grid-column: 1 / -1; }
.media-grid img, .media-grid video { width: 100%; display: block; object-fit: cover; max-height: 460px; background: #000; }
.media-grid:not(.n1) img, .media-grid:not(.n1) video { aspect-ratio: 1; }
.media-gone { display: grid; place-items: center; aspect-ratio: 16/9; background: var(--surface-2); color: var(--muted); font-size: .85rem; padding: 12px; text-align: center; }
/* iPhone zooms the page when a field under 16px gets focus; keep every field at 16px or more (this must stay last). */
input:not([type=checkbox]):not([type=radio]), select, textarea, .input { font-size: max(16px, 1rem) !important; }
/* Background choice in Profile > Settings: white and black sit on top of the light and dark palettes, whatever the colour theme. */
:root[data-theme="light"][data-bg="white"] { --bg: #FFFFFF; --surface: #FFFFFF; --surface-2: #F4F4F4; --line: #E8E8E8; --peach: #F6EFE7; --hero: linear-gradient(250deg, #FFF7EC 0%, #F1F7F9 100%); }
:root[data-theme="dark"][data-bg="black"] { --bg: #000000; --surface: #121212; --surface-2: #1E1E1E; --line: #2A2A2A; --peach: #262321; --hero: linear-gradient(250deg, #2A2418 0%, #10232A 100%); }
.bg-row { flex-wrap: wrap; gap: 10px; }
.bg-pick { display: flex; flex-wrap: wrap; gap: 8px; }
.bg-opt { display: grid; justify-items: center; gap: 4px; padding: 6px 4px; min-width: 52px; border: 0; background: none; font-size: .78rem; color: var(--muted); cursor: pointer; }
.bg-opt i { width: 34px; height: 34px; border-radius: 50%; box-shadow: 0 0 0 1px var(--line); border: 3px solid var(--surface); }
.bg-opt.on { color: var(--text); font-weight: 700; }
.bg-opt.on i { box-shadow: 0 0 0 2px var(--primary); }
/* Never let anything widen the page sideways on phones. */
#view { overflow-x: clip; max-width: 100%; }
/* No rubber-band bounce: in the app opened from the home screen, iPhones drag the fixed bottom menu along with it. */
/* Only the page itself stops the rubber-band bounce. On body it also blocked mouse-wheel and trackpad scrolling in some desktop browsers. */
html { overscroll-behavior-y: none; }
/* Stories: row on the home page, add dialog and full-screen viewer */
.story { position: relative; }
.story-hit { border: 0; background: none; padding: 0; cursor: pointer; }
.story .ring.seen { background: var(--line); }
.story .pet-photo img { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; }
.story-plus { position: absolute; top: 46px; inset-inline-end: 2px; width: 24px; height: 24px; border-radius: 50%; border: 2px solid var(--bg); background: var(--primary); color: #fff; font-size: .9rem; line-height: 1; display: grid; place-items: center; padding: 0; cursor: pointer; }
.story-preview { display: grid; place-items: center; aspect-ratio: 9 / 12; max-height: 260px; border-radius: 18px; background: var(--surface-2); overflow: hidden; }
.story-preview img { width: 100%; height: 100%; object-fit: cover; }
body.sv-open { overflow: hidden; }
.sv { position: fixed; inset: 0; z-index: 90; background: #000; display: grid; place-items: center; }
.sv-card { position: relative; width: min(100vw, 480px); height: 100dvh; max-height: 100dvh; overflow: hidden; color: #fff; display: grid; grid-template-rows: auto auto 1fr auto; }
@media (min-width: 600px) { .sv-card { height: min(100dvh, 860px); border-radius: 24px; } }
.sv-bars { display: flex; gap: 4px; padding: max(10px, env(safe-area-inset-top)) 12px 0; z-index: 3; }
.sv-bars span { flex: 1; height: 3px; border-radius: 3px; background: rgba(255,255,255,.4); overflow: hidden; }
.sv-bars i { display: block; height: 100%; background: #fff; }
.sv-head { display: flex; align-items: center; gap: 10px; padding: 10px 12px; z-index: 3; text-shadow: 0 1px 3px rgba(0,0,0,.45); }
.sv-head .avatar { width: 36px; height: 36px; font-size: 1.2rem; display: grid; place-items: center; border-radius: 50%; background: rgba(255,255,255,.25); }
.sv-head .small { opacity: .9; font-size: .8rem; }
.sv-btn { border: 0; background: rgba(0,0,0,.25); color: #fff; width: 40px; height: 40px; border-radius: 50%; font-size: 1.1rem; cursor: pointer; display: grid; place-items: center; flex: none; }
.sv-btn.wide { width: auto; padding: 0 14px; border-radius: 20px; font-size: .9rem; }
.sv-btn.like { width: 52px; height: 48px; border-radius: 24px; gap: 0; font-size: 1.2rem; line-height: 1; }
.sv-btn.like small { font-size: .7rem; }
.sv-media { position: absolute; inset: 0; display: grid; place-items: center; z-index: 1; }
.sv-media img { width: 100%; height: 100%; object-fit: contain; }
.sv-emoji { font-size: 9rem; filter: drop-shadow(0 8px 20px rgba(0,0,0,.15)); }
.sv-text { position: absolute; inset-inline: 16px; bottom: 120px; z-index: 2; text-align: center; font-weight: 700; font-size: 1.15rem; padding: 10px 14px; border-radius: 16px; background: rgba(0,0,0,.4); }
.sv-tap { position: absolute; top: 80px; bottom: 90px; width: 35%; border: 0; background: none; z-index: 2; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.sv-tap.prev { inset-inline-start: 0; }
.sv-tap.next { inset-inline-end: 0; width: 65%; }
.sv-sent { position: absolute; bottom: 84px; inset-inline: 12px; z-index: 3; display: flex; flex-wrap: wrap; gap: 6px; }
.sv-sent span { background: rgba(0,0,0,.45); border-radius: 14px; padding: 4px 10px; font-size: .8rem; }
.sv-foot { grid-row: 4; z-index: 3; display: flex; align-items: center; gap: 8px; padding: 12px 12px max(14px, env(safe-area-inset-bottom)); background: linear-gradient(transparent, rgba(0,0,0,.45)); }
.sv-foot .input { flex: 1; min-width: 0; background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.5); color: #fff; border-radius: 24px; }
.sv-foot .input::placeholder { color: rgba(255,255,255,.8); }
.sv-foot.mine { justify-content: space-between; font-size: .9rem; }
.story-hit .ring { display: block; }
.story-hit .pet-photo { display: grid; place-items: center; overflow: hidden; }
.story .pet-photo img { width: 56px; height: 56px; max-width: none; }
/* Adoption listings, detail and the public page opened from a shared link */
.pet-card { position: relative; }
.pet-card .photo img, .adopt-detail .cover img { width: 100%; height: 100%; object-fit: cover; }
.pet-card > .fav { position: absolute; top: 10px; inset-inline-end: 10px; z-index: 2; }
.pet-card .poster, .adopt-detail .poster { color: var(--muted); }
.pet-actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-top: 4px; }
.clamp2 { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.adopt-gallery { display: flex; gap: 8px; overflow-x: auto; scroll-snap-type: x mandatory; border-radius: 22px; scrollbar-width: none; }
.adopt-gallery img { flex: none; width: 88%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 22px; scroll-snap-align: center; }
.pub-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding: 6px 0 4px; }
.pub-head b { font-size: 1.2rem; }
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.btn.danger-ghost { color: var(--danger); border-color: color-mix(in srgb, var(--danger) 40%, var(--line)); }
/* Logo menu and support */
.logo-btn { border: 0; padding: 0; cursor: pointer; }
.brand-text { color: inherit; text-decoration: none; }
.row-between { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.support-form { padding: 16px; }
.faq summary { cursor: pointer; list-style: none; }
.faq summary::-webkit-details-marker { display: none; }
a.menu-item { text-decoration: none; color: inherit; }
.faq { padding: 14px 16px; }
.brand { position: relative; }
.app-menu { position: absolute; top: calc(100% + 8px); inset-inline-start: 0; z-index: 60; min-width: 210px; padding: 6px; display: grid; gap: 2px; background: var(--surface); border: 1px solid var(--line); border-radius: 18px; box-shadow: 0 12px 32px rgba(0,0,0,.16); }
.app-menu[hidden] { display: none; }
.app-menu button { display: flex; align-items: center; gap: 8px; width: 100%; padding: 12px 14px; border: 0; border-radius: 12px; background: none; font: inherit; color: var(--text); text-align: start; cursor: pointer; }
.app-menu button:hover, .app-menu button:focus-visible { background: var(--surface-2); }
.app-menu button.danger-txt { color: var(--danger); }
.app-menu button { min-height: 0; line-height: 1.4; padding: 11px 14px; margin: 0; }
.adopt-gallery video { flex: none; width: 88%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 22px; background: #000; scroll-snap-align: center; }
.pet-card .photo video { width: 100%; height: 100%; object-fit: cover; }
.pet-card .photo .mp-tag { position: absolute; bottom: 8px; inset-inline-start: 8px; }
@media (max-width: 520px) { .offer-cta { flex-wrap: wrap; } .offer-cta .grow { flex: 1 1 60%; } .offer-cta > .btn { flex: 1 0 100%; justify-content: center; } }
.tri-pick { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.tri-pick label { position: relative; }
.tri-pick input { position: absolute; opacity: 0; inset: 0; }
.tri-pick span { display: grid; place-items: center; min-height: 44px; padding: 6px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); font-size: .9rem; text-align: center; cursor: pointer; }
.tri-pick input:checked + span { border-color: var(--primary); background: var(--peach); color: var(--primary-text); font-weight: 700; }
.tri-pick input:focus-visible + span { outline: 2px solid var(--primary); outline-offset: 2px; }
/* Profile photo used as an avatar */
img.av-img { width: 1.4em; height: 1.4em; border-radius: 50%; object-fit: cover; vertical-align: middle; display: inline-block; }
.avatar img.av-img, .photo img.av-img, .sit-av img.av-img, .org-ic img.av-img, .sr-art img.av-img, .chip img.av-img { width: 100%; height: 100%; }
.avatar, .sit-av, .org-ic { overflow: hidden; }
.avatar-pick .av-upload { width: 52px; height: 52px; padding: 0; overflow: hidden; display: grid; place-items: center; border-radius: 50%; }
.vax-row.editable { cursor: pointer; border-radius: 12px; }
.vax-row.editable:hover, .vax-row.editable:focus-visible { background: var(--surface-2); }
.vax-pen { align-self: center; font-size: .9rem; opacity: .6; }
.vax-add { display: grid; gap: 6px; margin-top: 8px; }
.story-name { max-width: 76px; line-height: 1.3; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow-wrap: anywhere; }
.count-pill { display: inline-block; min-width: 18px; padding: 0 6px; border-radius: 99px; background: var(--danger); color: #fff; font-size: .7rem; font-weight: 700; line-height: 18px; text-align: center; margin-inline-start: 4px; }
.sup-thread { display: grid; gap: 10px; }
.sup-msg { display: grid; gap: 2px; max-width: 85%; padding: 10px 12px; border-radius: 16px; background: var(--surface-2); justify-self: start; }
.sup-msg.staff { justify-self: end; background: color-mix(in srgb, var(--teal) 16%, var(--surface)); }
.sup-msg b { font-size: .8rem; }
.adm-preview { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 52vw; }
.adm-report, .adm-docs { display: grid; gap: 8px; }
.adm-media { width: 100%; max-height: 280px; object-fit: contain; border-radius: 14px; background: var(--surface-2); }
.adm-doc-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 10px; }
.adm-doc-grid figure { margin: 0; display: grid; gap: 4px; }
.adm-doc-grid img, .adm-doc-ph { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 12px; background: var(--surface-2); display: grid; place-items: center; }

/* Profile numbers open what's behind them */
.stat-btn { all: unset; box-sizing: border-box; cursor: pointer; border-radius: 12px; padding: 4px 2px; text-align: center; }
.stat-btn:hover, .stat-btn:focus-visible { background: color-mix(in srgb, var(--text) 6%, transparent); }
.stat-btn:focus-visible { outline: 2px solid var(--accent, currentColor); outline-offset: 2px; }
.stat-list .stat-row { color: inherit; text-decoration: none; padding: 12px 14px; display: block; }
.stat-list .stat-row.list-row { display: flex; gap: 12px; }
.stat-list .stat-row p { margin: 4px 0 0; }
.stat-n { font-weight: 700; white-space: nowrap; }

/* Grid or list view for a profile's posts */
.section-head:has(.view-toggle) { align-items: center; }
.view-toggle { display: inline-flex; gap: 2px; padding: 3px; border-radius: 12px; background: var(--surface-2); }
.view-toggle button { display: grid; place-items: center; width: 44px; height: 36px; border: 0; border-radius: 9px; background: none; color: var(--muted, inherit); cursor: pointer; }
.view-toggle button.on { background: var(--surface); color: var(--text); box-shadow: 0 1px 3px rgba(0,0,0,.08); }
.post-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 3px; }
.post-tile { position: relative; aspect-ratio: 1; display: block; overflow: hidden; background: var(--surface-2); color: inherit; text-decoration: none; }
.post-tile img, .post-tile video { width: 100%; height: 100%; object-fit: cover; display: block; }
.post-tile .photo { width: 100%; height: 100%; border-radius: 0; display: grid; place-items: center; font-size: 2.6rem; aspect-ratio: auto; }
.post-tile .photo img { width: 100%; height: 100%; object-fit: cover; }
.tile-text { display: flex; align-items: center; justify-content: center; text-align: center; height: 100%; padding: 10px; box-sizing: border-box; font-size: .8rem; line-height: 1.5; overflow: hidden; }
.tile-badge { position: absolute; top: 6px; inset-inline-end: 6px; color: #fff; font-size: .8rem; text-shadow: 0 1px 3px rgba(0,0,0,.5); display: grid; place-items: center; }
.tile-badge .ic { width: 16px; height: 16px; filter: drop-shadow(0 1px 2px rgba(0,0,0,.5)); }
.sv-who { display: flex; align-items: center; gap: 10px; min-width: 0; padding: 0; border: 0; background: none; color: inherit; font: inherit; text-align: start; cursor: pointer; }
.sv-who .small { display: block; }
.sv-head > .sv-who { flex: 1 1 auto; }

/* Places imported from OpenStreetMap */
.badge.unverified { background: color-mix(in srgb, #D9822B 16%, transparent); color: #A85A12; }
.osm-note { margin: 6px 0 0; }
.map-private { margin: 0 0 10px; font-size: .85rem; color: var(--muted, inherit); }
.more-btn { display: block; margin: 12px auto 0; }
.loc-steps { margin: 0; padding-inline-start: 20px; display: grid; gap: 6px; line-height: 1.7; }

/* Sponsored posts in the feed */
.ad-post .meta { font-weight: 600; }
.ad-art { display: grid; place-items: center; aspect-ratio: 4 / 3; font-size: 5.5rem; text-decoration: none; margin-top: 10px; }
.ad-cta { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 22px; background: var(--surface-2); color: var(--text); text-decoration: none; font-size: .92rem; }
.ad-cta-btn { display: inline-flex; align-items: center; gap: 4px; flex: none; padding: 8px 14px; border-radius: 999px; background: var(--grad); color: var(--on-primary); font-weight: 700; font-size: .85rem; }
.post-place { display: inline-flex; align-items: center; gap: 4px; margin: 2px 22px 0; font-size: .88rem; color: var(--primary-text); text-decoration: none; font-weight: 600; }

/* Desktop: the app's own look, laid out like a social site on a computer. The menu sits in a side column
   and pages keep the phone-width column, so cards and text don't stretch across a wide screen. */
@media (min-width: 900px) {
  :root { --side-w: 244px; }
  body { padding-inline-start: var(--side-w); }
  .topbar {
    position: fixed; top: 0; bottom: 0; inset-inline-start: 0; width: var(--side-w); box-sizing: border-box;
    flex-direction: column; align-items: stretch; gap: 0; padding: 24px 14px 20px;
    border-bottom: 0; border-inline-end: 1px solid var(--line); background: var(--bg); backdrop-filter: none; overflow-y: auto;
  }
  .brand { padding: 0 6px 22px; }
  .topnav { flex-direction: column; gap: 4px; margin: 0; }
  .topnav a { padding: 12px 14px; font-size: 1rem; gap: 12px; }
  .topnav a .ic { width: 22px; height: 22px; }
  .topnav a:hover { background: var(--surface-2); color: var(--text); }
  .topnav a.active:hover { color: var(--primary-text); }
  .top-actions { margin: auto 0 0; padding-top: 18px; justify-content: center; }
  #view { max-width: 660px; padding: 28px 24px 48px; }
  .feed-layout { grid-template-columns: minmax(0, 1fr); }
  .side { display: none; }
  #view:has(.map) { max-width: 980px; }
  .fab { inset-inline-start: auto; inset-inline-end: 32px; bottom: 32px; }
  #toast { left: calc(50% + var(--side-w) / 2); }
  html[dir="rtl"] #toast { left: calc(50% - var(--side-w) / 2); }
}
/* Wide screens: the feed gets a side column next to it, like Instagram's suggestions. */
@media (min-width: 1240px) {
  #view:has(.feed-layout) { max-width: 1020px; }
  .feed-layout { grid-template-columns: minmax(0, 620px) 320px; justify-content: center; gap: 36px; }
  .side { display: grid; }
}
@media (min-width: 900px) { body.gate { padding-inline-start: 0; } body.gate #view { max-width: 1100px; } }

/* Group chats */
.group-av { display: grid; place-items: center; background: var(--peach); font-size: 1.3rem; }
.head-links { display: inline-flex; gap: 14px; align-items: center; }
.head-links .link { background: none; border: 0; padding: 0; font: inherit; cursor: pointer; color: var(--primary-text); font-weight: 700; }
button.chat-who { border: 0; background: none; font: inherit; color: inherit; text-align: start; cursor: pointer; padding: 0; }
.group-chat .msg-wrap { max-width: 78%; display: grid; }
.group-chat .bubble-row.me .msg-wrap { justify-items: end; }
.group-chat .msg { max-width: 100%; }
.msg-from { font-size: .78rem; font-weight: 700; color: var(--primary-text); margin: 0 10px 2px; }
.group-join-bar { position: sticky; bottom: calc(var(--nav-h) + 8px + env(safe-area-inset-bottom)); display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 18px; background: var(--surface); border: 1px solid var(--line); }
@media (min-width: 900px) { .group-join-bar { bottom: 12px; } }
.group-invite { display: grid; justify-items: center; gap: 8px; text-align: center; padding: 28px 20px; }
.group-invite p { margin: 0; }
.group-link { display: grid; gap: 6px; padding: 14px 16px; }
.group-link code { font-size: .78rem; word-break: break-all; padding: 8px 10px; border-radius: 10px; background: var(--surface-2); }
.member-row { padding: 6px 0; gap: 10px; }
.member-row .link { background: none; border: 0; padding: 0; font: inherit; cursor: pointer; color: var(--primary-text); }

/* Map search */
.map-search { position: relative; display: flex; gap: 8px; margin: 0 0 10px; }
.map-search .input { flex: 1; min-width: 0; }
.map-search .btn { flex: none; }
.map-results { position: absolute; z-index: 700; top: calc(100% + 6px); inset-inline: 0; max-height: 60vh; overflow-y: auto; padding: 6px; background: var(--surface); border: 1px solid var(--line); border-radius: 18px; box-shadow: 0 12px 30px rgba(60, 40, 20, .14); }
.map-results[hidden] { display: none; }
.map-result { display: flex; align-items: center; gap: 10px; width: 100%; padding: 10px 12px; border: 0; border-radius: 12px; background: none; font: inherit; color: var(--text); text-align: start; cursor: pointer; }
.map-result:hover, .map-result:focus-visible { background: var(--surface-2); }
.map-result b { display: block; }
.map-result .small { display: block; }
.mr-ic { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 12px; background: var(--peach); flex: none; }
.mr-head { padding: 8px 12px 4px; font-size: .78rem; font-weight: 800; color: var(--muted); }
.mr-note { margin: 0; padding: 8px 12px; }
.pin.found .bubble { box-shadow: 0 0 0 4px rgba(242, 194, 48, .45); }

/* Install the app */
.install-card { display: flex; align-items: center; gap: 12px; margin-top: 14px; padding: 12px 14px; }
.install-ic { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 14px; background: var(--grad-tile); color: var(--on-primary); flex: none; }
.install-ic .ic { stroke-width: 2; }
.install-x { flex: none; }
.install-preview { display: grid; justify-items: center; gap: 6px; margin-bottom: 6px; }
.install-preview img { border-radius: 15px; box-shadow: 0 6px 16px rgba(0,0,0,.12); }
@media (max-width: 420px) { .install-card { flex-wrap: wrap; } .install-card .grow { flex: 1 1 60%; } }

/* Pets allowed in a park */
.pets-card { display: grid; gap: 6px; padding: 14px 16px; margin-top: 12px; }
.pets-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.pets-vote { display: flex; gap: 8px; flex-wrap: wrap; }
.pets-vote .btn.on { background: var(--primary); color: var(--on-primary); border-color: transparent; }
.badge.pets-yes, .badge.pets-leash { background: color-mix(in srgb, #3E9B5B 16%, transparent); color: #2C7A45; }
.badge.pets-no { background: color-mix(in srgb, #C8433A 15%, transparent); color: #A8322A; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .badge.pets-yes, :root:not([data-theme="light"]) .badge.pets-leash { color: #8FD3A3; } :root:not([data-theme="light"]) .badge.pets-no { color: #F0A29B; } }
:root[data-theme="dark"] .badge.pets-yes, :root[data-theme="dark"] .badge.pets-leash { color: #8FD3A3; }
:root[data-theme="dark"] .badge.pets-no { color: #F0A29B; }

/* New members strip on the home feed */
.newbies { display: flex; align-items: center; gap: 12px; margin: 12px 0 4px; padding: 10px 16px; border-radius: 999px; background: var(--peach); color: inherit; text-decoration: none; }
.newbie-stack { display: flex; flex: none; }
.newbie-stack .avatar { width: 38px; height: 38px; font-size: 1.15rem; border: 2px solid var(--peach); background: var(--surface); }
.newbie-stack .avatar + .avatar { margin-inline-start: -12px; }
.newbie-text { flex: 1; min-width: 0; display: grid; gap: 1px; }
.newbie-text b { font-size: .95rem; }
.newbie-text .small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.newbies .newbie-go { flex: none; color: var(--primary-text); }
html[dir="rtl"] .newbie-go { transform: scaleX(-1); }

/* Verify identity card on your profile */
.verify-card { display: grid; gap: 8px; padding: 14px 16px; margin-top: 12px; }
.verify-card .doc { border: 1.5px dashed var(--line, #ddd); padding: 10px 12px; }

/* Places import in progress */
.spinner.sm { width: 18px; height: 18px; border-width: 2.5px; display: inline-block; vertical-align: -3px; }
.btn .spinner.sm { border-color: rgba(255,255,255,.4); border-top-color: #fff; }
.adm-busy { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 12px; background: var(--surface-2); font-size: .9rem; }
.adm-url { font-size: .72rem; word-break: break-all; resize: none; }

/* Unread count on the bell and the Messages tab: red, ringed in the bar's own colour so it reads in light and dark */
.pill-btn { position: relative; }
.pill-btn .bell-count { top: -5px; inset-inline-end: -5px; }
.count { box-shadow: 0 0 0 2px var(--surface); line-height: 16px; text-align: center; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .count { background: #F0625A; } }
:root[data-theme="dark"] .count { background: #F0625A; }

/* Community rules and banned accounts */
.rules-list { margin: 4px 0; padding-inline: 30px 8px; display: grid; gap: 18px; }
.rules-list li { line-height: 1.9; padding-inline-start: 4px; }
.rules-list li::marker { font-weight: 700; color: var(--muted); }
.rules-list b { display: block; margin-bottom: 4px; }
.rules-list span { color: var(--muted); font-size: .93em; }
.rules-ban { margin: 0; padding: 14px 16px; border-radius: 12px; background: color-mix(in srgb, var(--danger) 10%, transparent); color: var(--danger); font-size: .93em; line-height: 1.6; }
.rules-card { display: grid; gap: 16px; padding: 22px 20px; }
.badge.danger { background: color-mix(in srgb, var(--danger) 14%, transparent); color: var(--danger); }
.banned-card { text-align: center; display: grid; gap: 10px; justify-items: center; }
.rules-list.fa-num { list-style-type: persian; }

/* Emoji picker under captions */
.emoji-bar { display: grid; gap: 6px; margin-top: -4px; }
.emoji-toggle { justify-self: start; }
.emoji-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(40px, 1fr)); gap: 2px; max-height: 176px; overflow-y: auto; padding: 6px; border: 1px solid var(--line); border-radius: 14px; }
.emoji-grid[hidden] { display: none; }
.emoji-grid button { font-size: 22px; line-height: 1; padding: 8px 0; border: 0; background: none; border-radius: 10px; cursor: pointer; }
.emoji-grid button:active, .emoji-grid button:hover { background: color-mix(in srgb, var(--muted) 14%, transparent); }

/* Photos: hold to see large; no save menu on phones */
#view img, #view video, .sv img, .peek img { -webkit-touch-callout: none; -webkit-user-select: none; user-select: none; -webkit-user-drag: none; }
body:has(.peek) { overflow: hidden; }
.peek { position: fixed; inset: 0; z-index: 1000; display: grid; place-items: center; padding: 16px; background: rgba(0, 0, 0, .78); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); animation: peek-in .14s ease-out; touch-action: none; }
.peek img { max-width: 100%; max-height: 86vh; border-radius: 18px; object-fit: contain; box-shadow: 0 12px 40px rgba(0, 0, 0, .45); pointer-events: none; }
@keyframes peek-in { from { opacity: 0; transform: scale(.94); } }
.more-comments { justify-self: start; border: 0; background: none; padding: 2px 0; color: var(--muted); font: inherit; font-size: .9em; font-weight: 600; cursor: pointer; }
.profile-btns { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-top: 10px; } .profile-btns .edit-btn { margin-top: 0; }
.gear-btn { padding-inline: 10px; font-size: 1.05rem; }
/* Things waiting for the team, on the logo and in the bell */
.logo-btn { position: relative; overflow: visible; }
.logo-count { top: -5px; inset-inline-end: -5px; }
.adm-todo { color: inherit; text-decoration: none; }

/* Chat: photos and videos, replies, pinned message */
.msg.has-media { padding: 4px; overflow: hidden; }
.msg.has-media .msg-text { padding: 6px 10px 4px; }
.msg[data-mid] { cursor: pointer; }
.msg-media { display: block; width: min(260px, 62vw); max-height: 340px; object-fit: cover; border-radius: 16px; background: var(--surface-2); }
.msg-quote { display: grid; gap: 1px; width: 100%; margin: 0 0 6px; padding: 6px 10px; border: 0; border-inline-start: 3px solid currentColor; border-radius: 10px; background: color-mix(in srgb, currentColor 10%, transparent); color: inherit; font: inherit; font-size: .85em; text-align: start; cursor: pointer; }
.msg.has-media .msg-quote { margin: 2px 2px 6px; width: calc(100% - 4px); }
.msg-quote span { opacity: .85; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 240px; }
.msg.flash { outline: 3px solid var(--primary); outline-offset: 2px; }
.pin-bar { position: sticky; top: 0; z-index: 3; display: flex; align-items: center; gap: 6px; padding: 6px 10px; margin-bottom: 8px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); }
.pin-jump { display: flex; align-items: center; gap: 8px; min-width: 0; border: 0; background: none; color: inherit; font: inherit; text-align: start; cursor: pointer; padding: 2px; }
.pin-jump > span { display: grid; min-width: 0; }
.pin-jump .small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--muted); }
.compose-bar { position: sticky; bottom: calc(var(--nav-h) + 70px + env(safe-area-inset-bottom)); display: flex; align-items: center; gap: 10px; padding: 8px 12px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); margin-top: 6px; }
@media (min-width: 900px) { .compose-bar { bottom: 66px; } }
.compose-bar .grow { display: grid; min-width: 0; }
.compose-bar .small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cb-thumb { width: 44px; height: 44px; border-radius: 10px; object-fit: cover; display: grid; place-items: center; background: var(--surface-2); font-size: 1.3rem; flex: none; }
.attach-btn { flex: none; padding-inline: 12px; font-size: 1.15rem; cursor: pointer; }
.app-menu .menu-link { display: flex; align-items: center; gap: 8px; width: 100%; padding: 11px 14px; border-radius: 12px; color: var(--text); text-decoration: none; line-height: 1.4; box-sizing: border-box; }
.app-menu .menu-link:hover, .app-menu .menu-link:focus-visible { background: var(--surface-2); }

/* Pull to refresh */
.ptr { position: fixed; top: calc(env(safe-area-inset-top, 0px) + 4px); left: 50%; z-index: 900; display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: var(--surface); border: 1px solid var(--line); box-shadow: 0 6px 18px rgba(0, 0, 0, .12); opacity: 0; transform: translate(-50%, 0); pointer-events: none; transition: opacity .15s; }
.ptr .spinner { animation-play-state: paused; }
.ptr.ready .spinner, .ptr.spin .spinner { animation-play-state: running; }
.review-banner { display: flex; align-items: center; gap: 12px; margin-top: 14px; padding: 12px 14px; color: inherit; text-decoration: none; border: 1px solid color-mix(in srgb, var(--primary) 35%, var(--line)); background: var(--peach); }
.care-edit { font-size: 15px; padding: 6px; opacity: .75; } .care-del { color: var(--danger, #c0392b); align-self: flex-start; }
.story-preview.se-frame { position: relative; display: block; aspect-ratio: 9 / 16; max-height: none; width: min(100%, 300px); margin: 0 auto; touch-action: none; user-select: none; -webkit-user-select: none; cursor: grab; }
.se-img { position: absolute; top: 0; left: 0; max-width: none; transform-origin: 0 0; pointer-events: none; }
.se-text { position: absolute; transform: translate(-50%, -50%); width: 86%; text-align: center; font-weight: 700; line-height: 1.3; overflow-wrap: anywhere; cursor: move; padding: 4px; border: 1px dashed rgba(255,255,255,.6); border-radius: 8px; }
.se-tools { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 10px; }
.se-zoom { display: flex; align-items: center; gap: 6px; flex: 1; }
.se-zoom input { flex: 1; accent-color: var(--primary); }
.se-colors { display: flex; gap: 8px; }
.se-color { width: 30px; height: 30px; border-radius: 50%; border: 2px solid var(--line); cursor: pointer; padding: 0; }
.se-color.on { outline: 3px solid var(--primary); outline-offset: 2px; }
/* Full-screen story editor (Instagram-style) */
.se-full { position: fixed; inset: 0; z-index: 1000; background: #000; display: grid; place-items: center; color: #fff; touch-action: none; }
.se-stage { position: relative; width: min(100vw, calc(100dvh * 9 / 16)); aspect-ratio: 9 / 16; overflow: hidden; border-radius: 18px; background: #111; touch-action: none; user-select: none; -webkit-user-select: none; }
@media (max-width: 600px) { .se-stage { border-radius: 0; } }
.se-stage .se-img { position: absolute; top: 0; left: 0; max-width: none; pointer-events: none; }
.se-stage .se-text { position: absolute; width: 86%; text-align: center; font-weight: 700; line-height: 1.3; white-space: pre-wrap; overflow-wrap: anywhere; cursor: move; border: 0; padding: 0; }
.se-round { position: absolute; width: 46px; height: 46px; border-radius: 50%; border: 0; background: rgba(0,0,0,.45); color: #fff; font-size: 1.25rem; font-weight: 700; cursor: pointer; display: grid; place-items: center; z-index: 3; }
.se-x { top: max(14px, env(safe-area-inset-top)); left: 14px; }
.se-side { position: absolute; top: max(14px, env(safe-area-inset-top)); right: 14px; display: flex; flex-direction: column; align-items: center; gap: 14px; z-index: 3; }
.se-side .se-round { position: static; font-family: Georgia, serif; }
.se-colors { display: flex; flex-direction: column; gap: 12px; }
.se-colors .se-color { width: 30px; height: 30px; border-radius: 50%; border: 2px solid #fff; cursor: pointer; padding: 0; }
.se-colors .se-color.on { outline: 3px solid #fff; outline-offset: 2px; transform: scale(1.1); }
.se-done { position: absolute; top: max(18px, env(safe-area-inset-top)); left: 50%; transform: translateX(-50%); z-index: 3; border: 0; background: #fff; color: #111; font-weight: 700; padding: 8px 20px; border-radius: 99px; cursor: pointer; }
.se-typing { position: absolute; inset: 0; z-index: 2; background: rgba(0,0,0,.45); display: grid; place-items: center; }
.se-typing textarea { width: 86%; max-width: 420px; background: transparent; border: 0; outline: 0; resize: none; text-align: center; font: 700 1.8rem/1.3 Vazirmatn, Tahoma, sans-serif; caret-color: #fff; }
.se-typing textarea::placeholder { color: rgba(255,255,255,.6); }
.se-bottom { position: absolute; left: 0; right: 0; bottom: 0; z-index: 3; padding: 12px 14px max(14px, env(safe-area-inset-bottom)); background: linear-gradient(transparent, rgba(0,0,0,.7)); display: grid; gap: 10px; }
.se-pets { display: flex; gap: 8px; overflow-x: auto; }
.se-chip { flex: none; border: 1px solid rgba(255,255,255,.5); background: rgba(0,0,0,.35); color: #fff; border-radius: 99px; padding: 6px 12px; font: inherit; font-size: .85rem; cursor: pointer; }
.se-chip.on { background: #fff; color: #111; }
.se-row { display: flex; align-items: center; gap: 10px; }
.se-rule { flex: 1; display: flex; gap: 8px; align-items: center; font-size: .8rem; line-height: 1.4; background: rgba(0,0,0,.4); padding: 8px 12px; border-radius: 99px; }
.se-rule.shake { animation: se-shake .4s; }
@keyframes se-shake { 25% { transform: translateX(-6px); } 75% { transform: translateX(6px); } }
.se-share { flex: none; width: 52px; height: 52px; border-radius: 50%; border: 0; background: var(--primary); color: #fff; font-size: 1.5rem; cursor: pointer; }
.se-full [hidden] { display: none !important; }
.bday-banner { display: flex; gap: 12px; align-items: flex-start; margin-top: 14px; padding: 12px 14px; background: linear-gradient(135deg, #FFF1D6, #FCE1EC); color: #3a2a1a; } .bday-banner a { color: inherit; text-decoration: none; }
.soon-card { padding: 28px 20px; text-align: center; display: flex; flex-direction: column; align-items: center; gap: 6px; margin-top: 12px; }
.soon-card .big { font-size: 2.4rem; }
.soon-card p { margin: 0; line-height: 1.9; }
.viewas-bar { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin: 8px 0 12px; padding: 10px 14px; border-radius: 16px; background: color-mix(in srgb, #E0A800 18%, var(--surface)); color: #6B4E00; font-weight: 600; font-size: .9rem; }
:root[data-theme="dark"] .viewas-bar { color: #F5D77A; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .viewas-bar { color: #F5D77A; } }

/* Service subscriptions */
.sub-card { display: grid; gap: 8px; }
.sub-card.on { border: 1.5px solid #E0A800; }
.sub-card h3 { margin: 0; font-size: 1.05rem; }
.sub-card ul { margin: 0; padding-inline-start: 20px; display: grid; gap: 2px; font-size: .92rem; }
.kv { display: flex; justify-content: space-between; gap: 10px; font-size: .95rem; }
.lbl { font-size: .85rem; font-weight: 600; color: var(--muted); }
.sub-seg { display: flex; width: 100%; }
.sub-seg button { flex: 1; }
.sub-price { font-weight: 800; font-size: 1.1rem; }
.sub-price .muted { font-weight: 400; font-size: .85rem; }
.sub-gift { color: #2E7D32; font-weight: 600; font-size: .9rem; }
.note { background: var(--hero); border-radius: 14px; padding: 10px 12px; font-size: .88rem; line-height: 1.8; }
.sub-total { border-top: 1px dashed var(--line); padding-top: 8px; font-weight: 800; }
.sub-code, .sub-ref .row { display: flex; gap: 8px; align-items: center; }
.sub-code .input, .sub-ref .input { flex: 1; min-width: 0; }
.sub-up { display: grid; place-items: center; gap: 4px; padding: 22px 12px; border: 2px dashed var(--line); border-radius: 16px; cursor: pointer; text-align: center; color: var(--muted); }
.adm-plan { border: 1px solid var(--line); border-radius: 14px; padding: 10px 12px; display: grid; gap: 8px; min-width: 0; }
.adm-plan legend { font-weight: 700; padding: 0 6px; }
.ok-row.chk { grid-template-columns: auto minmax(0, 1fr); }
