/* ─── Accent color overrides (blue) ─────────────────────────────────────────── */
.mil-social-icons li a:hover { color: #2563eb !important; }
.mil-accent { color: #2563eb !important; }

/* ─── Floating pill top bar ─────────────────────────────────────────────────── */
.mil-top-panel {
    background: transparent !important;
    border-bottom: none !important;
    box-shadow: none !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    pointer-events: none;
    padding-left: 0 !important;
    padding-right: 0 !important;
}

.nav-pills-container {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 12px;
    width: 100%;
    padding-right: 16px;
}

/* ─── The pill ───────────────────────────────────────────────────────────────── */
.nav-pill {
    pointer-events: all;
    display: flex;
    align-items: center;
    height: 58px;
    max-width: 1100px;
    padding: 0 8px 0 4px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(20px) saturate(1.8);
    -webkit-backdrop-filter: blur(20px) saturate(1.8);
    border: 1px solid rgba(37, 99, 235, 0.1);
    box-shadow: 0 2px 16px rgba(37, 99, 235, 0.07), 0 1px 4px rgba(0, 0, 0, 0.04);
    transition: height 0.25s ease, box-shadow 0.25s ease;
}
.nav-scrolled .nav-pill {
    height: 50px;
    box-shadow: 0 6px 32px rgba(37, 99, 235, 0.14), 0 2px 8px rgba(0, 0, 0, 0.07);
}

/* ─── Nav logo ───────────────────────────────────────────────────────────────── */
.nav-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    padding: 0 16px 0 8px;
    flex-shrink: 0;
}
.nav-logo-initials {
    width: 30px;
    height: 30px;
    background: #2563eb;
    color: #fff;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 0.5px;
    flex-shrink: 0;
    transition: opacity 0.2s ease;
}
.nav-logo:hover .nav-logo-initials { opacity: 0.85; }
.nav-logo-name {
    font-size: 17px;
    font-weight: 600;
    color: #1a1a1a;
    letter-spacing: 0.1px;
    white-space: nowrap;
}

/* ─── Nav links: pill-highlight ──────────────────────────────────────────────── */
.mil-navigation ul li > a {
    font-size: 17px !important;
    font-weight: 500 !important;
    letter-spacing: 0.2px !important;
    color: #374151 !important;
    padding: 6px 12px !important;
    border-radius: 999px;
    transition: background 0.2s ease, color 0.2s ease !important;
    position: relative;
}
.mil-navigation ul li > a::after { display: none !important; }
.mil-navigation ul li > a:hover {
    background: rgba(37, 99, 235, 0.07);
    color: #1a1a1a !important;
}
.mil-navigation ul li.mil-active > a::before { display: none !important; }
.mil-navigation ul li.mil-active > a {
    background: rgba(37, 99, 235, 0.12) !important;
    color: #2563eb !important;
    font-weight: 600 !important;
}

/* ─── Desktop submenu dropdown ───────────────────────────────────────────────── */
.mil-top-panel .mil-navigation ul li.mil-has-children ul {
    background-color: rgba(255, 255, 255, 0.97);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(37, 99, 235, 0.1);
    border-radius: 16px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
}
.mil-top-panel .mil-navigation ul li.mil-has-children ul li a {
    color: #374151;
    border-radius: 8px;
}
.mil-top-panel .mil-navigation ul li.mil-has-children ul li a:hover {
    color: #2563eb;
    background: rgba(37, 99, 235, 0.06);
}

/* ─── Mobile nav ─────────────────────────────────────────────────────────────── */
@media screen and (max-width: 1200px) {
    .nav-pills-container { padding-right: 0; justify-content: center; }
    .nav-pill {
        max-width: calc(100% - 32px);
        margin: 0 16px;
        border-radius: 16px;
        padding: 0 8px;
    }
    .nav-logo { padding: 0 12px 0 8px; }
    .nav-logo-name { display: none; }
    .mil-top-panel .mil-navigation {
        top: 74px;
        background-color: rgba(255, 255, 255, 0.97) !important;
        backdrop-filter: blur(20px) !important;
        -webkit-backdrop-filter: blur(20px) !important;
        border-bottom: 1px solid rgba(37, 99, 235, 0.1) !important;
        box-shadow: 0 8px 32px rgba(0, 0, 0, 0.07) !important;
        border-radius: 0 0 16px 16px;
    }
    .mil-top-panel .mil-navigation nav ul li a { color: #1a1a1a !important; }
    .mil-top-panel .mil-navigation nav ul li a:hover { color: #2563eb !important; }
    .mil-top-panel .mil-navigation nav ul li.mil-active > a {
        color: #2563eb !important;
        background: none !important;
        font-weight: 600 !important;
    }
    .mil-top-panel .mil-top-panel-btns {
        padding-right: 0 !important;
        margin-left: auto;
    }
}

/* ─── Hero tagline pill ─────────────────────────────────────────────────────── */
.hero-tagline {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 0.5px;
    color: #2563eb;
    background: rgba(37, 99, 235, 0.07);
    border: 1px solid rgba(37, 99, 235, 0.18);
    border-radius: 999px;
    padding: 5px 14px;
    margin-bottom: 18px;
}
.hero-tagline-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #2563eb;
    display: inline-block;
}

/* ─── Hero glassmorphism card ───────────────────────────────────────────────── */
.hero-glass-panel {
    background: rgba(255, 255, 255, 0.68);
    backdrop-filter: blur(14px) saturate(1.5);
    -webkit-backdrop-filter: blur(14px) saturate(1.5);
    border: 1px solid rgba(255, 255, 255, 0.65);
    border-radius: 18px;
    box-shadow: 0 4px 32px rgba(37, 99, 235, 0.05), inset 0 1px 0 rgba(255, 255, 255, 0.9);
    padding: 36px 40px;
    margin-bottom: 8px;
}
@media screen and (max-width: 768px) {
    .hero-glass-panel { padding: 24px 20px; }
}

/* ─── Tooltip ───────────────────────────────────────────────────────────────── */
.tooltip {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: help;
    margin-left: 8px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: rgba(37, 99, 235, 0.08);
    border: 1px solid rgba(37, 99, 235, 0.2);
    color: #2563eb;
    transition: background 0.2s ease, border-color 0.2s ease;
    vertical-align: middle;
}
.tooltip:hover {
    background: rgba(37, 99, 235, 0.14);
    border-color: rgba(37, 99, 235, 0.4);
}
.tooltip .tooltiptext {
    visibility: hidden;
    width: 300px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(16px) saturate(1.6);
    -webkit-backdrop-filter: blur(16px) saturate(1.6);
    color: #1a1a1a;
    text-align: left;
    border-radius: 14px;
    padding: 14px 18px;
    position: absolute;
    z-index: 99;
    left: 50%;
    transform: translateX(-50%) translateY(4px);
    bottom: calc(100% + 12px);
    font-size: 13px;
    font-weight: 400;
    line-height: 1.6;
    opacity: 0;
    transition: opacity 0.22s ease, transform 0.22s ease;
    pointer-events: none;
    border: 1px solid rgba(37, 99, 235, 0.12);
    box-shadow: 0 8px 32px rgba(37, 99, 235, 0.08), 0 2px 8px rgba(0, 0, 0, 0.06);
}
.tooltip .tooltiptext::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 6px solid transparent;
    border-top-color: rgba(255, 255, 255, 0.95);
}
.tooltip:hover .tooltiptext {
    visibility: visible;
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* ─── Social icons ──────────────────────────────────────────────────────────── */
.social-icon {
    position: relative;
    transition: color 0.2s ease, transform 0.2s ease !important;
}
.social-icon:hover { transform: scale(1.15); }

/* ─── News illustrated background ───────────────────────────────────────────── */
.news-bg-wrap {
    position: relative;
    background: #ffffff;
    border-radius: 24px;
    padding: 36px;
    overflow: hidden;
}
.news-bg-svg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}
@media screen and (max-width: 768px) {
    .news-bg-wrap { padding: 20px 16px; border-radius: 16px; }
}

/* ─── News cards ────────────────────────────────────────────────────────────── */
@keyframes cardFadeUp {
    from { opacity: 0; transform: translateY(18px); }
    to   { opacity: 1; transform: translateY(0); }
}
.news-card { animation: cardFadeUp 0.5s ease both; }

.news-badge {
    display: inline-flex;
    align-items: center;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1.2px;
    text-transform: uppercase;
    border-radius: 6px;
    padding: 3px 10px;
}
.news-date-chip {
    display: inline-flex;
    align-items: center;
    font-size: 11px;
    font-weight: 600;
    color: #9ca3af;
    background: rgba(0, 0, 0, 0.04);
    border-radius: 4px;
    padding: 2px 8px;
    margin-left: 8px;
    vertical-align: middle;
    letter-spacing: 0.3px;
}

/* ─── Hero layout ────────────────────────────────────────────────────────────── */
.mil-side-banner.mil-center {
    flex-direction: column !important;
    align-items: flex-start !important;
    justify-content: center !important;
    position: relative;
    height: auto !important;
    min-height: calc(100vh - 90px);
    padding: 40px 0;
    gap: 0;
}
.mil-side-banner.mil-center .mil-banner-title {
    flex: unset;
    min-width: unset;
    width: 100%;
    position: relative;
    z-index: 1;
}

/* ─── Hero photo — absolute, behind content ──────────────────────────────────── */
.hero-photo-wrap {
    position: absolute !important;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    z-index: 0;
    flex-shrink: unset;
}
.hero-photo-wrap::before {
    content: '';
    position: absolute;
    inset: -40px;
    background: radial-gradient(ellipse at center, rgba(37, 99, 235, 0.08) 0%, transparent 68%);
    z-index: 0;
    pointer-events: none;
}
.hero-photo {
    position: relative;
    z-index: 1;
    width: 270px;
    border-radius: 14px;
    box-shadow: 0 12px 48px rgba(0, 0, 0, 0.08);
    display: block;
}

@media screen and (max-width: 992px) {
    .hero-photo-wrap { display: none; }
}

/* ─── Publications page ────────────────────────────────────────────────────── */
.mil-section-title .mil-divider { display: none; }
.mil-timeline ul { flex: 1; min-width: 0; }
.pub-paper-item {
    padding: 14px 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
    transition: background 0.2s ease;
}
.pub-paper-item:last-child { border-bottom: none; }

.pub-venue-badge {
    display: inline-flex;
    align-items: center;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.5px;
    border-radius: 999px;
    padding: 3px 11px;
    color: #0d7a5f;
    background: rgba(16, 185, 129, 0.08);
    border: 1px solid rgba(16, 185, 129, 0.25);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}
.role-badge {
    display: inline-flex;
    align-items: center;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.5px;
    border-radius: 999px;
    padding: 3px 11px;
    margin-right: 6px;
    margin-bottom: 4px;
    color: #0d7a5f;
    background: rgba(16, 185, 129, 0.08);
    border: 1px solid rgba(16, 185, 129, 0.25);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}
.pub-award-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 11px;
    font-weight: 700;
    background: rgba(37, 99, 235, 0.08);
    color: #2563eb;
    border-radius: 6px;
    padding: 3px 10px;
    border: 1px solid rgba(37, 99, 235, 0.2);
}
.pub-toggle-btn {
    background: none;
    border: 1px solid rgba(37, 99, 235, 0.25);
    color: #2563eb;
    font-size: 12px;
    font-weight: 600;
    padding: 4px 14px;
    border-radius: 999px;
    cursor: pointer;
    transition: background 0.15s ease, border-color 0.15s ease;
    margin-top: 10px;
    margin-right: 6px;
    font-family: inherit;
    letter-spacing: 0.3px;
}
.pub-toggle-btn:hover { background: rgba(37, 99, 235, 0.07); border-color: #2563eb; }
.pub-toggle-btn.active { background: rgba(37, 99, 235, 0.1); border-color: #2563eb; }

.pub-abstract-box {
    margin-top: 14px;
    padding: 14px 18px;
    background: rgba(37, 99, 235, 0.04);
    border-radius: 10px;
    border-left: 3px solid rgba(37, 99, 235, 0.3);
    font-size: 15px;
    color: #444;
    line-height: 1.75;
}
.pub-links {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 6px;
    align-items: center;
}
.pub-link {
    font-size: 12px;
    font-weight: 600;
    color: #2563eb;
    text-decoration: none;
    letter-spacing: 0.2px;
    padding: 3px 11px;
    border-radius: 999px;
    background: rgba(37, 99, 235, 0.07);
    border: 1px solid rgba(37, 99, 235, 0.18);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    transition: background 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}
.pub-link:hover {
    background: rgba(37, 99, 235, 0.14);
    border-color: rgba(37, 99, 235, 0.35);
    box-shadow: 0 2px 8px rgba(37, 99, 235, 0.12);
}

.pub-year-group {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 4px;
}
.pub-year-badge {
    font-size: 13px;
    font-weight: 700;
    color: #9ca3af;
    letter-spacing: 0.5px;
    white-space: nowrap;
}
.pub-title {
    font-size: 18px;
    font-weight: 700;
    color: #1a1a1a;
    line-height: 1.4;
    margin: 0;
    flex: 1;
}
.pub-authors {
    font-size: 15px;
    color: #555;
    margin: 3px 0 6px;
    line-height: 1.5;
}
.pub-section-count {
    font-size: 13px;
    font-weight: 600;
    color: #9ca3af;
    background: rgba(0, 0, 0, 0.04);
    padding: 3px 10px;
    border-radius: 999px;
    display: inline-block;
}

/* ─── Research project cards ────────────────────────────────────────────────── */
.proj-list {
    display: flex;
    flex-direction: column;
    gap: 24px;
}
.proj-card {
    display: flex;
    flex-direction: row;
    background: #ffffff;
    border: 1px solid rgba(0, 0, 0, 0.07);
    border-radius: 16px;
    box-shadow: 0 4px 24px rgba(37, 99, 235, 0.05);
    overflow: hidden;
    text-decoration: none;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.proj-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 36px rgba(37, 99, 235, 0.12);
}
.proj-card-img {
    width: 340px;
    flex-shrink: 0;
    overflow: hidden;
    background: #f1f5f9;
    display: flex;
}
.proj-card-img img {
    width: 100%;
    flex: 1;
    min-height: 0;
    object-fit: cover;
    transition: transform 0.35s ease;
}
.proj-card:hover .proj-card-img img {
    transform: scale(1.04);
}
.proj-card-body {
    padding: 28px 32px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}
.proj-card-category {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.8px;
    text-transform: uppercase;
    color: #2563eb;
    margin: 0 0 10px;
}
.proj-card-title {
    font-size: 20px;
    font-weight: 700;
    color: #1a1a1a;
    line-height: 1.4;
    margin: 0 0 18px;
}
.proj-card-link {
    font-size: 13px;
    font-weight: 600;
    color: #2563eb;
    letter-spacing: 0.2px;
}
@media screen and (max-width: 768px) {
    .proj-card { flex-direction: column; }
    .proj-card-img { width: 100%; aspect-ratio: 16 / 9; }
    .proj-card-body { padding: 20px; }
    .proj-card-title { font-size: 17px; }
}
