/* 
==========================================================================
   GMS PRO - UNIFIED PROFESSIONAL CSS
   Futuristic, Clean, and High-Performance
========================================================================== 
*/

:root {
    --primary: #06b6d4;
    --primary-soft: rgba(6, 182, 212, 0.1);
    --secondary: #8b5cf6;
    --accent: #d946ef;
    --bg: #f8fafc;
    --text: #0f172a;
    --text-muted: #64748b;
    --card-bg: #ffffff;
    --border: rgba(0, 0, 0, 0.08);
    --sidebar-bg: #0f172a;
    --sidebar-text: #94a3b8;
    --sidebar-active: #ffffff;
    --btn-light-bg: #f1f5f9;
    --btn-light-text: #0f172a;
    --navbar-bg: rgba(255, 255, 255, 0.8);
}

[data-theme="dark"] {
    --bg: #030712;
    --text: #f8fafc;
    --text-muted: #94a3b8;
    --card-bg: #0f172a;
    --border: rgba(255, 255, 255, 0.08);
    --sidebar-bg: #030712;
    --sidebar-text: #64748b;
    --sidebar-active: #06b6d4;
    --btn-light-bg: #1e293b;
    --btn-light-text: #f8fafc;
    --navbar-bg: rgba(3, 7, 18, 0.8);
}

body {
    background-color: var(--bg);
    color: var(--text);
    font-family: 'Outfit', sans-serif;
    margin: 0;
    overflow-x: hidden; /* Prevent horizontal scrollbar */
    transition: background 0.3s ease;
}

/* --- Layout Structure --- */
.dashboard-wrapper {
    display: flex;
    min-height: 100vh;
}

.dashboard-sidebar {
    width: 260px;
    background: #030712; /* Deep modern dark */
    color: #94a3b8;
    height: 100vh;
    position: fixed;
    top: 0;
    left: 0;
    display: flex;
    flex-direction: column;
    padding: 0;
    border-right: 1px solid rgba(255,255,255,0.05);
    z-index: 1000;
    overflow-x: hidden;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: rgba(255,255,255,0.1) transparent;
}

.dashboard-sidebar::-webkit-scrollbar {
    width: 4px;
}
.dashboard-sidebar::-webkit-scrollbar-track {
    background: transparent;
}
.dashboard-sidebar::-webkit-scrollbar-thumb {
    background: rgba(255,255,255,0.1);
    border-radius: 10px;
}
.dashboard-sidebar::-webkit-scrollbar-thumb:hover {
    background: var(--primary);
}

.dashboard-sidebar.collapsed {
    width: 80px;
}

.dashboard-main {
    flex: 1;
    margin-left: 260px;
    min-width: 0;
    transition: margin-left 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.dashboard-main.expanded {
    margin-left: 80px;
}

/* --- Sidebar Items --- */
.sidebar-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 10px 28px;
    color: #94a3b8;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.85rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    white-space: nowrap;
    position: relative;
    border-left: 3px solid transparent;
}

.sidebar-item i:first-child {
    font-size: 1.1rem;
    min-width: 24px;
    display: flex;
    justify-content: center;
    transition: all 0.3s ease;
}

.sidebar-item span {
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.collapsed .sidebar-item {
    padding-left: 28px;
    padding-right: 0;
    gap: 0;
}

.collapsed .sidebar-item span,
.collapsed .sidebar-footer .theme-label span {
    opacity: 0;
    pointer-events: none;
}

.sidebar-item:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.03);
}

.sidebar-item.active {
    color: #fff;
    background: linear-gradient(90deg, rgba(6, 182, 212, 0.1), transparent);
    border-left-color: var(--primary);
}

.sidebar-item.active i {
    color: var(--primary);
    filter: drop-shadow(0 0 8px rgba(6, 182, 212, 0.4));
}

/* --- Hover Expansion --- */
.dashboard-sidebar.collapsed:hover {
    width: 260px;
    box-shadow: 20px 0 50px rgba(0,0,0,0.4);
    background: #030712;
}

.dashboard-sidebar.collapsed:hover .sidebar-item {
    padding-left: 28px;
    gap: 15px;
}

.dashboard-sidebar.collapsed:hover .sidebar-item span,
.dashboard-sidebar.collapsed:hover .sidebar-footer .theme-label span {
    opacity: 1;
    pointer-events: auto;
}

/* --- Brand & Logo --- */
.logo-box-premium {
    transition: all 0.4s ease;
}

.dashboard-sidebar:hover .logo-box-premium {
    transform: rotate(5deg) scale(1.1);
}



/* --- Navbar Redesign --- */
.dashboard-navbar {
    height: 80px;
    padding: 0 40px;
    background: rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.3);
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 900;
}

[data-theme="dark"] .dashboard-navbar {
    background: rgba(15, 23, 42, 0.6);
    border-color: rgba(255, 255, 255, 0.05);
}

.nav-link-custom {
    color: var(--text);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.85rem;
    padding: 4px 0;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    position: relative;
    opacity: 0.7;
}

.nav-link-custom:hover {
    color: var(--primary);
    opacity: 1;
}

.nav-link-custom::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: width 0.3s ease;
}

.nav-link-custom:hover::after {
    width: 100%;
}

.navbar-search-box {
    background: rgba(0,0,0,0.03);
    border: 1px solid var(--border);
    border-radius: 100px;
    padding: 8px 20px;
    display: flex;
    align-items: center;
    gap: 12px;
    transition: all 0.3s ease;
}

[data-theme="dark"] .navbar-search-box {
    background: rgba(255,255,255,0.03);
}

.navbar-search-box:focus-within {
    background: var(--card-bg);
    border-color: var(--primary);
    box-shadow: 0 10px 20px rgba(0,0,0,0.05);
}


/* --- Professional Form Design --- */
.tool-process-card {
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.4);
    border-radius: 32px;
    padding: 40px;
    box-shadow: 0 20px 50px rgba(0,0,0,0.05);
}

[data-theme="dark"] .tool-process-card {
    background: rgba(15, 23, 42, 0.7);
    border-color: rgba(255, 255, 255, 0.05);
}

.drop-zone {
    width: 100%;
    height: 180px;
    padding: 25px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    font-family: 'Outfit', sans-serif;
    font-weight: 500;
    font-size: 1rem;
    cursor: pointer;
    color: var(--text-muted);
    border: 2px dashed var(--border);
    border-radius: 24px;
    background: rgba(0,0,0,0.02);
    transition: all 0.3s ease;
}

.drop-zone:hover, .drop-zone--over {
    border-color: var(--primary);
    background: var(--primary-soft);
    color: var(--primary);
}

.drop-zone-icon {
    font-size: 2.5rem;
    margin-bottom: 12px;
    display: block;
}

.file-item-premium {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 12px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: all 0.2s ease;
    animation: slideUp 0.3s ease forwards;
}

.file-item-premium:hover {
    border-color: var(--primary);
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

.process-btn-premium {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
    border: none;
    border-radius: 100px;
    padding: 16px 32px;
    font-weight: 800;
    font-size: 1.1rem;
    letter-spacing: -0.5px;
    box-shadow: 0 10px 25px rgba(6, 182, 212, 0.3);
    transition: all 0.4s ease;
    width: 100%;
}

.process-btn-premium:hover:not(:disabled) {
    transform: translateY(-5px) scale(1.02);
    box-shadow: 0 15px 35px rgba(6, 182, 212, 0.4);
}

.process-btn-premium:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.navbar-search-input {
    background: transparent;
    border: none;
    outline: none;
    font-size: 0.85rem;
    width: 100%;
    color: var(--text);
}

/* --- User Profile Module --- */
.user-profile-nav {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 6px 16px;
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 100px;
    transition: all 0.3s ease;
    cursor: pointer;
}

.user-profile-nav:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 16px rgba(0,0,0,0.05);
    border-color: var(--primary);
}

.user-avatar-small {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--primary);
}

.dropdown-menu.glass {
    background: #ffffff !important;
    backdrop-filter: blur(25px) !important;
    -webkit-backdrop-filter: blur(25px) !important;
    border: 1px solid rgba(0, 0, 0, 0.08) !important;
    box-shadow: 0 15px 35px rgba(0,0,0,0.1) !important;
    padding: 12px !important;
    animation: dropdownPop 0.3s cubic-bezier(0.19, 1, 0.22, 1);
}

[data-theme="dark"] .dropdown-menu.glass {
    background: rgba(15, 23, 42, 0.8) !important;
    border-color: rgba(255, 255, 255, 0.05) !important;
}

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

.dropdown-item {
    font-size: 13px !important;
    font-weight: 500 !important;
    padding: 8px 12px !important;
    color: var(--text) !important;
    border-radius: 8px !important;
    transition: all 0.2s ease !important;
}

.dropdown-item:hover {
    background: var(--primary-soft) !important;
    color: var(--primary) !important;
    transform: translateX(5px);
}

.dropdown-header {
    font-size: 11px !important;
    font-weight: 800 !important;
    text-transform: uppercase !important;
    letter-spacing: 1px !important;
    padding: 0 12px 8px !important;
    opacity: 0.6;
}

.tool-card-new {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 24px;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 16px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.tool-card-new:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
    border-color: var(--primary);
}

.tool-icon-box {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

.admin-hero-title {
    font-size: 2.5rem;
    font-weight: 800;
    letter-spacing: -1px;
    margin-bottom: 1rem;
}

.admin-stat-card {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 30px;
    transition: all 0.3s ease;
}

.admin-stat-value {
    font-size: 2.5rem;
    font-weight: 800;
    line-height: 1;
}

/* --- Buttons --- */
.admin-btn-primary {
    background: var(--primary);
    color: white;
    border: none;
    padding: 10px 24px;
    border-radius: 100px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.admin-btn-purple {
    background: var(--secondary);
    color: white;
    border: none;
    padding: 10px 24px;
    border-radius: 100px;
    font-weight: 600;
    transition: all 0.3s ease;
}

/* --- Responsive --- */
@media (max-width: 992px) {
    .dashboard-sidebar {
        transform: translateX(-100%);
        width: 0;
        padding: 0;
    }
    .dashboard-main {
        margin-left: 0;
    }
}

/* --- Animation --- */
.slide-up {
    animation: slideUp 0.5s ease forwards;
}

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

/* --- Premium Tool Cards --- */
.tool-card-premium {
    background: rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.4);
    border-radius: 20px;
    padding: 20px;
    height: 100%;
    display: flex;
    flex-direction: column;
    gap: 12px;
    transition: all 0.5s cubic-bezier(0.19, 1, 0.22, 1);
    position: relative;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.02);
}

[data-theme="dark"] .tool-card-premium {
    background: rgba(15, 23, 42, 0.6);
    border-color: rgba(255, 255, 255, 0.05);
}

.tool-card-premium:hover {
    transform: translateY(-10px) scale(1.02);
    border-color: var(--primary);
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
}

/* --- Advanced Shimmer Effect --- */
.tool-card-premium::after {
    content: "";
    position: absolute;
    top: -50%;
    left: -60%;
    width: 20%;
    height: 200%;
    background: linear-gradient(
        to right, 
        rgba(255, 255, 255, 0) 0%, 
        rgba(255, 255, 255, 0.3) 50%, 
        rgba(255, 255, 255, 0) 100%
    );
    transform: rotate(25deg);
    transition: all 0.8s cubic-bezier(0.19, 1, 0.22, 1);
    z-index: 2;
    pointer-events: none;
}

.tool-card-premium:hover::after {
    left: 120%;
}

/* Subtle background glow on hover */
.tool-card-premium::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 50% 0%, var(--primary-soft), transparent 70%);
    opacity: 0;
    transition: opacity 0.5s ease;
    z-index: 0;
}

.tool-card-premium:hover::before {
    opacity: 1;
}

.tool-icon-wrapper {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    color: white;
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
    transition: all 0.4s ease;
    position: relative;
    z-index: 1;
}

.tool-card-premium:hover .tool-icon-wrapper {
    transform: rotate(12deg) scale(1.15);
    box-shadow: 0 15px 30px rgba(0,0,0,0.3);
    filter: brightness(1.2) drop-shadow(0 0 10px rgba(255,255,255,0.3));
}

.tool-content {
    position: relative;
    z-index: 1;
}

.tool-title {
    font-size: 1rem;
    font-weight: 800;
    margin-bottom: 4px;
    color: var(--text);
    letter-spacing: -0.3px;
}

.tool-desc {
    font-size: 12px;
    color: var(--text-muted);
    line-height: 1.5;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.tool-arrow {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--btn-light-bg);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    margin-top: auto;
    align-self: flex-start;
    transition: all 0.3s ease;
    border: 1px solid var(--border);
}

.tool-card-premium:hover .tool-arrow {
    background: var(--primary);
    color: white;
    transform: translateX(10px);
    border-color: var(--primary);
}

/* --- Unified Notifications (Toasts) --- */
.gms-toast-container {
    position: fixed;
    top: 24px;
    right: 24px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 12px;
    pointer-events: none;
}

.gms-toast {
    min-width: 300px;
    max-width: 400px;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.4);
    border-radius: 16px;
    padding: 16px 20px;
    display: flex;
    align-items: center;
    gap: 15px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.1);
    pointer-events: auto;
    animation: toastSlideIn 0.5s cubic-bezier(0.19, 1, 0.22, 1) forwards;
    transition: all 0.3s ease;
}

[data-theme="dark"] .gms-toast {
    background: rgba(15, 23, 42, 0.85);
    border-color: rgba(255, 255, 255, 0.05);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.3);
}

.gms-toast.hiding {
    animation: toastSlideOut 0.5s cubic-bezier(0.19, 1, 0.22, 1) forwards;
}

@keyframes toastSlideIn {
    from { transform: translateX(100%); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

@keyframes toastSlideOut {
    from { transform: translateX(0); opacity: 1; }
    to { transform: translateX(120%); opacity: 0; }
}

.gms-toast-icon {
    width: 32px;
    height: 32px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    flex-shrink: 0;
}

.gms-toast-success .gms-toast-icon { background: rgba(16, 185, 129, 0.1); color: #10b981; }
.gms-toast-error .gms-toast-icon { background: rgba(239, 68, 68, 0.1); color: #ef4444; }
.gms-toast-info .gms-toast-icon { background: rgba(59, 130, 246, 0.1); color: #3b82f6; }

.gms-toast-content {
    flex: 1;
}

.gms-toast-title {
    font-size: 14px;
    font-weight: 800;
    margin-bottom: 2px;
    color: var(--text);
}

.gms-toast-message {
    font-size: 12px;
    color: var(--text-muted);
}
