/* Journalist Dashboard Styles */

:root {
    --primary-color: #000000;
    --accent-color: #d4af37;
    /* Gold accent */
    --bg-color: #f8f9fa;
    --card-bg: #ffffff;
    --text-color: #333333;
    --border-color: #e0e0e0;
    --sidebar-width: 250px;
}

body {
    font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
    background-color: var(--bg-color);
    margin: 0;
    padding: 0;
    color: var(--text-color);
    display: flex;
    min-height: 100vh;
}

/* Sidebar */
.dashboard-sidebar {
    width: var(--sidebar-width);
    background-color: #ffffff;
    color: #374151;
    display: flex;
    flex-direction: column;
    position: fixed;
    height: 100vh;
    left: 0;
    top: 0;
    z-index: 1000;
    border-right: 1px solid #e5e7eb;
    box-shadow: 2px 0 8px rgba(0,0,0,0.04);
    transition: transform 0.3s ease;
}

.sidebar-header {
    padding: 22px 20px 18px;
    border-bottom: 1px solid #e5e7eb;
    text-align: center;
    background: #ffffff;
}

.sidebar-header h2 {
    margin: 0;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    color: #111827;
    text-transform: uppercase;
    font-family: 'Playfair Display','Georgia',serif;
}

.sidebar-nav {
    flex: 1;
    padding: 20px 0;
    list-style: none;
    margin: 0;
}

.sidebar-nav li {
    margin-bottom: 5px;
}

.sidebar-nav a {
    display: block;
    padding: 10px 20px;
    color: #374151;
    text-decoration: none;
    transition: all 0.15s;
    border-left: 3px solid transparent;
    border-radius: 0 6px 6px 0;
    margin-right: 8px;
    font-size: 0.875rem;
}

.sidebar-nav a:hover {
    background-color: #f3f4f6;
    color: #111827;
    border-left-color: #d1d5db;
}

.sidebar-nav a.active {
    background-color: #e9ecef;
    color: #111827;
    border-left-color: #c9a84c;
    font-weight: 600;
}

.user-profile-mini {
    padding: 16px 20px;
    border-top: 1px solid #e5e7eb;
    background-color: #f7f8fa;
}

.user-name {
    font-weight: 600;
    display: block;
    margin-bottom: 3px;
    color: #111827;
    font-size: 0.88rem;
}

.user-role {
    font-size: 0.68rem;
    color: #9ca3af;
    text-transform: uppercase;
    letter-spacing: 0.8px;
}

/* Main Content */
.dashboard-main {
    flex: 1;
    margin-left: var(--sidebar-width);
    padding: 30px;
    width: calc(100% - var(--sidebar-width));
}

.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.btn {
    padding: 10px 20px;
    border-radius: 4px;
    border: none;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.9rem;
    transition: opacity 0.2s;
}

.btn-primary {
    background-color: var(--primary-color);
    color: #fff;
}

.btn-accent {
    background-color: var(--accent-color);
    color: #000;
}

.btn:hover {
    opacity: 0.9;
}

/* Article List */
.article-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

.article-card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    transition: transform 0.2s;
    position: relative;
}

.article-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.article-status {
    position: absolute;
    top: 20px;
    right: 20px;
    font-size: 0.75rem;
    padding: 4px 8px;
    border-radius: 12px;
    font-weight: bold;
    text-transform: uppercase;
}

.status-new {
    background-color: #e3f2fd;
    color: #1976d2;
}

.status-submitted {
    background-color: #fff3e0;
    color: #f57c00;
}

.status-approved {
    background-color: #e8f5e9;
    color: #388e3c;
}

.status-included {
    background-color: #f3e5f5;
    color: #7b1fa2;
    border: 1px solid #7b1fa2;
}

.article-title {
    margin-top: 10px;
    margin-bottom: 10px;
    font-size: 1.2rem;
    padding-right: 60px;
    /* Space for status badge */
}

.article-meta {
    font-size: 0.85rem;
    color: #666;
    margin-bottom: 15px;
}

/* Editor View */
.editor-container {
    background: var(--card-bg);
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    max-width: 900px;
    margin: 0 auto;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #444;
}

.form-control {
    width: 100%;
    padding: 10px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 1rem;
    box-sizing: border-box;
}

textarea.form-control {
    min-height: 150px;
    font-family: inherit;
}

.toolbar {
    padding: 10px;
    background: #f1f1f1;
    border: 1px solid var(--border-color);
    border-bottom: none;
    border-radius: 4px 4px 0 0;
}

.editor-content {
    min-height: 300px;
    border: 1px solid var(--border-color);
    border-radius: 0 0 4px 4px;
    padding: 20px;
    background: #fff;
}

.media-gallery {
    display: flex;
    overflow-x: auto;
    gap: 10px;
    padding: 10px 0;
}

.media-item {
    width: 120px;
    height: 120px;
    position: relative;
    border-radius: 4px;
    overflow: hidden;
    flex-shrink: 0;
}

.media-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.media-remove {
    position: absolute;
    top: 5px;
    right: 5px;
    background: rgba(255, 0, 0, 0.8);
    color: #fff;
    border: none;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    cursor: pointer;
    font-size: 12px;
}

/* Page Break Blot */
.ql-pagebreak {
    border: none;
    border-top: 2px dashed #999;
    height: 30px;
    margin: 20px 0;
    position: relative;
    cursor: default;
    background: #f8f9fa;
    display: block;
}

.ql-pagebreak::after {
    content: "PAGE BREAK";
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 12px;
    color: #555;
    background: #f8f9fa;
    padding: 2px 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
}

@media print {
    .ql-pagebreak {
        border: none;
        break-after: always;
        page-break-after: always;
        height: 0;
        margin: 0;
        visibility: hidden;
        display: block;
    }
}