/*
 * css/pssr-theme.css
 * Unified stylesheet for the minimal PSSR legacy-archive site.
 * One palette/typography system for all pages (home, archive, issue,
 * article, search) - replaces the old per-page bloat stylesheets.
 */

:root {
    --primary: #192842;
    --primary-dark: #101b2d;
    --secondary: #407f9d;
    --accent: #e83e52;
    --accent-light: #fff0f2;
    --text: #172033;
    --muted: #657084;
    --border: #e7eaf0;
    --soft: #f7f9fb;
    --bg: #ffffff;
}

* { box-sizing: border-box; }

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: "Segoe UI", Arial, sans-serif;
    line-height: 1.65;
}

a { color: inherit; text-decoration: none; }

h1, h2, h3 { font-family: Georgia, "Times New Roman", serif; }

/* =====================================
   TOP BAR / BRAND / NAV (shared header)
===================================== */

.topbar {
    background: var(--primary);
    color: #fff;
    font-size: 13px;
    padding: 9px 0;
}

.brand-header {
    background: #fff;
    padding: 26px 0;
    border-bottom: 1px solid var(--border);
}

.journal-logo { max-height: 86px; width: auto; object-fit: contain; }

.journal-brand { display: flex; align-items: center; gap: 16px; }

.journal-name {
    font-family: Georgia, "Times New Roman", serif;
    font-size: 25px;
    font-weight: 600;
    color: var(--primary);
    margin: 0;
}

.main-nav { background: #fff; border-bottom: 1px solid var(--border); }

.main-nav .navbar-nav { gap: 6px; }

.main-nav .nav-link {
    color: var(--primary);
    font-size: 14px;
    font-weight: 600;
    padding: 17px 20px !important;
    position: relative;
    transition: .2s ease;
}

.main-nav .nav-link i { margin-right: 7px; }

.main-nav .nav-link:hover,
.main-nav .nav-link.active { color: var(--accent); }

.main-nav .nav-link.active::after {
    content: "";
    position: absolute;
    left: 18px; right: 18px; bottom: -1px;
    height: 2px;
    background: var(--accent);
}

/* =====================================
   PAGE HEADER (archive / issue / search / article)
===================================== */

.page-header {
    background: var(--soft);
    border-bottom: 1px solid var(--border);
    padding: 50px 0 40px;
}

.breadcrumb { font-size: 14px; margin-bottom: 18px; background: transparent; padding: 0; }

.breadcrumb a { color: var(--secondary); }

.page-title { font-size: 36px; font-weight: 700; color: var(--primary); margin-bottom: 10px; }

.page-intro { color: var(--muted); font-size: 16px; max-width: 760px; }

/* =====================================
   MAIN / SECTION TITLES (home)
===================================== */

.main-content { padding: 58px 0 70px; }

.section-title {
    color: var(--primary);
    font-size: 32px;
    font-weight: 600;
    margin-bottom: 18px;
}

.section-intro { max-width: 920px; color: #4d596d; font-size: 16px; }

.section-divider { height: 1px; background: var(--border); margin: 35px 0; }

.about-cover { max-width: 100%; border-radius: 3px; box-shadow: 0 12px 30px rgba(25, 40, 66, .12); }

.journal-platform-note {
    display: flex; align-items: flex-start; gap: 15px;
    padding: 18px 20px; margin-top: 20px;
    background: var(--soft); border-left: 4px solid var(--secondary); border-radius: 3px;
}

.platform-icon {
    width: 38px; height: 38px; min-width: 38px;
    display: flex; align-items: center; justify-content: center;
    background: var(--secondary); color: #fff; border-radius: 50%;
}

.journal-platform-note h5 { color: var(--primary); font-size: 17px; font-weight: 700; }
.journal-platform-note p { color: #555; font-size: 14px; line-height: 1.7; }

/* Home: Legacy/Latest Archives cards */
.archive-card {
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 28px 30px;
    background: #fff;
    transition: .2s ease;
}

.archive-card:hover { border-color: #d8dde7; box-shadow: 0 12px 28px rgba(25, 40, 66, .07); }

.archive-icon {
    width: 62px; height: 62px; min-width: 62px;
    border-radius: 50%;
    background: var(--accent-light); color: var(--accent);
    display: flex; align-items: center; justify-content: center;
    font-size: 25px;
}

.archive-title { color: var(--primary); font-size: 24px; font-weight: 700; margin-bottom: 4px; }
.archive-text { color: var(--muted); margin: 0; }

.btn-journal {
    background: var(--primary); border: 1px solid var(--primary); color: #fff;
    border-radius: 5px; font-weight: 600; padding: 11px 18px; white-space: nowrap;
    transition: .2s ease; display: inline-block;
}
.btn-journal:hover { background: var(--primary-dark); border-color: var(--primary-dark); color: #fff; }

/* =====================================
   ARCHIVE PAGE (by year/volume)
===================================== */

.archive-section { padding: 45px 0 55px; }

.archive-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 25px;
}

.archive-year {
    border: 1px solid var(--border);
    border-radius: 8px;
    overflow: hidden;
    background: #fff;
}

.year-header {
    background: var(--soft);
    padding: 20px 25px;
    display: flex; align-items: center; justify-content: space-between;
    border-bottom: 1px solid var(--border);
}

.year-title { margin: 0; color: var(--primary); font-size: 24px; font-weight: 700; }
.volume-label { color: var(--muted); font-size: 14px; }

.issue-list {
    padding: 20px;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 18px;
}

.issue-item {
    display: flex; flex-direction: column;
    border: 1px solid var(--border); border-radius: 6px;
    overflow: hidden; background: #fff;
}

.issue-cover-link { display: block; }

.issue-cover-img {
    width: 100%; aspect-ratio: 3 / 4; object-fit: cover; display: block;
}

.issue-cover-icon {
    width: 100%; aspect-ratio: 3 / 4;
    background: var(--soft); border-bottom: 1px solid var(--border);
    display: flex; align-items: center; justify-content: center;
    color: var(--muted); flex-shrink: 0; font-size: 27px;
}

.issue-item-body { padding: 14px; display: flex; flex-direction: column; gap: 6px; flex: 1; }

.issue-item .issue-title {
    color: var(--primary); font-size: 16px; font-weight: 600; line-height: 1.35;
    text-decoration: none;
}
.issue-item .issue-title:hover { text-decoration: underline; }
.issue-meta { color: var(--muted); font-size: 13px; line-height: 1.5; }
.issue-meta i { margin-right: 5px; }

.btn-view-issue {
    border: 1px solid var(--secondary); color: var(--secondary);
    padding: 7px 14px; font-size: 13px; border-radius: 4px;
    white-space: nowrap; transition: all .2s ease;
    text-align: center; margin-top: auto;
}
.btn-view-issue:hover { background: var(--secondary); color: #fff; }

/* =====================================
   ISSUE PAGE (articles list + sidebar)
===================================== */

.issue-label {
    color: var(--secondary); font-size: 14px; font-weight: 600;
    text-transform: uppercase; letter-spacing: .5px; margin-bottom: 8px;
}

.issue-overview {
    border: 1px solid var(--border); border-radius: 7px; padding: 25px;
    margin-bottom: 35px; background: #fff;
}
.overview-title { color: var(--primary); font-size: 21px; font-weight: 600; margin-bottom: 12px; }
.overview-text { color: #5e6b76; font-size: 15px; line-height: 1.7; margin-bottom: 0; }

.article-card {
    border: 1px solid var(--border); border-radius: 7px; padding: 25px;
    margin-bottom: 18px; background: #fff;
    transition: box-shadow .2s ease, border-color .2s ease;
}
.article-card:hover { border-color: #d6dfe7; box-shadow: 0 5px 18px rgba(0, 0, 0, .05); }

.article-type {
    display: inline-block; font-size: 12px; font-weight: 600;
    text-transform: uppercase; letter-spacing: .4px; color: var(--secondary); margin-bottom: 8px;
}
.article-card .article-title { font-size: 20px; line-height: 1.4; font-weight: 600; margin-bottom: 9px; }
.article-card .article-title a { color: var(--primary); }
.article-card .article-title a:hover { color: var(--secondary); }
.article-authors { color: #5d6b77; font-size: 14px; margin-bottom: 14px; }
.article-authors i { margin-right: 5px; }
.article-abstract { color: #626e78; font-size: 14px; line-height: 1.65; margin-bottom: 17px; }

.article-doi { color: var(--muted); font-size: 13px; margin-bottom: 14px; }

.article-footer {
    display: flex; align-items: center; justify-content: space-between;
    border-top: 1px solid var(--border); padding-top: 15px; gap: 15px;
}
.article-info { color: var(--muted); font-size: 13px; }
.article-info span { margin-right: 16px; }
.article-info i { margin-right: 4px; }

.btn-read {
    color: var(--secondary); border: 1px solid var(--secondary); border-radius: 4px;
    padding: 7px 14px; font-size: 13px; white-space: nowrap;
}
.btn-read:hover { color: #fff; background: var(--secondary); }

.article-actions { display: flex; align-items: center; gap: 10px; }

.btn-pdf {
    color: var(--accent); border: 1px solid var(--accent); border-radius: 4px;
    padding: 7px 14px; font-size: 13px; white-space: nowrap;
}
.btn-pdf:hover { color: #fff; background: var(--accent); }

.sidebar-box { border: 1px solid var(--border); border-radius: 7px; padding: 22px; margin-bottom: 20px; }
.sidebar-title { color: var(--primary); font-size: 18px; font-weight: 600; margin-bottom: 15px; }
.sidebar-list { list-style: none; padding: 0; margin: 0; }
.sidebar-list li { padding: 9px 0; border-bottom: 1px solid var(--border); }
.sidebar-list li:last-child { border-bottom: none; }
.sidebar-list a { color: var(--secondary); font-size: 14px; }
.sidebar-list a:hover { text-decoration: underline; }

.download-issue {
    display: block; width: 100%; text-align: center;
    background: var(--primary); color: #fff; padding: 11px 15px;
    border-radius: 4px; font-size: 14px; margin-top: 5px;
}
.download-issue:hover { background: var(--secondary); color: #fff; }

/* =====================================
   ARTICLE PAGE
===================================== */

.article-page { padding: 50px 0 80px; }

.article-page .article-title {
    color: var(--primary); font-size: 36px; line-height: 1.25; font-weight: 700; margin: 0 0 30px;
}

.article-page .section-title { font-size: 23px; margin: 32px 0 15px; }

.authors { border-bottom: 1px solid var(--border); padding-bottom: 25px; }
.author { margin-bottom: 18px; }
.author:last-child { margin-bottom: 0; }
.author-name { color: var(--secondary); font-size: 18px; font-weight: 700; }
.author-affiliation { color: #4e5968; font-size: 15px; line-height: 1.6; margin-top: 3px; }

.doi-box {
    background: var(--soft); border-left: 4px solid var(--secondary);
    padding: 14px 17px; margin: 25px 0 30px;
}
.doi-box strong { color: #222; }
.doi-box a { color: #26719b; text-decoration: underline; word-break: break-word; }

.keywords { line-height: 1.8; }
.keyword {
    display: inline-block; background: #eef3f5; color: #465b67;
    border-radius: 3px; padding: 5px 10px; margin: 3px 3px 3px 0; font-size: 14px;
}

.abstract { font-family: Georgia, "Times New Roman", serif; font-size: 17px; line-height: 1.85; text-align: justify; }
.abstract p { margin-bottom: 15px; }

.article-sidebar { position: sticky; top: 25px; }
.sidebar-card { border: 1px solid var(--border); background: #fff; margin-bottom: 22px; }
.sidebar-header { background: var(--primary); color: #fff; padding: 12px 16px; font-size: 16px; font-weight: 700; }
.sidebar-body { padding: 17px; }

.issue-card { display: flex; align-items: center; gap: 15px; }
.issue-card .issue-cover-icon { width: 60px; height: 78px; font-size: 20px; }

.pdf-button {
    display: block; width: 100%; background: var(--primary); color: #fff;
    border: 0; border-radius: 3px; padding: 11px 15px; text-align: center; font-weight: 600;
}
.pdf-button:hover { background: var(--primary-dark); color: #fff; }

.detail-row {
    display: flex; justify-content: space-between; gap: 15px;
    padding: 9px 0; border-bottom: 1px solid #eee; font-size: 14px;
}
.detail-row:last-child { border-bottom: 0; }
.detail-label { color: var(--muted); font-weight: 600; }
.detail-value { color: #222; text-align: right; }

.citation-select { border: 1px solid #ccd3da; border-radius: 3px; height: 43px; font-size: 14px; }
.citation-text {
    margin-top: 15px; padding: 15px; background: var(--soft); border: 1px solid var(--border);
    font-family: Georgia, "Times New Roman", serif; font-size: 14px; line-height: 1.7;
}
.copy-citation {
    margin-top: 10px; width: 100%; border: 1px solid var(--secondary);
    background: #fff; color: var(--secondary); padding: 8px; border-radius: 3px;
    font-size: 14px; font-weight: 600;
}
.copy-citation:hover { background: var(--secondary); color: #fff; }

.license-text { font-size: 14px; color: #555; line-height: 1.7; }

/* =====================================
   SEARCH PAGE
===================================== */

.search-input {
    height: 52px; border: 1px solid var(--border); font-size: 15px;
}
.search-input:focus { border-color: var(--secondary); box-shadow: 0 0 0 .15rem rgba(64, 127, 157, .12); }

.search-result {
    border: 1px solid var(--border); border-radius: 7px; padding: 25px;
    margin-bottom: 18px; background: #fff;
    transition: box-shadow .2s ease, border-color .2s ease;
}
.search-result:hover { border-color: #d6dfe7; box-shadow: 0 5px 18px rgba(0, 0, 0, .05); }

.search-result mark {
    background: #fff3a3;
    color: inherit;
    padding: 0 1px;
    border-radius: 2px;
}

/* =====================================
   FOOTER
===================================== */

.footer { background: var(--primary-dark); color: #fff; }
.footer-main { padding: 52px 0 45px; }
.footer-brand { display: flex; align-items: center; gap: 14px; margin-bottom: 22px; }
.footer-logo { object-fit: contain; max-height: 58px; }
.footer-journal-name { font-size: 18px; font-weight: 600; }
.footer-url { color: #aeb9cb; font-size: 13px; }

.contact-item { display: flex; gap: 13px; margin-bottom: 13px; color: #dbe1eb; font-size: 14px; }
.contact-item i { color: #fff; width: 18px; margin-top: 5px; }

.license-box { color: #dbe1eb; font-size: 13px; }
.license-box a { color: #9db7e4; }

.cc-badge {
    background: #fff; color: #111; display: inline-flex; align-items: center; gap: 5px;
    padding: 4px 7px; border-radius: 3px; margin-bottom: 14px;
}

.footer-bottom {
    border-top: 1px solid rgba(255,255,255,.08); padding: 15px 0;
    color: #9da8bb; font-size: 12px;
}

/* =====================================
   RESPONSIVE
===================================== */

@media (max-width: 991.98px) {
    .brand-header { padding: 20px 0; }
    .journal-name { font-size: 21px; }
    .main-nav .nav-link { padding: 12px 5px !important; }
    .main-nav .nav-link.active::after { display: none; }
    .archive-grid { grid-template-columns: 1fr; }
    .issue-list { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 767.98px) {
    .journal-brand { justify-content: center; text-align: center; flex-direction: column; }
    .journal-logo { max-height: 70px; }
    .journal-name { font-size: 20px; }
    .main-content { padding: 40px 0 50px; }
    .section-title { font-size: 27px; }
    .about-cover { width: 150px; margin: 25px auto 0; display: block; }
    .archive-card { padding: 22px; }
    .archive-card .d-flex { flex-wrap: wrap; }
    .archive-card .btn-journal { margin-top: 18px; width: 100%; }
    .page-title { font-size: 29px; }
    .year-header { align-items: flex-start; flex-direction: column; }
    .issue-list { grid-template-columns: repeat(2, 1fr); }
    .article-card { padding: 20px; }
    .article-footer { align-items: flex-start; flex-direction: column; }
    .article-actions { width: 100%; }
    .btn-read, .btn-pdf { width: 100%; text-align: center; }
    .article-sidebar { position: static; margin-top: 40px; }
    .article-page .article-title { font-size: 28px; }
    .abstract { text-align: left; font-size: 16px; }
}

@media (max-width: 575.98px) {
    .issue-list { grid-template-columns: 1fr; }
}
