/* ============================================================
   HotSpot SaaS Platform — Custom CSS
   Primary: #4C061D | Secondary: #D17A22 | Accent: #B4C292
   ============================================================ */

:root {
    --hs-primary:        #4C061D;
    --hs-primary-hover:  #3a0416;
    --hs-primary-light:  #fdf0f3;
    --hs-secondary:      #D17A22;
    --hs-secondary-hover:#b86920;
    --hs-accent:         #B4C292;
    --hs-accent-hover:   #9dad7d;
    --hs-sidebar-bg:     linear-gradient(180deg, #4C061D 0%, #380314 100%);
    --hs-sidebar-width:  260px;
    --hs-topbar-height:  60px;
    --hs-font-body:      'Inter', sans-serif;
    --hs-font-heading:   'Plus Jakarta Sans', sans-serif;
    --hs-border:         #eef0f6;
    --hs-bg:             #f6f7fb;
    --hs-card-shadow:    0 1px 8px rgba(0,0,0,0.06), 0 4px 20px rgba(0,0,0,0.04);
    --hs-radius:         14px;
    --hs-radius-sm:      8px;
}

/* ── Base ── */
html, body { height: 100%; }
body.hs-body {
    font-family: var(--hs-font-body);
    background: var(--hs-bg);
    color: #1a1a2e;
    margin: 0;
    overflow-x: hidden;
}

/* ── Sidebar ── */
.hs-sidebar {
    position: fixed; top: 0; left: 0; bottom: 0;
    width: var(--hs-sidebar-width);
    background: var(--hs-sidebar-bg);
    display: flex; flex-direction: column;
    z-index: 1040;
    transition: transform 0.25s ease;
    overflow-y: auto;
}
.hs-sidebar-header { padding: 20px 20px 12px; border-bottom: 1px solid rgba(255,255,255,0.08); }
.hs-brand { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.hs-brand-icon { width: 38px; height: 38px; background: rgba(255,255,255,0.15); border-radius: 10px; display: flex; align-items: center; justify-content: center; color: white; font-size: 18px; flex-shrink: 0; }
.hs-brand-logo { height: 36px; object-fit: contain; border-radius: 8px; }
.hs-brand-name { color: white; font-family: var(--hs-font-heading); font-weight: 700; font-size: 15px; line-height: 1.2; }

/* Nav */
.hs-nav { flex: 1; padding: 12px 12px 0; }
.hs-nav-section { margin-bottom: 4px; }
.hs-nav-label { font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.8px; color: rgba(255,255,255,0.35); padding: 10px 10px 4px; }
.hs-nav-link {
    display: flex; align-items: center; gap: 10px;
    padding: 9px 12px; border-radius: 9px;
    color: rgba(255,255,255,0.7); font-size: 14px; font-weight: 500;
    text-decoration: none; transition: all 0.15s;
    margin-bottom: 1px;
}
.hs-nav-link i { font-size: 16px; width: 20px; text-align: center; flex-shrink: 0; }
.hs-nav-link:hover { background: rgba(255,255,255,0.1); color: white; }
.hs-nav-link.active { background: rgba(255,255,255,0.15); color: white; font-weight: 600; }
.hs-nav-link.active i { color: var(--hs-accent); }

/* Sidebar Footer */
.hs-sidebar-footer { padding: 12px; border-top: 1px solid rgba(255,255,255,0.08); }
.hs-user-card { display: flex; align-items: center; gap: 10px; padding: 8px; border-radius: 10px; background: rgba(255,255,255,0.07); }
.hs-user-avatar { width: 34px; height: 34px; border-radius: 9px; background: rgba(255,255,255,0.2); color: white; font-size: 13px; font-weight: 700; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.hs-user-avatar.sm { width: 28px; height: 28px; font-size: 11px; border-radius: 7px; }
.hs-user-info { flex: 1; overflow: hidden; }
.hs-user-name { color: white; font-size: 13px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hs-user-role { color: rgba(255,255,255,0.5); font-size: 11px; text-transform: capitalize; }

/* ── Main Content ── */
.hs-main {
    margin-left: var(--hs-sidebar-width);
    min-height: 100vh;
    display: flex; flex-direction: column;
    transition: margin 0.25s ease;
}
.hs-topbar {
    height: var(--hs-topbar-height);
    background: white;
    border-bottom: 1px solid var(--hs-border);
    display: flex; align-items: center;
    padding: 0 24px; gap: 12px;
    position: sticky; top: 0; z-index: 100;
}
.hs-sidebar-toggle { background: none; border: none; padding: 4px; color: #666; cursor: pointer; border-radius: 8px; line-height: 1; display: none; }
.hs-sidebar-toggle:hover { background: #f0f0f0; }
.hs-topbar-breadcrumb { flex: 1; font-size: 14px; color: #888; }
.hs-topbar-actions { display: flex; align-items: center; gap: 10px; }
.hs-content { padding: 28px 28px 40px; flex: 1; max-width: 1400px; width: 100%; }

/* ── Page Header ── */
.hs-page-header { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 28px; flex-wrap: wrap; gap: 12px; }
.hs-page-title { font-family: var(--hs-font-heading); font-size: 24px; font-weight: 800; margin: 0; color: var(--hs-primary); }
.hs-page-sub { font-size: 14px; color: #888; margin: 2px 0 0; }

/* ── Cards ── */
.hs-card { background: white; border-radius: var(--hs-radius); box-shadow: var(--hs-card-shadow); border: 1px solid var(--hs-border); overflow: hidden; }
.hs-card-header { display: flex; align-items: center; justify-content: space-between; padding: 16px 20px; border-bottom: 1px solid var(--hs-border); }
.hs-card-title { font-size: 15px; font-weight: 700; margin: 0; color: #1a1a2e; }
.hs-card-badge { font-size: 12px; font-weight: 600; color: var(--hs-secondary); background: #fff8f0; padding: 3px 10px; border-radius: 100px; border: 1px solid #ffe0b2; }
.hs-card-body { padding: 20px; }
.hs-card-footer { padding: 12px 20px; background: #fafafa; border-top: 1px solid var(--hs-border); }
.hs-info-card { border-left: 4px solid var(--hs-secondary); }

/* ── Stat Cards ── */
.hs-stat-card { background: white; border-radius: var(--hs-radius); padding: 20px; display: flex; align-items: center; gap: 16px; box-shadow: var(--hs-card-shadow); border: 1px solid var(--hs-border); }
.hs-stat-icon { width: 52px; height: 52px; border-radius: 14px; display: flex; align-items: center; justify-content: center; font-size: 22px; flex-shrink: 0; }
.hs-stat-value { font-family: var(--hs-font-heading); font-size: 26px; font-weight: 800; line-height: 1; }
.hs-stat-sub { font-size: 14px; font-weight: 400; color: #aaa; }
.hs-stat-label { font-size: 12px; color: #888; margin-top: 3px; font-weight: 500; }
.hs-stat-detail { font-size: 11px; margin-top: 2px; }
.hs-stat-primary .hs-stat-icon { background: var(--hs-primary-light); color: var(--hs-primary); }
.hs-stat-success .hs-stat-icon { background: #f0fdf4; color: #22c55e; }
.hs-stat-secondary .hs-stat-icon { background: #fff8f0; color: var(--hs-secondary); }
.hs-stat-accent .hs-stat-icon { background: #f3f7ee; color: #5a8a3a; }
.hs-stat-primary .hs-stat-value { color: var(--hs-primary); }
.hs-stat-success .hs-stat-value { color: #16a34a; }
.hs-stat-secondary .hs-stat-value { color: var(--hs-secondary); }
.hs-stat-accent .hs-stat-value { color: #5a8a3a; }

/* Mini stat */
.hs-stat-mini { background: white; border-radius: var(--hs-radius-sm); padding: 14px 16px; text-align: center; box-shadow: var(--hs-card-shadow); border: 1px solid var(--hs-border); }
.hs-stat-mini-value { display: block; font-family: var(--hs-font-heading); font-size: 22px; font-weight: 800; color: var(--hs-primary); }
.hs-stat-mini-label { font-size: 12px; color: #888; }
.hs-stat-mini-warning .hs-stat-mini-value { color: #d97706; }
.hs-stat-mini-success .hs-stat-mini-value { color: #16a34a; }
.hs-stat-mini-danger .hs-stat-mini-value { color: #dc2626; }

/* ── Table ── */
.hs-table { font-size: 14px; margin-bottom: 0; }
.hs-table thead th { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px; color: #888; background: #fafafa; border-bottom: 2px solid var(--hs-border); padding: 10px 16px; white-space: nowrap; }
.hs-table tbody td { padding: 12px 16px; vertical-align: middle; border-color: var(--hs-border); }
.hs-table tbody tr:hover { background: #fafcff; }

/* ── Buttons ── */
.hs-btn-primary { background: var(--hs-primary); color: white; border: none; border-radius: 8px; padding: 8px 18px; font-weight: 600; font-size: 14px; transition: background 0.15s; }
.hs-btn-primary:hover { background: var(--hs-primary-hover); color: white; }
.hs-btn-secondary { background: var(--hs-secondary); color: white; border: none; border-radius: 8px; padding: 8px 18px; font-weight: 600; font-size: 14px; transition: background 0.15s; }
.hs-btn-secondary:hover { background: var(--hs-secondary-hover); color: white; }
.hs-btn-outline-primary { color: var(--hs-primary); border: 1.5px solid var(--hs-primary); border-radius: 8px; padding: 6px 14px; font-weight: 600; font-size: 13px; background: transparent; transition: all 0.15s; }
.hs-btn-outline-primary:hover { background: var(--hs-primary); color: white; }
.btn-xs { padding: 3px 8px; font-size: 12px; border-radius: 6px; }
.btn-danger-subtle { background: #fff1f1 !important; border-color: #fecaca !important; }

/* ── Misc UI ── */
.hs-code { background: #f5f5f5; color: var(--hs-primary); padding: 2px 8px; border-radius: 6px; font-size: 13px; font-weight: 600; font-family: 'Courier New', monospace; }
.hs-link { color: var(--hs-primary); text-decoration: none; font-weight: 500; }
.hs-link:hover { color: var(--hs-primary-hover); text-decoration: underline; }
.hs-badge-soft { background: var(--hs-primary-light); color: var(--hs-primary); border: 1px solid #f5c6d0; font-weight: 600; }
.hs-router-row { display: flex; align-items: center; gap: 12px; padding: 12px 20px; border-bottom: 1px solid var(--hs-border); }
.hs-router-row:last-child { border-bottom: none; }
.hs-router-status-dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }
.hs-router-info { flex: 1; min-width: 0; }
.hs-router-icon { width: 44px; height: 44px; border-radius: 12px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.hs-router-meta { font-size: 13px; color: #666; display: flex; flex-direction: column; gap: 3px; margin-top: 8px; }
.hs-router-meta div { display: flex; align-items: center; gap: 4px; }
.hs-price-tag { font-family: var(--hs-font-heading); font-size: 20px; font-weight: 800; color: var(--hs-primary); }
.hs-price-tag span { font-size: 12px; font-weight: 500; color: #aaa; }
.hs-package-features { display: flex; flex-direction: column; gap: 5px; }
.hs-feature { font-size: 13px; color: #555; display: flex; align-items: center; gap: 6px; }
.hs-detail-list { margin: 0; }
.hs-detail-list dt { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.4px; color: #aaa; margin-top: 12px; margin-bottom: 2px; }
.hs-detail-list dd { margin: 0; font-size: 14px; color: #1a1a2e; font-weight: 500; }
.hs-detail-list dt:first-child { margin-top: 0; }
.hs-logo-preview { height: 50px; object-fit: contain; border-radius: 8px; border: 1px solid var(--hs-border); padding: 4px; background: #fafafa; }

/* Empty state */
.hs-empty-state { text-align: center; padding: 60px 20px; color: #aaa; }
.hs-empty-state i { font-size: 52px; display: block; margin-bottom: 12px; opacity: 0.3; }
.hs-empty-state h5 { color: #555; font-weight: 700; margin-bottom: 6px; }
.hs-empty-state p { font-size: 14px; margin-bottom: 20px; }
.opacity-60 { opacity: 0.6; }

/* ── Auth Pages ── */
body.hs-auth-body { background: linear-gradient(135deg, var(--hs-primary-light) 0%, #fff 100%); min-height: 100vh; font-family: var(--hs-font-body); }
.hs-auth-wrapper { display: flex; min-height: 100vh; }
.hs-auth-left { flex: 1; background: var(--hs-sidebar-bg); display: flex; align-items: center; justify-content: center; padding: 40px; }
.hs-auth-left-inner { max-width: 400px; color: white; }
.hs-auth-logo { display: flex; align-items: center; gap: 12px; margin-bottom: 40px; }
.hs-auth-logo-icon { width: 48px; height: 48px; background: rgba(255,255,255,0.15); border-radius: 14px; display: flex; align-items: center; justify-content: center; font-size: 22px; color: white; }
.hs-auth-logo-icon.sm { width: 36px; height: 36px; font-size: 16px; border-radius: 10px; }
.hs-auth-logo-text { font-family: var(--hs-font-heading); font-size: 20px; font-weight: 800; color: white; }
.hs-auth-headline { font-family: var(--hs-font-heading); font-size: 32px; font-weight: 800; line-height: 1.2; margin-bottom: 16px; }
.hs-auth-subline { color: rgba(255,255,255,0.7); font-size: 15px; line-height: 1.6; margin-bottom: 32px; }
.hs-auth-features { display: flex; flex-direction: column; gap: 10px; }
.hs-auth-feature { display: flex; align-items: center; gap: 10px; color: rgba(255,255,255,0.8); font-size: 14px; }
.hs-auth-feature i { color: var(--hs-accent); font-size: 16px; }
.hs-auth-right { width: 480px; display: flex; align-items: center; justify-content: center; padding: 40px; }
.hs-auth-card { width: 100%; max-width: 400px; }
.hs-auth-title { font-family: var(--hs-font-heading); font-size: 26px; font-weight: 800; color: var(--hs-primary); margin-bottom: 4px; }
.hs-auth-subtitle { color: #888; font-size: 14px; margin-bottom: 28px; }

/* ── Pagination ── */
.pagination .page-link { color: var(--hs-primary); border-color: var(--hs-border); font-size: 13px; }
.pagination .page-item.active .page-link { background: var(--hs-primary); border-color: var(--hs-primary); }

/* ── Portal URL box ── */
.hs-portal-url {}
.hs-portal-url .form-control { font-size: 11px; }

/* ── Responsive ── */
@media (max-width: 991.98px) {
    .hs-sidebar { transform: translateX(-100%); }
    .hs-sidebar.open { transform: translateX(0); }
    .hs-main { margin-left: 0; }
    .hs-sidebar-toggle { display: block; }
    .hs-content { padding: 20px 16px 40px; }
    .hs-auth-right { width: 100%; padding: 24px 16px; }
    .hs-auth-card { max-width: 100%; }
    .hs-stat-value { font-size: 20px; }
}
