:root {
    --accent:   #4f6ef7;
    --accent-light: #eef0fe;
    --body-bg:  #f4f6f9;
    --card-bg:  #ffffff;
    --border:   #e8ecf0;
    --text:     #1a202c;
    --muted:    #718096;
    --radius:   10px;
    --shadow:   0 1px 4px rgba(0,0,0,0.07);
}

*, *::before, *::after { box-sizing: border-box; }

body {
    font-family: 'Segoe UI', system-ui, sans-serif;
    background: var(--body-bg);
    color: var(--text);
    margin: 0;
    font-size: 0.9rem;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* ── Navbar ─────────────────────────────────────────── */
.pub-navbar {
    background: #fff;
    border-bottom: 1px solid var(--border);
    height: 60px;
    display: flex;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 200;
    box-shadow: var(--shadow);
}

.pub-brand { display: flex; align-items: center; gap: 10px; }

.pub-brand-icon {
    width: 36px; height: 36px;
    background: var(--accent);
    border-radius: 8px;
    display: flex; align-items: center; justify-content: center;
    color: white; font-size: 1.1rem; flex-shrink: 0;
}

.pub-brand-title {
    font-weight: 700; font-size: 1rem; color: var(--text);
    display: block; line-height: 1.1;
}

.pub-brand-sub {
    font-size: 0.72rem; color: var(--muted);
    display: block;
}

.pub-date-badge {
    background: var(--body-bg);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 4px 12px;
    font-size: 0.78rem;
    color: var(--muted);
}

/* ── Content ─────────────────────────────────────────── */
.pub-content { padding: 24px; flex: 1; }

/* ── Hero ─────────────────────────────────────────────── */
.pub-hero {
    background: linear-gradient(135deg, #1e2130 0%, #2d3452 100%);
    border-radius: var(--radius);
    padding: 32px 28px;
    color: white;
    margin-bottom: 24px;
}

.pub-hero h1 { font-size: 1.5rem; font-weight: 700; margin-bottom: 6px; }
.pub-hero p  { color: rgba(255,255,255,0.65); margin-bottom: 0; font-size: 0.9rem; }

/* ── Stat cards ───────────────────────────────────────── */
.pub-stat {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 18px 20px;
    display: flex;
    align-items: center;
    gap: 14px;
    box-shadow: var(--shadow);
}

.pub-stat-icon {
    width: 46px; height: 46px; border-radius: 10px;
    display: flex; align-items: center; justify-content: center;
    font-size: 1.3rem; flex-shrink: 0;
}
.pub-stat-icon.blue   { background: #eef0fe; color: var(--accent); }
.pub-stat-icon.green  { background: #f0fff4; color: #38a169; }
.pub-stat-icon.orange { background: #fffaf0; color: #dd6b20; }

.pub-stat-value { font-size: 1.5rem; font-weight: 700; line-height: 1; }
.pub-stat-label { font-size: 0.78rem; color: var(--muted); margin-top: 3px; }

/* ── Filter bar ───────────────────────────────────────── */
.filter-bar {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 16px 20px;
    box-shadow: var(--shadow);
    margin-bottom: 20px;
}

/* ── Cards ────────────────────────────────────────────── */
.pub-card {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    overflow: hidden;
}

.pub-card-header {
    padding: 14px 20px;
    border-bottom: 1px solid var(--border);
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text);
    background: #fafbfc;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 8px;
}

.pub-card-body { padding: 20px; }

/* ── Table ────────────────────────────────────────────── */
.pub-table { font-size: 0.875rem; width: 100%; margin: 0; border-collapse: collapse; }

.pub-table thead th {
    background: #f7fafc;
    color: var(--muted);
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 600;
    padding: 10px 14px;
    border-bottom: 1px solid var(--border);
    white-space: nowrap;
}

.pub-table tbody td {
    padding: 10px 14px;
    border-bottom: 1px solid #f0f2f5;
    vertical-align: middle;
}

.pub-table tbody tr:last-child td { border-bottom: none; }
.pub-table tbody tr:hover td { background: #fafbfc; }

/* ── Badge ────────────────────────────────────────────── */
.pub-badge {
    display: inline-block;
    background: #f0f2f5;
    color: var(--muted);
    font-size: 0.72rem;
    font-weight: 600;
    padding: 3px 8px;
    border-radius: 5px;
}

/* ── Tabs ─────────────────────────────────────────────── */
.pub-tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--border); margin-bottom: 20px; }

.pub-tab {
    padding: 8px 16px;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--muted);
    border: none; background: none;
    border-bottom: 2px solid transparent;
    cursor: pointer; transition: all 0.2s;
}

.pub-tab:hover { color: var(--text); }
.pub-tab.active { color: var(--accent); border-bottom-color: var(--accent); }

.pub-tab-pane { display: none; }
.pub-tab-pane.active { display: block; }

/* ── Footer ───────────────────────────────────────────── */
.pub-footer {
    background: #fff;
    border-top: 1px solid var(--border);
    padding: 14px 0;
    font-size: 0.78rem;
    color: var(--muted);
}

/* ── Form controls ────────────────────────────────────── */
.form-control, .form-select {
    border-color: var(--border);
    border-radius: 7px;
    font-size: 0.875rem;
}

.form-control:focus, .form-select:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(79,110,247,0.1);
}

.btn { border-radius: 7px; font-size: 0.875rem; font-weight: 500; }
.btn-primary { background: var(--accent); border-color: var(--accent); }
.btn-primary:hover { background: #3d5ae3; border-color: #3d5ae3; }

/* ── Responsive ───────────────────────────────────────── */
@media (max-width: 768px) {
    .pub-content { padding: 16px; }
    .pub-hero { padding: 22px 18px; }
}
