/* GooveBlend Admin Styles */

.admin-body {
    background: #f8fafc;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* Admin Login */
.admin-login-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
}

.login-form {
    background: white;
    padding: 3rem;
    border-radius: 12px;
    box-shadow: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 10px 10px -5px rgb(0 0 0 / 0.04);
    width: 100%;
    max-width: 400px;
}

.login-header {
    text-align: center;
    margin-bottom: 2rem;
}

.login-header .logo {
    width: 48px;
    height: 48px;
    margin-bottom: 1rem;
}

.login-header h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
}

.login-footer {
    text-align: center;
    margin-top: 2rem;
}

.login-footer a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.875rem;
}

.login-footer a:hover {
    color: var(--primary-color);
}

/* Admin Container */
.admin-container {
    display: flex;
    min-height: 100vh;
}

/* Admin Sidebar */
.admin-sidebar {
    width: 250px;
    background: var(--bg-dark);
    color: white;
    padding: 0;
    position: fixed;
    height: 100vh;
    overflow-y: auto;
}

.sidebar-header {
    padding: 2rem 1.5rem;
    border-bottom: 1px solid #374151;
    text-align: center;
}

.sidebar-header .logo {
    width: 40px;
    height: 40px;
    margin-bottom: 0.5rem;
}

.sidebar-header h3 {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--primary-color);
}

.sidebar-nav ul {
    list-style: none;
    padding: 1rem 0;
}

.sidebar-nav .nav-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 1.5rem;
    color: #d1d5db;
    text-decoration: none;
    transition: var(--transition);
    border-left: 3px solid transparent;
}

.sidebar-nav .nav-item:hover,
.sidebar-nav .nav-item.active {
    background: #374151;
    color: white;
    border-left-color: var(--primary-color);
}

.sidebar-nav .nav-item i {
    width: 20px;
    text-align: center;
}

/* Admin Main Content */
.admin-main {
    flex: 1;
    margin-left: 250px;
    padding: 0;
    background: #f8fafc;
}

.admin-header {
    background: white;
    padding: 1.5rem 2rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: var(--shadow-sm);
}

.admin-header h1 {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--text-primary);
}

.admin-user {
    display: flex;
    align-items: center;
    gap: 1rem;
    color: var(--text-secondary);
}

.logout-btn {
    background: var(--error-color);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: var(--border-radius);
    text-decoration: none;
    font-size: 0.875rem;
    transition: var(--transition);
}

.logout-btn:hover {
    background: #dc2626;
}

/* Dashboard Stats */
.dashboard-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    padding: 2rem;
}

.stat-card {
    background: white;
    padding: 1.5rem;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-sm);
    display: flex;
    align-items: center;
    gap: 1rem;
}

.stat-icon {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: white;
}

.stat-card:nth-child(1) .stat-icon {
    background: var(--primary-color);
}

.stat-card:nth-child(2) .stat-icon {
    background: var(--success-color);
}

.stat-card:nth-child(3) .stat-icon {
    background: var(--secondary-color);
}

.stat-card:nth-child(4) .stat-icon {
    background: var(--warning-color);
}

.stat-info h3 {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.25rem;
}

.stat-info p {
    color: var(--text-secondary);
    font-size: 0.875rem;
}

/* Dashboard Content */
.dashboard-content {
    padding: 0 2rem 2rem;
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 2rem;
}

.dashboard-section {
    background: white;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-sm);
    padding: 1.5rem;
}

.dashboard-section h2 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
}

/* Admin Tables */
.table-container {
    overflow-x: auto;
    margin-bottom: 1rem;
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
}

.admin-table th,
.admin-table td {
    padding: 0.75rem;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

.admin-table th {
    background: var(--bg-secondary);
    font-weight: 600;
    color: var(--text-primary);
}

.admin-table td {
    color: var(--text-secondary);
}

.admin-table tr:hover {
    background: var(--bg-secondary);
}

/* Status and Type Badges */
.status-badge,
.type-badge {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 500;
    text-transform: uppercase;
}

.status-badge.published {
    background: #d1fae5;
    color: #065f46;
}

.status-badge.draft {
    background: #fef3c7;
    color: #92400e;
}

.status-badge.pending {
    background: #fef3c7;
    color: #92400e;
}

.status-badge.approved {
    background: #d1fae5;
    color: #065f46;
}

.status-badge.rejected {
    background: #fee2e2;
    color: #991b1b;
}

.type-badge.mobile-app {
    background: #dbeafe;
    color: #1e40af;
}

.type-badge.music-video {
    background: #fce7f3;
    color: #be185d;
}

/* Form Styles */
.article-form {
    background: white;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-sm);
    margin: 2rem;
}

.form-section {
    padding: 2rem;
    border-bottom: 1px solid var(--border-color);
}

.form-section:last-child {
    border-bottom: none;
}

.form-section h3 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: var(--text-primary);
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid var(--border-color);
    border-radius: var(--border-radius);
    font-size: 1rem;
    transition: var(--transition);
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.form-group small {
    display: block;
    margin-top: 0.25rem;
    color: var(--text-light);
    font-size: 0.875rem;
}

.checkbox-group {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    border: 2px solid var(--border-color);
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: var(--transition);
}

.checkbox-label:hover {
    border-color: var(--primary-color);
}

.checkbox-label input[type="checkbox"] {
    width: auto;
    margin: 0;
}

.checkbox-label input[type="checkbox"]:checked + i {
    color: var(--primary-color);
}

.type-fields {
    margin-top: 1rem;
    padding: 1rem;
    background: var(--bg-secondary);
    border-radius: var(--border-radius);
}

.form-actions {
    padding: 2rem;
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
}

.btn-full {
    width: 100%;
}

/* Comments Management */
.comments-list .comment-item {
    background: var(--bg-secondary);
    padding: 1rem;
    border-radius: var(--border-radius);
    margin-bottom: 1rem;
}

.comment-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.comment-article {
    color: var(--text-light);
    font-size: 0.875rem;
}

.comment-content {
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.comment-date {
    font-size: 0.75rem;
    color: var(--text-light);
}

/* Responsive Admin */
@media (max-width: 768px) {
    .admin-sidebar {
        transform: translateX(-100%);
        transition: transform 0.3s ease;
    }
    
    .admin-main {
        margin-left: 0;
    }
    
    .dashboard-stats {
        grid-template-columns: 1fr;
        padding: 1rem;
    }
    
    .dashboard-content {
        grid-template-columns: 1fr;
        padding: 0 1rem 1rem;
    }
    
    .admin-header {
        padding: 1rem;
    }
    
    .article-form {
        margin: 1rem;
    }
    
    .form-section {
        padding: 1.5rem;
    }
    
    .form-actions {
        padding: 1.5rem;
        flex-direction: column;
    }
    
    .checkbox-group {
        flex-direction: column;
    }
}

/* Rich Text Editor Styles */
#editor-container {
    border: 2px solid var(--border-color);
    border-radius: var(--border-radius);
    overflow: hidden;
}

#editor-toolbar {
    background: var(--bg-secondary);
    padding: 0.5rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    gap: 0.25rem;
    flex-wrap: wrap;
}

#editor-toolbar button {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    padding: 0.5rem;
    cursor: pointer;
    transition: var(--transition);
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
}

#editor-toolbar button:hover {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

#editor {
    min-height: 300px;
    padding: 1rem;
    background: white;
    outline: none;
    line-height: 1.6;
}

#editor:focus {
    box-shadow: inset 0 0 0 2px var(--primary-color);
}

#editor img {
    max-width: 100%;
    height: auto;
    border-radius: 4px;
    margin: 0.5rem 0;
}

#editor a {
    color: var(--primary-color);
    text-decoration: underline;
}

#editor ul, #editor ol {
    margin-left: 2rem;
    margin-bottom: 1rem;
}

#editor li {
    margin-bottom: 0.25rem;
}