/*
 * S3 workspace — Satam design language (aligned with satam.id / myoffice).
 * Bright blue-white wash, navy ink, one blue→cyan brand gradient, glass shell,
 * thin blue-grey hairlines. Shared by login, tenant signup, the tenant POS
 * panel (Metronic content) and the platform (superadmin) panel.
 */
:root {
    --ws-font: 'Plus Jakarta Sans', 'Inter', 'Segoe UI', system-ui, sans-serif;
    --ws-mono: 'DM Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
    --ws-bg: #f4f8ff;
    --ws-bg-glow-1: #dff2ff;
    --ws-bg-glow-2: #e3e9ff;
    --ws-surface: #ffffff;
    --ws-surface-alt: #f7fbff;
    --ws-surface-sunken: #eef5ff;
    --ws-glass: rgba(255, 255, 255, .84);
    --ws-text: #10284a;
    --ws-body: #3f5673;
    --ws-muted: #5f7690;
    --ws-subtle: #8aa1b8;
    --ws-line: #dbe8f5;
    --ws-line-strong: #c6daef;
    --ws-accent: #174be0;
    --ws-accent-strong: #1240bf;
    --ws-accent-2: #00aeca;
    --ws-accent-soft: #edf5ff;
    --ws-accent-ring: rgba(77, 139, 239, .18);
    --ws-gradient: linear-gradient(135deg, #2b3ae8 0%, #1559d8 48%, #0aa3c0 100%);
    --ws-gradient-soft: linear-gradient(115deg, #174be0, #087bdb 62%, #008ba9);
    --ws-seam: linear-gradient(90deg, transparent, #58c9e6, #2f6ff0, transparent);
    --ws-success: #0a8a60;
    --ws-success-soft: #effcf6;
    --ws-success-line: #b7e7d2;
    --ws-danger: #c2334d;
    --ws-danger-soft: #fff5f6;
    --ws-danger-line: #f0c4cb;
    --ws-warning: #9a6210;
    --ws-warning-soft: #fff8ec;
    --ws-warning-line: #f4d9a8;
    --ws-radius-sm: 10px;
    --ws-radius: 14px;
    --ws-radius-lg: 20px;
    --ws-radius-xl: 28px;
    --ws-shadow-sm: 0 1px 2px rgba(16, 40, 74, .04), 0 6px 16px -12px rgba(18, 60, 110, .28);
    --ws-shadow: 0 22px 48px -34px rgba(18, 60, 110, .5), 0 3px 10px -7px rgba(18, 60, 110, .16);
    --ws-shadow-lg: 0 30px 80px -38px rgba(22, 61, 119, .45), 0 6px 18px -12px rgba(22, 61, 119, .2);
    --ws-shadow-accent: 0 14px 28px -14px rgba(23, 75, 224, .62);
    --ws-sidebar-width: 268px;
    --ws-header-height: 72px;
}
html[data-workspace-theme="dark"] {
    --ws-bg: #0a1426;
    --ws-bg-glow-1: #0e2544;
    --ws-bg-glow-2: #151d45;
    --ws-surface: #0f1d34;
    --ws-surface-alt: #132440;
    --ws-surface-sunken: #0c182d;
    --ws-glass: rgba(12, 24, 45, .84);
    --ws-text: #e8f0fc;
    --ws-body: #c1cfe3;
    --ws-muted: #93a7c2;
    --ws-subtle: #6d83a3;
    --ws-line: #22375a;
    --ws-line-strong: #2e4670;
    --ws-accent: #7aa5ff;
    --ws-accent-strong: #a3c0ff;
    --ws-accent-2: #29d4ec;
    --ws-accent-soft: #15294c;
    --ws-accent-ring: rgba(122, 165, 255, .22);
    --ws-success: #53dca5;
    --ws-success-soft: #0f2a25;
    --ws-success-line: #1f5746;
    --ws-danger: #ff91a4;
    --ws-danger-soft: #2c1522;
    --ws-danger-line: #5b2638;
    --ws-warning: #f3c46e;
    --ws-warning-soft: #2a2211;
    --ws-warning-line: #5a4519;
    --ws-shadow-sm: 0 1px 2px rgba(0, 0, 0, .3);
    --ws-shadow: 0 22px 48px -30px rgba(0, 0, 0, .75);
    --ws-shadow-lg: 0 30px 80px -34px rgba(0, 0, 0, .8);
    color-scheme: dark;
}

/* ---------------------------------------------------------------- base -- */
.ws-shell, .ws-login { font-family: var(--ws-font); -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }
.ws-shell *, .ws-login * { box-sizing: border-box; }
.ws-shell {
    margin: 0; color: var(--ws-body); font-size: 14px; line-height: 1.6;
    background:
        radial-gradient(1100px 620px at 102% -12%, var(--ws-bg-glow-1) 0, transparent 62%),
        radial-gradient(900px 560px at -12% 108%, var(--ws-bg-glow-2) 0, transparent 58%),
        var(--ws-bg) !important;
    background-attachment: fixed !important;
}
.ws-shell a, .ws-login a { text-decoration: none; }
:where(.ws-shell, .ws-login) :where(button, input, select, textarea) { font: inherit; }
.ws-shell button { cursor: pointer; }
.ws-shell :focus-visible, .ws-login :focus-visible { outline: 2px solid var(--ws-accent); outline-offset: 3px; }
.ws-icon { width: 20px; height: 20px; flex-shrink: 0; vertical-align: middle; }
.ws-shell [hidden], .ws-login [hidden] { display: none !important; }
.ws-skip-link { position: fixed; top: 12px; left: 12px; z-index: 10000; padding: 11px 18px; border-radius: 12px; background: var(--ws-gradient); color: #fff !important; font-weight: 700; transform: translateY(-180%); }
.ws-skip-link:focus { transform: translateY(0); }

/* --------------------------------------------------------------- brand -- */
.ws-brand { display: inline-flex; align-items: center; gap: 12px; color: var(--ws-text); min-width: 0; }
.ws-brand-mark { display: grid; place-items: center; width: 42px; height: 42px; flex-shrink: 0; border: 1px solid var(--ws-line); border-radius: 13px; background: linear-gradient(180deg, #ffffff, #eef6ff); box-shadow: 0 12px 24px -16px rgba(23, 75, 224, .65), inset 0 1px 0 #fff; }
.ws-brand-mark img { width: 30px; height: 30px; object-fit: contain; }
.ws-brand-copy { display: flex; flex-direction: column; min-width: 0; }
.ws-brand-copy strong { color: var(--ws-text); font-size: 18px; font-weight: 800; letter-spacing: -.03em; line-height: 1.2; overflow-wrap: anywhere; }
.ws-brand-copy small { margin-top: 2px; color: var(--ws-muted); font-size: 10.5px; font-weight: 600; letter-spacing: .01em; white-space: nowrap; }
html[data-workspace-theme="dark"] .ws-brand-mark { background: linear-gradient(180deg, #16294a, #0f1d34); }

/* -------------------------------------------------------- icon buttons -- */
.ws-icon-button { display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 40px; flex-shrink: 0; border: 1px solid var(--ws-line); border-radius: 12px; background: linear-gradient(180deg, var(--ws-surface), var(--ws-surface-alt)); color: var(--ws-muted); box-shadow: var(--ws-shadow-sm); transition: color .18s, border-color .18s, transform .18s; }
.ws-icon-button:hover { color: var(--ws-accent); border-color: var(--ws-line-strong); transform: translateY(-1px); }
.ws-icon-button .ws-icon { width: 18px; height: 18px; }

/* ------------------------------------------------------------- sidebar -- */
.ws-sidebar { position: fixed; inset: 0 auto 0 0; width: var(--ws-sidebar-width); z-index: 1040; display: flex; flex-direction: column; color: var(--ws-body); background: var(--ws-glass); -webkit-backdrop-filter: blur(18px) saturate(1.2); backdrop-filter: blur(18px) saturate(1.2); border-right: 1px solid var(--ws-line); box-shadow: 12px 0 36px -30px rgba(18, 60, 110, .45); }
.ws-sidebar-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 24px 20px 18px 22px; }
.ws-workspace-badge { position: relative; display: flex; align-items: center; gap: 11px; margin: 0 16px 18px; padding: 12px 13px; overflow: hidden; border: 1px solid var(--ws-line); border-radius: 16px; background: linear-gradient(168deg, var(--ws-surface) 0%, var(--ws-surface-alt) 60%, var(--ws-surface-sunken) 100%); box-shadow: var(--ws-shadow-sm); }
.ws-workspace-badge::before { content: ''; position: absolute; top: 0; left: 14%; right: 14%; height: 2px; background: var(--ws-seam); opacity: .75; }
.ws-workspace-symbol { display: grid; place-items: center; width: 34px; height: 34px; flex-shrink: 0; border-radius: 10px; color: #fff; background: var(--ws-gradient); box-shadow: var(--ws-shadow-accent); }
.ws-workspace-symbol .ws-icon { width: 18px; height: 18px; }
.ws-workspace-badge > span:last-child { min-width: 0; }
.ws-workspace-badge small { display: block; color: var(--ws-muted); font-size: 9.5px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.ws-workspace-badge strong { display: block; margin-top: 2px; overflow: hidden; color: var(--ws-text); font-size: 13px; font-weight: 700; white-space: nowrap; text-overflow: ellipsis; }
.ws-navigation { flex: 1; overflow-y: auto; overscroll-behavior: contain; padding: 0 14px 12px; scrollbar-width: thin; scrollbar-color: var(--ws-line-strong) transparent; }
.ws-nav-group + .ws-nav-group { margin-top: 20px; }
.ws-nav-label { margin: 6px 0 8px; padding: 0 12px; color: var(--ws-subtle); font-size: 10px; font-weight: 800; letter-spacing: .13em; text-transform: uppercase; }
.ws-nav-link { position: relative; display: flex; align-items: center; gap: 12px; min-height: 42px; margin: 3px 0; padding: 10px 12px; border-radius: 12px; color: var(--ws-body); font-size: 13px; font-weight: 600; line-height: 1.35; transition: background .18s, color .18s, box-shadow .18s; }
.ws-nav-link .ws-icon { width: 19px; height: 19px; color: var(--ws-muted); transition: color .18s; }
.ws-nav-link:hover { color: var(--ws-accent); background: var(--ws-accent-soft); }
.ws-nav-link:hover .ws-icon { color: var(--ws-accent); }
.ws-nav-link.is-active { color: #fff; background: var(--ws-gradient); box-shadow: 0 14px 26px -16px rgba(23, 75, 224, .85), inset 0 1px 0 rgba(255, 255, 255, .28); }
.ws-nav-link.is-active .ws-icon { color: #fff; }
.ws-active-dot { width: 6px; height: 6px; margin-left: auto; border-radius: 50%; background: #fff; box-shadow: 0 0 0 3px rgba(255, 255, 255, .25); }
.ws-sidebar-bottom { padding: 10px 16px 18px; }
.ws-sidebar-note { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; padding: 12px 13px; border: 1px dashed var(--ws-line-strong); border-radius: 14px; background: var(--ws-surface-alt); color: var(--ws-muted); font-size: 11.5px; line-height: 1.55; }
.ws-sidebar-note .ws-icon { width: 18px; height: 18px; color: var(--ws-accent-2); }
.ws-nav-link.ws-logout { color: var(--ws-danger); font-size: 12.5px; }
.ws-nav-link.ws-logout .ws-icon { color: var(--ws-danger); }
.ws-nav-link.ws-logout:hover { color: var(--ws-danger); background: var(--ws-danger-soft); }
.ws-sidebar-credit { display: flex; align-items: center; justify-content: center; gap: 7px; margin-top: 12px; color: var(--ws-subtle); font-size: 9px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; }
.ws-sidebar-credit img { width: 14px; height: 14px; object-fit: contain; }
.ws-sidebar-close, .ws-menu-toggle, .ws-sidebar-backdrop { display: none; }

/* -------------------------------------------------------------- header -- */
.ws-header { position: sticky; top: 0; z-index: 1010; display: flex; align-items: center; justify-content: space-between; gap: 16px; height: var(--ws-header-height); margin-left: var(--ws-sidebar-width); padding: 0 32px; background: var(--ws-glass); -webkit-backdrop-filter: blur(18px) saturate(1.2); backdrop-filter: blur(18px) saturate(1.2); border-bottom: 1px solid var(--ws-line); box-shadow: 0 10px 30px -26px rgba(18, 60, 110, .5); }
.ws-header-location, .ws-header-actions { display: flex; align-items: center; gap: 14px; min-width: 0; }
.ws-header-actions { flex-shrink: 0; gap: 12px; }
.ws-location-icon { display: grid; place-items: center; width: 38px; height: 38px; flex-shrink: 0; border: 1px solid var(--ws-line); border-radius: 12px; color: var(--ws-accent); background: var(--ws-accent-soft); }
.ws-location-icon .ws-icon { width: 19px; height: 19px; }
.ws-location-copy { display: flex; flex-direction: column; min-width: 0; }
.ws-location-copy small { color: var(--ws-muted); font-size: 9.5px; font-weight: 800; letter-spacing: .13em; text-transform: uppercase; }
.ws-location-copy strong { max-width: 280px; overflow: hidden; color: var(--ws-text); font-size: 14px; font-weight: 700; white-space: nowrap; text-overflow: ellipsis; }
.ws-role-badge { padding: 6px 11px; border: 1px solid rgba(23, 75, 224, .14); border-radius: 999px; color: var(--ws-accent); background: var(--ws-accent-soft); font-size: 11px; font-weight: 700; }
.ws-header-divider { width: 1px; height: 28px; margin: 0 2px; background: var(--ws-line); }
.ws-theme-toggle .ws-sun, [data-workspace-theme="dark"] .ws-theme-toggle .ws-moon { display: none; }
[data-workspace-theme="dark"] .ws-theme-toggle .ws-sun { display: block; }
.ws-account { position: relative; }
.ws-account summary { display: flex; align-items: center; gap: 10px; padding: 4px 8px 4px 4px; list-style: none; border: 1px solid transparent; border-radius: 14px; cursor: pointer; transition: border-color .18s, background .18s; }
.ws-account summary:hover, .ws-account[open] summary { border-color: var(--ws-line); background: var(--ws-surface); }
.ws-account summary::-webkit-details-marker { display: none; }
.ws-account summary > .ws-icon { width: 14px; height: 14px; color: var(--ws-muted); }
.ws-avatar { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 11px; color: #fff; background: var(--ws-gradient); box-shadow: var(--ws-shadow-accent); font-size: 14px; font-weight: 800; }
.ws-account-name { display: flex; flex-direction: column; max-width: 150px; }
.ws-account-name strong { overflow: hidden; color: var(--ws-text); font-size: 12.5px; font-weight: 700; white-space: nowrap; text-overflow: ellipsis; }
.ws-account-name small { color: var(--ws-muted); font-size: 11px; }
.ws-account-dropdown { position: absolute; top: calc(100% + 14px); right: 0; width: 272px; max-width: calc(100vw - 32px); padding: 8px; border: 1px solid var(--ws-line); border-radius: 18px; background: var(--ws-surface); box-shadow: var(--ws-shadow-lg); }
.ws-account-info { display: flex; flex-direction: column; gap: 3px; margin-bottom: 6px; padding: 13px; overflow-wrap: anywhere; border-bottom: 1px solid var(--ws-line); }
.ws-account-info strong { color: var(--ws-text); font-size: 14px; font-weight: 700; }
.ws-account-info span { color: var(--ws-muted); font-size: 12px; }
.ws-account-info small { color: var(--ws-accent); font-size: 11px; font-weight: 700; }
.ws-account-dropdown > a, .ws-account-dropdown > button { display: flex; align-items: center; gap: 12px; width: 100%; padding: 11px 12px; border: 0; border-radius: 11px; color: var(--ws-text); background: transparent; font-size: 13px; font-weight: 600; text-align: left; }
.ws-account-dropdown > a:hover, .ws-account-dropdown > button:hover { color: var(--ws-accent); background: var(--ws-accent-soft); }
.ws-account-dropdown > a[href*="logout"]:hover { color: var(--ws-danger); background: var(--ws-danger-soft); }
.ws-account-dropdown .ws-icon { width: 17px; height: 17px; }

/* ---------------------------------------------- frame, intro and footer -- */
.ws-frame { display: flex; flex-direction: column; min-width: 0; min-height: calc(100vh - var(--ws-header-height)); margin-left: var(--ws-sidebar-width); }
.ws-main { flex: 1; width: 100%; max-width: 1680px; min-width: 0; margin: 0 auto; padding: 30px 32px 36px; }
.ws-page-intro { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin: 0 0 26px; }
.ws-page-intro > div:first-child { min-width: 0; }
.ws-eyebrow { display: inline-flex; align-items: center; gap: 8px; max-width: 100%; margin: 0 0 12px !important; padding: 6px 12px; border: 1px solid rgba(23, 75, 224, .12); border-radius: 999px; color: var(--ws-accent); background: var(--ws-accent-soft); font-size: 10px; font-weight: 800; letter-spacing: .14em; line-height: 1.3; text-transform: uppercase; }
.ws-eyebrow > span { width: 6px; height: 6px; flex-shrink: 0; border-radius: 50%; background: var(--ws-accent-2); box-shadow: 0 0 0 3px rgba(0, 174, 202, .2); }
.ws-page-intro h1 { margin: 0 0 8px; color: var(--ws-text); font-size: clamp(26px, 2.4vw, 34px); font-weight: 800; letter-spacing: -.035em; line-height: 1.15; overflow-wrap: anywhere; }
.ws-page-intro > div > p:last-child { margin: 0; color: var(--ws-muted); font-size: 13.5px; }
.ws-page-side { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 10px; flex-shrink: 0; }
.ws-date { display: flex; flex-direction: column; align-items: flex-end; padding: 9px 15px; border: 1px solid var(--ws-line); border-radius: 14px; background: var(--ws-surface); box-shadow: var(--ws-shadow-sm); }
.ws-date span { color: var(--ws-muted); font-size: 11px; font-weight: 600; }
.ws-date strong { color: var(--ws-text); font-size: 13px; font-weight: 700; }
.ws-footer { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; margin-top: auto; padding: 18px 32px; border-top: 1px solid var(--ws-line); color: var(--ws-muted); font-size: 11.5px; }
.ws-footer a { color: inherit; }
.ws-footer > span { display: inline-flex; align-items: center; gap: 7px; }
.ws-footer .ws-icon { width: 14px; height: 14px; color: var(--ws-accent-2); }
.ws-footer img { width: 16px; height: 16px; object-fit: contain; }

/* ------------------------------------------------ platform components -- */
.ws-saas-content { min-width: 0; color: var(--ws-body); }
.ws-saas-content h2, .ws-saas-content h3 { color: var(--ws-text); }
.ws-saas-content a:not(.ws-btn):not(.button) { color: var(--ws-accent); font-weight: 600; }
.ws-saas-content .muted { color: var(--ws-muted); }
.ws-grid { display: grid; gap: 18px; grid-template-columns: repeat(auto-fit, minmax(min(240px, 100%), 1fr)); }
.ws-grid + .ws-panel, .ws-panel + .ws-panel, .ws-panel + .ws-grid, .ws-grid + .ws-grid { margin-top: 20px; }
.ws-panel { position: relative; min-width: 0; border: 1px solid var(--ws-line); border-radius: var(--ws-radius-lg); background: var(--ws-surface); box-shadow: var(--ws-shadow); overflow-wrap: anywhere; }
.ws-panel-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 18px; padding: 20px 22px; border-bottom: 1px solid var(--ws-line); }
.ws-panel-head h2 { margin: 0; color: var(--ws-text); font-size: 16px; font-weight: 800; letter-spacing: -.01em; }
.ws-panel-head p { margin: 3px 0 0; color: var(--ws-muted); font-size: 12.5px; }
.ws-panel-body { padding: 22px; }
.ws-panel-body > :first-child { margin-top: 0; }
.ws-panel-body > :last-child { margin-bottom: 0; }
.ws-panel.is-flush .ws-table th:first-child, .ws-panel.is-flush .ws-table td:first-child { padding-left: 22px; }
.ws-panel.is-flush .ws-table th:last-child, .ws-panel.is-flush .ws-table td:last-child { padding-right: 22px; }
.ws-stat { position: relative; overflow: hidden; padding: 20px 20px 18px; border: 1px solid var(--ws-line); border-radius: var(--ws-radius-lg); background: linear-gradient(168deg, var(--ws-surface) 0%, var(--ws-surface-alt) 100%); box-shadow: var(--ws-shadow); }
.ws-stat::before { content: ''; position: absolute; top: 0; left: 12%; right: 12%; height: 2px; background: var(--ws-seam); opacity: .65; }
.ws-stat-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.ws-stat-label { color: var(--ws-muted); font-size: 10.5px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.ws-stat-icon { display: grid; place-items: center; width: 42px; height: 42px; flex-shrink: 0; border-radius: 13px; color: #fff; background: var(--ws-gradient); box-shadow: var(--ws-shadow-accent); }
.ws-stat-icon .ws-icon { width: 20px; height: 20px; }
.ws-stat-value { margin: 14px 0 4px; color: var(--ws-text); font-size: clamp(26px, 2.6vw, 34px); font-weight: 800; letter-spacing: -.04em; line-height: 1.1; font-variant-numeric: tabular-nums; }
.ws-stat-meta { margin: 0; color: var(--ws-muted); font-size: 12px; }
.ws-stat-value small { color: var(--ws-muted); font-size: .5em; font-weight: 700; letter-spacing: 0; }
.ws-stat-value.is-compact { font-size: 22px; letter-spacing: -.02em; }
.ws-stat-value .ws-badge { font-size: 14px; padding: 6px 13px; }
.ws-stat-link { display: inline-flex; align-items: center; gap: 6px; margin-top: 10px; font-size: 12px; }
.ws-stat-link .ws-icon { width: 14px; height: 14px; }
.ws-cta { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 18px; margin-top: 20px; padding: 24px 26px; overflow: hidden; border-radius: var(--ws-radius-lg); color: #fff; background: radial-gradient(420px 220px at 100% 0%, rgba(255, 255, 255, .18), transparent 70%), var(--ws-gradient-soft); box-shadow: var(--ws-shadow-accent); }
.ws-cta h2 { margin: 0 0 4px; color: #fff; font-size: 18px; font-weight: 800; letter-spacing: -.02em; }
.ws-cta p { max-width: 560px; margin: 0; color: rgba(255, 255, 255, .82); font-size: 13px; }
.ws-cta .ws-btn { color: var(--ws-text) !important; background: #fff; box-shadow: 0 12px 24px -14px rgba(6, 28, 80, .7); }

.ws-btn, .ws-saas-content .button, .ws-saas-content button:not(.ws-btn-reset) { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 42px; padding: 10px 17px; border: 0; border-radius: 12px; color: #fff !important; background: var(--ws-gradient); box-shadow: 0 14px 26px -16px rgba(23, 75, 224, .7), inset 0 1px 0 rgba(255, 255, 255, .28), inset 0 -2px 0 rgba(6, 28, 80, .18); cursor: pointer; font-size: 13px; font-weight: 700; line-height: 1.2; white-space: nowrap; transition: transform .18s, box-shadow .18s, filter .18s; }
.ws-btn:hover, .ws-saas-content .button:hover, .ws-saas-content button:not(.ws-btn-reset):hover { filter: brightness(1.05); transform: translateY(-1px); }
.ws-btn:active, .ws-saas-content button:not(.ws-btn-reset):active { transform: translateY(1px); }
.ws-btn:disabled, .ws-saas-content button:disabled { opacity: .6; cursor: wait; transform: none; }
.ws-btn .ws-icon { width: 16px; height: 16px; }
.ws-btn.is-ghost { color: var(--ws-text) !important; background: linear-gradient(180deg, var(--ws-surface), var(--ws-surface-alt)); border: 1px solid var(--ws-line); box-shadow: var(--ws-shadow-sm); }
.ws-btn.is-ghost:hover { color: var(--ws-accent) !important; border-color: var(--ws-line-strong); }
.ws-btn.is-sm { min-height: 34px; padding: 7px 12px; border-radius: 10px; font-size: 12px; }

.ws-table-scroll { width: 100%; overflow-x: auto; }
.ws-table, .ws-saas-content table { width: 100%; border-collapse: collapse; font-size: 13px; }
.ws-table th, .ws-saas-content th { padding: 12px 14px; border-bottom: 1px solid var(--ws-line); background: var(--ws-surface-alt); color: var(--ws-muted); font-size: 10.5px; font-weight: 800; letter-spacing: .1em; text-align: left; text-transform: uppercase; white-space: nowrap; }
.ws-table td, .ws-saas-content td { padding: 14px; border-bottom: 1px solid var(--ws-line); color: var(--ws-body); text-align: left; vertical-align: middle; }
.ws-table tbody tr:last-child td, .ws-saas-content tbody tr:last-child td { border-bottom: 0; }
.ws-table tbody tr, .ws-saas-content tbody tr { transition: background .15s; }
.ws-table tbody tr:hover, .ws-saas-content tbody tr:hover { background: var(--ws-surface-alt); }
.ws-table strong, .ws-saas-content td strong { color: var(--ws-text); font-weight: 700; }
.ws-cell-sub { display: block; margin-top: 2px; color: var(--ws-muted); font-size: 12px; }
.ws-num { font-variant-numeric: tabular-nums; white-space: nowrap; }
.ws-empty { padding: 36px 16px !important; color: var(--ws-muted) !important; text-align: center !important; }
.ws-empty .ws-icon { display: block; width: 28px; height: 28px; margin: 0 auto 8px; color: var(--ws-subtle); }
.ws-row-action { display: inline-flex; align-items: center; gap: 5px; font-size: 12.5px; font-weight: 700; white-space: nowrap; }
.ws-row-action .ws-icon { width: 14px; height: 14px; }
.ws-row-action + .ws-row-action { margin-left: 14px; }
.ws-actions-cell { text-align: right !important; white-space: nowrap; }
.ws-sr-only { position: absolute !important; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

.ws-badge { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border: 1px solid var(--ws-line); border-radius: 999px; color: var(--ws-muted); background: var(--ws-surface-alt); font-size: 11.5px; font-weight: 700; line-height: 1.4; white-space: nowrap; }
.ws-badge::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; opacity: .85; }
.ws-badge.is-success { color: var(--ws-success); background: var(--ws-success-soft); border-color: var(--ws-success-line); }
.ws-badge.is-danger { color: var(--ws-danger); background: var(--ws-danger-soft); border-color: var(--ws-danger-line); }
.ws-badge.is-warning { color: var(--ws-warning); background: var(--ws-warning-soft); border-color: var(--ws-warning-line); }
.ws-badge.is-info { color: var(--ws-accent); background: var(--ws-accent-soft); border-color: rgba(23, 75, 224, .16); }

.ws-alert { display: flex; align-items: flex-start; gap: 11px; margin: 0 0 20px; padding: 13px 15px; border: 1px solid var(--ws-success-line); border-radius: 16px; color: var(--ws-success); background: var(--ws-success-soft); box-shadow: var(--ws-shadow-sm); font-size: 13px; line-height: 1.55; }
.ws-alert .ws-icon { width: 18px; height: 18px; margin-top: 1px; }
.ws-alert ul { margin: 2px 0 0; padding-left: 18px; }
.ws-alert.is-danger { color: var(--ws-danger); background: var(--ws-danger-soft); border-color: var(--ws-danger-line); }
.ws-alert.is-info { color: var(--ws-accent); background: var(--ws-accent-soft); border-color: rgba(23, 75, 224, .16); }

.ws-form-section { min-width: 0; margin: 0; padding: 0; border: 0; }
.ws-form-section + .ws-form-section { margin-top: 26px; }
.ws-form-section > legend { display: flex; align-items: center; gap: 8px; width: 100%; margin: 0 0 14px; padding: 0; color: var(--ws-accent); font-size: 10.5px; font-weight: 800; letter-spacing: .13em; text-transform: uppercase; }
.ws-form-section > legend::after { content: ''; flex: 1; height: 1px; background: linear-gradient(90deg, var(--ws-line), transparent); }
.ws-form-grid { display: grid; gap: 16px 18px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.ws-form-grid > .is-full { grid-column: 1 / -1; }
.ws-form-field { display: grid; gap: 7px; min-width: 0; align-content: start; }
.ws-form-field > label, .ws-saas-content .ws-form-field > label { margin: 0; color: var(--ws-text); font-size: 12.5px; font-weight: 700; }
.ws-form-hint { margin: 0; color: var(--ws-muted); font-size: 11.5px; line-height: 1.5; }
.ws-saas-content input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]), .ws-saas-content select, .ws-saas-content textarea, .ws-input { width: 100%; min-height: 44px; padding: 11px 14px; border: 1px solid var(--ws-line); border-radius: 12px; color: var(--ws-text); background: linear-gradient(180deg, var(--ws-surface), var(--ws-surface-alt)); box-shadow: inset 0 1px 2px rgba(23, 60, 110, .05); font: inherit; font-size: 13.5px; font-weight: 500; outline: 0; transition: border-color .18s, box-shadow .18s; }
.ws-saas-content textarea { min-height: 96px; resize: vertical; }
.ws-saas-content input:focus, .ws-saas-content select:focus, .ws-saas-content textarea:focus, .ws-input:focus { border-color: #6aa5f5; box-shadow: 0 0 0 4px var(--ws-accent-ring); }
.ws-saas-content input[readonly] { color: var(--ws-muted); background: var(--ws-surface-sunken); }
.ws-saas-content input::placeholder, .ws-saas-content textarea::placeholder { color: var(--ws-subtle); font-weight: 400; }
.ws-saas-content input[type="checkbox"] { width: 17px; height: 17px; accent-color: var(--ws-accent); vertical-align: middle; }
.ws-check { display: inline-flex !important; align-items: center; gap: 10px; margin: 0 !important; color: var(--ws-text); font-size: 13px; font-weight: 600; cursor: pointer; }
.ws-form-actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 10px; margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--ws-line); }
.ws-form-actions > .ws-check { margin-right: auto !important; }
.ws-kv { display: grid; gap: 0; margin: 0; }
.ws-kv > div { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 18px; padding: 12px 0; border-bottom: 1px dashed var(--ws-line); }
.ws-kv > div:last-child { border-bottom: 0; }
.ws-kv dt { color: var(--ws-muted); font-size: 12.5px; font-weight: 600; }
.ws-kv dd { margin: 0; color: var(--ws-text); font-size: 13.5px; font-weight: 700; text-align: right; }
.ws-offer { display: flex; flex-direction: column; gap: 12px; padding: 18px; border: 1px solid var(--ws-line); border-radius: 16px; background: linear-gradient(168deg, var(--ws-surface), var(--ws-surface-alt)); box-shadow: var(--ws-shadow-sm); transition: border-color .18s, transform .18s; }
.ws-offer:hover { border-color: var(--ws-line-strong); transform: translateY(-2px); }
.ws-offer-name { color: var(--ws-text); font-size: 14px; font-weight: 800; }
.ws-offer-cycle { color: var(--ws-muted); font-size: 10.5px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.ws-offer-price { color: var(--ws-text); font-size: 22px; font-weight: 800; letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.ws-offer .ws-btn { margin-top: auto; }
.ws-note { margin: 12px 0 0; color: var(--ws-muted); font-size: 12.5px; }
.ws-saas-content nav[aria-label] { margin-top: 18px; }
.ws-saas-content nav[aria-label] svg { width: 18px; height: 18px; }

/* -------------------------- tenant POS content (Metronic markup kept) -- */
.ws-shell .app-content { padding: 0; }
.ws-shell .app-container { padding-left: 0 !important; padding-right: 0 !important; }
.ws-shell .app-toolbar { display: none; }
.ws-shell .card, .ws-shell .elev-card, .ws-shell .chart-box { border: 1px solid var(--ws-line) !important; border-radius: var(--ws-radius-lg) !important; background: var(--ws-surface) !important; box-shadow: var(--ws-shadow) !important; color: var(--ws-body); }
.ws-shell .elev-card.alt { background: linear-gradient(168deg, var(--ws-surface) 0%, var(--ws-surface-alt) 100%) !important; }
.ws-shell .chart-box { min-width: 0; padding: 20px 20px 14px; }
.ws-shell .chart-box h6 { color: var(--ws-text); font-size: 13.5px; font-weight: 800; letter-spacing: -.005em; line-height: 1.5; }
.ws-shell .gradient-bar { height: 2px; margin: 10px 0 14px; border-radius: 2px; background: linear-gradient(90deg, #2f6ff0, #58c9e6 45%, transparent 90%); }
.ws-shell .card-header, .ws-shell #gfs3-bg-primary { border-bottom: 1px solid var(--ws-line) !important; border-radius: var(--ws-radius-lg) var(--ws-radius-lg) 0 0 !important; background: var(--ws-surface) !important; color: var(--ws-text); }
.ws-shell .card-header .card-title, .ws-shell .card-title { color: var(--ws-text) !important; font-weight: 800; }
.ws-shell #gfs3-bg-primary { padding: 8px 22px; }
.ws-shell .card-body { border-radius: 0 0 var(--ws-radius-lg) var(--ws-radius-lg); background: transparent !important; }
.ws-shell .card-body.bg-light-success, .ws-shell .bg-cwhite { background: var(--ws-surface) !important; }
.ws-shell .shadow { box-shadow: var(--ws-shadow) !important; }
.ws-shell .br20 { border-radius: var(--ws-radius-lg); }
.ws-shell .form-control, .ws-shell .form-select, .ws-shell .filter-input { min-height: 44px; border: 1px solid var(--ws-line) !important; border-radius: 12px !important; color: var(--ws-text) !important; background-color: var(--ws-surface) !important; box-shadow: inset 0 1px 2px rgba(23, 60, 110, .05) !important; font-family: var(--ws-font); font-size: 13px; font-weight: 500; transition: border-color .18s, box-shadow .18s; }
.ws-shell textarea.form-control { min-height: 92px; }
.ws-shell .form-control-sm { min-height: 36px; font-size: 12px; }
.ws-shell .form-control:focus, .ws-shell .form-select:focus, .ws-shell .filter-input:focus { border-color: #6aa5f5 !important; box-shadow: 0 0 0 4px var(--ws-accent-ring) !important; }
.ws-shell .form-control::placeholder { color: var(--ws-subtle); }
.ws-shell .form-control[readonly], .ws-shell .form-control:disabled, .ws-shell .form-select:disabled { color: var(--ws-muted) !important; background-color: var(--ws-surface-sunken) !important; }
.ws-shell .form-label { color: var(--ws-text); font-size: 12px; font-weight: 700; }
.ws-shell .form-check-input:checked { border-color: var(--ws-accent); background-color: var(--ws-accent); }
.ws-shell .form-check-input:focus { box-shadow: 0 0 0 4px var(--ws-accent-ring); }
.ws-shell .btn { border-radius: 12px; font-family: var(--ws-font); font-size: 12.5px; font-weight: 700; transition: transform .18s, box-shadow .18s, filter .18s, background .18s; }
.ws-shell .btn:not(.btn-icon):not(.btn-sm) { min-height: 40px; }
.ws-shell .btn:hover { transform: translateY(-1px); }
.ws-shell .btn:active { transform: translateY(1px); }
.ws-shell .btn-primary, .ws-shell .btn-success, .ws-shell #create_btn { border: 0 !important; color: #fff !important; background: var(--ws-gradient) !important; box-shadow: 0 14px 26px -16px rgba(23, 75, 224, .75), inset 0 1px 0 rgba(255, 255, 255, .26), inset 0 -2px 0 rgba(6, 28, 80, .18) !important; }
.ws-shell .btn-primary:hover, .ws-shell .btn-success:hover, .ws-shell #create_btn:hover { filter: brightness(1.05); }
.ws-shell .btn-primary i, .ws-shell .btn-success i, .ws-shell #create_btn i { color: #fff !important; }
.ws-shell .btn-outline-success, .ws-shell .btn-outline-primary, .ws-shell .btn-outline-secondary, .ws-shell .btn-light, .ws-shell .btn-warning { border: 1px solid var(--ws-line) !important; color: var(--ws-text) !important; background: linear-gradient(180deg, var(--ws-surface), var(--ws-surface-alt)) !important; box-shadow: var(--ws-shadow-sm) !important; }
.ws-shell .btn-outline-success:hover, .ws-shell .btn-outline-primary:hover, .ws-shell .btn-outline-secondary:hover, .ws-shell .btn-light:hover, .ws-shell .btn-warning:hover { color: var(--ws-accent) !important; border-color: var(--ws-line-strong) !important; }
.ws-shell .btn-outline-success i, .ws-shell .btn-outline-primary i, .ws-shell .btn-light i, .ws-shell .btn-warning i { color: inherit !important; }
.ws-shell .btn-danger { border: 1px solid var(--ws-danger-line) !important; color: var(--ws-danger) !important; background: var(--ws-danger-soft) !important; box-shadow: none !important; }
.ws-shell .btn-danger i { color: inherit !important; }
.ws-shell .btn-danger:hover { color: #fff !important; background: #d9435c !important; border-color: #d9435c !important; }
.ws-shell .btn-info { border: 1px solid rgba(23, 75, 224, .16) !important; color: var(--ws-accent) !important; background: var(--ws-accent-soft) !important; box-shadow: none !important; }
.ws-shell .btn-info i { color: inherit !important; }
.ws-shell .btn-info:hover { color: #fff !important; background: var(--ws-accent) !important; }
.ws-shell .badge-pill { display: inline-flex; align-items: center; gap: 4px; padding: 7px 13px; border: 1px solid rgba(23, 75, 224, .16); border-radius: 999px; color: var(--ws-accent) !important; background: var(--ws-accent-soft) !important; box-shadow: none; font-size: 11.5px; font-weight: 700; letter-spacing: 0; }
.ws-shell .badge-pill i { color: inherit !important; }
.ws-shell .badge-pill:hover { color: #fff !important; background: var(--ws-gradient) !important; border-color: transparent; }
.ws-shell .btn-apk { display: inline-flex; align-items: center; gap: 6px; border: 0; color: #fff !important; background: #10284a; box-shadow: 0 14px 26px -16px rgba(16, 40, 74, .8), inset 0 1px 0 rgba(255, 255, 255, .18); }
.ws-shell .btn-apk:hover { color: #fff !important; background: var(--ws-gradient); }
.ws-shell .btn-apk i { color: #7fe3f2 !important; }
.ws-shell .btn-apk:hover i { color: #fff !important; }
html[data-workspace-theme="dark"] .ws-shell .btn-apk { background: var(--ws-gradient); }
.ws-shell .table, .ws-shell .table-modern { border-color: var(--ws-line); color: var(--ws-body); background: var(--ws-surface); }
.ws-shell table tr, .ws-shell table tr:hover { box-shadow: none; transform: none; }
.ws-shell .table thead th, .ws-shell .table-modern thead th { padding-top: 13px; padding-bottom: 13px; border-color: var(--ws-line); color: var(--ws-muted) !important; background: var(--ws-surface-alt) !important; font-size: 10.5px; font-weight: 800; letter-spacing: .09em; text-transform: uppercase; }
.ws-shell .table td, .ws-shell .table-modern tbody td { border-color: var(--ws-line); color: var(--ws-body); background: var(--ws-surface); font-size: 13px; }
.ws-shell .table tbody tr:hover > td, .ws-shell .table-modern tbody tr:hover > td { background: var(--ws-surface-alt); }
.ws-shell .table-wrapper-scroll { border-color: var(--ws-line) !important; border-radius: var(--ws-radius) !important; background: var(--ws-surface) !important; box-shadow: none !important; }
.ws-shell .page-item .page-link { margin: 0 2px; border: 1px solid var(--ws-line); border-radius: 10px !important; color: var(--ws-body); background: var(--ws-surface); font-weight: 700; }
.ws-shell .page-item.active .page-link, .ws-shell .page-link.active { border-color: transparent; color: #fff; background: var(--ws-gradient); box-shadow: var(--ws-shadow-accent); }
.ws-shell .dataTables_wrapper .dataTables_info { color: var(--ws-muted); font-size: 12px; }
.ws-shell .dataTables_wrapper .paginate_button { border-radius: 10px !important; }
.ws-shell .dataTables_wrapper .paginate_button.current, .ws-shell .dataTables_wrapper .paginate_button.current:hover { border: 0 !important; color: #fff !important; background: var(--ws-gradient) !important; box-shadow: var(--ws-shadow-accent); }
.ws-shell .chart-grid { gap: 20px; }
.ws-shell .chart-grid > * { min-width: 0; }
.ws-shell .filter-container { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 15px; }
.ws-shell .filter-input { flex: 1; padding: 8px 12px; }
.ws-shell .no-wrap, .ws-shell #text-wrap { white-space: nowrap; }
.ws-shell .modal { overflow-y: auto; }
.ws-shell .modal-content { overflow: hidden; border: 1px solid var(--ws-line); border-radius: 22px; color: var(--ws-body); background: var(--ws-surface); box-shadow: var(--ws-shadow-lg); }
.ws-shell .modal-content::before { content: ''; position: absolute; top: 0; left: 12%; right: 12%; height: 2px; background: var(--ws-seam); opacity: .7; }
.ws-shell .modal-header, .ws-shell .modal-footer { border-color: var(--ws-line); }
.ws-shell .modal-title { color: var(--ws-text); font-weight: 800; }
.ws-shell .modal-backdrop.show { background: #0b1d3a; opacity: .45; }
.ws-shell .small-note { color: var(--ws-muted); }
.ws-shell .text-primary { color: var(--ws-accent) !important; }
.ws-shell .nav-tabs .nav-link.active, .ws-shell .nav-pills .nav-link.active { color: #fff !important; background: var(--ws-gradient) !important; border-color: transparent !important; }
.ws-shell .ws-filter-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 3px; padding: 0 0 15px; border-bottom: 1px solid var(--ws-line); }
.ws-filter-title { display: flex; align-items: center; gap: 9px; color: var(--ws-text); font-size: 13px; font-weight: 800; }
.ws-filter-title .ws-icon { width: 17px; height: 17px; color: var(--ws-accent); }
.ws-shell .ws-filter-download { display: inline-flex; align-items: center; gap: 7px; color: var(--ws-accent); font-size: 11.5px; font-weight: 700; }
.ws-filter-download .ws-icon { width: 15px; height: 15px; }
.ws-shell .swal2-popup { border-radius: 22px; font-family: var(--ws-font); }
.ws-shell .swal2-title { color: var(--ws-text); }
.ws-shell .swal2-styled.swal2-confirm { border-radius: 12px; background: var(--ws-gradient) !important; box-shadow: var(--ws-shadow-accent) !important; }
.ws-shell .swal2-styled.swal2-cancel { border-radius: 12px; }
[data-workspace-theme="dark"] .ws-shell .text-dark,
[data-workspace-theme="dark"] .ws-shell .text-black,
[data-workspace-theme="dark"] .ws-shell .gfs3-dark-mode-t,
[data-workspace-theme="dark"] .ws-shell .gfs3-dark-mode-tt { color: var(--ws-text) !important; }
[data-workspace-theme="dark"] .ws-shell .text-muted { color: var(--ws-muted) !important; }
[data-workspace-theme="dark"] .ws-shell .gfs3-dark-mode-1,
[data-workspace-theme="dark"] .ws-shell .gfs3-dark-mode-2,
[data-workspace-theme="dark"] .ws-shell .gfs3-dark-mode-3 { background-color: var(--ws-surface) !important; }
[data-workspace-theme="dark"] .ws-shell .apexcharts-text { fill: var(--ws-muted) !important; }
[data-workspace-theme="dark"] .ws-shell .apexcharts-legend-text { color: var(--ws-muted) !important; }
[data-workspace-theme="dark"] .ws-shell .apexcharts-tooltip { color: #10284a; }

/* ------------------------------------------------------- shell layout -- */
@media (min-width: 992px) and (max-width: 1250px) {
    :root { --ws-sidebar-width: 240px; }
    .ws-main { padding: 26px; }
    .ws-header { padding: 0 26px; }
    .ws-shell .chart-grid.wide-3 { grid-template-columns: 1fr; }
}
@media (max-width: 991px) {
    :root { --ws-header-height: 66px; }
    .ws-frame { margin-left: 0; }
    .ws-sidebar { width: 288px; max-width: calc(100vw - 40px); transform: translateX(-100%); transition: transform .24s ease; z-index: 1060; background: var(--ws-surface); }
    .ws-sidebar-open .ws-sidebar { transform: translateX(0); }
    .ws-sidebar-open { overflow: hidden; }
    .ws-sidebar-open .ws-sidebar-backdrop { display: block; position: fixed; inset: 0; z-index: 1050; background: rgba(11, 29, 58, .45); -webkit-backdrop-filter: blur(3px); backdrop-filter: blur(3px); }
    .ws-sidebar-close, .ws-menu-toggle { display: inline-flex; }
    .ws-sidebar-close { width: 34px; height: 34px; }
    .ws-sidebar-top { padding: 20px 16px 16px 18px; }
    .ws-header { margin-left: 0; padding: 0 22px; }
    .ws-main { padding: 24px 22px 30px; }
    .ws-footer { padding: 16px 22px; }
    .ws-location-icon { display: none; }
    .ws-page-intro { align-items: flex-start; margin-bottom: 22px; }
    .ws-shell .chart-grid { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
    .ws-header { gap: 10px; padding: 0 14px; }
    .ws-header-location, .ws-header-actions { gap: 8px; }
    .ws-account-name, .ws-role-badge, .ws-header-divider, .ws-date { display: none; }
    .ws-account summary { gap: 4px; padding: 3px; }
    .ws-location-copy strong { max-width: 150px; font-size: 13px; }
    .ws-location-copy small { font-size: 8.5px; }
    .ws-icon-button { width: 38px; height: 38px; }
    .ws-main { padding: 22px 14px 28px; }
    .ws-page-intro { flex-direction: column; align-items: stretch; gap: 14px; }
    .ws-page-intro h1 { font-size: 26px; }
    .ws-page-side { justify-content: flex-start; }
    .ws-footer { padding: 14px 16px; }
    .ws-footer span:last-child { display: none; }
    .ws-panel-head, .ws-panel-body { padding: 16px; }
    .ws-form-grid { grid-template-columns: 1fr; }
    .ws-form-actions .ws-btn { flex: 1 1 auto; }
    .ws-shell #gfs3-bg-primary { padding: 10px 16px; }
    .ws-shell .action-bar { width: 100%; margin-left: 0 !important; justify-content: flex-start !important; }
    .ws-cta { padding: 20px; }
}
@media (prefers-reduced-motion: reduce) {
    .ws-shell *, .ws-login * { animation: none !important; scroll-behavior: auto !important; transition: none !important; }
}
@media print {
    .ws-sidebar, .ws-header, .ws-sidebar-backdrop, .ws-footer { display: none !important; }
    .ws-frame { margin: 0; }
    .ws-main { padding: 0; }
    .ws-shell { background: #fff !important; color: #000; }
}

/* ------------------------------------------ login, signup, verification -- */
.ws-login {
    position: relative; min-height: 100vh; margin: 0; overflow-x: hidden; color: var(--ws-body);
    background:
        radial-gradient(circle at 10% 8%, var(--ws-bg-glow-1) 0, transparent 34%),
        radial-gradient(circle at 92% 88%, var(--ws-bg-glow-2) 0, transparent 38%),
        var(--ws-bg);
}
.ws-login::after { content: ''; position: fixed; z-index: 0; border: 1px solid var(--ws-line-strong); border-radius: 50%; pointer-events: none; }
.ws-login::after { width: 440px; height: 440px; right: -210px; bottom: -200px; box-shadow: 0 0 0 22px rgba(207, 220, 255, .3); }
html[data-workspace-theme="dark"] .ws-login::after { box-shadow: none; opacity: .5; }
/* Story column: a narrow, quiet inset panel — brand, one line of intent, nothing else. */
.ws-login-page { position: relative; z-index: 1; display: grid; grid-template-columns: minmax(340px, 34vw) minmax(0, 1fr); min-height: 100vh; }
.ws-login-visual { position: sticky; top: 16px; align-self: start; display: flex; height: calc(100vh - 32px); min-height: 420px; margin: 16px 0 16px 16px; overflow: hidden; border: 1px solid var(--ws-line); border-radius: var(--ws-radius-xl); color: var(--ws-body); background: radial-gradient(120% 70% at 0% 0%, #e2f1ff 0%, transparent 60%), radial-gradient(90% 60% at 100% 100%, #e3f7fb 0%, transparent 65%), linear-gradient(165deg, #f7fbff 0%, #eef5ff 100%); box-shadow: var(--ws-shadow-sm); }
.ws-login-visual::before, .ws-login-visual::after { content: ''; position: absolute; border: 1px solid rgba(23, 75, 224, .12); border-radius: 50%; pointer-events: none; }
.ws-login-visual::before { width: 420px; height: 420px; top: -150px; right: -170px; }
.ws-login-visual::after { width: 250px; height: 250px; top: -64px; right: -84px; border-color: rgba(0, 174, 202, .2); }
.ws-login-visual-media { position: absolute; z-index: 0; top: 88px; right: 28px; bottom: 128px; left: 28px; overflow: hidden; border: 1px solid rgba(23, 75, 224, .12); border-radius: 24px; background: rgba(255, 255, 255, .42); box-shadow: 0 22px 46px -28px rgba(23, 75, 224, .5); }
.ws-login-visual-media::after { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(255, 255, 255, .04), rgba(9, 32, 73, .12)); pointer-events: none; }
.ws-login-visual-media img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: center; }
.ws-login-visual-media + .ws-login-visual-inner { position: relative; }
html[data-workspace-theme="dark"] .ws-login-visual-media { border-color: rgba(122, 165, 255, .2); background: rgba(15, 29, 52, .5); }
.ws-login-visual-inner { position: relative; z-index: 1; display: flex; flex-direction: column; justify-content: space-between; gap: 40px; width: 100%; padding: 34px 36px 40px; }
.ws-login-visual-copy { max-width: 400px; }
.ws-login-visual-copy h1 { margin: 0 0 12px; color: var(--ws-text); font-size: clamp(30px, 2.6vw, 40px); font-weight: 800; letter-spacing: -.045em; line-height: 1.12; }
.ws-login-visual-copy h1 em { font-style: normal; background: var(--ws-gradient-soft); -webkit-background-clip: text; background-clip: text; color: transparent; }
.ws-login-lead { max-width: 340px; margin: 0; color: var(--ws-muted); font-size: 14.5px; line-height: 1.7; }
html[data-workspace-theme="dark"] .ws-login-visual { background: radial-gradient(120% 70% at 0% 0%, #13305c 0%, transparent 60%), radial-gradient(90% 60% at 100% 100%, #0e3346 0%, transparent 65%), linear-gradient(165deg, #0f1d34 0%, #0c182d 100%); }
html[data-workspace-theme="dark"] .ws-login-visual::before { border-color: rgba(122, 165, 255, .16); }
html[data-workspace-theme="dark"] .ws-login-visual::after { border-color: rgba(41, 212, 236, .18); }
.ws-login-panel { position: relative; display: flex; flex-direction: column; justify-content: center; padding: 96px clamp(24px, 5vw, 72px) 72px; }
.ws-login-panel-top { position: absolute; top: 28px; right: clamp(24px, 5vw, 72px); left: clamp(24px, 5vw, 72px); display: flex; align-items: center; justify-content: flex-end; }
.ws-login-mobile-brand { display: none; }
.ws-login-theme { display: grid; place-items: center; width: 40px; height: 40px; padding: 0; border: 1px solid var(--ws-line); border-radius: 12px; color: var(--ws-muted); background: var(--ws-surface); box-shadow: var(--ws-shadow-sm); cursor: pointer; transition: color .18s, transform .18s; }
.ws-login-theme:hover { color: var(--ws-accent); transform: translateY(-1px); }
.ws-login-theme .ws-icon { width: 17px; height: 17px; }
.ws-login-theme .ws-sun, [data-workspace-theme="dark"] .ws-login-theme .ws-moon { display: none; }
[data-workspace-theme="dark"] .ws-login-theme .ws-sun { display: block; }
.ws-login-card { position: relative; width: min(100%, 460px); margin: 0 auto; padding: 36px 36px 30px; overflow: hidden; border: 1px solid var(--ws-line); border-radius: var(--ws-radius-xl); background: radial-gradient(420px 220px at 100% 0%, var(--ws-bg-glow-1), transparent 70%), var(--ws-surface); box-shadow: var(--ws-shadow-lg); }
.ws-login-card::before { content: ''; position: absolute; top: 0; left: 12%; right: 12%; height: 2px; background: var(--ws-seam); opacity: .75; }
.ws-login-heading { margin-bottom: 26px; }
.ws-login-kicker { display: inline-block; color: var(--ws-accent); font-size: 11px; font-weight: 800; letter-spacing: .18em; text-transform: uppercase; }
.ws-login-heading h2 { margin: 12px 0 8px; color: var(--ws-text); font-size: clamp(26px, 2.4vw, 31px); font-weight: 800; letter-spacing: -.04em; line-height: 1.15; }
.ws-login-heading p { margin: 0; color: var(--ws-muted); font-size: 13.5px; line-height: 1.7; }
.ws-field { margin-bottom: 18px; }
.ws-field > label, .ws-field-label label { display: block; margin: 0 0 8px; color: var(--ws-text); font-size: 12.5px; font-weight: 700; }
.ws-field-label { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.ws-field-label > span { color: var(--ws-subtle); font-size: 10px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.ws-input-wrap { position: relative; display: flex; align-items: center; }
.ws-input-wrap > .ws-icon { position: absolute; left: 15px; width: 17px; height: 17px; color: var(--ws-subtle); pointer-events: none; transition: color .18s; }
.ws-input-wrap:focus-within > .ws-icon { color: var(--ws-accent); }
.ws-input-wrap input { width: 100%; min-height: 48px; padding: 12px 44px; border: 1px solid var(--ws-line); border-radius: 13px; outline: 0; color: var(--ws-text); background: linear-gradient(180deg, var(--ws-surface), var(--ws-surface-alt)); box-shadow: inset 0 1px 2px rgba(23, 60, 110, .05); font-size: 14px; font-weight: 500; transition: border-color .18s, box-shadow .18s; }
.ws-input-wrap input::placeholder { color: var(--ws-subtle); font-weight: 400; }
.ws-input-wrap input:focus { border-color: #6aa5f5; box-shadow: inset 0 1px 2px rgba(23, 60, 110, .04), 0 0 0 4px var(--ws-accent-ring), 0 8px 18px -14px #2f6ff0; }
.ws-password-toggle { position: absolute; right: 7px; display: grid; place-items: center; width: 36px; height: 36px; padding: 0; border: 0; border-radius: 10px; color: var(--ws-subtle); background: transparent; cursor: pointer; }
.ws-password-toggle:hover { color: var(--ws-accent); background: var(--ws-accent-soft); }
.ws-password-toggle .ws-icon { width: 17px; height: 17px; }
.ws-captcha-box { margin: 22px 0 12px; padding: 13px; border: 1px dashed var(--ws-line-strong); border-radius: 16px; background: var(--ws-surface-alt); }
.ws-captcha-heading { display: flex; align-items: center; gap: 10px; margin-bottom: 11px; }
.ws-captcha-check { display: grid; place-items: center; width: 30px; height: 30px; flex-shrink: 0; border-radius: 9px; color: var(--ws-accent); background: var(--ws-accent-soft); }
.ws-captcha-check .ws-icon { width: 16px; height: 16px; }
.ws-captcha-heading > span:last-child { display: flex; flex-direction: column; }
.ws-captcha-heading strong { color: var(--ws-text); font-size: 12px; font-weight: 700; }
.ws-captcha-heading small { margin-top: 1px; color: var(--ws-muted); font-size: 11px; }
.ws-captcha-box .ws-turnstile { min-height: 65px; }
.ws-login-error, .ws-login-feedback { margin: 0; padding: 11px 13px; border: 1px solid var(--ws-danger-line); border-radius: 12px; color: var(--ws-danger); background: var(--ws-danger-soft); font-size: 12.5px; line-height: 1.5; }
.ws-login-feedback.is-success { border-color: var(--ws-success-line); color: var(--ws-success); background: var(--ws-success-soft); }
.ws-login-submit { display: flex; align-items: center; justify-content: center; gap: 10px; width: 100%; min-height: 50px; margin-top: 18px; padding: 13px 18px; border: 0; border-radius: 14px; color: #fff; background: var(--ws-gradient); box-shadow: 0 18px 32px -18px rgba(23, 75, 224, .75), inset 0 1px 0 rgba(255, 255, 255, .32), inset 0 -2px 0 rgba(6, 28, 80, .2); cursor: pointer; font-size: 14px; font-weight: 800; letter-spacing: .01em; transition: transform .18s, box-shadow .18s, filter .18s; }
.ws-login-submit:hover { filter: brightness(1.05); transform: translateY(-2px); box-shadow: 0 22px 36px -18px rgba(23, 75, 224, .7), inset 0 1px 0 rgba(255, 255, 255, .34), inset 0 -2px 0 rgba(6, 28, 80, .2); }
.ws-login-submit:active { transform: translateY(1px); }
.ws-login-submit:disabled { opacity: .75; cursor: wait; transform: none; }
.ws-login-submit > .ws-icon { width: 18px; height: 18px; }
.ws-submit-loading { display: inline-flex; align-items: center; gap: 8px; }
.ws-spinner { display: inline-block; width: 14px; height: 14px; border: 2px solid rgba(255, 255, 255, .35); border-top-color: #fff; border-radius: 50%; animation: ws-spin .7s linear infinite; }
@keyframes ws-spin { to { transform: rotate(360deg); } }
.ws-login-help { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--ws-line); color: var(--ws-muted); font-size: 12.5px; }
.ws-login-help a { color: var(--ws-accent); font-weight: 800; }
.ws-login-help a:hover { text-decoration: underline; }
.ws-login-copyright { position: absolute; right: clamp(24px, 5vw, 72px); bottom: 26px; left: clamp(24px, 5vw, 72px); margin: 0; color: var(--ws-muted); font-size: 11px; text-align: center; }
.ws-login-copyright span { padding: 0 6px; color: var(--ws-accent-2); }
.ws-login-visual-preview { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 18px; margin-top: 12px; padding: 12px; border: 1px solid var(--ws-line); border-radius: 14px; background: var(--ws-surface-alt); }
.ws-login-visual-preview img { display: block; width: min(100%, 280px); height: 120px; object-fit: cover; border-radius: 10px; }
.ws-checkbox { display: inline-flex; align-items: center; gap: 7px; color: var(--ws-muted); font-size: 12px; font-weight: 600; }
.ws-checkbox input { accent-color: var(--ws-accent); }

/* Tenant signup: the same card, taller, with a sticky story column. */
.ws-register-panel { justify-content: flex-start; padding-top: 96px; padding-bottom: 72px; }
.ws-register-card { width: min(100%, 640px); }
.ws-register-summary { margin-bottom: 20px; }
.ws-register-group { min-width: 0; margin: 0 0 24px; padding: 0; border: 0; }
.ws-register-group > legend::after { content: ''; flex: 1; height: 1px; background: linear-gradient(90deg, var(--ws-line), transparent); }
.ws-register-group > legend { display: flex; align-items: center; gap: 8px; width: 100%; margin-bottom: 14px; padding: 0; color: var(--ws-accent); font-size: 10.5px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; }
.ws-register-row { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }
.ws-field-hint { margin: 7px 0 0; color: var(--ws-muted); font-size: 11.5px; line-height: 1.5; }
.ws-field .ws-login-error { margin: 8px 0 0; }
.ws-plan-card { position: relative; display: block; margin-bottom: 12px; border: 1px solid var(--ws-line); border-radius: 16px; background: linear-gradient(168deg, var(--ws-surface), var(--ws-surface-alt)); box-shadow: var(--ws-shadow-sm); cursor: pointer; transition: border-color .18s, box-shadow .18s, transform .18s; }
.ws-plan-card:hover { border-color: var(--ws-line-strong); transform: translateY(-1px); }
.ws-plan-card input { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; border: 0; opacity: 0; }
.ws-plan-card:has(input:checked) { border-color: var(--ws-accent); box-shadow: 0 0 0 4px var(--ws-accent-ring), var(--ws-shadow-sm); }
.ws-plan-card:has(input:focus-visible) { outline: 2px solid var(--ws-accent); outline-offset: 2px; }
.ws-plan-body { display: block; padding: 16px 18px; }
.ws-plan-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.ws-plan-head strong { color: var(--ws-text); font-size: 15px; font-weight: 800; }
.ws-plan-check { display: grid; place-items: center; width: 22px; height: 22px; flex-shrink: 0; border: 1px solid var(--ws-line-strong); border-radius: 50%; color: transparent; background: var(--ws-surface); }
.ws-plan-check .ws-icon { width: 13px; height: 13px; }
.ws-plan-card:has(input:checked) .ws-plan-check { border-color: transparent; color: #fff; background: var(--ws-gradient); box-shadow: var(--ws-shadow-accent); }
.ws-plan-desc { display: block; margin-top: 5px; color: var(--ws-muted); font-size: 12.5px; line-height: 1.6; }
.ws-plan-limits { display: flex; flex-wrap: wrap; gap: 8px 16px; margin-top: 11px; }
.ws-plan-limits > span { display: inline-flex; align-items: center; gap: 6px; color: var(--ws-body); font-size: 12px; font-weight: 600; }
.ws-plan-limits .ws-icon { width: 15px; height: 15px; color: var(--ws-accent); }
.ws-plan-prices { display: flex; flex-wrap: wrap; gap: 10px 22px; margin-top: 13px; padding-top: 12px; border-top: 1px dashed var(--ws-line); }
.ws-plan-price { display: flex; flex-direction: column; gap: 2px; min-width: 108px; }
.ws-plan-price small { color: var(--ws-muted); font-size: 10px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.ws-plan-price strong { color: var(--ws-text); font-size: 16px; font-weight: 800; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }

/* OTP verification: one oversized, unambiguous code field. */
.ws-otp-target { color: var(--ws-accent); word-break: break-all; }
.ws-otp-wrap .ws-otp-input { padding: 14px 18px; font-family: var(--ws-mono); font-size: 26px; font-weight: 500; letter-spacing: 13px; text-align: center; }
.ws-otp-wrap .ws-otp-input::placeholder { color: var(--ws-line-strong); letter-spacing: 13px; }
.ws-otp-expiry { margin: 0; color: var(--ws-muted); font-size: 12.5px; line-height: 1.6; }
.ws-otp-expiry strong { color: var(--ws-text); }
.ws-otp-resend { display: flex; align-items: center; justify-content: center; gap: 6px; margin-top: 16px; color: var(--ws-muted); font-size: 12.5px; }
.ws-otp-resend button { padding: 0; border: 0; color: var(--ws-accent); background: transparent; cursor: pointer; font-size: 12.5px; font-weight: 800; }
.ws-otp-resend button:hover { text-decoration: underline; }

@media (min-width: 951px) and (max-height: 820px) {
    .ws-login-panel { padding-top: 76px; padding-bottom: 58px; }
    .ws-login-panel-top { top: 20px; }
    .ws-login-card { padding-top: 28px; padding-bottom: 24px; }
    .ws-login-heading { margin-bottom: 20px; }
    .ws-login-copyright { bottom: 20px; }
}
@media (max-width: 950px) {
    .ws-login-page { grid-template-columns: 1fr; }
    .ws-login-visual { display: none; }
    .ws-login-panel { min-height: 100vh; padding: 92px 20px 70px; }
    .ws-login-mobile-brand { display: block; margin-right: auto; }
    .ws-login-panel-top { top: 22px; right: 20px; left: 20px; justify-content: space-between; }
    .ws-login-copyright { right: 20px; bottom: 22px; left: 20px; }
    .ws-register-panel { padding-top: 92px; }
}
@media (max-width: 520px) {
    .ws-login-panel { padding-right: 14px; padding-left: 14px; }
    .ws-login-panel-top { right: 14px; left: 14px; }
    .ws-login-card { width: 100%; padding: 26px 18px 22px; border-radius: 22px; }
    .ws-login-heading { margin-bottom: 22px; }
    .ws-login-heading h2 { font-size: 25px; }
    .ws-login-copyright { right: 14px; left: 14px; }
    .ws-register-row { grid-template-columns: 1fr; }
    .ws-captcha-box { padding: 0; border: 0; background: transparent; }
    .ws-otp-wrap .ws-otp-input { font-size: 21px; letter-spacing: 8px; }
    .ws-otp-wrap .ws-otp-input::placeholder { letter-spacing: 8px; }
}
@media (max-width: 380px) {
    .ws-login-panel { padding-right: 12px; padding-left: 12px; }
    .ws-login-card { padding: 22px 14px 20px; }
}

/* ----------------------------------------------- subscription invoice -- */
.ws-invoice { min-height: 100vh; padding: clamp(20px, 5vw, 52px) 16px; }
.ws-invoice-sheet { position: relative; width: min(100%, 780px); margin: 0 auto; padding: clamp(22px, 4vw, 44px); overflow: hidden; border: 1px solid var(--ws-line); border-radius: var(--ws-radius-lg); background: var(--ws-surface); box-shadow: var(--ws-shadow-lg); }
.ws-invoice-sheet::before { content: ''; position: absolute; top: 0; left: 12%; right: 12%; height: 2px; background: var(--ws-seam); opacity: .75; }
.ws-invoice-head { display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: space-between; gap: 18px; padding-bottom: 22px; border-bottom: 1px solid var(--ws-line); }
.ws-invoice-title { margin: 0; color: var(--ws-text); font-size: clamp(22px, 3vw, 29px); font-weight: 800; letter-spacing: -.035em; }
.ws-invoice-number { margin: 7px 0 0; color: var(--ws-muted); font-family: var(--ws-mono); font-size: 11px; letter-spacing: .08em; }
.ws-invoice-status { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 999px; color: #fff; background: var(--ws-gradient); box-shadow: var(--ws-shadow-accent); font-size: 11px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }
.ws-invoice-meta { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 18px; padding: 22px 0; border-bottom: 1px solid var(--ws-line); }
.ws-invoice-meta > div > small { display: block; margin-bottom: 5px; color: var(--ws-muted); font-size: 10px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.ws-invoice-meta > div > span { color: var(--ws-text); font-size: 13px; font-weight: 700; overflow-wrap: anywhere; }
.ws-invoice-table-wrap { overflow-x: auto; }
.ws-invoice-table { width: 100%; margin: 22px 0 0; border-collapse: collapse; font-size: 13px; }
.ws-invoice-table th { padding: 0 0 11px; border-bottom: 1px solid var(--ws-line); color: var(--ws-muted); font-size: 10px; font-weight: 800; letter-spacing: .12em; text-align: left; text-transform: uppercase; }
.ws-invoice-table td { padding: 14px 0; border-bottom: 1px solid var(--ws-line); color: var(--ws-text); vertical-align: top; }
.ws-invoice-table th:last-child, .ws-invoice-table td:last-child { text-align: right; }
.ws-invoice-total { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; margin-top: 20px; padding-top: 18px; border-top: 2px solid var(--ws-text); }
.ws-invoice-total > span { color: var(--ws-muted); font-size: 11px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; }
.ws-invoice-total > strong { color: var(--ws-text); font-size: clamp(20px, 3vw, 26px); font-weight: 800; letter-spacing: -.03em; }
.ws-invoice-note { margin: 22px 0 0; color: var(--ws-muted); font-size: 12px; line-height: 1.7; }
.ws-invoice-actions { display: flex; flex-wrap: wrap; gap: 10px; width: min(100%, 780px); margin: 18px auto 0; }
.ws-invoice-actions button, .ws-invoice-actions a { display: inline-flex; align-items: center; gap: 8px; padding: 10px 16px; border: 1px solid var(--ws-line); border-radius: 12px; color: var(--ws-text); background: var(--ws-surface); box-shadow: var(--ws-shadow-sm); cursor: pointer; font-size: 12.5px; font-weight: 700; text-decoration: none; }
.ws-invoice-actions button:hover, .ws-invoice-actions a:hover { color: var(--ws-accent); border-color: var(--ws-line-strong); }
.ws-invoice-actions .ws-icon { width: 15px; height: 15px; }
@media print {
    .ws-login { background: #fff; }
    .ws-login::before, .ws-login::after { display: none; }
    .ws-invoice { padding: 0; background: #fff; }
    .ws-invoice-sheet { width: 100%; border: 0; border-radius: 0; box-shadow: none; }
    .ws-invoice-sheet::before, .ws-invoice-actions { display: none; }
}

/* ------------------------------------------- subscription lifecycle UI -- */
/* Reminder / read-only banner above every tenant page. */
.ws-sub-notice { display: flex; align-items: center; gap: 14px; margin: 0 0 20px; padding: 14px 16px; border: 1px solid rgba(23, 75, 224, .16); border-radius: 18px; background: linear-gradient(135deg, rgba(23, 75, 224, .07), rgba(0, 174, 202, .07)), var(--ws-surface); box-shadow: var(--ws-shadow-sm); }
.ws-sub-notice.is-read-only { border-color: var(--ws-warning-line); background: linear-gradient(135deg, rgba(237, 161, 0, .1), rgba(235, 104, 52, .06)), var(--ws-surface); }
.ws-sub-notice-icon { display: grid; place-items: center; width: 40px; height: 40px; flex-shrink: 0; border-radius: 13px; color: #fff; background: var(--ws-gradient); box-shadow: var(--ws-shadow-accent); }
.ws-sub-notice.is-read-only .ws-sub-notice-icon { background: linear-gradient(135deg, #eda100, #eb6834); box-shadow: 0 12px 24px -14px rgba(235, 104, 52, .8); }
.ws-sub-notice-copy { flex: 1; min-width: 0; }
.ws-sub-notice-copy strong { display: block; color: var(--ws-text); font-size: 14px; font-weight: 800; }
.ws-sub-notice-copy p { margin: 2px 0 0; color: var(--ws-muted); font-size: 12.5px; line-height: 1.55; }
.ws-sub-notice-hint { color: var(--ws-muted); font-size: 12px; font-weight: 600; }
.ws-sub-notice .ws-btn { flex-shrink: 0; }

/* Locked workspace: a blurred skeleton under a lock card, no tenant data. */
.ws-locked { position: relative; min-height: 520px; }
.ws-locked-skeleton { display: grid; gap: 18px; filter: blur(5px) saturate(.9); opacity: .75; pointer-events: none; user-select: none; }
.ws-skel-card, .ws-skel-panel { display: grid; gap: 12px; padding: 20px; border: 1px solid var(--ws-line); border-radius: var(--ws-radius-lg); background: var(--ws-surface); box-shadow: var(--ws-shadow-sm); }
.ws-skel { display: block; height: 12px; border-radius: 999px; background: linear-gradient(90deg, var(--ws-surface-sunken) 0%, var(--ws-line) 50%, var(--ws-surface-sunken) 100%); background-size: 200% 100%; animation: ws-shimmer 1.6s linear infinite; }
.ws-skel.is-sm { width: 30%; }
.ws-skel.is-md { width: 55%; }
.ws-skel.is-lg { width: 80%; height: 22px; }
.ws-skel.is-dot { width: 28px; height: 28px; border-radius: 9px; }
.ws-skel-bars { display: flex; align-items: flex-end; gap: 14px; height: 180px; padding-top: 10px; }
.ws-skel-bars span { flex: 1; border-radius: 10px 10px 4px 4px; background: linear-gradient(180deg, rgba(23, 75, 224, .22), rgba(0, 174, 202, .12)); }
.ws-skel-row { display: grid; grid-template-columns: 28px 1fr 90px 90px; align-items: center; gap: 14px; padding: 6px 0; border-bottom: 1px dashed var(--ws-line); }
.ws-skel-row .ws-skel.is-sm { width: 100%; }
@keyframes ws-shimmer { to { background-position: -200% 0; } }
.ws-locked-card { position: absolute; top: 60px; left: 50%; z-index: 2; width: min(92%, 460px); padding: 30px 28px 26px; overflow: hidden; border: 1px solid var(--ws-line); border-radius: var(--ws-radius-xl); background: radial-gradient(360px 200px at 100% 0%, var(--ws-bg-glow-1), transparent 70%), var(--ws-surface); box-shadow: var(--ws-shadow-lg); text-align: center; transform: translateX(-50%); }
.ws-locked-card::before { content: ''; position: absolute; top: 0; left: 12%; right: 12%; height: 2px; background: var(--ws-seam); opacity: .75; }
.ws-locked-icon { display: grid; place-items: center; width: 60px; height: 60px; margin: 0 auto 14px; border-radius: 20px; color: #fff; background: linear-gradient(145deg, #10284a, #174be0); box-shadow: 0 18px 30px -16px rgba(16, 40, 74, .8), inset 0 1px 0 rgba(255, 255, 255, .25), inset 0 -3px 0 rgba(0, 0, 0, .2); }
.ws-locked-icon .ws-icon { width: 26px; height: 26px; }
.ws-locked-card h2 { margin: 0 0 8px; color: var(--ws-text); font-size: 22px; font-weight: 800; letter-spacing: -.03em; }
.ws-locked-card p { margin: 0; color: var(--ws-muted); font-size: 13.5px; line-height: 1.65; }
.ws-locked-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 20px; }

/* Signup trial note and OTP channel hint. */
.ws-trial-note { display: flex; align-items: center; gap: 13px; margin: 4px 0 6px; padding: 14px 16px; border: 1px solid rgba(23, 75, 224, .18); border-radius: 16px; background: linear-gradient(135deg, rgba(23, 75, 224, .07), rgba(0, 174, 202, .08)); }
.ws-trial-note-icon { display: grid; place-items: center; width: 38px; height: 38px; flex-shrink: 0; border-radius: 12px; color: #fff; background: var(--ws-gradient); box-shadow: var(--ws-shadow-accent); }
.ws-trial-note-icon .ws-icon { width: 18px; height: 18px; }
.ws-trial-note strong { display: block; color: var(--ws-text); font-size: 14px; font-weight: 800; }
.ws-trial-note small { display: block; margin-top: 2px; color: var(--ws-muted); font-size: 12px; line-height: 1.5; }
.ws-otp-channel-note { margin: 10px 0 0; color: var(--ws-muted); font-size: 12px; line-height: 1.55; text-align: center; }
.ws-otp-channel-note strong { color: var(--ws-text); }

/* Subscription page: status hero. */
.ws-sub-hero { position: relative; display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(250px, 1fr); gap: 26px; margin-bottom: 22px; padding: 26px 28px; overflow: hidden; border-radius: 26px; color: #fff; background: radial-gradient(420px 240px at 100% 0%, rgba(255, 255, 255, .18), transparent 70%), linear-gradient(135deg, #0f2f7a 0%, #174be0 52%, #0aa3c0 100%); box-shadow: 0 30px 60px -36px rgba(23, 75, 224, .9), inset 0 1px 0 rgba(255, 255, 255, .25); }
.ws-sub-hero.is-read-only { background: radial-gradient(420px 240px at 100% 0%, rgba(255, 255, 255, .18), transparent 70%), linear-gradient(135deg, #7a3d06 0%, #c2410c 55%, #eda100 100%); box-shadow: 0 30px 60px -36px rgba(194, 65, 12, .9), inset 0 1px 0 rgba(255, 255, 255, .25); }
.ws-sub-hero.is-locked { background: radial-gradient(420px 240px at 100% 0%, rgba(255, 255, 255, .12), transparent 70%), linear-gradient(135deg, #0b1526 0%, #10284a 60%, #33415c 100%); box-shadow: 0 30px 60px -36px rgba(11, 21, 38, .9), inset 0 1px 0 rgba(255, 255, 255, .15); }
.ws-sub-hero::after { content: ''; position: absolute; width: 320px; height: 320px; right: -120px; bottom: -170px; border: 1px solid rgba(255, 255, 255, .18); border-radius: 50%; box-shadow: 0 0 0 40px rgba(255, 255, 255, .04); pointer-events: none; }
.ws-sub-hero-main { position: relative; z-index: 1; min-width: 0; }
.ws-sub-hero-chip { display: inline-flex; align-items: center; gap: 7px; padding: 6px 12px; border: 1px solid rgba(255, 255, 255, .28); border-radius: 999px; background: rgba(255, 255, 255, .14); font-size: 11px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.ws-sub-hero-chip .ws-icon { width: 14px; height: 14px; }
.ws-sub-hero h2 { margin: 14px 0 2px; color: #fff; font-size: 20px; font-weight: 800; letter-spacing: -.02em; }
.ws-sub-hero-big { margin: 6px 0 2px; font-size: clamp(34px, 3.4vw, 46px); font-weight: 800; letter-spacing: -.05em; line-height: 1.05; }
.ws-sub-hero-big span { font-size: .42em; font-weight: 700; letter-spacing: 0; opacity: .85; }
.ws-sub-hero-meta { margin: 0 0 16px; color: rgba(255, 255, 255, .82); font-size: 13px; }
.ws-sub-hero .ws-sub-hero-cta { margin: 0 0 18px; color: var(--ws-text) !important; background: #fff; box-shadow: 0 14px 26px -16px rgba(6, 28, 80, .7); }
.ws-sub-progress { height: 8px; overflow: hidden; border-radius: 999px; background: rgba(255, 255, 255, .2); }
.ws-sub-progress span { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #fff, rgba(255, 255, 255, .7)); }
.ws-sub-hero-usage { position: relative; z-index: 1; display: grid; align-content: center; gap: 12px; }
.ws-usage { padding: 13px 15px; border: 1px solid rgba(255, 255, 255, .2); border-radius: 16px; background: rgba(255, 255, 255, .1); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.ws-usage-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; font-size: 12.5px; }
.ws-usage-top span { display: inline-flex; align-items: center; gap: 7px; color: rgba(255, 255, 255, .85); font-weight: 600; }
.ws-usage-top .ws-icon { width: 15px; height: 15px; }
.ws-usage-top strong { font-size: 15px; font-weight: 800; font-variant-numeric: tabular-nums; }
.ws-usage-bar { height: 6px; margin-top: 9px; overflow: hidden; border-radius: 999px; background: rgba(255, 255, 255, .18); }
.ws-usage-bar span { display: block; height: 100%; border-radius: inherit; background: #fff; }

/* Subscription page: plans. */
.ws-pricing { margin: 26px 0 24px; }
.ws-pricing-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 16px 24px; margin-bottom: 20px; }
.ws-pricing-head h2 { margin: 0 0 4px; color: var(--ws-text); font-size: 20px; font-weight: 800; letter-spacing: -.02em; }
.ws-pricing-head p { max-width: 620px; margin: 0; color: var(--ws-muted); font-size: 13px; line-height: 1.6; }
.ws-cycle-toggle { position: relative; display: inline-flex; padding: 4px; border: 1px solid var(--ws-line); border-radius: 999px; background: var(--ws-surface); box-shadow: var(--ws-shadow-sm), inset 0 1px 2px rgba(23, 60, 110, .06); }
.ws-cycle-toggle input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.ws-cycle-toggle label { margin: 0; padding: 8px 18px; border-radius: 999px; color: var(--ws-muted); cursor: pointer; font-size: 12.5px; font-weight: 800; transition: color .18s, background .18s, box-shadow .18s; }
.ws-cycle-toggle input:checked + label { color: #fff; background: var(--ws-gradient); box-shadow: var(--ws-shadow-accent); }
.ws-cycle-toggle input:focus-visible + label { outline: 2px solid var(--ws-accent); outline-offset: 2px; }
.ws-pricing.show-monthly .is-yearly, .ws-pricing.show-yearly .is-monthly { display: none !important; }
.ws-plans3d { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(260px, 100%), 1fr)); gap: 22px; perspective: 1400px; }
.ws-plan3d { position: relative; display: flex; flex-direction: column; gap: 16px; padding: 24px 22px 22px; overflow: hidden; border: 1px solid var(--ws-line); border-radius: 24px; background: linear-gradient(170deg, var(--ws-surface) 0%, var(--ws-surface-alt) 58%, var(--ws-surface-sunken) 100%); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .9), inset 0 -22px 34px -30px rgba(23, 75, 224, .4), 0 34px 60px -40px rgba(18, 60, 110, .6), 0 10px 22px -14px rgba(18, 60, 110, .25); transform-style: preserve-3d; transition: transform .28s cubic-bezier(.2, .8, .2, 1), box-shadow .28s; }
.ws-plan3d::before { content: ''; position: absolute; top: 0; left: 12%; right: 12%; height: 2px; background: var(--ws-seam); opacity: .8; }
.ws-plan3d:hover { transform: translateY(-8px) rotateX(3deg); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .9), inset 0 -22px 34px -30px rgba(23, 75, 224, .45), 0 46px 70px -40px rgba(18, 60, 110, .7), 0 14px 28px -16px rgba(23, 75, 224, .35); }
.ws-plan3d.is-current { border-color: rgba(23, 75, 224, .45); box-shadow: 0 0 0 4px var(--ws-accent-ring), inset 0 1px 0 rgba(255, 255, 255, .9), 0 34px 60px -40px rgba(18, 60, 110, .6); }
html[data-workspace-theme="dark"] .ws-plan3d { box-shadow: inset 0 1px 0 rgba(255, 255, 255, .06), 0 34px 60px -36px rgba(0, 0, 0, .8); }
.ws-plan3d-head { display: flex; align-items: center; gap: 13px; }
.ws-plan3d-head h3 { margin: 0; color: var(--ws-text); font-size: 17px; font-weight: 800; letter-spacing: -.02em; }
.ws-plan3d-icon { display: grid; place-items: center; width: 48px; height: 48px; flex-shrink: 0; border-radius: 15px; color: #fff; background: var(--ws-gradient); box-shadow: 0 14px 24px -12px rgba(23, 75, 224, .85), inset 0 1px 0 rgba(255, 255, 255, .35), inset 0 -3px 0 rgba(6, 28, 80, .25); transform: translateZ(30px); }
.ws-plan3d-icon .ws-icon { width: 22px; height: 22px; }
.ws-plan3d-chip { display: inline-flex; margin-top: 4px; padding: 3px 9px; border-radius: 999px; color: var(--ws-accent); background: var(--ws-accent-soft); font-size: 10.5px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.ws-plan3d-desc { margin: -4px 0 0; color: var(--ws-muted); font-size: 12.5px; line-height: 1.6; }
.ws-plan3d-price { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 6px; padding: 14px 0; border-top: 1px dashed var(--ws-line); border-bottom: 1px dashed var(--ws-line); }
.ws-plan3d-price strong { color: var(--ws-text); font-size: 28px; font-weight: 800; letter-spacing: -.04em; font-variant-numeric: tabular-nums; }
.ws-plan3d-price span { color: var(--ws-muted); font-size: 13px; font-weight: 600; }
.ws-plan3d-price em { margin-left: auto; padding: 3px 9px; border-radius: 999px; color: var(--ws-success); background: var(--ws-success-soft); font-size: 11px; font-style: normal; font-weight: 800; }
.ws-plan3d-na { color: var(--ws-subtle) !important; font-size: 12.5px !important; }
.ws-plan3d-features { display: grid; gap: 9px; margin: 0; padding: 0; list-style: none; }
.ws-plan3d-features li { display: flex; align-items: center; gap: 9px; color: var(--ws-body); font-size: 13px; font-weight: 600; }
.ws-plan3d-features .ws-icon { width: 16px; height: 16px; color: var(--ws-accent); }
.ws-plan3d-cta { margin-top: auto; }
.ws-plan3d-cta button { width: 100%; }

/* Fallback notice when a write is refused and no dialog library is loaded. */
.ws-toast { position: fixed; right: 20px; bottom: 20px; z-index: 11000; max-width: min(420px, calc(100vw - 40px)); padding: 14px 16px; border: 1px solid var(--ws-warning-line); border-radius: 16px; color: var(--ws-text); background: var(--ws-surface); box-shadow: var(--ws-shadow-lg); font-size: 13px; line-height: 1.55; }
.ws-toast a { display: inline-block; margin-top: 6px; color: var(--ws-accent); font-weight: 800; }

@media (max-width: 800px) {
    .ws-sub-hero { grid-template-columns: 1fr; padding: 22px 20px; }
}
@media (max-width: 640px) {
    .ws-sub-notice { flex-wrap: wrap; }
    .ws-sub-notice .ws-btn { width: 100%; }
    .ws-locked-card { top: 30px; padding: 24px 18px 20px; }
    .ws-skel-row { grid-template-columns: 28px 1fr 60px; }
    .ws-skel-row .ws-skel:last-child { display: none; }
}
@media (prefers-reduced-motion: reduce) {
    .ws-plan3d:hover { transform: none; }
}
