/* =====================================================================
   Tudor Journals — main stylesheet
   Design tokens extracted from the supplied screenshots
   ===================================================================== */

:root {
    /* Brand */
    --tj-navy-900: #0f1535;
    --tj-navy-800: #1a2456;
    --tj-navy-700: #1e2a5e;
    --tj-navy-600: #243175;
    --tj-blue-600: #4f5ec5;
    --tj-blue-500: #5b6dd1;
    --tj-blue-400: #7c8ee0;
    --tj-blue-100: #e6e9fa;

    /* Neutrals */
    --tj-bg:       #f5f6fa;
    --tj-surface:  #ffffff;
    --tj-border:   #e2e6ef;
    --tj-text:     #1a202c;
    --tj-muted:    #64748b;

    /* Status */
    --tj-success-bg: #d1fae5;
    --tj-success-fg: #065f46;
    --tj-warning-bg: #fef3c7;
    --tj-warning-fg: #92400e;
    --tj-danger-bg:  #fee2e2;
    --tj-danger-fg:  #991b1b;
    --tj-info-bg:    #dbeafe;
    --tj-info-fg:    #1e40af;

    /* Misc */
    --tj-radius:   10px;
    --tj-radius-sm: 6px;
    /* Visual rule: no shadows.
       The legacy variables are kept as `none` so every selector that
       references them via `box-shadow: var(--tj-shadow*)` resolves to
       no shadow without having to edit each one individually. */
    --tj-shadow-sm: none;
    --tj-shadow:    none;
    --tj-shadow-lg: none;

    --font-sans:  "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    --font-serif: var(--font-sans);  /* unified — single font across the whole site */
}

/* ---- Base ----------------------------------------------------------- */
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
    font-family: var(--font-sans);
    font-size: 16px;
    line-height: 1.6;
    color: var(--tj-text);
    background: var(--tj-bg);
    -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--tj-blue-600); text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3, h4 { font-family: var(--font-serif); color: var(--tj-text); margin: 0 0 .5em; line-height: 1.2; }
h1 { font-size: 3rem; font-weight: 700; }
h2 { font-size: 2.25rem; font-weight: 700; }
h3 { font-size: 1.5rem; font-weight: 700; }
p  { margin: 0 0 1rem; }

.container { max-width: 1200px; margin: 0 auto; padding: 0 1.5rem; }
.section { padding: 4rem 0; }
.text-center { text-align: center; }
.muted { color: var(--tj-muted); }

/* ---- Header / Nav -------------------------------------------------- */
.site-header {
    background: var(--tj-navy-800);
    color: #fff;
    padding: 1rem 0;
    position: sticky; top: 0; z-index: 50;
}
.site-header .container {
    display: flex; align-items: center; justify-content: space-between; gap: 2rem;
}
.brand {
    display: inline-flex; align-items: center; gap: 1rem;
    color: #fff; padding: .25rem 0;
}
.brand:hover { text-decoration: none; }
.brand:hover .brand-name { color: #fff; }
.brand:hover .brand-monogram { border-color: rgba(255,255,255,.45); }

/* Elegant typographic monogram — thin circle with serif initials.
   Replaces the old rounded-square logo image. Pure CSS, no asset. */
.brand-monogram {
    width: 44px; height: 44px;
    flex-shrink: 0;
    display: inline-flex; align-items: center; justify-content: center;
    border: 1px solid rgba(255, 255, 255, .35);
    border-radius: 50%;
    color: #fff;
    position: relative;
}
.brand-monogram > span {
    font-family: var(--font-serif);
    font-size: 1.1rem;
    font-weight: 500;
    font-style: italic;
    letter-spacing: .02em;
    line-height: 1;
    /* subtle gold tint on the second initial via background-clip */
}
.brand-monogram::after {
    /* tiny accent dot bottom-right, gold */
    content: '';
    position: absolute;
    width: 5px; height: 5px;
    border-radius: 50%;
    background: #fbbf24;
    right: -2px; bottom: 1px;
}

.brand-text {
    line-height: 1.15;
    display: flex; flex-direction: column;
    border-left: 1px solid rgba(255, 255, 255, .18);
    padding-left: 1rem;
}
.brand-name {
    font-family: var(--font-serif);
    font-size: 1.35rem; font-weight: 700;
    color: #fff; letter-spacing: -.01em;
    display: block;
}
.brand-tagline {
    font-size: .58rem; font-weight: 500;
    color: rgba(255, 255, 255, .72);
    text-transform: uppercase; letter-spacing: .12em;
    margin-top: .2rem;
}
/* Hide the long tagline on narrower viewports — header only.
   Footer keeps it (rendered at a different size below). */
@media (max-width: 1100px) {
    .site-header .brand-tagline { display: none; }
}

/* Footer brand — white on the dark footer background. */
.brand--footer { color: #fff; gap: .85rem; }
.brand--footer .brand-monogram {
    width: 40px; height: 40px;
    border-color: rgba(255, 255, 255, .35);
    color: #fff;
}
.brand--footer .brand-text {
    border-left: 1px solid rgba(255, 255, 255, .18);
    padding-left: .85rem;
}
.brand--footer .brand-name { color: #fff; font-size: 1.15rem; }
.brand--footer .brand-tagline {
    color: rgba(255, 255, 255, .72);
    font-size: .62rem;
    letter-spacing: .12em;
}

@media (max-width: 540px) {
    .brand { gap: .65rem; }
    .brand-text { padding-left: .75rem; }
    .brand-name { font-size: 1.1rem; }
    .brand-tagline { font-size: .62rem; letter-spacing: .1em; }
}

.nav-main { display: flex; align-items: center; gap: .25rem; }
.nav-main a {
    color: rgba(255,255,255,.85);
    padding: .55rem 1.1rem;
    border-radius: 8px;
    font-weight: 500;
    transition: background .15s, color .15s;
}
.nav-main a:hover { background: rgba(255,255,255,.08); color: #fff; text-decoration: none; }
.nav-main a.active { background: var(--tj-blue-600); color: #fff; }

.nav-actions { display: flex; gap: .75rem; align-items: center; }

/* Logged-in chip in the public header (replaces "Dashboard" button) */
.nav-userchip {
    display: inline-flex; align-items: center; justify-content: center;
    width: 40px; height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, .08);
    border: 1px solid rgba(255, 255, 255, .25);
    text-decoration: none;
    transition: background .15s, border-color .15s, transform .15s;
}
.nav-userchip:hover { background: rgba(255, 255, 255, .18); border-color: rgba(255, 255, 255, .55); }
.nav-userchip-avatar {
    color: #fff; font-weight: 700; font-size: .85rem;
    letter-spacing: .03em;
    font-family: var(--font-sans, inherit);
}

/* ---- Buttons ------------------------------------------------------- */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: .55rem;
    padding: .7rem 1.35rem;
    border: 1px solid transparent;
    border-radius: 8px;
    font-weight: 600; font-size: .95rem;
    font-family: inherit;
    cursor: pointer;
    transition: all .15s ease;
    text-decoration: none;
    line-height: 1.2;
}
.btn:hover { text-decoration: none; filter: brightness(0.95); }
.btn-primary       { background: var(--tj-blue-600); color: #fff; }
.btn-primary:hover { background: var(--tj-blue-500); color: #fff; }
.btn-light         { background: #fff; color: var(--tj-navy-800); }
.btn-light:hover   { background: #f0f1f5; color: var(--tj-navy-800); }
.btn-outline       { background: transparent; color: #fff; border-color: rgba(255,255,255,.4); }
.btn-outline:hover { background: rgba(255,255,255,.08); color: #fff; }
.btn-outline-dark  { background: transparent; color: var(--tj-blue-600); border-color: var(--tj-blue-600); }
.btn-outline-dark:hover { background: var(--tj-blue-100); color: var(--tj-blue-600); }
.btn-block         { width: 100%; }
.btn-lg            { padding: .9rem 1.6rem; font-size: 1rem; }

/* ---- Hero ---------------------------------------------------------- */
.hero {
    /* Drop a photo at assets/images/home-hero.jpg (any tasteful library /
       manuscripts / lab photo). Layered: blue overlay first, then the image.
       The gradient stays as fallback when the file is missing — no broken
       layout regardless. */
    background:
        linear-gradient(
            135deg,
            rgba(30, 27, 75, .90) 0%,
            rgba(67, 56, 202, .82) 55%,
            rgba(79, 70, 229, .72) 100%
        ),
        url('../images/home-hero.jpg') center / cover no-repeat,
        linear-gradient(135deg, var(--tj-navy-800) 0%, var(--tj-blue-600) 100%);
    color: #fff;
    padding: 5rem 0 6rem;
    position: relative;
    overflow: hidden;
}
.hero::before {
    content: ''; position: absolute; inset: 0;
    background: radial-gradient(circle at 80% 20%, rgba(255,255,255,.10), transparent 55%);
    pointer-events: none;
}
.hero .container { position: relative; }
.hero-grid {
    display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: center;
}
.hero h1 { color: #fff; font-size: 3.25rem; margin-bottom: 1.25rem; }
.hero p.lead { color: rgba(255,255,255,.85); font-size: 1.1rem; margin-bottom: 2rem; }
.hero-actions { display: flex; gap: 1rem; flex-wrap: wrap; }

.search-card {
    background: rgba(255,255,255,.08);
    border: 1px solid rgba(255,255,255,.15);
    border-radius: 12px;
    padding: 1.75rem;
    backdrop-filter: blur(8px);
}
.search-card h3 {
    color: #fff; font-family: var(--font-sans); font-size: 1.05rem; font-weight: 600;
    display: flex; align-items: center; gap: .5rem; margin-bottom: 1rem;
}
.search-form { display: flex; gap: .5rem; }
.search-form input {
    flex: 1; padding: .8rem 1rem;
    background: rgba(255,255,255,.1);
    border: 1px solid rgba(255,255,255,.2);
    border-radius: 8px;
    color: #fff;
    font-size: .95rem;
}
.search-form input::placeholder { color: rgba(255,255,255,.55); }
.search-form input:focus { outline: none; background: rgba(255,255,255,.15); border-color: rgba(255,255,255,.4); }
.search-form button {
    background: rgba(255,255,255,.18); color: #fff; border: 0; padding: 0 1.1rem;
    border-radius: 8px; cursor: pointer; font-size: 1rem;
}
.search-form button:hover { background: rgba(255,255,255,.28); }

.search-pills { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: 1rem; }
.search-pills a {
    background: rgba(255,255,255,.12);
    color: rgba(255,255,255,.9);
    padding: .35rem .9rem;
    border-radius: 999px;
    font-size: .85rem;
}
.search-pills a:hover { background: rgba(255,255,255,.2); text-decoration: none; }

/* ---- Stats strip --------------------------------------------------- */
.stats {
    background: var(--tj-navy-900);
    color: #fff;
    padding: 2.5rem 0;
}
.stats-grid {
    display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; text-align: center;
}
.stat-num { font-size: 2.6rem; font-weight: 700; line-height: 1; }
.stat-label { color: rgba(255,255,255,.65); margin-top: .35rem; font-size: .95rem; }

/* ---- Section heads ------------------------------------------------- */
.section-head { text-align: center; max-width: 720px; margin: 0 auto 3rem; }
.section-head h2 { margin-bottom: 1rem; }
.section-head p  { color: var(--tj-muted); font-size: 1.05rem; }

/* ---- Journal cards ------------------------------------------------- */
.journals-grid {
    display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 1.5rem;
}
.journal-card {
    background: var(--tj-surface);
    border: 1px solid var(--tj-border);
    border-radius: var(--tj-radius);
    padding: 1.75rem;
    border-top: 4px solid var(--tj-blue-600);
    display: flex; flex-direction: column;
    transition: border-color .15s;
}
.journal-card:hover { border-color: var(--tj-blue-400); }
.journal-card h3 { font-size: 1.25rem; margin-bottom: .75rem; }
.journal-card h3 a { color: var(--tj-text); }
.journal-card .meta {
    color: var(--tj-blue-600);
    font-size: .9rem; margin-bottom: 1rem;
    display: flex; gap: .75rem; align-items: center;
}
.journal-card .description {
    color: var(--tj-muted); font-size: .95rem; margin-bottom: 1.25rem;
    display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.journal-card .badges { margin-top: auto; display: flex; flex-direction: column; gap: .4rem; align-items: flex-start; }
.journal-card-cover { display: block; margin: -1.75rem -1.75rem 1.25rem; overflow: hidden; }
.journal-card-cover img { width: 100%; height: 200px; object-fit: cover; display: block; }
/* image zoom on hover removed per visual policy */
.journal-cover-img { width: 200px; aspect-ratio: 3/4; object-fit: cover; border-radius: 8px; display: block; }

/* ---- Badges -------------------------------------------------------- */
.badge {
    display: inline-flex; align-items: center; gap: .4rem;
    padding: .3rem .8rem;
    border-radius: 999px;
    font-size: .82rem;
    font-weight: 500;
}
.badge-area    { background: var(--tj-blue-100); color: var(--tj-blue-600); }
.badge-success { background: var(--tj-success-bg); color: var(--tj-success-fg); }
.badge-warning { background: var(--tj-warning-bg); color: var(--tj-warning-fg); }
.badge-danger  { background: var(--tj-danger-bg); color: var(--tj-danger-fg); }
.badge-info    { background: var(--tj-info-bg); color: var(--tj-info-fg); }

/* ---- Features ------------------------------------------------------ */
.features-grid {
    display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.5rem;
}
.feature-card {
    background: var(--tj-surface);
    border: 1px solid var(--tj-border);
    border-radius: var(--tj-radius);
    padding: 2rem 1.5rem;
    text-align: center;
}
.feature-icon {
    width: 56px; height: 56px;
    background: var(--tj-blue-100);
    color: var(--tj-blue-600);
    border-radius: 12px;
    display: flex; align-items: center; justify-content: center;
    margin: 0 auto 1.25rem;
    font-size: 1.5rem;
}
.feature-card h3 { font-family: var(--font-sans); font-size: 1.1rem; margin-bottom: .75rem; }
.feature-card p  { color: var(--tj-muted); font-size: .95rem; margin: 0; }

/* ---- CTA strip ----------------------------------------------------- */
.cta-strip {
    background: linear-gradient(135deg, var(--tj-navy-800), var(--tj-blue-600));
    color: #fff; padding: 5rem 0; text-align: center;
}
.cta-strip h2 { color: #fff; margin-bottom: 1rem; }
.cta-strip p  { color: rgba(255,255,255,.85); max-width: 640px; margin: 0 auto 2rem; }
.cta-strip .btn-light { color: var(--tj-navy-800); }

/* ---- Footer -------------------------------------------------------- */
.site-footer {
    background: var(--tj-navy-900);
    color: rgba(255, 255, 255, .72);
    padding: 4rem 0 1.5rem;
    /* Subtle blue→purple top edge to echo the brand without using a shadow. */
    border-top: 3px solid var(--tj-blue-600);
}
.site-footer h4 {
    color: #fff;
    font-family: var(--font-sans);
    font-size: .78rem;
    margin-bottom: 1rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .12em;
}
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: .55rem; font-size: .92rem; }
.site-footer a { color: rgba(255, 255, 255, .72); text-decoration: none; }
.site-footer a:hover { color: #fff; text-decoration: underline; }

/* ---- Modern footer (2-zone layout) -------------------------------- */
.site-footer--modern .footer-top {
    display: grid;
    grid-template-columns: 1.4fr 2fr;
    gap: 3rem;
    margin-bottom: 2.5rem;
}
.site-footer--modern .footer-brand { max-width: 360px; }
.site-footer--modern .footer-blurb {
    color: rgba(255, 255, 255, .65);
    font-size: .92rem;
    line-height: 1.55;
    margin: 1.25rem 0 1rem;
}
.site-footer--modern .footer-contact { margin: 0; font-size: .9rem; }
.site-footer--modern .footer-contact a {
    color: #fbbf24;
    border-bottom: 1px solid rgba(251, 191, 36, .4);
    padding-bottom: 1px;
}
.site-footer--modern .footer-contact a:hover { border-bottom-color: #fbbf24; text-decoration: none; }

.site-footer--modern .footer-cols {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.75rem;
}

/* Accent rule between top and bottom zones */
.footer-rule {
    height: 1px;
    background: linear-gradient(
        90deg,
        rgba(255, 255, 255, .04) 0%,
        rgba(255, 255, 255, .22) 50%,
        rgba(255, 255, 255, .04) 100%
    );
    margin: 0 0 1.5rem;
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    color: rgba(255, 255, 255, .55);
    font-size: .82rem;
}
.footer-bottom .footer-meta { color: rgba(255, 255, 255, .45); }
.footer-bottom .footer-meta a { color: rgba(255, 255, 255, .62); }
.footer-bottom .footer-meta a:hover { color: #fff; }

/* Responsive */
@media (max-width: 900px) {
    .site-footer--modern .footer-top {
        grid-template-columns: 1fr;
        gap: 2.25rem;
    }
    .site-footer--modern .footer-cols { grid-template-columns: repeat(2, 1fr); gap: 1.5rem 1.25rem; }
}
@media (max-width: 540px) {
    .site-footer { padding: 3rem 0 1.5rem; }
    .site-footer--modern .footer-cols { grid-template-columns: 1fr 1fr; }
    .footer-bottom { flex-direction: column; align-items: flex-start; }
}

/* ---- Journal detail header ---------------------------------------- */
.journal-header {
    background: linear-gradient(135deg, var(--tj-navy-800), var(--tj-blue-600));
    color: #fff;
    padding: 3rem 0;
}
.journal-header-grid {
    display: grid; grid-template-columns: 200px 1fr; gap: 2.5rem; align-items: flex-start;
}
.journal-cover {
    background: #c0392b; color: #fff;
    border-radius: 8px;
    padding: 1.25rem 1rem;
    text-align: center;
    aspect-ratio: 3/4;
    display: flex; flex-direction: column; justify-content: space-between;
}
.journal-cover .label { font-size: .75rem; opacity: .8; }
.journal-cover .title { font-family: var(--font-serif); font-size: 1.1rem; font-weight: 700; }
.journal-header h1 { color: #fff; font-size: 2.5rem; margin: 1rem 0 .5rem; }
.journal-header .badges { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: 1rem; }
.journal-header .meta-row { display: flex; flex-wrap: wrap; gap: 1.5rem; color: rgba(255,255,255,.85); font-size: .95rem; }
.journal-header .meta-row span { display: inline-flex; align-items: center; gap: .4rem; }

/* Two-column journal page */
.journal-body {
    display: grid; grid-template-columns: 2fr 1fr; gap: 2rem;
    padding-top: 3rem; padding-bottom: 3rem;
    /* keep horizontal padding from .container — don't override it */
}
.tabs {
    background: var(--tj-surface);
    border: 1px solid var(--tj-border);
    border-radius: var(--tj-radius);
    overflow: hidden;
}
.tab-bar { display: flex; gap: 0; border-bottom: 1px solid var(--tj-border); padding: 0 1rem; }
.tab-bar button {
    background: none; border: 0; padding: 1rem 1.25rem;
    font-family: inherit; font-size: .95rem; font-weight: 500;
    color: var(--tj-muted); cursor: pointer;
    border-bottom: 2px solid transparent;
}
.tab-bar button.active { color: var(--tj-text); border-bottom-color: var(--tj-blue-600); }
.tab-pane { display: none; padding: 1.75rem; }
.tab-pane.active { display: block; }

.sidebar-card {
    background: var(--tj-surface);
    border: 1px solid var(--tj-border);
    border-radius: var(--tj-radius);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}
.sidebar-card h3 { font-family: var(--font-sans); font-size: 1.1rem; margin-bottom: 1rem; }
.sidebar-card .info-block { margin-bottom: 1rem; }
.sidebar-card .info-block .label { font-size: .8rem; color: var(--tj-muted); text-transform: uppercase; letter-spacing: .04em; margin-bottom: .25rem; }
.sidebar-card .info-block .value { font-weight: 500; }

/* ---- Forms (auth + generic) --------------------------------------- */
.auth-wrap { min-height: calc(100vh - 200px); display: flex; align-items: center; justify-content: center; padding: 3rem 1.5rem; }
.auth-card {
    background: var(--tj-surface);
    border: 1px solid var(--tj-border);
    border-radius: var(--tj-radius);
    padding: 2.5rem;
    width: 100%; max-width: 460px;
}
.auth-card h1 { font-size: 2rem; margin-bottom: .5rem; text-align: center; }
.auth-card .sub { color: var(--tj-muted); text-align: center; margin-bottom: 2rem; }
.auth-card .auth-foot { text-align: center; margin-top: 1.25rem; color: var(--tj-muted); font-size: .9rem; }

.form-group { margin-bottom: 1.1rem; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.form-label { display: block; font-size: .9rem; font-weight: 500; margin-bottom: .4rem; color: var(--tj-text); }
.form-control {
    width: 100%; padding: .7rem .9rem;
    border: 1px solid var(--tj-border);
    border-radius: 8px;
    font-size: .95rem; font-family: inherit;
    background: #fff;
    transition: border-color .15s;
}
.form-control:focus { outline: 2px solid var(--tj-blue-600); outline-offset: 1px; border-color: var(--tj-blue-600); }
.form-help { font-size: .82rem; color: var(--tj-muted); margin-top: .3rem; }
.form-check { display: flex; align-items: center; gap: .5rem; font-size: .9rem; }

/* ---- Alerts -------------------------------------------------------- */
.alert {
    position: relative;
    padding: .85rem 2.5rem .85rem 1rem;
    border-radius: 8px;
    margin-bottom: 1.25rem;
    font-size: .92rem;
    border: 1px solid transparent;
}
.alert-success { background: var(--tj-success-bg); color: var(--tj-success-fg); border-color: #6ee7b7; }
.alert-error,
.alert-danger,
.alert-warning { background: var(--tj-danger-bg); color: var(--tj-danger-fg); border-color: #fca5a5; }
.alert-info    { background: var(--tj-info-bg); color: var(--tj-info-fg); border-color: #93c5fd; }
.alert-close {
    position: absolute;
    top: .5rem; right: .55rem;
    border: 0;
    background: transparent;
    color: inherit;
    opacity: .55;
    font-size: 1.25rem;
    line-height: 1;
    cursor: pointer;
    padding: .15rem .4rem;
    border-radius: 4px;
}
.alert-close:hover { opacity: 1; background: rgba(0,0,0,.06); }

/* ---- Page hero (smaller) ------------------------------------------ */
.page-hero {
    background: linear-gradient(135deg, var(--tj-navy-800), var(--tj-blue-600));
    color: #fff; padding: 3.5rem 0;
}
.page-hero h1 { color: #fff; font-size: 2.5rem; margin: 0; }
.page-hero p  { color: rgba(255,255,255,.85); margin-top: .5rem; max-width: 720px; }

/* ---- Article list (journal-style rows) ---------------------------- */
.article-list { background: #fff; border: 1px solid var(--tj-border); border-radius: var(--tj-radius); overflow: hidden; }
.article-row { padding: 1.25rem 1.5rem; border-bottom: 1px solid var(--tj-border); }
.article-row:last-child { border-bottom: 0; }
.article-row-title { margin: 0 0 .35rem; font-family: var(--font-serif); font-size: 1.2rem; font-weight: 700; line-height: 1.3; }
.article-row-title a { color: var(--tj-blue-600); text-decoration: none; transition: color .15s; }
.article-row-title a:hover { color: var(--tj-navy-800); text-decoration: none; }
.article-row-chevron { display: inline-block; margin-left: .25rem; font-weight: 400; color: var(--tj-blue-400); transition: color .15s; }
.article-row-title a:hover .article-row-chevron { color: var(--tj-blue-600); }
.article-row-authors { color: var(--tj-blue-600); font-size: .92rem; margin-bottom: .5rem; }
.article-row-meta { color: var(--tj-muted); font-size: .85rem; display: flex; align-items: center; gap: .5rem; flex-wrap: wrap; }
.article-row-type { color: var(--tj-blue-600); font-weight: 500; }
.article-row-divider { color: var(--tj-blue-400); }
.article-row-journal { font-style: italic; color: var(--tj-blue-600) !important; text-decoration: none; }
.article-row-journal:hover { text-decoration: underline; }

/* ---- 2-column article grid (homepage Latest Articles) ------------ */
.article-list--grid {
    background: transparent;
    border: 0;
    border-radius: 0;
    overflow: visible;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: .75rem 1.25rem;
}
.article-list--grid .article-row {
    padding: 1rem 1.25rem;
    border: 1px solid var(--tj-border);
    border-radius: 8px;
    background: #fff;
}
.article-list--grid .article-row-title { font-size: 1.05rem; }
.article-list--grid .article-row-abstract { font-size: .85rem; line-height: 1.5; }
.article-list--grid .article-row-meta { font-size: .78rem; }
@media (max-width: 900px) {
    .article-list--grid { grid-template-columns: 1fr; }
}

/* ---- Article detail (single page) -------------------------------- */
.article-head {
    background: linear-gradient(180deg, #f8f9fc 0%, #ffffff 100%);
    border-bottom: 1px solid var(--tj-border);
    padding: 3rem 0 1.5rem;
}
.article-head-type { font-size: .82rem; color: var(--tj-muted); text-transform: uppercase; letter-spacing: .06em; font-weight: 500; margin-bottom: .75rem; }
.article-head-title { font-family: var(--font-serif); font-size: 2.4rem; font-weight: 700; color: var(--tj-text); line-height: 1.18; margin: 0 0 1rem; }
.article-head-authors { color: var(--tj-blue-600); font-size: 1.05rem; margin-bottom: .85rem; font-weight: 500; }
.article-head-dates { color: var(--tj-muted); font-size: .92rem; margin-bottom: .85rem; }
.article-head-doi { font-size: .92rem; margin-bottom: 1.5rem; display: flex; align-items: center; gap: .4rem; }
.article-head-doi a { color: var(--tj-blue-600); }

.article-tabs { display: flex; gap: .25rem; flex-wrap: wrap; margin-top: 1.5rem; border-bottom: 1px solid var(--tj-border); padding-bottom: 0; }
.article-tab { display: inline-flex; align-items: center; gap: .4rem; padding: .7rem 1.1rem;
    background: transparent; border: 0; border-bottom: 3px solid transparent; cursor: pointer;
    color: var(--tj-muted); font-family: inherit; font-size: .92rem; font-weight: 500;
    text-decoration: none; transition: all .15s;
}
.article-tab:hover { color: var(--tj-navy-800); text-decoration: none; }
.article-tab.active { color: var(--tj-text); border-bottom-color: var(--tj-blue-600); background: var(--tj-navy-800); color: #fff; border-radius: 6px 6px 0 0; padding: .7rem 1.25rem; border-bottom-color: var(--tj-navy-800); }
.article-tab.read-btn { background: #4ade80; color: #064e3b; border-radius: 6px; margin-left: auto; padding: .65rem 1.25rem; font-weight: 600; }
.article-tab.read-btn:hover { background: #22c55e; color: #064e3b; }

.article-grid { display: grid; grid-template-columns: 2fr 1fr; gap: 3rem; max-width: 1200px; }
.article-content { font-size: 1.02rem; line-height: 1.75; color: var(--tj-text); }
.article-section-title { font-family: var(--font-serif); font-size: 1.7rem; font-weight: 700; margin: 0 0 1rem; color: var(--tj-text); }
.article-abstract { font-size: 1.02rem; line-height: 1.75; }
.article-keywords { color: var(--tj-muted); font-size: .95rem; margin: 1.5rem 0; padding: .85rem 1rem; background: #f8f9fc; border-radius: 6px; }
.article-body { font-size: 1.05rem; line-height: 1.8; }
.article-body h2, .article-body h3, .article-body h4 { font-family: var(--font-serif); margin-top: 2rem; margin-bottom: .75rem; }
.article-body h2 { font-size: 1.6rem; }
.article-body h3 { font-size: 1.3rem; }
.article-body p { margin-bottom: 1rem; }
.article-body ul, .article-body ol { margin: 1rem 0 1rem 1.5rem; padding: 0; }
.article-body li { margin-bottom: .35rem; }

/* CMS pages reuse the same rich-text typography */
.cms-content { font-size: 1.02rem; line-height: 1.75; color: var(--tj-text); }
.cms-content h2, .cms-content h3, .cms-content h4 { font-family: var(--font-serif); margin-top: 1.75rem; margin-bottom: .65rem; }
.cms-content h2 { font-size: 1.5rem; }
.cms-content h3 { font-size: 1.2rem; }
.cms-content p  { margin-bottom: 1rem; }
.cms-content ul, .cms-content ol { margin: 1rem 0 1rem 1.5rem; padding: 0; }
.cms-content li { margin-bottom: .35rem; }
.cms-content blockquote { border-left: 3px solid var(--tj-blue-600); padding: .25rem 1rem; margin: 1rem 0; color: var(--tj-muted); font-style: italic; }
.cms-content a { color: var(--tj-blue-600); text-decoration: underline; }
.cms-content .ql-align-center  { text-align: center; }
.cms-content .ql-align-right   { text-align: right; }
.cms-content .ql-align-justify { text-align: justify; }
.article-body blockquote { border-left: 3px solid var(--tj-blue-600); padding: .25rem 1rem; margin: 1rem 0; color: var(--tj-muted); font-style: italic; }
.article-body code { background: #f0f1f5; padding: .15rem .4rem; border-radius: 4px; font-size: .92em; }
.article-body pre { background: #1a2456; color: #e6e9fa; padding: 1rem; border-radius: 8px; overflow-x: auto; }
.article-body a { color: var(--tj-blue-600); text-decoration: underline; }
.article-body img { max-width: 100%; height: auto; border-radius: 6px; margin: 1rem 0; }
/* Quill alignment classes */
.article-body .ql-align-center  { text-align: center; }
.article-body .ql-align-right   { text-align: right; }
.article-body .ql-align-justify { text-align: justify; }

.related-list { list-style: none; padding: 0; margin: 0; }
.related-list li { padding: 1rem 0; border-bottom: 1px solid var(--tj-border); }
.related-list li:last-child { border-bottom: 0; }
.related-title { display: block; font-family: var(--font-serif); font-size: 1.05rem; font-weight: 600; color: var(--tj-blue-600); margin-bottom: .25rem; }
.related-title:hover { text-decoration: none; color: var(--tj-navy-800); }
.related-authors { color: var(--tj-text); font-size: .88rem; margin-bottom: .15rem; }
.related-meta { color: var(--tj-muted); font-size: .82rem; }

.article-sidebar { font-size: .92rem; }
.article-sidebar h3 { font-family: var(--font-sans); font-size: .8rem; color: var(--tj-muted); text-transform: uppercase; letter-spacing: .06em; margin: 0 0 .75rem; padding-bottom: .5rem; border-bottom: 1px solid var(--tj-border); }
.article-sidebar ul { list-style: none; padding: 0; margin: 0; }
.article-sidebar li { padding: .35rem 0; }
.article-sidebar li a { color: var(--tj-text); }
.article-sidebar li a:hover { color: var(--tj-blue-600); }
.cite-box { background: #f8f9fc; border-left: 3px solid var(--tj-blue-600); padding: .85rem 1rem; font-size: .88rem; line-height: 1.55; border-radius: 0 6px 6px 0; }
.cite-box a { word-break: break-all; }

@media (max-width: 900px) {
    .article-grid { grid-template-columns: 1fr; gap: 2rem; }
    .article-head-title { font-size: 1.7rem; }
    .article-tab.read-btn { margin-left: 0; width: 100%; justify-content: center; }
}

/* ---- Empty state -------------------------------------------------- */
.empty-state { text-align: center; padding: 3rem 1rem; color: var(--tj-muted); }

/* ---- Floating "back to top" -------------------------------------- */
.back-to-top {
    position: fixed; bottom: 2rem; right: 2rem;
    width: 48px; height: 48px;
    border-radius: 50%;
    background: var(--tj-blue-600); color: #fff;
    display: none; align-items: center; justify-content: center;
    border: 0; cursor: pointer; font-size: 1.2rem;
    z-index: 40;
}
.back-to-top.visible { display: inline-flex; }

/* ---- Mobile -------------------------------------------------------- */
.nav-toggle {
    display: none; background: none; border: 0; color: #fff; font-size: 1.4rem; cursor: pointer;
}

@media (max-width: 900px) {
    h1 { font-size: 2.2rem; }
    h2 { font-size: 1.75rem; }
    .hero h1 { font-size: 2.4rem; }
    .hero { padding: 3rem 0 4rem; }
    .hero-grid,
    .journal-header-grid,
    .journal-body { grid-template-columns: 1fr; }
    .features-grid { grid-template-columns: repeat(2, 1fr); }
    .footer-grid { grid-template-columns: 1fr 1fr; }
    .stats-grid  { grid-template-columns: repeat(2, 1fr); gap: 1.5rem; }

    .nav-toggle { display: inline-flex; }
    .nav-main, .nav-actions {
        display: none; width: 100%;
        flex-direction: column; align-items: stretch; gap: .25rem;
        margin-top: 1rem;
    }
    .site-header .container { flex-wrap: wrap; }
    body.nav-open .nav-main,
    body.nav-open .nav-actions { display: flex; }
}
@media (max-width: 540px) {
    .features-grid,
    .footer-grid,
    .stats-grid { grid-template-columns: 1fr; }
    .form-row { grid-template-columns: 1fr; }
}

/* =====================================================================
   Dashboard layout (sidebar + content), used for /dashboard, /author/*,
   /manage/*. No public site header/footer is rendered.
   ===================================================================== */
.dashboard-body { background: #f5f6fa; }

.dashboard-shell {
    display: grid;
    grid-template-columns: 264px 1fr;
    min-height: 100vh;
}

/* ---- Sidebar ------------------------------------------------------- */
.dashboard-sidebar {
    background: var(--tj-navy-900);
    color: rgba(255,255,255,.78);
    display: flex; flex-direction: column;
    position: sticky; top: 0;
    height: 100vh; max-height: 100vh;
    overflow-y: auto;
    padding: 1.25rem 0 1rem;
    /* Firefox: thin scrollbar */
    scrollbar-width: thin;
    scrollbar-color: rgba(255,255,255,.18) transparent;
}
.dashboard-sidebar::-webkit-scrollbar { width: 4px; }
.dashboard-sidebar::-webkit-scrollbar-track { background: transparent; }
.dashboard-sidebar::-webkit-scrollbar-thumb { background: rgba(255,255,255,.14); border-radius: 2px; }
.dashboard-sidebar::-webkit-scrollbar-thumb:hover { background: rgba(255,255,255,.28); }

.dashboard-brand { padding: .25rem 1.5rem 1.25rem; border-bottom: 1px solid rgba(255,255,255,.08); }
.dashboard-brand-link { display: flex; align-items: center; gap: .85rem; color: #fff; text-decoration: none; }
.dashboard-brand-link:hover { text-decoration: none; }

/* Sidebar TJ monogram — same circle treatment as the header, sized down. */
.dashboard-brand-monogram {
    width: 40px; height: 40px;
    border-color: rgba(255, 255, 255, .35);
    color: #fff;
}
.dashboard-brand-monogram > span { font-size: 1rem; }
.dashboard-brand-logo {
    width: 38px; height: 38px;
    border-radius: 9px;
    display: block;
    flex-shrink: 0;
    /* shadow removed per visual policy */
}
.dashboard-brand-text { line-height: 1.15; }
.dashboard-brand-name { font-family: var(--font-serif); font-size: 1.15rem; font-weight: 700; display: block; color: #fff; }
.dashboard-brand-tagline { font-size: .72rem; color: rgba(255,255,255,.55); text-transform: uppercase; letter-spacing: .06em; }

.dashboard-userblock {
    display: flex; align-items: center; gap: .75rem;
    padding: 1rem 1.5rem 1.25rem;
    border-bottom: 1px solid rgba(255,255,255,.08);
}
.dashboard-user-avatar {
    width: 40px; height: 40px;
    background: linear-gradient(135deg, var(--tj-blue-500), var(--tj-blue-400));
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    color: #fff; font-weight: 600; font-size: .92rem;
    flex-shrink: 0;
}
.dashboard-user-info { min-width: 0; flex: 1; }
.dashboard-user-name { color: #fff; font-weight: 600; font-size: .92rem; line-height: 1.2; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dashboard-user-role { color: rgba(255,255,255,.55); font-size: .78rem; margin-top: .15rem; text-transform: uppercase; letter-spacing: .04em; }

.dashboard-nav { flex: 1; padding: .5rem .75rem; }
.dashboard-nav-group { margin-bottom: 1rem; }
.dashboard-nav-label {
    color: rgba(255,255,255,.4);
    font-size: .68rem; font-weight: 600;
    text-transform: uppercase; letter-spacing: .08em;
    padding: .85rem .75rem .35rem;
}
.dashboard-nav-item {
    display: flex; align-items: center; gap: 12px;
    padding: .65rem .75rem;
    border-radius: 8px;
    color: rgba(255, 255, 255, .88);
    font-size: .92rem; font-weight: 500;
    text-decoration: none;
    margin-bottom: .15rem;
    /* No transition / no transform — visual policy: instant feedback only. */
}
.dashboard-nav-item:hover {
    background: rgba(255, 255, 255, .08);
    color: #ffffff;
    text-decoration: none;
}
.dashboard-nav-item.active {
    background: var(--tj-blue-600);
    color: #ffffff;
}
.dashboard-nav-item.disabled { opacity: .55; cursor: not-allowed; }

/* Icon slot — fixed 20×20 box that centers a monochrome SVG. The SVG
   inherits the item's text color via currentColor, so:
     - inactive item → icon at rgba(255,255,255,.88)
     - hover         → icon at #fff
     - active        → icon at #fff
   No fills, no gradients, no shadows. */
.dashboard-nav-icon {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: inherit;
}
.dashboard-nav-icon svg {
    width: 20px;
    height: 20px;
    display: block;
    stroke: currentColor;
    fill: none;
}
.dashboard-nav-item.active .dashboard-nav-icon,
.dashboard-nav-item:hover  .dashboard-nav-icon { color: #ffffff; }

.dashboard-nav-text { flex: 1; }
.dashboard-nav-badge {
    background: rgba(255,255,255,.12);
    color: rgba(255,255,255,.7);
    font-size: .65rem; font-weight: 700;
    padding: .15rem .45rem;
    border-radius: 999px;
    text-transform: uppercase;
}

.dashboard-sidebar-foot { padding: .5rem .75rem 0; border-top: 1px solid rgba(255,255,255,.08); margin-top: .5rem; }
.dashboard-nav-signout:hover { background: rgba(220,38,38,.15); color: #fca5a5; }

/* ---- Main column (top bar + content) ------------------------------ */
.dashboard-main { display: flex; flex-direction: column; min-width: 0; }

.dashboard-topbar {
    display: flex; align-items: center; gap: 1rem;
    background: #fff;
    border-bottom: 1px solid var(--tj-border);
    padding: .85rem 1.75rem;
    position: sticky; top: 0; z-index: 20;
}
.dashboard-toggle {
    display: none;
    background: none; border: 0;
    font-size: 1.4rem; color: var(--tj-text); cursor: pointer;
}
.dashboard-crumb { flex: 1; font-size: .9rem; }
.dashboard-crumb a { color: var(--tj-muted); text-decoration: none; }
.dashboard-crumb a:hover { color: var(--tj-blue-600); }

.dashboard-userchip {
    display: flex; align-items: center; gap: .65rem;
    padding: .35rem .35rem .35rem .75rem;
    background: #f8f9fc;
    border: 1px solid var(--tj-border);
    border-radius: 999px;
    font-size: .88rem;
}

/* ---- Notifications bell ------------------------------------------- */
.dashboard-bell { position: relative; }
.dashboard-bell-btn {
    background: #f8f9fc; border: 1px solid var(--tj-border);
    width: 38px; height: 38px; border-radius: 50%;
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 1.05rem; color: var(--tj-text); cursor: pointer; position: relative;
    transition: background .15s, border-color .15s;
}
.dashboard-bell-btn:hover { background: #fff; border-color: var(--tj-blue-400); }
.dashboard-bell-badge {
    position: absolute; top: -4px; right: -4px;
    min-width: 18px; height: 18px; padding: 0 5px;
    background: #ef4444; color: #fff;
    border-radius: 999px;
    font-size: .68rem; font-weight: 700; line-height: 18px; text-align: center;
    border: 2px solid #fff;
}
.dashboard-bell-menu {
    position: absolute; top: calc(100% + .5rem); right: 0;
    width: 360px; max-width: calc(100vw - 2rem);
    background: #fff; border: 1px solid var(--tj-border);
    border-radius: 12px; border: 1px solid var(--tj-border);
    z-index: 30; overflow: hidden;
}
.dashboard-bell-head {
    display: flex; justify-content: space-between; align-items: center;
    padding: .75rem 1rem; border-bottom: 1px solid var(--tj-border);
    font-size: .92rem;
}
.dashboard-bell-head a { color: var(--tj-blue-600); text-decoration: none; font-size: .82rem; }
.dashboard-bell-head a:hover { text-decoration: underline; }
.dashboard-bell-empty {
    padding: 1.5rem 1rem; text-align: center; color: var(--tj-muted); font-size: .88rem;
}
.dashboard-bell-list { list-style: none; margin: 0; padding: 0; max-height: 360px; overflow-y: auto; }
.dashboard-bell-list li { border-top: 1px solid var(--tj-border); }
.dashboard-bell-list li:first-child { border-top: 0; }
.dashboard-bell-list li.is-unread { background: #f4f6fc; }
.dashboard-bell-item {
    display: block; width: 100%; text-align: left;
    background: transparent; border: 0; cursor: pointer;
    padding: .7rem 1rem; font-family: inherit;
    transition: background .12s;
}
.dashboard-bell-item:hover { background: #eef0f8; }
.dashboard-bell-item strong { display: block; font-size: .88rem; color: var(--tj-text); }
.dashboard-bell-item span { display: block; font-size: .82rem; color: var(--tj-muted); margin-top: .15rem; }
.dashboard-bell-item em { display: block; font-style: normal; font-size: .74rem; color: var(--tj-muted); margin-top: .35rem; }

/* ---- Pagination --------------------------------------------------- */
.tj-pagination {
    display: flex; gap: .35rem; justify-content: center; align-items: center;
    margin-top: 2rem; flex-wrap: wrap;
}
.tj-page-link {
    display: inline-flex; align-items: center;
    min-width: 36px; height: 36px; padding: 0 .65rem;
    background: #fff; border: 1px solid var(--tj-border);
    border-radius: 8px;
    color: var(--tj-text); text-decoration: none;
    font-size: .88rem; font-weight: 500;
    transition: background .12s, border-color .12s, color .12s;
}
.tj-page-link:hover { background: #f1f3f9; border-color: var(--tj-blue-400); color: var(--tj-blue-600); text-decoration: none; }
.tj-page-link.is-active { background: var(--tj-blue-600); color: #fff; border-color: var(--tj-blue-600); }
.tj-page-gap { color: var(--tj-muted); padding: 0 .25rem; }

/* ---- Journals filter bar ----------------------------------------- */
.tj-filterbar {
    background: #fff; border: 1px solid var(--tj-border); border-radius: 12px;
    padding: 1rem 1.25rem; margin-bottom: 1.75rem;
    display: flex; gap: .75rem; align-items: center; flex-wrap: wrap;
}
.tj-filterbar input[type="search"], .tj-filterbar select {
    padding: .55rem .85rem; border: 1px solid var(--tj-border); border-radius: 8px;
    font-size: .92rem; font-family: inherit; background: #f8f9fc;
}
.tj-filterbar input[type="search"] { flex: 1; min-width: 220px; }
.tj-filterbar input[type="search"]:focus, .tj-filterbar select:focus {
    outline: 2px solid var(--tj-blue-400); border-color: var(--tj-blue-500); background: #fff;
}
.tj-filterbar-meta { color: var(--tj-muted); font-size: .85rem; margin-left: auto; }

/* ---- Article row with thumbnail (home page) ----------------------- */
.article-row-thumb {
    display: flex; gap: 1.25rem; align-items: stretch;
}
.article-row-thumb .article-row-body { flex: 1; min-width: 0; }
.article-row-cover {
    flex-shrink: 0;
    width: 110px; min-height: 140px;
    border-radius: 8px; overflow: hidden;
    background: linear-gradient(135deg, var(--tj-blue-600), var(--tj-navy-800));
    display: flex; align-items: center; justify-content: center;
    text-decoration: none;
    border: 1px solid var(--tj-border);
}
.article-row-cover:hover { border-color: var(--tj-blue-400); }
.article-row-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.article-row-cover-fallback {
    color: #fff; font-family: var(--font-serif); font-weight: 700; font-size: 1.5rem;
    letter-spacing: .05em;
}
@media (max-width: 640px) {
    .article-row-thumb { flex-direction: column-reverse; }
    .article-row-cover { width: 100%; min-height: 160px; max-height: 200px; }
}
.dashboard-context {
    display: inline-flex; align-items: center; gap: .35rem;
    background: #fff7ed; color: #92400e;
    border: 1px solid #fcd34d;
    padding: .25rem .55rem;
    border-radius: 999px;
    font-size: .78rem; font-weight: 600;
    cursor: pointer;
}
.dashboard-context select {
    border: 0; background: transparent; font-family: inherit; font-size: .78rem;
    font-weight: 600; color: #92400e; cursor: pointer; padding: 0; margin-left: .25rem;
}
.dashboard-context select:focus { outline: 2px solid #fcd34d; border-radius: 4px; }
.dashboard-userchip-avatar {
    width: 28px; height: 28px;
    background: linear-gradient(135deg, var(--tj-blue-500), var(--tj-blue-400));
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    color: #fff; font-weight: 600; font-size: .7rem;
}
.dashboard-userchip-name { color: var(--tj-text); font-weight: 500; }
.dashboard-signout {
    width: 28px; height: 28px;
    background: var(--tj-danger-bg);
    color: var(--tj-danger-fg);
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    text-decoration: none;
    font-size: 1rem;
}
.dashboard-signout:hover { background: #fca5a5; text-decoration: none; }

.dashboard-flash { padding: 1rem 1.75rem 0; }

.dashboard-content { flex: 1; padding: 0; }

/* Inside the dashboard, override page-hero to look like a compact page header */
.dashboard-content .page-hero {
    background: #fff;
    color: var(--tj-text);
    padding: 1.75rem 1.75rem 1.25rem;
    border-bottom: 1px solid var(--tj-border);
}
.dashboard-content .page-hero h1 { color: var(--tj-text); font-size: 1.85rem; }
.dashboard-content .page-hero p { color: var(--tj-muted); }
.dashboard-content .page-hero .btn-light { background: var(--tj-blue-600); color: #fff; }
.dashboard-content .page-hero .btn-light:hover { background: var(--tj-blue-500); }
/* Page-hero (sub-page header inside dashboard) — text colors now use .tj-* classes */
.dashboard-content .page-hero .tj-breadcrumb,
.dashboard-content .page-hero .tj-subtitle { color: var(--tj-muted); }
.dashboard-content .page-hero .tj-breadcrumb a { color: var(--tj-blue-600); text-decoration: none; }
.dashboard-content .page-hero .tj-breadcrumb a:hover { text-decoration: underline; }

/* Tab pills used in journal_nav and wizard_nav */
.tj-breadcrumb { margin: 0 0 .25rem; font-size: .85rem; }
.tj-subtitle   { margin: 0; font-size: .9rem; }
.tj-tabs       { display: flex; gap: .35rem; flex-wrap: wrap; margin-top: 1.25rem; }
.tj-tab {
    display: inline-flex; align-items: center; gap: .5rem;
    padding: .45rem .9rem;
    border-radius: 7px;
    font-size: .85rem; font-weight: 500;
    color: var(--tj-muted);
    background: transparent;
    text-decoration: none;
    transition: background .15s, color .15s;
}
.tj-tab:hover, .tj-tab:visited { color: var(--tj-text); text-decoration: none; }
.tj-tab.is-active, .tj-tab.is-active:visited {
    background: var(--tj-blue-600);
    color: #fff;
}
/* Wizard step pills */
.tj-tab-step { background: #f0f1f5; }
.tj-tab-step:not(.is-reached) { opacity: .55; cursor: not-allowed; }
.tj-tab-step.is-active, .tj-tab-step.is-active:visited {
    background: var(--tj-blue-600); color: #fff;
}
.tj-step-num {
    display: inline-flex; align-items: center; justify-content: center;
    width: 18px; height: 18px; border-radius: 50%;
    background: rgba(0,0,0,.08);
    font-size: .68rem; font-weight: 700;
    color: inherit;
}
.tj-tab.is-active .tj-step-num,
.tj-tab-step.is-active .tj-step-num { background: rgba(255,255,255,.25); }

.dashboard-content .section { padding: 1.5rem 1.75rem; }
.dashboard-content .container { padding: 0; max-width: none; }

/* ---- Mobile dashboard ---------------------------------------------- */
@media (max-width: 900px) {
    .dashboard-shell { grid-template-columns: 1fr; }
    .dashboard-sidebar {
        position: fixed; top: 0; left: 0;
        width: 280px; height: 100vh;
        transform: translateX(-100%);
        /* transition removed per visual policy (snap, no slide) */
        z-index: 100;
        border-right: 1px solid rgba(255,255,255,.08);
    }
    body.sidebar-open .dashboard-sidebar { transform: translateX(0); }
    body.sidebar-open::after {
        content: ''; position: fixed; inset: 0;
        background: rgba(0,0,0,.4); z-index: 99;
    }
    .dashboard-toggle { display: inline-flex; }

    /* Wide admin/manage tables (subscriptions, charges, logs, …) can have
       6-8 columns and would force the viewport to zoom out on phones.
       Make any dashboard table scroll horizontally inside its container
       instead, with a sticky header row for context. */
    .dashboard-content table {
        display: block;
        overflow-x: auto;
        max-width: 100%;
        -webkit-overflow-scrolling: touch;
    }
    .dashboard-content table thead th { white-space: nowrap; }
    /* Tables that already sit inside a wrapper div with overflow:auto
       (issues, dashboards, etc.) keep behaving as block elements — the
       outer wrapper handles scroll; the inner table fits naturally. */
}

/* =====================================================================
   Dashboard hub (per-role overview with metrics + charts)
   ===================================================================== */
.dash-hero {
    display: flex; justify-content: space-between; align-items: center;
    flex-wrap: wrap; gap: 1rem;
    padding: 2rem 1.75rem 1.25rem;
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fc 100%);
    border-bottom: 1px solid var(--tj-border);
}
.dash-hero h1 { font-family: var(--font-serif); font-size: 1.85rem; margin: 0 0 .15rem; }
.dash-hero-eyebrow { color: var(--tj-blue-600); font-size: .78rem; text-transform: uppercase;
    letter-spacing: .08em; font-weight: 600; margin: 0 0 .15rem; }
.dash-hero-sub { color: var(--tj-muted); margin: 0; }

.dash-metrics {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 1.25rem;
    padding: 1.5rem 1.75rem 0;
}
.dash-metric {
    background: #fff;
    border: 1px solid var(--tj-border);
    border-radius: 12px;
    padding: 1.25rem;
    display: flex; align-items: center; gap: 1rem;
    transition: border-color .15s;
}
.dash-metric:hover { border-color: var(--tj-blue-400); }
.dash-metric-icon {
    width: 48px; height: 48px;
    border-radius: 12px;
    display: flex; align-items: center; justify-content: center;
    font-size: 1.4rem;
    flex-shrink: 0;
}
.dash-metric-body { min-width: 0; }
.dash-metric-label { color: var(--tj-muted); font-size: .82rem; text-transform: uppercase;
    letter-spacing: .04em; font-weight: 500; }
.dash-metric-value { font-family: var(--font-serif); font-size: 2rem; font-weight: 700; color: var(--tj-text); line-height: 1.1; margin: .15rem 0; }
.dash-metric-sub { color: var(--tj-muted); font-size: .82rem; }

.dash-metric.tone-blue  .dash-metric-icon { background: #e6e9fa; color: #4f5ec5; }
.dash-metric.tone-navy  .dash-metric-icon { background: #d1d5e8; color: #1a2456; }
.dash-metric.tone-green .dash-metric-icon { background: #d1fae5; color: #065f46; }
.dash-metric.tone-amber .dash-metric-icon { background: #fef3c7; color: #92400e; }
.dash-metric.tone-red   .dash-metric-icon { background: #fee2e2; color: #991b1b; }

.dash-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.25rem;
    padding: 1.5rem 1.75rem;
}
.dash-card {
    background: #fff;
    border: 1px solid var(--tj-border);
    border-radius: 12px;
    padding: 1.5rem;
    min-height: 200px;
}
.dash-card-wide { grid-column: 1 / -1; }
.dash-card-head {
    display: flex; justify-content: space-between; align-items: baseline;
    gap: 1rem; margin-bottom: 1rem;
}
.dash-card-head h3 { font-family: var(--font-sans); font-size: 1.05rem; font-weight: 600; margin: 0; }
.dash-card-sub  { color: var(--tj-muted); font-size: .82rem; }
.dash-card-link { font-size: .85rem; color: var(--tj-blue-600); text-decoration: none; font-weight: 500; }
.dash-card-link:hover { text-decoration: underline; }

/* Chart wrappers — guarantee a bounded height for Chart.js (responsive: true, maintainAspectRatio: false) */
.dash-chart           { position: relative; height: 280px; width: 100%; }
.dash-chart-doughnut  { height: 240px; max-width: 320px; margin: 0 auto; }

/* =====================================================================
   Issues archive — grid of cover cards
   ===================================================================== */
.issues-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 1.5rem; }
.issue-card {
    background: #fff;
    border: 1px solid var(--tj-border);
    border-radius: var(--tj-radius);
    overflow: hidden;
    text-decoration: none;
    color: inherit;
    display: flex; flex-direction: column;
    transition: border-color .15s;
}
.issue-card:hover { border-color: var(--tj-blue-400); text-decoration: none; }
.issue-card-cover { width: 100%; aspect-ratio: 3/4; object-fit: cover; display: block; }
.issue-card-cover-placeholder {
    width: 100%; aspect-ratio: 3/4;
    background: linear-gradient(135deg, var(--tj-navy-800), var(--tj-blue-600));
    color: #fff;
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    font-family: var(--font-serif);
}
.issue-card-cover-placeholder .vol { font-size: 1.4rem; font-weight: 700; }
.issue-card-cover-placeholder .num { font-size: 1rem; opacity: .85; }
.issue-card-body { padding: 1rem 1.25rem 1.25rem; }
.issue-card-body h3 { font-family: var(--font-serif); font-size: 1.05rem; margin: .35rem 0 .25rem; }
.issue-card-title { color: var(--tj-blue-600); font-size: .92rem; line-height: 1.35; margin-bottom: .35rem; }
.issue-card-meta { color: var(--tj-muted); font-size: .82rem; }

/* =====================================================================
   Article individual page (/articles/{id}) — full scientific layout
   ===================================================================== */
.sr-only { position: absolute !important; width: 1px; height: 1px;
    padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }

/* ---- Skip-to-content link (keyboard a11y) ------------------------- */
.skip-link {
    position: absolute; top: 0; left: 0;
    padding: .65rem 1.1rem;
    background: var(--tj-blue-600); color: #fff;
    border-radius: 0 0 8px 0;
    text-decoration: none; font-weight: 600; font-size: .92rem;
    z-index: 1000;
    transform: translateY(-110%);
}
.skip-link:focus { transform: translateY(0); outline: 2px solid #fff; outline-offset: -4px; }

/* ---- Focus-visible (keyboard users see focus, mouse users don't) -- */
:focus { outline: none; }
:focus-visible {
    outline: 2px solid var(--tj-blue-600);
    outline-offset: 2px;
    border-radius: 4px;
}
.btn:focus-visible,
.form-control:focus-visible,
.tj-page-link:focus-visible,
.dashboard-nav-item:focus-visible,
.dashboard-bell-btn:focus-visible {
    outline: 2px solid var(--tj-blue-600);
    outline-offset: 2px;
}
/* Inside the dark sidebar, foco amarelo destaca melhor */
.dashboard-sidebar a:focus-visible,
.dashboard-sidebar button:focus-visible {
    outline: 2px solid #fbbf24;
    outline-offset: 2px;
}

/* ---- Disabled state (consistent across buttons/inputs) ------------ */
.btn:disabled,
.btn[aria-disabled="true"],
.form-control:disabled {
    opacity: .5;
    cursor: not-allowed;
    pointer-events: none;
}

/* ---- Responsive table wrapper for the dashboard ------------------- */
.table-responsive {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border-radius: var(--tj-radius);
}
.table-responsive table { min-width: 100%; }

/* On narrow viewports, let dashboard tables scroll horizontally inside
   their card containers instead of forcing the whole page to scroll. */
@media (max-width: 768px) {
    .dashboard-content section .container > div { overflow-x: auto; }
    .dashboard-content table { font-size: .82rem; }
}

.art-head {
    background: linear-gradient(180deg, #f8f9fc 0%, #ffffff 100%);
    border-bottom: 1px solid var(--tj-border);
    padding: 2rem 0 1.25rem;
}
/* Override default `.section { padding: 4rem 0 }` for the article body wrap */
.section.art-section-wrap { padding: 1.5rem 0 3rem; }
.art-head-crumb { margin: 0 0 .5rem; font-size: .9rem; }
.art-head-crumb a { color: var(--tj-blue-600); text-decoration: none; }
.art-head-crumb a:hover { text-decoration: underline; }
.art-head-type {
    color: var(--tj-muted); font-size: .78rem; font-weight: 500;
    text-transform: uppercase; letter-spacing: .06em; margin: 0 0 .5rem;
}
.art-head-title {
    font-family: var(--font-sans);
    font-size: 1.95rem; font-weight: 700; line-height: 1.2;
    color: var(--tj-text); margin: 0 0 1rem;
}
.art-head-authors { color: var(--tj-text); margin: 0 0 .85rem; line-height: 1.7; font-size: .98rem; }
.art-author { display: inline; }
.art-author-corresp { color: var(--tj-blue-600); margin-left: .15rem; cursor: help; }
.art-author-orcid {
    display: inline-flex; align-items: center; justify-content: center;
    width: 16px; height: 16px;
    background: #a6ce39; color: #fff;
    border-radius: 50%; margin-left: .15rem;
    font-size: .55rem; font-weight: 700;
    text-decoration: none; vertical-align: middle;
}
.art-author-orcid:hover { background: #8fb429; text-decoration: none; }
.art-author-aff { color: var(--tj-muted); font-size: .85rem; }

.art-head-dates { color: var(--tj-muted); font-size: .9rem; margin: 0 0 .75rem; }
.art-head-doi { font-size: .9rem; margin: 0 0 1.25rem; display: flex; align-items: center; gap: .5rem; flex-wrap: wrap; }
.art-head-doi a { color: var(--tj-blue-600); word-break: break-all; }
.art-doi-copy {
    background: #fff; border: 1px solid var(--tj-border);
    color: var(--tj-blue-600);
    padding: .25rem .65rem; border-radius: 6px;
    font-size: .78rem; font-family: inherit; cursor: pointer;
    transition: background .15s;
}
.art-doi-copy:hover { background: var(--tj-blue-100); }

.art-actions { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: 1rem; }
.art-btn {
    display: inline-flex; align-items: center; gap: .35rem;
    padding: .55rem 1rem;
    border-radius: 7px;
    font-size: .85rem; font-weight: 600;
    text-decoration: none;
    border: 1px solid transparent;
    cursor: pointer; font-family: inherit;
}
.art-btn--primary { background: var(--tj-blue-600); color: #fff; }
.art-btn--primary:hover { background: var(--tj-blue-500); color: #fff; text-decoration: none; }
.art-btn--ghost { background: #fff; color: var(--tj-text); border-color: var(--tj-border); }
.art-btn--ghost:hover { background: #f8f9fc; text-decoration: none; }
.art-btn--disabled { opacity: .55; cursor: not-allowed; }

.art-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 280px;
    gap: 2rem;
    padding-top: 2rem;
    padding-bottom: 2rem;
    align-items: flex-start;
}
.art-content { min-width: 0; }
.art-section { margin-bottom: 2rem; scroll-margin-top: 80px; }
.art-section h2 {
    font-family: var(--font-sans);
    font-size: 1.3rem; font-weight: 700;
    color: var(--tj-text);
    margin: 0 0 .75rem;
    padding-bottom: .35rem;
    border-bottom: 2px solid var(--tj-blue-600);
    display: inline-block;
}
.art-section p { line-height: 1.7; }

.art-cite-block { background: #fff; border: 1px solid var(--tj-border); border-radius: 10px; padding: 1rem 1.25rem; margin-bottom: 2rem; }
.art-cite-block summary { cursor: pointer; font-weight: 600; color: var(--tj-text); list-style: none; }
.art-cite-block summary::-webkit-details-marker { display: none; }
.art-cite-block summary::before { content: '▸ '; color: var(--tj-blue-600); }
.art-cite-block[open] summary::before { content: '▾ '; }
.art-cite-row { padding: 1rem 0; border-top: 1px solid var(--tj-border); }
.art-cite-row:first-of-type { border-top: 0; padding-top: 1rem; }
.art-cite-row h4 { margin: 0 0 .5rem; font-size: .82rem; color: var(--tj-blue-600); text-transform: uppercase; letter-spacing: .06em; font-weight: 700; }
.art-cite-row p { margin: 0 0 .5rem; line-height: 1.6; font-size: .92rem; }
.art-link { background: none; border: 0; padding: 0; color: var(--tj-blue-600); font-family: inherit; font-size: .82rem; cursor: pointer; }
.art-link:hover { text-decoration: underline; }

.art-keywords-block { background: #f8f9fc; padding: .85rem 1rem; border-radius: 6px; }
.art-kw {
    display: inline-block;
    background: #fff; color: var(--tj-blue-600);
    padding: .15rem .65rem; border-radius: 999px;
    font-size: .82rem; margin: 0 .25rem;
    text-decoration: none; border: 1px solid var(--tj-border);
}
.art-kw:hover { background: var(--tj-blue-100); border-color: var(--tj-blue-400); text-decoration: none; }

.art-refs { padding-left: 1.5rem; margin: 0; }
.art-refs li { margin-bottom: .65rem; line-height: 1.55; font-size: .92rem; color: var(--tj-text); overflow-wrap: anywhere; }

.art-sidebar { display: flex; flex-direction: column; gap: 1.25rem; position: sticky; top: 80px; }
.art-card, .art-nav {
    background: #fff; border: 1px solid var(--tj-border); border-radius: 10px; padding: 1.1rem 1.25rem;
}
.art-nav h3, .art-card h3 {
    font-family: var(--font-sans); font-size: .78rem;
    color: var(--tj-muted); text-transform: uppercase; letter-spacing: .06em; font-weight: 600;
    margin: 0 0 .75rem; padding-bottom: .5rem; border-bottom: 1px solid var(--tj-border);
}
.art-nav ul { list-style: none; padding: 0; margin: 0; }
.art-nav li { padding: .3rem 0; }
.art-nav a {
    color: var(--tj-text); text-decoration: none; font-size: .88rem;
    display: block; padding-left: .6rem; border-left: 2px solid transparent;
}
.art-nav a:hover { color: var(--tj-blue-600); border-left-color: var(--tj-blue-400); }

.art-metrics-row { display: grid; grid-template-columns: 1fr 1fr; text-align: center; gap: .75rem; }
.art-metrics-num { font-size: 1.4rem; font-weight: 700; color: var(--tj-blue-600); line-height: 1; }
.art-metrics-lbl { color: var(--tj-muted); font-size: .76rem; text-transform: uppercase; letter-spacing: .04em; margin-top: .15rem; }

@media (max-width: 900px) {
    .art-grid { grid-template-columns: 1fr; padding-top: 1.25rem; }
    .art-head { padding: 1.5rem 0 1.25rem; }
    .art-head-title { font-size: 1.5rem; }
    .art-sidebar { position: static; }
}

/* =====================================================================
   Journal individual page (/journals/{slug})
   ===================================================================== */
.journal-hero {
    background: linear-gradient(135deg, var(--tj-navy-900) 0%, var(--tj-navy-700) 50%, var(--tj-blue-600) 100%);
    color: #fff;
    padding: 2.5rem 0;
}
.journal-hero-grid {
    display: grid;
    grid-template-columns: 200px minmax(0, 1fr);
    gap: 2rem;
    align-items: flex-start;
}
.journal-hero-cover img,
.journal-hero-cover-placeholder {
    width: 200px;
    aspect-ratio: 3 / 4;
    border-radius: 10px;
    /* shadow removed per visual policy */
    object-fit: cover;
    display: block;
}
.journal-hero-cover-placeholder {
    background: rgba(255,255,255,.08);
    border: 1px solid rgba(255,255,255,.18);
    display: flex; flex-direction: column;
    align-items: center; justify-content: center;
    gap: .35rem;
    color: #fff;
}
.journal-hero-cover-placeholder .mono { font-size: 2.4rem; font-weight: 700; letter-spacing: .04em; }
.journal-hero-cover-placeholder .lbl  { font-size: .7rem; opacity: .65; text-transform: uppercase; letter-spacing: .08em; }

.journal-hero-info { min-width: 0; }
.journal-hero-badges { display: flex; flex-wrap: wrap; gap: .4rem; margin-bottom: 1rem; }
.jc-badge--ghost { background: rgba(255,255,255,.18); color: #fff; }

.journal-hero-title {
    font-family: var(--font-sans);
    font-size: 2rem; font-weight: 700; line-height: 1.2;
    color: #fff; margin: 0 0 .25rem;
}
.journal-hero-abbrev { color: rgba(255,255,255,.7); margin: 0 0 1rem; font-size: .92rem; letter-spacing: .04em; }

.journal-hero-meta {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: .75rem 1.5rem;
    margin: 0 0 1.25rem;
}
.journal-hero-meta > div { min-width: 0; }
.journal-hero-meta dt {
    color: rgba(255,255,255,.6);
    font-size: .7rem; text-transform: uppercase; letter-spacing: .05em; font-weight: 500;
    margin: 0 0 .15rem;
}
.journal-hero-meta dd { margin: 0; color: #fff; font-size: .92rem; font-weight: 500; overflow-wrap: anywhere; }

.journal-hero-actions { display: flex; gap: .75rem; flex-wrap: wrap; }

/* ---- Page grid (tabs + sidebar) -------------------------------- */
.journal-page-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 320px;
    gap: 2rem;
    align-items: flex-start;
}

.journal-tabs-wrap {
    background: #fff;
    border: 1px solid var(--tj-border);
    border-radius: 12px;
    overflow: hidden;
}
.journal-tabs-bar {
    display: flex; flex-wrap: wrap;
    border-bottom: 1px solid var(--tj-border);
    background: #f8f9fc;
    padding: 0 .25rem;
}
.journal-tab {
    background: none; border: 0; border-bottom: 2px solid transparent;
    padding: .85rem 1rem; cursor: pointer;
    font-family: inherit; font-size: .85rem; font-weight: 500;
    color: var(--tj-muted);
    transition: color .15s, border-color .15s;
    white-space: nowrap;
}
.journal-tab:hover { color: var(--tj-text); }
.journal-tab.is-active {
    color: var(--tj-text);
    border-bottom-color: var(--tj-blue-600);
    background: #fff;
}

.journal-pane { display: none; padding: 1.5rem; }
.journal-pane.is-active { display: block; }
.journal-pane-head {
    display: flex; justify-content: space-between; align-items: baseline;
    flex-wrap: wrap; gap: .5rem;
    margin-bottom: 1rem;
}
.journal-pane-head h2 {
    margin: 0;
    font-size: 1.15rem; font-weight: 600;
    font-family: var(--font-sans);
}
.journal-pane-link { font-size: .82rem; color: var(--tj-blue-600); text-decoration: none; }
.journal-pane-link:hover { text-decoration: underline; }

.issue-list { list-style: none; padding: 0; margin: 0; }
.issue-list li {
    padding: .85rem 0;
    border-top: 1px solid var(--tj-border);
}
.issue-list li:first-child { border-top: 0; }
.issue-list a { color: var(--tj-text); text-decoration: none; }
.issue-list a:hover strong { color: var(--tj-blue-600); }
.issue-list-title { color: var(--tj-muted); font-size: .9rem; }
.issue-list-meta  { display: block; color: var(--tj-muted); font-size: .82rem; margin-top: .15rem; }

.journal-sidebar { display: flex; flex-direction: column; gap: 1.25rem; }

@media (max-width: 900px) {
    .journal-hero-grid { grid-template-columns: 1fr; gap: 1.5rem; }
    .journal-hero-cover img,
    .journal-hero-cover-placeholder { width: 140px; margin: 0 auto; }
    .journal-page-grid { grid-template-columns: 1fr; }
    .journal-tabs-bar { overflow-x: auto; flex-wrap: nowrap; }
    .journal-tab { flex: 0 0 auto; }
}

/* =====================================================================
   Journal cards (jc-*)  —  used in /journals and home "Featured Journals"
   ===================================================================== */
.jc-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 1.5rem;
}

.jc {
    display: flex; flex-direction: column;
    background: #fff;
    border: 1px solid var(--tj-border);
    border-radius: 14px;
    overflow: hidden;
    transition: border-color .15s ease;
}
.jc:hover { border-color: var(--tj-blue-400); }

/* ---- Cover ------------------------------------------------------- */
.jc-cover {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 7;
    overflow: hidden;
    background: var(--tj-navy-800);
    position: relative;
}
.jc-cover img {
    width: 100%; height: 100%;
    object-fit: cover; display: block;
    transition: transform .35s ease;
}
/* image zoom on hover removed per visual policy */
.jc-cover-placeholder {
    width: 100%; height: 100%;
    background: linear-gradient(135deg, var(--tj-navy-800) 0%, var(--tj-blue-600) 100%);
    color: #fff;
    display: flex; flex-direction: column;
    align-items: center; justify-content: center;
    gap: .25rem;
    position: relative;
}
.jc-cover-placeholder::before {
    content: ''; position: absolute; inset: 0;
    background: radial-gradient(circle at 80% 20%, rgba(255,255,255,.12), transparent 55%);
}
.jc-cover-monogram {
    font-size: 2rem; font-weight: 700;
    letter-spacing: .04em;
    position: relative;
}
.jc-cover-pub { font-size: .72rem; opacity: .7; text-transform: uppercase; letter-spacing: .08em; position: relative; }

/* ---- Body -------------------------------------------------------- */
.jc-body {
    display: flex; flex-direction: column;
    padding: 1.25rem 1.35rem 1.35rem;
    gap: .85rem;
    flex: 1;
}

/* ---- Badges (sólidos com bom contraste) -------------------------- */
.jc-badges { display: flex; flex-wrap: wrap; gap: .4rem; }
.jc-badge {
    display: inline-flex; align-items: center; gap: .3rem;
    padding: .25rem .6rem;
    border-radius: 999px;
    font-size: .72rem; font-weight: 600;
    text-transform: uppercase; letter-spacing: .03em;
    line-height: 1.4;
}
.jc-badge--success { background: #059669; color: #fff; }
.jc-badge--info    { background: var(--tj-blue-600); color: #fff; }
.jc-badge--warning { background: #d97706; color: #fff; }

/* ---- Title ------------------------------------------------------- */
.jc-title {
    margin: 0;
    font-family: var(--font-sans);
    font-size: 1.15rem;
    font-weight: 700;
    line-height: 1.3;
    color: var(--tj-text);
}
.jc-title a { color: inherit; text-decoration: none; }
.jc-title a:hover { color: var(--tj-blue-600); text-decoration: none; }

/* ---- Description (line-clamp prevents overflow) ----------------- */
.jc-desc {
    margin: 0;
    color: var(--tj-muted);
    font-size: .9rem;
    line-height: 1.55;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ---- Compact meta line (replaces the verbose dl on cards) -------- */
.jc-meta-line {
    display: flex; flex-wrap: wrap; gap: .5rem .85rem;
    padding: .65rem 0 0;
    border-top: 1px dashed var(--tj-border);
    color: var(--tj-muted);
    font-size: .78rem;
}
.jc-meta-line span { display: inline-flex; align-items: center; }
.jc-meta-line span + span::before {
    content: "·"; margin-right: .85rem; color: var(--tj-blue-400);
}

/* ---- Info list (definition list, two columns) ------------------- */
.jc-info {
    display: grid;
    grid-template-columns: 1fr;
    gap: .35rem .75rem;
    margin: 0;
    padding: .75rem 0 0;
    border-top: 1px dashed var(--tj-border);
    font-size: .85rem;
}
.jc-info > div { display: grid; grid-template-columns: 130px minmax(0, 1fr); align-items: baseline; gap: .5rem; }
.jc-info dt {
    color: var(--tj-muted);
    font-size: .72rem;
    text-transform: uppercase;
    letter-spacing: .04em;
    font-weight: 500;
    margin: 0;
}
.jc-info dd {
    margin: 0;
    color: var(--tj-text);
    font-weight: 500;
    overflow-wrap: anywhere;
}

/* ---- Actions ----------------------------------------------------- */
.jc-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: .5rem;
    margin-top: auto;
    padding-top: .25rem;
}
.jc-btn {
    display: inline-flex; align-items: center; justify-content: center;
    padding: .6rem .85rem;
    border-radius: 8px;
    font-size: .85rem; font-weight: 600;
    text-decoration: none;
    border: 1px solid transparent;
    transition: background .15s, color .15s, border-color .15s;
    text-align: center;
    line-height: 1.2;
}
.jc-btn--primary { background: var(--tj-blue-600); color: #fff; }
.jc-btn--primary:hover { background: var(--tj-blue-500); color: #fff; text-decoration: none; }
.jc-btn--ghost   { background: #fff; color: var(--tj-blue-600); border-color: var(--tj-border); }
.jc-btn--ghost:hover { background: var(--tj-blue-100); color: var(--tj-blue-600); border-color: var(--tj-blue-400); text-decoration: none; }
.jc-btn--disabled { background: #f0f1f5; color: var(--tj-muted); cursor: not-allowed; }

/* ---- Responsive -------------------------------------------------- */
@media (max-width: 640px) {
    .jc-grid { grid-template-columns: 1fr; gap: 1rem; }
    .jc-info > div { grid-template-columns: 110px minmax(0, 1fr); }
    .jc-actions { grid-template-columns: 1fr; }
}

.dash-feed { list-style: none; padding: 0; margin: 0; }
.dash-feed li {
    display: flex; gap: .85rem; align-items: flex-start;
    padding: .85rem 0;
    border-bottom: 1px solid var(--tj-border);
}
.dash-feed li:last-child { border-bottom: 0; }
.dash-feed-dot {
    width: 10px; height: 10px; border-radius: 50%;
    background: var(--tj-blue-600);
    margin-top: .5rem; flex-shrink: 0;
}
.dash-feed-dot.tone-green { background: #10b981; }
.dash-feed-dot.tone-amber { background: #f59e0b; }
.dash-feed-dot.tone-red   { background: #ef4444; }
.dash-feed-dot.tone-blue  { background: #4f5ec5; }
.dash-feed-body { flex: 1; min-width: 0; font-size: .92rem; line-height: 1.45; }
.dash-feed-body a { color: var(--tj-text); text-decoration: none; }
.dash-feed-body a:hover { color: var(--tj-blue-600); text-decoration: underline; }
.dash-feed-meta { color: var(--tj-muted); font-size: .82rem; margin-top: .15rem; }

/* Right-aligned action button inside dash-feed items */
.dash-feed li { align-items: flex-start; }
.dash-feed li > .btn { flex-shrink: 0; margin-left: auto; align-self: center; }

/* Smart alert above metric cards (author dashboard) */
.dash-alert {
    margin: 1rem 1.75rem 0;
    padding: .75rem 1rem;
    border-radius: 8px;
    border: 1px solid transparent;
    font-size: .9rem;
    line-height: 1.4;
}
.dash-alert--success { background: #d1fae5; color: #065f46; border-color: #6ee7b7; }
.dash-alert--info    { background: #dbeafe; color: #1e40af; border-color: #93c5fd; }
.dash-alert--warning { background: #fef3c7; color: #92400e; border-color: #fcd34d; }
.dash-alert--danger  { background: #fee2e2; color: #991b1b; border-color: #fca5a5; }

.dashboard-nav-count {
    background: var(--tj-blue-600);
    color: #fff;
    font-size: .72rem; font-weight: 700;
    padding: .15rem .5rem;
    border-radius: 999px;
    min-width: 22px; text-align: center;
}
.dashboard-nav-item.active .dashboard-nav-count { background: rgba(255,255,255,.25); }

@media (max-width: 900px) {
    .dash-grid { grid-template-columns: 1fr; }
    .dash-metrics { padding: 1.25rem 1rem 0; }
    .dash-grid    { padding: 1.25rem 1rem; }
    .dash-hero    { padding: 1.5rem 1rem 1rem; }
}

/* =====================================================================
   Article page — align head and body to the same readable column
   ===================================================================== */
.article-head > .container { max-width: 1200px !important; padding-left: 1.5rem; padding-right: 1.5rem; }
.article-grid {
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
    grid-template-columns: minmax(0, 2.2fr) minmax(0, 1fr);
    gap: 3rem;
    padding-left: 1.5rem;
    padding-right: 1.5rem;
}
@media (max-width: 900px) {
    .article-grid { padding-left: 1rem; padding-right: 1rem; grid-template-columns: 1fr; }
    .article-head > .container { padding-left: 1rem; padding-right: 1rem; }
}

/* =====================================================================
   Polish pass — overflow fixes + minimalist dashboard + cleaner wizard
   ===================================================================== */

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

/* Grid columns must shrink — prevents children with long words pushing past */
.journal-header-grid > *,
.journal-body > *,
.article-grid > *,
.dash-grid > *,
.dash-metric > *,
.dashboard-shell > * { min-width: 0; }

.journal-body         { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); }
.journal-header-grid  { grid-template-columns: 200px minmax(0, 1fr); }

/* ---- Dashboard scale (minimalist) ------------------------------- */
.dashboard-content { font-size: .92rem; }
.dashboard-content h1 { font-size: 1.45rem; line-height: 1.25; }
.dashboard-content h2 { font-size: 1.15rem; }
.dashboard-content h3 { font-size: .98rem; font-family: var(--font-sans); margin-bottom: .85rem; }
.dashboard-content h4 { font-size: .85rem; font-family: var(--font-sans); }

/* Page hero (sub-page header inside dashboard) — slimmer */
.dashboard-content .page-hero { padding: 1.1rem 1.75rem .85rem; }
.dashboard-content .page-hero h1 { font-size: 1.4rem; margin: 0 0 .25rem; }
.dashboard-content .page-hero p  { font-size: .85rem; margin: 0; }

/* Hero on /dashboard hub */
.dash-hero { padding: 1.4rem 1.75rem 1rem; }
.dash-hero h1 { font-size: 1.5rem; }
.dash-hero-sub { font-size: .85rem; }

/* Metric cards */
.dash-metrics { gap: 1rem; padding: 1.25rem 1.75rem 0; }
.dash-metric  { padding: 1rem 1.1rem; gap: .85rem; }
.dash-metric-icon  { width: 40px; height: 40px; font-size: 1.15rem; border-radius: 10px; }
.dash-metric-label { font-size: .7rem; letter-spacing: .05em; }
.dash-metric-value { font-size: 1.5rem; }
.dash-metric-sub   { font-size: .76rem; }

/* Cards / charts */
.dash-grid { gap: 1rem; padding: 1.25rem 1.75rem; }
.dash-card { padding: 1.1rem 1.25rem; min-height: 0; border-radius: 10px; }
.dash-card-head { margin-bottom: .65rem; }
.dash-card-head h3 { font-size: .9rem; }
.dash-card-sub  { font-size: .74rem; }
.dash-chart           { height: 240px; }
.dash-chart-doughnut  { height: 200px; max-width: 280px; }

/* Buttons inside dashboard */
.dashboard-content .btn        { padding: .5rem 1rem;    font-size: .85rem; border-radius: 7px; }
.dashboard-content .btn-lg     { padding: .6rem 1.15rem; font-size: .9rem; }

/* Form controls */
.dashboard-content .form-control { padding: .55rem .75rem; font-size: .88rem; border-radius: 7px; }
.dashboard-content .form-label   { font-size: .82rem; margin-bottom: .3rem; }
.dashboard-content .form-help    { font-size: .76rem; }
.dashboard-content .form-group   { margin-bottom: .85rem; }

/* Tables (manage lists) */
.dashboard-content table { font-size: .88rem; }
.dashboard-content thead th { padding: .65rem 1rem !important; font-size: .7rem !important; }
.dashboard-content tbody td { padding: .7rem 1rem !important; }

/* Alerts */
.dashboard-content .alert { font-size: .85rem; padding: .65rem .85rem; }

/* Section padding */
.dashboard-content .section { padding: 1.25rem 1.75rem; }

/* Inline cards built with [style] in views — make padding consistent */
.dashboard-content [style*="border-radius:var(--tj-radius);padding:2rem"],
.dashboard-content [style*="border-radius:var(--tj-radius);padding:1.75rem"] {
    padding: 1.25rem !important;
    border-radius: 10px !important;
}
.dashboard-content [style*="border-radius:var(--tj-radius);padding:1.5rem"] {
    border-radius: 10px !important;
}

/* (Legacy inline-style pill overrides removed — tabs now use .tj-tab classes) */

/* Sidebar */
.dashboard-nav-item  { padding: .55rem .75rem; font-size: .88rem; }
.dashboard-nav-label { font-size: .65rem; padding: .75rem .75rem .3rem; }
.dashboard-user-name { font-size: .88rem; }
.dashboard-user-role { font-size: .7rem; }

/* Top bar */
.dashboard-topbar    { padding: .65rem 1.5rem; }
.dashboard-userchip  { font-size: .82rem; padding: .25rem .25rem .25rem .65rem; }

@media (max-width: 900px) {
    .dashboard-content .section { padding: 1rem; }
    .dash-metrics { padding: 1rem 1rem 0; gap: .75rem; }
    .dash-grid    { padding: 1rem; gap: .85rem; }
    .dashboard-content .page-hero { padding: 1rem; }
    .dash-hero { padding: 1rem; }
}

/* =====================================================================
   Article page extras (toolbar, cite panel, side-nav, metrics)
   These extend the older .art-* rules above without breaking them.
   ===================================================================== */
.art-head-affs {
    list-style: decimal; padding-left: 1.25rem; margin: .5rem 0 1rem;
    color: var(--tj-muted); font-size: .85rem; line-height: 1.5;
}
.art-head-affs li { margin: .15rem 0; }
.art-head-meta {
    display: flex; flex-wrap: wrap; gap: .35rem 1rem;
    color: var(--tj-muted); font-size: .88rem;
    margin: 0 0 1.25rem;
}
.art-head-license { color: var(--tj-success-fg, #047857); font-weight: 600; }

.art-toolbar {
    display: flex; flex-wrap: wrap; gap: .5rem;
    padding-top: 1rem; border-top: 1px solid var(--tj-border);
    margin-top: 1rem;
}
.art-toolbar .art-btn {
    background: #fff; color: var(--tj-text);
    border: 1px solid var(--tj-border);
    padding: .55rem .9rem;
    transition: background .15s, border-color .15s, color .15s;
}
.art-toolbar .art-btn:hover { background: var(--tj-blue-50, #eef0fb); border-color: var(--tj-blue-400); color: var(--tj-blue-600); text-decoration: none; }
.art-btn--link { color: var(--tj-blue-600) !important; font-weight: 500 !important; word-break: break-all; }

/* PDF download — red so it stands out as the primary content download.
   Use !important to win against the generic .art-toolbar .art-btn rule that
   sets a white background on hover/default. */
.art-toolbar .art-btn--pdf,
.art-toolbar a.art-btn--pdf {
    background: #dc2626 !important;
    color: #fff !important;
    border-color: #dc2626 !important;
}
.art-toolbar a.art-btn--pdf:hover {
    background: #b91c1c !important;
    border-color: #b91c1c !important;
    color: #fff !important;
}
.art-toolbar .art-btn--pdf.is-disabled {
    background: #fca5a5 !important;
    border-color: #fca5a5 !important;
    cursor: not-allowed;
    opacity: .85;
}

/* Cite panel (collapsible from toolbar) */
.art-cite-panel {
    margin-top: 1rem;
    background: #fff; border: 1px solid var(--tj-border);
    border-radius: 10px; padding: 1rem;
}
.art-cite-tabs { display: flex; flex-wrap: wrap; gap: .25rem; border-bottom: 1px solid var(--tj-border); margin-bottom: .85rem; }
.art-cite-tab {
    background: transparent; border: 0; padding: .55rem .9rem;
    font-family: inherit; font-size: .85rem; color: var(--tj-muted);
    cursor: pointer; border-bottom: 2px solid transparent; margin-bottom: -1px;
}
.art-cite-tab:hover { color: var(--tj-text); }
.art-cite-tab.is-active { color: var(--tj-blue-600); border-bottom-color: var(--tj-blue-600); font-weight: 600; }
.art-cite-body { display: none; position: relative; }
.art-cite-body.is-active { display: block; }
.art-cite-body pre {
    background: #f8f9fc; border: 1px solid var(--tj-border);
    border-radius: 8px; padding: .85rem 3.5rem .85rem 1rem;
    font-size: .85rem; white-space: pre-wrap; word-break: break-word;
    margin: 0; font-family: ui-monospace, Menlo, Consolas, monospace;
    line-height: 1.55;
}
.art-cite-copy {
    position: absolute; top: .65rem; right: .65rem;
    background: #fff; border: 1px solid var(--tj-border);
    color: var(--tj-blue-600); padding: .25rem .55rem;
    border-radius: 6px; font-size: .72rem; font-family: inherit; cursor: pointer;
}
.art-cite-copy:hover { background: var(--tj-blue-50, #eef0fb); }

/* "How to Cite" inline list (always visible at bottom) */
.art-cite-list { display: flex; flex-direction: column; gap: .65rem; }
.art-cite-row {
    display: grid; grid-template-columns: 90px minmax(0, 1fr) auto; gap: .85rem;
    align-items: start;
    padding: .85rem; background: #f8f9fc;
    border: 1px solid var(--tj-border); border-radius: 8px;
}
.art-cite-row .art-cite-style {
    font-size: .72rem; font-weight: 700; text-transform: uppercase;
    letter-spacing: .06em; color: var(--tj-blue-600);
    padding-top: .15rem;
}
.art-cite-row .art-cite-text { font-size: .9rem; line-height: 1.55; color: var(--tj-text); }
.art-cite-mini {
    background: #fff; border: 1px solid var(--tj-border);
    color: var(--tj-blue-600); padding: .3rem .65rem;
    border-radius: 6px; font-size: .72rem; cursor: pointer; font-family: inherit;
    align-self: start;
}
.art-cite-mini:hover { background: var(--tj-blue-50, #eef0fb); }

/* 2-column grid: main + right sidebar (which now also hosts the side-nav) */
.art-section-wrap { background: #f4f6fb; padding: 1.5rem 0 3rem; }
.art-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 280px;
    gap: 2rem;
    align-items: flex-start;
}
.art-main { background: #fff; border: 1px solid var(--tj-border); border-radius: 12px; padding: 2rem; min-width: 0; }

/* Side-nav (now inside the right sidebar — not standalone-sticky anymore;
   the parent .art-sidebar handles sticky positioning) */
.art-nav {
    background: #fff; border: 1px solid var(--tj-border); border-radius: 10px;
    padding: 1rem 1.1rem; font-size: .88rem;
}
.art-nav strong {
    display: block; font-size: .72rem; text-transform: uppercase; letter-spacing: .06em;
    color: var(--tj-muted); margin-bottom: .65rem; font-weight: 700;
}
.art-nav ul { list-style: none; padding: 0; margin: 0; }
.art-nav li { margin: 0; }
.art-nav a {
    display: block; padding: .35rem .6rem; border-left: 2px solid transparent;
    color: var(--tj-text); text-decoration: none; transition: color .12s, border-color .12s, background .12s;
    border-radius: 0 4px 4px 0;
}
.art-nav a:hover { background: #f4f6fc; color: var(--tj-blue-600); }
.art-nav a.is-active { color: var(--tj-blue-600); border-left-color: var(--tj-blue-600); background: #f4f6fc; font-weight: 600; }

/* Sections in main */
.art-prose { font-size: .98rem; line-height: 1.75; color: var(--tj-text); }
.art-prose p { margin: 0 0 1rem; }
.art-prose h3, .art-prose h4 { margin-top: 1.5rem; }
.art-prose img { max-width: 100%; border-radius: 6px; margin: 1rem 0; }
/* P9 — table styling for pasted tables in the body. */
.art-prose table {
    width: 100%;
    border-collapse: collapse;
    margin: 1.25rem 0;
    font-size: .92rem;
}
.art-prose th, .art-prose td {
    border: 1px solid var(--tj-border);
    padding: .55rem .75rem;
    text-align: left;
    vertical-align: top;
}
.art-prose thead th {
    background: #f8f9fc;
    font-weight: 700;
}
.art-prose tbody tr:nth-child(even) { background: #fafbff; }
.art-prose caption { font-size: .85rem; color: var(--tj-muted); padding: .5rem 0; text-align: left; }
.art-prose blockquote {
    border-left: 4px solid var(--tj-blue-400);
    margin: 1rem 0; padding: .25rem 1rem;
    color: var(--tj-muted); font-style: italic;
}
.art-prose .ql-align-center  { text-align: center; }
.art-prose .ql-align-right   { text-align: right; }
.art-prose .ql-align-justify { text-align: justify; }

.art-section-sub { font-family: var(--font-sans); font-size: 1rem; font-weight: 700; color: var(--tj-text); margin: 0 0 .5rem; }
.art-section-meta { background: #f8f9fc; border-left: 3px solid var(--tj-blue-400); padding: .85rem 1rem; border-radius: 0 6px 6px 0; }
.art-section-meta p { margin: 0; font-size: .9rem; line-height: 1.6; }

.art-keywords { display: flex; flex-wrap: wrap; gap: .4rem; }
.art-keyword {
    display: inline-block; background: var(--tj-blue-50, #eef0fb);
    color: var(--tj-blue-600); padding: .25rem .7rem;
    border-radius: 999px; font-size: .82rem; font-weight: 500;
}

.art-references { padding-left: 1.5rem; margin: 0; counter-reset: refs; }
.art-references li {
    margin-bottom: .9rem; padding-left: .25rem; line-height: 1.55;
    font-size: .9rem; color: var(--tj-text); overflow-wrap: anywhere;
}

.art-related { list-style: none; padding: 0; margin: 0; display: grid; gap: .85rem; }
.art-related li {
    background: #f8f9fc; border: 1px solid var(--tj-border); border-radius: 8px;
    padding: .85rem 1rem; transition: background .12s;
}
.art-related li:hover { background: #eef0fb; }
.art-related a { color: var(--tj-text); text-decoration: none; }
.art-related a:hover { color: var(--tj-blue-600); }

/* Right sidebar cards extras */
.art-dates { list-style: none; padding: 0; margin: 0; font-size: .88rem; }
.art-dates li { display: flex; justify-content: space-between; padding: .35rem 0; border-top: 1px dashed var(--tj-border); }
.art-dates li:first-child { border-top: 0; }
.art-dates span { color: var(--tj-muted); }
.art-dates strong { color: var(--tj-text); font-weight: 600; }

.art-metrics { display: grid; grid-template-columns: 1fr 1fr; gap: .75rem; }
.art-metrics > div {
    text-align: center; padding: .85rem .25rem;
    background: #f8f9fc; border: 1px solid var(--tj-border); border-radius: 8px;
}
.art-metrics strong { display: block; font-size: 1.5rem; font-weight: 700; color: var(--tj-blue-600); line-height: 1; margin-bottom: .25rem; }
.art-metrics span { font-size: .72rem; text-transform: uppercase; letter-spacing: .06em; color: var(--tj-muted); }

.art-author-list { list-style: none; padding: 0; margin: 0; }
.art-author-list li { padding: .55rem 0; border-top: 1px solid var(--tj-border); }
.art-author-list li:first-child { border-top: 0; }

@media (max-width: 900px) {
    .art-grid { grid-template-columns: 1fr; }
    .art-sidebar { position: static; }
    .art-main { padding: 1.25rem; }
}
@media (max-width: 540px) {
    .art-cite-row { grid-template-columns: 1fr; }
    .art-cite-row .art-cite-style { font-size: .68rem; }
}

/* =====================================================================
   Journal public page (/journals/{slug}) — refined hero, tabs, sidebar
   ===================================================================== */
.jh {
    background: linear-gradient(135deg, #1a2456 0%, #3d4cb5 60%, #4f5ec5 100%);
    color: #fff;
    padding: 3rem 0 2.5rem;
    position: relative;
    overflow: hidden;
}
.jh::before {
    content: ""; position: absolute; inset: 0;
    background: radial-gradient(circle at 80% 20%, rgba(255,255,255,.08), transparent 55%);
    pointer-events: none;
}
.jh-grid {
    display: grid; grid-template-columns: 200px 1fr; gap: 2.25rem;
    align-items: center; position: relative; z-index: 1;
}
.jh-cover img,
.jh-cover-placeholder {
    width: 200px; aspect-ratio: 3/4; object-fit: cover;
    border-radius: 10px;
    border: 1px solid rgba(255,255,255,.18);
    display: block;
}
.jh-cover-placeholder {
    background: linear-gradient(135deg, var(--tj-blue-600), var(--tj-navy-800));
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    color: #fff;
}
.jh-cover-placeholder span { font-family: var(--font-serif); font-weight: 700; font-size: 2.4rem; letter-spacing: .04em; }
.jh-cover-placeholder small { font-size: .7rem; text-transform: uppercase; letter-spacing: .12em; opacity: .7; margin-top: .35rem; }

.jh-info { min-width: 0; }
.jh-badges { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: .85rem; }
.jh-badge {
    display: inline-flex; align-items: center; gap: .35rem;
    padding: .25rem .7rem; font-size: .78rem; font-weight: 500;
    border-radius: 999px;
    background: rgba(255, 255, 255, .12);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, .2);
}
.jh-badge--success { background: rgba(16, 185, 129, .18); border-color: rgba(16, 185, 129, .4); }
.jh-badge--info    { background: rgba(124, 142, 224, .25); border-color: rgba(124, 142, 224, .55); }
/* Highlight badge for journals actively accepting submissions — solid
   green so it pops on the dark hero, with a live "status dot" prefix. */
.jh-badge--accepting {
    background: #10b981;
    border-color: #059669;
    color: #fff;
    font-weight: 700;
    padding: .35rem .85rem .35rem .65rem;
    box-shadow: 0 0 0 3px rgba(16, 185, 129, .25);
}
.jh-badge-dot {
    display: inline-block;
    width: .55rem; height: .55rem;
    background: #fff; border-radius: 50%;
    box-shadow: 0 0 0 3px rgba(255, 255, 255, .35);
}
.jc-badge--accepting {
    background: #10b981;
    color: #fff;
    font-weight: 700;
    box-shadow: 0 0 0 2px rgba(16, 185, 129, .25);
    padding: .3rem .7rem .3rem .55rem;
}
.jh-title {
    font-family: var(--font-serif); font-size: 2.25rem; font-weight: 700;
    color: #fff; margin: 0; line-height: 1.18;
}
.jh-abbrev { color: rgba(255, 255, 255, .75); font-size: .92rem; margin: .35rem 0 1rem; }
.jh-meta {
    display: flex; flex-wrap: wrap; gap: .35rem 1.5rem;
    color: rgba(255, 255, 255, .85); font-size: .9rem; margin-bottom: 1.25rem;
}
.jh-actions { display: flex; gap: .65rem; flex-wrap: wrap; }

/* ---- Body grid (main + aside) ------------------------------------- */
.jp-section { background: #f4f6fb; }
.jp-grid {
    display: grid; grid-template-columns: 1fr 320px; gap: 2rem;
    align-items: flex-start;
}
.jp-main {
    background: #fff;
    border: 1px solid var(--tj-border);
    border-radius: 14px;
    overflow: hidden;
}
.jp-tabs {
    display: flex; gap: 0;
    flex-wrap: nowrap; overflow-x: auto; overflow-y: hidden;
    border-bottom: 1px solid var(--tj-border);
    background: #fafbfd;
    padding: 0 .5rem;
    scrollbar-width: thin;
    scrollbar-color: rgba(79, 94, 197, .35) transparent;
    -webkit-overflow-scrolling: touch;
}
.jp-tabs::-webkit-scrollbar { height: 4px; }
.jp-tabs::-webkit-scrollbar-thumb { background: rgba(79, 94, 197, .35); border-radius: 2px; }
.jp-tabs::-webkit-scrollbar-track { background: transparent; }
.jp-tab { flex-shrink: 0; }
.jp-tab {
    background: transparent; border: 0; padding: 1rem 1.1rem;
    font-family: inherit; font-size: .92rem; font-weight: 500;
    color: var(--tj-muted); cursor: pointer;
    border-bottom: 3px solid transparent; margin-bottom: -1px;
    transition: color .15s, border-color .15s;
    white-space: nowrap;
}
.jp-tab:hover { color: var(--tj-text); }
.jp-tab.is-active {
    color: var(--tj-blue-600);
    border-bottom-color: var(--tj-blue-600);
    font-weight: 600;
}
.jp-pane { display: none; padding: 1.75rem 2rem 2rem; }
.jp-pane.is-active { display: block; }
.jp-pane-head {
    display: flex; justify-content: space-between; align-items: baseline;
    margin: 0 0 1.25rem;
}
.jp-pane-head h2 {
    font-family: var(--font-serif); font-size: 1.45rem; font-weight: 700;
    margin: 0; color: var(--tj-text);
}
.jp-pane-meta { font-size: .82rem; color: var(--tj-muted); }
.jp-prose { font-size: .95rem; line-height: 1.7; color: var(--tj-text); }
.jp-prose p:first-child { margin-top: 0; }
.jp-prose h2, .jp-prose h3 { font-family: var(--font-serif); margin-top: 1.5rem; }
.jp-prose .ql-align-center  { text-align: center; }
.jp-prose .ql-align-right   { text-align: right; }
.jp-prose .ql-align-justify { text-align: justify; }
.jp-prose ol, .jp-prose ul { padding-left: 1.5rem; }
.jp-prose blockquote {
    border-left: 4px solid var(--tj-blue-400);
    margin: 1rem 0; padding: .25rem 1rem;
    color: var(--tj-muted); font-style: italic;
}

.article-row-doi {
    color: var(--tj-blue-600); text-decoration: none; font-family: monospace; font-size: .82rem;
}
.article-row-doi:hover { text-decoration: underline; }

.jp-pane-link { color: var(--tj-blue-600); text-decoration: none; }
.jp-pane-link:hover { text-decoration: underline; }

/* ---- Issues grid (inside Issues tab) ----------------------------- */
.jp-issue-grid {
    display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 1.25rem;
}
.jp-issue-card {
    display: block; text-decoration: none; color: inherit;
    transition: transform .15s;
}
.jp-issue-card:hover { text-decoration: none; }
.jp-issue-card:hover img,
.jp-issue-card:hover .jp-issue-card-placeholder { border-color: var(--tj-blue-400); }
.jp-issue-card img,
.jp-issue-card-placeholder {
    width: 100%; aspect-ratio: 3/4; object-fit: cover;
    border-radius: 8px; border: 1px solid var(--tj-border);
    display: block; margin-bottom: .55rem;
}
.jp-issue-card-placeholder {
    background: linear-gradient(135deg, var(--tj-blue-600), var(--tj-navy-800));
    color: #fff; display: flex; flex-direction: column; align-items: center; justify-content: center;
    text-align: center;
}
.jp-issue-card-placeholder span { font-family: var(--font-serif); font-weight: 700; font-size: 1.05rem; }
.jp-issue-card-placeholder small { opacity: .8; font-size: .82rem; margin-top: .15rem; }
.jp-issue-card-body { padding: .15rem .15rem; font-size: .85rem; line-height: 1.4; display: flex; flex-direction: column; gap: .15rem; }
.jp-issue-card-body strong { color: var(--tj-text); font-weight: 600; }
.jp-issue-card-title { color: var(--tj-muted); font-size: .8rem; }
.jp-issue-card-date { color: var(--tj-muted); font-size: .76rem; margin-top: .1rem; }

.jp-empty {
    text-align: center; padding: 2.5rem 1rem;
    color: var(--tj-muted);
}
.jp-empty-icon { font-size: 2.5rem; margin-bottom: .5rem; }
.jp-empty p { margin: 0 0 1rem; }

/* Minimalist editorial board list — no cards, just rows separated by
   a hairline. Avatars are small monogram circles (or hidden on mobile).
   No gradients, no shadows. */
.jp-board-card {
    display: flex;
    gap: .85rem;
    align-items: flex-start;
    padding: .75rem 0;
    background: transparent;
    border: 0;
    border-bottom: 1px solid var(--tj-border);
    border-radius: 0;
    margin: 0;
}
.jp-board-list .jp-board-card:last-child { border-bottom: 0; }
.jp-board-avatar {
    width: 32px; height: 32px;
    border-radius: 50%;
    background: transparent;
    color: var(--tj-blue-600);
    border: 1px solid var(--tj-border);
    font-weight: 600;
    font-size: .72rem;
    letter-spacing: .04em;
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0;
    margin-top: .12rem;
}
.jp-board-role {
    font-size: .68rem;
    text-transform: uppercase;
    letter-spacing: .08em;
    color: var(--tj-muted);
    font-weight: 600;
}
.jp-board-name {
    font-weight: 600;
    font-size: .95rem;
    color: var(--tj-text);
    line-height: 1.3;
    margin-top: 0;
}
.jp-board-email { font-size: .82rem; }

/* Section heading separating role groups (Editors / Reviewers / etc.) */
.jp-board-section {
    font-size: .7rem;
    text-transform: uppercase;
    letter-spacing: .14em;
    color: var(--tj-muted);
    font-weight: 600;
    margin: 1.75rem 0 .35rem;
    padding-bottom: 0;
    border-bottom: 0;
}
.jp-board-section:first-of-type { margin-top: .25rem; }
.jp-board-list {
    list-style: none;
    padding: 0;
    margin: 0;
    border-top: 1px solid var(--tj-border);
}
.jp-board-affil {
    color: var(--tj-muted);
    font-size: .82rem;
    margin-top: .1rem;
}
.jp-board-links {
    display: flex; flex-wrap: wrap; gap: .4rem .9rem;
    margin-top: .25rem;
    font-size: .78rem;
}
.jp-board-link {
    color: var(--tj-blue-600);
    text-decoration: none;
}
.jp-board-link:hover { text-decoration: underline; }

@media (max-width: 540px) {
    .jp-board-avatar { display: none; }
}

/* ---- Sidebar cards ----------------------------------------------- */
.jp-aside { display: flex; flex-direction: column; gap: 1rem; position: sticky; top: 1rem; }
.jp-card {
    background: #fff;
    border: 1px solid var(--tj-border);
    border-radius: 12px;
    padding: 1.25rem;
}
.jp-card--featured {
    background: linear-gradient(180deg, #f4f6fc 0%, #ffffff 50%);
    padding: 1.25rem 1.25rem 1.5rem;
}
.jp-card-eyebrow {
    font-size: .72rem; text-transform: uppercase; letter-spacing: .08em;
    color: var(--tj-blue-600); font-weight: 700; margin-bottom: .75rem;
}
.jp-card-title {
    margin: 0 0 .85rem; font-size: 1.02rem; font-weight: 700;
    color: var(--tj-text); font-family: var(--font-sans);
}
.jp-card-cta { width: 100%; margin-top: 1rem; justify-content: center; display: flex; }

.jp-issue-link { display: block; text-align: center; margin-bottom: .85rem; }
.jp-issue-link img {
    width: 65%; max-width: 140px; aspect-ratio: 3/4; object-fit: cover;
    border-radius: 8px; border: 1px solid var(--tj-border);
}
.jp-issue-link:hover img { border-color: var(--tj-blue-400); }
.jp-issue-placeholder {
    width: 65%; max-width: 140px; aspect-ratio: 3/4; margin: 0 auto;
    background: linear-gradient(135deg, var(--tj-blue-600), var(--tj-navy-800));
    color: #fff; border-radius: 8px;
    display: flex; align-items: center; justify-content: center;
    font-family: var(--font-serif); font-weight: 700; text-align: center;
    line-height: 1.3;
}
.jp-card-body { text-align: center; }

.jp-info { margin: 0; padding: 0; display: grid; gap: .75rem; }
.jp-info > div { display: grid; grid-template-columns: 110px 1fr; gap: .5rem; align-items: baseline; }
.jp-info dt { color: var(--tj-muted); font-size: .72rem; text-transform: uppercase; letter-spacing: .04em; font-weight: 500; margin: 0; }
.jp-info dd { margin: 0; color: var(--tj-text); font-weight: 500; font-size: .9rem; overflow-wrap: anywhere; }

.jp-editor-mini { display: flex; gap: .85rem; align-items: center; }
.jp-editor-avatar {
    width: 44px; height: 44px; border-radius: 50%;
    background: linear-gradient(135deg, var(--tj-blue-600), var(--tj-navy-800));
    color: #fff; font-weight: 700; font-size: .85rem;
    display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}

/* ---- Mobile ------------------------------------------------------ */
@media (max-width: 900px) {
    .jh-grid { grid-template-columns: 1fr; gap: 1.5rem; }
    .jh-cover img, .jh-cover-placeholder { width: 160px; margin: 0 auto; }
    .jh-info { text-align: center; }
    .jh-meta, .jh-actions, .jh-badges { justify-content: center; }
    .jp-grid { grid-template-columns: 1fr; }
    .jp-aside { position: static; }
}
@media (max-width: 540px) {
    .jh-title { font-size: 1.7rem; }
    .jp-pane { padding: 1.25rem; }
    .jp-tab { padding: .75rem .85rem; font-size: .85rem; }
}

/* ===================================================================
   Submission timeline (author submission_show.php sidebar)
   Vertical list of milestones with colored markers — no shadows,
   no animations, just borders + color tones.
   =================================================================== */
.tj-timeline {
    list-style: none;
    padding: 0 0 0 .5rem;
    margin: .65rem 0 0;
    position: relative;
}
.tj-timeline::before {
    content: "";
    position: absolute;
    left: 7px;
    top: .35rem;
    bottom: .35rem;
    width: 2px;
    background: var(--tj-border);
}
.tj-timeline-item {
    position: relative;
    padding: 0 0 1rem 1.5rem;
}
.tj-timeline-item:last-child { padding-bottom: 0; }
.tj-timeline-marker {
    position: absolute;
    left: 0;
    top: .25rem;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #fff;
    border: 2px solid var(--tj-blue-600);
    z-index: 1;
}
.tj-timeline-item[data-tone="green"] .tj-timeline-marker { border-color: #10b981; }
.tj-timeline-item[data-tone="red"]   .tj-timeline-marker { border-color: #ef4444; }
.tj-timeline-item[data-tone="amber"] .tj-timeline-marker { border-color: #f59e0b; }
.tj-timeline-item.is-current .tj-timeline-marker {
    background: var(--tj-blue-600);
}
.tj-timeline-item[data-tone="green"].is-current .tj-timeline-marker { background: #10b981; }
.tj-timeline-item[data-tone="red"].is-current   .tj-timeline-marker { background: #ef4444; }
.tj-timeline-item[data-tone="amber"].is-current .tj-timeline-marker { background: #f59e0b; }

.tj-timeline-title {
    font-size: .88rem;
    font-weight: 600;
    color: var(--tj-text);
    line-height: 1.3;
}
.tj-timeline-meta {
    font-size: .76rem;
    color: var(--tj-muted);
    margin-top: .15rem;
}
.tj-timeline-note {
    font-size: .82rem;
    color: var(--tj-text);
    font-style: italic;
    margin-top: .35rem;
    padding: .35rem .55rem;
    background: #f8f9fc;
    border-left: 2px solid var(--tj-blue-400);
    border-radius: 0 4px 4px 0;
}

/* =====================================================================
   FASE 1 — Visual standardization (no shadows, no animations).
   ===================================================================== */

/* ---- Auth split layout (login / forgot / register) -----------------
   Full-bleed background, but inner content padded so it lines up with
   the header's .container box (max-width 1200px, 1.5rem side padding).
   The padding formula reproduces the container's left/right offset. */
.auth-split {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    min-height: calc(100vh - 200px);
    background: var(--tj-bg, #f5f6fb);
    --auth-gutter: max(1.5rem, calc((100vw - 1200px) / 2 + 1.5rem));
}
.auth-split-brand {
    position: relative;
    color: #fff;
    display: flex; align-items: center; justify-content: flex-start;
    /* Left padding = container offset → content aligns with header brand.
       Right padding small (gap to the form column). */
    padding: 3rem 2rem 3rem var(--auth-gutter);
    overflow: hidden;
    background: linear-gradient(135deg, var(--tj-blue-600) 0%, #4338ca 100%);
}
.auth-split-brand-overlay { display: none; }
.auth-split-brand-inner {
    position: relative; z-index: 2;
    max-width: 440px;
    width: 100%;
}

/* ---- Elegant brandmark (refined logo treatment) -------------------- */
.auth-brandmark {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding-bottom: 2rem;
    margin-bottom: 2rem;
    border-bottom: 1px solid rgba(255,255,255,.18);
}
.auth-brandmark-monogram {
    flex-shrink: 0;
    width: 72px; height: 72px;
    display: inline-flex; align-items: center; justify-content: center;
    border: 1px solid rgba(255, 255, 255, .42);
    border-radius: 50%;
    position: relative;
    color: #fff;
}
.auth-brandmark-monogram > span {
    font-family: var(--font-serif);
    font-style: italic;
    font-weight: 500;
    font-size: 1.65rem;
    letter-spacing: .02em;
    line-height: 1;
}
.auth-brandmark-monogram::after {
    content: '';
    position: absolute;
    width: 8px; height: 8px;
    border-radius: 50%;
    background: #fbbf24;
    right: -2px; bottom: 4px;
}
.auth-brandmark-text { display: flex; flex-direction: column; }
.auth-brandmark-name {
    font-family: var(--font-serif, Georgia, serif);
    font-size: 1.85rem;
    font-weight: 600;
    letter-spacing: -.01em;
    line-height: 1.05;
    color: #fff;
}
.auth-brandmark-rule {
    display: block;
    width: 42px; height: 2px;
    margin: .55rem 0;
    background: linear-gradient(90deg, #fbbf24 0%, #f59e0b 100%);
    border-radius: 2px;
}
.auth-brandmark-tagline {
    font-family: var(--font-sans);
    font-size: .72rem;
    text-transform: uppercase;
    letter-spacing: .18em;
    color: rgba(255,255,255,.85);
    line-height: 1.4;
}

.auth-split-points {
    list-style: none; padding: 0; margin: 0;
    font-size: .95rem;
    line-height: 1.5;
}
.auth-split-points li {
    padding: .65rem 0 .65rem 1.75rem;
    position: relative;
    border-top: 1px solid rgba(255,255,255,.12);
    color: rgba(255,255,255,.92);
}
.auth-split-points li:first-child { border-top: 0; }
.auth-split-points li::before {
    content: '\2713';
    position: absolute; left: 0; top: .65rem;
    color: #fbbf24;
    font-weight: 700;
}
.auth-split-form {
    display: flex; align-items: center; justify-content: flex-end;
    /* Right padding = container offset → form right edge aligns with header. */
    padding: 3rem var(--auth-gutter) 3rem 2rem;
    background: var(--tj-bg, #f5f6fb);
}
.auth-split .auth-card { max-width: 440px; width: 100%; padding: 2.25rem; }
.auth-card-head { text-align: center; margin-bottom: 1.5rem; }
.auth-card-head h1 { margin: 0 0 .35rem; font-size: 1.65rem; }
.auth-card-head .muted { margin: 0; font-size: .95rem; }
.auth-row {
    display: flex; justify-content: space-between; align-items: center;
    margin: .25rem 0 1.25rem; font-size: .9rem; gap: .5rem; flex-wrap: wrap;
}
.auth-link { color: var(--tj-blue-600); text-decoration: none; }
.auth-link:hover { text-decoration: underline; }
.auth-foot { text-align: center; margin-top: 1.25rem; font-size: .9rem; }

/* ---- Latest Published Issues (homepage block) -------------------- */
.tj-issues-section { background: #fff; }
.tj-issues-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 1.25rem;
}
/* Dedicated /issues page — slightly tighter cards to fit the sidebar layout. */
.tj-issues-grid--page {
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1rem;
}
.tj-issue-card {
    display: flex;
    flex-direction: column;
    background: #fff;
    border: 1px solid var(--tj-border);
    border-radius: var(--tj-radius, 8px);
    overflow: hidden;
    text-decoration: none;
    color: var(--tj-text);
}
.tj-issue-card:hover { border-color: var(--tj-blue-400); text-decoration: none; }
.tj-issue-cover {
    position: relative;
    aspect-ratio: 4 / 3;
    background: linear-gradient(135deg, var(--tj-blue-600), #4338ca);
    color: #fff;
    display: flex; align-items: center; justify-content: center;
    overflow: hidden;
}
.tj-issue-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.tj-issue-cover-fallback {
    font-family: var(--font-serif, Georgia, serif);
    font-size: 1.85rem; font-weight: 700; letter-spacing: .04em;
}
.tj-issue-badge {
    position: absolute; top: .55rem; left: .55rem;
    background: #fbbf24; color: #1e1b4b;
    font-size: .68rem; font-weight: 700;
    padding: .15rem .55rem; border-radius: 999px;
    text-transform: uppercase; letter-spacing: .06em;
}
.tj-issue-body { padding: .85rem 1rem 1rem; }
.tj-issue-journal {
    font-size: .72rem;
    color: var(--tj-blue-600);
    text-transform: uppercase;
    letter-spacing: .08em;
    font-weight: 700;
    margin-bottom: .25rem;
}
.tj-issue-vol {
    font-family: var(--font-serif, Georgia, serif);
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--tj-text);
    line-height: 1.25;
}
.tj-issue-title {
    font-size: .88rem;
    color: var(--tj-text);
    margin-top: .25rem;
    line-height: 1.4;
}
.tj-issue-meta {
    margin-top: .55rem;
    font-size: .8rem;
    color: var(--tj-muted);
    display: flex; flex-wrap: wrap; gap: .35rem; align-items: center;
}
.tj-issue-dot { color: rgba(0,0,0,.25); }

/* ---- Article-row enhancements (homepage list) -------------------- */
.article-row-abstract {
    font-size: .9rem;
    color: var(--tj-text);
    line-height: 1.55;
    margin: .5rem 0 .25rem;
    max-width: 70ch;
}
.article-row-doi {
    font-family: ui-monospace, Menlo, Consolas, monospace;
}
.article-row-tags {
    margin: .55rem 0 0;
    display: flex; flex-wrap: wrap; gap: .4rem;
}
.tj-tag--link { color: var(--tj-blue-600); text-decoration: none; }
.tj-tag--link:hover { background: #eef0fb; text-decoration: none; }

@media (max-width: 540px) {
    .tj-issues-grid { grid-template-columns: 1fr 1fr; gap: 1rem; }
}

/* ---- Branded confirmation modal (replaces window.confirm) --------
   Native <dialog>, centred, with the Tudor Journals monogram in the
   header bar. No shadow, no animation. */
.tj-confirm {
    border: 1px solid var(--tj-border);
    border-radius: 12px;
    padding: 0;
    width: min(440px, 92vw);
    background: #fff;
    color: var(--tj-text);
}
.tj-confirm::backdrop { background: rgba(15, 17, 38, .55); }

.tj-confirm-head {
    display: flex;
    align-items: center;
    gap: .65rem;
    padding: .85rem 1.25rem;
    background: linear-gradient(135deg, var(--tj-blue-600) 0%, #4338ca 100%);
    color: #fff;
    border-top-left-radius: 11px;
    border-top-right-radius: 11px;
}
.tj-confirm-mark {
    width: 32px; height: 32px;
    border: 1px solid rgba(255,255,255,.42);
    border-radius: 50%;
    display: inline-flex; align-items: center; justify-content: center;
    color: #fff;
    flex-shrink: 0;
    position: relative;
}
.tj-confirm-mark > span {
    font-family: var(--font-serif, Georgia, serif);
    font-style: italic;
    font-size: .82rem;
    font-weight: 500;
    letter-spacing: .02em;
    line-height: 1;
}
.tj-confirm-mark::after {
    content: '';
    position: absolute;
    width: 4px; height: 4px;
    border-radius: 50%;
    background: #fbbf24;
    right: -1px; bottom: 2px;
}
.tj-confirm-brand {
    font-family: var(--font-serif, Georgia, serif);
    font-size: 1.05rem;
    font-weight: 600;
    color: #fff;
}

.tj-confirm-body { padding: 1.5rem 1.5rem .25rem; }
.tj-confirm-title {
    margin: 0 0 .5rem;
    font-family: var(--font-serif, Georgia, serif);
    font-size: 1.2rem;
    font-weight: 600;
}
.tj-confirm-msg {
    margin: 0;
    font-size: .95rem;
    line-height: 1.55;
    color: var(--tj-text);
}

.tj-confirm-foot {
    display: flex;
    justify-content: flex-end;
    gap: .5rem;
    padding: 1.25rem 1.5rem 1.5rem;
}
.tj-confirm-foot .btn { min-width: 90px; }

@media (max-width: 480px) {
    .tj-confirm-body, .tj-confirm-foot { padding-left: 1.25rem; padding-right: 1.25rem; }
    .tj-confirm-foot { flex-direction: column-reverse; }
    .tj-confirm-foot .btn { width: 100%; }
}

/* ---- Internal chat (admin ↔ editor-chief) ------------------------ */
.tj-chat {
    display: grid;
    grid-template-columns: 320px 1fr;
    gap: 0;
    background: #fff;
    border: 1px solid var(--tj-border);
    border-radius: var(--tj-radius, 8px);
    overflow: hidden;
    min-height: 580px;
}
.tj-chat-list {
    border-right: 1px solid var(--tj-border);
    background: #f8f9fc;
    max-height: 720px;
    overflow-y: auto;
}
.tj-chat-list-head {
    font-size: .68rem;
    text-transform: uppercase;
    letter-spacing: .12em;
    color: var(--tj-muted);
    font-weight: 700;
    padding: 1rem 1rem .35rem;
}
.tj-chat-threads { list-style: none; padding: 0; margin: 0; }
.tj-chat-thread {
    display: flex;
    align-items: center;
    gap: .75rem;
    padding: .75rem 1rem;
    text-decoration: none;
    color: var(--tj-text);
    border-bottom: 1px solid var(--tj-border);
}
.tj-chat-thread:hover { background: rgba(79, 94, 197, .06); text-decoration: none; }
.tj-chat-thread.is-active { background: #eef0fb; border-left: 3px solid var(--tj-blue-600); padding-left: calc(1rem - 3px); }
.tj-chat-avatar {
    width: 38px; height: 38px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--tj-blue-600), #4338ca);
    color: #fff;
    font-weight: 600;
    font-size: .82rem;
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0;
}
.tj-chat-avatar--ghost {
    background: transparent;
    color: var(--tj-blue-600);
    border: 1px solid var(--tj-border);
}
.tj-chat-thread-body { flex: 1; min-width: 0; }
.tj-chat-thread-name {
    display: flex; justify-content: space-between; align-items: center; gap: .35rem;
    font-weight: 600; font-size: .92rem;
}
.tj-chat-thread-preview {
    display: block;
    color: var(--tj-muted);
    font-size: .8rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.tj-chat-thread-time {
    color: var(--tj-muted);
    font-size: .72rem;
    flex-shrink: 0;
}
.tj-chat-unread {
    background: var(--tj-blue-600);
    color: #fff;
    font-size: .68rem;
    font-weight: 700;
    padding: .1rem .45rem;
    border-radius: 999px;
    min-width: 18px;
    text-align: center;
}

/* Right pane */
.tj-chat-pane {
    display: flex; flex-direction: column;
    min-width: 0;
}
.tj-chat-empty {
    flex: 1;
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    text-align: center; padding: 2rem;
}
.tj-chat-empty h2 { font-family: var(--font-serif, Georgia, serif); margin: 0 0 .35rem; }
.tj-chat-head {
    display: flex; align-items: center; gap: .75rem;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--tj-border);
    background: #fff;
}
.tj-chat-head-name { font-weight: 600; }
.tj-chat-head-role { font-size: .78rem; text-transform: uppercase; letter-spacing: .08em; }
.tj-chat-messages {
    flex: 1;
    overflow-y: auto;
    padding: 1.25rem;
    background: #fafbff;
    max-height: 540px;
}
.tj-chat-daybreak {
    text-align: center;
    margin: 1rem 0 .5rem;
    position: relative;
}
.tj-chat-daybreak::before {
    content: ''; position: absolute; left: 0; right: 0; top: 50%;
    border-top: 1px solid var(--tj-border); z-index: 0;
}
.tj-chat-daybreak span {
    position: relative; z-index: 1;
    background: #fafbff;
    padding: 0 .65rem;
    color: var(--tj-muted);
    font-size: .72rem;
    text-transform: uppercase;
    letter-spacing: .08em;
}
.tj-chat-msg {
    display: flex; margin: .25rem 0;
}
.tj-chat-msg.is-mine { justify-content: flex-end; }
.tj-chat-bubble {
    max-width: 70%;
    padding: .55rem .85rem;
    border-radius: 14px;
    background: #fff;
    border: 1px solid var(--tj-border);
    color: var(--tj-text);
    font-size: .92rem;
    line-height: 1.5;
    position: relative;
    word-break: break-word;
}
.tj-chat-msg.is-mine .tj-chat-bubble {
    background: var(--tj-blue-600);
    color: #fff;
    border-color: var(--tj-blue-600);
}
.tj-chat-time {
    display: block;
    margin-top: .25rem;
    font-size: .68rem;
    opacity: .65;
    text-align: right;
}
.tj-chat-msg.is-mine .tj-chat-time { color: rgba(255,255,255,.85); opacity: .9; }

.tj-chat-compose {
    display: flex; gap: .5rem;
    padding: .85rem 1rem;
    border-top: 1px solid var(--tj-border);
    background: #fff;
}
.tj-chat-compose textarea {
    flex: 1;
    border: 1px solid var(--tj-border);
    border-radius: 8px;
    padding: .55rem .75rem;
    font-size: .9rem;
    resize: vertical;
    min-height: 44px;
    max-height: 160px;
    font-family: inherit;
}
.tj-chat-compose textarea:focus {
    outline: 2px solid var(--tj-blue-600);
    outline-offset: 1px;
    border-color: var(--tj-blue-600);
}

@media (max-width: 900px) {
    .tj-chat { grid-template-columns: 1fr; min-height: 0; }
    .tj-chat-list { border-right: 0; border-bottom: 1px solid var(--tj-border); max-height: 280px; }
    .tj-chat-messages { max-height: 420px; }
}

/* ---- Required-field asterisk -------------------------------------- */
.form-label .req,
.req {
    color: #dc2626;          /* red-600 — visible against white form bg */
    font-weight: 700;
    margin-left: 2px;
}

/* ---- Keyword chip editor (Metadata Step 1) ------------------------
   Plain input wrapper + UL of pill chips below. JS in metadata.php
   keeps the hidden field in sync. No shadow, no animation, no
   transform — visual policy. */
.keyword-input-wrapper {
    border: 1px solid var(--tj-border);
    border-radius: 8px;
    padding: .55rem .75rem;
    background: #fff;
    cursor: text;
}
.keyword-input-wrapper:focus-within {
    border-color: var(--tj-blue-600);
    outline: 1px solid var(--tj-blue-600);
}
.keyword-input {
    border: none;
    outline: none;
    width: 100%;
    font-size: .95rem;
    padding: .25rem 0;
    background: transparent;
    color: var(--tj-text);
}
.keyword-tags {
    list-style: none;
    padding: 0;
    margin: .55rem 0 0;
    display: flex;
    flex-wrap: wrap;
    gap: .4rem;
}
.keyword-tag {
    display: inline-flex;
    align-items: center;
    gap: .45rem;
    padding: .25rem .7rem;
    border-radius: 999px;
    background: #eef0fb;
    color: #3730a3;
    border: 1px solid #c7d2fe;
    font-size: .85rem;
    font-weight: 600;
    line-height: 1.3;
}
.keyword-remove {
    border: 0;
    background: transparent;
    color: #3730a3;
    cursor: pointer;
    font-size: 1.05rem;
    line-height: 1;
    padding: 0 0 0 .15rem;
}
.keyword-remove:hover { color: #1e1b4b; }
.keyword-counter {
    margin: .5rem 0 0;
    font-size: .8rem;
    color: var(--tj-muted);
}
.keyword-error {
    margin: .35rem 0 0;
    font-size: .82rem;
    color: #b91c1c;
}

/* ---- "New submission" — journal confirmation block ----------------
   Used by app/views/author/choose_journal.php when an author picks
   the journal from the dropdown. Green pill with check icon, no
   shadow, no animation. */
.journal-selected-confirmation {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-top: 1.25rem;
    padding: 1rem 1.1rem;
    border: 1px solid #b7ebc6;
    background: #f0fff4;
    color: #166534;
    border-radius: 10px;
}
.journal-check-circle {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: #16a34a;
    color: #ffffff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 700;
    flex-shrink: 0;
    margin-top: 1px;
}
.journal-selected-body { flex: 1; min-width: 0; }
.journal-selected-head {
    font-size: .82rem;
    text-transform: uppercase;
    letter-spacing: .08em;
    font-weight: 700;
    color: #166534;
    margin-bottom: .35rem;
}
.journal-selected-name {
    font-family: var(--font-serif, Georgia, serif);
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--tj-text);
    margin-bottom: .35rem;
}
.journal-selected-list {
    list-style: none;
    padding: 0;
    margin: 0;
    font-size: .88rem;
    color: var(--tj-text);
}
.journal-selected-list li { padding: .12rem 0; }
.journal-selected-list strong {
    color: var(--tj-muted);
    font-weight: 600;
    margin-right: .25rem;
}

/* Continue button disabled state — readable, no movement on hover */
#tj-newsub-continue[disabled],
#tj-newsub-continue[disabled]:hover {
    opacity: .55;
    cursor: not-allowed;
    background: var(--tj-blue-600);
    color: #fff;
}

/* ---- OAuth provider buttons --------------------------------------- */
.auth-divider {
    display: flex;
    align-items: center;
    gap: .75rem;
    margin: 1.25rem 0 1rem;
    color: var(--tj-muted);
    font-size: .78rem;
    text-transform: uppercase;
    letter-spacing: .1em;
}
.auth-divider::before,
.auth-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--tj-border);
}
.auth-providers {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: .5rem;
}
.auth-provider {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .55rem;
    padding: .55rem 1rem;
    border: 1px solid var(--tj-border);
    border-radius: 6px;
    background: #fff;
    color: var(--tj-text);
    text-decoration: none;
    font-size: .92rem;
    font-weight: 500;
}
.auth-provider:hover { background: #f8f9fc; text-decoration: none; }
.auth-provider-icon { display: inline-flex; line-height: 0; }

@media (max-width: 768px) {
    .auth-split { grid-template-columns: 1fr; min-height: auto; }
    .auth-split-brand { padding: 2rem 1.5rem; text-align: center; }
    .auth-split-brand-inner { max-width: none; }
    .auth-split-points { display: none; }
    .auth-split-form { padding: 2rem 1rem; }
}

/* ---- Card baseline (single border, no shadow) ---------------------- */
.tj-card {
    background: #fff;
    border: 1px solid var(--tj-border);
    border-radius: var(--tj-radius, 8px);
    padding: 1.5rem;
}
.tj-card + .tj-card { margin-top: 1.25rem; }
.tj-card-title {
    margin: 0 0 1rem;
    font-size: 1.05rem;
    font-family: var(--font-sans);
}

/* ---- Button normalization (no transform on hover) ------------------ */
.btn { box-shadow: none !important; }
.btn:hover, .btn:focus { transform: none !important; }

/* ---- Badge normalization ------------------------------------------- */
.badge { box-shadow: none !important; }

/* ---- Thin scrollbars (global) --------------------------------------
   Applies to the page, dashboard main area and any other overflow:auto
   container that didn't define its own scrollbar look. Discreet, no
   shadow, no animation — keeps focus on the content. */
html {
    scrollbar-width: thin;                                   /* Firefox */
    scrollbar-color: rgba(79, 94, 197, .35) transparent;     /* thumb / track */
}
*::-webkit-scrollbar         { width: 8px; height: 8px; }    /* Chrome / Safari / Edge */
*::-webkit-scrollbar-track   { background: transparent; }
*::-webkit-scrollbar-thumb   {
    background: rgba(79, 94, 197, .35);
    border-radius: 4px;
    border: 2px solid transparent;
    background-clip: content-box;
}
*::-webkit-scrollbar-thumb:hover { background: rgba(79, 94, 197, .55); background-clip: content-box; }

/* =====================================================================
   Email template preview (admin) — inbox-style envelope.
   No shadows, no animations. Clean Tudor Journals frame around the
   plain-text body so the admin can see how the message will read.
   ===================================================================== */
.tj-email-meta {
    background: #f8f9fc;
    border: 1px solid var(--tj-border);
    border-radius: var(--tj-radius, 8px);
    padding: .85rem 1.25rem;
    margin-bottom: 1.25rem;
    font-size: .9rem;
}
.tj-email-meta dl {
    margin: 0;
    display: grid;
    grid-template-columns: 80px 1fr;
    row-gap: .2rem;
    column-gap: .75rem;
}
.tj-email-meta dt {
    color: var(--tj-muted);
    text-transform: uppercase;
    letter-spacing: .08em;
    font-size: .7rem;
    font-weight: 700;
    padding-top: .15rem;
}
.tj-email-meta dd { margin: 0; color: var(--tj-text); }

.tj-email {
    max-width: 640px;
    margin: 0 auto;
    background: #fff;
    border: 1px solid var(--tj-border);
    border-radius: var(--tj-radius, 8px);
    overflow: hidden;
}
.tj-email-header {
    padding: 1.5rem 2rem 1rem;
    background: linear-gradient(135deg, var(--tj-blue-600) 0%, #4338ca 100%);
    color: #fff;
}
.tj-email-brand {
    display: flex;
    align-items: center;
    gap: .85rem;
}
.tj-email-header .brand-monogram {
    width: 44px; height: 44px;
    border: 1px solid rgba(255,255,255,.35);
    color: #fff;
}
.tj-email-header .brand-monogram > span {
    font-family: var(--font-serif, Georgia, serif);
    font-style: italic;
    font-size: 1.1rem;
}
.tj-email-brand-text { display: flex; flex-direction: column; line-height: 1.15; }
.tj-email-brand-name {
    font-family: var(--font-serif, Georgia, serif);
    font-size: 1.25rem;
    font-weight: 600;
    color: #fff;
}
.tj-email-brand-tagline {
    font-size: .68rem;
    text-transform: uppercase;
    letter-spacing: .14em;
    color: rgba(255,255,255,.75);
    margin-top: .15rem;
}
.tj-email-rule {
    display: block;
    width: 42px; height: 2px;
    margin-top: .85rem;
    background: linear-gradient(90deg, #fbbf24 0%, #f59e0b 100%);
    border-radius: 2px;
}

.tj-email-body {
    padding: 1.75rem 2rem;
    font-family: var(--font-sans);
    font-size: .98rem;
    line-height: 1.65;
    color: var(--tj-text);
    /* Preserve mono-style breaks but keep proportional font so it looks like
       a normal email, not a code block. */
    white-space: normal;
    word-break: break-word;
}

.tj-email-foot {
    padding: 1.25rem 2rem 1.5rem;
    border-top: 1px solid var(--tj-border);
    background: #f8f9fc;
    font-size: .82rem;
    color: var(--tj-muted);
}
.tj-email-foot p { margin: 0 0 .4rem; }
.tj-email-foot-meta { font-size: .75rem; }
.tj-email-foot-meta a { color: var(--tj-blue-600); text-decoration: none; }
.tj-email-foot-meta a:hover { text-decoration: underline; }

@media (max-width: 540px) {
    .tj-email-header,
    .tj-email-body,
    .tj-email-foot { padding-left: 1.25rem; padding-right: 1.25rem; }
    .tj-email-meta dl { grid-template-columns: 60px 1fr; }
}

/* ---- Preview modal (native <dialog>) ------------------------------- */
.tj-modal {
    border: 1px solid var(--tj-border);
    border-radius: var(--tj-radius, 8px);
    padding: 0;
    width: min(760px, 92vw);
    max-height: 88vh;
    background: #fff;
    color: var(--tj-text);
}
.tj-modal::backdrop { background: rgba(15, 17, 38, .55); }

.tj-modal-head {
    display: flex;
    align-items: center;
    gap: .75rem;
    padding: .85rem 1.25rem;
    border-bottom: 1px solid var(--tj-border);
    background: #f8f9fc;
}
.tj-modal-title {
    margin: 0;
    font-family: var(--font-sans);
    font-size: 1rem;
    font-weight: 600;
    color: var(--tj-text);
}
.tj-modal-key {
    font-family: ui-monospace, Menlo, Consolas, monospace;
    font-size: .82rem;
    color: var(--tj-muted);
    padding: .15rem .55rem;
    border: 1px solid var(--tj-border);
    border-radius: 999px;
    background: #fff;
}
.tj-modal-close {
    margin-left: auto;
    border: 0;
    background: transparent;
    color: var(--tj-muted);
    font-size: 1.6rem;
    line-height: 1;
    cursor: pointer;
    padding: 0 .35rem;
}
.tj-modal-close:hover { color: var(--tj-text); }

.tj-modal-body {
    padding: 0;
    height: 70vh;
    background: #f5f6fb;
}
.tj-modal-iframe {
    width: 100%;
    height: 100%;
    border: 0;
    display: block;
    background: #f5f6fb;
}

@media (max-width: 540px) {
    .tj-modal { width: 96vw; max-height: 92vh; }
    .tj-modal-body { height: 76vh; }
}

/* =====================================================================
   Public Articles page — search + filters + results
   (Inspired by PubMed information architecture; visual identity is
   Tudor Journals — no shadows, no animations, no card-floats.)
   ===================================================================== */

/* ---- Search bar ---------------------------------------------------- */
.tj-articles-search { padding-top: 1.5rem; padding-bottom: 0; }
.tj-search-bar {
    background: #fff;
    border: 1px solid var(--tj-border);
    border-radius: var(--tj-radius, 8px);
    padding: 1.25rem 1.25rem 1rem;
}
.tj-search-label {
    display: block;
    font-size: .72rem;
    color: var(--tj-muted);
    text-transform: uppercase;
    letter-spacing: .12em;
    margin-bottom: .5rem;
    font-weight: 600;
}
.tj-search-row {
    display: flex;
    gap: .5rem;
    align-items: stretch;
    flex-wrap: wrap;
}
.tj-search-input {
    flex: 1;
    min-width: 240px;
    border: 1px solid var(--tj-border);
    border-radius: 6px;
    padding: .65rem .85rem;
    font-size: 1rem;
    background: #fff;
}
.tj-search-input:focus {
    outline: 2px solid var(--tj-blue-600);
    outline-offset: 1px;
    border-color: var(--tj-blue-600);
}
.tj-search-btn { padding: 0 1.5rem; }
.tj-search-help { font-size: .82rem; margin: .65rem 0 0; }

.tj-search-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
    margin-top: 1rem;
    padding-top: .85rem;
    border-top: 1px solid var(--tj-border);
    font-size: .9rem;
}
.tj-search-controls-left { color: var(--tj-text); }
.tj-search-term { color: var(--tj-blue-600); font-weight: 600; }
.tj-search-controls-right {
    display: flex;
    gap: .85rem;
    flex-wrap: wrap;
}
.tj-search-ctl {
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    font-size: .85rem;
    color: var(--tj-muted);
}
.tj-search-ctl select {
    border: 1px solid var(--tj-border);
    border-radius: 4px;
    padding: .3rem .5rem;
    background: #fff;
    font-size: .88rem;
    color: var(--tj-text);
}

/* ---- 2-column grid ------------------------------------------------- */
.tj-articles-main { padding-top: 1.25rem; }
.tj-articles-grid {
    display: grid;
    grid-template-columns: 260px 1fr;
    gap: 1.75rem;
    align-items: start;
}

/* ---- Sidebar filters ----------------------------------------------- */
.tj-filters {
    position: sticky;
    top: 1rem;
}
.tj-filters-toggle { display: none; }
.tj-filters-form {
    background: #fff;
    border: 1px solid var(--tj-border);
    border-radius: var(--tj-radius, 8px);
    padding: 1rem 1rem .75rem;
}
.tj-filter-section {
    border: 0;
    padding: 0 0 .85rem;
    margin: 0 0 .85rem;
    border-bottom: 1px solid var(--tj-border);
}
.tj-filter-section:last-of-type { border-bottom: 0; margin-bottom: 0; padding-bottom: 0; }
.tj-filter-section legend {
    font-size: .72rem;
    text-transform: uppercase;
    letter-spacing: .1em;
    color: var(--tj-muted);
    font-weight: 700;
    margin-bottom: .5rem;
    padding: 0;
}
.tj-filter-check, .tj-filter-radio {
    display: flex;
    align-items: center;
    gap: .55rem;
    padding: .25rem 0;
    font-size: .88rem;
    color: var(--tj-text);
    cursor: pointer;
}
.tj-filter-check input, .tj-filter-radio input { margin: 0; }
.tj-filter-radio-input {
    margin-top: .5rem;
    display: flex; align-items: center; gap: .5rem;
    font-size: .82rem; color: var(--tj-muted);
}
.tj-filter-radio-input input {
    width: 90px;
    border: 1px solid var(--tj-border);
    border-radius: 4px;
    padding: .25rem .4rem;
    font-size: .85rem;
}
.tj-filter-count {
    color: var(--tj-muted);
    font-size: .8rem;
    font-style: normal;
    margin-left: .2rem;
}
.tj-filter-reset {
    display: inline-block;
    font-size: .78rem;
    color: var(--tj-blue-600);
    margin-top: .35rem;
}
.tj-filter-clear-all {
    width: 100%;
    margin-top: .75rem;
    font-size: .85rem;
    padding: .45rem;
}

/* ---- Active chips above results ------------------------------------ */
.tj-active-chips {
    display: flex;
    flex-wrap: wrap;
    gap: .35rem;
    margin-bottom: 1rem;
}
.tj-chip {
    display: inline-flex;
    align-items: center;
    gap: .35rem;
    background: #eef0fb;
    color: var(--tj-blue-600);
    border: 1px solid #c7cef0;
    border-radius: 999px;
    padding: .2rem .7rem;
    font-size: .8rem;
    text-decoration: none;
}
.tj-chip:hover { background: #dfe3f5; text-decoration: none; }
.tj-chip-x { font-weight: 700; }

/* ---- Result list (no cards, divider-based) ------------------------- */
.tj-result-list {
    list-style: none;
    padding: 0;
    margin: 0;
    background: #fff;
    border: 1px solid var(--tj-border);
    border-radius: var(--tj-radius, 8px);
}
.tj-result {
    padding: 1.25rem 1.5rem;
    border-top: 1px solid var(--tj-border);
}
.tj-result:first-child { border-top: 0; }

.tj-result-title {
    font-family: var(--font-serif, Georgia, serif);
    font-size: 1.15rem;
    font-weight: 600;
    margin: 0 0 .35rem;
    line-height: 1.3;
}
.tj-result-title a {
    color: var(--tj-blue-600);
    text-decoration: none;
}
.tj-result-title a:hover { text-decoration: underline; }
.tj-result-authors {
    font-size: .9rem;
    color: var(--tj-text);
    margin: 0 0 .35rem;
}
.tj-result-meta {
    font-size: .82rem;
    color: var(--tj-muted);
    margin: 0 0 .55rem;
    display: flex;
    flex-wrap: wrap;
    gap: .4rem;
    align-items: center;
}
.tj-result-meta a { color: var(--tj-muted); text-decoration: none; }
.tj-result-meta a:hover { color: var(--tj-blue-600); text-decoration: underline; }
.tj-result-type {
    text-transform: uppercase;
    letter-spacing: .06em;
    font-size: .72rem;
    font-weight: 700;
    color: var(--tj-text);
}
.tj-result-dot { color: rgba(0,0,0,.25); }
.tj-result-doi { font-family: ui-monospace, Menlo, Consolas, monospace; }

.tj-result-abstract {
    font-size: .92rem;
    color: var(--tj-text);
    line-height: 1.55;
    margin: .35rem 0 .55rem;
    max-width: 70ch;
}

.tj-result-tags { margin: .3rem 0 0; display: flex; flex-wrap: wrap; gap: .35rem; }
.tj-tag {
    display: inline-block;
    border: 1px solid var(--tj-border);
    border-radius: 4px;
    padding: .12rem .5rem;
    font-size: .72rem;
    color: var(--tj-muted);
    background: #f8f9fc;
}
.tj-tag--oa {
    border-color: #34d399;
    color: #047857;
    background: #ecfdf5;
}
.tj-result-actions { margin: .65rem 0 0; display: flex; flex-wrap: wrap; gap: .85rem; font-size: .85rem; }
.tj-action {
    color: var(--tj-blue-600);
    text-decoration: none;
    font-weight: 500;
}
.tj-action:hover { text-decoration: underline; }

/* Display modes ------------------------------------------------------ */
.tj-result-list--compact  .tj-result { padding: .9rem 1.25rem; }
.tj-result-list--compact  .tj-result-title { font-size: 1rem; }

/* ---- Pagination ---------------------------------------------------- */
.tj-pagination {
    margin-top: 1.25rem;
    display: flex;
    flex-wrap: wrap;
    gap: .35rem;
    align-items: center;
    justify-content: center;
    font-size: .9rem;
}
.tj-page {
    padding: .35rem .75rem;
    border: 1px solid var(--tj-border);
    border-radius: 6px;
    text-decoration: none;
    color: var(--tj-text);
    background: #fff;
}
.tj-page:hover { background: #f8f9fc; text-decoration: none; }
.tj-page.is-current {
    background: var(--tj-blue-600);
    color: #fff;
    border-color: var(--tj-blue-600);
}
.tj-page.is-disabled {
    color: rgba(0,0,0,.3);
    background: #f8f9fc;
    cursor: not-allowed;
}
.tj-page-gap { padding: 0 .25rem; color: var(--tj-muted); }
.tj-page-summary { margin-left: 1rem; }

/* ---- Empty state --------------------------------------------------- */
.tj-empty {
    background: #fff;
    border: 1px solid var(--tj-border);
    border-radius: var(--tj-radius, 8px);
    padding: 2.5rem 1.5rem;
    text-align: center;
}
.tj-empty h2 { font-family: var(--font-serif, Georgia, serif); margin: 0 0 .5rem; font-size: 1.35rem; }
.tj-empty p  { color: var(--tj-muted); max-width: 480px; margin: 0 auto 1rem; }
.tj-empty-actions { display: flex; gap: .65rem; justify-content: center; flex-wrap: wrap; }

/* ---- Responsive ---------------------------------------------------- */
@media (max-width: 900px) {
    .tj-articles-grid { grid-template-columns: 1fr; }
    .tj-filters { position: static; }
    .tj-filters-toggle {
        display: inline-block;
        background: #fff;
        border: 1px solid var(--tj-border);
        border-radius: 6px;
        padding: .55rem 1rem;
        font-weight: 600;
        color: var(--tj-text);
        cursor: pointer;
        margin-bottom: .75rem;
        width: 100%;
        text-align: left;
    }
    .tj-filters-toggle::after { content: ' \25BE'; float: right; }
    .tj-filters-toggle[aria-expanded="true"]::after { content: ' \25B4'; }
    .tj-filters-form { display: none; }
    .tj-filters-form.is-open { display: block; }
    .tj-search-controls { font-size: .85rem; }
    .tj-search-controls-right { width: 100%; }
}
@media (max-width: 540px) {
    .tj-search-btn { flex: 1; }
    .tj-result { padding: 1rem; }
    .tj-result-meta { font-size: .78rem; }
    .tj-pagination { gap: .25rem; }
    .tj-page { padding: .3rem .55rem; font-size: .85rem; }
    .tj-page-summary { width: 100%; text-align: center; margin: .5rem 0 0; }
}
