/* =====================================================================
   Home page refresh – loaded last on the home page only (home.php).
   Brings the older sections (About, News & Events, Vision/Mission,
   messages, Why Apply, Why MPPLG, What to expect, tables, People,
   Research, Demography) in line with the newer Placement Brochure and
   Class of 2027 blocks: soft gradients, rounded cards, left-aligned text.
   Remove the <link> in home.php to go back to the old look.
   ===================================================================== */

:root {
    --hm-wine: #6a0a1d;
    --hm-red: #890c25;
    --hm-rose: #b71a34;
    --hm-grad: linear-gradient(135deg, #6a0a1d 0%, #890c25 55%, #b71a34 100%);
    --hm-tint: linear-gradient(180deg, #fbf5f6 0%, #ffffff 100%);
    --hm-ink: #1f1d24;
    --hm-text: #5c5e66;
    --hm-line: #ece6e8;
    --hm-card: 0 18px 44px rgba(17, 12, 45, 0.07);
    --hm-card-hover: 0 24px 54px rgba(137, 12, 37, 0.14);
}

/* ---------- shared: headings, body copy, buttons ---------- */
.about2 h2, .aboutProgram h2, .whyApply h2, .whyUs .title, .whatExpect .title,
.learningPedology .title, .admissionSection h2, .facultyMemberSection .title,
.research .title, .studentDemography .title, .directorMessage .row h2,
.expertTalkSeries h2 {
    color: var(--hm-ink);
    font-weight: 700;
    letter-spacing: -0.02em;
}
.about2 p, .aboutProgram p, .directorMessage .row p:not(.fw-semibold), .admissionSection p {
    color: var(--hm-text);
    text-align: left !important;          /* justified text leaves rivers of white space */
    line-height: 1.75;
}
.about2 p span, .aboutProgram p span { text-align: left !important; }

.btn-readmore {
    padding: 11px 24px;
    border: 0;
    border-radius: 10px;
    background: var(--hm-red);
    box-shadow: 0 10px 22px rgba(137, 12, 37, 0.22);
    transition: transform .2s ease, box-shadow .2s ease, background-color .2s ease;
}
.btn-readmore:hover, .btn-readmore:focus {
    color: #fff;
    background: var(--hm-wine);
    transform: translateY(-2px);
    box-shadow: 0 14px 28px rgba(137, 12, 37, 0.28);
    border: 0 !important;
}

/* ---------- About IIT Kharagpur / About CoEPPLG ---------- */
#aboutIITKgp::before, #aboutIITKgp .aboutImgWrapper::before { display: none; }   /* striped corner blocks */
.about2 { padding: 96px 0; }
.about2 h2 {
    /* "ABOUT" becomes a small eyebrow label, the name below it the real title */
    font-size: 13px;
    font-weight: 700;
    letter-spacing: .16em;
    text-transform: uppercase;
    color: var(--hm-red);
    margin-bottom: 18px;
}
.about2 h2 span {
    display: block;
    margin-top: 10px;
    font-size: 34px;
    line-height: 1.2;
    letter-spacing: -0.02em;
    text-transform: none;
    color: var(--hm-ink);
}
.about2 h5 { color: var(--hm-ink); font-weight: 500; }
.about2 .aboutImgWrapper img {
    border-radius: 22px;
    box-shadow: var(--hm-card);
}
#aboutCoEPPLG {
    background: var(--hm-tint);
    border-top: 1px solid var(--hm-line);
    border-bottom: 1px solid var(--hm-line);
}

/* News & Events list */
.EventList {
    padding: 26px 24px 22px;
    background: #fff;
    border: 1px solid var(--hm-line);
    border-radius: 20px;
    box-shadow: var(--hm-card);
}
.EventList .title { font-size: 20px; letter-spacing: -0.01em; }
.about2 .EventList .singleResearchAndAchievement {
    position: relative;
    min-height: 0;
    padding: 16px 16px 14px 20px;
    background: #fff;
    border: 1px solid var(--hm-line);
    border-radius: 14px;
    transition: border-color .2s ease, box-shadow .2s ease;
}
.about2 .EventList .singleResearchAndAchievement::before {
    content: "";
    position: absolute;
    left: 0; top: 14px; bottom: 14px;
    width: 4px;
    border-radius: 0 4px 4px 0;
    background: var(--hm-grad);
}
.about2 .EventList a:hover .singleResearchAndAchievement {
    border-color: #e3c9cf;
    box-shadow: 0 10px 24px rgba(137, 12, 37, 0.10);
}
.about2 .EventList .singleResearchAndAchievement h5 { color: var(--hm-ink); font-size: 15px; line-height: 1.4; }
.EventList .swiper-button-next .ico, .EventList .swiper-button-prev .ico {
    border-color: var(--hm-line);
    color: var(--hm-red);
    background: #fff;
}
.EventList .swiper-button-next .ico:hover, .EventList .swiper-button-prev .ico:hover {
    background: var(--hm-red);
    border-color: transparent;
    color: #fff;
}

/* News & Events: smooth vertical loop (cards printed twice, track moves up by half, then repeats) */
.evMarquee {
    height: 380px;
    overflow: hidden;
    -webkit-mask-image: linear-gradient(180deg, transparent 0, #000 8%, #000 92%, transparent 100%);
    mask-image: linear-gradient(180deg, transparent 0, #000 8%, #000 92%, transparent 100%);
}
.evTrack { animation: ev-scroll var(--ev-dur, 40s) linear infinite; }
.evMarquee:hover .evTrack, .evMarquee:focus-within .evTrack { animation-play-state: paused; }
.evList { display: flex; flex-direction: column; gap: 14px; padding: 8px 0 6px; }   /* bottom padding + gap keep the join seamless */
.evList + .evList { padding-top: 8px; }
.evItem > a { display: block; text-decoration: none; }
@media (min-width: 768px) {   /* card takes the height of the About text beside it; the list fills what's left */
    .about2 .row > [class*="col-"] > .EventList { height: 100%; display: flex; flex-direction: column; }
    .about2 .EventList .evMarquee { flex: 1 1 0; height: auto; min-height: 200px; }
}
@keyframes ev-scroll {
    from { transform: translateY(0); }
    to { transform: translateY(-50%); }
}
@media (prefers-reduced-motion: reduce) {   /* no auto-scroll: a normal scrollable list instead */
    .evTrack { animation: none; }
    .evMarquee { overflow-y: auto; -webkit-mask-image: none; mask-image: none; }
    .evList[aria-hidden="true"] { display: none; }
}

/* ---------- Vision & Mission ---------- */
.missonVission {
    padding: 96px 0;
    background:
        radial-gradient(600px 300px at 85% 0%, rgba(255, 255, 255, 0.10), transparent 70%),
        radial-gradient(500px 260px at 0% 100%, rgba(0, 0, 0, 0.18), transparent 70%),
        var(--hm-grad);
}
.missonVission::before { display: none; }
.missonVission .row > [class*="col-"] > * { position: relative; }
.missonVission .row > [class*="col-"] {
    padding-top: 30px;
    padding-bottom: 30px;
}
.missonVission h5 {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 14px;
    letter-spacing: .16em;
    margin-bottom: 16px;
    color: rgba(255, 255, 255, 0.85);
}
.missonVission h5::before {
    content: "";
    width: 28px; height: 2px;
    background: rgba(255, 255, 255, 0.7);
}
.missonVission p {
    max-width: 92%;
    font-size: 20px;
    line-height: 1.6;
    font-weight: 500;
    color: #fff;
    text-align: left !important;
}
.missonVission .btn-readmore {
    background: #fff;
    color: var(--hm-red);
    box-shadow: 0 10px 22px rgba(0, 0, 0, 0.18);
}
.missonVission .btn-readmore:hover { background: #fff; color: var(--hm-wine); }

/* ---------- Director's & Chairperson's messages ---------- */
.directorMessage { margin-top: 96px; }
.directorMessage .row {
    position: relative;
    overflow: hidden;
    padding: 48px;
    background: #fff;
    background-image: none;
    border: 1px solid var(--hm-line);
    border-radius: 24px;
    box-shadow: var(--hm-card);
}
.directorMessage .row::before { display: none; }
.directorMessage .row img { border-radius: 18px; box-shadow: 0 16px 36px rgba(17, 12, 45, 0.14); }
.directorMessage .row h2 { font-size: 34px; margin-bottom: 18px; }
.directorMessage .row p { font-size: 16px; }
.directorMessage .row p.fw-semibold {
    position: relative;
    padding-left: 22px;
    border-left: 3px solid var(--hm-rose);
    color: var(--hm-ink);
    font-size: 18px;
    font-style: italic;
    line-height: 1.6;
    text-align: left !important;
}
.chairPersonMsg .msgWrapper {
    background:
        radial-gradient(500px 260px at 100% 0%, rgba(255, 255, 255, 0.10), transparent 70%),
        var(--hm-grad);
    border-top-left-radius: 24px;
    border-bottom-left-radius: 24px;
    padding: 48px;
}
.chairPersonMsg .msgWrapper p { text-align: left !important; line-height: 1.7; }
.chairPersonMsg .msgWrapper .btn-readmore { background: #fff; color: var(--hm-red); }
.chairPersonMsg img { border-top-right-radius: 24px; border-bottom-right-radius: 24px; }

/* ---------- Programme / Why Apply / Why MPPLG / What to expect ---------- */
.aboutProgram { padding: 96px 0 80px; }
.aboutProgram h2 { font-size: 36px; }
/* show the 2nd paragraph by default (its DB markup carries d-none); View More reveals the rest */
.aboutProgram p:not(.viewMoreProgram) + p.viewMoreProgram { display: block !important; }
.mpEyebrow {
    display: block;
    margin-bottom: 10px;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: .18em;
    text-transform: uppercase;
    color: var(--hm-red);
}
.mpInfo {
    padding: 28px 28px 24px;
    background: var(--hm-tint);
    border: 1px solid var(--hm-line);
    border-radius: 24px;
    box-shadow: var(--hm-card);
}
.mpVenn { display: block; width: 100%; max-width: 400px; height: auto; margin: 0 auto; }
.mpC { stroke-width: 1.5; }
.mpC1 { fill: rgba(106, 10, 29, .10); stroke: rgba(106, 10, 29, .35); }
.mpC2 { fill: rgba(137, 12, 37, .10); stroke: rgba(137, 12, 37, .35); }
.mpC3 { fill: rgba(183, 26, 52, .10); stroke: rgba(183, 26, 52, .35); }
.mpL { font-size: 16px; font-weight: 700; fill: var(--hm-ink); text-anchor: middle; }
.mpCore { fill: var(--hm-red); filter: drop-shadow(0 8px 16px rgba(137, 12, 37, .3)); }
.mpCoreT { font-size: 15px; font-weight: 800; letter-spacing: .04em; fill: #fff; text-anchor: middle; }
.mpStats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-top: 18px; }
.mpStat {
    padding: 14px 10px;
    text-align: center;
    background: #fff;
    border: 1px solid var(--hm-line);
    border-radius: 14px;
}
.mpStat b { display: block; font-size: 30px; line-height: 1; color: var(--hm-red); }
.mpStat span { display: block; margin-top: 6px; font-size: 13px; line-height: 1.35; color: var(--hm-text); }
.mpTags { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-top: 16px; }
.mpTags span {
    padding: 5px 12px;
    font-size: 13px;
    font-weight: 600;
    color: var(--hm-red);
    background: #fff;
    border: 1px solid rgba(137, 12, 37, .2);
    border-radius: 999px;
}

.whyApply {
    padding: 96px 0;
    background: var(--hm-tint);
    border-top: 1px solid var(--hm-line);
}
.whyApply h2 { font-size: 36px; text-align: center; margin-bottom: 20px !important; }
@media (max-width: 767px) { .whyApply .row > [class*="col-"] + [class*="col-"] { margin-top: 16px; } }
.whyApply .card {
    position: relative;
    overflow: hidden;
    padding: 32px 28px;
    background: #fff;
    border: 1px solid var(--hm-line);
    border-radius: 20px;
    box-shadow: var(--hm-card);
    transition: transform .25s ease, box-shadow .25s ease;
    height: 100%;
    text-align: center;
}
.whyApply .card::before { display: none; }
.whyApply .card.active, .whyApply .card:hover {
    background: var(--hm-grad);
    border-color: transparent;
    transform: translateY(-4px);
    box-shadow: var(--hm-card-hover);
}
.whyApply .card h5 { font-size: 21px; line-height: 1.3; margin-bottom: 14px; color: var(--hm-ink); }
.whyApply .card p { color: var(--hm-text); line-height: 1.7; text-align: center !important; }
.whyIco {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 60px;
    height: 60px;
    margin: 0 auto 20px;
    border-radius: 16px;
    background: #fbeef1;
    color: var(--hm-red);
    transition: background .25s ease, color .25s ease;
}
.whyIco svg { width: 28px; height: 28px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.whyApply .card.active .whyIco, .whyApply .card:hover .whyIco { background: rgba(255, 255, 255, .16); color: #fff; }

.whyUs { padding: 96px 0; }
.whyUs .title { font-size: 36px; margin-bottom: 8px; }
.whyUs .card {
    padding: 22px 24px;
    gap: 16px;
    background: #fff;
    border: 1px solid var(--hm-line);
    border-radius: 16px;
    box-shadow: 0 8px 22px rgba(17, 12, 45, 0.05);
    transition: transform .25s ease, box-shadow .25s ease, background .25s ease;
}
.whyUs .card .ico, .whyUs .card i {
    flex-shrink: 0;
    width: 44px; height: 44px;
    padding: 11px;
    border-radius: 12px;
    background: #fbeef1;
    color: var(--hm-red);
    box-sizing: border-box;
}
.whyUs .card h6 { font-size: 18px; color: var(--hm-ink); }
.whyUs .card:hover {
    background: var(--hm-grad);
    transform: translateY(-3px);
    box-shadow: var(--hm-card-hover);
}
.whyUs .card:hover .ico, .whyUs .card:hover i { background: rgba(255, 255, 255, 0.16); color: #fff; }

.whatExpect { padding: 96px 0; background: var(--hm-tint); border-top: 1px solid var(--hm-line); }
.whatExpect .mpEyebrow { text-align: center; }
.whatExpect .title { font-size: 36px; text-align: center; margin-bottom: 48px; }

/* learning journey: numbered steps joined by a line (row on desktop, vertical timeline below 992px) */
.weJourney {
    position: relative;
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 20px;
    margin: 0;
    padding: 0;
    list-style: none;
}
.weJourney::before {
    content: "";
    position: absolute;
    top: 22px;
    left: 10%;
    right: 10%;
    border-top: 2px dashed rgba(137, 12, 37, .3);
}
.weStep { position: relative; display: flex; flex-direction: column; }
.weNum {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 46px;
    height: 46px;
    margin: 0 auto 20px;
    border: 2px solid var(--hm-red);
    border-radius: 50%;
    background: #fff;
    font-size: 15px;
    font-weight: 700;
    color: var(--hm-red);
    box-shadow: 0 0 0 6px #fbf5f6;
    transition: background .25s ease, color .25s ease;
}
.weCard {
    flex: 1;
    padding: 24px 22px;
    background: #fff;
    border: 1px solid var(--hm-line);
    border-radius: 18px;
    box-shadow: var(--hm-card);
    transition: transform .25s ease, box-shadow .25s ease;
}
.weStep:hover .weCard { transform: translateY(-4px); box-shadow: var(--hm-card-hover); }
.weStep:hover .weNum { background: var(--hm-red); color: #fff; }
.weIco {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    margin-bottom: 16px;
    border-radius: 14px;
    background: #fbeef1;
    color: var(--hm-red);
}
.weIco svg, .weList svg { fill: none; stroke: currentColor; stroke-linecap: round; stroke-linejoin: round; }
.weIco svg { width: 24px; height: 24px; stroke-width: 1.8; }
.weCard h5 { margin-bottom: 10px; font-size: 18px; font-weight: 700; line-height: 1.3; color: var(--hm-ink); }
.weCard p { margin: 0; font-size: 15px; line-height: 1.65; color: var(--hm-text); text-align: left !important; }
.weList { margin: 12px 0 0; padding: 0; list-style: none; }
.weList li { display: flex; gap: 8px; align-items: flex-start; margin-top: 8px; font-size: 14px; line-height: 1.5; color: var(--hm-ink); }
.weList svg { flex-shrink: 0; width: 16px; height: 16px; margin-top: 2px; stroke-width: 2.5; color: var(--hm-red); }

@media (max-width: 991px) {
    .weJourney { grid-template-columns: 1fr; gap: 16px; }
    .weJourney::before { display: none; }
    .weStep:not(:last-child)::after {   /* line from this number down to the next one */
        content: "";
        position: absolute;
        top: 46px;
        bottom: -16px;
        left: 22px;
        border-left: 2px dashed rgba(137, 12, 37, .3);
    }
    .weStep { flex-direction: row; gap: 18px; }
    .weNum { flex-shrink: 0; margin: 0; }
    .weIco { display: none; }
    .whatExpect .title { margin-bottom: 32px; }
}

/* ---------- Teaching-learning pedagogy & admission tables ---------- */
.learningPedology { padding: 96px 0; }
.learningPedology .title { font-size: 36px; font-weight: 700; }
.learningPedology .title b, .learningPedology .title strong { font-weight: inherit; }
.learningPedology p { color: var(--hm-text); line-height: 1.75; text-align: left !important; }
.learningPedology h5, .learningPedology h6 { color: var(--hm-red); font-weight: 700; }
.learningPedology .table, .admissionSection table {
    border-collapse: separate;
    border-spacing: 0;
    overflow: hidden;
    border: 1px solid var(--hm-line) !important;
    border-radius: 16px;
    box-shadow: 0 10px 26px rgba(17, 12, 45, 0.05);
}
.learningPedology .table th { background: var(--hm-grad); border: 0; padding: 14px 16px; }
.learningPedology .table td { padding: 12px 16px; border-color: var(--hm-line); color: var(--hm-ink); }
.learningPedology .table tbody tr:nth-child(even) td { background: #fcf8f9; }
.admissionSection { padding: 96px 0; background: var(--hm-tint); border-top: 1px solid var(--hm-line); }
.admissionSection h2 { font-size: 36px; }
.admissionSection .table-bordered > :not(caption) > * > * { border-color: var(--hm-line); padding: 12px 14px; }
.admissionSection table th { background: #fbeef1; color: var(--hm-ink); }
.admissionSection h2 { margin-bottom: 24px; }
.admissionSection ul li { align-items: flex-start; gap: 12px; margin-bottom: 14px; color: var(--hm-text); line-height: 1.6; }
.admissionSection ul li::before {   /* red tick instead of the Font Awesome glyph */
    content: "";
    flex-shrink: 0;
    width: 20px;
    height: 20px;
    margin-top: 3px;
    background: var(--hm-red);
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='10'/%3E%3Cpath d='M8 12.5l2.5 2.5L16 9.5'/%3E%3C/svg%3E") center / contain no-repeat;
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='10'/%3E%3Cpath d='M8 12.5l2.5 2.5L16 9.5'/%3E%3C/svg%3E") center / contain no-repeat;
}
.adInfo {
    padding: 28px;
    background: #fff;
    border: 1px solid var(--hm-line);
    border-radius: 24px;
    box-shadow: var(--hm-card);
}
.adInfoHead {
    margin: 0 0 8px !important;
    font-size: 13px !important;
    font-weight: 700;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--hm-text);
}
.adFact { display: flex; align-items: center; gap: 16px; padding: 16px 0; border-bottom: 1px solid var(--hm-line); }
.adFact b { display: block; font-size: 20px; line-height: 1.25; color: var(--hm-ink); }
.adFact div > span { display: block; margin-top: 3px; font-size: 14px; line-height: 1.5; color: var(--hm-text); }
.adIco, .adRing {
    position: relative;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    border-radius: 16px;
    background: #fbeef1;
    color: var(--hm-red);
}
.adIco svg { width: 26px; height: 26px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.adRing { background: none; }
.adRing svg { position: absolute; inset: 0; transform: rotate(-90deg); }
.adRingBg, .adRingFg { fill: none; stroke-width: 5; }
.adRingBg { stroke: #fbeef1; }
.adRingFg { stroke: var(--hm-red); stroke-linecap: round; }
.adRing em { font-style: normal; font-size: 12px; font-weight: 800; color: var(--hm-red); }
.adPref { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding-top: 18px; }
.adPref span {
    padding: 5px 12px;
    font-size: 13px;
    font-weight: 600;
    color: var(--hm-red);
    background: #fbeef1;
    border-radius: 999px;
}
.adPref .adPrefLabel { padding: 0 4px 0 0; background: none; color: var(--hm-text); font-weight: 600; }

/* ---------- People ---------- */
.facultyMemberSection { padding: 96px 0; }
.facultyMemberSection .title { font-size: 36px; }
.facultyMemberSection .singleProfessor {
    border: 1px solid var(--hm-line);
    border-radius: 18px;
    box-shadow: 0 10px 26px rgba(17, 12, 45, 0.06);
}
.facultyMemberSection .singleProfessor:hover {
    transform: translateY(-4px);
    box-shadow: var(--hm-card-hover);
}

/* ---------- Research & Achievements / Demography ---------- */
.research { background: var(--hm-tint); border-top: 1px solid var(--hm-line); padding-top: 96px !important; }
.research .title { font-size: 36px; }
.research .nav-pills {
    display: flex;
    gap: 4px;
    padding: 5px;
    background: #fff;
    border: 1px solid var(--hm-line);
    border-radius: 999px;
    box-shadow: 0 6px 16px rgba(17, 12, 45, 0.05);
}
.research .nav-pills { margin-left: auto !important; margin-right: auto !important; width: max-content; }
.research .nav-pills .nav-link { border-radius: 999px; padding: 8px 22px; font-weight: 600; color: var(--hm-text); }
.research .nav-pills .nav-link.active { background: var(--hm-red); color: #fff; }
.research .research-project {
    background: #fff;
    border: 1px solid var(--hm-line);
    border-radius: 18px;
    box-shadow: var(--hm-card);
}
.studentDemography { padding: 96px 0 0 !important; }
.studentDemography .title { font-size: 36px; }
.studentDemography .batchText { color: var(--hm-red); font-weight: 600; letter-spacing: .04em; }
.studentDemography img { border-radius: 20px; }

/* demography: half-ring chart built in home.php from $demo_groups (same look as the old artwork) */
.demo { max-width: 760px; margin: 32px auto 0; overflow: hidden; }
.demo svg { display: block; width: 100%; height: auto; font-family: inherit; }
.demoRim { fill: #fafafa; filter: drop-shadow(0 0 18px rgba(0, 0, 0, .06)); }
.demoHole { fill: #f9f9f9; }
.demoSeg path { transition: filter .2s ease; }
.demoSeg:hover path { filter: brightness(1.08); }
.demoSeg text { fill: #fff; text-anchor: middle; }
.demoLbl { font-size: 10.5px; font-weight: 500; }
.demoNum { font-size: 22px; font-weight: 800; }
.demoPct { font-size: 10px; font-weight: 700; }
.demoTotal { font-size: 40px; font-weight: 800; fill: #111; text-anchor: middle; }
.demoTotalLbl { font-size: 13px; fill: #222; text-anchor: middle; letter-spacing: .02em; }
.demoPill { fill: #f1f1f1; }
.demoPillSep { stroke: #c9c9c9; stroke-width: 1; }
.demoGen { font-size: 15px; fill: #222; text-anchor: middle; }
.demoSym { fill: none; stroke: #222; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- small screens ---------- */
@media (max-width: 767px) {
    .about2, .missonVission, .aboutProgram, .whyApply, .whyUs, .whatExpect,
    .learningPedology, .admissionSection, .facultyMemberSection { padding: 64px 0; }
    .studentDemography { padding: 64px 0 0 !important; }
    /* one type scale on phones: eyebrow 12 · section title 26 · card title 18 · person name 20 */
    .pbr-eyebrow, .bp-eyebrow, .mpEyebrow, .about2 h2, .missonVission h5 {
        font-size: 12px !important;
        font-weight: 700 !important;
        letter-spacing: .16em !important;
    }
    .pbr-title, .bp-title, .about2 h2 span, .expertTalkSeries .bp-head h2, .directorMessage .row h2,
    .chairPersonMsg .msgWrapper h2, .aboutProgram h2, .whyApply h2, .whyUs .title, .whatExpect .title,
    .learningPedology .title, .admissionSection h2, .facultyMemberSection .title, .research .title,
    .studentDemography .title {
        font-size: 26px !important;
        font-weight: 600 !important;
        line-height: 1.25 !important;
        letter-spacing: -0.02em !important;
    }
    .whyApply .card h5, .weCard h5, .whyUs h6, .about2 .EventList .title { font-size: 18px !important; font-weight: 600 !important; }
    .chairPersonMsg .msgWrapper h5, .directorMessage h6, .facultyMemberSection .singleProfessor h5 { font-size: 20px !important; }
    .studentDemography .batchText { font-size: 18px; }
    /* body copy: 15px everywhere on phones */
    .pbr-lede, .bp-sub, .admissionSection ul li, .weCard p, .whyApply .card p, .whyUs p,
    .directorMessage .row p:not(.fw-semibold), .learningPedology p, .whatExpect p, .research p {
        font-size: 15px !important;
        line-height: 1.7 !important;
    }
    .directorMessage .row, .chairPersonMsg .msgWrapper { padding: 28px 25px; }
    /* chairperson: photo stacks on top of the text panel – round the outer corners only so they join */
    .chairPersonMsg .rts-video-section {
        height: 340px !important;
        overflow: hidden;
        border-radius: 24px 24px 0 0;
    }
    .chairPersonMsg .rts-video-section img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        object-position: center top;
        border-radius: 0 !important;
    }
    .chairPersonMsg .msgWrapper { border-radius: 0 0 24px 24px; }
    /* News & Events: space below the About text, no extra gap above its heading */
    .about2 .EventList { margin-top: 36px; padding: 20px 18px 18px; }
    .about2 .EventList .title { margin-top: 0 !important; }
    /* same comfortable side margin in every section on phones */
    .about2 > .container, .missonVission > .container, .directorMessage > .container, .chairPersonMsg > .container,
    .aboutProgram > .container, .whyApply > .container, .whyUs > .container, .whatExpect > .container,
    .learningPedology > .container, .admissionSection > .container, .facultyMemberSection > .container,
    .research > .container, .studentDemography > .container, .expertTalkSeries > .container,
    .pbr-section > .container, .bp-section > .container {
        padding-left: 20px;
        padding-right: 20px;
    }
    .missonVission p { max-width: 100%; font-size: 17px; }
    .missonVission .row > [class*="col-"] { padding-top: 12px; padding-bottom: 12px; }
    /* stacked columns: no side padding, so text lines up with the 20px edge used by every section */
    .about2 > .container > .row > [class*="col-"], .missonVission > .container > .row > [class*="col-"],
    .aboutProgram > .container > .row > [class*="col-"], .admissionSection > .container > .row > [class*="col-"] {
        padding-left: 0 !important;
        padding-right: 0 !important;
    }
    .missonVission .row > [class*="col-"] + [class*="col-"] { margin-top: 20px; }
}

/* =====================================================================
   Events at the Centre – under the hero (data: Views/Web/data/home_events.php)
   ===================================================================== */
.hev-section { padding: 56px 0 52px; background: #fff; }
/* continuous strip – same behaviour as the Batch Profile and Visitors strips */
.hev-marquee {
    overflow: hidden;
    padding: 6px 0 16px;
    -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 6%, #000 94%, transparent 100%);
    mask-image: linear-gradient(90deg, transparent 0, #000 6%, #000 94%, transparent 100%);
}
.hev-track { display: flex; width: max-content; animation: hev-marquee 55s linear infinite; will-change: transform; }
.hev-marquee:hover .hev-track, .hev-marquee:focus-within .hev-track { animation-play-state: paused; }
.hev-list { display: flex; gap: 22px; margin: 0; padding: 0 22px 0 0; list-style: none; }
.hev-list > li { display: flex; }
@keyframes hev-marquee { from { transform: translateX(0); } to { transform: translateX(-50%); } }

.hev-card {
    display: flex; flex-direction: column; width: 420px; overflow: hidden;
    border: 1px solid #ECE4E6; border-radius: 16px; background: #fff;
    color: inherit; text-decoration: none;
    transition: transform .3s ease, box-shadow .3s ease, border-color .3s ease;
}
.hev-card:hover { transform: translateY(-4px); border-color: #e2c9cf; box-shadow: 0 14px 30px rgba(17, 12, 45, .09); color: inherit; }
.hev-card:focus-visible { outline: 3px solid rgba(137, 12, 37, .35); outline-offset: 3px; }
/* event banners are 1920 × 612 – the frame keeps that shape so the whole banner shows */
.hev-media { display: block; aspect-ratio: 1920 / 612; overflow: hidden; border-bottom: 1px solid #ECE4E6; background: #f3eef0; }
.hev-media img { display: block; width: 100%; height: 100%; object-fit: contain; }
.hev-body { display: flex; flex: 1; flex-direction: column; padding: 16px 18px 18px; }
.hev-type { margin-bottom: 6px; color: var(--hm-red); font-size: 11px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; }
.hev-title {
    display: -webkit-box; overflow: hidden; color: var(--hm-ink); font-size: 16px; font-weight: 600; line-height: 1.45;
    -webkit-line-clamp: 2; -webkit-box-orient: vertical; min-height: 2.9em;
}
.hev-when { display: inline-flex; align-items: center; gap: 7px; margin-top: auto; padding-top: 12px; color: var(--hm-text); font-size: 13px; }
.hev-when .ico { width: 13px; height: 13px; color: var(--hm-red); }
@media (max-width: 767px) {
    .hev-section { padding: 44px 0 40px; }
    .hev-card { width: 290px; }
    .hev-list { gap: 16px; padding-right: 16px; }
    .hev-track { animation-duration: 45s; }
}
@media (prefers-reduced-motion: reduce) {
    .hev-track { animation: none; }
    .hev-marquee { overflow-x: auto; }
    .hev-list[aria-hidden="true"], .hev-copy { display: none !important; }
}

/* =====================================================================
   IIT Kharagpur at a glance (data: Views/Web/data/at_a_glance.php)
   ===================================================================== */
.agl-section { padding: 64px 0 48px; background: #f7f2ec; }
.agl-title { margin: 0 0 36px; color: var(--hm-red); font-size: clamp(30px, 3.6vw, 44px); font-weight: 700; letter-spacing: -.02em; }
.agl-grid { display: grid; grid-template-columns: minmax(220px, 1fr) minmax(0, 2fr); align-items: center; gap: 40px; }
.agl-rank { text-align: center; }
.agl-rankNum { margin: 0; color: #0b0f19; font-size: clamp(96px, 11vw, 150px); font-weight: 800; line-height: .9; letter-spacing: -.04em; }
.agl-rankNum sup { top: -.15em; margin-left: 4px; font-size: .4em; letter-spacing: 0; vertical-align: baseline; position: relative; }
.agl-rankLabel { margin: 10px 0 18px; color: #0b0f19; font-size: clamp(30px, 3.4vw, 44px); font-weight: 600; letter-spacing: .02em; text-transform: uppercase; }
.agl-rankNote { max-width: 300px; margin: 0 auto; color: #2b2b33; font-size: 17px; line-height: 1.5; }
.agl-stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 34px 48px; margin: 0; padding-left: 40px; border-left: 1px solid #e3d8cc; }
.agl-stats dt { margin-bottom: 6px; color: #1c1c22; font-size: 18px; font-weight: 600; }
.agl-stats dd { margin: 0; color: var(--hm-red); font-size: clamp(36px, 4vw, 52px); font-weight: 700; line-height: 1.05; letter-spacing: .01em; }
.agl-stats dd small { display: block; margin-top: 4px; color: #6b5f57; font-size: 15px; font-weight: 500; letter-spacing: 0; }
.agl-links { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 12px; margin-top: 44px; padding-top: 22px; border-top: 1px solid #e3d8cc; }
.agl-links > span { margin-right: 6px; color: #6b5f57; font-size: 13px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; }
.agl-links a { display: inline-flex; align-items: center; gap: 6px; padding: 7px 14px; border: 1px solid #e3d8cc; border-radius: 999px; background: #fff; color: var(--hm-ink); font-size: 14px; font-weight: 500; text-decoration: none; transition: border-color .2s ease, color .2s ease; }
.agl-links a:hover { border-color: var(--hm-red); color: var(--hm-red); }
.agl-links a .ico { width: 11px; height: 11px; opacity: .6; }
.agl-links a:focus-visible { outline: 3px solid rgba(137, 12, 37, .35); outline-offset: 2px; }
@media (max-width: 767px) {
    .agl-grid { grid-template-columns: 1fr; gap: 32px; }
    .agl-stats { padding-left: 0; padding-top: 28px; border-left: 0; border-top: 1px solid #e3d8cc; gap: 26px 24px; }
}
/* grid items may shrink below their content, so nothing spills past the screen on phones */
.agl-grid > *, .agl-stats > div { min-width: 0; }
/* the site's paragraphs are justified; the rank block is centred */
.agl-rank p { text-align: center !important; }
.agl-rankNote { text-align: center !important; }
.agl-stats dd small { overflow-wrap: anywhere; }

/* =====================================================================
   "View all …", "View CV", "Read more" – text links with a right arrow
   (overrides the outlined buttons from batch_profile.css on the home page only)
   ===================================================================== */
.bp-head .bp-viewall, .bp-viewall-link, .bp-section .bp-cv, .hm-more {
    display: inline-flex; align-items: center; gap: 14px; width: auto; height: auto;
    padding: 0; border: 0; border-radius: 0; background: none;
    color: var(--hm-ink); font-size: 17px; font-weight: 700; line-height: 1.3; text-decoration: none;
    transition: color .2s ease;
}
.bp-head .bp-viewall .ico, .bp-viewall-link .ico, .bp-section .bp-cv .ico, .hm-more .ico {
    width: 14px; height: 14px; flex: none; stroke: currentColor; stroke-width: .8; transition: transform .2s ease;
}
.bp-head .bp-viewall:hover, .bp-viewall-link:hover, .bp-section .bp-cv:hover,
a:hover .hm-more { gap: 14px; background: none; color: var(--hm-red); }
.bp-head .bp-viewall:hover .ico, .bp-viewall-link:hover .ico, .bp-section .bp-cv:hover .ico,
a:hover .hm-more .ico { transform: translateX(4px); }
.bp-head .bp-viewall:focus-visible, .bp-viewall-link:focus-visible, .bp-section .bp-cv:focus-visible {
    outline: 3px solid rgba(137, 12, 37, .3); outline-offset: 3px; border-radius: 4px;
}
.bp-head .bp-viewall { margin-bottom: 4px; }
.bp-section .bp-cv { align-self: flex-start; margin-top: auto; gap: 10px; font-size: 14px; cursor: pointer; }
.bp-section .bp-cv .ico, .hm-more .ico { width: 12px; height: 12px; }
.hm-more { display: flex; width: fit-content; gap: 10px; font-size: 14px; }
a:hover .hm-more, .bp-section .bp-cv:hover { gap: 10px; }

/* ---------- About IIT Kharagpur fused into "at a glance" ----------
   same two columns and divider as the figures below, so both rows line up */
.agl-section { padding: 80px 0 56px; }
.agl-about { display: grid; grid-template-columns: minmax(220px, 1fr) minmax(0, 2fr); gap: 40px; margin-bottom: 64px; }
.agl-about > * { min-width: 0; }
.agl-intro .agl-title { margin: 0 0 14px; color: var(--hm-ink); font-size: clamp(28px, 2.8vw, 38px); line-height: 1.18; }
.agl-tagline { margin: 0; padding-top: 14px; border-top: 3px solid var(--hm-red); width: fit-content; color: var(--hm-text); font-size: 18px; font-style: italic; font-weight: 500; text-align: left !important; }
.agl-motto { padding-left: 40px; border-left: 1px solid #e3d8cc; }
.agl-desc { color: var(--hm-text); font-size: 16px; line-height: 1.8; }
.agl-desc h1, .agl-desc h2, .agl-desc h3, .agl-desc h4, .agl-desc h5, .agl-desc h6 {
    margin: 0 0 10px; color: var(--hm-red) !important; font-size: 13px !important; font-weight: 700; letter-spacing: .14em; text-transform: uppercase;
}
.agl-desc p { margin: 0 0 12px; color: var(--hm-text); text-align: left !important; line-height: 1.8; }
.agl-desc p span { text-align: left !important; }
.agl-more { margin-top: 10px; }
.agl-sub {
    display: flex; align-items: center; gap: 18px; margin: 0 0 34px;
    color: var(--hm-red); font-size: clamp(22px, 2.4vw, 30px); font-weight: 700; letter-spacing: -.02em;
}
.agl-sub::after { content: ""; flex: 1; height: 1px; background: #e3d8cc; }
@media (max-width: 767px) {
    .agl-section { padding: 56px 0 44px; }
    .agl-about { grid-template-columns: 1fr; gap: 24px; margin-bottom: 48px; }
    .agl-motto { padding: 24px 0 0; border-left: 0; border-top: 1px solid #e3d8cc; }
    .agl-intro .agl-title { font-size: 26px; }
    .agl-tagline { font-size: 16px; }
    .agl-desc, .agl-desc p { font-size: 15px; }
}

/* ---------- "at a glance": compact – rank + four figures in one row ---------- */
.agl-section .agl-sub { margin-bottom: 22px; font-size: clamp(20px, 2vw, 24px); }
.agl-section .agl-grid {
    grid-template-columns: minmax(200px, 1fr) minmax(0, 4fr); gap: 0; align-items: stretch;
    padding: 24px 0; border-radius: 16px; background: #fff; border: 1px solid #ebe0d4;
}
.agl-section .agl-rank { display: grid; grid-template-columns: auto 1fr; align-items: center; gap: 2px 14px; padding: 0 28px; text-align: left; }
.agl-section .agl-rank p { text-align: left !important; }
.agl-section .agl-rankNum { grid-row: span 2; font-size: 64px; line-height: 1; color: var(--hm-red); }
.agl-section .agl-rankLabel { align-self: end; margin: 0; font-size: 13px; font-weight: 700; letter-spacing: .12em; color: var(--hm-ink); }
.agl-section .agl-rankNote { align-self: start; max-width: none; margin: 0; font-size: 13px; line-height: 1.4; color: var(--hm-text); }
.agl-section .agl-stats { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; padding: 0; border: 0; }
.agl-section .agl-stats > div { display: flex; flex-direction: column-reverse; justify-content: center; padding: 0 24px; border-left: 1px solid #ebe0d4; }
.agl-section .agl-stats dt { margin: 4px 0 0; color: var(--hm-text); font-size: 13px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; }
.agl-section .agl-stats dd { font-size: clamp(26px, 2.4vw, 34px); line-height: 1.1; color: var(--hm-ink); }
.agl-section .agl-stats dd small { display: inline; margin: 0 0 0 4px; font-size: 13px; }
.agl-section .agl-links { margin-top: 26px; padding-top: 0; border-top: 0; }
@media (max-width: 991px) {
    .agl-section .agl-grid { grid-template-columns: 1fr; padding: 0; }
    .agl-section .agl-rank { padding: 20px 22px; border-bottom: 1px solid #ebe0d4; }
    .agl-section .agl-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .agl-section .agl-stats > div { padding: 16px 22px; border-left: 0; }
    .agl-section .agl-stats > div:nth-child(even) { border-left: 1px solid #ebe0d4; }
    .agl-section .agl-stats > div:nth-child(n+3) { border-top: 1px solid #ebe0d4; }
}
@media (min-width: 768px) and (max-width: 991px) {
    .agl-section .agl-stats { grid-template-columns: repeat(4, minmax(0, 1fr)); }
    .agl-section .agl-stats > div { border-left: 1px solid #ebe0d4; border-top: 0 !important; }
    .agl-section .agl-stats > div:first-child { border-left: 0; }
}
@media (max-width: 767px) {
    .agl-section .agl-rankNum { font-size: 52px; }
    .agl-section .agl-stats dd { font-size: 26px; }
}

/* =====================================================================
   Placement Brochure – maroon banner: text + key facts left, brochure cover right
   (overrides the light card in home.css)
   ===================================================================== */
.pbr-section { padding: 64px 0; }
.pbr-section .pbr-card {
    position: relative; grid-template-columns: minmax(0, 1fr) 380px; border: 0; border-radius: 22px;
    background:
        radial-gradient(rgba(255, 255, 255, .07) 1px, transparent 1px) 0 0 / 18px 18px,
        var(--hm-grad);
    box-shadow: 0 24px 50px rgba(106, 10, 29, .22);
}
.pbr-section .pbr-content { padding: 44px 0 44px 52px; }
.pbr-section .pbr-eyebrow { color: #f3c9d1; }
.pbr-section .pbr-title { margin-bottom: 10px; color: #fff; font-size: 28px; }
.pbr-section .pbr-title span { color: #ffd9df; }
.pbr-section .pbr-lede { max-width: 560px; margin-bottom: 26px; color: rgba(255, 255, 255, .82); font-size: 16px; }

.pbr-facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0; max-width: 640px; margin: 0 0 30px; padding: 18px 0; list-style: none; border-top: 1px solid rgba(255, 255, 255, .18); border-bottom: 1px solid rgba(255, 255, 255, .18); }
.pbr-facts li { min-width: 0; padding: 0 20px; border-left: 1px solid rgba(255, 255, 255, .18); }
.pbr-facts li:first-child { padding-left: 0; border-left: 0; }
.pbr-facts b { display: block; color: #fff; font-size: 26px; font-weight: 700; line-height: 1.1; letter-spacing: -.01em; }
.pbr-facts span { display: block; margin-top: 4px; color: rgba(255, 255, 255, .72); font-size: 13px; line-height: 1.4; }

.pbr-section .pbr-btn { border-color: #fff; background: #fff; color: var(--hm-red); }
.pbr-section .pbr-btn:hover, .pbr-section .pbr-btn:focus-visible { border-color: #fff; background: #ffe9ed; color: var(--hm-wine); }
.pbr-section .pbr-link { color: #fff; }
.pbr-section .pbr-link .ico { color: #ffd9df; }
.pbr-section .pbr-link:hover { color: #fff; border-bottom-color: #fff; }

.pbr-section .pbr-visual { min-height: 0; padding: 40px 20px; background: none; }
.pbr-section .pbr-watermark { bottom: -30px; color: #fff; opacity: .08; }
.pbr-section .pbr-cover { width: 170px; }
.pbr-section .pbr-cover img { box-shadow: 0 22px 40px rgba(0, 0, 0, .35); }
.pbr-section .pbr-sheet { background: rgba(255, 255, 255, .9); }
.pbr-section .pbr-sheet--2 { background: #fdf3f5; }
.pbr-section .pbr-cover-eye { background: #fff; color: var(--hm-red); }

@media (max-width: 991px) {
    .pbr-section .pbr-card { grid-template-columns: minmax(0, 1fr) 260px; }
    .pbr-section .pbr-content { padding: 36px 0 36px 36px; }
    .pbr-section .pbr-cover { width: 140px; }
}
@media (max-width: 767px) {
    .pbr-section { padding: 40px 0; }
    .pbr-section .pbr-card { grid-template-columns: 1fr; }
    .pbr-section .pbr-visual { order: -1; padding: 32px 20px 8px; }
    .pbr-section .pbr-cover { width: 120px; }
    .pbr-section .pbr-content { padding: 22px 22px 28px; }
    .pbr-section .pbr-title { font-size: 22px !important; }
    .pbr-section .pbr-lede { font-size: 15px !important; color: rgba(255, 255, 255, .82) !important; }
    .pbr-facts li { padding: 0 12px; }
    .pbr-facts b { font-size: 21px; }
    .pbr-facts span { font-size: 12px; }
}

/* ---------- phones: section heads + "View all" links ---------- */
@media (max-width: 767px) {
    /* the link under each strip replaces the one in the head (batch_profile.css hides it, the link style above re-showed it) */
    .bp-head .bp-viewall { display: none; }
    .bp-head { margin-bottom: 18px; }
    .bp-viewall-bottom { margin-top: 4px; }
    .bp-viewall-link, .agl-more { font-size: 15px; gap: 10px; }
    .bp-viewall-link .ico, .agl-more .ico { width: 12px; height: 12px; }
    .hev-section .bp-title { font-size: 26px !important; }
    .hev-section { padding: 40px 0 32px; }
    .hev-marquee { padding-bottom: 12px; }
    .hev-card { width: 260px; }
    .hev-body { padding: 14px 16px 16px; }
    .hev-title { font-size: 15px; }
    .hev-type { font-size: 11px; }
}
@media (max-width: 767px) {
    /* About: keep the motto short on phones – the full text is one tap away (Read More) */
    .agl-desc p { display: -webkit-box; overflow: hidden; -webkit-line-clamp: 5; -webkit-box-orient: vertical; }
    .agl-about { margin-bottom: 40px; }
    .agl-intro .agl-title { font-size: 24px !important; }
    /* at a glance: units on their own line, so nothing wraps mid-phrase */
    .agl-section .agl-stats dd small { display: block; margin: 2px 0 0; font-size: 12px; }
    .agl-section .agl-stats > div { justify-content: flex-end; padding: 16px 18px; } /* column-reverse: flex-end = top */
    .agl-section .agl-stats dd { font-size: 24px; }
    .agl-section .agl-stats dt { font-size: 12px; }
    .agl-section .agl-rank { padding: 18px; }
    /* useful links: one swipeable row instead of three wrapped rows */
    .agl-section .agl-links {
        flex-wrap: nowrap; overflow-x: auto; margin: 22px -20px 0; padding: 0 20px 4px;
        scrollbar-width: none; -webkit-overflow-scrolling: touch;
    }
    .agl-section .agl-links::-webkit-scrollbar { display: none; }
    .agl-section .agl-links > *, .agl-section .agl-links a { flex: none; white-space: nowrap; }
    .agl-section .agl-links a { padding: 6px 12px; font-size: 13px; }
}
