/**
 * Admin Panel Stylesheet
 */

/* 1. Admin Login Layout */
.login-body {
    background: radial-gradient(circle at 15% 50%, #061124 0%, #030814 100%);
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    position: relative;
    overflow: hidden;
}

.login-body::before {
    content: '';
    position: absolute;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(6, 182, 212, 0.15) 0%, transparent 70%);
    top: -200px;
    left: -200px;
    border-radius: 50%;
    z-index: 0;
}

.login-card {
    background: rgba(19, 45, 82, 0.4);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #f8fafc;
    width: 100%;
    max-width: 420px;
    padding: 3rem 2.5rem;
    border-radius: 16px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    position: relative;
    z-index: 1;
    transform: translateY(0);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.login-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 30px 60px -15px rgba(0, 0, 0, 0.6);
}

.login-card h2 {
    color: #f8fafc;
    font-size: 1.75rem;
    margin-bottom: 0.5rem;
}

.login-card .form-label {
    color: #cbd5e1;
}

.login-card .form-control {
    background-color: rgba(12, 30, 58, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #f8fafc;
    transition: all 0.3s ease;
}

.login-card .form-control:focus {
    background-color: rgba(12, 30, 58, 0.9);
    border-color: #06b6d4;
    box-shadow: 0 0 0 3px rgba(6, 182, 212, 0.25);
    transform: translateY(-1px);
}

.login-card .btn-primary {
    background: linear-gradient(135deg, #06b6d4 0%, #0369a1 100%);
    border: none;
    padding: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.5px;
    box-shadow: 0 4px 15px rgba(6, 182, 212, 0.3);
    transition: all 0.3s ease;
}

.login-card .btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(6, 182, 212, 0.5);
    background: linear-gradient(135deg, #08c8e8 0%, #037abf 100%);
}

/* 2. Admin Layout structure */
.admin-wrapper {
    display: flex;
    min-height: 100vh;
    flex-direction: column;
}

@media (min-width: 768px) {
    .admin-wrapper {
        flex-direction: row;
    }
}

.admin-sidebar {
    width: 100%;
    background: linear-gradient(180deg, #0c1e3a 0%, #061124 100%);
    color: #cbd5e1;
    padding: 2rem;
    border-bottom: 1px solid #1e293b;
    box-shadow: 4px 0 15px rgba(0,0,0,0.1);
}

@media (min-width: 768px) {
    .admin-sidebar {
        width: 260px;
        border-bottom: none;
        border-right: 1px solid #1e293b;
        position: sticky;
        top: 0;
        height: 100vh;
    }
}

.admin-logo {
    font-family: var(--font-title);
    font-size: 1.25rem;
    font-weight: 700;
    color: #f8fafc;
    margin-bottom: 2rem;
}

.admin-logo span {
    color: #06b6d4;
}

.admin-menu {
    list-style: none;
    display: flex;
    flex-direction: row;
    gap: 1rem;
    flex-wrap: wrap;
}

@media (min-width: 768px) {
    .admin-menu {
        flex-direction: column;
        gap: 0.5rem;
    }
}

.admin-menu-item a {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    border-radius: 8px;
    font-size: 0.95rem;
    color: #94a3b8;
    transition: var(--transition-smooth);
}

.admin-menu-item a:hover, .admin-menu-item.active a {
    color: #f8fafc;
    background-color: rgba(255, 255, 255, 0.05);
}

.admin-menu-item.active a {
    background-color: #0369a1;
    color: #ffffff;
}

.admin-content {
    flex: 1;
    padding: 2.5rem;
    background-color: #f8fafc;
}

.admin-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2.5rem;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 1.5rem;
}

/* Stats Cards */
.stat-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2.5rem;
}

.stat-card {
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 1.75rem;
    box-shadow: 0 4px 6px -1px rgba(0,0,0,0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.stat-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 20px -5px rgba(0,0,0,0.08);
}

.stat-card h3 {
    font-size: 0.85rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 0.5rem;
}

.stat-card .value {
    font-family: var(--font-title);
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-primary);
}

/* Leads Table */
.table-responsive {
    overflow-x: auto;
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    box-shadow: var(--shadow-sm);
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
}

.admin-table th, .admin-table td {
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid var(--border-color);
    font-size: 0.9rem;
}

.admin-table th {
    background-color: #f1f5f9;
    color: #475569;
    font-weight: 600;
}

.admin-table tr:last-child td {
    border-bottom: none;
}

.admin-table tr {
    transition: background-color 0.2s ease;
}

.admin-table tr:hover {
    background-color: #f1f5f9;
}

/* Badge statuses */
.status-badge {
    display: inline-flex;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
}

.status-new { background-color: #dbeafe; color: #1e40af; }
.status-contacted { background-color: #fef3c7; color: #92400e; }
.status-converted { background-color: #d1fae5; color: #065f46; }
.status-archived { background-color: #e2e8f0; color: #475569; }

/* Selector styling */
.status-select {
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    border: 1px solid var(--border-color);
    font-size: 0.8rem;
    outline: none;
    cursor: pointer;
}

.status-select:focus {
    border-color: var(--primary);
}
