﻿/* ============================================================
   CPESE 2027 - Style Enhancement Layer
   Additive modernization over style.min.css (loaded last).
   ============================================================ */

/* ---------- Base ---------- */
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; text-rendering: optimizeLegibility; }
::selection { background: #408ed4; color: #fff; }
a:focus-visible, .main-menu a:focus-visible, .header-top a:focus-visible { outline: 2px solid #2b75b5; outline-offset: 2px; }

/* ---------- Header top bar (desktop) ---------- */
.header-top {
    background: linear-gradient(90deg, #2b75b5 0%, #408ed4 60%, #2b75b5 100%);
    border-bottom: none;
}
.header-top .header-top-left p,
.header-top .header-top-left p span { color: #fff; }
.header-top .header-top-left p strong { color: #fff; font-weight: 700; }
.header-top.full-border { border-bottom: none; }

/* ---------- Logo & menu ---------- */
.logo a { display: inline-block; transition: opacity .25s ease; }
.logo a:hover { opacity: .9; }

.header-menu.sticker { transition: box-shadow .3s ease; }
.header-menu.sticker.sticky,
.header-menu.sticky { box-shadow: 0 4px 18px rgba(23, 58, 110, .18); }

.main-menu > ul > li > a { position: relative; transition: color .25s ease; }
.main-menu > ul > li > a::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 12px;
    width: 0;
    height: 3px;
    border-radius: 2px;
    background: #fff;
    transition: width .25s ease;
}
.main-menu > ul > li:hover > a::after { width: 28px; }

/* ---------- Breadcrumbs ---------- */
.breadcrumbs_area {
    background: linear-gradient(135deg, #f3f8fd 0%, #e9f1fa 100%);
    border-top: 1px solid #dde9f4;
    border-bottom: 1px solid #dde9f4;
}
.breadcrumb_content ul li:last-child { color: #2b75b5; font-weight: 600; }

/* ---------- Section headings ---------- */
.about-head h3 {
    position: relative;
    display: inline-block;
    padding-bottom: 12px;
}
.about-head h3::after {
    content: "";
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    bottom: 2px;
    width: 64px;
    height: 3px;
    border-radius: 2px;
    background: linear-gradient(90deg, #2b75b5, #408ed4);
}
.about-head h5 { color: #2b75b5; }

/* ---------- Content media ---------- */
.about-content img { border-radius: 6px; }
.about-content img.style12,
.about-content img.style17,
.about-content img.style18,
.about-content img.style20,
.about-content img.style21 { box-shadow: 0 4px 16px rgba(23, 58, 110, .14); }

/* ---------- Data tables (program / registration / publication) ---------- */
.table-desc {
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 18px rgba(23, 58, 110, .08);
}
.table-desc .cart-page table thead tr th {
    background: linear-gradient(135deg, #2b75b5, #408ed4);
    color: #fff;
    border-bottom: 3px solid #1d5c99;
}
.table-desc .cart-page table tbody tr:nth-child(even) td { background: #f6fafd; }
.table-desc .cart-page table td,
.table-desc .cart-page table th { transition: background-color .2s ease; }

/* ---------- Scroll to top ---------- */
.scroll-to-top {
    border-radius: 50%;
    background-color: #2b75b5;
    color: #fff;
    box-shadow: 0 4px 16px rgba(23, 58, 110, .35);
    transition: background-color .25s ease, transform .25s ease;
}
.scroll-to-top:hover { background-color: #1d5c99; color: #fff; transform: translateY(-3px); }

/* ---------- Footer ---------- */
.footer-bottom { background: #f7fafd; }

/* ---------- Mobile refinements ---------- */
@media only screen and (max-width: 991px) {
    .scroll-to-top { right: 18px; bottom: 18px; }
    .about-head h3::after { width: 44px; }
    .about-content img { max-width: 100%; height: auto; }
    .table-desc { box-shadow: 0 2px 10px rgba(23, 58, 110, .08); }
}


/* ---------- Home: Publication History timeline ---------- */
.pub-history {
    list-style: none;
    margin: 22px 0 10px;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}
.pub-item {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 14px 16px 14px 20px;
    border: 1px solid #e3edf7;
    border-radius: 12px;
    background: linear-gradient(180deg, #ffffff 0%, #f8fbfe 100%);
    box-shadow: 0 2px 8px rgba(23, 58, 110, .05);
    position: relative;
    overflow: hidden;
    transition: transform .22s ease, box-shadow .22s ease, border-color .22s ease;
}
.pub-item::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background: #c2d9ee;
    transition: background .22s ease;
}
.pub-item:hover {
    transform: translateY(-3px);
    border-color: #cfe2f3;
    box-shadow: 0 8px 22px rgba(23, 58, 110, .13);
}
.pub-item:hover::before { background: linear-gradient(180deg, #b9d6ef, #2b75b5); }
.pub-item.is-latest {
    background: linear-gradient(180deg, #ffffff 0%, #f2f8fe 100%);
}
.pub-item.is-latest::before { background: linear-gradient(180deg, #2b75b5, #55a3e4); }
.pub-year {
    flex: 0 0 62px;
    width: 62px;
    height: 62px;
    border-radius: 12px;
    background: linear-gradient(135deg, #2b75b5, #408ed4);
    color: #fff;
    font-size: 17px;
    font-weight: 700;
    letter-spacing: .4px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(43, 117, 181, .28);
    flex-shrink: 0;
}
.pub-item.is-latest .pub-venue::after {
    content: "Latest edition";
    display: inline-block;
    margin-left: 8px;
    padding: 1px 8px;
    font-size: 10.5px;
    font-weight: 600;
    letter-spacing: .3px;
    color: #fff;
    background: linear-gradient(135deg, #2b75b5, #408ed4);
    border-radius: 999px;
    vertical-align: 2px;
    white-space: nowrap;
}
.pub-item.is-latest .pub-year {
    background: linear-gradient(135deg, #1d5c99, #2b75b5);
    box-shadow: 0 4px 14px rgba(29, 92, 153, .38);
}
.pub-body { flex: 1 1 auto; min-width: 0; text-align: left; }
.pub-venue {
    font-size: 14px;
    font-weight: 600;
    line-height: 1.45;
    color: #1f3b5c;
    margin: 5px 0 9px;
}
.pub-badges { display: flex; flex-wrap: wrap; gap: 6px; }
.pub-badge {
    font-size: 11.5px;
    line-height: 1.5;
    padding: 3px 10px;
    border-radius: 999px;
    background: #eaf3fb;
    border: 1px solid #d3e6f7;
    color: #2b75b5;
    white-space: nowrap;
}
.pub-badge.is-scie { background: #f1fbf5; border-color: #cdeeda; color: #1f7a4d; }
.pub-badge.is-muted { background: #f5f7fa; border-color: #e6ebf1; color: #63758a; }

@media only screen and (max-width: 991px) {
    .pub-history { grid-template-columns: 1fr; gap: 11px; margin: 18px 0 8px; }
    .pub-year { flex-basis: 52px; width: 52px; height: 52px; font-size: 14px; border-radius: 10px; }
    .pub-item { padding: 12px 13px; gap: 12px; }
    .pub-venue { font-size: 13px; margin: 4px 0 8px; }
}

/* Narrow phones: stack the badge above the text so nothing gets clipped */
@media only screen and (max-width: 560px) {
    .pub-history { width: calc(100vw - 34px); grid-template-columns: 1fr; }
    .pub-item { display: block; padding: 12px 14px 12px 18px; }
    .pub-year { width: 46px; height: 46px; flex-basis: 46px; font-size: 12.5px; border-radius: 10px; margin-bottom: 8px; }
    .pub-venue { font-size: 12.5px; line-height: 1.4; margin: 0 0 8px; }
    .pub-item.is-latest .pub-venue::after { display: block; margin: 5px 0 0; width: -moz-fit-content; width: fit-content; }
    .pub-badges { gap: 5px; }
    .pub-badge { font-size: 10px; padding: 2px 7px; }
}


/* ---------- Home: Important Dates date modules ---------- */
.dates-panel { margin-top: 2px; }
.dates-group + .dates-group { margin-top: 20px; }
.dates-title {
    font-size: 11.5px;
    font-weight: 700;
    letter-spacing: 1.2px;
    text-transform: uppercase;
    color: #2b75b5;
    margin: 0 0 9px;
}
.dates-list {
    list-style: none;
    margin: 0;
    padding: 0;
    border: 1px solid #e3edf7;
    border-radius: 10px;
    overflow: hidden;
    background: #fff;
    box-shadow: 0 2px 8px rgba(23, 58, 110, .05);
}
.dates-list li {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 11px 15px;
    border-bottom: 1px solid #eef4fa;
    font-size: 13.5px;
    position: relative;
    transition: background-color .2s ease;
}
.dates-list li:last-child { border-bottom: none; }
.dates-list li:nth-child(even) { background: #f8fbfe; }
.dates-list li:hover { background: #f2f8fe; }
.dates-label { color: #35536f; }
.dates-value { font-weight: 700; color: #1f3b5c; white-space: nowrap; }
.dates-list li.is-key .dates-label { color: #2b75b5; font-weight: 700; }
.dates-list li.is-key .dates-value { color: #2b75b5; }
.dates-list li.is-key::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: linear-gradient(180deg, #2b75b5, #408ed4);
}

@media only screen and (max-width: 560px) {
    .dates-group + .dates-group { margin-top: 16px; }
    .dates-list li { flex-wrap: wrap; padding: 10px 13px; font-size: 12.5px; gap: 2px 10px; }
    .dates-list li:nth-child(even) { background: #f8fbfe; }
    .dates-value { font-size: 12.5px; }
}
