/* ============================================================
   SMOOTHMATHS - UNIFIED DESIGN SYSTEM v2.0
   Brand Colors: #09CAE9 (Cyan) + White
   Modern, Clean, Professional Design
   Created: October 2025
============================================================ */

:root {
    /* Primary Brand Colors */
    --sm-cyan: #09CAE9;
    --sm-cyan-dark: #07A8C3;
    --sm-cyan-light: #4DD9F2;
    --sm-cyan-lighter: #D4F4FC;
    --sm-white: #FFFFFF;
    
    /* Supporting Colors */
    --sm-success: #10B981;
    --sm-danger: #EF4444;
    --sm-warning: #F59E0B;
    
    /* Grayscale */
    --sm-gray-50: #F9FAFB;
    --sm-gray-100: #F3F4F6;
    --sm-gray-200: #E5E7EB;
    --sm-gray-300: #D1D5DB;
    --sm-gray-500: #6B7280;
    --sm-gray-700: #374151;
    --sm-gray-900: #111827;
    
    /* Shadows */
    --sm-shadow: 0 2px 8px rgba(9, 202, 233, 0.15);
    --sm-shadow-lg: 0 8px 24px rgba(9, 202, 233, 0.2);
    --sm-shadow-xl: 0 12px 32px rgba(9, 202, 233, 0.25);
    
    /* Border Radius */
    --sm-radius: 12px;
    --sm-radius-lg: 16px;
    --sm-radius-xl: 20px;
}

/* ============================================================
   GLOBAL RESETS & BASE STYLES
============================================================ */

.smoothmaths-dashboard-welcome,
.smoothmaths-dashboard-products,
.smoothmaths-unified-payments {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: var(--sm-gray-900);
}

/* ============================================================
   WELCOME SECTION
============================================================ */

.smoothmaths-dashboard-welcome {
    background: linear-gradient(135deg, var(--sm-cyan) 0%, var(--sm-cyan-dark) 100%);
    padding: 40px 30px;
    border-radius: var(--sm-radius-xl);
    margin: 0 0 30px 0;
    box-shadow: var(--sm-shadow-lg);
    color: var(--sm-white);
    position: relative;
    overflow: hidden;
}

.smoothmaths-dashboard-welcome::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
    border-radius: 50%;
    transform: translate(100px, -100px);
}

.smoothmaths-dashboard-welcome .welcome-container {
    position: relative;
    z-index: 1;
    max-width: 800px;
}

.smoothmaths-dashboard-welcome h2,
.smoothmaths-dashboard-welcome h3 {
    margin: 0 0 15px 0;
    font-weight: 700;
    color: var(--sm-white);
    text-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.smoothmaths-dashboard-welcome h2 {
    font-size: 36px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.smoothmaths-dashboard-welcome h3 {
    font-size: 28px;
}

.smoothmaths-dashboard-welcome p {
    margin: 0 0 10px 0;
    font-size: 18px;
    opacity: 0.95;
}

.smoothmaths-dashboard-welcome .welcome-icon {
    font-size: 42px;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.2));
}

.smoothmaths-dashboard-welcome .user-info {
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    padding: 15px 20px;
    border-radius: var(--sm-radius);
    margin-top: 20px;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.smoothmaths-dashboard-welcome .user-info p {
    margin: 0;
    font-size: 16px;
}

/* ============================================================
   PRODUCTS SECTION
============================================================ */

.smoothmaths-dashboard-products {
    background: var(--sm-white);
    padding: 30px;
    border-radius: var(--sm-radius-xl);
    box-shadow: var(--sm-shadow);
    margin: 0 0 30px 0;
}

.smoothmaths-dashboard-products > h3 {
    margin: 0 0 25px 0;
    font-size: 28px;
    font-weight: 700;
    color: var(--sm-gray-900);
    padding-bottom: 15px;
    border-bottom: 3px solid var(--sm-cyan);
    display: flex;
    align-items: center;
    gap: 12px;
}

.smoothmaths-dashboard-products .products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 24px;
}

.smoothmaths-dashboard-products .product-card {
    background: var(--sm-white);
    border: 2px solid var(--sm-gray-200);
    border-radius: var(--sm-radius-lg);
    overflow: hidden;
    transition: all 0.3s ease;
    position: relative;
}

.smoothmaths-dashboard-products .product-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--sm-shadow-lg);
    border-color: var(--sm-cyan);
}

.smoothmaths-dashboard-products .product-header {
    background: linear-gradient(135deg, var(--sm-cyan) 0%, var(--sm-cyan-dark) 100%);
    color: var(--sm-white);
    padding: 20px;
    position: relative;
}

.smoothmaths-dashboard-products .product-header h5 {
    margin: 0 0 8px 0;
    font-size: 20px;
    font-weight: 600;
    color: var(--sm-white);
}

.smoothmaths-dashboard-products .product-status {
    background: rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(10px);
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    display: inline-block;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.smoothmaths-dashboard-products .product-content {
    padding: 24px;
}

.smoothmaths-dashboard-products .material-section {
    margin-bottom: 20px;
}

.smoothmaths-dashboard-products .material-section:last-child {
    margin-bottom: 0;
}

.smoothmaths-dashboard-products .material-section h6 {
    margin: 0 0 12px 0;
    font-size: 16px;
    font-weight: 600;
    color: var(--sm-gray-900);
    display: flex;
    align-items: center;
    gap: 8px;
}

.smoothmaths-dashboard-products .materials-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.smoothmaths-dashboard-products .material-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    background: var(--sm-gray-50);
    border: 1px solid var(--sm-gray-200);
    border-radius: var(--sm-radius);
    text-decoration: none;
    color: var(--sm-gray-900);
    transition: all 0.2s ease;
    font-size: 14px;
    font-weight: 500;
}

.smoothmaths-dashboard-products .material-link:hover {
    background: var(--sm-cyan-lighter);
    border-color: var(--sm-cyan);
    color: var(--sm-cyan-dark);
    transform: translateX(4px);
}

.smoothmaths-dashboard-products .material-link .material-icon {
    font-size: 18px;
    opacity: 0.7;
}

.smoothmaths-dashboard-products .no-products {
    text-align: center;
    padding: 60px 20px;
    background: var(--sm-gray-50);
    border-radius: var(--sm-radius-lg);
    border: 2px dashed var(--sm-gray-300);
}

.smoothmaths-dashboard-products .no-products-icon {
    font-size: 64px;
    opacity: 0.3;
    margin-bottom: 16px;
}

.smoothmaths-dashboard-products .no-products h4 {
    margin: 0 0 10px 0;
    font-size: 20px;
    color: var(--sm-gray-700);
}

.smoothmaths-dashboard-products .no-products p {
    margin: 0;
    color: var(--sm-gray-500);
    font-size: 16px;
}

/* ============================================================
   PAYMENT METHODS SECTION
============================================================ */

.smoothmaths-unified-payments {
    background: var(--sm-white);
    padding: 30px;
    border-radius: var(--sm-radius-xl);
    box-shadow: var(--sm-shadow);
    margin: 0 0 30px 0;
}

.smoothmaths-unified-payments .payment-methods-section {
    margin-bottom: 30px;
}

.smoothmaths-unified-payments .payment-methods-title {
    margin: 0 0 25px 0;
    font-size: 28px;
    font-weight: 700;
    color: var(--sm-gray-900);
    padding-bottom: 15px;
    border-bottom: 3px solid var(--sm-cyan);
    display: flex;
    align-items: center;
    gap: 12px;
}

.smoothmaths-unified-payments .payment-methods-count {
    background: var(--sm-cyan-lighter);
    color: var(--sm-cyan-dark);
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
    margin-left: auto;
}

.smoothmaths-unified-payments .payment-methods-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 24px;
}

.smoothmaths-unified-payments .payment-method-card {
    background: var(--sm-white);
    border: 2px solid var(--sm-gray-200);
    border-radius: var(--sm-radius-lg);
    padding: 24px;
    position: relative;
    transition: all 0.3s ease;
    overflow: hidden;
}

.smoothmaths-unified-payments .payment-method-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, var(--sm-cyan) 0%, var(--sm-cyan-dark) 100%);
}

.smoothmaths-unified-payments .payment-method-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--sm-shadow-lg);
    border-color: var(--sm-cyan);
}

.smoothmaths-unified-payments .payment-method-default-badge {
    position: absolute;
    top: 16px;
    right: 16px;
    background: var(--sm-success);
    color: var(--sm-white);
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.smoothmaths-unified-payments .payment-method-header {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 20px;
}

.smoothmaths-unified-payments .payment-method-icon {
    font-size: 32px;
    flex-shrink: 0;
}

.smoothmaths-unified-payments .payment-method-info h4 {
    margin: 0 0 6px 0;
    font-size: 18px;
    font-weight: 600;
    color: var(--sm-gray-900);
}

.smoothmaths-unified-payments .payment-method-number {
    margin: 0;
    font-family: var(--sm-font-mono, 'Courier New', monospace);
    font-size: 16px;
    color: var(--sm-gray-500);
    letter-spacing: 1px;
}

.smoothmaths-unified-payments .payment-method-card p {
    margin: 10px 0;
    font-size: 14px;
    color: var(--sm-gray-700);
}

.smoothmaths-unified-payments .payment-method-card p strong {
    color: var(--sm-gray-900);
    font-weight: 600;
}

.smoothmaths-unified-payments .payment-method-card > div[style*="margin-top: 20px"] {
    margin-top: 20px !important;
    padding-top: 20px;
    border-top: 1px solid var(--sm-gray-200);
    display: flex !important;
    gap: 10px !important;
    flex-wrap: wrap !important;
}

.smoothmaths-unified-payments .payment-method-card button {
    padding: 10px 20px !important;
    border: none !important;
    border-radius: var(--sm-radius) !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    cursor: pointer !important;
    transition: all 0.2s ease !important;
    font-family: inherit !important;
}

.smoothmaths-unified-payments .payment-method-card button[style*="background: #007cba"] {
    background: var(--sm-cyan) !important;
    color: var(--sm-white) !important;
}

.smoothmaths-unified-payments .payment-method-card button[style*="background: #007cba"]:hover {
    background: var(--sm-cyan-dark) !important;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(9, 202, 233, 0.3);
}

.smoothmaths-unified-payments .payment-method-card button[style*="background: #dc3545"] {
    background: var(--sm-danger) !important;
    color: var(--sm-white) !important;
}

.smoothmaths-unified-payments .payment-method-card button[style*="background: #dc3545"]:hover {
    background: #DC2626 !important;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.3);
}

/* No Payment Methods State */
.smoothmaths-unified-payments > div[style*="text-align: center"][style*="padding: 60px"] {
    background: var(--sm-gray-50) !important;
    border: 2px dashed var(--sm-gray-300) !important;
    border-radius: var(--sm-radius-lg) !important;
}

/* Add Payment Method Form */
.smoothmaths-unified-payments > div[style*="border: 3px solid #28a745"] {
    background: linear-gradient(135deg, var(--sm-cyan-lighter), var(--sm-white)) !important;
    border: 2px solid var(--sm-cyan) !important;
    border-radius: var(--sm-radius-lg) !important;
    padding: 30px !important;
}

.smoothmaths-unified-payments > div[style*="border: 3px solid #28a745"] h3 {
    color: var(--sm-gray-900) !important;
}

.smoothmaths-unified-payments div[style*="background: #e3f2fd"] {
    background: var(--sm-cyan-lighter) !important;
    border: 1px solid var(--sm-cyan) !important;
}

.smoothmaths-unified-payments div[style*="background: #e3f2fd"] p {
    color: var(--sm-cyan-dark) !important;
}

.smoothmaths-unified-payments a[style*="background: #2196f3"] {
    background: var(--sm-cyan) !important;
    transition: all 0.2s ease;
}

.smoothmaths-unified-payments a[style*="background: #2196f3"]:hover {
    background: var(--sm-cyan-dark) !important;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(9, 202, 233, 0.3);
}

/* ============================================================
   RESPONSIVE DESIGN
============================================================ */

@media (max-width: 768px) {
    .smoothmaths-dashboard-welcome {
        padding: 30px 20px;
    }
    
    .smoothmaths-dashboard-welcome h2 {
        font-size: 28px;
    }
    
    .smoothmaths-dashboard-welcome h3 {
        font-size: 22px;
    }
    
    .smoothmaths-dashboard-products .products-grid,
    .smoothmaths-unified-payments .payment-methods-grid {
        grid-template-columns: 1fr;
    }
    
    .smoothmaths-dashboard-products,
    .smoothmaths-unified-payments {
        padding: 20px;
    }
}

@media (max-width: 480px) {
    .smoothmaths-dashboard-welcome h2 {
        font-size: 24px;
        flex-direction: column;
        text-align: center;
    }
    
    .smoothmaths-dashboard-products > h3,
    .smoothmaths-unified-payments .payment-methods-title {
        font-size: 22px;
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .smoothmaths-unified-payments .payment-methods-count {
        margin-left: 0;
    }
}

/* ============================================================
   UTILITY CLASSES
============================================================ */

.sm-fade-in {
    animation: smoothMathsFadeIn 0.5s ease-in-out;
}

@keyframes smoothMathsFadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.sm-pulse {
    animation: smoothMathsPulse 2s ease-in-out infinite;
}

@keyframes smoothMathsPulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.7;
    }
}
