:root {
    --primary: #6C5CE7;
    --primary-dark: #5A4BD1;
    --secondary: #00CEC9;
    --success: #00B894;
    --warning: #FDCB6E;
    --danger: #E17055;
    --dark: #2D3436;
    --light: #F8F9FA;
    --sidebar-width: 260px;
    --whatsapp-green: #25D366;
    --shopee-orange: #EE4D2D;
}

* { box-sizing: border-box; }

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: #F0F2F5;
    color: var(--dark);
}

/* AUTH PAGES */
.auth-wrapper {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    padding: 20px;
}

.auth-card {
    background: #fff;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.15);
    width: 100%;
    max-width: 440px;
    padding: 48px 40px;
}

.auth-card .logo {
    text-align: center;
    margin-bottom: 32px;
}

.auth-card .logo h1 {
    font-size: 28px;
    font-weight: 800;
    color: var(--primary);
    margin: 0;
}

.auth-card .logo span {
    color: var(--shopee-orange);
}

.auth-card .form-control {
    border-radius: 12px;
    padding: 12px 16px;
    border: 2px solid #E9ECEF;
    transition: border-color 0.2s;
}

.auth-card .form-control:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(108, 92, 231, 0.1);
}

.btn-primary-custom {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    border: none;
    border-radius: 12px;
    padding: 12px 24px;
    font-weight: 600;
    color: #fff;
    width: 100%;
    font-size: 16px;
    transition: all 0.3s;
}

.btn-primary-custom:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(108, 92, 231, 0.3);
    color: #fff;
}

/* SIDEBAR */
.sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: var(--sidebar-width);
    height: 100vh;
    background: linear-gradient(180deg, var(--dark) 0%, #1a1a2e 100%);
    color: #fff;
    z-index: 1000;
    overflow-y: auto;
    transition: transform 0.3s;
}

.sidebar-brand {
    padding: 24px 20px;
    border-bottom: 1px solid rgba(255,255,255,0.08);
}

.sidebar-brand h4 {
    font-weight: 800;
    margin: 0;
    font-size: 20px;
}

.sidebar-brand h4 span { color: var(--shopee-orange); }

.sidebar-nav { padding: 16px 0; }

.sidebar-nav .nav-section {
    padding: 8px 20px;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: rgba(255,255,255,0.35);
    margin-top: 8px;
}

.sidebar-nav .nav-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 11px 20px;
    color: rgba(255,255,255,0.65);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s;
    border-left: 3px solid transparent;
}

.sidebar-nav .nav-link:hover {
    color: #fff;
    background: rgba(255,255,255,0.06);
}

.sidebar-nav .nav-link.active {
    color: #fff;
    background: rgba(108, 92, 231, 0.2);
    border-left-color: var(--primary);
}

.sidebar-nav .nav-link i {
    font-size: 18px;
    width: 22px;
    text-align: center;
}

/* MAIN CONTENT */
.main-content {
    margin-left: var(--sidebar-width);
    min-height: 100vh;
}

.topbar {
    background: #fff;
    padding: 16px 32px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #E9ECEF;
    position: sticky;
    top: 0;
    z-index: 100;
}

.topbar-title {
    font-size: 20px;
    font-weight: 700;
    margin: 0;
}

.content-area {
    padding: 32px;
}

/* CARDS */
.stat-card {
    background: #fff;
    border-radius: 16px;
    padding: 24px;
    border: none;
    box-shadow: 0 2px 12px rgba(0,0,0,0.04);
    transition: transform 0.2s, box-shadow 0.2s;
}

.stat-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.08);
}

.stat-card .stat-icon {
    width: 52px;
    height: 52px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    color: #fff;
}

.stat-card .stat-value {
    font-size: 28px;
    font-weight: 800;
    margin: 8px 0 4px;
}

.stat-card .stat-label {
    font-size: 13px;
    color: #6c757d;
    font-weight: 500;
}

/* STATUS BADGES */
.status-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    display: inline-block;
}

.status-dot.online {
    background: var(--success);
    box-shadow: 0 0 8px var(--success);
    animation: pulse 2s infinite;
}

.status-dot.offline { background: var(--danger); }

.status-dot.waiting {
    background: var(--warning);
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(0.9); }
}

@keyframes scaleIn {
    0% { transform: scale(0); opacity: 0; }
    60% { transform: scale(1.15); }
    100% { transform: scale(1); opacity: 1; }
}

/* PLAN BADGES */
.plan-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #fff;
}

/* BUTTONS */
.btn-whatsapp {
    background: var(--whatsapp-green);
    border: none;
    color: #fff;
    font-weight: 600;
    border-radius: 10px;
    transition: all 0.2s;
}

.btn-whatsapp:hover {
    background: #128C7E;
    color: #fff;
    transform: translateY(-1px);
    box-shadow: 0 4px 15px rgba(37, 211, 102, 0.3);
}

.btn-shopee {
    background: var(--shopee-orange);
    border: none;
    color: #fff;
    font-weight: 600;
    border-radius: 10px;
}

.btn-shopee:hover {
    background: #D63F26;
    color: #fff;
}

/* QR MODAL */
#qrModal .modal-body img {
    image-rendering: pixelated;
}

/* TABLE */
.table-modern {
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}

.table-modern thead th {
    background: #F8F9FA;
    border: none;
    font-weight: 600;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #6c757d;
    padding: 14px 16px;
}

.table-modern tbody td {
    padding: 14px 16px;
    vertical-align: middle;
    border-color: #F0F2F5;
}

/* USAGE BAR */
.usage-bar-wrap {
    background: #E9ECEF;
    border-radius: 10px;
    height: 22px;
    overflow: hidden;
}

.usage-bar-fill {
    height: 100%;
    border-radius: 10px;
    transition: width 0.5s;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 700;
    color: #fff;
}

.usage-bar-fill.low { background: linear-gradient(90deg, var(--success), #00CEC9); }
.usage-bar-fill.mid { background: linear-gradient(90deg, var(--warning), #FDCB6E); }
.usage-bar-fill.high { background: linear-gradient(90deg, var(--danger), #E17055); }

/* RESPONSIVE */
.sidebar-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 24px;
    color: var(--dark);
}

@media (max-width: 991px) {
    .sidebar { transform: translateX(-100%); }
    .sidebar.show { transform: translateX(0); }
    .main-content { margin-left: 0; }
    .sidebar-toggle { display: block; }
    .content-area { padding: 20px 16px; }
}

/* LANDING */
.landing-hero {
    min-height: 100vh;
    background: linear-gradient(135deg, var(--primary) 0%, #2D3436 100%);
    color: #fff;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.landing-hero::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 600px;
    height: 600px;
    background: rgba(255,255,255,0.03);
    border-radius: 50%;
}

.pricing-card {
    background: #fff;
    border-radius: 20px;
    padding: 40px 32px;
    text-align: center;
    box-shadow: 0 10px 40px rgba(0,0,0,0.08);
    transition: all 0.3s;
    border: 2px solid transparent;
    position: relative;
}

.pricing-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 60px rgba(0,0,0,0.12);
}

.pricing-card.featured {
    border-color: var(--primary);
    transform: scale(1.05);
}

.pricing-card.featured::before {
    content: 'MAIS POPULAR';
    position: absolute;
    top: -14px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--primary);
    color: #fff;
    padding: 4px 20px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1px;
}

.pricing-price {
    font-size: 48px;
    font-weight: 800;
    color: var(--dark);
}

.pricing-price small {
    font-size: 16px;
    color: #6c757d;
    font-weight: 400;
}

.pricing-features {
    list-style: none;
    padding: 0;
    text-align: left;
}

.pricing-features li {
    padding: 8px 0;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 14px;
    color: #555;
}

.pricing-features li i {
    color: var(--success);
    font-size: 16px;
}

/* EMPTY STATE */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: #6c757d;
}

.empty-state i {
    font-size: 64px;
    opacity: 0.3;
    margin-bottom: 16px;
}
