/* ================================================
   SIM MANAGER - CSS 3.0 ULTRA PREMIUM EDITION
   3D Effects, Stunning Visuals, Modern Design
   ================================================ */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

:root {
    /* 🎨 Premium Dark Theme */
    --bg-dark: #0a0a0f;
    --bg-darker: #050508;
    --bg-card: rgba(15, 15, 25, 0.9);
    --bg-glass: rgba(255, 255, 255, 0.03);
    --bg-glass-hover: rgba(255, 255, 255, 0.08);

    /* ✨ Vibrant Accent Colors */
    --primary: #7c3aed;
    --primary-light: #a78bfa;
    --primary-glow: rgba(124, 58, 237, 0.5);
    --secondary: #06b6d4;
    --secondary-glow: rgba(6, 182, 212, 0.5);

    /* 🎯 Status Colors */
    --success: #10b981;
    --success-glow: rgba(16, 185, 129, 0.4);
    --warning: #f59e0b;
    --warning-glow: rgba(245, 158, 11, 0.4);
    --danger: #ef4444;
    --danger-glow: rgba(239, 68, 68, 0.4);

    /* 📝 Text Colors */
    --text-white: #ffffff;
    --text-light: #e2e8f0;
    --text-muted: #64748b;
    --text-dark: #334155;

    /* 🔲 3D & Shadows */
    --shadow-3d: 0 20px 60px rgba(0, 0, 0, 0.5), 0 8px 25px rgba(0, 0, 0, 0.3);
    --shadow-glow: 0 0 60px var(--primary-glow);
    --shadow-card: 0 10px 40px rgba(0, 0, 0, 0.4);

    /* 📐 Layout */
    --sidebar-width: 280px;
    --radius: 20px;
    --radius-sm: 12px;
    --radius-lg: 28px;

    /* ⏱ Animations */
    --ease-bounce: cubic-bezier(0.68, -0.55, 0.265, 1.55);
    --ease-smooth: cubic-bezier(0.4, 0, 0.2, 1);
}

/* ================================================
   🎨 DECORATIVE BACKGROUND OBJECTS
   ================================================ */

.bg-decorations {
    position: fixed;
    inset: 0;
    pointer-events: none;
    overflow: hidden;
    z-index: 0;
}

.bg-object {
    position: absolute;
    animation: float-object 20s ease-in-out infinite;
}

.bg-object.obj-1 {
    width: 400px;
    height: 400px;
    top: -100px;
    right: -100px;
    animation-delay: 0s;
}

.bg-object.obj-2 {
    width: 300px;
    height: 300px;
    bottom: -50px;
    left: 10%;
    animation-delay: 5s;
}

.bg-object.obj-3 {
    width: 250px;
    height: 250px;
    top: 40%;
    left: 30%;
    animation-delay: 10s;
}

@keyframes float-object {

    0%,
    100% {
        transform: translateY(0) rotate(0deg) scale(1);
    }

    25% {
        transform: translateY(-20px) rotate(5deg) scale(1.02);
    }

    50% {
        transform: translateY(10px) rotate(-5deg) scale(0.98);
    }

    75% {
        transform: translateY(-15px) rotate(3deg) scale(1.01);
    }
}

/* ================================================
   🎯 SVG ICON STYLES
   ================================================ */

.logo-icon-svg {
    width: 44px;
    height: 44px;
    flex-shrink: 0;
}

.logo-icon-svg svg {
    width: 100%;
    height: 100%;
    filter: drop-shadow(0 4px 15px rgba(124, 58, 237, 0.5));
}

.nav-icon-svg {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.nav-icon-svg svg {
    width: 100%;
    height: 100%;
}

.stat-icon svg {
    width: 32px;
    height: 32px;
}

/* ================================================
   🌟 GLOBAL STYLES
   ================================================ */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg-dark);
    color: var(--text-light);
    min-height: 100vh;
    line-height: 1.6;
    overflow-x: hidden;
}

/* Animated Background Gradient */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background:
        radial-gradient(ellipse at 20% 20%, rgba(124, 58, 237, 0.15) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 80%, rgba(6, 182, 212, 0.1) 0%, transparent 50%),
        radial-gradient(ellipse at 50% 50%, rgba(236, 72, 153, 0.05) 0%, transparent 70%);
    pointer-events: none;
    z-index: -1;
}

/* Floating Particles Animation */
body::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image:
        radial-gradient(2px 2px at 20px 30px, rgba(255, 255, 255, 0.15), transparent),
        radial-gradient(2px 2px at 40px 70px, rgba(255, 255, 255, 0.1), transparent),
        radial-gradient(1px 1px at 90px 40px, rgba(255, 255, 255, 0.12), transparent),
        radial-gradient(2px 2px at 130px 80px, rgba(255, 255, 255, 0.08), transparent),
        radial-gradient(1px 1px at 160px 120px, rgba(255, 255, 255, 0.1), transparent);
    background-size: 200px 200px;
    animation: float-particles 60s linear infinite;
    pointer-events: none;
    z-index: -1;
    opacity: 0.5;
}

@keyframes float-particles {
    0% {
        transform: translateY(0);
    }

    100% {
        transform: translateY(-200px);
    }
}

/* ================================================
   🔐 LOGIN PAGE - ULTRA 3D
   ================================================ */

.login-page {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    background: linear-gradient(135deg, #0a0a0f 0%, #1a1a2e 100%);
    position: relative;
    overflow: hidden;
}

.login-bg {
    position: absolute;
    inset: 0;
    overflow: hidden;
}

.bg-shape {
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
    animation: float 8s ease-in-out infinite;
}

.shape-1 {
    width: 500px;
    height: 500px;
    background: linear-gradient(135deg, #7c3aed, #ec4899);
    top: -150px;
    right: -150px;
    animation-delay: 0s;
}

.shape-2 {
    width: 400px;
    height: 400px;
    background: linear-gradient(135deg, #06b6d4, #3b82f6);
    bottom: -100px;
    left: -100px;
    animation-delay: 2s;
}

.shape-3 {
    width: 300px;
    height: 300px;
    background: linear-gradient(135deg, #f59e0b, #ef4444);
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    animation-delay: 4s;
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0) scale(1);
    }

    50% {
        transform: translateY(-30px) scale(1.05);
    }
}

.login-container {
    position: relative;
    width: 100%;
    max-width: 420px;
    padding: 20px;
    z-index: 10;
}

.login-card {
    background: rgba(15, 15, 25, 0.85);
    backdrop-filter: blur(40px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-lg);
    padding: 48px 40px;
    box-shadow: var(--shadow-3d);
    position: relative;
    overflow: hidden;
    transform-style: preserve-3d;
    transition: transform 0.3s var(--ease-smooth);
}

.login-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 200px;
    background: linear-gradient(180deg, rgba(124, 58, 237, 0.1) 0%, transparent 100%);
    pointer-events: none;
}

.login-card::after {
    content: '✨';
    position: absolute;
    top: 20px;
    right: 20px;
    font-size: 24px;
    animation: sparkle 2s ease-in-out infinite;
}

@keyframes sparkle {

    0%,
    100% {
        opacity: 1;
        transform: scale(1);
    }

    50% {
        opacity: 0.5;
        transform: scale(1.2);
    }
}

.login-header {
    text-align: center;
    margin-bottom: 36px;
}

.logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    margin-bottom: 12px;
}

.logo-icon {
    font-size: 48px;
    filter: drop-shadow(0 4px 20px rgba(124, 58, 237, 0.5));
}

.logo h1 {
    font-size: 32px;
    font-weight: 800;
    background: linear-gradient(135deg, #7c3aed 0%, #ec4899 50%, #06b6d4 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.tagline {
    color: var(--text-muted);
    font-size: 14px;
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-group label {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.input-icon {
    position: absolute;
    left: 16px;
    font-size: 18px;
    opacity: 0.6;
    z-index: 2;
}

.input-wrapper input {
    width: 100%;
    padding: 16px 16px 16px 50px;
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-sm);
    color: var(--text-white);
    font-size: 15px;
    transition: all 0.3s var(--ease-smooth);
}

.input-wrapper input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px var(--primary-glow), 0 0 30px var(--primary-glow);
    background: rgba(124, 58, 237, 0.05);
}

input,
select,
textarea {
    width: 100%;
    padding: 14px 16px;
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-sm);
    color: var(--text-white);
    font-size: 14px;
    font-family: inherit;
    transition: all 0.3s var(--ease-smooth);
}

input:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px var(--primary-glow);
}

input::placeholder,
textarea::placeholder {
    color: var(--text-muted);
}

select {
    cursor: pointer;
    background-color: rgba(15, 15, 25, 0.95);
}

select option {
    background-color: #1a1a2e;
    color: #ffffff;
    padding: 12px;
}

.error-message {
    background: rgba(239, 68, 68, 0.15);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #fca5a5;
    padding: 14px;
    border-radius: var(--radius-sm);
    font-size: 14px;
    text-align: center;
}

.login-footer {
    margin-top: 24px;
    text-align: center;
    color: var(--text-muted);
    font-size: 13px;
}

/* ================================================
   🔘 BUTTONS - 3D PREMIUM
   ================================================ */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 14px 32px;
    font-size: 14px;
    font-weight: 700;
    border: none;
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-family: inherit;
    position: relative;
    overflow: hidden;
    transition: all 0.3s var(--ease-smooth);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.6s;
}

.btn:hover::before {
    left: 100%;
}

.btn-primary {
    background: linear-gradient(135deg, #7c3aed 0%, #a855f7 50%, #ec4899 100%);
    color: white;
    box-shadow: 0 8px 30px rgba(124, 58, 237, 0.4), 0 4px 10px rgba(0, 0, 0, 0.3);
    transform: translateY(0);
}

.btn-primary:hover {
    transform: translateY(-4px) scale(1.02);
    box-shadow: 0 16px 50px rgba(124, 58, 237, 0.5), 0 8px 20px rgba(0, 0, 0, 0.4);
}

.btn-primary:active {
    transform: translateY(-2px) scale(0.98);
}

.btn-ghost {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-light);
    border: 2px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
}

.btn-ghost:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

.btn-danger {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: white;
    box-shadow: 0 8px 30px rgba(239, 68, 68, 0.4);
}

.btn-danger:hover {
    transform: translateY(-4px);
    box-shadow: 0 16px 50px rgba(239, 68, 68, 0.5);
}

.btn-success {
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
    box-shadow: 0 8px 30px rgba(16, 185, 129, 0.4);
}

.btn-block {
    width: 100%;
}

.btn-sm {
    padding: 10px 18px;
    font-size: 12px;
}

.btn-icon {
    padding: 12px;
    min-width: 44px;
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.btn-text {
    display: inline-flex;
    align-items: center;
}

.btn-loader {
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.btn-icon-svg,
.spinner-svg {
    display: block;
}

.spinner-svg {
    animation: spin 1s linear infinite;
}

/* ================================================
   📐 APP LAYOUT
   ================================================ */

.app-container {
    display: flex;
    min-height: 100vh;
}

/* ================================================
   📱 SIDEBAR - 3D GLASS
   ================================================ */

.sidebar {
    width: var(--sidebar-width);
    background: rgba(10, 10, 20, 0.95);
    backdrop-filter: blur(40px);
    border-right: 1px solid rgba(255, 255, 255, 0.05);
    display: flex;
    flex-direction: column;
    position: fixed;
    height: 100vh;
    z-index: 100;
    box-shadow: 10px 0 50px rgba(0, 0, 0, 0.5);
}

.sidebar-header {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 28px 24px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    background: linear-gradient(180deg, rgba(124, 58, 237, 0.1) 0%, transparent 100%);
}

.sidebar-header .logo-icon {
    font-size: 36px;
    filter: drop-shadow(0 4px 15px rgba(124, 58, 237, 0.5));
}

.sidebar-header h1 {
    font-size: 22px;
    font-weight: 800;
    background: linear-gradient(135deg, #7c3aed, #06b6d4);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.sidebar-nav {
    flex: 1;
    padding: 20px 16px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px 20px;
    color: var(--text-muted);
    text-decoration: none;
    border-radius: var(--radius-sm);
    transition: all 0.3s var(--ease-smooth);
    position: relative;
    overflow: hidden;
}

.nav-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background: linear-gradient(180deg, #7c3aed, #06b6d4);
    opacity: 0;
    transition: opacity 0.3s;
}

.nav-item:hover {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-white);
    transform: translateX(4px);
}

.nav-item.active {
    background: linear-gradient(135deg, rgba(124, 58, 237, 0.2), rgba(6, 182, 212, 0.1));
    color: var(--text-white);
    box-shadow: 0 4px 20px rgba(124, 58, 237, 0.2);
}

.nav-item.active::before {
    opacity: 1;
}

.nav-icon {
    font-size: 22px;
    filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.3));
}

.sidebar-footer {
    padding: 20px 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

/* ================================================
   📄 MAIN CONTENT
   ================================================ */

.main-content {
    flex: 1;
    margin-left: var(--sidebar-width);
    padding: 32px;
    min-height: 100vh;
}

.content-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 32px;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 20px;
}

.header-left h2 {
    font-size: 28px;
    font-weight: 800;
    background: linear-gradient(135deg, #ffffff 0%, #94a3b8 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

.sidebar-toggle {
    display: none;
    background: var(--bg-glass);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-white);
    font-size: 22px;
    padding: 10px 14px;
    border-radius: var(--radius-sm);
    cursor: pointer;
}

/* ================================================
   📊 STATS CARDS - 3D FLOATING
   ================================================ */

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 24px;
    margin-bottom: 32px;
}

.stat-card {
    background: var(--bg-card);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius);
    padding: 28px;
    display: flex;
    align-items: center;
    gap: 20px;
    position: relative;
    overflow: hidden;
    transition: all 0.4s var(--ease-smooth);
    transform-style: preserve-3d;
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 100%;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.05) 0%, transparent 50%);
    pointer-events: none;
}

.stat-card::after {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, rgba(124, 58, 237, 0.1) 0%, transparent 70%);
    pointer-events: none;
}

.stat-card:hover {
    transform: translateY(-8px) rotateX(5deg);
    box-shadow: var(--shadow-3d), var(--shadow-glow);
    border-color: rgba(124, 58, 237, 0.3);
}

.stat-card.warning {
    border-color: rgba(245, 158, 11, 0.4);
}

.stat-card.warning:hover {
    box-shadow: var(--shadow-3d), 0 0 40px var(--warning-glow);
}

.stat-card.highlight {
    border-color: rgba(236, 72, 153, 0.35);
}

.stat-card.highlight:hover {
    box-shadow: var(--shadow-3d), 0 0 40px rgba(236, 72, 153, 0.35);
}

.stat-icon {
    width: 64px;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    border-radius: var(--radius-sm);
    position: relative;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

.stat-icon.total {
    background: linear-gradient(135deg, #7c3aed 0%, #a855f7 100%);
}

.stat-icon.active {
    background: linear-gradient(135deg, #10b981 0%, #34d399 100%);
}

.stat-icon.inactive {
    background: linear-gradient(135deg, #6b7280 0%, #9ca3af 100%);
}

.stat-icon.warning {
    background: linear-gradient(135deg, #f59e0b 0%, #fbbf24 100%);
}

.stat-info {
    display: flex;
    flex-direction: column;
}

.stat-value {
    font-size: 36px;
    font-weight: 800;
    line-height: 1.2;
    background: linear-gradient(135deg, #ffffff 0%, #cbd5e1 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.stat-label {
    font-size: 13px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-top: 4px;
}

/* ================================================
   ⚠️ ALERT BANNER
   ================================================ */

.alert-banner {
    display: flex;
    align-items: center;
    gap: 16px;
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.15), rgba(239, 68, 68, 0.1));
    border: 1px solid rgba(245, 158, 11, 0.4);
    border-radius: var(--radius-sm);
    padding: 18px 24px;
    margin-bottom: 28px;
    animation: alert-pulse 3s ease-in-out infinite;
}

@keyframes alert-pulse {

    0%,
    100% {
        box-shadow: 0 0 0 0 rgba(245, 158, 11, 0.2);
    }

    50% {
        box-shadow: 0 0 30px rgba(245, 158, 11, 0.3);
    }
}

.alert-icon {
    font-size: 24px;
}

.alert-banner span {
    flex: 1;
    color: #fbbf24;
    font-weight: 600;
}

.alert-close {
    background: none;
    border: none;
    color: #fbbf24;
    font-size: 24px;
    cursor: pointer;
    opacity: 0.7;
    transition: opacity 0.3s;
}

.alert-close:hover {
    opacity: 1;
}

/* ================================================
   🔍 TOOLBAR
   ================================================ */

.toolbar {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 28px;
    flex-wrap: wrap;
}

.search-box {
    position: relative;
    flex: 1;
    min-width: 280px;
}

.search-icon {
    position: absolute;
    left: 18px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 18px;
    opacity: 0.5;
}

.search-box input {
    padding-left: 52px;
    background: var(--bg-card);
    border: 2px solid rgba(255, 255, 255, 0.08);
}

.filter-group {
    display: flex;
    gap: 14px;
}

.filter-group select {
    min-width: 140px;
    background: var(--bg-card);
}

/* ================================================
   📅 CALENDAR SECTION
   ================================================ */

.calendar-section {
    background: var(--bg-card);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius);
    padding: 28px;
    margin-bottom: 28px;
    position: relative;
    overflow: hidden;
}

.calendar-section::before {
    content: '';
    position: absolute;
    top: -80px;
    right: -60px;
    width: 200px;
    height: 200px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(124, 58, 237, 0.18), transparent 70%);
    opacity: 0.6;
    pointer-events: none;
}

.calendar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    flex-wrap: wrap;
    gap: 16px;
}

.calendar-header h3 {
    font-size: 20px;
    font-weight: 700;
}

.calendar-legend {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: var(--text-muted);
}

.legend-dot {
    width: 14px;
    height: 14px;
    border-radius: 4px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.legend-dot.green {
    background: linear-gradient(135deg, #10b981, #34d399);
}

.legend-dot.yellow {
    background: linear-gradient(135deg, #f59e0b, #fbbf24);
}

.legend-dot.red {
    background: linear-gradient(135deg, #ef4444, #f87171);
}

.sim-calendar {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(90px, 1fr));
    gap: 12px;
}

/* Calendar Cell - 3D */
.calendar-cell {
    background: var(--bg-glass);
    border-radius: var(--radius-sm);
    padding: 16px 10px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s var(--ease-smooth);
    border: 2px solid transparent;
    position: relative;
    overflow: hidden;
}

.calendar-cell::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
}

.calendar-cell.green::before {
    background: linear-gradient(90deg, #10b981, #34d399);
}

.calendar-cell.yellow::before {
    background: linear-gradient(90deg, #f59e0b, #fbbf24);
}

.calendar-cell.red::before {
    background: linear-gradient(90deg, #ef4444, #f87171);
}

.calendar-cell.green {
    border-color: rgba(16, 185, 129, 0.3);
    background: rgba(16, 185, 129, 0.08);
}

.calendar-cell.yellow {
    border-color: rgba(245, 158, 11, 0.3);
    background: rgba(245, 158, 11, 0.08);
}

.calendar-cell.red {
    border-color: rgba(239, 68, 68, 0.3);
    background: rgba(239, 68, 68, 0.08);
    animation: pulse-red 2s infinite;
}

@keyframes pulse-red {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.8;
    }
}

.calendar-cell:hover {
    transform: translateY(-4px) scale(1.05);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.4);
}

.cell-days {
    font-size: 32px;
    font-weight: 800;
    line-height: 1;
    margin-bottom: 8px;
}

.calendar-cell.green .cell-days {
    color: #10b981;
}

.calendar-cell.yellow .cell-days {
    color: #f59e0b;
}

.calendar-cell.red .cell-days {
    color: #ef4444;
}

.cell-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 11px;
}

.cell-number {
    color: var(--text-muted);
    font-weight: 600;
}

.cell-status {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    border: 2px solid rgba(148, 163, 184, 0.6);
    background: transparent;
    box-shadow: 0 0 8px rgba(0, 0, 0, 0.2);
    flex-shrink: 0;
}

.cell-status.on {
    background: #10b981;
    border-color: rgba(16, 185, 129, 0.9);
}

.cell-status.off {
    background: transparent;
    border-color: rgba(148, 163, 184, 0.7);
}

.calendar-empty {
    text-align: center;
    color: var(--text-muted);
    padding: 30px;
    font-size: 14px;
}

/* ================================================
   📱 SIM CARDS GRID - 3D ULTRA
   ================================================ */

.sim-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 18px;
}

.sim-card {
    background: var(--bg-card);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius);
    padding: 28px;
    transition: all 0.4s var(--ease-smooth);
    position: relative;
    overflow: hidden;
    transform-style: preserve-3d;
}

.sim-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 5px;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
}

.sim-card.status-on::before {
    background: linear-gradient(90deg, #10b981, #34d399);
}

.sim-card.status-off::before {
    background: linear-gradient(90deg, #6b7280, #9ca3af);
}

.sim-card.warning::before {
    background: linear-gradient(90deg, #f59e0b, #fbbf24);
}

.sim-card.critical::before {
    background: linear-gradient(90deg, #ef4444, #f87171);
    animation: glow-red 1.5s infinite;
}

@keyframes glow-red {

    0%,
    100% {
        box-shadow: 0 0 15px rgba(239, 68, 68, 0.5);
    }

    50% {
        box-shadow: 0 0 30px rgba(239, 68, 68, 0.8);
    }
}

.sim-card:hover {
    transform: translateY(-10px) rotateX(5deg);
    box-shadow: var(--shadow-3d), 0 0 50px rgba(124, 58, 237, 0.15);
    border-color: rgba(124, 58, 237, 0.3);
}

.sim-card.highlight-pulse {
    animation: card-highlight 0.5s ease 3;
}

@keyframes card-highlight {

    0%,
    100% {
        box-shadow: 0 0 0 0 rgba(124, 58, 237, 0.5);
    }

    50% {
        box-shadow: 0 0 0 15px rgba(124, 58, 237, 0);
    }
}

.sim-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 20px;
}

.sim-info-left {
    display: flex;
    align-items: center;
    gap: 14px;
}

/* Carrier Logos - 3D Style */
.carrier-logo {
    width: 52px;
    height: 52px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 20px;
    color: white;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.4);
    flex-shrink: 0;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3), inset 0 2px 0 rgba(255, 255, 255, 0.2);
    position: relative;
    overflow: hidden;
}

.carrier-logo::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 50%;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.2) 0%, transparent 100%);
    pointer-events: none;
}

.carrier-logo img {
    width: 26px;
    height: 26px;
    display: block;
}

/* Pakistani Carriers */
.carrier-logo.jazz {
    background: linear-gradient(180deg, #e30613 0%, #b8050f 100%);
}

.carrier-logo.telenor {
    background: linear-gradient(180deg, #0099ff 0%, #0077cc 100%);
}

.carrier-logo.zong {
    background: linear-gradient(180deg, #00a84f 0%, #008a40 100%);
}

.carrier-logo.ufone {
    background: linear-gradient(180deg, #ff6600 0%, #cc5200 100%);
}

.carrier-logo.scom {
    background: linear-gradient(180deg, #1a4d8c 0%, #133a6b 100%);
}

/* International Carriers */
.carrier-logo.vodafone {
    background: linear-gradient(180deg, #e60000 0%, #b80000 100%);
}

.carrier-logo.airtel {
    background: linear-gradient(180deg, #ed1c24 0%, #c0161c 100%);
}

.carrier-logo.jio {
    background: linear-gradient(180deg, #0a2885 0%, #081d66 100%);
}

.carrier-logo.tmobile {
    background: linear-gradient(180deg, #e20074 0%, #b3005c 100%);
}

.carrier-logo.att {
    background: linear-gradient(180deg, #00a8e0 0%, #0086b3 100%);
    font-size: 14px;
}

.carrier-logo.verizon {
    background: linear-gradient(180deg, #cd040b 0%, #a30309 100%);
}

.carrier-logo.default {
    background: linear-gradient(180deg, #7c3aed 0%, #5b21b6 100%);
}

.sim-number {
    font-size: 20px;
    font-weight: 700;
}

.sim-carrier {
    font-size: 13px;
    color: var(--text-muted);
    margin-top: 4px;
}

.sim-status {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border-radius: 25px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.sim-status.on {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.2), rgba(52, 211, 153, 0.1));
    color: #34d399;
    box-shadow: 0 0 20px rgba(16, 185, 129, 0.2);
}

.sim-status.off {
    background: rgba(107, 114, 128, 0.2);
    color: #9ca3af;
}

.sim-status .status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: currentColor;
    box-shadow: 0 0 8px currentColor;
    flex-shrink: 0;
}

.sim-card-body {
    margin-bottom: 24px;
}

.days-display {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 6px;
    margin-bottom: 16px;
    text-align: right;
}

.days-count {
    font-size: 52px;
    font-weight: 800;
    line-height: 1;
    text-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.days-count.normal {
    background: linear-gradient(135deg, #10b981, #34d399);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.days-count.warning {
    background: linear-gradient(135deg, #f59e0b, #fbbf24);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.days-count.critical {
    background: linear-gradient(135deg, #ef4444, #f87171);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.days-label {
    color: var(--text-muted);
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.4px;
    line-height: 1.2;
    max-width: 160px;
}

.progress-bar {
    height: 8px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 4px;
    overflow: hidden;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.3);
}

.progress-fill {
    height: 100%;
    border-radius: 4px;
    transition: width 0.6s var(--ease-smooth);
    box-shadow: 0 0 15px currentColor;
}

.progress-fill.normal {
    background: linear-gradient(90deg, #10b981, #34d399);
}

.progress-fill.warning {
    background: linear-gradient(90deg, #f59e0b, #fbbf24);
}

.progress-fill.critical {
    background: linear-gradient(90deg, #ef4444, #f87171);
}

.sim-card-footer {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto auto;
    gap: 10px;
    align-items: center;
}

.sim-card-footer .btn {
    padding: 10px 12px;
    font-size: 12px;
}

.sim-card-footer .btn-toggle {
    width: 100%;
    white-space: nowrap;
}

.sim-card-footer .btn-icon {
    padding: 10px;
}

.btn-toggle {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-white);
}

.btn-toggle:hover {
    background: var(--primary);
    border-color: var(--primary);
    box-shadow: 0 8px 25px var(--primary-glow);
}

/* ================================================
   🎭 MODALS - 3D FLOATING
   ================================================ */

.modal {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    opacity: 0;
    visibility: hidden;
    transition: all 0.4s var(--ease-smooth);
}

.modal.active {
    opacity: 1;
    visibility: visible;
}

.modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(8px);
}

.modal-content {
    position: relative;
    background: rgba(15, 15, 25, 0.95);
    backdrop-filter: blur(40px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius);
    width: 100%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
    transform: translateY(30px) scale(0.95);
    transition: all 0.4s var(--ease-bounce);
    box-shadow: var(--shadow-3d), var(--shadow-glow);
}

.modal.active .modal-content {
    transform: translateY(0) scale(1);
}

.modal-small {
    max-width: 420px;
}

.modal-large {
    max-width: 640px;
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 24px 28px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    background: linear-gradient(180deg, rgba(124, 58, 237, 0.1) 0%, transparent 100%);
}

.modal-header h3 {
    font-size: 20px;
    font-weight: 700;
}

.modal-close {
    background: rgba(255, 255, 255, 0.05);
    border: none;
    color: var(--text-muted);
    font-size: 24px;
    width: 40px;
    height: 40px;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-close:hover {
    color: var(--text-white);
    background: rgba(239, 68, 68, 0.2);
}

.modal-body {
    padding: 28px;
}

.modal form {
    padding: 28px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.modal-footer {
    display: flex;
    gap: 14px;
    justify-content: flex-end;
    padding: 0;
    margin-top: 8px;
}

/* ================================================
   🔔 TOAST NOTIFICATIONS
   ================================================ */

.toast-container {
    position: fixed;
    bottom: 28px;
    right: 28px;
    z-index: 2000;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.toast {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 18px 24px;
    background: rgba(15, 15, 25, 0.95);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-3d);
    animation: toast-slide 0.4s var(--ease-bounce);
    min-width: 280px;
}

@keyframes toast-slide {
    from {
        transform: translateX(100%);
        opacity: 0;
    }

    to {
        transform: translateX(0);
        opacity: 1;
    }
}

.toast.success {
    border-left: 4px solid #10b981;
}

.toast.error {
    border-left: 4px solid #ef4444;
}

.toast.warning {
    border-left: 4px solid #f59e0b;
}

.toast.info {
    border-left: 4px solid #3b82f6;
}

.toast-icon {
    font-size: 22px;
}

.toast-message {
    color: var(--text-light);
    font-size: 14px;
}

/* ================================================
   📋 HISTORY PAGE
   ================================================ */

.history-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 28px;
    background: var(--bg-glass);
    border-radius: var(--radius-sm);
    padding: 8px;
    width: fit-content;
}

.history-tab {
    padding: 12px 28px;
    background: transparent;
    border: none;
    color: var(--text-muted);
    font-size: 14px;
    font-weight: 600;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s;
}

.history-tab:hover {
    color: var(--text-white);
}

.history-tab.active {
    background: linear-gradient(135deg, #7c3aed, #a855f7);
    color: white;
    box-shadow: 0 4px 15px rgba(124, 58, 237, 0.4);
}

.history-list {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.history-item {
    display: flex;
    align-items: flex-start;
    gap: 18px;
    padding: 22px;
    background: var(--bg-card);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-sm);
    transition: all 0.3s;
}

.history-item:hover {
    transform: translateX(8px);
    border-color: rgba(124, 58, 237, 0.3);
}

.history-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    flex-shrink: 0;
}

.history-icon.created {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.2), transparent);
}

.history-icon.updated {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.2), transparent);
}

.history-icon.toggled {
    background: linear-gradient(135deg, rgba(168, 85, 247, 0.2), transparent);
}

.history-content {
    flex: 1;
}

.history-title {
    font-weight: 600;
    margin-bottom: 6px;
}

.history-details {
    font-size: 13px;
    color: var(--text-muted);
}

.history-time {
    font-size: 12px;
    color: var(--text-muted);
    white-space: nowrap;
}

.tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 24px;
    background: var(--bg-glass);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-sm);
    padding: 8px;
    width: fit-content;
    flex-wrap: wrap;
}

.tab-btn {
    padding: 12px 24px;
    background: transparent;
    border: none;
    color: var(--text-muted);
    font-size: 14px;
    font-weight: 600;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s;
}

.tab-btn:hover {
    color: var(--text-white);
}

.tab-btn.active {
    background: linear-gradient(135deg, #7c3aed, #a855f7);
    color: white;
    box-shadow: 0 4px 15px rgba(124, 58, 237, 0.35);
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
    animation: tab-fade 0.3s ease;
}

@keyframes tab-fade {
    from {
        opacity: 0;
        transform: translateY(6px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.table-container {
    background: var(--bg-card);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-sm);
    overflow-x: auto;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 720px;
}

.data-table thead {
    background: rgba(255, 255, 255, 0.03);
}

.data-table th,
.data-table td {
    padding: 14px 16px;
    text-align: left;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.data-table th {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-muted);
}

.data-table tbody tr:hover {
    background: rgba(255, 255, 255, 0.03);
}

.loading-cell,
.empty-cell {
    text-align: center;
    color: var(--text-muted);
    padding: 28px 16px;
}

.loading-cell .spinner {
    margin: 0 auto 12px;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.4px;
    border: 1px solid transparent;
    background: rgba(255, 255, 255, 0.08);
    color: var(--text-light);
}

.badge-created {
    background: rgba(16, 185, 129, 0.15);
    border-color: rgba(16, 185, 129, 0.35);
    color: #6ee7b7;
}

.badge-updated {
    background: rgba(59, 130, 246, 0.15);
    border-color: rgba(59, 130, 246, 0.35);
    color: #93c5fd;
}

.badge-toggled {
    background: rgba(139, 92, 246, 0.15);
    border-color: rgba(139, 92, 246, 0.35);
    color: #c4b5fd;
}

.badge-streak_created {
    background: rgba(249, 115, 22, 0.15);
    border-color: rgba(249, 115, 22, 0.35);
    color: #fdba74;
}

.badge-streak_completed {
    background: rgba(16, 185, 129, 0.15);
    border-color: rgba(16, 185, 129, 0.35);
    color: #6ee7b7;
}

.badge-warning {
    background: rgba(245, 158, 11, 0.15);
    border-color: rgba(245, 158, 11, 0.35);
    color: #fbbf24;
}

.badge-critical {
    background: rgba(239, 68, 68, 0.15);
    border-color: rgba(239, 68, 68, 0.35);
    color: #fca5a5;
}

.badge-success {
    background: rgba(16, 185, 129, 0.15);
    border-color: rgba(16, 185, 129, 0.35);
    color: #6ee7b7;
}

.badge-pending {
    background: rgba(100, 116, 139, 0.2);
    border-color: rgba(100, 116, 139, 0.35);
    color: #cbd5e1;
}

.status-on,
.status-off {
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.4px;
    border: 1px solid transparent;
}

.status-on {
    background: rgba(16, 185, 129, 0.2);
    border-color: rgba(16, 185, 129, 0.35);
    color: #34d399;
}

.status-off {
    background: rgba(107, 114, 128, 0.2);
    border-color: rgba(107, 114, 128, 0.3);
    color: #cbd5e1;
}

/* ================================================
   ⚙️ SETTINGS PAGE
   ================================================ */

.settings-grid,
.settings-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(380px, 1fr));
    gap: 28px;
}

.settings-card {
    background: var(--bg-card);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius);
    padding: 32px;
    position: relative;
    overflow: hidden;
}

.settings-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
}

.settings-card h3 {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.settings-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.card-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 18px;
}

.form-hint {
    display: block;
    margin-top: 6px;
    font-size: 12px;
    color: var(--text-muted);
}

.toggle-label {
    display: flex;
    align-items: center;
    gap: 12px;
    font-weight: 600;
    color: var(--text-light);
    cursor: pointer;
    position: relative;
}

.toggle-label input {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-switch {
    position: relative;
    width: 48px;
    height: 26px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 999px;
    transition: all 0.3s var(--ease-smooth);
    flex-shrink: 0;
}

.toggle-switch::after {
    content: '';
    position: absolute;
    top: 3px;
    left: 3px;
    width: 18px;
    height: 18px;
    background: #ffffff;
    border-radius: 50%;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
    transition: transform 0.3s var(--ease-smooth);
}

.toggle-label input:checked+.toggle-switch {
    background: rgba(16, 185, 129, 0.3);
    border-color: rgba(16, 185, 129, 0.6);
}

.toggle-label input:checked+.toggle-switch::after {
    transform: translateX(22px);
}

.toggle-label input:focus-visible+.toggle-switch {
    box-shadow: 0 0 0 4px rgba(124, 58, 237, 0.35);
}

.settings-info {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 20px;
}

.info-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.info-row:last-child {
    border-bottom: none;
}

.info-label {
    color: var(--text-muted);
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.4px;
}

.info-value {
    font-weight: 600;
}

.cron-info {
    padding: 18px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-sm);
}

.cron-info h4 {
    font-size: 15px;
    margin-bottom: 10px;
}

.cron-command {
    display: block;
    margin: 10px 0 6px;
    padding: 10px 12px;
    border-radius: 10px;
    background: rgba(15, 15, 25, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: #e2e8f0;
    font-family: Consolas, "Liberation Mono", Menlo, monospace;
    font-size: 12px;
}

/* ================================================
   🔥 STREAKS PAGE
   ================================================ */

.filter-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 28px;
    background: var(--bg-glass);
    padding: 8px;
    border-radius: var(--radius-sm);
    width: fit-content;
}

.filter-tab {
    padding: 12px 24px;
    background: transparent;
    border: none;
    color: var(--text-muted);
    font-size: 14px;
    font-weight: 600;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s;
}

.filter-tab:hover {
    color: var(--text-white);
}

.filter-tab.active {
    background: linear-gradient(135deg, #f97316, #ea580c);
    color: white;
    box-shadow: 0 4px 15px rgba(249, 115, 22, 0.4);
}

.streak-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
    gap: 24px;
}

/* Streak Card - 3D Fire Effect */
.streak-card {
    background: var(--bg-card);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius);
    padding: 28px;
    transition: all 0.4s var(--ease-smooth);
    position: relative;
    overflow: hidden;
}

.streak-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 5px;
    background: linear-gradient(90deg, #f97316, #fb923c);
}

.streak-card.completed::before {
    background: linear-gradient(90deg, #8b5cf6, #a78bfa);
}

.streak-card.goal-reached::before {
    background: linear-gradient(90deg, #10b981, #34d399);
    animation: shimmer 2s infinite;
}

@keyframes shimmer {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.6;
    }
}

.streak-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-3d), 0 0 40px rgba(249, 115, 22, 0.15);
}

.streak-card-header {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 24px;
}

.streak-fire {
    font-size: 40px;
    line-height: 1;
    filter: drop-shadow(0 4px 15px rgba(249, 115, 22, 0.5));
    animation: fire-flicker 1s ease-in-out infinite;
}

@keyframes fire-flicker {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.1);
    }
}

.streak-title {
    flex: 1;
}

.streak-title h4 {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 6px;
}

.streak-sim {
    font-size: 13px;
    color: var(--text-muted);
}

.streak-status {
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
}

.streak-status.active {
    background: rgba(249, 115, 22, 0.2);
    color: #fb923c;
}

.streak-status.completed {
    background: rgba(139, 92, 246, 0.2);
    color: #a78bfa;
}

.streak-status.goal-reached {
    background: rgba(16, 185, 129, 0.2);
    color: #34d399;
}

.streak-card-body {
    margin-bottom: 24px;
}

.streak-days-display {
    display: flex;
    align-items: baseline;
    gap: 14px;
    margin-bottom: 20px;
}

.streak-days-count {
    font-size: 56px;
    font-weight: 800;
    line-height: 1;
    background: linear-gradient(135deg, #f97316, #fbbf24);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0 4px 30px rgba(249, 115, 22, 0.3);
}

.streak-days-info {
    display: flex;
    flex-direction: column;
}

.streak-days-label {
    font-size: 18px;
    color: var(--text-light);
    font-weight: 600;
}

.streak-target {
    font-size: 13px;
    color: var(--text-muted);
}

.streak-progress {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 16px;
}

.streak-progress-bar {
    flex: 1;
    height: 10px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 5px;
    overflow: hidden;
}

.streak-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #f97316, #fbbf24);
    border-radius: 5px;
    transition: width 0.6s;
    box-shadow: 0 0 15px rgba(249, 115, 22, 0.5);
}

.streak-progress-fill.complete {
    background: linear-gradient(90deg, #10b981, #34d399);
}

.streak-progress-text {
    font-size: 14px;
    font-weight: 700;
    color: var(--text-muted);
    min-width: 50px;
}

.streak-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 18px;
    font-size: 12px;
    color: var(--text-muted);
}

.streak-start,
.streak-carrier {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.streak-card-footer {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.btn-danger-text {
    color: #f87171;
}

.btn-danger-text:hover {
    background: rgba(239, 68, 68, 0.15);
}

.streak-details {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.details-hero {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    flex-wrap: wrap;
    padding: 18px;
    border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.06);
}

.details-days {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.big-number {
    font-size: 56px;
    font-weight: 800;
    line-height: 1;
    background: linear-gradient(135deg, #f97316, #fbbf24);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.days-text {
    color: var(--text-muted);
    font-size: 14px;
    margin-top: 4px;
}

.details-progress-ring {
    position: relative;
    width: 120px;
    height: 120px;
}

.details-progress-ring svg {
    width: 100%;
    height: 100%;
    transform: rotate(-90deg);
}

.progress-bg,
.progress-value {
    fill: none;
    stroke-width: 10;
}

.progress-bg {
    stroke: rgba(255, 255, 255, 0.08);
}

.progress-value {
    stroke: #f97316;
    stroke-linecap: round;
}

.progress-center {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
}

.details-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 16px;
}

.info-item {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: var(--radius-sm);
    padding: 14px 16px;
}

.milestones-section h4,
.notes-section h4 {
    font-size: 15px;
    margin-bottom: 12px;
}

.milestones-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 12px;
}

.milestone-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.06);
    color: var(--text-muted);
    font-size: 13px;
}

.milestone-item.reached {
    color: #34d399;
    border-color: rgba(16, 185, 129, 0.4);
    background: rgba(16, 185, 129, 0.12);
}

.milestone-icon {
    font-size: 16px;
}

.milestone-days {
    font-weight: 600;
}

.notes-section {
    padding: 16px;
    border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.06);
}

/* ================================================
   🔧 UTILITIES
   ================================================ */

.text-muted {
    color: var(--text-muted);
}

.text-center {
    text-align: center;
}

.loading-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
    color: var(--text-muted);
}

.spinner {
    width: 48px;
    height: 48px;
    border: 4px solid rgba(255, 255, 255, 0.1);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 16px;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* ================================================
   📱 RESPONSIVE
   ================================================ */

@media (max-width: 1024px) {
    .sidebar {
        transform: translateX(-100%);
    }

    .sidebar.open {
        transform: translateX(0);
    }

    .main-content {
        margin-left: 0;
    }

    .sidebar-toggle {
        display: block;
    }
}

@media (max-width: 768px) {
    .stats-grid {
        grid-template-columns: 1fr 1fr;
    }

    .sim-grid {
        grid-template-columns: 1fr;
    }

    .streak-grid {
        grid-template-columns: 1fr;
    }

    .settings-grid {
        grid-template-columns: 1fr;
    }

    .toolbar {
        flex-direction: column;
    }

    .search-box {
        min-width: 100%;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .tabs {
        width: 100%;
    }

    .tab-btn {
        flex: 1;
        text-align: center;
    }

    .details-hero {
        flex-direction: column;
        align-items: flex-start;
    }

    .details-progress-ring {
        width: 100px;
        height: 100px;
    }

    .data-table {
        min-width: 640px;
    }
}

@media (max-width: 480px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }

    .main-content {
        padding: 20px 16px;
    }

    .stat-card {
        padding: 20px;
    }

    .sim-card {
        padding: 20px;
    }

    .sim-card-footer {
        grid-template-columns: 1fr 1fr;
    }

    .sim-card-footer .btn-toggle {
        grid-column: 1 / -1;
    }
}

/* ================================================
   🔧 CRITICAL LAYOUT FIXES
   ================================================ */

/* Fix calendar cells - larger and rectangular */
.calendar-cell {
    border-radius: 12px !important;
    min-height: 100px;
    padding: 16px !important;
}

/* Fix SIM cards - normalized sizes */
.sim-card {
    border-radius: 16px !important;
    padding: 16px !important;
    min-height: auto !important;
}

/* Fix SIM card header alignment */
.sim-card-header {
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    margin-bottom: 12px !important;
    gap: 10px !important;
}

.sim-info-left {
    display: flex !important;
    align-items: center !important;
    gap: 10px !important;
    flex: 1 !important;
    min-width: 0 !important;
}

.sim-details {
    min-width: 0;
    flex: 1;
}

/* Fix SIM number and carrier text */
.sim-number {
    font-size: 14px !important;
    font-weight: 700 !important;
    line-height: 1.2 !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
}

.sim-carrier {
    font-size: 10px !important;
    color: var(--text-muted) !important;
    margin-top: 1px !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
}

/* Fix carrier logo - compact */
.carrier-logo {
    min-width: 36px !important;
    min-height: 36px !important;
    width: 36px !important;
    height: 36px !important;
    font-size: 13px !important;
    border-radius: 9px !important;
    flex-shrink: 0 !important;
}

/* Fix status badge */
.sim-status {
    white-space: nowrap !important;
    padding: 4px 8px !important;
    font-size: 10px !important;
    font-weight: 700 !important;
    gap: 6px !important;
    flex-shrink: 0 !important;
}

.sim-status .status-dot {
    width: 6px !important;
    height: 6px !important;
}

/* Fix card body */
.sim-card-body {
    margin-bottom: 12px !important;
}

/* Fix progress bar */
.progress-bar {
    height: 5px !important;
    border-radius: 3px !important;
    margin-bottom: 6px !important;
}

/* Progress info row */
.progress-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
    font-size: 10px;
    line-height: 1.2;
}

.progress-days {
    color: var(--text-muted);
    font-weight: 500;
}

.progress-status {
    font-weight: 600;
}

.progress-status.normal {
    color: #10b981;
}

.progress-status.warning {
    color: #f59e0b;
}

.progress-status.critical {
    color: #ef4444;
}

/* Fix footer layout */
.sim-card-footer {
    display: flex !important;
    gap: 6px !important;
    margin-top: 0 !important;
}

.sim-card-footer .btn-toggle {
    flex: 1 !important;
    padding: 8px 10px !important;
    font-size: 11px !important;
}

.sim-card-footer .btn-icon {
    padding: 8px !important;
    font-size: 12px !important;
    min-width: 32px !important;
}

/* Fix button text overflow */
.btn-toggle {
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
}

/* ================================================
   📊 STATUS VISUALIZATION SECTION
   ================================================ */

.status-viz-section {
    margin-bottom: 28px;
}

.viz-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
}

@media (max-width: 900px) {
    .viz-grid {
        grid-template-columns: 1fr;
    }
}

.viz-card {
    background: linear-gradient(145deg, rgba(20, 20, 35, 0.95), rgba(15, 15, 28, 0.98));
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 20px;
    padding: 28px;
    position: relative;
    overflow: hidden;
}

.viz-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #7c3aed, #06b6d4);
}

.viz-title {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 24px;
    color: #f8fafc;
}

.viz-title svg {
    color: #a78bfa;
}

/* Ring Chart */
.ring-chart-container {
    position: relative;
    width: 180px;
    height: 180px;
    margin: 0 auto 24px;
}

.ring-chart {
    width: 100%;
    height: 100%;
    transform: rotate(-90deg);
}

.ring-center {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
}

.ring-percent {
    display: block;
    font-size: 36px;
    font-weight: 800;
    background: linear-gradient(135deg, #10b981, #34d399);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.ring-label {
    font-size: 12px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.ring-legend {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.ring-legend-item {
    display: flex;
    align-items: center;
    gap: 12px;
}

.legend-color {
    width: 12px;
    height: 12px;
    border-radius: 4px;
    flex-shrink: 0;
}

.legend-color.healthy {
    background: linear-gradient(135deg, #10b981, #34d399);
}

.legend-color.warning {
    background: linear-gradient(135deg, #f59e0b, #fbbf24);
}

.legend-color.critical {
    background: linear-gradient(135deg, #ef4444, #f87171);
}

.legend-text {
    flex: 1;
    font-size: 13px;
    color: var(--text-muted);
}

.legend-count {
    font-size: 14px;
    font-weight: 700;
    color: #f8fafc;
    background: rgba(255, 255, 255, 0.05);
    padding: 4px 10px;
    border-radius: 6px;
}

/* Quick Actions */
.quick-actions-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
}

.quick-action-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
    color: var(--text-light);
    font-size: 13px;
    font-weight: 600;
}

.quick-action-btn:hover {
    background: rgba(124, 58, 237, 0.15);
    border-color: rgba(124, 58, 237, 0.3);
    transform: translateY(-4px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.action-icon {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    border-radius: 12px;
}

.action-icon.warning {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.2), rgba(245, 158, 11, 0.1));
}

.action-icon.critical {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.2), rgba(239, 68, 68, 0.1));
}

.action-icon.active {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.2), rgba(16, 185, 129, 0.1));
}

.action-icon.all {
    background: linear-gradient(135deg, rgba(124, 58, 237, 0.2), rgba(124, 58, 237, 0.1));
}

/* ================================================
   HIDE VISUALIZATION SECTIONS
   ================================================ */

.status-viz-section,
.viz-grid,
.viz-card,
.ring-chart-container,
.quick-actions-grid {
    display: none !important;
}

/* ================================================
   COMPACT SIM CARDS - FIXED SIZING
   ================================================ */

.sim-grid {
    display: grid !important;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)) !important;
    gap: 16px !important;
}

.sim-card {
    padding: 18px !important;
    border-radius: 14px !important;
    display: flex !important;
    flex-direction: column !important;
    height: 100% !important;
    min-height: 170px !important;
    background: linear-gradient(145deg, rgba(26, 30, 46, 0.96), rgba(16, 18, 28, 0.98)) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.06) !important;
}

.sim-card::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(140px 120px at 85% -10%, rgba(255, 255, 255, 0.12), transparent 60%);
    opacity: 0.75;
    pointer-events: none;
}

.sim-card.status-on {
    border-color: rgba(16, 185, 129, 0.35) !important;
    box-shadow: 0 14px 32px rgba(16, 185, 129, 0.15), inset 0 1px 0 rgba(255, 255, 255, 0.06) !important;
}

.sim-card.status-off {
    border-color: rgba(148, 163, 184, 0.25) !important;
}

.sim-card.warning {
    border-color: rgba(245, 158, 11, 0.35) !important;
}

.sim-card.critical {
    border-color: rgba(239, 68, 68, 0.35) !important;
}

.sim-card:hover {
    transform: translateY(-6px) !important;
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.45), 0 0 24px rgba(124, 58, 237, 0.2) !important;
}

.sim-card-header {
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    margin-bottom: 14px !important;
    gap: 10px !important;
}

.sim-info-left {
    display: flex !important;
    align-items: center !important;
    gap: 10px !important;
    flex: 1 !important;
    min-width: 0 !important;
}

.sim-details {
    min-height: 34px !important;
}

.carrier-logo {
    width: 40px !important;
    height: 40px !important;
    min-width: 40px !important;
    min-height: 40px !important;
    font-size: 14px !important;
    border-radius: 10px !important;
    flex-shrink: 0 !important;
    box-shadow: 0 6px 14px rgba(0, 0, 0, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.2) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
}

.sim-number {
    font-size: 15px !important;
    font-weight: 700 !important;
    line-height: 1.3 !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
}

.sim-carrier {
    font-size: 11px !important;
    color: var(--text-muted) !important;
    margin-top: 2px !important;
    text-transform: uppercase !important;
    letter-spacing: 0.3px !important;
}

.sim-status {
    padding: 5px 10px !important;
    font-size: 10px !important;
    font-weight: 700 !important;
    gap: 6px !important;
    border-radius: 20px !important;
    white-space: nowrap !important;
    flex-shrink: 0 !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    background: rgba(255, 255, 255, 0.06) !important;
}

.sim-status .status-dot {
    width: 6px !important;
    height: 6px !important;
    box-shadow: 0 0 10px currentColor !important;
}

.sim-card-body {
    margin-bottom: 14px !important;
    flex: 1 !important;
}

.progress-bar {
    height: 6px !important;
    border-radius: 3px !important;
    margin-bottom: 8px !important;
    background: rgba(255, 255, 255, 0.09) !important;
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.45) !important;
}

.progress-info {
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    font-size: 11px !important;
}

.progress-days {
    font-size: 11px !important;
    font-weight: 500 !important;
}

.progress-status {
    font-size: 11px !important;
    font-weight: 600 !important;
}

.sim-card-footer {
    display: flex !important;
    gap: 8px !important;
    margin-top: auto !important;
}

.sim-card-footer .btn-toggle {
    flex: 1 !important;
    padding: 10px 14px !important;
    font-size: 11px !important;
    font-weight: 700 !important;
    border-radius: 8px !important;
}

.sim-card-footer .btn-icon {
    padding: 10px !important;
    font-size: 14px !important;
    min-width: 38px !important;
    border-radius: 8px !important;
}
