:root {
  --primary: #006b5f;
  --primary-deep: #003a3f;
  --action: #1bbfae;
  --mint: #7fe7e2;
  --graphite: #080d0f;
  --surface: #121f22;
  --surface-2: #17282b;
  --surface-3: #1d3135;
  --text: #f3fffc;
  --muted: #8ea3a0;
  --border: rgba(127, 231, 226, .14);
  --border-strong: rgba(127, 231, 226, .28);
  --danger: #ff6876;
  --warning: #ffbd59;
  --success: #45d9aa;
  --info: #62b8ff;
  --shadow: 0 24px 70px rgba(0, 0, 0, .26);
  --sidebar-width: 280px;
  --topbar-height: 76px;
  --radius-xs: 8px;
  --radius-sm: 12px;
  --radius: 16px;
  --radius-lg: 24px;
  --font: IRANSansX, Dana, Vazirmatn, "Noto Sans Arabic", Tahoma, Arial, sans-serif;
}

html[data-theme="light"] {
  --graphite: #f6faf9;
  --surface: #ffffff;
  --surface-2: #edf5f3;
  --surface-3: #e4efed;
  --text: #102321;
  --muted: #637a76;
  --border: rgba(0, 107, 95, .12);
  --border-strong: rgba(0, 107, 95, .25);
  --shadow: 0 24px 70px rgba(14, 56, 51, .11);
}

@media (prefers-color-scheme: light) {
  html[data-theme="system"] {
    --graphite: #f6faf9;
    --surface: #ffffff;
    --surface-2: #edf5f3;
    --surface-3: #e4efed;
    --text: #102321;
    --muted: #637a76;
    --border: rgba(0, 107, 95, .12);
    --border-strong: rgba(0, 107, 95, .25);
    --shadow: 0 24px 70px rgba(14, 56, 51, .11);
  }
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at 72% -10%, rgba(27, 191, 174, .12), transparent 34rem),
    var(--graphite);
  color: var(--text);
  font-family: var(--font);
  font-size: 14px;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
}
button, input, select, textarea { font: inherit; }
a { color: inherit; text-decoration: none; }
button, a { -webkit-tap-highlight-color: transparent; }
button { color: inherit; }
img, svg { display: block; max-width: 100%; }
svg { flex: 0 0 auto; }
h1, h2, h3, p { margin-top: 0; }
h1 { font-size: clamp(25px, 2.5vw, 38px); line-height: 1.35; margin-bottom: 10px; letter-spacing: -.025em; }
h2 { font-size: 18px; line-height: 1.5; margin-bottom: 8px; }
h3 { font-size: 15px; }
p { color: var(--muted); margin-bottom: 0; }
small { color: var(--muted); }
code, kbd { direction: ltr; font-family: "JetBrains Mono", Consolas, monospace; }
::selection { background: rgba(27, 191, 174, .3); color: var(--text); }
:focus-visible { outline: 3px solid rgba(27, 191, 174, .38); outline-offset: 2px; }

.app-shell { min-height: 100vh; }
.sidebar {
  position: fixed;
  inset: 0 0 0 auto;
  z-index: 40;
  width: var(--sidebar-width);
  height: 100vh;
  overflow: auto;
  padding: 18px 16px;
  background: color-mix(in srgb, var(--surface) 94%, transparent);
  border-left: 1px solid var(--border);
  backdrop-filter: blur(22px);
  display: flex;
  flex-direction: column;
  scrollbar-width: thin;
}
.brand-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 4px 4px 15px; }
.brand { display: inline-flex; align-items: center; gap: 11px; }
.brand-mark {
  width: 42px; height: 42px; border-radius: 14px;
  display: inline-grid; place-items: center;
  background: linear-gradient(145deg, var(--mint), var(--action) 45%, var(--primary));
  color: #04211e; font-size: 25px; font-weight: 900; box-shadow: 0 10px 30px rgba(27,191,174,.22);
}
.brand > span:last-child { display: flex; flex-direction: column; line-height: 1.1; direction: ltr; text-align: left; }
.brand strong { font-size: 19px; letter-spacing: .02em; }
.brand small { font-size: 10px; text-transform: uppercase; letter-spacing: .19em; color: var(--action); margin-top: 5px; }
.sidebar-close { display: none !important; }

.workspace-switcher { position: relative; margin-bottom: 14px; }
.workspace-current {
  width: 100%; border: 1px solid var(--border); background: var(--surface-2); color: var(--text);
  border-radius: var(--radius); padding: 10px; display: flex; align-items: center; gap: 10px; cursor: pointer; text-align: right;
}
.workspace-current:hover { border-color: var(--border-strong); background: var(--surface-3); }
.workspace-current > svg { margin-right: auto; }
.workspace-copy { min-width: 0; display: flex; flex-direction: column; line-height: 1.45; }
.workspace-copy strong, .workspace-copy small { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 155px; }
.workspace-copy small { font-size: 11px; }
.workspace-avatar, .user-avatar {
  display: inline-grid; place-items: center; flex: 0 0 auto; width: 39px; height: 39px; border-radius: 13px;
  background: linear-gradient(145deg, rgba(127,231,226,.22), rgba(0,107,95,.34)); border: 1px solid var(--border-strong); color: var(--mint); font-weight: 800;
}
.workspace-avatar.small { width: 31px; height: 31px; border-radius: 10px; }
.workspace-avatar.large { width: 52px; height: 52px; border-radius: 17px; font-size: 19px; }
.user-avatar.xlarge { width: 76px; height: 76px; border-radius: 23px; font-size: 28px; }
.dropdown-panel {
  position: absolute; z-index: 20; top: calc(100% + 8px); inset-inline: 0; padding: 7px; background: var(--surface);
  border: 1px solid var(--border-strong); border-radius: var(--radius); box-shadow: var(--shadow);
}
.dropdown-item { width: 100%; padding: 8px; border: 0; border-radius: 11px; background: transparent; color: var(--text); display: flex; align-items: center; gap: 9px; text-align: right; cursor: pointer; }
.dropdown-item:hover, .dropdown-item.selected { background: var(--surface-2); }
.dropdown-item > span:nth-child(2) { display: flex; flex-direction: column; line-height: 1.45; }
.dropdown-item > svg { margin-right: auto; color: var(--action); }
.dropdown-item.add { border-top: 1px solid var(--border); margin-top: 5px; padding-top: 11px; color: var(--action); }

.sidebar-nav { display: flex; flex-direction: column; gap: 3px; }
.nav-label { margin: 16px 12px 5px; color: var(--muted); font-size: 10px; font-weight: 700; letter-spacing: .08em; }
.nav-item {
  position: relative; width: 100%; min-height: 43px; border: 0; background: transparent; color: var(--muted); border-radius: 12px; padding: 9px 11px;
  display: flex; align-items: center; gap: 11px; cursor: pointer; text-align: right; transition: .18s ease;
}
.nav-item:hover { color: var(--text); background: var(--surface-2); }
.nav-item.is-active { color: var(--text); background: linear-gradient(90deg, rgba(0,107,95,.35), rgba(27,191,174,.09)); }
.nav-item.is-active::before { content: ""; position: absolute; right: 0; width: 3px; height: 22px; border-radius: 3px; background: var(--action); box-shadow: 0 0 16px var(--action); }
.nav-item.is-active svg, .admin-link svg { color: var(--action); }
.nav-badge { margin-right: auto; min-width: 22px; height: 22px; padding: 0 5px; border-radius: 999px; display: grid; place-items: center; color: #061311; background: var(--action); font-size: 10px; }
.sidebar-footer { margin-top: auto; padding-top: 18px; }
.status-chip { display: flex; align-items: center; gap: 8px; padding: 10px 12px; margin-bottom: 7px; color: var(--muted); border: 1px solid var(--border); border-radius: 12px; font-size: 11px; }
.status-chip svg { margin-right: auto; }
.status-dot { width: 8px; height: 8px; background: var(--success); border-radius: 50%; box-shadow: 0 0 12px var(--success); }
.logout { color: #ff9ca6; }

.main-area { min-height: 100vh; margin-right: var(--sidebar-width); }
.topbar {
  position: sticky; top: 0; z-index: 30; height: var(--topbar-height); padding: 0 28px; display: flex; align-items: center; justify-content: space-between; gap: 20px;
  background: color-mix(in srgb, var(--graphite) 82%, transparent); border-bottom: 1px solid var(--border); backdrop-filter: blur(18px);
}
.topbar-start, .topbar-actions { display: flex; align-items: center; gap: 10px; }
.breadcrumbs { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 12px; }
.breadcrumbs strong { color: var(--text); }
.mobile-menu { display: none !important; }
.icon-button {
  width: 39px; height: 39px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface); color: var(--muted); display: inline-grid; place-items: center; cursor: pointer;
}
.icon-button:hover { color: var(--text); border-color: var(--border-strong); background: var(--surface-2); }
.command-trigger { height: 39px; min-width: 210px; border: 1px solid var(--border); border-radius: 12px; padding: 0 11px; background: var(--surface); color: var(--muted); display: flex; align-items: center; gap: 8px; cursor: pointer; }
.command-trigger span { margin-left: auto; }
kbd { padding: 2px 6px; border: 1px solid var(--border); background: var(--surface-2); border-radius: 6px; font-size: 10px; }
.notification-button { position: relative; }
.notification-button > span { position: absolute; top: -5px; left: -5px; min-width: 18px; height: 18px; display: grid; place-items: center; border-radius: 999px; background: var(--danger); color: #fff; font-size: 9px; border: 2px solid var(--graphite); }
.user-chip { max-width: 210px; display: flex; align-items: center; gap: 9px; padding-right: 4px; }
.user-chip > span:last-child { min-width: 0; display: flex; flex-direction: column; line-height: 1.4; }
.user-chip strong, .user-chip small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.user-chip small { direction: ltr; text-align: right; font-size: 10px; }
.content-wrap { max-width: 1540px; margin: 0 auto; padding: 28px; }

.page-header, .page-hero { margin-bottom: 22px; display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; }
.page-header > div:first-child, .page-hero > div:first-child { max-width: 880px; }
.page-hero {
  position: relative; overflow: hidden; padding: 30px; border-radius: var(--radius-lg); border: 1px solid var(--border);
  background: linear-gradient(125deg, rgba(0,107,95,.3), rgba(18,31,34,.88) 50%, rgba(27,191,174,.08));
}
.page-hero::after { content: ""; position: absolute; width: 250px; height: 250px; border-radius: 50%; left: -80px; top: -140px; background: rgba(27,191,174,.15); filter: blur(14px); pointer-events: none; }
.page-hero.compact { padding: 25px 28px; }
.eyebrow { display: inline-block; margin-bottom: 7px; color: var(--action); font-size: 10px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; direction: ltr; }
.hero-actions, .inline-actions, .product-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.section-heading { display: flex; justify-content: space-between; align-items: center; gap: 18px; margin-bottom: 22px; }

.button {
  min-height: 42px; border-radius: 12px; border: 1px solid transparent; padding: 8px 17px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; cursor: pointer; font-weight: 700; transition: .18s ease;
}
.button:hover { transform: translateY(-1px); }
.button.primary { color: #031815; background: linear-gradient(135deg, var(--mint), var(--action)); box-shadow: 0 9px 24px rgba(27,191,174,.17); }
.button.primary:hover { box-shadow: 0 13px 30px rgba(27,191,174,.27); }
.button.ghost { color: var(--text); border-color: var(--border-strong); background: var(--surface); }
.button.ghost:hover { background: var(--surface-2); }
.button.danger { color: #fff; border-color: rgba(255,104,118,.32); background: rgba(255,104,118,.16); }
.button.small { min-height: 36px; padding: 6px 12px; font-size: 12px; }
.button.tiny { min-height: 30px; padding: 4px 9px; border-radius: 9px; font-size: 10px; }
.button.large { min-height: 50px; }
.button.wide { width: 100%; }
.text-link { display: inline-flex; align-items: center; gap: 6px; color: var(--action); font-size: 12px; }

.panel, .stat-card, .product-card, .workspace-card, .summary-card, .payment-panel, .timeline-panel, .auth-card, .install-card, .notification-card, .service-card {
  border: 1px solid var(--border); border-radius: var(--radius); background: color-mix(in srgb, var(--surface) 96%, transparent); box-shadow: 0 8px 30px rgba(0,0,0,.06);
}
.panel { padding: 20px; min-width: 0; }
.panel-header { margin-bottom: 17px; display: flex; justify-content: space-between; align-items: center; gap: 15px; }
.panel-header h2 { margin-bottom: 1px; }
.panel-header p { font-size: 12px; }
.stats-grid, .cards-grid, .product-grid, .dashboard-grid, .split-grid, .security-grid, .checkout-grid, .auth-grid, .requirements-grid { display: grid; gap: 15px; }
.stats-grid { margin-bottom: 18px; }
.stats-grid.four { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.stats-grid.five { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.stat-card { position: relative; overflow: hidden; padding: 17px; display: grid; grid-template-columns: 1fr auto; gap: 1px 10px; }
.stat-card::after { content: ""; position: absolute; width: 80px; height: 80px; border-radius: 50%; left: -35px; bottom: -45px; background: rgba(27,191,174,.08); }
.stat-card > span, .stat-card > small { grid-column: 1; }
.stat-card strong { grid-column: 1; font-size: 25px; line-height: 1.5; }
.stat-card small { font-size: 10px; }
.stat-icon { grid-column: 2; grid-row: 1 / span 3; width: 43px; height: 43px; border-radius: 13px; display: grid; place-items: center; background: rgba(27,191,174,.1); color: var(--action); }
.dashboard-grid { grid-template-columns: minmax(0, 1.6fr) minmax(310px, .8fr); align-items: start; }
.span-2 { grid-column: span 2; }
.cards-grid.two, .form-grid.two, .split-grid, .checkout-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
.cards-grid.three, .form-grid.three { grid-template-columns: repeat(3, minmax(0,1fr)); }
.product-grid { grid-template-columns: repeat(3, minmax(0,1fr)); }
.security-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }

.badge { display: inline-flex; width: max-content; align-items: center; justify-content: center; min-height: 24px; padding: 2px 9px; border-radius: 999px; border: 1px solid var(--border); font-size: 10px; white-space: nowrap; }
.badge.success { color: var(--success); background: rgba(69,217,170,.1); border-color: rgba(69,217,170,.23); }
.badge.warning { color: var(--warning); background: rgba(255,189,89,.1); border-color: rgba(255,189,89,.24); }
.badge.danger { color: #ff8e99; background: rgba(255,104,118,.1); border-color: rgba(255,104,118,.24); }
.badge.info { color: var(--info); background: rgba(98,184,255,.1); border-color: rgba(98,184,255,.22); }
.badge.muted { color: var(--muted); }
.badge.large { padding: 7px 13px; font-size: 12px; }

.table-wrap { width: 100%; overflow: auto; border: 1px solid var(--border); border-radius: 12px; }
table { width: 100%; border-collapse: collapse; min-width: 650px; }
th, td { padding: 13px 14px; border-bottom: 1px solid var(--border); text-align: right; vertical-align: middle; }
th { position: sticky; top: 0; z-index: 1; color: var(--muted); background: var(--surface-2); font-size: 10px; font-weight: 700; white-space: nowrap; }
td { font-size: 12px; }
tbody tr:last-child td { border-bottom: 0; }
tbody tr:hover { background: rgba(127,231,226,.025); }
td a { color: var(--action); font-weight: 700; }
.person-cell { display: flex; align-items: center; gap: 9px; }
.person-cell > div { display: flex; flex-direction: column; }
.person-cell small { direction: ltr; text-align: right; }

.service-list, .usage-list, .notification-list, .session-list, .mini-list { display: flex; flex-direction: column; }
.service-row { display: grid; grid-template-columns: auto minmax(0,1fr) auto auto; align-items: center; gap: 11px; padding: 12px 0; border-bottom: 1px solid var(--border); }
.service-row:last-child { border-bottom: 0; }
.service-row > div { min-width: 0; display: flex; flex-direction: column; }
.service-row strong, .service-row small { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.service-logo, .product-icon, .session-icon { width: 42px; height: 42px; border-radius: 13px; display: inline-grid; place-items: center; background: rgba(27,191,174,.1); color: var(--action); border: 1px solid var(--border); font-weight: 800; }
.service-logo.large { width: 58px; height: 58px; border-radius: 18px; font-size: 20px; }
.usage-item { padding: 11px 0; border-bottom: 1px solid var(--border); }
.usage-item:last-child { border-bottom: 0; }
.usage-item > div:first-child { display: flex; justify-content: space-between; gap: 8px; margin-bottom: 8px; font-size: 11px; }
.usage-item span { color: var(--muted); }
.progress { height: 7px; overflow: hidden; background: var(--surface-2); border-radius: 999px; }
.progress i { display: block; height: 100%; background: linear-gradient(90deg, var(--primary), var(--action), var(--mint)); border-radius: inherit; }
.usage-number { font-size: 22px; font-weight: 800; }
.usage-table { display: grid; gap: 12px; }

.empty-state { min-height: 180px; padding: 30px; display: grid; place-items: center; align-content: center; gap: 7px; text-align: center; border: 1px dashed var(--border-strong); border-radius: 13px; background: rgba(127,231,226,.018); }
.empty-state > div { color: var(--action); }
.empty-state.mini { min-height: 105px; padding: 18px; }
.mini-list > a { display: flex; flex-direction: column; padding: 11px 0; border-bottom: 1px solid var(--border); }
.mini-list > a:last-child { border-bottom: 0; }

.filter-bar { display: flex; align-items: center; gap: 8px; overflow: auto; padding-bottom: 11px; margin-bottom: 7px; scrollbar-width: thin; }
.filter-pill { flex: 0 0 auto; min-height: 35px; padding: 6px 12px; border: 1px solid var(--border); background: var(--surface); color: var(--muted); border-radius: 999px; }
.filter-pill.active, .filter-pill:hover { color: #031815; background: var(--action); border-color: var(--action); }
.filter-pill span { opacity: .65; }
.product-card { padding: 19px; display: flex; flex-direction: column; min-height: 330px; transition: .2s ease; }
.product-card:hover { transform: translateY(-3px); border-color: var(--border-strong); box-shadow: 0 20px 44px rgba(0,0,0,.12); }
.product-top, .workspace-card-top, .service-card-top { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-bottom: 15px; }
.product-card h2 { margin-bottom: 0; }
.product-card > small { direction: ltr; text-align: right; margin-bottom: 10px; }
.product-card > p { font-size: 12px; }
.product-price { margin-top: auto; padding-top: 18px; display: flex; align-items: baseline; gap: 5px; }
.product-price strong { font-size: 17px; }
.product-actions { margin-top: 15px; }
.product-actions .button { flex: 1; }
.detail-hero { padding: 25px; display: flex; justify-content: space-between; gap: 25px; align-items: center; }
.detail-price { text-align: left; }
.detail-price strong { display: block; font-size: 26px; }
.selected-product { padding: 15px; display: flex; align-items: center; gap: 11px; background: var(--surface-2); border: 1px solid var(--border); border-radius: 13px; }

.workspace-card { padding: 19px; }
.workspace-card.active { border-color: rgba(27,191,174,.45); box-shadow: inset 0 0 0 1px rgba(27,191,174,.1); }
.workspace-card small { direction: ltr; display: block; margin-bottom: 14px; }

.form-stack { display: flex; flex-direction: column; gap: 15px; }
.form-grid { display: grid; gap: 13px; }
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field > span { color: var(--muted); font-size: 11px; font-weight: 700; }
input, select, textarea {
  width: 100%; color: var(--text); background: var(--surface-2); border: 1px solid var(--border); border-radius: 11px; padding: 10px 12px; outline: none; transition: .15s ease;
}
input, select { min-height: 43px; }
textarea { resize: vertical; min-height: 115px; }
input::placeholder, textarea::placeholder { color: color-mix(in srgb, var(--muted) 70%, transparent); }
input:focus, select:focus, textarea:focus { border-color: var(--action); box-shadow: 0 0 0 3px rgba(27,191,174,.1); }
select option { background: var(--surface); color: var(--text); }
fieldset { margin: 0; padding: 18px; border: 1px solid var(--border); border-radius: 14px; }
legend { padding: 0 8px; color: var(--action); font-weight: 800; }
.inline-form { display: flex; align-items: flex-end; gap: 10px; margin-bottom: 15px; }
.inline-form .field { flex: 1; }
.password-wrap { position: relative; }
.password-wrap input { padding-left: 44px; }
.password-wrap button { position: absolute; left: 4px; top: 4px; }
.segmented { display: grid; grid-template-columns: auto 1fr auto 1fr; align-items: center; gap: 8px; margin-bottom: 15px; padding: 5px; background: var(--surface-2); border-radius: 12px; }
.segmented input { width: 17px; min-height: auto; }
.segmented span { cursor: pointer; padding: 7px; }
.check-row { display: flex; align-items: center; gap: 8px; color: var(--muted); }
.check-row input { width: 17px; min-height: auto; }

.detail-list { margin: 0; display: flex; flex-direction: column; }
.detail-list > div { display: grid; grid-template-columns: 110px minmax(0,1fr); gap: 10px; padding: 11px 0; border-bottom: 1px solid var(--border); }
.detail-list > div:last-child { border-bottom: 0; }
.detail-list dt { color: var(--muted); }
.detail-list dd { margin: 0; min-width: 0; word-break: break-word; }
.summary-card { padding: 18px; }
.summary-card > div, .invoice-totals > div { display: flex; justify-content: space-between; gap: 10px; padding: 9px 0; border-bottom: 1px solid var(--border); }
.summary-total { font-size: 16px; font-weight: 800; border-bottom: 0 !important; }

.timeline-panel { padding: 20px; margin-bottom: 16px; }
.order-timeline { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 0; padding-top: 12px; }
.order-timeline > div { position: relative; padding: 0 8px; text-align: center; display: flex; flex-direction: column; align-items: center; }
.order-timeline > div::before { content: ""; position: absolute; top: 18px; right: -50%; width: 100%; height: 2px; background: var(--border); }
.order-timeline > div:first-child::before { display: none; }
.order-timeline span { z-index: 1; width: 37px; height: 37px; border-radius: 50%; display: grid; place-items: center; background: var(--surface-2); border: 1px solid var(--border-strong); margin-bottom: 7px; }
.order-timeline .done span, .order-timeline .done::before { background: var(--action); color: #041714; border-color: var(--action); }
.order-timeline .active span { border-color: var(--warning); color: var(--warning); }
.order-timeline strong { font-size: 11px; }
.order-timeline small { font-size: 9px; }
.service-delivery { min-height: 250px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; text-align: center; }

.invoice-layout { display: grid; grid-template-columns: minmax(0,1fr) 330px; gap: 17px; align-items: start; }
.invoice-sheet { padding: 27px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); }
.invoice-brand { display: flex; align-items: center; gap: 10px; margin-bottom: 30px; }
.invoice-meta { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 15px; padding: 17px 0; border-block: 1px solid var(--border); margin-bottom: 18px; }
.invoice-totals { max-width: 330px; margin: 20px 0 0 auto; }
.payment-panel { position: sticky; top: calc(var(--topbar-height) + 20px); padding: 20px; }
.payment-success { display: grid; place-items: center; gap: 8px; min-height: 180px; text-align: center; color: var(--success); }

.ticket-layout { display: grid; grid-template-columns: minmax(0,1fr) 290px; gap: 16px; align-items: start; }
.ticket-thread { display: flex; flex-direction: column; gap: 13px; }
.ticket-sidebar { position: sticky; top: calc(var(--topbar-height) + 20px); }
.message-card { padding: 17px; border: 1px solid var(--border); border-radius: 15px; background: var(--surface); }
.message-card.staff { border-color: rgba(27,191,174,.3); background: linear-gradient(135deg, rgba(0,107,95,.16), var(--surface)); }
.message-meta { display: flex; align-items: center; gap: 9px; margin-bottom: 11px; }
.message-meta > div { display: flex; flex-direction: column; line-height: 1.4; }
.message-meta .badge { margin-right: auto; }
.message-body { white-space: normal; color: color-mix(in srgb, var(--text) 90%, var(--muted)); }
.reply-inline { margin-top: 10px; }
.ticket-admin-list { display: grid; gap: 12px; }

.notification-page-list { display: flex; flex-direction: column; gap: 9px; }
.notification-card, .notification-item { display: flex; align-items: flex-start; gap: 10px; padding: 13px; }
.notification-item { border-bottom: 1px solid var(--border); }
.notification-item:last-child { border-bottom: 0; }
.notification-item.unread, .notification-card.unread { background: rgba(27,191,174,.045); }
.notification-dot { flex: 0 0 auto; width: 8px; height: 8px; margin-top: 8px; border-radius: 50%; background: var(--muted); }
.unread .notification-dot { background: var(--action); box-shadow: 0 0 10px var(--action); }
.notification-item > div, .notification-card > div { min-width: 0; flex: 1; }
.notification-item p, .notification-card p { font-size: 11px; }
.notification-title, .notification-type { display: flex; align-items: center; gap: 8px; }

.session-list article { display: grid; grid-template-columns: auto minmax(0,1fr) auto auto; align-items: center; gap: 10px; padding: 11px 0; border-bottom: 1px solid var(--border); }
.session-list article:last-child { border-bottom: 0; }
.session-list article > div { min-width: 0; display: flex; flex-direction: column; }
.session-list strong, .session-list small { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.secret-box, .code-field, .code-block { direction: ltr; text-align: left; word-break: break-all; padding: 12px; background: #061113; color: #a8fff5; border: 1px solid rgba(127,231,226,.16); border-radius: 10px; }
html[data-theme="light"] .secret-box, html[data-theme="light"] .code-field, html[data-theme="light"] .code-block { background: #e7f3f1; color: #00584f; }

.profile-header { display: flex; align-items: center; gap: 14px; padding-bottom: 17px; border-bottom: 1px solid var(--border); }
.profile-header h2, .profile-header p { margin: 0; }

.admin-tabs { display: flex; align-items: center; gap: 5px; overflow: auto; margin-bottom: 15px; padding: 5px; background: var(--surface); border: 1px solid var(--border); border-radius: 13px; }
.admin-tabs a { flex: 0 0 auto; padding: 7px 12px; color: var(--muted); border-radius: 9px; font-size: 11px; }
.admin-tabs a.active, .admin-tabs a:hover { color: #031815; background: var(--action); }

.flash { position: relative; margin-bottom: 13px; padding: 12px 14px; border: 1px solid var(--border); border-radius: 12px; display: flex; align-items: center; gap: 10px; background: var(--surface); }
.flash > button { margin-right: auto; border: 0; background: transparent; color: inherit; cursor: pointer; }
.flash.success { color: var(--success); border-color: rgba(69,217,170,.26); background: rgba(69,217,170,.07); }
.flash.danger { color: #ff9ca6; border-color: rgba(255,104,118,.26); background: rgba(255,104,118,.07); }
.flash.info { color: var(--info); border-color: rgba(98,184,255,.26); background: rgba(98,184,255,.07); }
.flash.secret { align-items: flex-end; justify-content: space-between; color: var(--mint); }
.flash.secret > div { display: flex; flex-direction: column; }
.flash.secret code { direction: ltr; font-size: 12px; word-break: break-all; }
.flash.secret button { margin-right: 0; color: var(--action); }
.callout { padding: 14px; border-radius: 12px; border: 1px solid var(--border); background: var(--surface-2); }
.callout.warning { border-color: rgba(255,189,89,.3); }
.muted-text { color: var(--muted); }

.command-dialog { position: fixed; inset: 0; z-index: 100; padding: 12vh 15px 15px; background: rgba(3,8,9,.66); backdrop-filter: blur(10px); }
.command-box { width: min(630px,100%); margin: 0 auto; overflow: hidden; background: var(--surface); border: 1px solid var(--border-strong); border-radius: 18px; box-shadow: var(--shadow); }
.command-search { display: flex; align-items: center; gap: 10px; padding: 12px 15px; border-bottom: 1px solid var(--border); }
.command-search input { min-height: 40px; border: 0; background: transparent; box-shadow: none !important; padding: 5px; }
.command-search button { border: 0; background: var(--surface-2); color: var(--muted); border-radius: 7px; padding: 4px 7px; font-size: 10px; cursor: pointer; }
.command-results { padding: 8px; }
.command-results a { display: flex; align-items: center; gap: 11px; padding: 10px; border-radius: 11px; }
.command-results a:hover { background: var(--surface-2); }
.command-results a > span { width: 38px; height: 38px; display: grid; place-items: center; color: var(--action); background: rgba(27,191,174,.08); border-radius: 11px; }
.command-results a > div { display: flex; flex-direction: column; }

/* Authentication and installer */
.auth-body, .install-body { min-height: 100vh; }
.auth-grid { min-height: 100vh; grid-template-columns: minmax(420px,.85fr) minmax(500px,1.15fr); }
.auth-panel { display: grid; place-items: center; padding: 35px; background: var(--graphite); }
.auth-card { width: min(460px,100%); padding: 28px; }
.auth-heading { margin: 25px 0; }
.auth-heading h1 { font-size: 27px; }
.auth-note { margin-top: 15px; text-align: center; color: var(--muted); }
.auth-divider { margin: 18px 0; height: 1px; background: var(--border); }
.auth-showcase { position: relative; overflow: hidden; display: grid; place-items: center; padding: 55px; background: linear-gradient(140deg,#061113,#073b39 65%,#006b5f); }
.auth-showcase::before, .auth-showcase::after { content: ""; position: absolute; border: 1px solid rgba(127,231,226,.15); border-radius: 50%; }
.auth-showcase::before { width: 640px; height: 640px; left: -170px; top: -180px; }
.auth-showcase::after { width: 400px; height: 400px; right: -200px; bottom: -180px; }
.showcase-content { position: relative; z-index: 1; max-width: 590px; }
.showcase-content h2 { font-size: clamp(28px,3vw,48px); }
.showcase-content p { color: #bcd6d2; font-size: 16px; }
.showcase-points { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 10px; margin-top: 28px; }
.showcase-points div { padding: 13px; border: 1px solid rgba(127,231,226,.14); background: rgba(7,23,23,.35); border-radius: 13px; backdrop-filter: blur(10px); }
.showcase-points strong { display: block; color: #f3fffc; }
.showcase-points small { color: #9fc3bd; }

.install-shell { width: min(1050px,calc(100% - 30px)); margin: 35px auto; }
.install-card { padding: 27px; }
.requirements-grid { grid-template-columns: repeat(4,minmax(0,1fr)); margin-bottom: 20px; }
.requirement { padding: 13px; border-radius: 12px; border: 1px solid var(--border); display: flex; flex-direction: column; }
.requirement.ok { border-color: rgba(69,217,170,.27); background: rgba(69,217,170,.06); }
.requirement.bad { border-color: rgba(255,104,118,.27); background: rgba(255,104,118,.06); }
.success-card { max-width: 680px; margin: 12vh auto 0; padding: 35px; text-align: center; }
.success-icon { width: 74px; height: 74px; margin: 0 auto 16px; display: grid; place-items: center; border-radius: 23px; background: rgba(69,217,170,.11); color: var(--success); }

.onboarding-shell { max-width: 900px; margin: 0 auto; }
.onboarding-intro { padding: 28px; text-align: center; }
.onboarding-steps { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 13px; margin-top: 15px; }
.step-card { padding: 17px; border: 1px solid var(--border); background: var(--surface); border-radius: 14px; }
.step-card > span { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 11px; color: #031815; background: var(--action); font-weight: 900; margin-bottom: 11px; }

.error-page { min-height: 100vh; display: grid; place-items: center; padding: 20px; text-align: center; }
.error-code { font-size: clamp(80px,14vw,180px); line-height: 1; font-weight: 900; color: transparent; -webkit-text-stroke: 1px var(--action); opacity: .45; }
.centered { text-align: center; }
.narrow { max-width: 700px; margin-inline: auto; }
.grand { font-size: 38px; }

.sidebar-backdrop { display: none; }

@media (max-width: 1250px) {
  .product-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .stats-grid.five { grid-template-columns: repeat(3,minmax(0,1fr)); }
  .command-trigger { min-width: 42px; width: 42px; padding: 0; justify-content: center; }
  .command-trigger span, .command-trigger kbd { display: none; }
  .user-chip > span:last-child { display: none; }
}

@media (max-width: 980px) {
  :root { --sidebar-width: 280px; }
  .sidebar { transform: translateX(105%); transition: transform .22s ease; box-shadow: var(--shadow); }
  body.sidebar-open { overflow: hidden; }
  body.sidebar-open .sidebar { transform: translateX(0); }
  .sidebar-close, .mobile-menu { display: inline-grid !important; }
  .sidebar-backdrop { position: fixed; inset: 0; z-index: 35; background: rgba(0,0,0,.48); backdrop-filter: blur(3px); }
  body.sidebar-open .sidebar-backdrop { display: block; }
  .main-area { margin-right: 0; }
  .topbar { padding-inline: 18px; }
  .breadcrumbs { display: none; }
  .stats-grid.four, .stats-grid.five { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .dashboard-grid { grid-template-columns: 1fr; }
  .dashboard-grid .span-2 { grid-column: span 1; }
  .invoice-layout, .ticket-layout { grid-template-columns: 1fr; }
  .payment-panel, .ticket-sidebar { position: static; }
}

@media (max-width: 740px) {
  body { font-size: 13px; }
  .topbar { height: 64px; padding-inline: 12px; }
  .topbar-actions { gap: 6px; }
  .user-chip { display: none; }
  .content-wrap { padding: 16px 12px 28px; }
  .page-header, .page-hero, .detail-hero { align-items: stretch; flex-direction: column; padding: 20px; }
  .page-header { padding: 0; }
  .hero-actions .button { flex: 1; }
  .stats-grid.four, .stats-grid.five, .product-grid, .cards-grid.two, .cards-grid.three, .split-grid, .security-grid, .checkout-grid, .form-grid.two, .form-grid.three { grid-template-columns: 1fr; }
  .span-2 { grid-column: span 1; }
  .panel { padding: 15px; }
  .stat-card strong { font-size: 21px; }
  .product-card { min-height: 300px; }
  .inline-form { align-items: stretch; flex-direction: column; }
  .detail-list > div { grid-template-columns: 95px minmax(0,1fr); }
  .order-timeline { grid-template-columns: 1fr; gap: 12px; }
  .order-timeline > div { min-height: 48px; padding-right: 53px; align-items: flex-start; text-align: right; justify-content: center; }
  .order-timeline > div::before { right: 18px; top: -19px; width: 2px; height: 30px; }
  .order-timeline > div:first-child::before { display: none; }
  .order-timeline span { position: absolute; right: 0; top: 6px; margin: 0; }
  .service-row { grid-template-columns: auto minmax(0,1fr) auto; }
  .service-row > .icon-button { grid-column: 2 / span 2; width: 100%; }
  .session-list article { grid-template-columns: auto minmax(0,1fr) auto; }
  .session-list article form { grid-column: 2 / span 2; }
  .invoice-sheet { padding: 17px; }
  .invoice-meta { grid-template-columns: 1fr; }
  .auth-grid { display: block; }
  .auth-panel { min-height: 100vh; padding: 20px 14px; }
  .auth-showcase { display: none; }
  .auth-card { padding: 20px; }
  .install-shell { width: min(100% - 20px,1050px); margin: 10px auto; }
  .install-card { padding: 17px; }
  .requirements-grid, .onboarding-steps { grid-template-columns: 1fr; }
  .segmented { grid-template-columns: auto 1fr; }
  .command-dialog { padding-top: 7vh; }
  table { min-width: 600px; }
}

@media (max-width: 420px) {
  .stats-grid.four, .stats-grid.five { grid-template-columns: 1fr; }
  .notification-button { display: none; }
  .page-hero { padding: 17px; }
  .hero-actions { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; animation: none !important; }
}

/* =========================================================
   Rayvina Account Auth UI 1.2.0
   Mobile-first authentication refresh — no database changes
   ========================================================= */
.auth-body {
  position: relative;
  min-height: 100vh;
  overflow-x: hidden;
  background:
    radial-gradient(circle at 78% 12%, rgba(27,191,174,.16), transparent 28rem),
    radial-gradient(circle at 10% 88%, rgba(0,107,95,.13), transparent 30rem),
    var(--graphite);
}
.auth-body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: .42;
  background-image:
    linear-gradient(rgba(127,231,226,.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(127,231,226,.035) 1px, transparent 1px);
  background-size: 46px 46px;
  mask-image: linear-gradient(to bottom, #000, transparent 88%);
}
.skip-link {
  position: fixed;
  z-index: 200;
  top: 12px;
  right: 12px;
  transform: translateY(-160%);
  padding: 8px 13px;
  color: #031815;
  background: var(--action);
  border-radius: 10px;
  font-weight: 800;
}
.skip-link:focus { transform: translateY(0); }
.auth-orbit {
  position: fixed;
  z-index: 0;
  pointer-events: none;
  border: 1px solid rgba(127,231,226,.09);
  border-radius: 50%;
}
.auth-orbit-one { width: 440px; height: 440px; top: -260px; right: 28%; }
.auth-orbit-two { width: 300px; height: 300px; bottom: -190px; left: 27%; }
.auth-theme-toggle {
  position: fixed;
  z-index: 80;
  top: max(18px, env(safe-area-inset-top));
  left: 20px;
  border-color: rgba(127,231,226,.2);
  background: color-mix(in srgb, var(--surface) 84%, transparent);
  backdrop-filter: blur(16px);
  box-shadow: 0 12px 34px rgba(0,0,0,.15);
}
.auth-shell {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(390px, .9fr) minmax(560px, 1.1fr);
}
.auth-showcase {
  position: sticky;
  top: 0;
  min-height: 100vh;
  height: 100vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: clamp(32px, 4vw, 64px);
  border-left: 1px solid rgba(127,231,226,.12);
  background:
    radial-gradient(circle at 14% 14%, rgba(127,231,226,.16), transparent 17rem),
    linear-gradient(145deg, #061012 0%, #082426 52%, #00483f 100%);
}
.auth-showcase::before {
  content: "";
  position: absolute;
  width: 540px;
  height: 540px;
  left: -250px;
  bottom: -250px;
  border: 1px solid rgba(127,231,226,.12);
  border-radius: 50%;
  box-shadow: 0 0 0 70px rgba(127,231,226,.02), 0 0 0 140px rgba(127,231,226,.018);
}
.auth-showcase::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(112deg, transparent 0 48%, rgba(127,231,226,.035) 48.2% 48.4%, transparent 48.6% 100%);
}
.auth-showcase-top,
.auth-showcase-content,
.auth-showcase-bottom { position: relative; z-index: 2; }
.auth-showcase-top,
.auth-showcase-bottom { display: flex; align-items: center; justify-content: space-between; gap: 18px; }
.auth-brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  direction: ltr;
  text-align: left;
}
.auth-brand img {
  width: 52px;
  height: 52px;
  border-radius: 16px;
  box-shadow: 0 14px 35px rgba(0,0,0,.24);
}
.auth-brand > span { display: flex; flex-direction: column; line-height: 1.1; }
.auth-brand strong { color: #f3fffc; font-size: 21px; letter-spacing: .025em; }
.auth-brand small { margin-top: 6px; color: #8cd8cf; font-size: 9px; letter-spacing: .18em; text-transform: uppercase; }
.auth-system-status,
.auth-mobile-secure {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: #b8d5d0;
  font-size: 10px;
  white-space: nowrap;
}
.auth-system-status i {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--success);
  box-shadow: 0 0 0 4px rgba(69,217,170,.09), 0 0 14px var(--success);
}
.auth-showcase-content { max-width: 620px; margin-block: 40px; }
.auth-kicker {
  display: inline-flex;
  margin-bottom: 18px;
  color: #87ccc4;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .16em;
  direction: ltr;
}
.auth-showcase-content h1 {
  max-width: 610px;
  margin-bottom: 18px;
  color: #f3fffc;
  font-size: clamp(34px, 4vw, 62px);
  line-height: 1.28;
  letter-spacing: -.045em;
}
.auth-showcase-content > p {
  max-width: 610px;
  color: #b3cec9;
  font-size: clamp(14px, 1.2vw, 17px);
  line-height: 2;
}
.auth-feature-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap: 11px;
  margin-top: 32px;
}
.auth-feature-grid article {
  min-width: 0;
  display: grid;
  grid-template-columns: auto minmax(0,1fr);
  align-items: start;
  gap: 11px;
  padding: 14px;
  border: 1px solid rgba(127,231,226,.13);
  border-radius: 15px;
  background: rgba(3,17,18,.3);
  backdrop-filter: blur(12px);
  transition: transform .2s ease, border-color .2s ease, background .2s ease;
}
.auth-feature-grid article:hover {
  transform: translateY(-2px);
  border-color: rgba(127,231,226,.25);
  background: rgba(3,17,18,.43);
}
.auth-feature-grid article > span {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(127,231,226,.13);
  border-radius: 12px;
  color: var(--mint);
  background: rgba(27,191,174,.08);
}
.auth-feature-grid article div { min-width: 0; display: flex; flex-direction: column; }
.auth-feature-grid strong { color: #f3fffc; font-size: 12px; }
.auth-feature-grid small { margin-top: 2px; color: #91b2ac; font-size: 10px; line-height: 1.7; }
.auth-showcase-bottom { align-items: flex-end; }
.auth-proof { display: flex; flex-direction: column; line-height: 1.35; }
.auth-proof strong { color: #f3fffc; font-size: 13px; letter-spacing: .07em; }
.auth-proof span { color: #86aaa4; font-size: 9px; }
.auth-showcase-bottom > p {
  margin-right: auto;
  color: #76a29b;
  font-size: 8px;
  letter-spacing: .14em;
  direction: ltr;
}
.auth-panel {
  min-width: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 58px clamp(30px, 6vw, 90px) 28px;
  background: transparent;
}
.auth-mobile-header,
.auth-mobile-benefits { display: none; }
.auth-tabs {
  width: min(540px, 100%);
  display: grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap: 5px;
  margin-bottom: 14px;
  padding: 5px;
  border: 1px solid var(--border);
  border-radius: 15px;
  background: color-mix(in srgb, var(--surface) 88%, transparent);
  backdrop-filter: blur(14px);
}
.auth-tabs a {
  min-height: 42px;
  display: grid;
  place-items: center;
  border-radius: 11px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  transition: .18s ease;
}
.auth-tabs a:hover { color: var(--text); background: var(--surface-2); }
.auth-tabs a.active {
  color: #031815;
  background: linear-gradient(135deg, var(--mint), var(--action));
  box-shadow: 0 9px 24px rgba(27,191,174,.16);
}
.auth-card {
  width: min(540px, 100%);
  padding: clamp(24px, 3vw, 36px);
  border-color: var(--border-strong);
  border-radius: 24px;
  background: color-mix(in srgb, var(--surface) 94%, transparent);
  box-shadow: 0 28px 90px rgba(0,0,0,.2);
  backdrop-filter: blur(24px);
}
.auth-card .flash { margin-bottom: 19px; }
.auth-heading {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  margin: 0 0 27px;
}
.auth-heading-icon {
  width: 48px;
  height: 48px;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  border: 1px solid var(--border-strong);
  border-radius: 15px;
  color: var(--action);
  background: linear-gradient(145deg, rgba(27,191,174,.13), rgba(0,107,95,.05));
  box-shadow: inset 0 1px rgba(255,255,255,.04);
}
.auth-heading-icon.large { width: 62px; height: 62px; margin: 0 auto 4px; border-radius: 20px; }
.auth-heading h2 { margin: 0 0 5px; font-size: clamp(23px, 2vw, 29px); letter-spacing: -.025em; }
.auth-heading p { font-size: 12px; line-height: 1.8; }
.centered-heading { flex-direction: column; align-items: center; text-align: center; }
.auth-form { gap: 18px; }
.auth-field { gap: 8px; }
.auth-field > .field-label {
  color: var(--text);
  font-size: 11px;
  font-weight: 800;
}
.input-shell {
  position: relative;
  display: flex;
  align-items: center;
  min-height: 52px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface-2);
  transition: border-color .16s ease, box-shadow .16s ease, background .16s ease;
}
.input-shell:focus-within {
  border-color: var(--action);
  background: var(--surface);
  box-shadow: 0 0 0 4px rgba(27,191,174,.1);
}
.input-shell:has(input:user-invalid) { border-color: rgba(255,104,118,.5); }
.input-shell .input-icon {
  width: 47px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  color: var(--muted);
}
.input-shell:focus-within .input-icon { color: var(--action); }
.input-shell input {
  min-width: 0;
  min-height: 50px;
  padding: 10px 0 10px 12px;
  border: 0;
  border-radius: inherit;
  background: transparent;
  box-shadow: none !important;
}
.ltr-input { direction: ltr; text-align: left; }
.ltr-input::placeholder { direction: rtl; text-align: right; }
.password-shell input { padding-left: 63px; }
.password-toggle {
  position: absolute;
  left: 6px;
  top: 50%;
  transform: translateY(-50%);
  min-width: 51px;
  min-height: 36px;
  padding: 5px 9px;
  border: 0;
  border-radius: 10px;
  color: var(--action);
  background: rgba(27,191,174,.08);
  font-size: 10px;
  font-weight: 800;
  cursor: pointer;
}
.password-toggle:hover { background: rgba(27,191,174,.15); }
.field-help { color: var(--muted); font-size: 9px; line-height: 1.65; }
.field-help.centered { text-align: center; }
.field-error,
.caps-warning { color: #ff9ca6; font-size: 9px; }
.auth-form-options {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.auth-check { align-items: flex-start; cursor: pointer; }
.auth-check input {
  width: 19px;
  height: 19px;
  flex: 0 0 auto;
  margin-top: 2px;
  accent-color: var(--action);
}
.auth-check span { font-size: 10px; line-height: 1.8; }
.security-hint {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: var(--success);
  font-size: 9px;
  white-space: nowrap;
}
.auth-submit {
  position: relative;
  min-height: 52px;
  border-radius: 14px;
  font-size: 12px;
  overflow: hidden;
}
.auth-submit::before {
  content: "";
  position: absolute;
  inset: 0;
  transform: translateX(110%);
  background: linear-gradient(90deg, transparent, rgba(255,255,255,.32), transparent);
  transition: transform .55s ease;
}
.auth-submit:hover::before { transform: translateX(-110%); }
.auth-submit:disabled { cursor: wait; opacity: .82; transform: none; }
.auth-submit.is-loading::after {
  content: "";
  width: 17px;
  height: 17px;
  border: 2px solid rgba(3,24,21,.25);
  border-top-color: #031815;
  border-radius: 50%;
  animation: auth-spin .7s linear infinite;
}
@keyframes auth-spin { to { transform: rotate(360deg); } }
.auth-separator {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 20px 0;
  color: var(--muted);
  font-size: 9px;
}
.auth-separator::before,
.auth-separator::after { content: ""; height: 1px; flex: 1; background: var(--border); }
.auth-secondary-action { min-height: 49px; border-radius: 14px; font-size: 11px; }
.auth-trust-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 18px;
  color: var(--muted);
  font-size: 8px;
}
.auth-trust-row span { display: inline-flex; align-items: center; gap: 4px; }
.auth-trust-row svg { color: var(--success); }
.auth-note { margin: 16px 0 0; text-align: center; color: var(--muted); font-size: 8px; line-height: 1.8; }
.auth-panel-footer {
  width: min(540px,100%);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-top: 18px;
  color: var(--muted);
  font-size: 8px;
}
.auth-panel-footer span:first-child { direction: ltr; }
.auth-form-section {
  padding-bottom: 18px;
  border-bottom: 1px solid var(--border);
}
.auth-form-section:last-of-type { padding-bottom: 0; border-bottom: 0; }
.auth-section-heading {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 13px;
}
.auth-section-heading > span {
  width: 31px;
  height: 31px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border: 1px solid var(--border-strong);
  border-radius: 10px;
  color: var(--action);
  background: rgba(27,191,174,.08);
  font-weight: 900;
  font-size: 11px;
}
.auth-section-heading > div { display: flex; flex-direction: column; line-height: 1.55; }
.auth-section-heading strong { font-size: 11px; }
.auth-section-heading small { font-size: 9px; }
.auth-fields-grid { gap: 11px; }
.password-strength {
  margin-top: 12px;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: 13px;
  background: color-mix(in srgb, var(--surface-2) 82%, transparent);
}
.strength-meter { display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; direction: ltr; }
.strength-meter i { height: 5px; border-radius: 999px; background: var(--surface-3); transition: .18s ease; }
.password-strength[data-score="1"] .strength-meter i:nth-child(-n+1) { background: var(--danger); }
.password-strength[data-score="2"] .strength-meter i:nth-child(-n+2) { background: var(--warning); }
.password-strength[data-score="3"] .strength-meter i:nth-child(-n+3) { background: var(--action); }
.password-strength[data-score="4"] .strength-meter i:nth-child(-n+4) { background: var(--success); }
.strength-copy { display: flex; align-items: center; gap: 5px; margin-top: 8px; font-size: 9px; }
.strength-copy span { color: var(--muted); }
.strength-copy strong { color: var(--text); }
.password-rules {
  display: flex;
  flex-wrap: wrap;
  gap: 5px 12px;
  margin: 9px 0 0;
  padding: 0;
  list-style: none;
}
.password-rules li { position: relative; padding-right: 12px; color: var(--muted); font-size: 8px; }
.password-rules li::before {
  content: "";
  position: absolute;
  right: 0;
  top: .7em;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--surface-3);
}
.password-rules li.valid { color: var(--success); }
.password-rules li.valid::before { background: var(--success); box-shadow: 0 0 8px rgba(69,217,170,.45); }
.terms-check {
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: 13px;
  background: rgba(127,231,226,.025);
}
.auth-switch-copy { margin-top: 17px; text-align: center; font-size: 10px; }
.auth-switch-copy a { color: var(--action); font-weight: 800; }
.otp-shell { justify-content: center; }
.otp-input {
  min-height: 66px !important;
  padding: 10px 16px !important;
  direction: ltr;
  text-align: center;
  font-family: "JetBrains Mono", Consolas, monospace;
  font-size: 28px;
  font-weight: 800;
  letter-spacing: .34em;
}
.mfa-help-box {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-top: 18px;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: 13px;
  color: var(--action);
  background: var(--surface-2);
}
.mfa-help-box > div { display: flex; flex-direction: column; }
.mfa-help-box strong { color: var(--text); font-size: 10px; }
.mfa-help-box small { margin-top: 2px; font-size: 9px; line-height: 1.7; }
.auth-back-link { width: 100%; justify-content: center; margin-top: 18px; }

html[data-theme="light"] .auth-showcase { color: #f3fffc; }
@media (prefers-color-scheme: light) {
  html[data-theme="system"] .auth-showcase { color: #f3fffc; }
}

@media (max-width: 1180px) {
  .auth-shell { grid-template-columns: minmax(350px,.78fr) minmax(500px,1.22fr); }
  .auth-showcase { padding: 34px; }
  .auth-showcase-content h1 { font-size: 39px; }
  .auth-feature-grid { grid-template-columns: 1fr; }
  .auth-feature-grid article:nth-child(n+4) { display: none; }
  .auth-showcase-bottom .auth-proof:nth-child(3) { display: none; }
}

@media (max-width: 860px) {
  .auth-body { min-height: 100svh; }
  .auth-theme-toggle {
    top: calc(max(12px, env(safe-area-inset-top)) + 2px);
    left: 13px;
    width: 38px;
    height: 38px;
    border-radius: 12px;
  }
  .auth-orbit-one { right: -190px; }
  .auth-orbit-two { left: -150px; }
  .auth-shell { display: block; min-height: 100svh; }
  .auth-showcase { display: none; }
  .auth-panel {
    min-height: 100svh;
    justify-content: flex-start;
    padding: calc(max(14px, env(safe-area-inset-top)) + 2px) 14px calc(22px + env(safe-area-inset-bottom));
  }
  .auth-mobile-header {
    width: min(560px,100%);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    min-height: 44px;
    padding-left: 54px;
    margin-bottom: 16px;
  }
  .auth-brand.compact { gap: 9px; }
  .auth-brand.compact img { width: 42px; height: 42px; border-radius: 13px; }
  .auth-brand.compact strong { color: var(--text); font-size: 18px; }
  .auth-brand.compact small { margin-top: 4px; color: var(--action); }
  .auth-mobile-secure { color: var(--success); font-size: 9px; }
  .auth-tabs { width: min(560px,100%); margin-bottom: 10px; }
  .auth-card {
    width: min(560px,100%);
    padding: 24px;
    border-radius: 21px;
    box-shadow: 0 20px 60px rgba(0,0,0,.16);
  }
  .auth-panel-footer { width: min(560px,100%); }
  .auth-mobile-benefits {
    width: min(560px,100%);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 14px;
    color: var(--muted);
    font-size: 8px;
  }
  .auth-mobile-benefits span { display: inline-flex; align-items: center; gap: 4px; }
  .auth-mobile-benefits svg { color: var(--success); }
}

@media (max-width: 560px) {
  .auth-body::before { background-size: 32px 32px; opacity: .32; }
  .auth-panel { padding-inline: 10px; }
  .auth-mobile-header { padding-inline: 4px 52px; margin-bottom: 12px; }
  .auth-mobile-secure { display: none; }
  .auth-tabs { position: relative; z-index: 2; margin-bottom: 8px; border-radius: 14px; }
  .auth-tabs a { min-height: 40px; }
  .auth-card { padding: 20px 16px; border-radius: 19px; }
  .auth-heading { gap: 11px; margin-bottom: 22px; }
  .auth-heading-icon { width: 43px; height: 43px; border-radius: 13px; }
  .auth-heading h2 { font-size: 22px; }
  .auth-heading p { font-size: 10px; }
  .auth-fields-grid { grid-template-columns: 1fr !important; }
  .input-shell { min-height: 51px; }
  .input-shell input { font-size: 14px; }
  .auth-form-options { align-items: flex-start; }
  .security-hint { margin-top: 3px; }
  .auth-submit { min-height: 51px; }
  .auth-trust-row { gap: 7px 10px; }
  .auth-panel-footer { flex-direction: column; justify-content: center; text-align: center; gap: 2px; margin-top: 15px; }
  .auth-mobile-benefits { gap: 5px 11px; }
  .password-rules { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); }
  .otp-input { font-size: 24px; letter-spacing: .24em; }
}

@media (max-width: 380px) {
  .auth-panel { padding-inline: 7px; }
  .auth-card { padding: 18px 13px; }
  .auth-mobile-header { padding-right: 3px; }
  .auth-brand.compact img { width: 39px; height: 39px; }
  .auth-heading-icon { display: none; }
  .auth-heading { display: block; }
  .auth-form-options { flex-direction: column; gap: 7px; }
  .password-rules { grid-template-columns: 1fr; }
  .auth-mobile-benefits span:nth-child(2) { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .auth-submit::before { display: none; }
}

/* Rayvina Account 1.3.0: Identity, SMS OTP, integrations and mobile hardening */
@font-face{font-family:IRANSansX;src:local("IRANSansX"),local("IRANSans"),url("../fonts/IRANSansX-Regular.woff2") format("woff2");font-style:normal;font-weight:100 900;font-display:swap}
html,body,button,input,select,textarea{font-family:IRANSansX,IRANSans,"Vazirmatn",Tahoma,Arial,sans-serif}
.otp-login-button{display:flex;align-items:center;justify-content:space-between;background:rgba(27,191,174,.1);border:1px solid rgba(27,191,174,.38);color:var(--text);text-decoration:none}.otp-login-button span{display:flex;align-items:center;gap:8px}.verified-phone-card{display:flex;align-items:center;gap:12px;padding:13px 14px;border:1px solid rgba(69,212,154,.36);background:rgba(69,212,154,.08);border-radius:14px;margin-bottom:18px}.verified-phone-card>span{display:grid;place-items:center;width:36px;height:36px;border-radius:11px;background:rgba(69,212,154,.15);color:var(--success)}.verified-phone-card div{display:grid;flex:1}.verified-phone-card small{color:var(--muted)}.verified-phone-card a{color:var(--primary);font-weight:700}.otp-field{max-width:440px;margin-inline:auto;width:100%}.otp-shell .otp-input{text-align:center!important;font-size:28px;letter-spacing:.32em;font-weight:800}.otp-actions{margin-top:16px}.auth-secret{font-weight:800;direction:rtl}.identity-header{align-items:center}.identity-score{display:grid;place-items:center;min-width:150px;padding:16px;border:1px solid var(--border);border-radius:18px;background:var(--surface)}.identity-score strong{font-size:28px;color:var(--primary)}.identity-score span{color:var(--muted);font-size:12px}.profile-tabs{display:flex;gap:8px;overflow-x:auto;padding:6px;margin-bottom:18px;border:1px solid var(--border);border-radius:15px;background:var(--surface);scrollbar-width:none}.profile-tabs a{white-space:nowrap;padding:9px 13px;border-radius:10px;color:var(--muted);text-decoration:none;font-weight:700;font-size:13px}.profile-tabs a:hover{background:var(--surface-2);color:var(--text)}.identity-grid{display:grid;grid-template-columns:minmax(0,2fr) minmax(250px,1fr);gap:18px;align-items:start}.identity-main{grid-column:1}.identity-summary{grid-column:2;grid-row:1;position:sticky;top:88px}.section-title{display:flex;align-items:flex-start;justify-content:space-between;gap:14px;margin-bottom:20px}.section-title>div:first-child{display:flex;gap:11px}.section-title h2,.section-title p{margin:0}.section-title p{color:var(--muted);font-size:12px;margin-top:4px}.section-icon{display:grid;place-items:center;min-width:42px;height:42px;border-radius:13px;background:rgba(27,191,174,.1);color:var(--primary)}.profile-hero{display:flex;align-items:center;gap:14px;padding:15px;border:1px solid var(--border);border-radius:16px;background:var(--surface-2);margin-bottom:18px}.profile-hero>div{display:grid;gap:2px;min-width:0}.profile-hero strong{font-size:18px}.profile-hero span,.profile-hero small{color:var(--muted);overflow-wrap:anywhere}.identity-status-list{display:grid;gap:10px;margin:18px 0}.identity-status-list>div{display:flex;gap:10px;align-items:center;padding:12px;border:1px solid var(--border);border-radius:13px}.identity-status-list>div>span{color:var(--primary)}.identity-status-list p{display:grid;margin:0}.identity-status-list small{color:var(--muted)}.verified-phone-display{padding:15px;border:1px solid var(--border);border-radius:14px;background:var(--surface-2);margin-bottom:16px}.verified-phone-display div{display:grid}.verified-phone-display strong{font-size:18px}.verified-phone-display small{color:var(--muted)}.phone-verify-grid{grid-template-columns:minmax(0,1fr) auto;align-items:end}.phone-verify-grid .button{min-height:49px}.address-list{display:grid;gap:11px;margin-bottom:15px}.address-card{padding:15px;border:1px solid var(--border);border-radius:15px;background:var(--surface-2)}.address-card-head{display:flex;justify-content:space-between;gap:10px}.address-card-head>div:first-child{display:flex;align-items:center;gap:8px}.address-card p{margin:10px 0 5px;line-height:1.8}.address-card small{color:var(--muted)}.inline-actions{display:flex;gap:7px;align-items:center;flex-wrap:wrap}.link-button{border:0;background:transparent;color:var(--primary);cursor:pointer;font:700 12px inherit}.danger-text{color:var(--danger)!important}.form-disclosure{border:1px dashed var(--border);border-radius:15px;padding:0 14px}.form-disclosure summary{display:flex;align-items:center;gap:8px;padding:14px 0;cursor:pointer;font-weight:800}.form-disclosure form{padding-bottom:16px}.field textarea{width:100%;border:1px solid var(--border);border-radius:12px;background:var(--input-bg,var(--surface-2));color:var(--text);padding:12px;font:inherit;resize:vertical}.upload-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px}.upload-card{display:grid;place-items:center;text-align:center;gap:6px;padding:18px 10px;border:1px dashed var(--border);border-radius:15px;background:var(--surface-2);cursor:pointer}.upload-card>span{color:var(--primary)}.upload-card small{color:var(--muted)}.upload-card input{max-width:100%;font-size:11px}.privacy-note,.state-box{display:flex;gap:9px;padding:13px 14px;border:1px solid var(--border);border-radius:13px;line-height:1.8;margin:13px 0;color:var(--muted)}.state-box{display:block}.state-box strong{color:var(--text)}.state-box p{margin:5px 0 0}.state-box.success{border-color:rgba(69,212,154,.35);background:rgba(69,212,154,.07)}.state-box.warning{border-color:rgba(255,190,92,.35);background:rgba(255,190,92,.07)}.state-box.danger{border-color:rgba(255,107,125,.35);background:rgba(255,107,125,.07)}.document-list{display:grid;gap:8px;margin-top:18px}.document-list a{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:12px;border:1px solid var(--border);border-radius:12px;color:var(--text);text-decoration:none}.document-list a span{display:flex;align-items:center;gap:7px}.document-list small{color:var(--muted)}.integration-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px;margin-bottom:18px}.integration-health{display:block;color:var(--muted);margin-top:10px}.badge.warning{background:rgba(255,190,92,.12);color:#ffca75}.badge.danger{background:rgba(255,107,125,.12);color:#ff98a6}.badge.muted{background:var(--surface-2);color:var(--muted)}
@media(max-width:900px){.identity-grid{grid-template-columns:1fr}.identity-main,.identity-summary{grid-column:1}.identity-summary{grid-row:auto;position:static}.integration-grid{grid-template-columns:1fr}.upload-grid{grid-template-columns:1fr}.identity-score{display:none}}
@media(max-width:620px){.profile-tabs{margin-inline:-4px}.section-title{align-items:flex-start}.phone-verify-grid{grid-template-columns:1fr}.address-card-head{align-items:flex-start;flex-direction:column}.identity-main{padding:16px 13px}.profile-hero{align-items:flex-start}.document-list a{align-items:flex-start;flex-direction:column}.upload-card{min-height:130px}.auth-card{overflow:hidden}}

/* RAYVINA_INPUT_FOCUS_HOTFIX_BEGIN */
/* Static, clean form focus state. Keeps a visible border without glow, pulse or movement. */
input,
select,
textarea,
.input-shell,
.input-shell input,
.auth-field,
.field {
  animation: none !important;
}

input,
select,
textarea {
  transition: border-color .12s linear, background-color .12s linear !important;
}

input:focus,
select:focus,
textarea:focus,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: none !important;
  box-shadow: none !important;
  transform: none !important;
  animation: none !important;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--action) !important;
}

.input-shell {
  transition: border-color .12s linear, background-color .12s linear !important;
}

.input-shell:focus-within {
  border-color: var(--action) !important;
  background: var(--surface) !important;
  box-shadow: none !important;
  outline: none !important;
  transform: none !important;
  animation: none !important;
}

.input-shell:focus-within .input-icon {
  color: var(--action);
}

.auth-field:focus-within,
.field:focus-within {
  box-shadow: none !important;
  transform: none !important;
  filter: none !important;
  animation: none !important;
}

.input-shell::before,
.input-shell::after,
.auth-field::before,
.auth-field::after,
.field::before,
.field::after {
  animation: none !important;
  transition: none !important;
  transform: none !important;
}

/* Prevent mobile tap flashes around text controls while keeping buttons accessible. */
input,
select,
textarea {
  -webkit-tap-highlight-color: transparent;
}
/* RAYVINA_INPUT_FOCUS_HOTFIX_END */
