/* ========================================
   WhatsApp Pro - Master Stylesheet
   Complete CSS Framework
   ======================================== */

/* === RESET === */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    height: 100%;
    overflow-x: hidden;
}

/* === BODY & BACKGROUND === */
body {
    font-family: 'Cairo', sans-serif;
    background: #e8f5e9;
    color: #2e7d32;
    direction: rtl;
    line-height: 1.6;
}

/* === ANIMATED BACKGROUND WAVES === */
.wave {
    position: fixed;
    width: 200%;
    height: 200%;
    top: -50%;
    left: -50%;
    z-index: -1;
    opacity: 0.3;
}

.wave1 {
    background: radial-gradient(circle, #c8e6c9 0%, transparent 70%);
    animation: wave1 15s linear infinite;
}

.wave2 {
    background: radial-gradient(circle, #a5d6a7 0%, transparent 60%);
    animation: wave2 20s linear infinite reverse;
}

.wave3 {
    background: radial-gradient(circle, #81c784 0%, transparent 50%);
    animation: wave3 25s linear infinite;
}

@keyframes wave1 {
    0% { transform: rotate(0deg) translateX(0); }
    100% { transform: rotate(360deg) translateX(50px); }
}

@keyframes wave2 {
    0% { transform: rotate(0deg) translateY(0); }
    100% { transform: rotate(-360deg) translateY(-50px); }
}

@keyframes wave3 {
    0% { transform: rotate(0deg) translate(0, 0); }
    100% { transform: rotate(360deg) translate(30px, 30px); }
}

/* === SIDEBAR === */
.sidebar {
    position: fixed;
    right: 0;
    top: 0;
    width: 280px;
    height: 100vh;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: -4px 0 20px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    display: flex;
    flex-direction: column;
    transition: transform 0.3s ease;
}

.sidebar-header {
    padding: 24px;
    border-bottom: 1px solid rgba(200, 230, 201, 0.3);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 22px;
    font-weight: 700;
    color: #25D366;
}

.logo i {
    font-size: 32px;
}

.sidebar-toggle {
    background: none;
    border: none;
    font-size: 20px;
    color: #2e7d32;
    cursor: pointer;
    display: none;
}

.sidebar-nav {
    flex: 1;
    padding: 16px 0;
    overflow-y: auto;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 24px;
    color: #2e7d32;
    text-decoration: none;
    transition: all 0.3s;
    font-weight: 500;
    font-size: 15px;
    margin: 4px 12px;
    border-radius: 10px;
}

.nav-item:hover {
    background: rgba(37, 211, 102, 0.1);
    color: #25D366;
    transform: translateX(-4px);
}

.nav-item.active {
    background: linear-gradient(135deg, #25D366, #128C7E);
    color: white;
    box-shadow: 0 4px 12px rgba(37, 211, 102, 0.3);
}

.nav-item i {
    width: 20px;
    text-align: center;
    font-size: 18px;
}

.sidebar-footer {
    padding: 20px;
    border-top: 1px solid rgba(200, 230, 201, 0.3);
}

.user-info {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px;
    background: rgba(200, 230, 201, 0.2);
    border-radius: 8px;
    margin-bottom: 12px;
    font-weight: 500;
}

.user-info i {
    font-size: 24px;
    color: #25D366;
}

.logout-btn {
    width: 100%;
    padding: 12px;
    background: linear-gradient(135deg, #ef5350, #e53935);
    border: none;
    border-radius: 8px;
    color: white;
    font-family: 'Cairo', sans-serif;
    font-weight: 600;
    font-size: 15px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.3s;
}

.logout-btn:hover {
    box-shadow: 0 4px 12px rgba(239, 83, 80, 0.4);
    transform: translateY(-2px);
}

/* === MAIN CONTENT === */
.main-content {
    margin-right: 280px;
    padding: 30px;
    min-height: 100vh;
}

/* === PAGE HEADER === */
.page-header {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    padding: 28px;
    border-radius: 16px;
    margin-bottom: 30px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.page-header h1 {
    font-size: 28px;
    color: #2e7d32;
    margin-bottom: 6px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.page-header h1 i {
    color: #25D366;
}

.page-subtitle {
    color: #66bb6a;
    font-size: 15px;
}

/* === GLASS CARD === */
.glass-card {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 16px;
    padding: 24px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    border: 1px solid rgba(200, 230, 201, 0.3);
    transition: all 0.3s ease;
}

.glass-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

/* === STATS GRID === */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    padding: 24px;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    display: flex;
    align-items: center;
    gap: 16px;
    transition: all 0.3s;
    border: 1px solid rgba(200, 230, 201, 0.3);
}

.stat-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

.stat-icon {
    width: 60px;
    height: 60px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 26px;
    color: white;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    flex-shrink: 0;
}

.stat-content {
    flex: 1;
}

.stat-number {
    font-size: 32px;
    font-weight: 700;
    color: #2e7d32;
    line-height: 1;
    margin-bottom: 6px;
}

.stat-label {
    color: #66bb6a;
    font-size: 14px;
    font-weight: 500;
}

/* === CAMPAIGNS === */
.campaigns-section {
    margin-bottom: 30px;
}

.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
}

.section-header h2 {
    font-size: 22px;
    color: #2e7d32;
    display: flex;
    align-items: center;
    gap: 10px;
}

.campaigns-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

.campaign-card {
    background: rgba(255, 255, 255, 0.95);
    padding: 20px;
    border-radius: 14px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
    transition: all 0.3s;
}

.campaign-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 6px 24px rgba(0, 0, 0, 0.12);
}

.campaign-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid rgba(200, 230, 201, 0.3);
}

.campaign-header h3 {
    font-size: 18px;
    color: #2e7d32;
    margin: 0;
}

.campaign-status {
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}

.campaign-status.active {
    background: rgba(37, 211, 102, 0.15);
    color: #128C7E;
}

.campaign-status.completed {
    background: rgba(158, 158, 158, 0.15);
    color: #757575;
}

.campaign-body {
    margin-bottom: 16px;
}

.campaign-stat {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
    color: #66bb6a;
    font-size: 14px;
}

.campaign-stat i {
    width: 16px;
    color: #25D366;
}

.campaign-footer {
    display: flex;
    gap: 10px;
}

/* === QUICK ACTIONS === */
.quick-actions {
    margin-bottom: 30px;
}

.quick-actions h2 {
    font-size: 22px;
    color: #2e7d32;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.actions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
}

.action-card {
    background: rgba(255, 255, 255, 0.95);
    padding: 24px;
    border-radius: 14px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
    text-align: center;
    text-decoration: none;
    color: #2e7d32;
    transition: all 0.3s;
    border: 1px solid rgba(200, 230, 201, 0.3);
}

.action-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.15);
    border-color: #25D366;
}

.action-card i {
    font-size: 40px;
    color: #25D366;
    margin-bottom: 12px;
    display: block;
}

.action-card h3 {
    font-size: 18px;
    margin-bottom: 8px;
    color: #2e7d32;
}

.action-card p {
    color: #66bb6a;
    font-size: 14px;
}

/* === BUTTONS === */
.btn {
    padding: 12px 24px;
    border: none;
    border-radius: 10px;
    font-family: 'Cairo', sans-serif;
    font-weight: 600;
    font-size: 15px;
    cursor: pointer;
    transition: all 0.3s;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    justify-content: center;
}

.btn-primary {
    background: linear-gradient(135deg, #25D366, #128C7E);
    color: white;
    box-shadow: 0 4px 12px rgba(37, 211, 102, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(37, 211, 102, 0.4);
}

.btn-success {
    background: linear-gradient(135deg, #66bb6a, #43a047);
    color: white;
    box-shadow: 0 4px 12px rgba(102, 187, 106, 0.3);
}

.btn-success:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(102, 187, 106, 0.4);
}

.btn-info {
    background: linear-gradient(135deg, #4fc3f7, #0288d1);
    color: white;
    box-shadow: 0 4px 12px rgba(79, 195, 247, 0.3);
}

.btn-info:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(79, 195, 247, 0.4);
}

.btn-sm {
    padding: 8px 16px;
    font-size: 13px;
}

.btn-block {
    width: 100%;
    display: flex;
}

/* === FORMS === */
.form-group {
    margin-bottom: 20px;
}

.form-control {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid rgba(200, 230, 201, 0.5);
    border-radius: 10px;
    font-family: 'Cairo', sans-serif;
    font-size: 15px;
    background: white;
    color: #2e7d32;
    transition: all 0.3s;
}

.form-control:focus {
    outline: none;
    border-color: #25D366;
    box-shadow: 0 0 0 4px rgba(37, 211, 102, 0.1);
}

textarea.form-control {
    resize: vertical;
    min-height: 100px;
}

select.form-control {
    cursor: pointer;
}

/* === CHECK METHODS === */
.check-methods {
    margin-bottom: 30px;
}

.methods-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

.method-card {
    background: rgba(255, 255, 255, 0.95);
    padding: 24px;
    border-radius: 14px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
}

.method-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
    padding-bottom: 16px;
    border-bottom: 2px solid rgba(200, 230, 201, 0.3);
}

.method-header i {
    font-size: 24px;
    color: #25D366;
}

.method-header h3 {
    font-size: 18px;
    color: #2e7d32;
    margin: 0;
}

.upload-area {
    border: 2px dashed rgba(200, 230, 201, 0.6);
    border-radius: 10px;
    padding: 40px 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
    background: rgba(200, 230, 201, 0.1);
}

.upload-area:hover {
    border-color: #25D366;
    background: rgba(37, 211, 102, 0.1);
}

.upload-area i {
    font-size: 48px;
    color: #25D366;
    margin-bottom: 12px;
    display: block;
}

.upload-area p {
    color: #66bb6a;
    font-size: 14px;
}

/* === LOADING & EMPTY STATES === */
.loading-spinner {
    text-align: center;
    padding: 40px;
    color: #66bb6a;
}

.loading-spinner i {
    font-size: 40px;
    margin-bottom: 12px;
    color: #25D366;
}

.empty-state {
    text-align: center;
    padding: 40px;
    color: #66bb6a;
    font-size: 15px;
}

.empty-state a {
    color: #25D366;
    text-decoration: underline;
}

.error-state {
    text-align: center;
    padding: 40px;
    color: #ef5350;
    font-size: 15px;
}

/* === ACTIVE TASKS & HISTORY === */
.active-tasks,
.check-history {
    margin-bottom: 30px;
}

.active-tasks h2,
.check-history h2 {
    font-size: 22px;
    color: #2e7d32;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

/* === RESPONSIVE === */
@media (max-width: 1024px) {
    .sidebar {
        transform: translateX(100%);
    }
    
    .sidebar.active {
        transform: translateX(0);
    }
    
    .sidebar-toggle {
        display: block;
    }
    
    .main-content {
        margin-right: 0;
    }
}

@media (max-width: 768px) {
    .main-content {
        padding: 20px;
    }
    
    .stats-grid,
    .campaigns-grid,
    .actions-grid,
    .methods-grid {
        grid-template-columns: 1fr;
    }
    
    .page-header h1 {
        font-size: 22px;
    }
    
    .stat-number {
        font-size: 26px;
    }
}

@media (max-width: 480px) {
    .sidebar {
        width: 100%;
    }
    
    .glass-card {
        padding: 16px;
    }
    
    .stat-card {
        padding: 16px;
    }
    
    .btn {
        padding: 10px 20px;
        font-size: 14px;
    }
}

/* === UTILITY CLASSES === */
.text-center { text-align: center; }
.mb-0 { margin-bottom: 0; }
.mb-1 { margin-bottom: 8px; }
.mb-2 { margin-bottom: 16px; }
.mb-3 { margin-bottom: 24px; }
.mt-0 { margin-top: 0; }
.mt-1 { margin-top: 8px; }
.mt-2 { margin-top: 16px; }
.mt-3 { margin-top: 24px; }
