:root {
    --primary: #3370FF;
    --primary-light: #5A8CFF;
    --primary-gradient: linear-gradient(135deg, #4A84FF, #2358D8);
    --bg-color: #F4F8FB;
    --bg-waves: #eaf1fb;
    --text-dark: #1E293B;
    --text-muted: #64748B;
    --text-light: #94A3B8;
    --card-bg: rgba(255, 255, 255, 0.85);
    --card-shadow: 0 4px 20px rgba(47, 85, 151, 0.08);
    --hover-shadow: 0 12px 30px rgba(47, 85, 151, 0.12);
    --border-color: #E2E8F0;
    
    --success: #10B981;
    --warning: #F59E0B;
    --info: #3B82F6;
    
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 20px;
    --radius-xl: 24px;
}

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

body {
    font-family: 'Inter', sans-serif;
    color: var(--text-dark);
    background-color: var(--bg-color);
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1440 800' preserveAspectRatio='none'%3E%3Cpath fill='%23eaf1fc' fill-opacity='0.5' d='M0,256L48,261.3C96,267,192,277,288,272C384,267,480,245,576,234.7C672,224,768,224,864,250.7C960,277,1056,331,1152,330.7C1248,331,1344,277,1392,250.7L1440,224L1440,800L1392,800C1344,800,1248,800,1152,800C1056,800,960,800,864,800C768,800,672,800,576,800C480,800,384,800,288,800C192,800,96,800,48,800L0,800Z'%3E%3C/path%3E%3Cpath fill='%23dfeafe' fill-opacity='0.4' d='M0,448L48,426.7C96,405,192,363,288,368C384,373,480,427,576,432C672,437,768,395,864,368C960,341,1056,331,1152,346.7C1248,363,1344,405,1392,426.7L1440,448L1440,800L1392,800C1344,800,1248,800,1152,800C1056,800,960,800,864,800C768,800,672,800,576,800C480,800,384,800,288,800C192,800,96,800,48,800L0,800Z'%3E%3C/path%3E%3C/svg%3E");
    background-size: cover;
    background-attachment: fixed;
    min-height: 100vh;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
}

ul {
    list-style: none;
}

/* Typography */
h1 { font-size: 32px; font-weight: 800; color: var(--text-dark); letter-spacing: -0.5px; }
h2 { font-size: 36px; font-weight: 800; color: #fff; }
h3.section-title { font-size: 18px; font-weight: 600; margin-bottom: 16px; color: var(--text-dark); }
h4 { font-size: 16px; font-weight: 600; }
p { color: var(--text-muted); font-size: 14px; line-height: 1.5; }

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 20px;
    border-radius: var(--radius-md);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    outline: none;
}

.btn-sm { padding: 8px 16px; font-size: 13px; }
.btn-block { width: 100%; }

.btn-primary {
    background: var(--primary-gradient);
    color: #fff;
    box-shadow: 0 4px 12px rgba(51, 112, 255, 0.3);
}

.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(51, 112, 255, 0.4);
}

.btn-primary-outline {
    background: transparent;
    color: var(--primary);
    border: 2px solid var(--primary);
}
.btn-primary-outline:hover {
    background: rgba(51, 112, 255, 0.05);
}

.justify-between { justify-content: space-between; }

/* Icons */
.material-icons-round { font-size: 20px; }
.text-blue-custom { color: var(--primary); }
.text-light-blue-custom { color: #0EA5E9; }




.text-green-custom { color: #10B981; }
.text-yellow-custom { color: #F59E0B; }

/* Layout */
.app-layout {
    max-width: 1300px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.avatar { width: 36px; height: 36px; border-radius: 50%; object-fit: cover; }
.avatar-lg { width: 48px; height: 48px; border-radius: 50%; object-fit: cover; }


/* Main Container */
.main-container {
    display: flex;
    gap: 32px;
    flex: 1 0 auto;
    padding-bottom: 40px;
}

/* Sidebar */
.sidebar {
    width: 260px;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.sidebar-user-card {
    background: var(--card-bg);
    backdrop-filter: blur(10px);
    border-radius: var(--radius-lg);
    padding: 24px;
    box-shadow: var(--card-shadow);
    border: 1px solid rgba(255,255,255,0.6);
}

.user-info {
    display: flex;
    align-items: center;
    gap: 16px;
}

.user-details h4 { margin-bottom: 4px; }
.user-details p { font-size: 13px; }

.sidebar-nav-header {
    padding: 0 16px 20px 16px;
    margin-bottom: 8px;
    border-bottom: 2px solid var(--bg-waves);
}

.btn-premium-nav {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    background: var(--primary-gradient);
    color: #fff !important;
    padding: 14px 20px;
    border-radius: var(--radius-md);
    font-weight: 700;
    font-size: 15px;
    box-shadow: 0 8px 16px rgba(51, 112, 255, 0.25);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    width: 100%;
    margin-top: 8px;
}

.btn-premium-nav i {
    font-size: 20px;
}

.btn-premium-nav:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 16px rgba(51, 112, 255, 0.3);
    filter: brightness(1.05);
}

.btn-premium-nav.disabled {
    background: var(--text-light);
    opacity: 0.6;
    cursor: not-allowed;
    pointer-events: none;
    box-shadow: none;
    transform: none;
    filter: grayscale(1);
}

.sidebar-nav {
    background: var(--card-bg);
    backdrop-filter: blur(10px);
    border-radius: var(--radius-lg);
    padding: 16px 0;
    box-shadow: var(--card-shadow);
    border: 1px solid rgba(255,255,255,0.6);
}

.sidebar-nav ul li a {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 12px 24px;
    font-weight: 500;
    color: var(--text-dark);
    transition: background 0.2s;
}

.sidebar-nav ul li a:hover, .sidebar-nav ul li.active a {
    background: rgba(51, 112, 255, 0.08);
}

.sidebar-nav ul li.active a span { color: var(--primary); font-weight: 600; }

.icon-box {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.icon-blue { background: rgba(51, 112, 255, 0.1); color: var(--primary); }
.icon-light-blue { background: rgba(14, 165, 233, 0.1); color: #0EA5E9; }
.icon-green { background: rgba(16, 185, 129, 0.1); color: #10B981; }
.icon-gray { background: rgba(100, 116, 139, 0.1); color: var(--text-muted); }

.nav-spacer { height: 16px; margin: 16px 0; border-top: 1px solid var(--border-color); }

/* Dashboard Content */
.dashboard-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 24px;
}

/* Welcome Header */
.welcome-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end; /* Align to baseline */
    padding-top: 12px;
    margin-bottom: 12px;
}
.welcome-text p { margin-top: 6px; font-size: 16px; font-weight: 500; opacity: 0.8; }

.need-credits {
    background: rgba(255,255,255,0.8);
    padding: 10px 16px;
    border-radius: var(--radius-md);
    font-size: 14px;
    font-weight: 500;
    box-shadow: 0 4px 12px rgba(0,0,0,0.03);
}
.need-credits a { color: var(--primary); font-weight: 600; }
.need-credits a:hover { text-decoration: underline; }

/* Credits Banner */
.credits-banner {
    background: var(--primary-gradient);
    border-radius: var(--radius-xl);
    padding: 40px; /* Increased padding */
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: #fff;
    position: relative;
    overflow: hidden;
    box-shadow: 0 15px 35px rgba(51, 112, 255, 0.25);
}

.credits-banner::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -10%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, rgba(255,255,255,0) 70%);
    border-radius: 50%;
}

.credits-info { position: relative; z-index: 10; width: 50%; }
.credits-label { font-size: 16px; opacity: 0.9; margin-bottom: 8px; display: block; }

.progress-container { margin-top: 16px; }
.progress-bar {
    height: 10px; /* Slightly thicker */
    background: rgba(255,255,255,0.25);
    border-radius: 99px;
    overflow: hidden;
    margin-bottom: 10px;
}
.progress-fill { 
    height: 100%; 
    background: #fff; 
    border-radius: 99px;
    box-shadow: 0 0 10px rgba(255,255,255,0.4);
}
.progress-text { font-size: 14px; font-weight: 600; opacity: 0.95; }

.credits-illustration {
    position: relative;
    z-index: 10;
    height: 100px;
    width: 150px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Simple CSS docs illustration */
.ill-docs { position: relative; width: 100px; height: 80px; }
.ill-doc {
    position: absolute;
    background: rgba(255,255,255,0.9);
    border-radius: 4px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}
.doc-1 { width: 60px; height: 80px; left: 20px; top: 0; z-index: 3; }
.doc-2 { width: 60px; height: 80px; left: 0; top: 10px; transform: rotate(-10deg); z-index: 2; opacity: 0.8; }
.doc-3 { width: 60px; height: 80px; left: 40px; top: 10px; transform: rotate(10deg); z-index: 1; opacity: 0.6; }

/* Tool Cards Grid */
.tools-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr); /* Align both cards in one row as requested */
    gap: 32px; /* Increased gap */
    margin-bottom: 24px;
}

.tool-card {
    background: #fff;
    border-radius: var(--radius-xl); /* Larger radius */
    padding: 32px; /* Increased internal padding */
    display: flex;
    flex-direction: column;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid rgba(255,255,255,0.8);
    box-shadow: var(--card-shadow);
    height: 100%; /* Ensure equal height */
}

.tool-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--hover-shadow);
}

.tool-header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 20px;
}
.tool-header h4 { font-size: 20px; font-weight: 700; color: var(--text-dark); }

.tool-card p {
    font-size: 15px;
    line-height: 1.6;
    margin-bottom: 24px;
    color: var(--text-muted);
}

.tool-illustration {
    height: 140px; /* Slightly taller */
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.ill-img { max-height: 100%; max-width: 100%; object-fit: contain; }

.tool-card .btn { margin-top: auto; } /* Push buttons to the bottom */

/* Recent Activity */
.recent-activity-layout {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 24px;
}

.activity-section {
    background: #fff;
    border-radius: var(--radius-xl);
    padding: 32px;
    box-shadow: var(--card-shadow);
    border: 1px solid rgba(255,255,255,0.8);
}

.activity-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}
.activity-header .section-title { margin-bottom: 0; }
.view-all { font-size: 13px; color: var(--primary); font-weight: 600; }

.activity-list { display: flex; flex-direction: column; gap: 12px; }

.activity-item {
    display: flex;
    align-items: center;
    padding: 16px; /* Increased padding */
    border-radius: var(--radius-md);
    transition: all 0.3s ease;
    border-bottom: 1px solid var(--bg-waves); /* Subtle separator */
}

.activity-item:last-child { border-bottom: none; }

.activity-item:hover { 
    background: var(--bg-waves);
    transform: translateX(4px);
}

.activity-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 20px;
}

.activity-icon.sm { width: 32px; height: 32px; border-radius: 8px; margin-right: 12px; }
.activity-icon.sm .material-icons-round { font-size: 18px; }

.bg-light-blue { background: #E0F2FE; }
.bg-yellow { background: #FEF3C7; }
.bg-green { background: #D1FAE5; }

.activity-title { flex: 1; font-size: 14px; font-weight: 500; color: var(--text-dark); }
.activity-meta { font-size: 13px; color: var(--text-muted); display: flex; align-items: center; gap: 4px; }
.activity-meta .material-icons-round { font-size: 16px; }

/* Breadcrumbs */
.breadcrumb {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 24px;
}
.breadcrumb a {
    transition: color 0.2s;
}
.breadcrumb a:hover {
    color: var(--primary);
}

/* Responsive adjustments */
@media (max-width: 1024px) {
    .tools-grid { grid-template-columns: repeat(2, 1fr); }
    .recent-activity-layout { grid-template-columns: 1fr; }
}

/* Premium Select Component */
.premium-select-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    width: 100%;
    z-index: 10;
}

.premium-select {
    width: 100%;
    height: 46px;
    padding: 0 40px 0 44px;
    background: #fff;
    border: 1.5px solid #E2E8F0;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-dark);
    appearance: none;
    -webkit-appearance: none;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.02);
    font-family: inherit;
    outline: none;
}

.premium-select:hover {
    border-color: var(--primary-light);
    background-color: #F8FAFC;
    box-shadow: 0 4px 12px rgba(51, 112, 255, 0.05);
}

.premium-select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(51, 112, 255, 0.1);
    background-color: #fff;
}

.ps-icon-left {
    position: absolute;
    left: 14px;
    color: var(--primary);
    font-size: 20px;
    pointer-events: none;
    transition: transform 0.2s ease;
    display: flex;
    align-items: center;
    z-index: 11;
}

.ps-icon-right {
    position: absolute;
    right: 14px;
    color: #94A3B8;
    font-size: 20px;
    pointer-events: none;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    z-index: 11;
}

.premium-select-wrapper:hover .ps-icon-right {
    transform: translateY(1px);
    color: var(--primary);
}

.premium-select-wrapper:focus-within .ps-icon-right {
    color: var(--primary);
}
@media (max-width: 768px) {
    .main-container { flex-direction: column; }
    .sidebar { width: 100%; display: none; /* In a real app, make it off-canvas */ }
    .tools-grid { grid-template-columns: 1fr; }
    .nav-center { display: none; }
}
