/* ===========================================================
 * OPUS MUNDI — Content & Article CSS
 * Styles the Article Details, Issue TOC, Archive Grid,
 * and Search Results with glassmorphism and accent borders.
 * =========================================================== */

/* ── COMMON CONTAINER ───────────────────────────────────────────── */
.om-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 64px;
    width: 100%;
}

/* ── GLASS CARD UTILITY ────────────────────────────────────────── */
.om-glass-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 4px;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.2);
    margin-bottom: 32px;
    padding: 24px;
    transition: border-color 0.3s, box-shadow 0.3s;
}

.om-glass-card:hover {
    border-color: rgba(0, 212, 255, 0.25);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

[data-theme="light"] .om-glass-card {
    background: rgba(255, 255, 255, 0.5);
    border-color: rgba(179, 139, 0, 0.12);
    box-shadow: 0 4px 20px rgba(179, 139, 0, 0.05);
}

[data-theme="light"] .om-glass-card:hover {
    border-color: rgba(179, 139, 0, 0.3);
}

.om-card-title {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.4);
    margin-bottom: 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    padding-bottom: 8px;
}

[data-theme="light"] .om-card-title {
    color: rgba(13, 31, 45, 0.45);
    border-bottom-color: rgba(179, 139, 0, 0.08);
}

/* ── ARTICLE DETAILS PAGE ────────────────────────────────────────── */
.om-article-main-grid {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 40px;
    align-items: start;
}

.om-article-sidebar {
    position: sticky;
    top: 24px;
}

.om-article-cover img {
    width: 100%;
    height: auto;
    border-radius: 2px;
    display: block;
}

/* Article Title Area */
.om-article-title-wrap {
    margin-bottom: 32px;
}

.om-article-page-title {
    font-size: 32px;
    font-weight: 700;
    line-height: 1.25;
    color: #ffffff;
    margin-bottom: 12px;
}

[data-theme="light"] .om-article-page-title {
    color: #0d1f2d;
}

.om-article-subtitle {
    font-size: 18px;
    font-weight: 300;
    color: rgba(255, 255, 255, 0.6);
    line-height: 1.4;
}

[data-theme="light"] .om-article-subtitle {
    color: rgba(13, 31, 45, 0.65);
}

/* Authors */
.om-author-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.om-author-name {
    font-size: 16px;
    font-weight: 600;
    color: #00d4ff;
    display: flex;
    align-items: center;
    gap: 8px;
}

[data-theme="light"] .om-author-name {
    color: #b38b00;
}

.om-author-affiliation {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.4);
    margin-top: 2px;
}

.om-orcid-icon-link {
    text-decoration: none;
}

/* DOI */
.om-article-doi {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 12px;
    padding: 12px 20px;
}

.om-doi-label {
    font-weight: 700;
    color: rgba(255, 255, 255, 0.35);
}

.om-article-doi a {
    color: #00d4ff;
    text-decoration: none;
}

/* Abstract & References */
.om-abstract-content,
.om-references-content {
    font-size: 14px;
    line-height: 1.8;
    color: rgba(255, 255, 255, 0.65);
}

[data-theme="light"] .om-abstract-content,
[data-theme="light"] .om-references-content {
    color: rgba(13, 31, 45, 0.7);
}

/* Galleys */
.om-galley-links {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.om-galley-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 18px;
    background: rgba(0, 212, 255, 0.08);
    border: 1px solid rgba(0, 212, 255, 0.15);
    border-radius: 4px;
    color: #00d4ff !important;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    text-decoration: none;
    transition: all 0.2s;
}

.om-galley-link:hover {
    background: #00d4ff;
    color: #000 !important;
    box-shadow: 0 0 15px rgba(0, 212, 255, 0.4);
    transform: translateY(-2px);
}

/* ── ISSUE & ARCHIVE GRID ────────────────────────────────────────── */
.om-archive-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 32px;
}

.om-issue-summary {
    height: 100%;
    display: flex;
    flex-direction: column;
    padding: 0;
    overflow: hidden;
}

.om-is-cover {
    height: 200px;
    overflow: hidden;
    display: block;
}

.om-is-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.om-issue-summary:hover .om-is-cover img {
    transform: scale(1.05);
}

.om-is-content {
    padding: 24px;
}

.om-is-title {
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 8px;
}

.om-is-title a {
    color: #ffffff;
    text-decoration: none;
}

[data-theme="light"] .om-is-title a { color: #0d1f2d; }

.om-is-title a:hover { color: #00d4ff; }

/* ── SEARCH PAGE FORM ─────────────────────────────────────────────
 * DO NOT use generic width:100% or flex:1 on buttons here.
 * The search form has two distinct rows: query row + filter row.
 * FUNCTIONAL WIRING: field names (query, searchField) are OJS internals.
 * ─────────────────────────────────────────────────────────────── */
.om-search-form-wrap {
    margin-bottom: 48px;
}

/* ── Query row: input + submit button side by side ── */
.om-search-query-row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.om-search-input {
    flex: 1;
    min-width: 0; /* prevents overflow */
    background: rgba(255, 255, 255, 0.04) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    border-radius: 6px !important;
    color: rgba(255, 255, 255, 0.85) !important;
    padding: 10px 16px !important;
    font-size: 14px !important;
    outline: none !important;
    transition: border-color 0.2s !important;
}

.om-search-input:focus {
    border-color: #00d4ff !important;
    box-shadow: 0 0 0 3px rgba(0, 212, 255, 0.08) !important;
}

[data-theme="light"] .om-search-input {
    background: rgba(0, 0, 0, 0.03) !important;
    border-color: rgba(179, 139, 0, 0.2) !important;
    color: #0d1f2d !important;
}

.om-search-submit-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
    white-space: nowrap;
    padding: 10px 22px;
    background: rgba(0, 212, 255, 0.10);
    border: none; /* Seamless — no visible border */
    border-radius: 6px;
    color: #00d4ff;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.5px;
    cursor: pointer;
    transition: all 0.2s;
    width: auto !important;
}

.om-search-submit-btn:hover {
    background: #00d4ff;
    color: #000;
    box-shadow: 0 0 15px rgba(0, 212, 255, 0.35);
}

[data-theme="light"] .om-search-submit-btn {
    background: rgba(179, 139, 0, 0.1);
    border: none;
    color: #b38b00;
}


[data-theme="light"] .om-search-submit-btn:hover {
    background: #b38b00;
    color: #fff;
}

/* ── Filter row: label + select ── */
.om-search-filters-row {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.om-filter-label {
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.5px;
    color: rgba(255, 255, 255, 0.45);
    white-space: nowrap;
    text-transform: uppercase;
}

[data-theme="light"] .om-filter-label {
    color: rgba(13, 31, 45, 0.45);
}

.om-filter-select {
    background: rgba(255, 255, 255, 0.04) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    border-radius: 6px !important;
    color: rgba(255, 255, 255, 0.75) !important;
    padding: 6px 12px !important;
    font-size: 13px !important;
    outline: none !important;
    cursor: pointer;
    min-width: 180px;
    appearance: auto; /* keep native dropdown arrow */
    transition: border-color 0.2s !important;
}

.om-filter-select:focus {
    border-color: #00d4ff !important;
}

.om-filter-select option {
    background: #0d121a;
    color: rgba(255, 255, 255, 0.85);
}

[data-theme="light"] .om-filter-select {
    background: rgba(0, 0, 0, 0.03) !important;
    border-color: rgba(179, 139, 0, 0.2) !important;
    color: #0d1f2d !important;
}

[data-theme="light"] .om-filter-select option {
    background: #fdfcf0;
    color: #0d1f2d;
}



/* ── ARTICLE SUMMARY (TOC / SEARCH) ───────────────────────────── */
.om-article-summary {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 24px;
}

.om-as-content {
    flex: 1;
}

.om-as-title {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 8px;
}

.om-as-title a {
    color: #ffffff;
    text-decoration: none;
}

.om-as-title a:hover {
    color: #00d4ff;
}

[data-theme="light"] .om-as-title a { color: #0d1f2d; }

.om-as-authors {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.45);
}

.om-as-galleys {
    display: flex;
    gap: 8px;
}

.om-as-galleys .om-galley-link {
    padding: 6px 12px;
    font-size: 10px;
}

/* ── PAGINATION ──────────────────────────────────────────────────── */
.om-pagination {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 48px;
}

.om-pagination-btn {
    padding: 10px 24px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.6);
    text-decoration: none;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: all 0.2s;
}

.om-pagination-btn:hover {
    border-color: #00d4ff;
    color: #00d4ff;
    background: rgba(0, 212, 255, 0.05);
}

/* ── BREADCRUMBS MODS ────────────────────────────────────────────── */
.om-breadcrumb-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    gap: 12px;
}

/* ── MOBILE ──────────────────────────────────────────────────────── */
@media (max-width: 900px) {
    .om-article-main-grid { grid-template-columns: 1fr; }
    .om-article-sidebar { position: static; }
    .om-container { padding: 32px 20px; }
    .om-article-summary { flex-direction: column; align-items: flex-start; }
    .om-as-galleys { margin-top: 16px; }
}

/* ================================================================
   COMPREHENSIVE LIGHT THEME OVERRIDES — content.css
   Fixes all om-* classes that were still rendering with dark colors
   when [data-theme="light"] is set.
   ================================================================ */

/* ── Page-level container ── */
[data-theme="light"] .om-container {
    color: #1a1f2e;
}

/* ── Article Hero (About/Archive page top banner) ── */
[data-theme="light"] .om-article-page,
[data-theme="light"] .om-article-hero {
    background: transparent !important;
    color: #1a1f2e !important;
}

[data-theme="light"] .om-article-hero-meta {
    color: rgba(13, 31, 45, 0.45) !important;
}

[data-theme="light"] .om-article-title {
    color: #0d1f2d !important;
}

/* ── Badge (e.g. "About", "Issue") ── */
[data-theme="light"] .om-badge {
    background: rgba(179, 139, 0, 0.1) !important;
    color: #b38b00 !important;
    border-color: rgba(179, 139, 0, 0.25) !important;
}

/* ── Section labels ── */
[data-theme="light"] .om-section-label {
    color: #0d1f2d !important;
    border-bottom-color: rgba(179, 139, 0, 0.15) !important;
}

/* ── About grid, card bodies & sidebar ── */
[data-theme="light"] .om-about-grid,
[data-theme="light"] .om-about-main,
[data-theme="light"] .om-about-sidebar {
    background: transparent !important;
}

[data-theme="light"] .om-about-section {
    background: rgba(255, 255, 255, 0.7) !important;
    border-color: rgba(179, 139, 0, 0.1) !important;
}

[data-theme="light"] .om-about-body,
[data-theme="light"] .om-about-body p,
[data-theme="light"] .om-about-body li {
    color: rgba(13, 31, 45, 0.75) !important;
}

/* ── Journal meta card ── */
[data-theme="light"] .om-journal-meta-card {
    background: rgba(255, 255, 255, 0.8) !important;
    border-color: rgba(179, 139, 0, 0.12) !important;
}

[data-theme="light"] .om-meta-card-title {
    color: #0d1f2d !important;
    border-bottom-color: rgba(179, 139, 0, 0.1) !important;
}

[data-theme="light"] .om-meta-list {
    color: rgba(13, 31, 45, 0.6) !important;
}

[data-theme="light"] .om-meta-key {
    color: rgba(13, 31, 45, 0.45) !important;
}

[data-theme="light"] .om-meta-val {
    color: #1a1f2e !important;
}

/* ── Author info ── */
[data-theme="light"] .om-author-affiliation {
    color: rgba(13, 31, 45, 0.5) !important;
}

[data-theme="light"] .om-as-authors {
    color: rgba(13, 31, 45, 0.5) !important;
}

/* ── DOI ── */
[data-theme="light"] .om-doi-label {
    color: rgba(13, 31, 45, 0.35) !important;
}

[data-theme="light"] .om-article-doi a {
    color: #b38b00 !important;
}

/* ── Gallery links ── */
[data-theme="light"] .om-galley-link {
    background: rgba(179, 139, 0, 0.07) !important;
    border-color: rgba(179, 139, 0, 0.2) !important;
    color: #b38b00 !important;
}

[data-theme="light"] .om-galley-link:hover {
    background: #b38b00 !important;
    color: #fff !important;
    box-shadow: 0 0 12px rgba(179, 139, 0, 0.35) !important;
}

/* ── Archive/issue grid ── */
[data-theme="light"] .om-issue-summary {
    background: rgba(255, 255, 255, 0.75) !important;
    border-color: rgba(179, 139, 0, 0.1) !important;
}

[data-theme="light"] .om-is-title a {
    color: #0d1f2d !important;
}

[data-theme="light"] .om-is-title a:hover {
    color: #b38b00 !important;
}

/* ── Article in list (TOC) ── */
[data-theme="light"] .om-as-title a {
    color: #0d1f2d !important;
}

[data-theme="light"] .om-as-title a:hover {
    color: #b38b00 !important;
}

/* ── Pagination ── */
[data-theme="light"] .om-pagination-btn {
    border-color: rgba(13, 31, 45, 0.15) !important;
    color: rgba(13, 31, 45, 0.6) !important;
}

[data-theme="light"] .om-pagination-btn:hover {
    border-color: #b38b00 !important;
    color: #b38b00 !important;
    background: rgba(179, 139, 0, 0.05) !important;
}

