/* ── Fonte de ícones — Material Symbols Rounded (auto-hospedada) ────────── */
@font-face {
  font-family: 'Material Symbols Rounded';
  font-style:  normal;
  font-weight: 100 700;
  font-display: block;
  src: url('/assets/fonts/ms-rounded/MaterialSymbolsRounded.woff2') format('woff2');
}

/* ── Variáveis — Tema Claro (Xiglute Official) ─────────────────────────── */
:root {
  /* Cores da logomarca Xiglute */
  --primary:        #4da2c5;
  --primary-dark:   #3a7d99;
  --primary-darker: #4e7280;
  --primary-light:  #e8f4f9;
  --primary-mid:    #49acd5;
  --accent:         #1871b5;
  --accent-light:   #e3eef9;

  /* Backgrounds */
  --bg:             #f4f6f8;
  --surface:        #ffffff;
  --surface2:       #f9fafb;
  --surface3:       #eef2f5;

  /* Bordas e divisores */
  --border:         #dde3e9;
  --divider:        #eaecef;

  /* Textos */
  --text:           #1a1a2e;
  --text2:          #4a5568;
  --text3:          #8896a5;
  --text-on-primary:#ffffff;

  /* Feedback */
  --success:        #4caf50;
  --warning:        #ff9800;
  --error:          #f44336;
  --info:           #2196f3;
  --liked:          #f42738;

  /* Layout */
  --topbar-h:       56px;
  --bottomnav-h:    60px;
  --radius:         14px;
  --radius-sm:      8px;
  --radius-xs:      6px;
  --shadow:         0 2px 10px rgba(77,162,197,.12);
  --shadow-md:      0 4px 16px rgba(77,162,197,.18);
  --shadow-lg:      0 8px 32px rgba(77,162,197,.22);
  --transition:     .2s ease;

  /* Gradiente da marca */
  --gradient:       linear-gradient(135deg, #4da2c5 0%, #1871b5 100%);
  --gradient-dark:  linear-gradient(135deg, #3a7d99 0%, #0f5490 100%);
}

/* ── Tema Escuro ────────────────────────────────────────────────────────── */
[data-theme="dark"] {
  --primary:        #5bb5d8;
  --primary-dark:   #4da2c5;
  --primary-darker: #3a7d99;
  --primary-light:  #0d2a38;
  --primary-mid:    #60bfde;
  --accent:         #4a9fd4;
  --accent-light:   #0d2236;

  --bg:             #0f1419;
  --surface:        #192028;
  --surface2:       #1e2a36;
  --surface3:       #243040;

  --border:         #2a3a4a;
  --divider:        #243040;

  --text:           #e8edf2;
  --text2:          #a0aec0;
  --text3:          #637080;
  --text-on-primary:#ffffff;

  --shadow:         0 2px 10px rgba(0,0,0,.4);
  --shadow-md:      0 4px 16px rgba(0,0,0,.5);
  --shadow-lg:      0 8px 32px rgba(0,0,0,.6);

  --gradient:       linear-gradient(135deg, #2d7a9e 0%, #0f5490 100%);
  --gradient-dark:  linear-gradient(135deg, #1f5a76 0%, #0a3d6b 100%);
}

/* ── Reset & Base ───────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { font-size: 16px; -webkit-text-size-adjust: 100%; }

body {
  font-family: var(--font-body, 'Plus Jakarta Sans', 'Segoe UI', system-ui, sans-serif);
  font-size: 15px;
  font-weight: 400;
  line-height: 1.55;
  letter-spacing: -0.01em;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  overflow-x: hidden;
  transition: background var(--transition), color var(--transition);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a { color: var(--primary); text-decoration: none; }
img { max-width: 100%; display: block; }
button { cursor: pointer; border: none; background: none; font-family: inherit; }
input, textarea, select {
  font-family: inherit;
  font-size: 1rem;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  padding: .75rem 1rem;
  width: 100%;
  outline: none;
  background: var(--surface);
  color: var(--text);
  transition: border-color var(--transition), background var(--transition);
}
input:focus, textarea:focus, select:focus { border-color: var(--primary); }

/* ── Ícones — Material Symbols Rounded (solid/filled, hospedado localmente) */
.xi {
  font-family: 'Material Symbols Rounded';
  font-weight: normal;
  font-style: normal;
  font-size: 24px;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  vertical-align: middle;
  text-transform: none;
  letter-spacing: normal;
  word-wrap: normal;
  white-space: nowrap;
  direction: ltr;
  -webkit-font-smoothing: antialiased;
  font-variation-settings: 'FILL' 1, 'wght' 400, 'GRAD' 0, 'opsz' 24;
}
.xi-home::before        { content: "home"; }
.xi-people::before      { content: "group"; }
.xi-add::before         { content: "add"; }
.xi-chat::before        { content: "chat"; }
.xi-person::before      { content: "person"; }
.xi-search::before      { content: "search"; }
.xi-bell::before        { content: "notifications"; }
.xi-arrow-back::before  { content: "arrow_back"; }
.xi-like::before        { content: "thumb_up"; }
.xi-comment::before     { content: "comment"; }
.xi-share::before       { content: "share"; }
.xi-send::before        { content: "send"; }
.xi-image::before       { content: "image"; }
.xi-video::before       { content: "videocam"; }
.xi-close::before       { content: "close"; }
.xi-more::before        { content: "more_vert"; }
.xi-check::before       { content: "check"; }
.xi-star::before        { content: "star"; }
.xi-moon::before        { content: "dark_mode"; }
.xi-sun::before         { content: "light_mode"; }
.xi-edit::before        { content: "edit"; }
.xi-delete::before      { content: "delete"; }
.xi-music::before       { content: "music_note"; }
.xi-event::before       { content: "event"; }
.xi-store::before       { content: "storefront"; }
.xi-blog::before        { content: "article"; }
.xi-trophy::before      { content: "emoji_events"; }
.xi-location::before    { content: "location_on"; }
.xi-link::before        { content: "link"; }
.xi-photo::before       { content: "photo_camera"; }
.xi-plus::before        { content: "add_circle"; }
.xi-close::before       { content: "close"; }
.xi-send::before        { content: "send"; }
.xi-delete::before      { content: "delete"; }
.xi-hide::before        { content: "visibility_off"; }
.xi-image::before       { content: "image"; }

/* ── Splash ─────────────────────────────────────────────────────────────── */
#splash-screen {
  position: fixed; inset: 0;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  background: var(--gradient);
  z-index: 9999; gap: 2rem;
}
.splash-logo { width: 110px; height: 110px; border-radius: 22px; box-shadow: var(--shadow-lg); }
.splash-spinner {
  width: 40px; height: 40px;
  border: 3px solid rgba(255,255,255,.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin .8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ── Topbar ──────────────────────────────────────────────────────────────── */
.topbar {
  position: fixed; top: 0; left: 0; right: 0;
  height: var(--topbar-h);
  background: var(--gradient);
  color: #fff;
  display: flex; align-items: center; gap: .5rem;
  padding: 0 .5rem;
  z-index: 100;
  box-shadow: var(--shadow-md);
}
.topbar-title {
  flex: 1; font-size: 1.1rem; font-weight: 700;
  padding: 0 .5rem;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  letter-spacing: .02em;
}
.topbar-btn {
  width: 40px; height: 40px;
  border-radius: 50%; color: #fff;
  font-size: 1.15rem;
  display: flex; align-items: center; justify-content: center;
  transition: background var(--transition);
}
.topbar-btn:hover { background: rgba(255,255,255,.18); }
.topbar-actions { display: flex; gap: .25rem; }
.topbar-chat-avatar {
  width: 34px; height: 34px; border-radius: 50%; object-fit: cover;
  flex-shrink: 0; border: 2px solid rgba(255,255,255,.5);
}
.notif-btn { position: relative; }

/* ── Bottom Navigation ───────────────────────────────────────────────────── */
.bottom-nav {
  position: fixed; bottom: 0; left: 0; right: 0;
  height: var(--bottomnav-h);
  background: var(--surface);
  border-top: 1.5px solid var(--border);
  display: flex; align-items: center;
  z-index: 100;
  box-shadow: 0 -2px 12px rgba(0,0,0,.08);
}
.nav-item {
  flex: 1; display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  gap: 2px; color: var(--text3);
  font-size: .62rem; font-weight: 500;
  padding: .25rem 0;
  transition: color var(--transition);
  position: relative; text-decoration: none;
}
.nav-item.active     { color: var(--primary); }
.nav-item.active > i { transform: scale(1.1); }
.nav-item > i        { font-size: 1.25rem; transition: transform var(--transition); }
.nav-create {
  width: 50px; height: 50px;
  background: var(--gradient);
  border-radius: 50%; color: #fff !important;
  flex: none; margin: 0 .5rem;
  box-shadow: 0 4px 16px rgba(77,162,197,.45);
  transition: box-shadow var(--transition), transform var(--transition);
}
.nav-create:active { transform: scale(.94); }

/* ── Page container ──────────────────────────────────────────────────────── */
#page-container {
  padding-top: var(--topbar-h);
  padding-bottom: var(--bottomnav-h);
  min-height: 100vh;
}
/* Quando a rota não tem topbar/nav (login, signup, forgot-password):
   remove o padding e trava o scroll no body */
#page-container:has(.login-page) {
  padding: 0;
  min-height: unset;
  overflow: hidden;
}
body:has(.login-page) {
  overflow: hidden;
}

/* ── Badge ───────────────────────────────────────────────────────────────── */
.badge {
  position: absolute; top: 0; right: 0;
  min-width: 18px; height: 18px;
  background: var(--error); color: #fff;
  font-size: .62rem; font-weight: 700;
  border-radius: 9px;
  display: flex; align-items: center; justify-content: center;
  padding: 0 4px;
}

/* ── Card ────────────────────────────────────────────────────────────────── */
.card {
  background: var(--surface);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden; margin-bottom: .75rem;
  border: 1px solid var(--divider);
  transition: background var(--transition), border-color var(--transition);
}
.card-header { padding: .75rem 1rem; display: flex; align-items: center; gap: .75rem; }
.card-body   { padding: 0 1rem .75rem; }
.card-footer { padding: .5rem 1rem; border-top: 1px solid var(--divider); display: flex; gap: .5rem; }

/* ── Avatar ──────────────────────────────────────────────────────────────── */
.avatar {
  width: 42px; height: 42px; border-radius: 50%;
  object-fit: cover; background: var(--border); flex-shrink: 0;
  border: 2px solid var(--surface);
}
.avatar-lg  { width: 58px; height: 58px; }
.avatar-xl  { width: 80px; height: 80px; }
.avatar-xxl { width: 120px; height: 120px; }

/* ── Button ──────────────────────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .4rem;
  padding: .65rem 1.25rem; border-radius: var(--radius-sm);
  font-size: .9rem; font-weight: 600;
  transition: all var(--transition); cursor: pointer; border: none;
}
.btn-primary   { background: var(--gradient);  color: #fff; box-shadow: 0 2px 8px rgba(77,162,197,.35); }
.btn-primary:hover { background: var(--gradient-dark); box-shadow: 0 4px 12px rgba(77,162,197,.45); }
.btn-outline   { background: transparent; border: 1.5px solid var(--primary); color: var(--primary); }
.btn-outline:hover { background: var(--primary-light); }
.btn-ghost     { background: transparent; color: var(--text2); }
.btn-ghost:hover   { background: var(--surface3); }
.btn-accent    { background: var(--accent); color: #fff; }
.btn-danger    { background: var(--error); color: #fff; }
.btn-sm        { padding: .4rem .85rem; font-size: .8rem; border-radius: var(--radius-xs); }
.btn-block     { width: 100%; }
.btn:disabled  { opacity: .5; cursor: not-allowed; }
.btn:active    { transform: scale(.97); }

/* ── Form ────────────────────────────────────────────────────────────────── */
.form-group  { margin-bottom: 1rem; }
.form-label  { display: block; font-size: .84rem; font-weight: 600; color: var(--text2); margin-bottom: .35rem; }
.form-error  { font-size: .8rem; color: var(--error); margin-top: .25rem; }
.form-hint   { font-size: .8rem; color: var(--text3); margin-top: .25rem; }

/* ── Page helpers ────────────────────────────────────────────────────────── */
.page         { padding: 1rem; }
.page-full    { padding: 0; }
.section-title {
  font-size: .78rem; font-weight: 700; color: var(--text3);
  text-transform: uppercase; letter-spacing: .07em;
  padding: .75rem 1rem .25rem;
}

/* ── Login ───────────────────────────────────────────────────────────────── */
.login-page {
  height: 100dvh;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  padding: 2rem 1.5rem;
  background: var(--gradient);
  position: relative;
  overflow-y: auto;
  overflow-x: hidden;
  box-sizing: border-box;
  scrollbar-width: none;
}
.login-page::-webkit-scrollbar { display: none; }
.login-page::before {
  content: '';
  position: absolute; top: -60px; right: -60px;
  width: 240px; height: 240px;
  border-radius: 50%;
  background: rgba(255,255,255,.08);
}
.login-page::after {
  content: '';
  position: absolute; bottom: -80px; left: -40px;
  width: 280px; height: 280px;
  border-radius: 50%;
  background: rgba(255,255,255,.06);
}
.login-logo {
  width: 88px; height: 88px; border-radius: 20px;
  margin-bottom: 1.5rem; box-shadow: var(--shadow-lg);
  position: relative; z-index: 1;
}
.login-card {
  width: 100%; max-width: 400px;
  background: var(--surface);
  border-radius: var(--radius);
  padding: 2rem;
  box-shadow: var(--shadow-lg);
  position: relative; z-index: 1;
}
.login-title {
  font-size: 1.6rem; font-weight: 800;
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  text-align: center; margin-bottom: .25rem;
}
.login-subtitle {
  text-align: center; color: var(--text2);
  font-size: .88rem; margin-bottom: 1.5rem;
}
.login-divider {
  display: flex; align-items: center; gap: 1rem;
  color: var(--text3); font-size: .78rem; margin: 1.25rem 0;
}
.login-divider::before, .login-divider::after {
  content: ''; flex: 1; height: 1px; background: var(--border);
}
.btn-social {
  display: flex; align-items: center; gap: .75rem;
  padding: .75rem 1rem;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface); color: var(--text);
  font-size: .9rem; font-weight: 600;
  width: 100%; margin-bottom: .75rem;
  transition: background var(--transition), border-color var(--transition);
}
.btn-social:hover { background: var(--primary-light); border-color: var(--primary); }
.btn-social img, .btn-social svg { width: 22px; height: 22px; flex-shrink: 0; }
.login-footer {
  text-align: center; margin-top: 1.25rem;
  font-size: .85rem; color: var(--text2);
}
.login-divider {
  text-align: center; font-size: .78rem; color: var(--text3);
  margin: 1rem 0 .75rem; position: relative;
}
.login-divider::before, .login-divider::after {
  content: ''; position: absolute; top: 50%; width: 38%; height: 1px;
  background: var(--divider);
}
.login-divider::before { left: 0; }
.login-divider::after  { right: 0; }
.login-divider-thin {
  text-align: center; font-size: .78rem; color: var(--text3);
  margin: .75rem 0;
}

/* ── Eye toggle (campo senha) ──────────────────────────────────────────────── */
.input-eye-wrap {
  position: relative;
  display: flex;
  align-items: center;
}
.input-eye-wrap input {
  flex: 1;
  padding-right: 2.6rem;
}
.input-eye-btn {
  position: absolute;
  right: 0;
  top: 0;
  bottom: 0;
  width: 2.6rem;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: none;
  cursor: pointer;
  color: var(--text3);
  border-radius: 0 var(--radius) var(--radius) 0;
  transition: color var(--transition);
}
.input-eye-btn:hover { color: var(--primary); }
.input-eye-btn .ms-icon { font-size: 1.1rem; }

/* ── Form helpers ──────────────────────────────────────────────────────────── */
.form-hint {
  font-size: .76rem;
  color: var(--text3);
  margin-top: .25rem;
  display: block;
}
.form-error {
  font-size: .8rem;
  color: #e55;
  margin-top: .35rem;
}

/* ── Signup — indicador de etapas ──────────────────────────────────────────── */
.signup-steps {
  display: flex;
  gap: .4rem;
  justify-content: center;
  margin-bottom: 1.25rem;
}
.signup-step {
  width: 2rem;
  height: 4px;
  border-radius: 2px;
  background: var(--divider);
  transition: background .3s;
}
.signup-step.active { background: var(--primary); }
.signup-step.done   { background: var(--primary-mid); }

/* ── Signup / ForgotPassword — tela de sucesso ─────────────────────────────── */
.signup-success {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .75rem;
  padding: 1rem 0;
  text-align: center;
}
.signup-success-icon {
  font-size: 3.5rem;
  color: var(--primary);
}

/* ── ForgotPassword — ícone de cadeado ─────────────────────────────────────── */
.fp-icon-wrap {
  display: flex;
  justify-content: center;
  margin-bottom: .75rem;
}
.fp-lock-icon {
  font-size: 2.8rem;
  color: var(--primary);
}

/* ── OTP — grid de dígitos ─────────────────────────────────────────────────── */
.otp-digits {
  display: flex;
  gap: .5rem;
  justify-content: center;
  margin: .5rem 0;
}
.otp-digit {
  width: 3rem;
  height: 3.2rem;
  text-align: center;
  font-size: 1.4rem;
  font-weight: 700;
  border-radius: var(--radius);
  border: 1.5px solid var(--divider);
  background: var(--surface-alt, var(--surface));
  color: var(--text);
  caret-color: var(--primary);
  transition: border-color .2s;
}
.otp-digit:focus {
  outline: none;
  border-color: var(--primary);
}
.otp-ddi-select {
  border-radius: var(--radius);
  border: 1.5px solid var(--divider);
  background: var(--surface);
  color: var(--text);
  padding: 0 .4rem;
  font-size: .9rem;
}

/* ── Feed filter tabs ────────────────────────────────────────────────────── */
.feed-filter-bar {
  display: flex;
  overflow-x: auto;
  gap: .45rem;
  padding: .5rem .75rem;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 56px;
  z-index: 10;
  scrollbar-width: none;
}
.feed-filter-bar::-webkit-scrollbar { display: none; }
.feed-filter-btn {
  flex-shrink: 0;
  padding: .3rem .85rem;
  border-radius: 99px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text2);
  font-size: .8rem;
  cursor: pointer;
  white-space: nowrap;
  transition: background .15s, color .15s, border-color .15s;
}
.feed-filter-btn:hover { background: var(--hover, rgba(0,0,0,.06)); color: var(--text1); }
.feed-filter-btn.active { background: var(--primary); color: #fff; border-color: var(--primary); }

/* ── Feed ────────────────────────────────────────────────────────────────── */
.feed-list { padding: .75rem .75rem 0; }

.post-card {
  background: var(--surface);
  border-radius: var(--radius); margin-bottom: .75rem;
  box-shadow: var(--shadow); overflow: hidden;
  border: 1px solid var(--divider);
  transition: background var(--transition);
}
.post-header { display: flex; align-items: center; gap: .75rem; padding: .8rem; }
.post-meta   { flex: 1; min-width: 0; }
.post-author { font-weight: 700; font-size: .92rem; color: var(--text); cursor: pointer; }
.post-author:hover { color: var(--primary); }
.post-time   { font-size: .73rem; color: var(--text3); margin-top: 1px; }
.post-menu   { padding: .25rem; color: var(--text3); }
.post-body   { padding: 0 .8rem .6rem; font-size: .95rem; line-height: 1.65; word-break: break-word; overflow-wrap: break-word; white-space: pre-line; color: var(--text); }
.post-image  { width: 100%; max-height: 85vh; object-fit: contain; background: var(--surface3); display: block; }
.post-actions { display: flex; border-top: 1px solid var(--divider); }
.action-btn {
  flex: 1; display: flex; align-items: center; justify-content: center; gap: .35rem;
  padding: .6rem; font-size: .84rem; color: var(--text2);
  transition: background var(--transition), color var(--transition);
}
.action-btn:hover { background: var(--surface3); color: var(--primary); }
.action-btn.liked { color: var(--liked); }

/* FILL:1 já é o padrão — "liked" usa peso extra para destaque */
.action-btn.liked .xi-like {
  font-variation-settings: 'FILL' 1, 'wght' 700, 'GRAD' 200, 'opsz' 24;
  filter: drop-shadow(0 0 4px rgba(244,39,56,.35));
}
.action-btn.liked { color: var(--liked); }

/* ── Stories ─────────────────────────────────────────────────────────────── */
.stories-bar {
  display: flex; gap: .75rem;
  padding: .75rem; overflow-x: auto;
  background: var(--surface);
  border-bottom: 1px solid var(--divider);
  scrollbar-width: none;
}
.stories-bar::-webkit-scrollbar { display: none; }
.story-item {
  display: flex; flex-direction: column;
  align-items: center; gap: .25rem; flex-shrink: 0; cursor: pointer;
}
.story-ring {
  width: 62px; height: 62px; border-radius: 50%; padding: 2.5px;
  background: linear-gradient(45deg, #4da2c5, #1871b5, #49acd5);
}
.story-ring.seen { background: var(--border); }
.story-avatar { width: 100%; height: 100%; border-radius: 50%; border: 2.5px solid var(--surface); object-fit: cover; }
.story-name   { font-size: .63rem; color: var(--text2); max-width: 64px; text-align: center; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.story-add    { background: var(--primary-light); border: 2px dashed var(--primary); }

/* ── Profile ─────────────────────────────────────────────────────────────── */
.profile-cover     { width: 100%; height: 170px; object-fit: cover; background: var(--gradient); }
.profile-avatar-wrap { position: relative; margin: -44px 1rem 0; }
.profile-avatar    { width: 88px; height: 88px; border-radius: 50%; border: 3.5px solid var(--surface); box-shadow: var(--shadow-md); object-fit: cover; }
.profile-info      { padding: .5rem 1rem 1rem; }
.profile-name      { font-size: 1.2rem; font-weight: 800; color: var(--text); }
.profile-username  { font-size: .84rem; color: var(--text3); margin-top: 1px; }
.profile-bio       { font-size: .9rem; color: var(--text2); margin-top: .5rem; line-height: 1.45; }
.profile-stats     { display: flex; gap: 1.5rem; margin-top: .85rem; }
.stat-item         { display: flex; flex-direction: column; align-items: center; }
.stat-value        { font-size: 1.1rem; font-weight: 800; color: var(--text); }
.stat-label        { font-size: .68rem; color: var(--text3); text-transform: uppercase; letter-spacing: .04em; }
.profile-actions   { display: flex; gap: .5rem; margin-top: 1rem; }

/* ── Chat lista ──────────────────────────────────────────────────────────── */
.chat-list-header {
  display: flex; align-items: center; gap: .5rem;
  padding: .65rem .75rem .5rem;
  border-bottom: 1px solid var(--divider);
}
.chat-search-input {
  flex: 1; border-radius: 20px;
  padding: .45rem 1rem; font-size: .92rem;
}
.btn-new-group {
  width: 38px; height: 38px; border-radius: 50%;
  background: var(--gradient); color: #fff;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0; border: none; cursor: pointer;
  box-shadow: 0 2px 8px rgba(77,162,197,.3);
  transition: transform var(--transition);
}
.btn-new-group:active { transform: scale(.92); }
.btn-new-group .ms-icon { font-size: 1.1rem; }
.chat-list  { }
.chat-item  {
  display: flex; align-items: center; gap: .75rem;
  padding: .85rem 1rem;
  border-bottom: 1px solid var(--divider);
  background: var(--surface);
  transition: background var(--transition); cursor: pointer;
}
.chat-item:hover   { background: var(--surface2); }
.chat-info         { flex: 1; min-width: 0; }
.chat-name         { font-weight: 700; font-size: .95rem; color: var(--text); }
.chat-preview      { font-size: .82rem; color: var(--text3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-top: 1px; }
.chat-meta         { display: flex; flex-direction: column; align-items: flex-end; gap: .25rem; }
.chat-time         { font-size: .7rem; color: var(--text3); }
.chat-unread       { background: var(--primary); color: #fff; font-size: .68rem; font-weight: 700; min-width: 20px; height: 20px; border-radius: 10px; display: flex; align-items: center; justify-content: center; padding: 0 4px; }

/* ── Chat conversa ───────────────────────────────────────────────────────── */
.chat-messages {
  padding: .75rem; display: flex; flex-direction: column;
  gap: .35rem; padding-bottom: 120px; /* room for input + reply/typing bars */
}
/* Wrapper de alinhamento */
.msg-wrap    { display: flex; justify-content: flex-start; }
.msg-wrap-me { justify-content: flex-end; }
.msg-bubble {
  max-width: 76%; padding: .55rem .9rem;
  border-radius: 18px; font-size: .92rem;
  line-height: 1.45; word-break: break-word;
}
.msg-out {
  background: var(--gradient); color: #fff;
  border-bottom-right-radius: 4px;
  box-shadow: 0 2px 6px rgba(77,162,197,.3);
}
.msg-in {
  background: var(--surface); color: var(--text);
  border-bottom-left-radius: 4px;
  box-shadow: var(--shadow); border: 1px solid var(--divider);
}
/* Footer: hora + ações */
.msg-footer { display: flex; align-items: center; justify-content: flex-end; gap: .3rem; margin-top: .2rem; }
.msg-time   { font-size: .63rem; opacity: .7; white-space: nowrap; }
.msg-edited { font-size: .6rem; opacity: .65; font-style: italic; }
.msg-img    { max-width: 200px; border-radius: 10px; margin-top: .35rem; display: block; }
.msg-status { display: inline-flex; align-items: center; line-height: 1; }
.msg-status .ms-icon { font-size: 14px; }
.msg-status-sending  .ms-icon { color: rgba(255,255,255,.45); }
.msg-status-sent     .ms-icon { color: rgba(255,255,255,.65); }
.msg-status-delivered .ms-icon { color: rgba(255,255,255,.65); }
.msg-status-read     .ms-icon { color: #64b5f6; }
/* Ações editar/excluir/responder */
.msg-acts { display: flex; gap: .05rem; opacity: 0; transition: opacity .15s; }
.msg-wrap:hover .msg-acts,
.msg-wrap-me:hover .msg-acts,
.msg-wrap:focus-within .msg-acts,
.msg-wrap-me:focus-within .msg-acts { opacity: 1; }
.msg-act-btn {
  background: none; border: none; cursor: pointer;
  padding: .1rem .15rem; border-radius: 4px;
  color: rgba(255,255,255,.65); line-height: 1; font-size: .85rem;
}
.msg-act-btn .ms-icon { font-size: .85rem; }
.msg-act-btn:hover { background: rgba(255,255,255,.18); color: #fff; }
/* Mensagem não-própria: botões em tom escuro */
.msg-in .msg-act-btn { color: var(--text3); }
.msg-in .msg-act-btn:hover { background: var(--surface3); color: var(--text); }
/* Reply quote dentro do bubble */
.msg-reply-quote {
  border-left: 3px solid rgba(255,255,255,.5);
  padding: .2rem .5rem; margin-bottom: .35rem;
  font-size: .78rem; opacity: .8;
  background: rgba(0,0,0,.12); border-radius: 4px;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.msg-in .msg-reply-quote { border-left-color: var(--primary); background: var(--surface3); opacity: .9; }
/* Sender name (grupos) */
.msg-sender { font-size: .73rem; font-weight: 600; color: var(--primary); margin-bottom: .2rem; }
/* Typing indicator — sits directly above .chat-reply-bar or .chat-input-bar */
.chat-typing-bar {
  position: fixed; bottom: calc(var(--bottomnav-h) + 56px); left: 0; right: 0;
  max-width: 600px; margin: 0 auto;
  display: flex; align-items: center; gap: .5rem;
  padding: .3rem .75rem;
  background: var(--surface); border-top: 1px solid var(--border);
  z-index: 98; font-size: .82rem; color: var(--text3);
}
.chat-typing-bar.hidden { display: none; }
.typing-dots { display: inline-flex; gap: 3px; align-items: center; }
.typing-dots span {
  width: 6px; height: 6px; border-radius: 50%; background: var(--text3);
  animation: typingBounce 1.2s infinite; display: block;
}
.typing-dots span:nth-child(2) { animation-delay: .2s; }
.typing-dots span:nth-child(3) { animation-delay: .4s; }
@keyframes typingBounce {
  0%, 80%, 100% { transform: translateY(0); opacity: .5; }
  40%            { transform: translateY(-5px); opacity: 1; }
}
/* Reply bar — sits directly above .chat-input-bar */
.chat-reply-bar {
  position: fixed; bottom: calc(var(--bottomnav-h) + 56px); left: 0; right: 0;
  max-width: 600px; margin: 0 auto;
  display: flex; align-items: center; gap: .5rem;
  padding: .4rem .75rem;
  background: var(--surface2); border-top: 2px solid var(--primary);
  z-index: 99;
}
.chat-reply-bar.hidden { display: none; }
.reply-preview-inner { flex: 1; display: flex; align-items: center; gap: .4rem; min-width: 0; }
.reply-preview-text { font-size: .82rem; color: var(--text2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.reply-cancel-btn { background: none; border: none; cursor: pointer; color: var(--text3); padding: .2rem; line-height: 1; }
/* Presence status in topbar */
.chat-status-text { font-size: .72rem; color: var(--text3); font-weight: 400; }
.chat-status-text.online { color: #4caf50; }
/* Reactions below bubble */
.msg-reactions {
  display: flex; flex-wrap: wrap; gap: .3rem;
  margin-top: .2rem; padding: 0 .25rem;
}
.reaction-btn {
  display: inline-flex; align-items: center; gap: .25rem;
  background: var(--surface2); border: 1.5px solid var(--border);
  border-radius: 20px; padding: .15rem .45rem;
  font-size: .85rem; cursor: pointer; transition: background .15s;
  line-height: 1.4;
}
.reaction-btn.reacted { background: rgba(77,162,197,.18); border-color: var(--primary); }
.reaction-btn:hover { background: var(--surface3); }
.reaction-count { font-size: .7rem; color: var(--text2); }
.reaction-add-btn {
  background: none; border: 1.5px dashed var(--border);
  border-radius: 20px; padding: .15rem .35rem;
  cursor: pointer; color: var(--text3); display: inline-flex; align-items: center;
  transition: border-color .15s;
}
.reaction-add-btn:hover { border-color: var(--primary); color: var(--primary); }
/* Quick reaction picker */
.reaction-picker {
  display: flex; gap: .3rem; flex-wrap: wrap;
  background: var(--surface2); border: 1px solid var(--border);
  border-radius: 24px; padding: .35rem .5rem;
  box-shadow: var(--shadow-md); z-index: 200;
  position: relative; margin: .25rem 0;
}
.reaction-picker button {
  background: none; border: none; font-size: 1.4rem;
  cursor: pointer; border-radius: 50%; padding: .2rem;
  transition: transform .12s;
}
.reaction-picker button:hover { transform: scale(1.4); }
/* Link preview inside chat bubble */
.link-preview {
  display: block; text-decoration: none;
  border: 1px solid rgba(255,255,255,.15); border-radius: 8px;
  overflow: hidden; margin-top: .5rem; background: rgba(0,0,0,.18);
  transition: opacity .15s;
}
.link-preview:hover { opacity: .88; }
.msg-in .link-preview { border-color: var(--border); background: var(--surface3); }
.link-preview-img { width: 100%; max-height: 140px; object-fit: cover; display: block; }
.link-preview-body { padding: .4rem .55rem; }
.link-preview-site { font-size: .65rem; text-transform: uppercase; letter-spacing: .05em; opacity: .7; }
.link-preview-title { font-size: .82rem; font-weight: 600; margin: .1rem 0; color: inherit; }
.link-preview-desc { font-size: .75rem; opacity: .75; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
/* Group avatar in list */
.group-avatar {
  width: 42px; height: 42px; border-radius: 50%;
  background: var(--primary); color: #fff;
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
/* Chat section labels */
.chat-section-label {
  padding: .45rem .85rem .2rem;
  font-size: .72rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: .07em; color: var(--text3);
}
/* Inline edit */
.msg-edit-ta {
  width: 100%; border: none; outline: none; resize: none;
  background: rgba(255,255,255,.15); color: #fff;
  border-radius: 8px; padding: .35rem .5rem;
  font-size: .92rem; line-height: 1.45; min-height: 3rem;
}
.msg-edit-btns {
  display: flex; gap: .4rem; justify-content: flex-end; margin-top: .4rem;
}
/* Emoji picker */
.emoji-picker {
  position: fixed; bottom: calc(var(--bottomnav-h) + 56px); left: 0; right: 0;
  max-width: 600px; margin: 0 auto;
  background: var(--surface2); border-top: 1.5px solid var(--border);
  display: grid; grid-template-columns: repeat(8, 1fr);
  padding: .5rem; gap: .15rem;
  max-height: 220px; overflow-y: auto;
  z-index: 200;
  animation: slideUp .18s ease;
}
@keyframes slideUp { from { transform: translateY(100%); opacity: 0; } to { transform: none; opacity: 1; } }
.emoji-btn {
  background: none; border: none; cursor: pointer;
  font-size: 1.45rem; padding: .3rem; border-radius: 8px;
  line-height: 1; transition: background .1s;
  display: flex; align-items: center; justify-content: center;
}
.emoji-btn:hover { background: var(--surface3); }
/* Input bar */
.chat-input-bar {
  position: fixed; bottom: var(--bottomnav-h); left: 0; right: 0;
  background: var(--surface); border-top: 1.5px solid var(--border);
  padding: .5rem; display: flex; align-items: flex-end; gap: .5rem;
  z-index: 100;
}
.chat-input-bar textarea {
  flex: 1; resize: none; border-radius: 22px;
  padding: .55rem 1rem; max-height: 120px;
  line-height: 1.4; font-size: .95rem;
}
.btn-send {
  width: 42px; height: 42px;
  background: var(--gradient); color: #fff;
  border-radius: 50%; display: flex; align-items: center; justify-content: center;
  font-size: 1rem; flex-shrink: 0;
  box-shadow: 0 2px 8px rgba(77,162,197,.35);
  transition: transform var(--transition);
}
.btn-send:active { transform: scale(.92); }

/* ── Toast ───────────────────────────────────────────────────────────────── */
#toast-container {
  position: fixed; bottom: calc(var(--bottomnav-h) + 1rem);
  left: 50%; transform: translateX(-50%);
  z-index: 9998; display: flex; flex-direction: column; gap: .5rem;
  pointer-events: none; width: max-content; max-width: 92vw;
}
.toast {
  background: #1a2a3a; color: #e8edf2;
  padding: .75rem 1.25rem; border-radius: var(--radius-sm);
  font-size: .875rem;
  animation: toastIn .3s ease, toastOut .3s ease 2.7s forwards;
  pointer-events: auto;
  border-left: 3px solid var(--primary);
  box-shadow: var(--shadow-md);
}
.toast.success { border-left-color: var(--success); }
.toast.error   { border-left-color: var(--error); }
@keyframes toastIn  { from { opacity:0; transform:translateY(20px); } to { opacity:1; transform:translateY(0); } }
@keyframes toastOut { to   { opacity:0; transform:translateY(20px); } }

/* ── Modal ───────────────────────────────────────────────────────────────── */
.modal-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,.55);
  z-index: 200; animation: fadeIn .2s ease;
}
.modal-container {
  position: fixed; bottom: 0; left: 0; right: 0;
  background: var(--surface); border-radius: var(--radius) var(--radius) 0 0;
  z-index: 220; animation: slideUp .3s ease;
  max-height: 90vh; overflow-y: auto;
  border-top: 1px solid var(--border);
}
@keyframes fadeIn  { from { opacity: 0; } }
@keyframes slideUp { from { transform: translateY(100%); } }

/* ── Loader ──────────────────────────────────────────────────────────────── */
.loader {
  display: flex; align-items: center; justify-content: center;
  padding: 3rem 1rem;
}
#feed-load-more {
  display: flex; justify-content: center; align-items: center;
  padding: 1.25rem 0 2rem;
}
#feed-load-more[hidden] { display: none; }
.spinner {
  width: 36px; height: 36px;
  border: 3px solid var(--border);
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin .8s linear infinite;
}
.skeleton {
  background: linear-gradient(90deg, var(--surface3) 25%, var(--border) 50%, var(--surface3) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  border-radius: var(--radius-sm);
}
@keyframes shimmer { to { background-position: -200% 0; } }

/* ── Avatar sm ───────────────────────────────────────────────────────────── */
.avatar-sm { width: 32px; height: 32px; border-radius: 50%; object-fit: cover; flex-shrink: 0; border: 1.5px solid var(--surface); }

/* ── Icon button ─────────────────────────────────────────────────────────── */
.icon-btn {
  width: 32px; height: 32px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  color: var(--text2); transition: background var(--transition);
}
.icon-btn:hover { background: var(--hover, var(--surface3)); }

/* ── Bottom Sheet ────────────────────────────────────────────────────────── */
.bottom-sheet {
  position: fixed; bottom: 0; left: 0; right: 0;
  background: var(--surface);
  border-radius: 16px 16px 0 0;
  z-index: 210;
  max-height: 90vh;
  display: flex; flex-direction: column;
  transform: translateY(100%);
  transition: transform .3s cubic-bezier(.4,0,.2,1);
  box-shadow: 0 -4px 32px rgba(0,0,0,.18);
  border-top: 1px solid var(--border);
}
.bottom-sheet.open { transform: translateY(0); }
.bottom-sheet.full-sheet { max-height: 96vh; }
.sheet-header {
  padding: .65rem 1rem;
  border-bottom: 1px solid var(--divider);
  display: flex; align-items: center; justify-content: space-between;
  font-weight: 600; font-size: .97rem; flex-shrink: 0;
}
.sheet-content { overflow-y: auto; flex: 1; }

/* ── Comments ─────────────────────────────────────────────────────────────── */
.comment-item {
  display: flex; align-items: flex-start; gap: .65rem;
  padding: .7rem 1rem;
  border-bottom: 1px solid var(--divider);
}
.comment-bubble {
  flex: 1; background: var(--surface3, var(--hover));
  border-radius: 0 12px 12px 12px; padding: .55rem .8rem;
}
.comment-author { font-weight: 700; font-size: .83rem; color: var(--text); }
.comment-text   { font-size: .9rem; color: var(--text); margin-top: .15rem; line-height: 1.45; word-break: break-word; }
.comment-meta   { font-size: .73rem; color: var(--text3); margin-top: .3rem; display: flex; gap: .75rem; align-items: center; }
.comment-like-btn { color: var(--text3); font-weight: 600; }
.comment-like-btn.liked { color: var(--primary); }
.comment-input-wrap {
  display: flex; align-items: center; gap: .6rem;
  padding: .6rem 1rem; border-top: 1px solid var(--divider);
  background: var(--surface); flex-shrink: 0;
}
.comment-input-field {
  flex: 1; background: var(--surface3, #f0f2f5);
  border-radius: 20px; padding: .55rem 1rem;
  font-size: .9rem; color: var(--text);
  border: none; outline: none;
}
[data-theme="dark"] .comment-input-field { background: #1e2732; }
.comment-send-btn {
  color: var(--primary); font-size: 1.1rem;
  display: flex; align-items: center; justify-content: center;
  width: 36px; height: 36px; border-radius: 50%;
  transition: background var(--transition);
}
.comment-send-btn:hover  { background: var(--primary-light); }
.comment-send-btn:active { background: var(--primary-light); }

/* ── Create post ─────────────────────────────────────────────────────────── */
.post-input-area {
  width: 100%; min-height: 120px;
  border: none; outline: none;
  background: transparent; color: var(--text);
  font-size: 1rem; line-height: 1.55; resize: none;
}
.privacy-select {
  display: inline-flex; align-items: center; gap: .25rem;
  font-size: .76rem; background: var(--surface3, #eef1f5);
  color: var(--text2); border: none; border-radius: 12px;
  padding: .2rem .55rem; cursor: pointer; margin-top: .25rem;
  font-family: inherit;
}
[data-theme="dark"] .privacy-select { background: #1e2732; }

/* ── Privacy picker sheet ─────────────────────────────────────────────────── */
.privacy-option-item {
  display: flex; align-items: center; gap: .85rem;
  padding: .9rem 1.25rem; cursor: pointer;
  transition: background .15s;
}
.privacy-option-item:hover, .privacy-option-item.selected { background: var(--surface2); }
.privacy-option-icon { font-size: 1.4rem; flex-shrink: 0; }
.privacy-option-label { flex: 1; font-size: .95rem; font-weight: 500; color: var(--text); }
.privacy-option-radio { color: var(--primary); font-size: 1.3rem; flex-shrink: 0; }
.post-photo-preview { position: relative; margin: .5rem 0; }
.post-photo-preview img { width: 100%; border-radius: 10px; max-height: 240px; object-fit: cover; }
.post-photo-remove {
  position: absolute; top: .5rem; right: .5rem;
  background: rgba(0,0,0,.55); color: #fff;
  border-radius: 50%; width: 28px; height: 28px;
  display: flex; align-items: center; justify-content: center;
  font-size: .85rem;
}
.attach-bar { display: flex; gap: .25rem; padding: .4rem 0; overflow-x: auto; scrollbar-width: none; -ms-overflow-style: none; }
.attach-bar::-webkit-scrollbar { display: none; }
.attach-btn {
  display: flex; align-items: center; gap: .4rem; flex-shrink: 0;
  font-size: .85rem; color: var(--text2);
  padding: .4rem .8rem; border-radius: 20px;
  transition: background var(--transition);
}
.attach-btn:hover { background: var(--surface3, #f0f2f5); }

/* ── Menu sheet ──────────────────────────────────────────────────────────── */
.menu-item {
  display: flex; align-items: center; gap: .85rem;
  padding: .95rem 1.25rem;
  font-size: .95rem; color: var(--text);
  border-bottom: 1px solid var(--divider); cursor: pointer;
  transition: background var(--transition);
}
.menu-item:hover { background: var(--surface3, #f5f5f5); }
.menu-item:last-child { border-bottom: none; }
.menu-item.danger { color: var(--error); }
.menu-item > i { font-size: 1.25rem; color: var(--text3); flex-shrink: 0; }
.menu-item.danger > i { color: var(--error); }

/* ── Drawer ───────────────────────────────────────────────────────────────── */
.xi-menu::before   { content: "menu"; }
.xi-logout::before { content: "logout"; }
.xi-music::before  { content: "music_note"; }
.xi-video::before  { content: "videocam"; }
.xi-poll::before   { content: "poll"; }
.xi-forum::before  { content: "forum"; }
.xi-sell::before   { content: "sell"; }
.xi-fund::before   { content: "volunteer_activism"; }
.xi-heart::before  { content: "favorite"; }
.xi-play::before   { content: "play_arrow"; }

.drawer-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,.45);
  z-index: 300; animation: fadeIn .2s ease;
}
.drawer {
  position: fixed; top: 0; left: 0; bottom: 0;
  width: 285px; max-width: 85vw;
  background: var(--surface);
  z-index: 301;
  display: flex; flex-direction: column;
  transform: translateX(-100%);
  transition: transform .28s cubic-bezier(.4,0,.2,1);
  box-shadow: 4px 0 24px rgba(0,0,0,.18);
  overflow: hidden;
}
.drawer.open { transform: translateX(0); }
.drawer-header {
  position: relative;
  min-height: 130px;
  padding: 1rem;
  display: flex; flex-direction: column; justify-content: flex-end; gap: .4rem;
  flex-shrink: 0; overflow: hidden; cursor: pointer;
}
.drawer-cover {
  position: absolute; inset: 0;
  background: var(--gradient);
  background-size: cover; background-position: center;
}
.drawer-header-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to bottom, rgba(0,0,0,.05) 0%, rgba(0,0,0,.6) 100%);
  pointer-events: none;
}
.drawer-avatar {
  width: 56px; height: 56px; border-radius: 50%;
  border: 2.5px solid rgba(255,255,255,.85);
  object-fit: cover; flex-shrink: 0;
  position: relative; z-index: 1;
}
.drawer-user-info { position: relative; z-index: 1; }
.drawer-name  { font-size: 1rem; font-weight: 700; color: #fff; text-shadow: 0 1px 4px rgba(0,0,0,.5); }
.drawer-email { font-size: .78rem; color: rgba(255,255,255,.8); margin-top: 1px; }
.drawer-nav {
  flex: 1; overflow-y: auto; padding: .35rem 0;
  scrollbar-width: thin; scrollbar-color: var(--border) transparent;
}
.drawer-section-title {
  font-size: .7rem; font-weight: 700; color: var(--text3);
  text-transform: uppercase; letter-spacing: .07em;
  padding: .65rem 1rem .2rem; margin-top: .25rem;
}
.drawer-item {
  display: flex; align-items: center; gap: .85rem;
  padding: .78rem 1rem;
  color: var(--text); font-size: .93rem;
  cursor: pointer; border-radius: 0;
  transition: background var(--transition);
  text-decoration: none;
}
.drawer-item:hover, .drawer-item:active { background: var(--surface3); }
.drawer-item.active { color: var(--primary); background: var(--primary-light); }
.drawer-item.active > i { color: var(--primary); }
.drawer-item > i { font-size: 1.3rem; color: var(--text3); flex-shrink: 0; }
.drawer-xi { font-size: 1.3rem; color: var(--text3); flex-shrink: 0; }
.drawer-item.danger { color: var(--error); }
.drawer-item.danger > i { color: var(--error); }
.drawer-divider { height: 1px; background: var(--divider); margin: .35rem 0; }
.drawer-footer { padding: .35rem 0; border-top: 1px solid var(--divider); flex-shrink: 0; }

/* ── Seletor de fonte no drawer ──────────────────────────────────────────── */
.drawer-font-row {
  display: flex; align-items: center; gap: .6rem;
  padding: .5rem 1.1rem;
}
.drawer-font-icon {
  font-size: 1.1rem; color: var(--text3); flex-shrink: 0;
}
.drawer-font-btns {
  display: flex; gap: .35rem; flex: 1;
}
.font-chip {
  padding: .25rem .65rem;
  border-radius: 20px;
  border: 1.5px solid var(--divider);
  background: transparent;
  color: var(--text2);
  font-size: .75rem;
  font-weight: 600;
  cursor: pointer;
  transition: border-color .2s, color .2s, background .2s;
  font-family: inherit;
}
.font-chip:hover,
html[data-font="plus-jakarta-sans"] .font-chip[data-font="plus-jakarta-sans"],
html[data-font="inter"]             .font-chip[data-font="inter"],
html[data-font="nunito"]            .font-chip[data-font="nunito"] {
  border-color: var(--primary);
  color: var(--primary);
  background: var(--primary-light);
}

/* ── Seletor de idioma no drawer ─────────────────────────────────────────── */
.drawer-lang-row {
  display: flex; align-items: center; gap: .6rem;
  padding: .5rem 1.1rem;
  cursor: pointer;
}
.drawer-lang-label {
  font-size: .85rem; color: var(--text2); flex: 1;
}
.drawer-lang-expand {
  color: var(--text3); display: flex; align-items: center;
  transition: transform .2s;
}
.drawer-lang-row.open .drawer-lang-expand { transform: rotate(180deg); }
.drawer-lang-chips {
  display: none; flex-wrap: wrap; gap: .35rem;
  padding: .15rem 1.1rem .6rem;
}
.drawer-lang-row.open + .drawer-lang-chips { display: flex; }
.lang-chip {
  padding: .25rem .6rem;
  border-radius: 20px;
  border: 1.5px solid var(--divider);
  background: transparent;
  color: var(--text2);
  font-size: .8rem;
  font-weight: 600;
  cursor: pointer;
  transition: border-color .2s, color .2s, background .2s;
  font-family: inherit;
}
.lang-chip:hover,
.lang-chip.active {
  border-color: var(--primary);
  color: var(--primary);
  background: var(--primary-light);
}

/* ── Tab bar ──────────────────────────────────────────────────────────────── */
.tab-bar {
  display: flex; overflow-x: auto; gap: .25rem;
  padding: .5rem .75rem; background: var(--surface);
  border-bottom: 1px solid var(--divider);
  scrollbar-width: none; flex-shrink: 0;
  position: sticky; top: var(--topbar-h); z-index: 50;
}
.tab-bar::-webkit-scrollbar { display: none; }
.tab-btn {
  flex-shrink: 0; padding: .38rem .9rem;
  border-radius: 20px; font-size: .82rem; font-weight: 600;
  color: var(--text2); background: var(--surface3);
  border: 1.5px solid transparent;
  transition: all var(--transition); white-space: nowrap;
}
.tab-btn.active {
  color: var(--primary); background: var(--primary-light);
  border-color: var(--primary);
}

/* ── Module grid / list / cards ──────────────────────────────────────────── */
.module-grid {
  display: grid; grid-template-columns: repeat(2, 1fr);
  gap: .65rem; padding: .75rem;
}
.module-list { display: flex; flex-direction: column; }

.module-card {
  background: var(--surface); border-radius: var(--radius);
  border: 1px solid var(--divider); overflow: hidden;
  cursor: pointer; transition: transform var(--transition), box-shadow var(--transition);
  box-shadow: var(--shadow);
}
.module-card:active { transform: scale(.97); }
.module-card-thumb {
  width: 100%; aspect-ratio: 4/3; overflow: hidden;
  background: var(--surface3); position: relative;
}
.module-card-thumb img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform .4s ease;
}
.module-card:hover .module-card-thumb img { transform: scale(1.04); }
.module-card-no-img {
  width: 100%; height: 100%;
  display: flex; align-items: center; justify-content: center;
  color: var(--text3); font-size: 2.5rem;
}
.module-card-body   { padding: .6rem .7rem .7rem; }
.module-card-title  { font-size: .88rem; font-weight: 700; color: var(--text); line-height: 1.3; }
.module-card-meta   { font-size: .72rem; color: var(--text3); margin-top: .2rem; }
.module-card-desc   { font-size: .8rem; color: var(--text2); margin-top: .25rem; line-height: 1.35;
                      display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.module-card-count  { font-size: .75rem; color: var(--text3); margin-top: .25rem; }

/* Row card (music, forum, etc.) */
.row-card {
  display: flex; align-items: center; gap: .75rem;
  padding: .75rem 1rem; border-bottom: 1px solid var(--divider);
  background: var(--surface); cursor: pointer;
  transition: background var(--transition);
}
.row-card:hover { background: var(--surface2); }
.row-card-img {
  width: 50px; height: 50px; border-radius: 8px;
  object-fit: cover; flex-shrink: 0; background: var(--surface3);
  overflow: hidden;
}
.row-card-img img { width: 100%; height: 100%; object-fit: cover; }
.row-card-body  { flex: 1; min-width: 0; }
.row-card-title { font-size: .92rem; font-weight: 600; color: var(--text);
                  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.row-card-sub   { font-size: .78rem; color: var(--text3); margin-top: 1px; }

/* Blog card */
.blog-card { display: flex; flex-direction: column; margin-bottom: .65rem; }
.blog-card-cover {
  width: 100%; max-height: 180px; object-fit: cover;
  border-radius: var(--radius) var(--radius) 0 0;
}

/* Event card */
.event-date-badge {
  position: absolute; bottom: 0; left: 0; right: 0;
  background: rgba(0,0,0,.55); color: #fff;
  font-size: .72rem; font-weight: 600; padding: .25rem .5rem;
  text-align: center;
}

/* Video card */
.video-thumb { position: relative; }
.video-play-btn {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  background: rgba(0,0,0,.28);
  opacity: 0; transition: opacity var(--transition);
}
.module-card:hover .video-play-btn { opacity: 1; }
.video-duration {
  position: absolute; bottom: .3rem; right: .4rem;
  background: rgba(0,0,0,.7); color: #fff;
  font-size: .68rem; border-radius: 4px; padding: .1rem .35rem;
}

/* Music card */
.music-card { position: relative; }
.music-thumb {
  width: 50px; height: 50px; border-radius: 8px;
  overflow: hidden; flex-shrink: 0; position: relative;
}
.music-thumb img   { width: 100%; height: 100%; object-fit: cover; }
.music-thumb-default {
  width: 100%; height: 100%;
  background: var(--primary-light);
  display: flex; align-items: center; justify-content: center;
  color: var(--primary); font-size: 1.4rem;
}
.music-play-overlay {
  position: absolute; inset: 0; background: rgba(0,0,0,.4);
  display: flex; align-items: center; justify-content: center;
  color: #fff; opacity: 0; transition: opacity var(--transition);
}
.music-card:hover .music-play-overlay { opacity: 1; }

/* Store card */
.store-price { font-size: .95rem; font-weight: 800; color: var(--primary); margin-top: .2rem; }
.classified-price-badge {
  position: absolute; top: .4rem; right: .4rem;
  background: var(--primary); color: #fff;
  font-size: .72rem; font-weight: 700; border-radius: 6px; padding: .15rem .45rem;
}

/* Poll card */
.poll-card {
  background: var(--surface); border-radius: var(--radius);
  border: 1px solid var(--divider); margin: .65rem .75rem 0;
  box-shadow: var(--shadow); overflow: hidden;
}
.poll-option {
  display: flex; align-items: center; gap: .6rem;
  padding: .5rem .75rem; cursor: pointer;
  transition: background var(--transition);
}
.poll-option:hover { background: var(--surface2); }
.poll-option-label { flex: 1; font-size: .88rem; color: var(--text); }
.poll-bar   { flex: 2; height: 6px; background: var(--border); border-radius: 3px; overflow: hidden; }
.poll-bar-fill { height: 100%; background: var(--primary); border-radius: 3px; }
.poll-pct   { font-size: .75rem; font-weight: 700; color: var(--text3); width: 32px; text-align: right; }

/* Crowdfunding */
.fund-progress { margin: .4rem 0 .25rem; }
.fund-bar { height: 6px; background: var(--border); border-radius: 3px; overflow: hidden; margin-bottom: .25rem; }
.fund-bar-fill { height: 100%; background: var(--primary); border-radius: 3px; }
.fund-meta { display: flex; justify-content: space-between; font-size: .72rem; }
.fund-raised { color: var(--primary); font-weight: 700; }
.fund-goal   { color: var(--text3); }

/* Friends page */
.friend-list { display: flex; flex-direction: column; }
.friend-card {
  display: flex; align-items: center; gap: .75rem;
  padding: .85rem 1rem; border-bottom: 1px solid var(--divider);
  background: var(--surface); transition: background var(--transition);
}
.friend-card.removing { opacity: 0; max-height: 0; overflow: hidden; transition: opacity .3s, max-height .35s; }
.friend-info   { flex: 1; min-width: 0; cursor: pointer; }
.friend-name   { font-size: .93rem; font-weight: 700; color: var(--text); }
.friend-mutual { font-size: .78rem; color: var(--text3); margin-top: 1px; }
.friend-actions { display: flex; gap: .4rem; flex-shrink: 0; }

/* Search page */
.search-bar-wrap {
  padding: .65rem .75rem; background: var(--surface);
  border-bottom: 1px solid var(--divider);
  position: sticky; top: var(--topbar-h); z-index: 50;
}
.search-bar {
  display: flex; align-items: center; gap: .6rem;
  background: var(--surface3); border-radius: 24px;
  padding: .5rem 1rem;
}
.search-input {
  flex: 1; background: transparent; border: none; outline: none;
  font-size: .95rem; color: var(--text);
}
.search-cats { top: calc(var(--topbar-h) + 56px); }

/* Points hero */
.points-hero {
  background: var(--gradient);
  padding: 2.5rem 1rem 2rem;
  display: flex; flex-direction: column;
  align-items: center; gap: .5rem;
  text-align: center;
}
.points-icon  { margin-bottom: .25rem; }
.points-label { font-size: .9rem; color: rgba(255,255,255,.75); font-weight: 600; }

/* Empty state */
.empty-state {
  display: flex; flex-direction: column; align-items: center;
  padding: 3rem 2rem; gap: .75rem; color: var(--text3);
}
.empty-state > i   { font-size: 3.5rem; }
.empty-state > p   { font-size: .95rem; text-align: center; line-height: 1.5; }

/* Feed welcome (empty feed first visit) */
.feed-welcome {
  display: flex; flex-direction: column; align-items: center;
  padding: 2rem 1.5rem 3rem; gap: 1rem; text-align: center;
  animation: fadeInUp .5s ease both;
}
.feed-welcome-logo img {
  width: 72px; height: 72px; border-radius: 20px;
  box-shadow: 0 4px 20px rgba(0,0,0,.15);
}
.feed-welcome-title {
  font-size: 1.45rem; font-weight: 800; color: var(--text); margin: 0;
}
.feed-welcome-sub {
  font-size: .95rem; color: var(--text2); line-height: 1.6;
  max-width: 300px; margin: 0;
}
.feed-welcome-actions {
  display: flex; flex-direction: column; gap: .6rem; width: 100%; max-width: 280px;
  margin-top: .5rem;
}
.feed-welcome-tips {
  display: flex; flex-direction: column; gap: .6rem;
  width: 100%; max-width: 300px; margin-top: .5rem;
}
.feed-welcome-tip {
  display: flex; align-items: center; gap: .75rem;
  padding: .65rem 1rem; background: var(--surface2);
  border-radius: var(--radius-sm); text-align: left;
  font-size: .9rem; color: var(--text2);
}
.feed-welcome-tip-icon { font-size: 1.3rem; flex-shrink: 0; }
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* Input field shared */
input[type="text"], input[type="email"], input[type="password"], input[type="search"],
textarea, select {
  background: var(--surface2); color: var(--text);
  border: 1.5px solid var(--border); border-radius: var(--radius-sm);
  padding: .6rem .9rem; font-size: .95rem; width: 100%;
  transition: border-color var(--transition);
}
input:focus, textarea:focus, select:focus { border-color: var(--primary); outline: none; }
[data-theme="dark"] input, [data-theme="dark"] textarea, [data-theme="dark"] select { background: #1e2732; }

/* ── Theme Toggle ────────────────────────────────────────────────────────── */
#btn-theme {
  width: 40px; height: 40px; border-radius: 50%;
  color: #fff; font-size: 1rem;
  display: flex; align-items: center; justify-content: center;
  transition: background var(--transition);
}
#btn-theme:hover { background: rgba(255,255,255,.18); }

/* ── Utilities ───────────────────────────────────────────────────────────── */
.hidden      { display: none !important; }
.text-center { text-align: center; }
.text-muted  { color: var(--text3); }
.text-sm     { font-size: .84rem; }
.mt-1 { margin-top: .5rem; }  .mt-2 { margin-top: 1rem; }  .mt-3 { margin-top: 1.5rem; }
.mb-1 { margin-bottom: .5rem; } .mb-2 { margin-bottom: 1rem; }
.flex { display: flex; } .flex-center { display: flex; align-items: center; justify-content: center; }
.gap-1 { gap: .5rem; } .gap-2 { gap: 1rem; }

/* ── RTL (árabe) ─────────────────────────────────────────────────────────── */
[dir="rtl"] .drawer       { left: auto; right: 0; transform: translateX(100%); }
[dir="rtl"] .drawer.open  { transform: translateX(0); }
[dir="rtl"] .topbar       { flex-direction: row-reverse; }
[dir="rtl"] .bottom-nav   { direction: rtl; }
[dir="rtl"] .post-header  { flex-direction: row-reverse; }
[dir="rtl"] .post-actions { flex-direction: row-reverse; }
[dir="rtl"] .chat-item    { flex-direction: row-reverse; }
[dir="rtl"] .drawer-item  { flex-direction: row-reverse; }
[dir="rtl"] .drawer-font-row,
[dir="rtl"] .drawer-lang-row { flex-direction: row-reverse; }
[dir="rtl"] .input-eye-btn { right: auto; left: 0; border-radius: var(--radius) 0 0 var(--radius); }
[dir="rtl"] .input-eye-wrap input { padding-right: 1rem; padding-left: 2.6rem; }

/* ── Responsivo desktop ──────────────────────────────────────────────────── */
@media (min-width: 640px) {
  #page-container, .topbar, .bottom-nav, .chat-input-bar, #toast-container {
    max-width: 600px;
  }
  #page-container { margin: 0 auto; }
  .topbar, .bottom-nav, .chat-input-bar {
    left: 50%; transform: translateX(-50%); right: auto; width: 600px;
  }
  #toast-container { left: 50%; transform: translateX(-50%); }
}

/* ── Advanced Events ─────────────────────────────────────────────────────── */
.adv-event-card .event-date-badge {
  position: absolute; bottom: 0; left: 0; right: 0;
  background: linear-gradient(transparent, rgba(0,0,0,.7));
  color: #fff; font-size: .72rem; padding: .4rem .6rem .5rem;
  text-transform: capitalize;
}

/* ── Directory Pages card ────────────────────────────────────────────────── */
.page-dir-card .module-card-meta { font-size: .8rem; color: var(--text3); }

/* ── Listings / Reviews ──────────────────────────────────────────────────── */
.listing-card .listing-stars   { color: #f5a623; letter-spacing: -.05em; }
.listing-card .listing-rating  { font-size: .78rem; color: var(--text3); font-weight: 600; }
.listing-card .listing-rating-row { display: flex; align-items: center; gap: .3rem; margin: .15rem 0; }

/* ── Offers ──────────────────────────────────────────────────────────────── */
.offer-card .offer-discount-badge {
  position: absolute; top: .5rem; right: .5rem;
  background: var(--error); color: #fff;
  font-size: .72rem; font-weight: 700;
  padding: .2rem .45rem; border-radius: 4px;
}
.offer-price-row       { display: flex; align-items: baseline; gap: .5rem; margin: .25rem 0; }
.offer-old-price       { text-decoration: line-through; color: var(--text3); font-size: .82rem; }
.offer-price           { color: var(--primary); font-size: 1rem; font-weight: 700; }

/* ── Packages ────────────────────────────────────────────────────────────── */
.packages-list         { display: flex; flex-direction: column; gap: 1rem; padding: 1rem; }
.package-card {
  background: var(--surface2); border-radius: var(--radius);
  border: 2px solid var(--border); padding: 1.25rem;
  transition: border-color var(--transition);
}
.package-card.package-current { border-color: var(--primary); }
.package-header        { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: .75rem; }
.package-name          { font-size: 1.1rem; font-weight: 700; }
.package-price         { font-size: 1.4rem; font-weight: 800; color: var(--primary); }
.package-period        { font-size: .8rem; color: var(--text3); font-weight: 400; }
.package-desc          { font-size: .88rem; color: var(--text2); margin-bottom: .75rem; }
.package-features      { list-style: none; padding: 0; margin: 0 0 1rem; display: flex; flex-direction: column; gap: .35rem; }
.package-features li   { display: flex; align-items: center; gap: .4rem; font-size: .88rem; }
.package-features .xi  { color: var(--primary); font-size: 1rem; }
.package-btn           { width: 100%; padding: .65rem; border-radius: var(--radius-sm); font-size: .95rem; font-weight: 600; background: var(--primary); color: #fff; border: none; cursor: pointer; }
.package-btn.btn-current { background: var(--surface3); color: var(--text3); cursor: default; }
.module-hero           { display: flex; flex-direction: column; align-items: center; gap: .5rem; padding: 2rem 1rem 1rem; text-align: center; color: var(--text2); }
.module-hero h2        { margin: 0; font-size: 1.3rem; color: var(--text); }

/* ── Stickers ────────────────────────────────────────────────────────────── */
.sticker-tab           { flex: 1; padding: .55rem; background: none; border: none; border-bottom: 2px solid transparent; font-size: .9rem; color: var(--text2); cursor: pointer; transition: all var(--transition); }
.sticker-tab.active    { border-bottom-color: var(--primary); color: var(--primary); font-weight: 600; }
.stickers-grid         { display: grid; grid-template-columns: repeat(3, 1fr); gap: .75rem; padding: 1rem; }
.sticker-card          { display: flex; flex-direction: column; align-items: center; gap: .35rem; padding: .75rem .5rem; background: var(--surface2); border-radius: var(--radius-sm); cursor: pointer; transition: background var(--transition); }
.sticker-card:hover    { background: var(--surface3); }
.sticker-img           { width: 72px; height: 72px; display: flex; align-items: center; justify-content: center; }
.sticker-img img       { width: 100%; height: 100%; object-fit: contain; }
.sticker-placeholder   { font-size: 2.5rem; }
.sticker-name          { font-size: .75rem; color: var(--text2); text-align: center; }
.sticker-buy-btn       { font-size: .72rem; background: var(--primary); color: #fff; border: none; border-radius: 12px; padding: .25rem .6rem; cursor: pointer; }
.sticker-owned         { font-size: .72rem; color: var(--text3); }

/* ── Stories ─────────────────────────────────────────────────────────────── */
.story-rail            { display: flex; gap: .75rem; padding: 1rem; overflow-x: auto; scrollbar-width: none; }
.story-rail::-webkit-scrollbar { display: none; }
.story-create-btn, .story-bubble {
  display: flex; flex-direction: column; align-items: center; gap: .3rem;
  flex-shrink: 0; cursor: pointer;
}
.story-create-icon {
  width: 60px; height: 60px; border-radius: 50%;
  background: var(--primary); display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: 1.5rem;
}
.story-create-label, .story-user { font-size: .72rem; color: var(--text2); max-width: 64px; text-align: center; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.story-ring {
  width: 60px; height: 60px; border-radius: 50%;
  padding: 2.5px;
  background: linear-gradient(135deg, #f6a623, #e04f7b, #4da2c5);
}
.story-ring img        { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; border: 2.5px solid var(--surface); }
.story-seen .story-ring { background: var(--surface3); }
.story-viewer          { position: fixed; inset: 0; z-index: 9999; background: #000; display: flex; align-items: center; justify-content: center; }
.story-viewer.closing  { animation: fadeOut .25s ease forwards; }
.story-viewer-inner    { position: relative; width: 100%; max-width: 420px; height: 100%; }
.story-progress-bar    { position: absolute; top: .75rem; left: .75rem; right: .75rem; z-index: 2; display: flex; gap: 3px; }
.story-progress-seg    { flex: 1; height: 3px; background: rgba(255,255,255,.35); border-radius: 2px; transition: background .3s; }
.story-progress-seg.done   { background: #fff; }
.story-progress-seg.active { background: rgba(255,255,255,.8); animation: storyProgress 5s linear forwards; }
@keyframes storyProgress { from { background: rgba(255,255,255,.4); } to { background: #fff; } }
.story-viewer-header   { position: absolute; top: 1.5rem; left: .75rem; right: .75rem; z-index: 3; display: flex; align-items: center; gap: .5rem; }
.story-viewer-avatar   { width: 36px; height: 36px; border-radius: 50%; object-fit: cover; border: 2px solid #fff; }
.story-viewer-name     { color: #fff; font-size: .9rem; font-weight: 600; flex: 1; text-shadow: 0 1px 4px rgba(0,0,0,.5); }
.story-viewer-close    { background: none; border: none; color: #fff; font-size: 1.3rem; cursor: pointer; padding: .25rem; }
.story-view-img        { width: 100%; height: 100%; object-fit: contain; transition: opacity .18s; }
.story-view-video      { width: 100%; height: 100%; object-fit: contain; display: none; background: #000; }
.story-view-caption    { position: absolute; bottom: 1.5rem; left: 1rem; right: 1rem; color: #fff; font-size: .95rem; text-align: center; text-shadow: 0 1px 6px rgba(0,0,0,.8); pointer-events: none; }
.story-create-body     { padding: 1rem; display: flex; flex-direction: column; gap: .75rem; overflow-y: auto; flex: 1; }
.story-photo-preview   { min-height: 0; }
.story-photo-preview img  { max-width: 100%; max-height: 240px; object-fit: contain; border-radius: 8px; display: block; }
.story-photo-preview video { max-width: 100%; max-height: 240px; border-radius: 8px; display: block; }
.story-caption-input   { min-height: 80px; resize: none; }
.photo-upload-btn      { display: inline-flex; align-items: center; gap: .5rem; cursor: pointer; padding: .6rem 1rem; background: var(--surface3); border-radius: var(--radius-sm); font-size: .9rem; color: var(--text); }

/* ── People Suggestion ───────────────────────────────────────────────────── */
.module-page-header    { display: flex; align-items: flex-start; gap: .75rem; padding: 1rem; border-bottom: 1px solid var(--border); }
.module-page-header h2 { margin: 0 0 .2rem; font-size: 1.05rem; }
.module-page-header p  { margin: 0; font-size: .82rem; color: var(--text3); }
.people-list           { display: flex; flex-direction: column; }
.people-card           { display: flex; align-items: center; gap: .75rem; padding: .85rem 1rem; border-bottom: 1px solid var(--border); transition: background var(--transition); }
.people-card.removing  { opacity: 0; max-height: 0; overflow: hidden; transition: all .3s; }
.people-avatar img     { width: 48px; height: 48px; border-radius: 50%; object-fit: cover; cursor: pointer; }
.people-info           { flex: 1; cursor: pointer; }
.people-name           { font-weight: 600; font-size: .95rem; }
.people-meta           { font-size: .8rem; color: var(--text3); }
.people-bio            { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 180px; }
.people-actions        { display: flex; align-items: center; gap: .4rem; flex-shrink: 0; }
.btn-add-friend        { display: flex; align-items: center; gap: .25rem; background: var(--primary); color: #fff; border: none; border-radius: 20px; padding: .4rem .75rem; font-size: .82rem; font-weight: 600; cursor: pointer; white-space: nowrap; }
.btn-add-friend:disabled { background: var(--surface3); color: var(--text3); }
.btn-dismiss           { background: var(--surface3); border: none; border-radius: 50%; width: 32px; height: 32px; display: flex; align-items: center; justify-content: center; cursor: pointer; color: var(--text3); font-size: .9rem; }

/* ── Settings ────────────────────────────────────────────────────────────── */
.settings-page         { padding: 0; }
.settings-section      { padding: 1rem; border-bottom: 1px solid var(--border); }
.settings-section-title { font-size: .78rem; text-transform: uppercase; letter-spacing: .06em; color: var(--text3); font-weight: 700; margin-bottom: .75rem; }
.settings-row          { margin-bottom: .75rem; }
.settings-row label    { display: block; font-size: .82rem; color: var(--text2); margin-bottom: .3rem; }
.settings-input, .settings-select { width: 100%; }
.btn-settings-save     { margin-top: .5rem; padding: .55rem 1.25rem; background: var(--primary); color: #fff; border: none; border-radius: var(--radius-sm); font-size: .9rem; font-weight: 600; cursor: pointer; }
.settings-toggle-row   { display: flex; align-items: center; justify-content: space-between; padding: .5rem 0; }
.settings-toggle       { position: relative; width: 44px; height: 24px; cursor: pointer; }
.settings-toggle input { opacity: 0; width: 0; height: 0; }
.toggle-slider         { position: absolute; inset: 0; background: var(--surface3); border-radius: 24px; transition: background var(--transition); }
.toggle-slider::before { content: ''; position: absolute; width: 18px; height: 18px; border-radius: 50%; background: #fff; top: 3px; left: 3px; transition: transform var(--transition); }
.settings-toggle input:checked + .toggle-slider              { background: var(--primary); }
.settings-toggle input:checked + .toggle-slider::before      { transform: translateX(20px); }
.settings-danger .btn-danger { background: var(--error); color: #fff; border: none; padding: .6rem 1.25rem; border-radius: var(--radius-sm); font-size: .9rem; font-weight: 600; cursor: pointer; }

/* ── Video Channel card ──────────────────────────────────────────────────── */
.adv-channel-card .module-card-thumb { aspect-ratio: 1; }

/* ── Profile photo edit ──────────────────────────────────────────────────── */
.profile-cover-wrap {
  position: relative;
  width: 100%;
}
.profile-cover-edit-btn {
  position: absolute; bottom: .5rem; right: .5rem;
  width: 36px; height: 36px; border-radius: 50%;
  background: rgba(0,0,0,.55); backdrop-filter: blur(4px);
  border: 1.5px solid rgba(255,255,255,.3);
  color: #fff; font-size: 1rem; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background .2s;
}
.profile-cover-edit-btn:hover { background: rgba(0,0,0,.75); }

.profile-avatar-wrap {
  position: relative;
  display: inline-block;
}
.profile-avatar-edit-btn {
  position: absolute; bottom: 2px; right: 2px;
  width: 28px; height: 28px; border-radius: 50%;
  background: var(--primary);
  border: 2px solid var(--surface);
  color: #fff; font-size: .85rem; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background .2s;
}
.profile-avatar-edit-btn:hover { background: var(--primary-dark, #3a8fb5); }
.profile-avatar-edit-btn .ms-icon { font-size: .9rem; }

@keyframes spin { to { transform: rotate(360deg); } }

/* ── Image Editor (xie) ─────────────────────────────────────────────────── */
.xie-overlay {
  position: fixed; inset: 0; z-index: 10000;
  background: #000;
  display: flex; flex-direction: column;
  overflow: hidden;
  animation: xie-in .18s ease;
}
@keyframes xie-in { from { opacity: 0; transform: scale(.97); } to { opacity: 1; transform: scale(1); } }

.xie-topbar {
  display: flex; align-items: center; justify-content: space-between;
  padding: .5rem .75rem;
  background: #111;
  flex-shrink: 0;
  height: 52px;
}
.xie-title      { color: #fff; font-size: 1rem; font-weight: 600; }
.xie-btn-icon   { background: none; border: none; color: #fff; font-size: 1.3rem; cursor: pointer; padding: .4rem; border-radius: 50%; }
.xie-btn-icon:hover { background: rgba(255,255,255,.1); }
.xie-btn-done   { display: flex; align-items: center; gap: .35rem; background: var(--primary); color: #fff; border: none; border-radius: 20px; padding: .4rem .9rem; font-size: .9rem; font-weight: 600; cursor: pointer; }
.xie-btn-done:disabled { opacity: .6; cursor: default; }

.xie-frame-wrap {
  flex: 1; display: flex; align-items: center; justify-content: center;
  background: #000; overflow: hidden;
  min-height: 0;
}
.xie-frame {
  position: relative; overflow: hidden;
  cursor: grab; background: #000;
  /* size is set by JS */
}
.xie-frame:active { cursor: grabbing; }
.xie-frame canvas { display: block; width: 100%; height: 100%; }

.xie-tabs {
  display: flex; background: #111;
  border-top: 1px solid #222;
  flex-shrink: 0;
}
.xie-tab {
  flex: 1; padding: .65rem .5rem; background: none; border: none;
  color: #888; font-size: .84rem; font-weight: 600; cursor: pointer;
  border-bottom: 2px solid transparent;
  transition: color .2s, border-color .2s;
}
.xie-tab.active { color: #fff; border-bottom-color: var(--primary); }

.xie-controls {
  background: #111; flex-shrink: 0;
  min-height: 120px; max-height: 160px;
  overflow-y: auto; overflow-x: hidden;
  padding: .5rem 0;
}

/* Crop tab */
.xie-aspect-row {
  display: flex; gap: .4rem; padding: .5rem .75rem;
  overflow-x: auto; scrollbar-width: none;
}
.xie-aspect-row::-webkit-scrollbar { display: none; }
.xie-aspect-btn {
  flex-shrink: 0; padding: .35rem .75rem;
  background: #222; color: #aaa;
  border: 1.5px solid #333; border-radius: 20px;
  font-size: .8rem; font-weight: 600; cursor: pointer;
  transition: all .2s;
}
.xie-aspect-btn.active { background: var(--primary); color: #fff; border-color: var(--primary); }

.xie-transform-row {
  display: flex; gap: .5rem; justify-content: center;
  padding: .4rem .75rem;
}
.xie-transform-btn {
  display: flex; align-items: center; justify-content: center;
  width: 44px; height: 44px; border-radius: 50%;
  background: #222; border: 1.5px solid #333; color: #ccc;
  font-size: 1.1rem; cursor: pointer; transition: background .2s;
}
.xie-transform-btn:hover { background: #333; }

.xie-hint { text-align: center; font-size: .72rem; color: #555; padding: .25rem; }

/* Adjust tab */
.xie-sliders { padding: .5rem .75rem; display: flex; flex-direction: column; gap: .4rem; }
.xie-slider-row {
  display: flex; align-items: center; gap: .6rem;
}
.xie-slider-label { color: #aaa; font-size: .78rem; width: 90px; flex-shrink: 0; }
.xie-slider {
  flex: 1; -webkit-appearance: none; appearance: none;
  height: 4px; border-radius: 2px; background: #333; outline: none; cursor: pointer;
}
.xie-slider::-webkit-slider-thumb {
  -webkit-appearance: none; width: 16px; height: 16px;
  border-radius: 50%; background: var(--primary); cursor: pointer;
}
.xie-slider::-moz-range-thumb {
  width: 16px; height: 16px; border-radius: 50%; background: var(--primary); border: none; cursor: pointer;
}
.xie-slider-val { color: #777; font-size: .75rem; width: 32px; text-align: right; flex-shrink: 0; }
.xie-reset-btn {
  align-self: flex-end; margin-top: .25rem;
  background: none; border: 1px solid #333; color: #888;
  border-radius: 12px; padding: .3rem .75rem; font-size: .8rem; cursor: pointer;
}
.xie-reset-btn:hover { background: #222; color: #ccc; }

/* Filters tab */
.xie-presets {
  display: flex; gap: .5rem; padding: .5rem .75rem;
  overflow-x: auto; scrollbar-width: none;
}
.xie-presets::-webkit-scrollbar { display: none; }
.xie-preset {
  display: flex; flex-direction: column; align-items: center; gap: .3rem;
  flex-shrink: 0; cursor: pointer;
}
.xie-preset img {
  width: 72px; height: 72px; object-fit: cover;
  border-radius: 8px; border: 2.5px solid transparent;
  transition: border-color .2s;
}
.xie-preset.active img { border-color: var(--primary); }
.xie-preset span { font-size: .7rem; color: #999; text-align: center; }
.xie-preset.active span { color: #fff; font-weight: 600; }

/* Material Symbols ligature helper (editor & generic use) */
.ms-icon {
  font-family: 'Material Symbols Rounded';
  font-size: 1.25rem; line-height: 1;
  display: inline-flex; align-items: center; justify-content: center;
  font-variation-settings: 'FILL' 1, 'wght' 400, 'GRAD' 0, 'opsz' 24;
  vertical-align: middle; color: inherit;
}

/* ── Video Editor (xve) ─────────────────────────────────────────────────── */
.xve-overlay { user-select: none; }

.xve-frame-wrap { position: relative; }

.xve-frame {
  width: 100%; height: 100%;
  display: flex; align-items: center; justify-content: center;
  background: #000; overflow: hidden;
}

.xve-play-overlay {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
}
.xve-play-icon {
  width: 72px; height: 72px; border-radius: 50%;
  background: rgba(0,0,0,.45); backdrop-filter: blur(6px);
  border: 2px solid rgba(255,255,255,.25);
  display: flex; align-items: center; justify-content: center;
  color: #fff; transition: background .2s;
}

/* ── AgathaAI attach buttons ─────────────────────────────────────────────── */
.ai-attach-btn {
  background: linear-gradient(135deg, var(--primary-light), #f0e8ff);
  color: var(--primary-dark);
  border: 1px solid var(--primary);
  gap: .3rem;
}
.ai-attach-btn:hover { background: linear-gradient(135deg, #d5eaf6, #e8d8ff); }
.ai-attach-btn .ms-icon { font-size: 1.05rem; }
[data-theme="dark"] .ai-attach-btn {
  background: linear-gradient(135deg, rgba(91,181,216,.14), rgba(160,100,220,.14));
  color: var(--primary-mid);
  border-color: rgba(91,181,216,.35);
}
[data-theme="dark"] .ai-attach-btn:hover {
  background: linear-gradient(135deg, rgba(91,181,216,.24), rgba(160,100,220,.24));
}

/* ── AgathaAI Modal ──────────────────────────────────────────────────────── */
.ai-modal-overlay {
  position: fixed; inset: 0; z-index: 9999;
  background: rgba(0,0,0,.55); backdrop-filter: blur(4px);
  display: flex; align-items: center; justify-content: center;
  padding: 1rem;
  opacity: 0; transition: opacity .2s;
}
.ai-modal-overlay.open { opacity: 1; }

.ai-modal {
  background: var(--surface);
  border-radius: 18px;
  box-shadow: 0 24px 64px rgba(0,0,0,.22);
  width: 100%; max-width: 400px;
  overflow: hidden;
  transform: translateY(20px); transition: transform .25s;
}
.ai-modal-overlay.open .ai-modal { transform: translateY(0); }

.ai-modal-header {
  display: flex; align-items: center;
  padding: 1rem 1.25rem .75rem;
  border-bottom: 1px solid var(--divider);
}

.ai-modal-body { padding: 1rem 1.25rem; }

.ai-modal-textarea {
  width: 100%; box-sizing: border-box;
  resize: vertical; min-height: 90px;
  border: 1.5px solid var(--border);
  border-radius: 10px;
  padding: .65rem .8rem;
  font-size: .95rem;
  font-family: inherit;
  background: var(--surface2);
  color: var(--text);
  outline: none;
  transition: border-color .15s;
}
.ai-modal-textarea:focus { border-color: var(--primary); }

.ai-modal-status {
  display: flex; align-items: center; gap: .75rem;
  padding: .5rem 1.25rem;
  font-size: .85rem; color: var(--text3);
}

.ai-spinner {
  width: 18px; height: 18px; flex-shrink: 0;
  border: 2.5px solid var(--border);
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin .7s linear infinite;
}

/* ── Comment replies & edit ─────────────────────────────────────────────── */
.comment-reply { margin-left: 2.5rem; }
.comment-action-btn {
  background: none; border: none; cursor: pointer;
  font-size: .78rem; color: var(--primary);
  padding: 0 .3rem;
}
.comment-show-replies {
  background: none; border: none; cursor: pointer;
  font-size: .8rem; color: var(--primary);
  padding: .2rem 0; display: block;
}
.comment-replies-list { margin-left: .25rem; }
.reply-input-wrap {
  display: flex; align-items: center; gap: .5rem;
  margin-top: .5rem;
}
.reply-field {
  flex: 1; border: 1.5px solid var(--border);
  border-radius: 20px; padding: .4rem .8rem;
  font-size: .9rem; background: var(--surface2); color: var(--text);
}
.reply-field:focus { outline: none; border-color: var(--primary); }
.comment-edit-textarea {
  width: 100%; box-sizing: border-box;
  border: 1.5px solid var(--primary);
  border-radius: 8px; padding: .5rem .75rem;
  font-size: .9rem; font-family: inherit;
  background: var(--surface2); color: var(--text);
  resize: vertical; min-height: 60px;
}

/* ── Rich text toolbar ───────────────────────────────────────────────────── */
.richtext-toolbar {
  display: flex; gap: .3rem; padding: .3rem .5rem;
  border: 1px solid var(--border); border-bottom: none;
  border-radius: 10px 10px 0 0;
  background: var(--surface2);
}
.rt-btn {
  background: none; border: 1px solid transparent;
  border-radius: 6px; cursor: pointer;
  font-size: .9rem; padding: .2rem .5rem;
  color: var(--text2); line-height: 1.3;
}
.rt-btn:hover { background: var(--surface3); border-color: var(--border); }
.post-input-area { border-radius: 0 0 10px 10px !important; }

/* ── Emoji picker ────────────────────────────────────────────────────────── */
.emoji-picker {
  display: flex; flex-wrap: wrap; gap: .2rem;
  padding: .4rem .5rem;
  background: var(--surface2); border: 1px solid var(--border);
  border-radius: 10px; margin-bottom: .3rem;
  max-height: 120px; overflow-y: auto;
}
.emoji-opt {
  background: none; border: none; cursor: pointer;
  font-size: 1.2rem; padding: .1rem .2rem; line-height: 1;
  border-radius: 4px;
}
.emoji-opt:hover { background: var(--surface3); }

/* ── Check-in chip ───────────────────────────────────────────────────────── */
.checkin-chip {
  display: inline-flex; align-items: center;
  background: var(--primary-light, #e8f4f8);
  color: var(--primary);
  border-radius: 20px; padding: .3rem .75rem;
  font-size: .82rem; margin: .4rem 0;
}

/* ── Cart ────────────────────────────────────────────────────────────────── */
.cart-wrap { display: flex; flex-direction: column; min-height: 100%; }
.cart-items { flex: 1; padding: .75rem; }
.cart-item {
  display: flex; align-items: flex-start; gap: .75rem;
  background: var(--surface); border-radius: 14px;
  padding: .75rem; margin-bottom: .75rem;
  box-shadow: 0 1px 4px rgba(0,0,0,.06);
}
.cart-item-img { width: 72px; height: 72px; flex-shrink: 0; border-radius: 10px; overflow: hidden; background: var(--surface2); }
.cart-item-img img { width: 100%; height: 100%; object-fit: cover; }
.cart-no-img { display: flex; align-items: center; justify-content: center; height: 100%; color: var(--text3); }
.cart-item-info { flex: 1; }
.cart-item-title { font-size: .9rem; font-weight: 600; line-height: 1.3; margin-bottom: .2rem; }
.cart-item-opts  { font-size: .78rem; color: var(--text3); margin-bottom: .2rem; }
.cart-item-price { font-size: .95rem; font-weight: 700; color: var(--primary); }
.cart-item-ctrl  { display: flex; align-items: center; gap: .4rem; margin-top: .4rem; }
.cart-qty-btn {
  width: 28px; height: 28px; border-radius: 50%; border: 1.5px solid var(--border);
  background: var(--surface2); cursor: pointer; font-size: 1rem; line-height: 1;
  display: flex; align-items: center; justify-content: center;
}
.cart-qty-btn:disabled { opacity: .35; cursor: default; }
.cart-qty-num { font-size: .95rem; font-weight: 600; min-width: 20px; text-align: center; }
.cart-remove-btn {
  background: none; border: none; cursor: pointer;
  color: var(--error, #ef4444); padding: .25rem; flex-shrink: 0;
}
.cart-footer {
  padding: 1rem;
  background: var(--surface);
  border-top: 1px solid var(--divider);
  position: sticky; bottom: 0;
}
.cart-subtotal { display: flex; justify-content: space-between; align-items: center; font-size: .95rem; }
.cart-total-val { font-size: 1.1rem; font-weight: 700; color: var(--primary); }

/* ── Checkout ─────────────────────────────────────────────────────────────── */
.checkout-wrap { padding: 1rem; padding-bottom: 4rem; max-width: 520px; margin: auto; }
.checkout-steps {
  display: flex; align-items: center; margin-bottom: 1.5rem; gap: 0;
}
.checkout-step { display: flex; flex-direction: column; align-items: center; flex: 1; }
.step-circle {
  width: 32px; height: 32px; border-radius: 50%;
  border: 2px solid var(--border);
  display: flex; align-items: center; justify-content: center;
  font-size: .85rem; font-weight: 700; color: var(--text3);
  background: var(--surface2);
  transition: all .2s;
}
.checkout-step.active .step-circle { border-color: var(--primary); background: var(--primary); color: #fff; }
.checkout-step.done   .step-circle { border-color: var(--success,#10b981); background: var(--success,#10b981); color: #fff; }
.step-label { font-size: .72rem; margin-top: .3rem; color: var(--text3); }
.checkout-step.active .step-label { color: var(--primary); font-weight: 600; }
.step-line { flex: 1; height: 2px; background: var(--border); margin: 0 4px; margin-bottom: 18px; }
.checkout-section-title { font-size: .85rem; font-weight: 700; color: var(--text3); text-transform: uppercase; letter-spacing: .05em; margin-bottom: .75rem; }
.checkout-field { margin-bottom: .75rem; }
.checkout-label { font-size: .82rem; color: var(--text2); display: block; margin-bottom: .3rem; }
.checkout-input {
  width: 100%; box-sizing: border-box;
  border: 1.5px solid var(--border); border-radius: 10px;
  padding: .6rem .85rem; font-size: .95rem;
  background: var(--surface2); color: var(--text);
  outline: none; transition: border-color .15s;
}
.checkout-input:focus { border-color: var(--primary); }
.shipping-list { display: flex; flex-direction: column; gap: .6rem; }
.shipping-option {
  display: flex; align-items: center; gap: .75rem;
  border: 1.5px solid var(--border); border-radius: 12px; padding: .75rem 1rem;
  cursor: pointer; transition: border-color .15s, background .15s;
}
.shipping-option input { display: none; }
.shipping-option.selected { border-color: var(--primary); background: var(--primary-light, #e8f4f8); }
.shipping-info { flex: 1; }
.shipping-name { font-size: .9rem; font-weight: 600; }
.shipping-eta  { font-size: .78rem; color: var(--text3); }
.shipping-price { font-size: .9rem; font-weight: 700; color: var(--primary); }
.payment-methods { display: flex; flex-direction: column; gap: .6rem; }
.payment-opt {
  display: flex; align-items: center; gap: .75rem;
  border: 1.5px solid var(--border); border-radius: 12px; padding: .75rem 1rem;
  cursor: pointer; transition: border-color .15s, background .15s;
}
.payment-opt input { display: none; }
.payment-opt.selected { border-color: var(--primary); background: var(--primary-light, #e8f4f8); }
.order-confirm { padding: 3rem 1.5rem; text-align: center; }
.order-confirm-icon { margin-bottom: 1rem; }
.order-confirm-title { font-size: 1.5rem; font-weight: 800; margin: 0 0 .5rem; }
.order-confirm-sub { color: var(--text2); font-size: .95rem; }

/* ── Orders ──────────────────────────────────────────────────────────────── */
.orders-list { padding: .75rem; }
.order-card {
  background: var(--surface); border-radius: 14px;
  padding: .85rem 1rem; margin-bottom: .85rem;
  box-shadow: 0 1px 4px rgba(0,0,0,.06); cursor: pointer;
}
.order-card-header { display: flex; align-items: flex-start; justify-content: space-between; margin-bottom: .5rem; }
.order-number { font-size: .9rem; font-weight: 700; }
.order-date   { font-size: .78rem; color: var(--text3); margin-top: .1rem; }
.order-status-badge { font-size: .75rem; font-weight: 700; padding: .2rem .6rem; border-radius: 20px; }
.order-thumbs { display: flex; gap: .4rem; margin: .5rem 0; align-items: center; }
.order-thumb { width: 44px; height: 44px; border-radius: 8px; object-fit: cover; }
.order-thumb-more { font-size: .78rem; color: var(--text3); }
.order-card-footer { display: flex; justify-content: space-between; align-items: center; margin-top: .4rem; }
.order-total { font-size: 1rem; font-weight: 700; color: var(--primary); }
.order-detail-section { padding: .75rem 0; border-bottom: 1px solid var(--divider); }
.order-detail-section:last-child { border-bottom: none; }
.order-detail-title { font-size: .82rem; font-weight: 700; color: var(--text3); text-transform: uppercase; letter-spacing: .05em; margin-bottom: .5rem; }
.order-item-row { display: flex; align-items: center; gap: .75rem; padding: .4rem 0; }
.order-item-img { width: 52px; height: 52px; border-radius: 8px; object-fit: cover; }
.order-item-info { flex: 1; }
.order-timeline { display: flex; flex-direction: column; gap: .75rem; padding-left: .5rem; }
.order-timeline-item { display: flex; gap: .75rem; align-items: flex-start; }
.timeline-dot {
  width: 10px; height: 10px; border-radius: 50%;
  background: var(--primary); flex-shrink: 0; margin-top: .25rem;
}

/* ── Games ───────────────────────────────────────────────────────────────── */
.games-cat-bar {
  display: flex;
  overflow-x: auto;
  gap: .4rem;
  padding: .6rem .75rem;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 56px;
  z-index: 10;
  scrollbar-width: none;
  min-height: 44px;
  align-items: center;
}
.games-cat-bar::-webkit-scrollbar { display: none; }
.games-cat-btn {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: .3rem;
  padding: .3rem .75rem;
  border-radius: 99px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text2);
  font-size: .78rem;
  cursor: pointer;
  white-space: nowrap;
  transition: background .15s, color .15s, border-color .15s;
}
.games-cat-btn:hover  { background: var(--hover, rgba(0,0,0,.06)); color: var(--text1); }
.games-cat-btn.active { background: var(--primary); color: #fff; border-color: var(--primary); }

.game-card {
  background: var(--surface);
  border-radius: 12px;
  padding: 0;
  cursor: pointer;
  box-shadow: 0 2px 10px rgba(0,0,0,.08);
  transition: transform .18s, box-shadow .18s;
  overflow: hidden;
}
.game-card:hover  { transform: translateY(-3px); box-shadow: 0 8px 24px rgba(0,0,0,.16); }
.game-card:active { transform: scale(.97); box-shadow: none; }

/* Thumbnail — aspect-ratio 3:2, edge-to-edge */
.game-card-thumb {
  width: 100%; aspect-ratio: 3/2;
  display: flex; align-items: center; justify-content: center;
  overflow: hidden; position: relative;
}
.game-card-img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* Botão play no hover */
.game-card-play {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  background: rgba(0,0,0,.42);
  opacity: 0; transition: opacity .18s;
}
.game-card-play .ms-icon { font-size: 3rem; color: #fff; filter: drop-shadow(0 2px 8px rgba(0,0,0,.6)); }
.game-card:hover .game-card-play { opacity: 1; }

/* Área de texto abaixo da imagem */
.game-card-info  { padding: .6rem .7rem .65rem; }
.game-card-title { font-size: .85rem; font-weight: 700; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; margin-bottom: .25rem; }
.game-card-views { font-size: .7rem; color: var(--text3); display: flex; align-items: center; gap: .2rem; }
.game-card-views .ms-icon { font-size: .75rem; }

/* ── OTP login ───────────────────────────────────────────────────────────── */
.login-divider-thin { text-align: center; font-size: .82rem; color: var(--text3); margin: .75rem 0; position: relative; }
.login-divider-thin::before,
.login-divider-thin::after { content: ''; position: absolute; top: 50%; width: 42%; height: 1px; background: var(--divider); }
.login-divider-thin::before { left: 0; }
.login-divider-thin::after  { right: 0; }
.otp-ddi-select {
  border: 1.5px solid var(--border); border-radius: 10px;
  padding: .6rem .5rem; background: var(--surface2); color: var(--text);
  font-size: .9rem; outline: none;
}
.otp-digits { display: flex; gap: .5rem; justify-content: center; margin: .75rem 0; }
.otp-digit {
  width: 44px; height: 52px; text-align: center; font-size: 1.4rem; font-weight: 700;
  border: 2px solid var(--border); border-radius: 10px;
  background: var(--surface2); color: var(--text); outline: none;
  transition: border-color .15s;
}
.otp-digit:focus { border-color: var(--primary); }

/* ── Product detail ──────────────────────────────────────────────────────── */
.product-gallery { position: relative; background: var(--surface2); }
.product-gallery-main img { width: 100%; max-height: 320px; object-fit: contain; }
.product-thumbs { display: flex; gap: .4rem; padding: .5rem .75rem; overflow-x: auto; }
.product-thumb { width: 56px; height: 56px; border-radius: 8px; object-fit: cover; flex-shrink: 0; cursor: pointer; border: 2px solid transparent; }
.product-thumb.active { border-color: var(--primary); }
.product-info { padding: 1rem; }
.product-title { font-size: 1.1rem; font-weight: 800; margin: 0 0 .3rem; }
.product-price { font-size: 1.3rem; font-weight: 700; color: var(--primary); margin-bottom: .75rem; }
.product-options { margin-bottom: 1rem; }
.product-options-label { font-size: .82rem; color: var(--text3); margin-bottom: .4rem; }
.option-pills { display: flex; flex-wrap: wrap; gap: .4rem; }
.option-pill {
  border: 1.5px solid var(--border); border-radius: 20px; padding: .3rem .8rem;
  font-size: .85rem; cursor: pointer; background: var(--surface2);
  transition: all .15s;
}
.option-pill.selected { border-color: var(--primary); background: var(--primary); color: #fff; }
.qty-stepper { display: flex; align-items: center; gap: .6rem; margin-bottom: 1rem; }
.qty-btn { width: 36px; height: 36px; border-radius: 50%; border: 1.5px solid var(--border); background: var(--surface2); cursor: pointer; font-size: 1.2rem; display: flex; align-items: center; justify-content: center; }
.qty-num { font-size: 1rem; font-weight: 700; min-width: 28px; text-align: center; }

/* ── Gerenciador de módulos (Settings) ───────────────────────────────────── */
.settings-hint {
  font-size: .82rem; color: var(--text3);
  margin: -.25rem 0 .75rem; line-height: 1.5;
}
.mod-group { margin-bottom: 1rem; }
.mod-group-label {
  font-size: .72rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: .07em; color: var(--text3);
  padding: .3rem 0 .4rem; border-bottom: 1px solid var(--divider);
  margin-bottom: .25rem;
}
.mod-row {
  display: flex; align-items: center; gap: .65rem;
  padding: .55rem 0;
  border-bottom: 1px solid var(--divider);
}
.mod-row:last-child { border-bottom: none; }
.mod-row-icon {
  font-size: 1.15rem; color: var(--text3); flex-shrink: 0;
  font-family: 'Material Symbols Rounded';
  font-variation-settings: 'FILL' 1, 'wght' 400, 'GRAD' 0, 'opsz' 24;
  line-height: 1;
}
.mod-row-label { flex: 1; font-size: .9rem; }
.mod-row-disabled { opacity: .45; }
.mod-server-off {
  font-size: .72rem; color: var(--text3);
  background: var(--surface3); border-radius: 6px;
  padding: .15rem .45rem; white-space: nowrap;
}

.ai-modal-footer {
  display: flex; justify-content: flex-end; gap: .5rem;
  padding: .75rem 1.25rem 1rem;
  border-top: 1px solid var(--divider);
}
.xve-play-icon:hover { background: rgba(0,0,0,.65); }

/* Export progress */
.xve-export-progress {
  position: absolute; inset: 0;
  background: rgba(0,0,0,.7); backdrop-filter: blur(8px);
  display: flex; align-items: center; justify-content: center;
}
.xve-export-text {
  color: #fff; font-size: 1.1rem; font-weight: 700;
  display: flex; flex-direction: column; align-items: center; gap: .5rem;
}

/* Timeline / trim */
.xve-timeline-wrap {
  background: #0a0a0a; padding: .5rem .75rem .4rem;
  flex-shrink: 0;
}
.xve-time-labels {
  display: flex; justify-content: space-between;
  font-size: .75rem; color: #888; margin-bottom: .25rem;
}
.xve-timeline {
  position: relative; height: 28px;
}
.xve-timeline-range {
  position: absolute; top: 10px; height: 8px;
  background: var(--primary); border-radius: 4px;
  pointer-events: none;
  --playhead: 0%;
}
/* Playhead indicator */
.xve-timeline-range::after {
  content: '';
  position: absolute; top: -3px; left: var(--playhead);
  width: 3px; height: 14px; background: #fff; border-radius: 2px;
  transform: translateX(-50%);
  transition: left .1s linear;
}
/* Base track behind sliders */
.xve-timeline::before {
  content: ''; position: absolute; top: 10px; left: 0; right: 0;
  height: 8px; background: #2a2a2a; border-radius: 4px;
}
.xve-slider {
  position: absolute; top: 0; left: 0; right: 0; width: 100%;
  -webkit-appearance: none; appearance: none;
  height: 28px; background: transparent;
  pointer-events: none;
}
.xve-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 18px; height: 28px; border-radius: 4px;
  background: #fff; cursor: pointer;
  pointer-events: all;
  box-shadow: 0 1px 4px rgba(0,0,0,.5);
}
.xve-slider::-moz-range-thumb {
  width: 18px; height: 28px; border-radius: 4px;
  background: #fff; cursor: pointer;
  pointer-events: all; border: none;
  box-shadow: 0 1px 4px rgba(0,0,0,.5);
}
.xve-slider-end { z-index: 2; }

.xve-trim-labels {
  display: flex; justify-content: space-between;
  font-size: .72rem; color: #666; margin-top: .3rem;
}
.xve-trim-labels b { color: #aaa; }

/* Filter controls (videos share xie-presets) */
.xve-controls { overflow-x: auto; overflow-y: hidden; }
.xve-presets  { flex-wrap: nowrap; padding: .5rem .75rem; }

/* Loading thumbs */
.xve-thumbs-loading {
  display: flex; align-items: center; justify-content: center;
  gap: .75rem; padding: 1.5rem;
  color: #777; font-size: .88rem;
}

/* Story create — foto + vídeo */
.story-pick-row {
  display: flex; gap: .75rem; margin-bottom: .5rem;
}
.story-pick-btn {
  flex: 1; display: flex; align-items: center; justify-content: center;
  gap: .4rem; cursor: pointer;
  padding: .65rem; background: var(--surface3);
  border-radius: var(--radius-sm); font-size: .9rem; color: var(--text);
  transition: background .2s;
}
.story-pick-btn:hover { background: var(--surface2); }
.story-pick-btn .ms-icon { font-size: 1.2rem; color: var(--primary); }

/* Story destination selector */
.story-dest-label {
  font-size: .82rem; color: var(--text3); font-weight: 600;
  text-transform: uppercase; letter-spacing: .05em;
}
.story-dest-row {
  display: flex; gap: .5rem;
}
.story-dest-btn {
  flex: 1; display: flex; align-items: center; justify-content: center; gap: .3rem;
  padding: .55rem .4rem; border-radius: var(--radius-sm);
  background: var(--surface3); border: 1.5px solid transparent;
  font-size: .82rem; color: var(--text2); cursor: pointer; transition: all .18s;
}
.story-dest-btn.active {
  background: color-mix(in srgb, var(--primary) 12%, transparent);
  border-color: var(--primary); color: var(--primary); font-weight: 600;
}
.story-dest-btn:not(.active):hover { background: var(--surface2); }

/* ── Reactions panel ─────────────────────────────────────────────────────── */
.reaction-wrap { position: relative; }
.reaction-panel {
  position: absolute; bottom: calc(100% + 6px); left: 0;
  display: flex; gap: .25rem;
  background: var(--surface); border: 1px solid var(--divider);
  border-radius: 999px; padding: .3rem .45rem;
  box-shadow: 0 4px 16px rgba(0,0,0,.18);
  opacity: 0; pointer-events: none;
  transform: scale(.75) translateY(8px);
  transition: opacity .18s, transform .18s;
  z-index: 200; white-space: nowrap;
}
.reaction-panel.open {
  opacity: 1; pointer-events: all;
  transform: scale(1) translateY(0);
}
.reaction-opt {
  font-size: 1.5rem; background: none; border: none; cursor: pointer;
  padding: .15rem .2rem; border-radius: 50%;
  transition: transform .12s;
  line-height: 1;
}
.reaction-opt:hover, .reaction-opt.active { transform: scale(1.4); }
.reaction-icon { font-size: 1rem; line-height: 1; }
.like-btn.liked .reaction-icon { filter: none; }

/* ── Pinned post ─────────────────────────────────────────────────────────── */
.post-pinned { border-left: 3px solid var(--primary); }
.pin-badge {
  font-size: .75rem; color: var(--primary); font-weight: 600;
  padding: .3rem .75rem .1rem; display: flex; align-items: center;
}

/* ── Post author line ────────────────────────────────────────────────────── */
.post-author-line { display: flex; align-items: center; flex-wrap: wrap; gap: .2rem; }
.post-action-sub  { font-size: .82rem; color: var(--text3); font-weight: 400; }

/* ── Feeling badge ───────────────────────────────────────────────────────── */
.feeling-badge { font-size: .85rem; color: var(--text2); }

/* ── Reactions: image icons ──────────────────────────────────────────────── */
.reaction-img-icon      { width: 24px; height: 24px; object-fit: contain; vertical-align: middle; }
.reaction-panel-icon    { width: 32px; height: 32px; object-fit: contain; }
.reaction-opt           { display: flex; flex-direction: column; align-items: center; gap: 2px; }
.reaction-opt-label     { font-size: .6rem; color: #fff; font-weight: 600; text-shadow: 0 1px 3px rgba(0,0,0,.8); line-height: 1; }

/* ── Story view count bar ────────────────────────────────────────────────── */
.story-view-count-bar {
  position: absolute; bottom: 3.5rem; left: 50%; transform: translateX(-50%);
  background: rgba(0,0,0,.5); color: #fff; padding: .35rem .9rem; border-radius: 20px;
  display: flex; align-items: center; gap: .3rem; cursor: default; user-select: none;
}

/* ── Sticker grid picker ─────────────────────────────────────────────────── */
.sticker-opt:hover { outline: 2px solid var(--primary); outline-offset: 1px; }

/* ── Tag chips ───────────────────────────────────────────────────────────── */
.tag-chip {
  display: inline-flex; align-items: center; gap: .3rem;
  background: var(--hover); border-radius: 20px; padding: .2rem .5rem .2rem .25rem;
  font-size: .8rem;
}
.tag-chip img { width: 22px; height: 22px; border-radius: 50%; object-fit: cover; }

/* ── Post text with background ───────────────────────────────────────────── */
#post-text.has-bg {
  min-height: 140px; border-radius: 12px;
  font-size: 1.2rem; font-weight: 600; text-align: center;
  transition: background .2s, color .2s;
}

/* ── Post location ───────────────────────────────────────────────────────── */
.post-location {
  font-size: .8rem; color: var(--text3); padding: .1rem .75rem .4rem;
  display: flex; align-items: center;
}

/* ── Multi-photo grid ────────────────────────────────────────────────────── */
.post-photos-grid {
  display: grid; gap: 2px; overflow: hidden;
  border-radius: 0;
}
.post-photos-grid.grid-1 { grid-template-columns: 1fr; max-height: 400px; }
.post-photos-grid.grid-2 { grid-template-columns: 1fr 1fr; max-height: 260px; }
.post-photos-grid.grid-3 { grid-template-columns: 1fr 1fr; max-height: 260px; }
.post-photos-grid.grid-3 .photo-grid-item:first-child { grid-row: span 2; }
.post-photos-grid.grid-4 { grid-template-columns: 1fr 1fr; max-height: 260px; }
.photo-grid-item {
  position: relative; overflow: hidden; cursor: pointer; background: var(--surface3);
}
.photo-grid-item img {
  width: 100%; height: 100%; object-fit: cover; display: block;
  transition: transform .2s;
}
.photo-grid-item:hover img { transform: scale(1.03); }
.photo-more-overlay {
  position: absolute; inset: 0;
  background: rgba(0,0,0,.55); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.6rem; font-weight: 700;
}

/* ── Field label (video/link sheets) ────────────────────────────────────── */
.field-label {
  display: block;
  font-size: .82rem;
  font-weight: 600;
  color: var(--text2);
  margin-bottom: .3rem;
}

/* ── YouTube / Dailymotion embed in feed ────────────────────────────────── */
.post-yt-embed {
  position: relative;
  padding-bottom: 56.25%; /* 16:9 */
  height: 0;
  overflow: hidden;
  border-radius: var(--radius-sm);
  margin: .5rem 0;
  background: #000;
}

/* ── Clickable URLs in post body ────────────────────────────────────────── */
.post-url-link {
  color: var(--primary);
  text-decoration: none;
  word-break: break-all;
}
.post-url-link:hover { text-decoration: underline; }

/* ── Video library attachment title (sitevideo_video_new) ───────────────── */
.post-video-info  { padding: .3rem .8rem .6rem; }
.post-video-title { font-size: .9rem; font-weight: 700; color: var(--text); display: block; line-height: 1.35; margin-bottom: .2rem; }
.post-video-title:hover { color: var(--primary); }
.post-video-desc  { font-size: .82rem; color: var(--text3); line-height: 1.45; margin: 0; }
.post-video-card  { position: relative; cursor: pointer; }
.post-video-play-btn {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  background: rgba(0,0,0,.25);
}
.post-video-play-btn .ms-icon { font-size: 3.5rem; color: #fff; filter: drop-shadow(0 2px 6px rgba(0,0,0,.5)); }

/* ── Post video ──────────────────────────────────────────────────────────── */
.post-video { position: relative; cursor: pointer; background: #000; max-height: 360px; overflow: hidden; }
.post-video-thumb { width: 100%; max-height: 360px; object-fit: cover; display: block; }
.post-video-thumb-placeholder { width: 100%; height: 220px; background: #111; }
.post-video-play {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
}
.video-fullscreen-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,.95); z-index: 1000;
  display: flex; align-items: center; justify-content: center;
  opacity: 0; transition: opacity .22s;
}
.video-fullscreen-overlay.open { opacity: 1; }
.vfs-close {
  position: absolute; top: 1rem; right: 1rem;
  background: rgba(255,255,255,.15); border: none; border-radius: 50%;
  width: 2.5rem; height: 2.5rem; color: #fff; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
}
.vfs-video { max-width: 100%; max-height: 85vh; border-radius: 8px; }

/* ── Post music player ───────────────────────────────────────────────────── */
.post-music-player {
  display: flex; align-items: center; gap: .75rem;
  margin: 0; padding: .75rem;
  background: var(--surface3); border-radius: var(--radius-sm);
}
.post-music-info { flex: 1; min-width: 0; }
.post-music-title { font-weight: 600; font-size: .9rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.post-music-artist { font-size: .78rem; color: var(--text3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.post-music-play {
  background: none; border: none; cursor: pointer;
  color: var(--primary); font-size: 2rem; flex-shrink: 0;
  display: flex; align-items: center;
}

/* ── Link preview card ───────────────────────────────────────────────────── */
.post-link-preview {
  border: 1px solid var(--divider); border-radius: var(--radius-sm);
  overflow: hidden; cursor: pointer;
  transition: background .15s;
}
.post-link-preview:hover { background: var(--surface3); }
.link-preview-image { width: 100%; max-height: 200px; object-fit: cover; display: block; }
.link-preview-body { padding: .6rem .75rem; }
.link-preview-url { font-size: .72rem; color: var(--text3); text-transform: uppercase; letter-spacing: .04em; }
.link-preview-title { font-weight: 600; font-size: .88rem; margin: .2rem 0; }
.link-preview-desc { font-size: .8rem; color: var(--text2); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* ── Link preview card (composer) ───────────────────────────────────────── */
.link-preview-card {
  position: relative; border: 1px solid var(--divider); border-radius: var(--radius-sm);
  overflow: hidden; background: var(--surface2);
}
.link-preview-video-wrap {
  position: relative; padding-bottom: 56.25%; background: #000;
}
.link-preview-thumb {
  width: 100%; max-height: 160px; object-fit: cover; display: block;
}
.link-preview-info { padding: .5rem .75rem; padding-right: 2.2rem; }
.link-preview-host { font-size: .7rem; color: var(--text3); text-transform: uppercase; letter-spacing: .04em; margin-bottom: .15rem; }
.link-preview-title { font-weight: 600; font-size: .85rem; }
.link-preview-desc  { font-size: .78rem; color: var(--text2); margin-top: .1rem; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.link-preview-remove {
  position: absolute; top: .4rem; right: .4rem;
  background: rgba(0,0,0,.55); color: #fff; border: none; border-radius: 50%;
  width: 22px; height: 22px; font-size: .8rem; cursor: pointer; line-height: 22px; text-align: center;
}

/* ── Shared post card ────────────────────────────────────────────────────── */
.shared-post-card {
  border: 1px solid var(--divider); border-radius: var(--radius-sm);
  padding: .75rem; margin: 0; background: var(--surface3);
}
.shared-post-header { display: flex; align-items: center; gap: .5rem; margin-bottom: .4rem; }
.shared-post-body { font-size: .88rem; margin-bottom: .4rem; color: var(--text); word-break: break-word; }
.shared-post-image { width: 100%; max-height: 240px; object-fit: cover; border-radius: 4px; }

/* ── Embedded post stub (async loaded shared post) ──────────────────────── */
.post-embedded-stub {
  display: flex; align-items: center; gap: .5rem; padding: .65rem .75rem;
  border: 1px dashed var(--divider); border-radius: var(--radius-sm);
  background: var(--surface3); cursor: pointer; color: var(--text3);
  margin: 0;
}
.post-embedded-stub:hover { background: var(--surface2); }

/* ── Post likes bar ──────────────────────────────────────────────────────── */
.post-likes-bar {
  padding: .25rem .75rem .4rem; font-size: .8rem; color: var(--text3);
  cursor: pointer; border-top: 1px solid var(--divider);
}
.post-likes-bar:hover { color: var(--primary); }

/* ── Hashtag link ────────────────────────────────────────────────────────── */
.post-hashtag { color: var(--primary); text-decoration: none; font-weight: 500; }
.post-hashtag:hover { text-decoration: underline; }

/* ── People suggestions card ─────────────────────────────────────────────── */
.people-suggestion-card {
  background: var(--surface); border-radius: var(--radius);
  padding: 1rem; margin-bottom: .75rem;
  box-shadow: 0 1px 4px rgba(0,0,0,.07);
}
.people-suggestion-title {
  font-weight: 700; font-size: .9rem; color: var(--text2);
  margin-bottom: .75rem;
}
.people-suggestion-list { display: flex; flex-direction: column; gap: .6rem; }
.people-suggestion-item {
  display: flex; align-items: center; gap: .6rem; cursor: pointer;
  padding: .25rem 0;
}
.people-suggestion-item:hover { background: transparent; }
.people-suggestion-name { flex: 1; font-size: .88rem; font-weight: 600; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ── Feeling picker option ───────────────────────────────────────────────── */
.feeling-option {
  display: flex; flex-direction: column; align-items: center;
  gap: .2rem; padding: .5rem .25rem; border: none;
  background: var(--surface3); border-radius: var(--radius-sm);
  cursor: pointer; font-size: .78rem; color: var(--text);
  transition: background .15s;
}
.feeling-option:hover { background: var(--surface2); }

/* ── Detail page layout ──────────────────────────────────────────────────── */
.detail-page { padding-bottom: var(--bottomnav-h); }
.detail-cover-img {
  width: 100%; max-height: 280px; object-fit: cover; display: block;
}
.detail-content { padding: .85rem .75rem; }
.detail-main-title { font-size: 1.25rem; font-weight: 800; margin: 0 0 .5rem; line-height: 1.3; }
.detail-byline {
  display: flex; align-items: center; flex-wrap: wrap; gap: .35rem;
  font-size: .85rem; color: var(--text2); margin-bottom: .75rem;
}
.detail-body-text {
  font-size: .92rem; line-height: 1.7; color: var(--text2);
  margin-bottom: 1rem; word-break: break-word;
}
.detail-actions-bar {
  display: flex; gap: .6rem; margin-bottom: 1rem;
  flex-wrap: wrap;
}
.detail-section-title {
  font-size: .85rem; font-weight: 700; color: var(--text3);
  text-transform: uppercase; letter-spacing: .05em;
  margin: .75rem 0 .5rem; padding-bottom: .3rem;
  border-bottom: 1px solid var(--divider);
}
.detail-tags { display: flex; flex-wrap: wrap; gap: .4rem; margin: .75rem 0; }
.detail-tag {
  background: var(--surface3); border-radius: 20px;
  padding: .25rem .65rem; font-size: .78rem; color: var(--primary);
}

/* detail header (groups, etc.) */
.detail-cover {
  width: 100%; height: 180px; background: var(--surface3);
  overflow: hidden; display: flex; align-items: center; justify-content: center;
  background-size: cover; background-position: center;
}
.detail-cover img { width: 100%; height: 100%; object-fit: cover; }
.detail-header {
  display: flex; align-items: flex-end; gap: .75rem;
  padding: .75rem; margin-top: -2rem;
}
.detail-avatar {
  width: 72px; height: 72px; border-radius: 50%;
  object-fit: cover; border: 3px solid var(--surface);
  box-shadow: 0 2px 8px rgba(0,0,0,.15); flex-shrink: 0;
}
.detail-header-info { flex: 1; padding-bottom: .25rem; }
.detail-title { font-size: 1.1rem; font-weight: 800; margin: 0 0 .15rem; }
.detail-meta { font-size: .8rem; color: var(--text3); }
.detail-actions {
  display: flex; gap: .6rem; padding: .5rem .75rem .75rem;
  border-bottom: 1px solid var(--divider); flex-wrap: wrap;
}
.detail-body { padding: .75rem; font-size: .9rem; line-height: 1.6; color: var(--text2); }
.detail-tabs {
  display: flex; border-bottom: 2px solid var(--divider);
  padding: 0 .5rem; gap: .25rem;
}
.detail-tab {
  flex: 1; background: none; border: none; cursor: pointer;
  padding: .65rem .5rem; font-size: .9rem; font-weight: 600;
  color: var(--text3); border-bottom: 2.5px solid transparent;
  margin-bottom: -2px; transition: color .15s, border-color .15s;
}
.detail-tab.active { color: var(--primary); border-bottom-color: var(--primary); }

/* ── Video detail ────────────────────────────────────────────────────────── */
.video-detail-player { background: #000; }

/* ── Album grid & lightbox ───────────────────────────────────────────────── */
.album-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 3px;
}
.album-photo-item {
  aspect-ratio: 1; overflow: hidden; cursor: pointer;
  background: var(--surface3); border-radius: 4px;
  position: relative;
}
.album-photo-item img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform .2s;
  display: block;
}
.album-photo-item:hover img { transform: scale(1.06); }
.album-lightbox {
  position: fixed; inset: 0; background: rgba(0,0,0,.95);
  z-index: 1000; display: flex; align-items: center; justify-content: center;
}
.album-lightbox img {
  max-width: 100vw; max-height: 85vh; object-fit: contain; border-radius: 4px;
  display: block;
}
.lb-nav {
  position: absolute; top: 50%; transform: translateY(-50%);
  background: rgba(255,255,255,.15); border: none; border-radius: 50%;
  width: 44px; height: 44px; font-size: 1.6rem; color: #fff; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  z-index: 10; transition: background .15s;
}
.lb-nav:hover { background: rgba(255,255,255,.3); }
.lb-prev { left: .75rem; }
.lb-next { right: .75rem; }
.lb-actions {
  position: absolute; top: .75rem; right: .75rem;
  display: flex; gap: .5rem;
}
.lb-close-btn, .lb-delete-btn {
  background: rgba(255,255,255,.15); border: none; border-radius: 8px;
  padding: .4rem .75rem; color: #fff; cursor: pointer; font-size: .9rem;
  transition: background .15s;
}
.lb-close-btn:hover { background: rgba(255,255,255,.3); }
.lb-delete-btn { color: #ff6b6b; }
.lb-delete-btn:hover { background: rgba(255,100,100,.3); }
.album-thumbs { display: flex; gap: .4rem; overflow-x: auto; padding: .4rem 0; }
.classified-thumb {
  width: 54px; height: 54px; border-radius: 8px; object-fit: cover;
  cursor: pointer; border: 2px solid transparent; flex-shrink: 0;
  transition: border-color .15s;
}
.classified-thumb.active { border-color: var(--primary); }

/* ── Classified detail ───────────────────────────────────────────────────── */
.classified-price-display {
  font-size: 1.5rem; font-weight: 800; color: var(--primary);
  margin-bottom: .5rem;
}
.classified-photos { margin-bottom: .75rem; }
.classified-thumbs {
  display: flex; gap: .4rem; overflow-x: auto; padding-top: .4rem;
}
.classified-meta-chips { display: flex; flex-wrap: wrap; gap: .4rem; margin: .5rem 0; }
.classified-contact-section { margin-top: 1rem; }
.classified-contact-btns { display: flex; flex-wrap: wrap; gap: .6rem; margin-top: .5rem; }
.classified-contact-btns a { text-decoration: none; display: inline-flex; align-items: center; gap: .35rem; }

/* ── Crowdfunding detail ─────────────────────────────────────────────────── */
.fund-detail-progress { margin: .75rem 0; }
.fund-bar-lg { height: 12px; border-radius: 99px; background: var(--surface3); overflow: hidden; }
.fund-bar-lg .fund-bar-fill { height: 100%; background: var(--primary); border-radius: 99px; transition: width .4s; }
.fund-detail-stats {
  display: flex; justify-content: space-between;
  margin: .5rem 0; gap: .5rem;
}
.fund-detail-stat { display: flex; flex-direction: column; font-size: .85rem; }
.fund-detail-stat strong { font-size: 1.1rem; font-weight: 800; color: var(--primary); }
.fund-detail-stat span { color: var(--text3); font-size: .78rem; }
.fund-detail-pct { align-items: center; }
.fund-detail-meta {
  display: flex; flex-wrap: wrap; gap: .75rem;
  font-size: .82rem; color: var(--text3); margin-top: .4rem;
}
.pledge-amounts { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: .25rem; }
.pledge-preset {
  border: 1.5px solid var(--border); border-radius: 20px;
  padding: .4rem .85rem; background: var(--surface2); color: var(--text);
  font-size: .9rem; cursor: pointer; transition: all .15s;
}
.pledge-preset:hover { border-color: var(--primary); background: var(--primary-light); }
.pledge-preset.active { border-color: var(--primary); background: var(--primary); color: #fff; }

/* ── Forum replies ───────────────────────────────────────────────────────── */
.forum-reply .comment-bubble { background: var(--surface3); }
.forum-body { padding: .5rem 0; }

/* ── Music player ────────────────────────────────────────────────────────── */
.music-card.playing .row-card-title { color: var(--primary); font-weight: 700; }
.music-card.playing .music-play-overlay { opacity: 1; }
.music-thumb { position: relative; width: 48px; height: 48px; border-radius: 8px; overflow: hidden; flex-shrink: 0; }
.music-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.music-play-overlay {
  position: absolute; inset: 0; background: rgba(0,0,0,.45);
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: 1.2rem; opacity: 0; transition: opacity .18s;
}
.music-card:hover .music-play-overlay { opacity: 1; }

/* Mini bar */
.music-mini-bar {
  display: none; position: fixed; bottom: var(--bottomnav-h); left: 0; right: 0;
  background: var(--surface); border-top: 1px solid var(--divider);
  align-items: center; gap: .75rem; padding: .5rem .75rem;
  z-index: 90; box-shadow: 0 -2px 12px rgba(0,0,0,.12);
}
.mmb-cover { width: 40px; height: 40px; border-radius: 6px; overflow: hidden; flex-shrink: 0; background: var(--surface3); }
.mmb-cover img { width: 100%; height: 100%; object-fit: cover; }
.mmb-info { flex: 1; min-width: 0; cursor: pointer; }
.mmb-title  { font-size: .88rem; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mmb-artist { font-size: .75rem; color: var(--text3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mmb-controls { display: flex; align-items: center; gap: .25rem; }
.mmb-btn { background: none; border: none; cursor: pointer; color: var(--text); font-size: 1.2rem; padding: .35rem; border-radius: 50%; transition: background .15s; display: flex; align-items: center; }
.mmb-btn:hover { background: var(--surface3); }
.mmb-play { background: var(--primary); color: #fff; width: 36px; height: 36px; display: flex; align-items: center; justify-content: center; }
.mmb-play:hover { background: var(--primary-dark); }

/* Full player overlay */
.music-player-overlay {
  position: fixed; inset: 0; z-index: 500;
  background: linear-gradient(170deg, var(--primary-dark, #3a7d99) 0%, var(--bg) 60%);
  display: flex; flex-direction: column; align-items: center;
  padding: 0 1.5rem 1.5rem; overflow-y: auto;
  transform: translateY(100%); transition: transform .28s cubic-bezier(.4,0,.2,1);
}
.music-player-overlay.open { transform: translateY(0); }
.mpo-header {
  display: flex; align-items: center; justify-content: space-between;
  width: 100%; padding: 1rem 0 .75rem;
}
.mpo-down-btn { background: none; border: none; cursor: pointer; color: var(--text); font-size: 1.4rem; padding: .3rem; }
.mpo-playing-from { font-size: .78rem; font-weight: 600; text-transform: uppercase; letter-spacing: .1em; color: var(--text3); }
.mpo-cover { width: 260px; height: 260px; border-radius: 16px; object-fit: cover; box-shadow: 0 8px 32px rgba(0,0,0,.3); margin: .75rem auto; }
.mpo-info { text-align: center; margin: .75rem 0; }
.mpo-title  { font-size: 1.15rem; font-weight: 800; }
.mpo-artist { font-size: .9rem; color: var(--text3); }
.mpo-seek-wrap { width: 100%; cursor: pointer; padding: .5rem 0; }
.mpo-seek-track { position: relative; height: 4px; background: var(--surface3); border-radius: 2px; }
.mpo-seek-fill  { height: 100%; background: var(--primary); border-radius: 2px; }
.mpo-seek-thumb {
  position: absolute; top: 50%; transform: translate(-50%,-50%);
  width: 14px; height: 14px; border-radius: 50%; background: var(--primary);
  box-shadow: 0 1px 4px rgba(0,0,0,.3);
}
.mpo-time {
  display: flex; justify-content: space-between;
  font-size: .75rem; color: var(--text3); margin-bottom: .5rem; width: 100%;
}
.mpo-controls { display: flex; align-items: center; justify-content: center; gap: 1.25rem; margin: .5rem 0 1rem; }
.mpo-ctrl-btn {
  background: none; border: none; cursor: pointer; color: var(--text);
  font-size: 1.4rem; padding: .35rem; border-radius: 50%; transition: background .15s;
  display: flex; align-items: center; justify-content: center;
}
.mpo-ctrl-btn:hover { background: rgba(255,255,255,.1); }
.mpo-ctrl-btn.active { color: var(--primary); }
.mpo-play-btn {
  background: var(--primary); color: #fff;
  width: 56px; height: 56px; border-radius: 50%;
  font-size: 1.8rem;
}
.mpo-play-btn:hover { background: var(--primary-dark); }
.mpo-queue { width: 100%; }
.mpo-queue-section-title { font-size: .82rem; font-weight: 700; color: var(--text3); text-transform: uppercase; letter-spacing: .06em; margin-bottom: .5rem; }
.mpo-queue-list { display: flex; flex-direction: column; gap: .3rem; }
.mpo-queue-item {
  display: flex; align-items: center; gap: .75rem;
  padding: .5rem .6rem; border-radius: 10px; cursor: pointer;
  transition: background .15s;
}
.mpo-queue-item:hover, .mpo-queue-item.active { background: rgba(255,255,255,.08); }
.mpo-queue-item.active .mpo-queue-title-text { color: var(--primary); font-weight: 700; }
.mpo-queue-item img { width: 40px; height: 40px; border-radius: 6px; object-fit: cover; flex-shrink: 0; }
.mpo-queue-track-info { flex: 1; min-width: 0; }
.mpo-queue-title-text  { font-size: .88rem; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mpo-queue-artist-text { font-size: .75rem; color: var(--text3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ── Scrollbar custom (tema) ─────────────────────────────────────────────── */
::-webkit-scrollbar       { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: var(--surface2); }
::-webkit-scrollbar-thumb { background: var(--primary); border-radius: 3px; opacity: .7; }

/* ── Product Reviews ─────────────────────────────────────────────────────── */
#pd-reviews-section { margin-top: .5rem; }
.pd-review-form     { background: var(--surface2); border-radius: 12px; padding: .875rem; margin-top: .75rem; }
#pd-star-picker span { transition: color .1s; user-select: none; }
#pd-star-picker span:hover { color: var(--warning) !important; }

/* ── Sticker Pack Detail ─────────────────────────────────────────────────── */
.sticker-pack-preview {
  display: flex; flex-wrap: wrap; gap: .4rem; margin: .75rem 0;
  background: var(--surface2); border-radius: 12px; padding: .625rem;
}
.sticker-pack-thumb {
  width: 52px; height: 52px; object-fit: contain; border-radius: 6px;
}
.sticker-price-tag {
  font-size: .78rem; font-weight: 700; color: var(--primary);
  background: var(--surface2); border-radius: 6px; padding: .2rem .45rem;
  margin-top: .35rem; text-align: center;
}

/* ── Create FAB ──────────────────────────────────────────────────────────── */
.create-fab {
  position: fixed;
  right: 1rem;
  bottom: calc(var(--bottom-nav-h, 64px) + .75rem);
  z-index: 150;
  width: 52px; height: 52px;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  border: none;
  box-shadow: 0 4px 16px rgba(0,0,0,.25);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.5rem;
  cursor: pointer;
  transition: transform .15s, opacity .15s;
}
.create-fab:active  { transform: scale(.93); }
.create-fab.hidden  { display: none; }

/* ── Create Content Sheet ────────────────────────────────────────────────── */
.create-sheet       { max-height: 90vh; }
.create-sheet-content {
  overflow-y: auto;
  padding: 1rem;
  padding-bottom: calc(env(safe-area-inset-bottom) + 1rem);
}
.cc-field           { margin-bottom: .75rem; }
.cc-label           { display: block; font-size: .8rem; font-weight: 600; color: var(--text2); margin-bottom: .3rem; }
.cc-textarea        { width: 100%; resize: vertical; min-height: 90px; }
.poll-opt-row       { display: flex; align-items: center; gap: .4rem; margin-bottom: .45rem; }

/* ── Crowdfunding Detail Tabs ────────────────────────────────────────────── */
.fund-detail-tabs   { border-bottom: 1px solid var(--divider); }
details summary::-webkit-details-marker { display: none; }

/* ── Downloads Page ──────────────────────────────────────────────────────── */
#downloads-list     { padding-bottom: 2rem; }

/* ── Event Calendar ──────────────────────────────────────────────────────── */
#cal-sheet          { max-height: 95vh; }
.cal-sheet-inner    { padding: .5rem 0 1rem; }
.cal-month-header   {
  display: flex; align-items: center; justify-content: space-between;
  padding: .4rem 1rem .6rem;
}
.cal-month-title    { font-weight: 700; font-size: 1rem; }
.cal-nav-btn        {
  background: none; border: none; cursor: pointer;
  padding: .35rem .6rem; border-radius: 8px; font-size: 1.1rem;
  color: var(--primary);
}
.cal-nav-btn:active { background: var(--surface2); }
.cal-day-header-row {
  display: grid; grid-template-columns: repeat(7, 1fr);
  padding: 0 .5rem;
}
.cal-header-cell    {
  text-align: center; font-size: .7rem; font-weight: 600;
  color: var(--text3); padding: .2rem 0;
}
.cal-grid-cells     {
  display: grid; grid-template-columns: repeat(7, 1fr);
  gap: 2px; padding: .25rem .5rem .5rem;
}
.cal-cell           { min-height: 44px; padding: 1px; }
.cal-day-cell       {
  border-radius: 8px; cursor: pointer; padding: 4px 2px 3px;
  display: flex; flex-direction: column; align-items: center;
  transition: background .12s;
  user-select: none;
}
.cal-day-cell:active { background: var(--surface3); }
.cal-today          { background: var(--primary-light); font-weight: 700; }
.cal-today .cal-day-num { color: var(--primary); }
.cal-has-events     { background: var(--surface2); }
.cal-selected       { background: var(--primary) !important; border-radius: 8px; }
.cal-selected .cal-day-num { color: #fff !important; }
.cal-day-num        { font-size: .8rem; color: var(--text1); line-height: 1; }
.cal-dots           { display: flex; gap: 2px; margin-top: 2px; flex-wrap: wrap; justify-content: center; }
.cal-dot            { width: 5px; height: 5px; border-radius: 50%; background: var(--primary); flex-shrink: 0; }
.cal-day-detail     { padding: .75rem 1rem; border-top: 1px solid var(--divider); }
.cal-day-detail h3  { font-size: .9rem; font-weight: 700; margin-bottom: .5rem; }
.cal-event-row      {
  display: flex; align-items: center; gap: .5rem;
  padding: .4rem 0; border-bottom: 1px solid var(--divider);
  cursor: pointer; font-size: .85rem;
}
.cal-event-row:last-child { border-bottom: none; }
.cal-event-thumb    {
  width: 36px; height: 36px; border-radius: 6px; object-fit: cover;
  background: var(--surface2); flex-shrink: 0;
}
.cal-event-name     { color: var(--text1); flex: 1; font-weight: 500; }

/* ── Group / Store / Video Management Panels ─────────────────────────────── */
.manage-sheet        { max-height: 92vh; }
.manage-tabs         {
  display: flex; border-bottom: 1px solid var(--divider);
  padding: 0 .75rem; gap: .25rem;
}
.manage-tab-btn      {
  background: none; border: none; padding: .55rem .75rem;
  font-size: .85rem; cursor: pointer; border-bottom: 2px solid transparent;
  color: var(--text2); transition: color .15s, border-color .15s;
}
.manage-tab-btn.active { border-color: var(--primary); color: var(--primary); font-weight: 600; }
.manage-panel        { padding: 1rem; overflow-y: auto; max-height: 72vh; }
.manage-panel label  { display: block; font-size: .8rem; font-weight: 600; color: var(--text2); margin-bottom: .3rem; }
.manage-panel select,
.manage-panel input[type="text"],
.manage-panel textarea {
  width: 100%; box-sizing: border-box; margin-bottom: .75rem;
}
.manage-actions      { display: flex; gap: .5rem; margin-top: .5rem; }
.manage-actions .btn { flex: 1; }
.pending-member-row  {
  display: flex; align-items: center; gap: .5rem;
  padding: .5rem 0; border-bottom: 1px solid var(--divider);
}
.pending-member-row:last-child  { border-bottom: none; }
.pending-member-row img         { width: 36px; height: 36px; border-radius: 50%; object-fit: cover; }
.pending-member-row .pm-name    { flex: 1; font-size: .9rem; font-weight: 500; }
.pending-member-row .pm-actions { display: flex; gap: .35rem; }

/* ── Managed card (Store / Videos) ──────────────────────────────────────── */
.managed-card        { position: relative; }
.managed-card-actions {
  display: flex; gap: .4rem; padding: .4rem .5rem .5rem;
  border-top: 1px solid var(--divider);
}
.managed-card-actions .btn { flex: 1; font-size: .76rem; padding: .3rem .5rem; }

/* ── Onboarding / Welcome ────────────────────────────────────────────────── */
.onboarding-root     {
  min-height: 100dvh;
  display: flex; flex-direction: column; align-items: center;
  justify-content: center;
  padding: 2rem 1.5rem env(safe-area-inset-bottom, 1rem);
  background: var(--bg);
  overflow: hidden;
}
.onboarding-slides   {
  width: 100%; flex: 1;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  position: relative;
}
.onboarding-slide    {
  display: none; flex-direction: column; align-items: center;
  text-align: center; animation: obSlideIn .3s ease;
}
.onboarding-slide.active { display: flex; }
@keyframes obSlideIn {
  from { opacity: 0; transform: translateX(24px); }
  to   { opacity: 1; transform: translateX(0); }
}
.ob-emoji            {
  font-size: 5rem; line-height: 1;
  width: 120px; height: 120px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 1.75rem;
}
.ob-title            { font-size: 1.5rem; font-weight: 800; color: var(--text1); margin-bottom: .6rem; }
.ob-sub              { font-size: .95rem; color: var(--text2); line-height: 1.5; max-width: 320px; }
.ob-dots             { display: flex; gap: .45rem; margin: 1.5rem 0 1rem; }
.ob-dot              {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--border); transition: background .2s, width .2s;
  cursor: pointer;
}
.ob-dot.active       { background: var(--primary); width: 22px; border-radius: 4px; }
.ob-actions          { width: 100%; max-width: 360px; padding-bottom: .5rem; }

/* ── xConfirm Dialog ──────────────────────────────────────────────────── */
.xdialog-overlay {
  position: fixed; inset: 0; z-index: 9000;
  background: rgba(0,0,0,.5); backdrop-filter: blur(2px);
  display: flex; align-items: center; justify-content: center;
  padding: 1rem; animation: xdFadeIn .15s ease;
}
@keyframes xdFadeIn { from { opacity: 0; } to { opacity: 1; } }
.xdialog {
  background: var(--surface); border-radius: 16px;
  padding: 1.5rem; width: 100%; max-width: 320px;
  box-shadow: 0 8px 32px rgba(0,0,0,.3);
  animation: xdSlideUp .2s ease;
}
@keyframes xdSlideUp {
  from { opacity: 0; transform: translateY(16px) scale(.97); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}
.xdialog-msg {
  font-size: 1rem; color: var(--text1); line-height: 1.5;
  margin-bottom: 1.25rem; text-align: center;
}
.xdialog-actions {
  display: flex; gap: .75rem; justify-content: flex-end;
}
.xdialog-actions .btn { flex: 1; }

/* ── Pinned message bar ──────────────────────────────────────────────────── */
.chat-pinned-bar {
  display: flex;
  align-items: center;
  gap: .5rem;
  padding: .45rem .75rem;
  background: var(--card-bg);
  border-bottom: 1px solid var(--border);
  font-size: .8rem;
  position: sticky;
  top: 0;
  z-index: 15;
  cursor: pointer;
}
.chat-pinned-bar.hidden { display: none; }
.pinned-preview-text {
  flex: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: var(--text);
}
.pinned-unpin-btn {
  background: none; border: none; cursor: pointer;
  color: var(--text3); padding: 2px; line-height: 1;
}
.pinned-unpin-btn .ms-icon { font-size: 14px; vertical-align: middle; }

/* ── Member search dropdown (group creation) ─────────────────────────────── */
.member-search-dropdown {
  position: absolute;
  top: calc(100% + 2px);
  left: 0; right: 0;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  box-shadow: 0 4px 16px rgba(0,0,0,.15);
  z-index: 200;
  max-height: 200px;
  overflow-y: auto;
}
.member-search-dropdown.hidden { display: none; }
.member-search-item {
  display: flex;
  align-items: center;
  gap: .5rem;
  padding: .5rem .75rem;
  cursor: pointer;
  transition: background .12s;
}
.member-search-item:hover { background: var(--surface); }
.member-search-avatar {
  width: 32px; height: 32px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}
.member-search-name { font-size: .875rem; color: var(--text); }
.member-search-empty,
.member-search-loading {
  padding: .75rem;
  text-align: center;
  color: var(--text3);
  font-size: .8rem;
}
.spinner-sm {
  display: inline-block;
  width: 14px; height: 14px;
  border: 2px solid var(--border);
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin .5s linear infinite;
  vertical-align: middle;
}

/* ── Member chips ────────────────────────────────────────────────────────── */
.member-chips {
  display: flex;
  flex-wrap: wrap;
  gap: .35rem;
  min-height: 4px;
  margin-bottom: .25rem;
}
.member-chip {
  display: inline-flex;
  align-items: center;
  gap: .3rem;
  background: color-mix(in srgb, var(--primary) 12%, transparent);
  color: var(--primary);
  border-radius: 99px;
  padding: .15rem .5rem .15rem .2rem;
  font-size: .8rem;
}
.chip-avatar {
  width: 20px; height: 20px;
  border-radius: 50%;
  object-fit: cover;
}
.chip-remove {
  background: none; border: none;
  cursor: pointer; color: var(--primary);
  font-size: 1rem; line-height: 1; padding: 0;
}

/* ── @mention picker ─────────────────────────────────────────────────────── */
.mention-picker {
  position: absolute;
  bottom: 100%;
  left: 0; right: 0;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 8px 8px 0 0;
  box-shadow: 0 -4px 16px rgba(0,0,0,.1);
  max-height: 160px;
  overflow-y: auto;
  z-index: 100;
}
.mention-item {
  display: flex;
  align-items: center;
  gap: .5rem;
  padding: .5rem .75rem;
  cursor: pointer;
  font-size: .875rem;
  transition: background .12s;
}
.mention-item:hover,
.mention-item.focused { background: var(--surface); }
.mention-avatar {
  width: 28px; height: 28px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}

/* ── Group admin panel ───────────────────────────────────────────────────── */
.group-admin-member {
  display: flex;
  align-items: center;
  gap: .75rem;
  padding: .65rem 0;
  border-bottom: 1px solid var(--border);
}
.group-admin-member:last-child { border-bottom: none; }
.group-admin-avatar {
  width: 40px; height: 40px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}
.group-admin-name { font-size: .9rem; color: var(--text); }
.group-admin-role { font-size: .72rem; color: var(--text3); text-transform: capitalize; }
.group-admin-actions { display: flex; gap: .3rem; flex-shrink: 0; }
.group-admin-btn {
  background: none;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: .25rem .4rem;
  cursor: pointer;
  color: var(--text3);
  line-height: 1;
  transition: color .12s, border-color .12s;
}
.group-admin-btn .ms-icon { font-size: 18px; vertical-align: middle; }
.group-admin-btn:hover { color: var(--primary); border-color: var(--primary); }
.group-admin-btn.danger:hover { color: var(--error, #e53935); border-color: var(--error, #e53935); }

/* ── Settings — browser push notification row ─────────────────────────── */
.settings-push-row {
  display: flex;
  align-items: center;
  gap: .6rem;
  padding: .65rem .1rem;
  border-top: 1px solid var(--border);
}
.settings-push-hint {
  font-size: .75rem;
  color: var(--text3);
  margin-top: .15rem;
  line-height: 1.3;
}
.push-status-badge {
  font-size: .72rem;
  font-weight: 600;
  padding: .2rem .55rem;
  border-radius: 20px;
  white-space: nowrap;
  flex-shrink: 0;
}
.push-status-active  { background: rgba(46,204,113,.15); color: var(--success, #2ecc71); }
.push-status-blocked { background: rgba(231,76,60,.12);  color: var(--error,   #e74c3c); }
.btn-push-enable {
  background: var(--primary);
  color: #fff;
  border: none;
  border-radius: 8px;
  padding: .35rem .75rem;
  font-size: .8rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  flex-shrink: 0;
  transition: opacity .15s;
}
.btn-push-enable:hover   { opacity: .88; }
.btn-push-enable:disabled { opacity: .5; cursor: default; }

/* ── PWA Install — drawer button & iOS sheet ──────────────────────────── */
#drawer-install-btn .ms-icon { color: var(--primary); }

.ios-install-inner {
  padding: 1.25rem 1rem 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}
.ios-install-header {
  display: flex;
  align-items: center;
  gap: .85rem;
}
.ios-install-icon {
  width: 52px;
  height: 52px;
  border-radius: 12px;
  flex-shrink: 0;
}
.ios-install-title { font-weight: 700; font-size: 1rem; color: var(--text); }
.ios-install-sub   { font-size: .8rem; color: var(--text3); }
.ios-install-close {
  margin-left: auto;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text3);
  padding: .25rem;
  line-height: 1;
}
.ios-install-steps { display: flex; flex-direction: column; gap: .6rem; }
.ios-install-step {
  display: flex;
  align-items: center;
  gap: .75rem;
  padding: .65rem .85rem;
  background: var(--surface2);
  border-radius: 10px;
  font-size: .9rem;
  color: var(--text);
}
.ios-step-num {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  font-size: .75rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.ios-step-icon { color: var(--primary); font-size: 1.2rem; flex-shrink: 0; }
.ios-install-arrow {
  text-align: center;
  font-size: .8rem;
  color: var(--text3);
  padding-top: .25rem;
}
