/* MySubShare app. Dark brand ground, Fredoka headings, DM Sans body. */

:root {
  --orange: #fe6401;
  --orange-hi: #ff7a24;
  --purple: #7c5cfc;
  --green: #22c58b;
  --amber: #ffb020;
  --red: #ff4d5e;
  --bg: #0a0a0f;
  --panel: #12121a;
  --card: #181824;
  --line: rgba(245, 245, 248, 0.09);
  --text: #f5f5f8;
  --body: #d4d4de;
  --muted: #a3a3b2;
  --dim: #9d9dac;
  --max: 560px;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font-family: 'DM Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

h1, h2, h3, .brand-name, .balance-amount, .ring-secs, .digit, .refer-code, .stat-value, .post-title, .card-title {
  font-family: 'Fredoka', 'DM Sans', system-ui, sans-serif;
  letter-spacing: -0.015em;
}

a { color: var(--orange); text-decoration: none; }
a:hover { color: var(--orange-hi); }
button { font-family: inherit; }
img { max-width: 100%; height: auto; }

:focus-visible { outline: 2px solid var(--orange); outline-offset: 3px; border-radius: 10px; }

.sr-only, .skip {
  position: absolute;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}
.skip:focus {
  width: auto; height: auto; clip: auto;
  top: 12px; left: 12px; z-index: 50;
  padding: 10px 16px; border-radius: 999px;
  background: var(--orange); color: #0a0a0f; font-weight: 700;
}

/* Boot */
.boot {
  min-height: 100vh;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px;
  color: var(--muted);
}
.boot-mark {
  width: 56px; height: 56px; border-radius: 18px;
  background: var(--orange); color: #0a0a0f;
  display: flex; align-items: center; justify-content: center;
  font-family: 'Fredoka', sans-serif; font-weight: 700; font-size: 28px;
}

/* Shell */
.topbar {
  position: sticky; top: 0; z-index: 20;
  padding: calc(12px + env(safe-area-inset-top, 0px)) 16px 12px;
  background: rgba(10, 10, 15, 0.9);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
}
.topbar:empty { display: none; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--text); }
.brand-mark {
  width: 34px; height: 34px; border-radius: 11px;
  background: var(--orange); color: #0a0a0f;
  display: flex; align-items: center; justify-content: center;
  font-family: 'Fredoka', sans-serif; font-weight: 700; font-size: 18px;
}
.brand-name { font-weight: 600; font-size: 18px; }

.main {
  max-width: var(--max);
  margin: 0 auto;
  padding: 18px 16px calc(104px + env(safe-area-inset-bottom, 0px));
  outline: none;
}
.signed-out .main { padding-bottom: 32px; }

.tabs {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 20;
  display: grid; grid-template-columns: repeat(5, minmax(0, 1fr));
  padding: 8px 6px calc(16px + env(safe-area-inset-bottom, 0px));
  background: var(--panel);
  border-top: 1px solid var(--line);
}
.tab {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
  min-height: 56px;
  color: var(--dim); font-size: 12px; font-weight: 600;
}
.tab-on { color: var(--orange); font-weight: 700; }

.screen { display: flex; flex-direction: column; gap: 20px; }

/* Sign in */
.auth { display: flex; flex-direction: column; gap: 22px; padding-top: 26px; }
.auth-brand { display: flex; align-items: center; gap: 10px; }
.auth-title { margin: 0; font-size: clamp(28px, 8vw, 36px); font-weight: 600; line-height: 1.1; }
.auth-sub { margin: -12px 0 0; color: var(--muted); }
.auth-form { display: flex; flex-direction: column; gap: 16px; }
.auth-foot { margin: 8px 0 0; text-align: center; color: var(--muted); }
.field { display: flex; flex-direction: column; gap: 8px; }
.field-head { display: flex; justify-content: space-between; align-items: baseline; }
.field label { font-size: 14px; font-weight: 600; color: var(--body); }
.field input {
  height: 52px; padding: 0 16px;
  border: 1px solid rgba(245, 245, 248, 0.14); border-radius: 14px;
  background: var(--panel); color: var(--text);
  font-size: 16px; font-family: inherit;
}
.field input:focus { border-color: var(--orange); outline: none; }
.form-note { margin: 0; color: #ff8a95; font-size: 14px; }
.link-small { font-size: 14px; font-weight: 600; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 50px; padding: 0 20px;
  border: 0; border-radius: 15px;
  font-size: 16px; font-weight: 700; font-family: inherit;
  cursor: pointer;
}
.btn-block { width: 100%; }
.btn-primary { background: var(--orange); color: #0a0a0f; }
.btn-primary:hover { background: var(--orange-hi); color: #0a0a0f; }
.btn-primary:disabled { opacity: .6; cursor: default; }
.btn-dark { background: #0a0a0f; color: var(--text); }
.btn-white { background: #ffffff; color: #2d1f7a; }
.btn-line { background: transparent; border: 1px solid rgba(245, 245, 248, 0.18); color: var(--text); }

.icon-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 44px; height: 44px; flex: none;
  border: 0; border-radius: 13px;
  background: #262636; color: var(--text);
  cursor: pointer;
}
.icon-btn-lg { border: 1px solid var(--line); background: var(--panel); }
.icon-btn-light { background: rgba(255, 255, 255, 0.2); color: #ffffff; }

/* Home */
.greet { display: flex; align-items: center; justify-content: space-between; }
.greet-who { display: flex; align-items: center; gap: 12px; }
.avatar {
  width: 44px; height: 44px; border-radius: 50%;
  background: var(--purple); color: #ffffff;
  display: flex; align-items: center; justify-content: center;
  font-family: 'Fredoka', sans-serif; font-weight: 600; font-size: 18px;
}
.avatar-lg { width: 56px; height: 56px; font-size: 22px; }
.greet-text { display: flex; flex-direction: column; }
.greet-hello { font-size: 13px; color: var(--muted); }
.greet-name { font-family: 'Fredoka', sans-serif; font-weight: 600; font-size: 20px; }

.balance {
  background: var(--orange); color: #0a0a0f;
  border-radius: 24px; padding: 20px;
  display: flex; flex-direction: column; gap: 12px;
}
.balance-label { font-size: 14px; font-weight: 600; }
.balance-amount { font-size: 38px; font-weight: 600; line-height: 1; }
.balance-amount-dark { color: var(--text); }
.balance-note { margin: 0; font-size: 13px; font-weight: 600; }
.balance-actions { display: flex; gap: 10px; }
.balance .btn { min-height: 46px; font-size: 15px; }

.quick { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.quick-item {
  min-height: 84px; border-radius: 18px;
  background: var(--card); color: var(--text);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px;
  font-size: 13px; font-weight: 600; text-align: center;
}

.ad-slot { display: flex; flex-direction: column; gap: 10px; }
.ad {
  display: flex; flex-direction: column; gap: 12px;
  border-radius: 20px; overflow: hidden;
  background: #1d1440; border: 1px solid rgba(124, 92, 252, 0.4);
  color: var(--text);
}
.ad-img { width: 100%; display: block; }
.ad-text { display: flex; flex-direction: column; gap: 6px; padding: 18px; }
.ad-badge { font-size: 12px; font-weight: 700; color: var(--amber); }
.ad-heading { font-family: 'Fredoka', sans-serif; font-weight: 600; font-size: 19px; line-height: 1.25; }
.ad-body { font-size: 14px; color: #cfc6ff; }
.ad-cta {
  align-self: flex-start; margin-top: 4px;
  min-height: 38px; padding: 0 16px; border-radius: 12px;
  background: var(--orange); color: #0a0a0f;
  display: inline-flex; align-items: center; font-size: 14px; font-weight: 700;
}
.dots { display: flex; gap: 6px; justify-content: center; }
.dot { width: 7px; height: 5px; border-radius: 3px; background: #3a3a4c; }
.dot-on { width: 22px; background: var(--orange); }

.block { display: flex; flex-direction: column; gap: 12px; }
.block-head { display: flex; justify-content: space-between; align-items: baseline; }
.block-head h2 { margin: 0; font-size: 20px; font-weight: 600; }

.row {
  display: flex; align-items: center; gap: 14px;
  padding: 14px; border-radius: 18px;
  background: var(--panel); border: 1px solid var(--line);
  color: var(--text);
}
.tile {
  width: 48px; height: 48px; flex: none; border-radius: 14px;
  display: flex; align-items: center; justify-content: center;
  font-family: 'Fredoka', sans-serif; font-weight: 600; font-size: 18px;
}
.row-body { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; gap: 8px; }
.row-line { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.row-title { font-weight: 700; font-size: 16px; }
.row-days { font-size: 13px; font-weight: 600; color: var(--green); white-space: nowrap; }
.row-days-warn { color: var(--amber); }

.bar { display: block; height: 6px; border-radius: 3px; background: #262636; overflow: hidden; }
.bar-fill { display: block; height: 6px; border-radius: 3px; background: var(--green); }
.bar-warn { background: var(--amber); }
.bar-purple { background: var(--purple); }

.pill { padding: 5px 10px; border-radius: 999px; font-size: 12px; font-weight: 700; white-space: nowrap; }
.pill-green { background: rgba(34, 197, 139, 0.15); color: #4ade9f; }
.pill-amber { background: rgba(255, 176, 32, 0.15); color: #ffcf70; }

/* Cards */
.page-head { display: flex; flex-direction: column; gap: 6px; }
.page-head h1 { margin: 0; font-size: 28px; font-weight: 600; }
.page-head p { margin: 0; color: var(--muted); }
.page-head-row { flex-direction: row; align-items: center; gap: 12px; }
.page-title-inline { font-size: 22px; }

.card {
  background: var(--panel); border: 1px solid var(--line);
  border-radius: 22px; padding: 18px;
  display: flex; flex-direction: column; gap: 14px;
}
.card-balance { gap: 6px; }
.card-head { display: flex; align-items: center; gap: 12px; }
.card-titles { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.card-title { font-weight: 700; font-size: 17px; }
.card-sub { font-size: 13px; color: var(--muted); }
.card-note { margin: 0; font-size: 14px; color: var(--body); }

.fields { background: var(--card); border-radius: 16px; padding: 2px 14px; }
.field-row { display: flex; align-items: center; gap: 8px; min-height: 56px; border-bottom: 1px solid var(--line); }
.field-row:last-child { border-bottom: 0; }
.field-main { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.field-label { font-size: 12px; color: var(--dim); }
.field-value { font-size: 15px; font-weight: 600; word-break: break-all; }

.note { display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; border-radius: 16px; background: var(--card); }
.note p { margin: 0; font-size: 13px; line-height: 1.5; color: var(--body); }

/* Code screen */
.code-panel {
  background: var(--panel); border: 1px solid var(--line);
  border-radius: 26px; padding: 26px 18px 22px;
  display: flex; flex-direction: column; align-items: center; gap: 20px;
}
.ring-wrap { position: relative; width: 220px; height: 220px; }
.ring { transform: rotate(-90deg); display: block; }
.ring circle { transition: stroke-dashoffset .25s linear; }
.ring-center {
  position: absolute; inset: 0;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
}
.ring-secs { font-size: 58px; font-weight: 600; line-height: 1; color: var(--orange); }
.ring-label { font-size: 14px; color: var(--muted); }
.digits { display: flex; gap: 8px; }
.digit {
  width: 44px; height: 58px; border-radius: 12px;
  background: var(--card); border: 1px solid var(--line);
  display: flex; align-items: center; justify-content: center;
  font-size: 30px; font-weight: 600;
}
.digit-gap { margin-left: 10px; }
.digits-dead { opacity: .45; }
.code-note { margin: 0; max-width: 280px; text-align: center; font-size: 15px; color: var(--body); }
.usage { width: 100%; display: flex; flex-direction: column; gap: 8px; }
.usage-line { display: flex; justify-content: space-between; font-size: 13px; color: var(--muted); }
.usage-line strong { color: var(--text); }

/* Wallet */
.fund-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.fund {
  min-height: 108px; padding: 16px; border-radius: 20px;
  background: var(--card); border: 1px solid var(--line); color: var(--text);
  display: flex; flex-direction: column; gap: 8px;
}
.fund-primary { background: var(--orange); border-color: var(--orange); color: #0a0a0f; }
.fund-title { font-weight: 700; font-size: 16px; margin-top: auto; }
.fund-note { font-size: 12px; opacity: .85; }

.txn { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.txn:last-child { border-bottom: 0; }
.txn-icon {
  width: 42px; height: 42px; flex: none; border-radius: 13px;
  display: flex; align-items: center; justify-content: center;
  background: #262636; color: var(--text);
}
.txn-in { background: rgba(34, 197, 139, 0.15); color: #4ade9f; }
.txn-main { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.txn-title { font-weight: 600; font-size: 15px; }
.txn-date { font-size: 13px; color: var(--dim); }
.txn-amount { font-weight: 700; font-size: 15px; white-space: nowrap; }
.txn-amount-in { color: #4ade9f; }

/* Subscribe */
.search { position: relative; display: flex; align-items: center; }
.search svg { position: absolute; left: 16px; }
.search-input {
  width: 100%; height: 52px; padding: 0 16px 0 46px;
  border: 1px solid rgba(245, 245, 248, 0.14); border-radius: 16px;
  background: var(--panel); color: var(--text); font-size: 16px; font-family: inherit;
}
.search-input:focus { border-color: var(--orange); outline: none; }
.service-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.service {
  padding: 16px; border-radius: 20px;
  background: var(--panel); border: 1px solid var(--line); color: var(--text);
  display: flex; flex-direction: column; gap: 10px;
}
.service-name { font-weight: 700; font-size: 15px; }
.service-note { font-size: 13px; color: var(--muted); }

/* Refer */
.card-refer { background: var(--purple); border-color: var(--purple); color: #ffffff; }
.refer-label { font-size: 14px; font-weight: 600; }
.refer-code-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.refer-code { font-size: 32px; font-weight: 600; letter-spacing: 0.04em; word-break: break-all; }
.stat-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.stat {
  padding: 14px; border-radius: 18px;
  background: var(--panel); border: 1px solid var(--line);
  display: flex; flex-direction: column; gap: 6px;
}
.stat-green { border-color: rgba(34, 197, 139, 0.4); }
.stat-green .stat-value { color: #4ade9f; }
.stat-value { font-size: 22px; font-weight: 600; }
.stat-label { font-size: 12px; color: var(--muted); line-height: 1.35; }
.steps { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 10px; color: var(--body); font-size: 14px; }
.steps li::marker { color: var(--orange); font-weight: 700; }

/* Blog */
.post { display: flex; color: var(--text); border-radius: 20px; overflow: hidden; background: var(--panel); border: 1px solid var(--line); }
.post-lead { flex-direction: column; }
.post-img { width: 100%; height: 170px; object-fit: cover; display: block; }
.post-img-blank { display: flex; align-items: center; justify-content: center; background: #1d1440; }
.post-row { align-items: center; gap: 14px; padding: 12px; }
.post-thumb { width: 76px; height: 76px; flex: none; border-radius: 14px; object-fit: cover; }
.post-text { display: flex; flex-direction: column; gap: 6px; padding: 14px; min-width: 0; }
.post-row .post-text { padding: 0; }
.post-cat { font-size: 12px; font-weight: 700; color: var(--orange); }
.post-title { font-weight: 600; font-size: 16px; line-height: 1.35; }
.post-excerpt { font-size: 14px; color: var(--muted); }
.post-meta { font-size: 12px; color: var(--dim); }

/* Profile */
.menu { display: flex; flex-direction: column; border-radius: 20px; overflow: hidden; background: var(--panel); border: 1px solid var(--line); }
.menu-item {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 16px; color: var(--text); font-weight: 600; font-size: 15px;
  border-bottom: 1px solid var(--line);
}
.menu-item:last-child { border-bottom: 0; }

/* States */
.skeleton { display: flex; flex-direction: column; gap: 10px; }
.skeleton-line {
  display: block; height: 62px; border-radius: 16px;
  background: linear-gradient(90deg, #14141d, #1d1d2a, #14141d);
  background-size: 200% 100%;
  animation: shimmer 1.4s linear infinite;
}
@keyframes shimmer { from { background-position: 200% 0; } to { background-position: -200% 0; } }

.empty {
  padding: 28px 20px; border-radius: 20px;
  border: 1px dashed var(--line); text-align: center;
  display: flex; flex-direction: column; gap: 10px; align-items: center;
}
.empty-title { margin: 0; font-weight: 700; font-size: 17px; }
.empty-text { margin: 0; color: var(--muted); font-size: 14px; }

.toast {
  position: fixed; left: 50%; transform: translateX(-50%);
  bottom: calc(100px + env(safe-area-inset-bottom, 0px)); z-index: 40;
  max-width: calc(100% - 32px);
  padding: 12px 18px; border-radius: 999px;
  background: #ffffff; color: #0a0a0f;
  font-size: 14px; font-weight: 600;
  box-shadow: 0 10px 30px rgba(0, 0, 0, .45);
}
.toast-warn { background: var(--amber); }
.toast-ok { background: #4ade9f; }

@media (min-width: 720px) {
  .main { padding-bottom: 40px; padding-top: 24px; }
  .tabs {
    max-width: var(--max);
    left: 50%; right: auto; transform: translateX(-50%);
    width: 100%;
    border: 1px solid var(--line); border-bottom: 0;
    border-radius: 20px 20px 0 0;
  }
  .toast { bottom: 28px; }
}

@media (prefers-reduced-motion: reduce) {
  .skeleton-line { animation: none; }
  .ring circle { transition: none; }
}

/* v1.1: registration, checkout, funding and the article reader */
.auth-body { display: flex; flex-direction: column; gap: 20px; }
.text-input {
  height: 52px; padding: 0 16px; width: 100%;
  border: 1px solid rgba(245, 245, 248, 0.14); border-radius: 14px;
  background: var(--panel); color: var(--text);
  font-size: 16px; font-family: inherit;
}
.text-input:focus { border-color: var(--orange); outline: none; }
.text-input-big { height: 62px; font-size: 26px; font-family: 'Fredoka', sans-serif; font-weight: 600; }
.select {
  height: 52px; padding: 0 14px; width: 100%;
  border: 1px solid rgba(245, 245, 248, 0.14); border-radius: 14px;
  background: var(--panel); color: var(--text); font-size: 16px; font-family: inherit;
}
.field-caption { font-size: 14px; font-weight: 600; color: var(--body); }
.row-2 { display: grid; grid-template-columns: 1fr 1.4fr; gap: 10px; }
.row-inline { display: flex; gap: 10px; }
.row-inline .text-input { flex: 1 1 auto; }
.row-inline .btn { flex: none; min-height: 52px; }
.form-ok { margin: 0; color: #4ade9f; font-size: 14px; }

.divider { display: flex; align-items: center; gap: 12px; color: var(--dim); font-size: 13px; }
.divider-line { flex: 1 1 auto; height: 1px; background: var(--line); }
.google-holder { display: flex; justify-content: center; min-height: 44px; }
.google-btn { display: flex; justify-content: center; width: 100%; }

.plan-list { display: flex; flex-direction: column; gap: 8px; }
.plan {
  display: flex; align-items: center; gap: 12px;
  padding: 14px; border-radius: 16px;
  background: var(--card); color: var(--text);
}
.plan-main { flex: 1 1 auto; display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.plan-name { font-weight: 700; font-size: 15px; }
.plan-days { font-size: 13px; color: var(--muted); }
.plan-price { font-family: 'Fredoka', sans-serif; font-weight: 600; font-size: 17px; white-space: nowrap; }

.total-row { display: flex; justify-content: space-between; align-items: center; padding-top: 4px; border-top: 1px solid var(--line); }
.total-amount { font-family: 'Fredoka', sans-serif; font-weight: 600; font-size: 26px; }

.pay-option {
  display: flex; align-items: center; gap: 14px; width: 100%;
  padding: 16px; border-radius: 18px; text-align: left;
  background: var(--panel); border: 1px solid var(--line); color: var(--text);
  font-family: inherit; cursor: pointer;
}
.pay-option:disabled { opacity: .6; cursor: default; }
.pay-option-go { border-color: rgba(34, 197, 139, 0.45); }
.pay-icon { width: 44px; height: 44px; flex: none; border-radius: 13px; display: flex; align-items: center; justify-content: center; }
.pay-icon-green { background: rgba(34, 197, 139, 0.15); color: #4ade9f; }
.pay-icon-orange { background: rgba(254, 100, 1, 0.16); color: var(--orange); }
.pay-icon-purple { background: rgba(124, 92, 252, 0.18); color: #b9a7ff; }
.pay-main { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.pay-title { font-weight: 700; font-size: 16px; }
.pay-note { font-size: 13px; color: var(--muted); }

.card-transfer { gap: 10px; }
.transfer-amount { font-family: 'Fredoka', sans-serif; font-weight: 600; font-size: 34px; }
.file-input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.file-pick {
  display: flex; align-items: center; gap: 10px;
  min-height: 52px; padding: 0 16px; border-radius: 14px;
  border: 1px dashed rgba(245, 245, 248, 0.24); color: var(--body);
  font-weight: 600; cursor: pointer;
}
.file-name { font-size: 13px; color: var(--dim); }

.chips { display: flex; gap: 8px; flex-wrap: wrap; }
.chip {
  min-height: 38px; padding: 0 14px; border-radius: 999px;
  border: 1px solid rgba(245, 245, 248, 0.16); background: transparent;
  color: var(--body); font-weight: 600; font-size: 14px; font-family: inherit; cursor: pointer;
}
.chip:hover { border-color: var(--orange); color: var(--orange); }

.accordion { border-radius: 16px; background: var(--panel); border: 1px solid var(--line); padding: 14px 16px; }
.accordion summary { cursor: pointer; font-weight: 600; font-size: 15px; }
.accordion .auth-form { margin-top: 14px; }

.article { display: flex; flex-direction: column; gap: 12px; }
.article-img { width: 100%; border-radius: 18px; }
.article-title { margin: 0; font-size: 26px; font-weight: 600; line-height: 1.2; }
.article-body { font-size: 17px; line-height: 1.7; color: var(--body); }
.article-body h2, .article-body h3 { font-family: 'Fredoka', sans-serif; color: var(--text); line-height: 1.3; margin: 1.6em 0 .5em; }
.article-body h2 { font-size: 22px; }
.article-body h3 { font-size: 19px; }
.article-body img { border-radius: 14px; }
.article-body a { color: var(--orange); text-decoration: underline; }
.article-body ul, .article-body ol { padding-left: 1.2em; }
.article-body li { margin-bottom: .4em; }
.article-body blockquote { margin: 1.2em 0; padding-left: 16px; border-left: 3px solid var(--purple); color: var(--text); }
.article-body pre { overflow-x: auto; padding: 14px; border-radius: 12px; background: var(--card); font-size: 14px; }
.article-body table { width: 100%; border-collapse: collapse; font-size: 15px; display: block; overflow-x: auto; }
.article-body th, .article-body td { padding: 10px 12px; border-bottom: 1px solid var(--line); text-align: left; }

/* v1.2: choosing which of our bank accounts to pay into */
.bank-pills { display: flex; gap: 8px; flex-wrap: wrap; }
.bank-pill {
  display: inline-flex; align-items: center; gap: 8px;
  min-height: 42px; padding: 0 14px; border-radius: 999px;
  border: 1px solid rgba(245, 245, 248, 0.16); background: transparent;
  color: var(--body); font-weight: 600; font-size: 14px; font-family: inherit; cursor: pointer;
}
.bank-pill-on { background: var(--text); border-color: var(--text); color: var(--bg); }
.routing-note {
  display: flex; gap: 10px; align-items: flex-start;
  padding: 12px 14px; border-radius: 14px;
  background: rgba(255, 176, 32, 0.12); border: 1px solid rgba(255, 176, 32, 0.35);
}
.routing-note p { margin: 0 0 4px; font-size: 13px; line-height: 1.45; color: #ffd489; }
.routing-note p:last-child { margin-bottom: 0; }
.routing-note[hidden] { display: none; }

/* v1.3: logo, Anike, support desk, profile and birthdays */
.brand-logo-wrap { display: inline-flex; align-items: center; }
.brand-logo { height: 34px; width: auto; max-width: 160px; object-fit: contain; display: block; }
.brand-fallback { display: inline-flex; align-items: center; gap: 10px; }
.auth-brand .brand-logo { height: 42px; }
.topbar-tools { display: flex; gap: 8px; }
.icon-btn-anike { background: var(--purple); color: #fff; }

/* Anike */
.chat { gap: 12px; }
.chat-head { display: flex; align-items: center; gap: 12px; }
.chat-avatar {
  width: 44px; height: 44px; border-radius: 50%;
  background: var(--purple); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-family: 'Fredoka', sans-serif; font-weight: 600; font-size: 20px;
}
.chat-who { display: flex; flex-direction: column; }
.chat-name { font-family: 'Fredoka', sans-serif; font-weight: 600; font-size: 20px; }
.chat-status { font-size: 13px; color: var(--muted); }
.chat-log { display: flex; flex-direction: column; gap: 10px; min-height: 40vh; }
.chat-log-desk { min-height: 30vh; max-height: 58vh; overflow-y: auto; padding: 4px 2px; }
.bubble {
  max-width: 86%; padding: 12px 14px; border-radius: 18px;
  font-size: 15px; line-height: 1.5; overflow-wrap: anywhere;
}
.bubble-bot { align-self: flex-start; background: var(--panel); border: 1px solid var(--line); border-bottom-left-radius: 6px; }
.bubble-agent { align-self: flex-start; background: rgba(124, 92, 252, 0.16); border: 1px solid rgba(124, 92, 252, 0.4); border-bottom-left-radius: 6px; }
.bubble-user { align-self: flex-end; background: var(--orange); color: #0a0a0f; border-bottom-right-radius: 6px; }
.bubble-user-left { align-self: flex-start; background: var(--panel); border: 1px solid var(--line); }
.bubble-agent-right { align-self: flex-end; background: rgba(124, 92, 252, 0.2); border: 1px solid rgba(124, 92, 252, 0.4); }
span.bubble-agent { display: block; font-size: 12px; font-weight: 700; color: #b9a7ff; margin-bottom: 4px; background: none; border: 0; padding: 0; max-width: none; }
.bubble-typing { display: inline-flex; gap: 5px; }
.bubble-typing span { width: 7px; height: 7px; border-radius: 50%; background: var(--dim); animation: blink 1.2s infinite ease-in-out; }
.bubble-typing span:nth-child(2) { animation-delay: .15s; }
.bubble-typing span:nth-child(3) { animation-delay: .3s; }
@keyframes blink { 0%, 80%, 100% { opacity: .25; } 40% { opacity: 1; } }
.chat-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chat-form {
  position: sticky; bottom: calc(92px + env(safe-area-inset-bottom, 0px));
  display: flex; align-items: flex-end; gap: 8px;
  padding: 8px; border-radius: 20px;
  background: var(--panel); border: 1px solid var(--line);
}
.chat-input {
  flex: 1 1 auto; min-height: 44px; max-height: 140px; resize: none;
  border: 0; outline: 0; background: transparent; color: var(--text);
  font: 400 16px/1.4 'DM Sans', system-ui, sans-serif; padding: 11px 8px;
}
.chat-send {
  width: 44px; height: 44px; flex: none; border: 0; border-radius: 14px;
  background: var(--orange); color: #0a0a0f; display: flex; align-items: center; justify-content: center; cursor: pointer;
}
.chat-send:disabled { opacity: .5; }

/* Support desk */
.seg { display: flex; gap: 6px; overflow-x: auto; }
.seg-item {
  display: inline-flex; align-items: center; gap: 8px; flex: none;
  min-height: 40px; padding: 0 14px; border-radius: 999px;
  border: 1px solid rgba(245, 245, 248, 0.16); color: var(--body); font-weight: 600; font-size: 14px;
}
.seg-on { background: var(--text); border-color: var(--text); color: var(--bg); }
.seg-count { min-width: 22px; height: 22px; padding: 0 6px; border-radius: 11px; background: var(--orange); color: #0a0a0f; font-size: 12px; font-weight: 700; display: inline-flex; align-items: center; justify-content: center; }
.ticket {
  display: flex; flex-direction: column; gap: 6px;
  padding: 14px 16px; border-radius: 18px;
  background: var(--panel); border: 1px solid var(--line); color: var(--text);
}
.ticket-open { border-color: rgba(255, 176, 32, 0.45); }
.ticket-top { display: flex; justify-content: space-between; gap: 10px; }
.ticket-name { font-weight: 700; }
.ticket-age { font-size: 12px; color: var(--dim); white-space: nowrap; }
.ticket-text { font-size: 14px; color: var(--muted); }
.ticket-meta { display: flex; gap: 6px; }
.pill-dim { background: #262636; color: var(--muted); }
.pill-purple { background: rgba(124, 92, 252, 0.18); color: #b9a7ff; }
.member-card { gap: 10px; }
.member-facts { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 13px; color: var(--muted); }
.member-subs { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 6px; }
.member-subs li { display: flex; justify-content: space-between; gap: 10px; font-size: 14px; }
.desk-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.desk-state { font-size: 13px; color: var(--muted); }
.btn-small { min-height: 38px; padding: 0 14px; font-size: 14px; border-radius: 12px; }
.select-small { height: 38px; width: auto; font-size: 14px; }
.team-list { display: flex; flex-direction: column; gap: 6px; margin: 10px 0; }
.team-row { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--line); }

/* Profile */
.menu-item-accent { background: rgba(124, 92, 252, 0.16); border: 1px solid rgba(124, 92, 252, 0.4); border-radius: 18px; }
.check { display: flex; align-items: center; gap: 10px; font-size: 15px; color: var(--body); }
.check input { width: 20px; height: 20px; accent-color: var(--orange); }
.field-hint { font-size: 13px; color: var(--dim); }
.accordion-card summary { font-family: 'Fredoka', sans-serif; font-size: 17px; }

/* Birthday prompt at registration */
.bday-prompt {
  display: flex; flex-direction: column; gap: 10px;
  padding: 16px; border-radius: 18px;
  background: rgba(255, 176, 32, 0.08); border: 1px solid rgba(255, 176, 32, 0.35);
}
.bday-prompt-head { display: flex; align-items: center; gap: 10px; }
.bday-prompt-title { font-family: 'Fredoka', sans-serif; font-weight: 600; font-size: 17px; }
.bday-prompt-text { margin: 0; font-size: 14px; color: var(--body); }

/* Birthday on the home screen */
.bday { position: relative; overflow: hidden; border-radius: 24px; }
.bday-inner { position: relative; z-index: 2; padding: 22px 20px; display: flex; flex-direction: column; gap: 8px; }
.bday-today {
  background: linear-gradient(135deg, #7c5cfc 0%, #fe6401 100%);
  color: #fff; min-height: 190px;
}
.bday-soon { background: #1d1440; border: 1px solid rgba(124, 92, 252, 0.45); }
.bday-kicker { font-size: 13px; font-weight: 700; letter-spacing: .02em; opacity: .9; }
.bday-title { margin: 0; font-family: 'Fredoka', sans-serif; font-weight: 700; font-size: 30px; line-height: 1.1; }
.bday-title-sm { font-size: 24px; }
.bday-text { margin: 0; font-size: 15px; line-height: 1.5; max-width: 280px; }
.bday-confetti { position: absolute; inset: 0; z-index: 1; pointer-events: none; }
.bday-bit {
  position: absolute; top: -12px; width: 8px; height: 14px; border-radius: 2px; opacity: .9;
  animation-name: fall; animation-iteration-count: infinite; animation-timing-function: linear;
}
@keyframes fall { from { transform: translateY(0) rotate(0deg); } to { transform: translateY(240px) rotate(540deg); } }
.bday-balloons { position: absolute; right: 12px; top: 18px; z-index: 1; display: flex; gap: 6px; }
.balloon { width: 34px; height: 42px; border-radius: 50% 50% 48% 48%; position: relative; animation: bob 3s ease-in-out infinite; }
.balloon::after { content: ""; position: absolute; left: 50%; top: 100%; width: 1px; height: 38px; background: rgba(255, 255, 255, .6); }
.balloon-1 { background: #ffb020; }
.balloon-2 { background: #22c58b; animation-delay: .5s; margin-top: 12px; }
.balloon-3 { background: #ff6fb1; animation-delay: 1s; }
@keyframes bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
.cd { display: flex; align-items: flex-start; gap: 8px; margin-top: 6px; }
.cd-unit { display: flex; flex-direction: column; align-items: center; gap: 4px; }
.cd-num {
  min-width: 64px; padding: 10px 0; border-radius: 14px; text-align: center;
  background: rgba(255, 255, 255, 0.08); border: 1px solid rgba(255, 255, 255, 0.12);
  font-family: 'Fredoka', sans-serif; font-weight: 600; font-size: 30px; font-variant-numeric: tabular-nums;
}
.cd-label { font-size: 12px; color: var(--muted); }
.cd-sep { font-family: 'Fredoka', sans-serif; font-size: 28px; padding-top: 10px; color: var(--muted); }

@media (prefers-reduced-motion: reduce) {
  .bday-bit, .balloon, .bubble-typing span { animation: none; }
  .bday-bit { display: none; }
}
/* Keep the greeting clear of the balloons on narrow screens */
.bday-today .bday-inner { padding-right: 140px; }
.bday-today .bday-title { font-size: 27px; }
.bday-balloons { top: 22px; right: 14px; }
/* Saved replies stay on one line; the full text is in the tooltip and the reply box */
.chat-chips .chip { max-width: 100%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* v1.4: Anike card, floating button, ad carousel, tickets */
.anike-card {
  display: flex; flex-direction: column; gap: 14px;
  padding: 18px; border-radius: 24px;
  background: linear-gradient(140deg, #2a1d63 0%, #1b1440 60%, #14102c 100%);
  border: 1px solid rgba(124, 92, 252, 0.45);
}
.anike-top { display: flex; gap: 14px; align-items: center; }
.anike-face {
  position: relative; width: 52px; height: 52px; flex: none; border-radius: 50%;
  background: var(--purple); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-family: 'Fredoka', sans-serif; font-weight: 600; font-size: 24px;
  box-shadow: 0 0 0 4px rgba(124, 92, 252, 0.25);
}
.anike-dot { position: absolute; right: 1px; bottom: 2px; width: 13px; height: 13px; border-radius: 50%; background: var(--green); border: 2px solid #1b1440; }
.anike-words { display: flex; flex-direction: column; gap: 3px; }
.anike-name { font-family: 'Fredoka', sans-serif; font-weight: 600; font-size: 20px; }
.anike-sub { font-size: 14px; line-height: 1.45; color: #d9d2ff; }
.anike-quick { display: flex; flex-wrap: wrap; gap: 8px; }
.anike-q {
  min-height: 36px; padding: 0 13px; border-radius: 999px;
  background: rgba(255, 255, 255, 0.08); border: 1px solid rgba(255, 255, 255, 0.16);
  color: #fff; font: 600 13px/1 'DM Sans', system-ui, sans-serif; cursor: pointer;
}
.anike-q:hover { background: rgba(255, 255, 255, 0.16); }
.anike-actions { display: flex; gap: 10px; }
.anike-actions .btn { flex: 1 1 0; min-height: 46px; font-size: 15px; }
.btn-ghost { background: transparent; border: 1px solid rgba(255, 255, 255, 0.3); color: #fff; }
.btn-ghost:hover { color: #fff; border-color: #fff; }

.chat-fab {
  position: fixed; z-index: 25;
  right: 16px; bottom: calc(96px + env(safe-area-inset-bottom, 0px));
  display: inline-flex; align-items: center; gap: 8px;
  height: 52px; padding: 0 18px 0 14px; border-radius: 999px;
  background: var(--purple); color: #fff;
  font-weight: 700; font-size: 15px;
  box-shadow: 0 10px 28px rgba(124, 92, 252, 0.45);
}
.chat-fab:hover { color: #fff; background: #8d70ff; }
.chat-head .chat-ticket-link { margin-left: auto; }

.ads { display: flex; flex-direction: column; gap: 10px; }
.ads-track {
  display: flex; overflow-x: auto; scroll-snap-type: x mandatory;
  scrollbar-width: none; border-radius: 20px;
}
.ads-track::-webkit-scrollbar { display: none; }
.ad-slide {
  position: relative; flex: 0 0 100%; scroll-snap-align: start;
  display: flex; flex-direction: column; overflow: hidden;
  border-radius: 20px; min-height: 150px;
  background: #1d1440; border: 1px solid rgba(124, 92, 252, 0.4); color: var(--text);
}
.ad-slide + .ad-slide { margin-left: 10px; }
.ad-slide-img { width: 100%; aspect-ratio: 16 / 7; object-fit: cover; display: block; }
.ad-slide-bare { border: 0; min-height: 0; }
.ad-slide-bare .ad-slide-img { aspect-ratio: 16 / 7; }
.ad-slide-text { display: flex; flex-direction: column; gap: 6px; padding: 16px 18px; }
.ad-slide-admin { background: transparent; border: 2px dashed rgba(254, 100, 1, 0.55); }
.ad-slide-admin .ad-badge { color: var(--orange); }
button.dot { border: 0; padding: 0; cursor: pointer; height: 6px; }

.ticket-reply { border-color: rgba(124, 92, 252, 0.6); }
.ticket-subject { font-size: 13px; font-weight: 700; color: var(--orange); }
.ticket-info { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.text-area { height: auto; min-height: 140px; padding: 14px 16px; line-height: 1.5; resize: vertical; }
.chat-form-static { position: static; }
.chat-fab { transition: opacity .2s ease, transform .2s ease; }
body.anike-card-visible .chat-fab { opacity: 0; transform: translateY(12px); pointer-events: none; }

/* v1.5: birthday advert, invite link, referral note, descriptions, close, HTML ads */
.bday-promo {
  display: flex; gap: 14px; align-items: center;
  padding: 14px 16px; border-radius: 20px;
  background: linear-gradient(120deg, rgba(255, 176, 32, 0.14), rgba(254, 100, 1, 0.10));
  border: 1px solid rgba(255, 176, 32, 0.4); color: var(--text);
}
.bday-promo-icon {
  width: 48px; height: 48px; flex: none; border-radius: 14px;
  background: rgba(255, 176, 32, 0.16); display: flex; align-items: center; justify-content: center;
}
.bday-promo-words { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.bday-promo-title { font-family: 'Fredoka', sans-serif; font-weight: 600; font-size: 17px; }
.bday-promo-text { font-size: 13px; line-height: 1.45; color: var(--body); }
.bday-promo-cta { font-size: 13px; font-weight: 700; color: var(--amber); margin-top: 2px; }

.invited {
  display: flex; gap: 10px; align-items: center;
  padding: 12px 14px; border-radius: 14px;
  background: rgba(255, 176, 32, 0.12); border: 1px solid rgba(255, 176, 32, 0.35);
  font-size: 14px; color: #ffd489;
}
.invited-bad { background: rgba(255, 77, 94, 0.1); border-color: rgba(255, 77, 94, 0.35); color: #ff9aa4; }
.refer-link-row {
  display: flex; align-items: center; gap: 8px;
  padding: 6px 6px 6px 12px; border-radius: 14px; background: rgba(0, 0, 0, 0.18);
}
.refer-link { flex: 1 1 auto; min-width: 0; font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
a.auth-brand { color: inherit; align-self: flex-start; }

.service-desc { margin: 0; font-size: 14px; line-height: 1.5; color: var(--body); white-space: pre-line; }
.plan-desc { font-size: 13px; line-height: 1.45; color: var(--muted); white-space: pre-line; }
.checkout-desc { display: flex; flex-direction: column; gap: 8px; padding: 12px 14px; border-radius: 14px; background: var(--card); }
.plan-desc-full { margin: 0; font-size: 14px; line-height: 1.5; color: var(--text); white-space: pre-line; }

.chat-close { margin-left: 4px; background: #262636; }

.ad-slide-html { background: transparent; border: 0; min-height: 0; }
.ad-html-frame { width: 100%; height: 160px; border: 0; border-radius: 20px; display: block; background: transparent; }

/* v1.5.1: foldable profile sections and tidy selects */
.accordion-card { padding: 0; overflow: hidden; }
.accordion-card > summary {
  list-style: none; display: flex; align-items: center; gap: 10px;
  padding: 18px; font-family: 'Fredoka', sans-serif; font-weight: 600; font-size: 17px;
}
.accordion-card > summary::-webkit-details-marker { display: none; }
.accordion-card > summary .acc-title { flex: 1 1 auto; }
.accordion-card > summary svg { color: var(--muted); transition: transform .2s ease; }
.accordion-card[open] > summary svg { transform: rotate(90deg); }
.accordion-card > .auth-form { margin: 0; padding: 0 18px 18px; }
.acc-badge {
  padding: 4px 10px; border-radius: 999px; font-family: 'DM Sans', sans-serif;
  font-size: 12px; font-weight: 700; background: rgba(254, 100, 1, 0.16); color: var(--orange);
}
.accordion-highlight { border-color: rgba(254, 100, 1, 0.5); }

.select {
  -webkit-appearance: none; appearance: none;
  background-color: var(--panel);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23a3a3b2' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 14px center; background-size: 16px;
  padding-right: 40px; color: var(--text);
}
.select:focus { border-color: var(--orange); outline: none; }
.select option { background: var(--panel); color: var(--text); }
