/* ============================================================
   Bright Future Academy - main stylesheet
   ============================================================ */
:root {
    --navy: #1E3A8A;
    --navy-2: #172B66;
    --gold: #F6AD52;
    --blue: #3B6FD4;
    --cream: #EAF0FA;
    --gray-bg: #F6F8FC;
    --text: #445066;
}
* { box-sizing: border-box; }
body {
    font-family: 'Poppins', 'Segoe UI', Arial, sans-serif;
    color: var(--text);
    background: #fff;
    margin: 0;
    line-height: 1.7;
}
a { color: var(--blue); }
a:hover { color: var(--navy); }
img { max-width: 100%; }
h1, h2, h3, h4, h5 { color: var(--navy); font-weight: 700; }
.text-white { color: #fff !important; }
.text-center { text-align: center; }
.text-gold { color: var(--gold) !important; }

.container { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 15px; }
.row { display: flex; flex-wrap: wrap; margin: 0 -15px; }
[class*="col-"] { padding: 0 15px; flex: 0 0 100%; max-width: 100%; }
.col-md-3 { flex: 0 0 25%; max-width: 25%; }
.col-md-4 { flex: 0 0 33.3333%; max-width: 33.3333%; }
.col-md-6 { flex: 0 0 50%; max-width: 50%; }
.col-md-8 { flex: 0 0 66.6667%; max-width: 66.6667%; }
.col-md-9 { flex: 0 0 75%; max-width: 75%; }
.col-md-12 { flex: 0 0 100%; max-width: 100%; }
.col-md-offset-2 { margin-left: 16.6667%; }

.spacet60 { padding-top: 60px; }
.spaceb60 { padding-bottom: 60px; }
.spacet40 { padding-top: 40px; }
.spaceb40 { padding-bottom: 40px; }
.pb30 { padding-bottom: 30px; }
.pb40 { padding-bottom: 40px; }
.pt10 { padding-top: 10px; }
.pb10 { padding-bottom: 10px; }
.mt0 { margin-top: 0; }
.fullwidth { width: 100%; }

/* ---------- News marquee ---------- */
.newsarea {
    background: #000;
    border-top: 1px solid #2b2b2b;
    border-bottom: 1px solid #2b2b2b;
}
.newscontent { display: flex; align-items: stretch; min-height: 40px; }
.newsarea .container { max-width: 100%; padding-left: 0; }
.newstab {
    position: relative;
    background: #3A3A3A;
    color: #fff;
    font-weight: 700; font-size: 12px; letter-spacing: 1px; text-transform: uppercase;
    padding: 10px 20px;
    margin-right: 16px; white-space: nowrap; display: flex; align-items: center;
}
.newstab::before {
    content: ''; width: 8px; height: 8px; border-radius: 50%;
    background: var(--gold); margin-right: 8px;
    animation: livePulse 1.2s ease-in-out infinite;
}
@keyframes livePulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(246, 173, 82, .55); }
    50% { box-shadow: 0 0 0 6px rgba(246, 173, 82, 0); }
}
.marquee-wrap { overflow: hidden; flex: 1; display: flex; align-items: center; position: relative; }
.marquee-wrap::before, .marquee-wrap::after {
    content: ''; position: absolute; top: 0; bottom: 0; width: 45px; z-index: 2; pointer-events: none;
}
.marquee-wrap::before { left: 0; background: linear-gradient(to right, #000, rgba(0, 0, 0, 0)); }
.marquee-wrap::after { right: 0; background: linear-gradient(to left, #000, rgba(0, 0, 0, 0)); }
.marquee-wrap ul { list-style: none; margin: 0; padding: 0; white-space: nowrap; display: inline-block; will-change: transform; }
.marquee-wrap li { display: inline-block; }
.marquee-wrap li a { color: #fff; font-size: 13px; text-decoration: none; margin-right: 44px; }
.marquee-wrap li a:hover { color: var(--gold); }
.marquee-wrap .datenews { color: var(--gold); font-weight: 600; }

/* ---------- Top bar ---------- */
.toparea { background: var(--gold); color: #6B3A00; font-size: 13px; }
.toparea a { color: #6B3A00; text-decoration: none; }
.toparea ul { list-style: none; margin: 0; padding: 8px 0; display: flex; align-items: center; }
.toplist { justify-content: flex-start; }
.topicon { justify-content: flex-end; }
.topicon li { margin-left: 14px; }
.topicon li:first-child { color: var(--navy); font-weight: 600; }
.topicon a:hover { color: #fff; }

/* ---------- Header ---------- */
header { background: #fff; }
header .container { display: flex; align-items: center; justify-content: space-between; padding: 22px 15px; flex-wrap: wrap; }
.logo { display: flex; align-items: center; gap: 12px; text-decoration: none; min-width: 0; }
.logo img { height: 56px; width: auto; max-width: 100%; flex-shrink: 0; }
.logo-text { display: flex; flex-direction: column; line-height: 1.2; min-width: 0; }
.logo-name { color: var(--navy); font-weight: 700; font-size: 26px; overflow-wrap: anywhere; }
.logo-tagline { color: #8A5A26; font-size: 12px; letter-spacing: 1.5px; text-transform: uppercase; }
.header-extras { list-style: none; margin: 0; padding: 0; display: flex; align-items: center; gap: 24px; }
.header-extras li { display: flex; align-items: center; }
.he-text { font-size: 12px; color: #8A5A26; text-transform: uppercase; letter-spacing: .5px; }
.he-text span { display: block; color: var(--navy); font-size: 16px; font-weight: 700; text-transform: none; }
.i-plain { font-size: 24px; color: var(--navy); margin-right: 10px; }
.complainbtn {
    background: var(--gold); color: #4A2600 !important; padding: 10px 26px;
    border-radius: 30px; text-decoration: none !important; font-weight: 600; cursor: pointer; border: 0; font-size: 14px;
}
.complainbtn:hover { background: var(--navy); color: #fff !important; }

/* ---------- Navbar ---------- */
.navborder { border-top: 1px solid #22345f; border-bottom: 1px solid #22345f; background: #1B2A4A; position: sticky; top: 0; z-index: 1000; }
.navbar { display: flex; align-items: center; justify-content: space-between; padding: 5px 0; }
.navbar-nav { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; }
.navbar-nav > li { position: relative; }
.navbar-nav > li > a {
    display: block; padding: 8px 18px; margin: 6px 4px; color: #fff; text-decoration: none;
    font-weight: 600; font-size: 14px; border: 1px solid rgba(255,255,255,.25);
    border-radius: 8px; transition: all .2s ease;
}
.navbar-nav > li.active > a,
.navbar-nav > li > a:hover {
    background: var(--gold); color: var(--navy); border-color: var(--gold);
}
.dropdown-menu {
    display: none; position: absolute; top: 100%; left: 0; background: #fff;
    min-width: 230px; box-shadow: 0 12px 30px rgba(30,58,138,.14); border-radius: 0 0 8px 8px;
    list-style: none; margin: 0; padding: 8px 0;
}
.navbar-nav > li:hover .dropdown-menu { display: block; }
.dropdown-menu li a { display: block; padding: 8px 18px; color: var(--text); text-decoration: none; font-size: 13.5px; }
.dropdown-menu li a:hover { background: var(--gray-bg); color: var(--navy); }
.caret { border-left: 4px solid transparent; border-right: 4px solid transparent; border-top: 4px solid currentColor; display: inline-block; margin-left: 5px; }
.navbar-toggle {
    display: none; background: #22345f; border: 0; border-radius: 6px; padding: 8px 10px; cursor: pointer;
}
.navbar-toggle .icon-bar { display: block; width: 22px; height: 2px; background: #fff; margin: 4px 0; }

/* ---------- Carousel ---------- */
.carousel { position: relative; overflow: hidden; margin-top: 22px; }
.carousel-inner { display: flex; transition: transform .6s ease; will-change: transform; background: #0B1A3A; }
.carousel-inner .item { flex: 0 0 100%; max-width: 100%; }
.carousel-inner img { width: 100%; height: auto; display: block; }
.carousel-control { position: absolute; top: 50%; transform: translateY(-50%); background: rgba(30,58,138,.55); color: #fff; width: 46px; height: 46px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 22px; text-decoration: none; z-index: 5; }
.carousel-control.left { left: 18px; }
.carousel-control.right { right: 18px; }
.carousel-control:hover { background: var(--gold); color: var(--navy); }
.carousel-dots { position: absolute; bottom: 16px; left: 0; right: 0; text-align: center; z-index: 5; }
.carousel-dots span { display: inline-block; width: 12px; height: 12px; border-radius: 50%; background: rgba(255,255,255,.5); margin: 0 5px; cursor: pointer; }
.carousel-dots span.active { background: var(--gold); }

/* ---------- Android App Download ---------- */
.app-download { background: linear-gradient(135deg, var(--navy-2), var(--navy)); margin-top: 10px; }
.app-download-inner { display: flex; align-items: center; gap: 22px; padding: 26px 0; flex-wrap: wrap; }
.app-icon { width: 64px; height: 64px; border-radius: 16px; background: rgba(255,255,255,.12); color: #fff; display: flex; align-items: center; justify-content: center; font-size: 36px; flex: none; }
.app-text { flex: 1 1 260px; min-width: 0; }
.app-text h3 { color: #fff; margin: 0 0 4px; font-size: 22px; }
.app-text p { color: #CBD8F2; margin: 0; font-size: 14px; }
.btn-app { display: inline-flex; align-items: center; gap: 8px; background: var(--gold); color: #4A2600 !important; padding: 13px 28px; border-radius: 30px; font-weight: 700; text-decoration: none !important; flex: none; transition: all .2s ease; }
.btn-app:hover { background: #fff; color: var(--navy) !important; }

/* ---------- Services ---------- */
.services { padding: 40px 0 10px; }
.service-box { margin-bottom: 30px; }
.service-box-content {
    background: #fff; border: 1px solid #eef1f7; border-radius: 12px; padding: 30px 26px; text-align: center;
    box-shadow: 0 6px 22px rgba(30,58,138,.06); transition: all .25s ease; height: 100%;
}
.service-box-content:hover { transform: translateY(-6px); box-shadow: 0 14px 34px rgba(30,58,138,.14); }
.service-box-content h3 a { color: var(--navy); text-decoration: none; font-size: 18px; }
.service-box-icon img { height: 64px; margin-top: 10px; }

/* ---------- Section headings ---------- */
.head-title { font-size: 30px; margin: 0 0 10px; }
.divider { width: 70px; height: 4px; background: var(--gold); border-radius: 4px; margin: 18px auto; }
.center-block { margin-left: auto; margin-right: auto; display: block; }
.img-responsive { max-width: 100%; height: auto; }
.img-rounded { border-radius: 12px; }

/* ---------- Accordion ---------- */
.panel { border: 1px solid #eef1f7; border-radius: 10px; margin-bottom: 12px; overflow: hidden; }
.panel-heading { background: var(--gray-bg); padding: 0; }
.panel-title a { display: block; padding: 14px 18px; color: var(--navy); text-decoration: none; font-size: 15px; }
.panel-collapse { display: none; }
.panel-collapse.in { display: block; }
.panel-body { padding: 16px 18px; font-size: 14px; }

/* ---------- Courses ---------- */
.bg-gray { background: var(--gray-bg); }
.courses-box { background: #fff; border-radius: 12px; overflow: hidden; box-shadow: 0 6px 22px rgba(30,58,138,.07); margin: 10px; transition: all .25s ease; }
.courses-box:hover { transform: translateY(-6px); box-shadow: 0 14px 34px rgba(30,58,138,.14); }
.courses-box-img img { width: 100%; height: 190px; object-fit: cover; }
.course-inner { padding: 20px; }
.course-subject { color: var(--gold); font-weight: 700; text-decoration: none; font-size: 12px; text-transform: uppercase; letter-spacing: 1px; }
.course-inner h4 { margin: 6px 0 8px; font-size: 18px; }
.course-inner p { font-size: 13.5px; }
.btn-read {
    display: inline-block; background: var(--navy); color: #fff !important; padding: 9px 22px;
    border-radius: 30px; text-decoration: none !important; font-size: 13px; font-weight: 600; margin-top: 8px;
}
.btn-read:hover { background: var(--gold); color: var(--navy) !important; }
.carousel-track { overflow-x: auto; overflow-y: hidden; -webkit-overflow-scrolling: touch; scrollbar-width: thin; }
.carousel-track::-webkit-scrollbar { height: 6px; }
.carousel-track::-webkit-scrollbar-thumb { background: #c6cfdd; border-radius: 3px; }
.carousel-track-inner { display: flex; transition: transform .4s ease; min-width: max-content; }
.carousel-track-inner > * { flex: 0 0 25%; scroll-snap-align: start; }

/* ---------- Counters ---------- */
.countdown_bg { background: linear-gradient(135deg, var(--navy-2), var(--navy)); color: #fff; padding: 60px 0; }
.counter-title { color: #fff; }
.counter-text p { color: #CBD8F2; }
.counter-main { text-align: center; padding: 22px 10px; }
.counter-main img { height: 52px; margin-bottom: 8px; }
.counter-main h3 { color: var(--gold); font-size: 40px; margin: 4px 0; }
.counter-main span { color: #fff; text-transform: uppercase; letter-spacing: 1px; font-size: 13px; }

/* ---------- Staff ---------- */
.teamstaff { margin: 10px 0; }
.staffteam { background: #fff; border: 1px solid #eef1f7; border-radius: 12px; overflow: hidden; text-align: center; margin: 10px; box-shadow: 0 6px 22px rgba(30,58,138,.06); }
.staffteamimg { position: relative; overflow: hidden; }
.staffteamimg img { width: 100%; height: 300px; object-fit: cover; }
.social-links { position: absolute; bottom: -60px; left: 0; right: 0; list-style: none; margin: 0; padding: 10px 0; background: rgba(30,58,138,.85); display: flex; justify-content: center; gap: 8px; transition: bottom .3s ease; }
.staffteam:hover .social-links { bottom: 0; }
.social-links li { color: #fff; font-size: 12px; }
.staff-content { padding: 18px; }
.staff-content h3 { margin: 0 0 4px; font-size: 18px; }
.staff-content .post { color: var(--gold); font-weight: 600; font-size: 13px; }

/* ---------- Testimonials ---------- */
.testimonial_bg { background: linear-gradient(135deg, #172B66, var(--navy)); }
.testimonial { background: #fff; border-radius: 14px; padding: 26px; margin: 12px; }
.testimonialimg img { width: 64px; height: 64px; border-radius: 50%; object-fit: cover; }
.testi_description h4 { margin: 10px 0 2px; }
.testi_description h5 { color: var(--gold); margin: 0 0 8px; font-size: 14px; }
.testi_description p { font-size: 13.5px; margin: 0; }

/* ---------- Footer ---------- */
footer { background: #101C33; color: #C9D4EA; }
footer .container.spacet40.spaceb40 { padding-top: 50px; padding-bottom: 30px; }
.fo-title { color: #fff; margin: 0 0 18px; font-size: 18px; }
.f1-list { list-style: none; margin: 0; padding: 0; }
.f1-list li { margin-bottom: 8px; }
.f1-list a { color: #C9D4EA; text-decoration: none; font-size: 14px; }
.f1-list a:hover { color: var(--gold); }
.company-social { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 12px; }
.company-social a { display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 40px; border-radius: 50%; background: rgba(255,255,255,.1); color: #fff; text-decoration: none; font-size: 16px; }
.company-social a:hover { background: var(--gold); color: var(--navy); }
.complain a { color: var(--gold); text-decoration: none; font-weight: 600; }
.contacts-item { display: flex; align-items: flex-start; margin-bottom: 22px; }
.cleft { font-size: 22px; color: var(--gold); margin-right: 12px; min-width: 30px; }
.content-title { color: #fff; text-decoration: none; font-weight: 600; }
.contacts-item p { margin: 0; font-size: 13.5px; }
.sub-title { color: #C9D4EA; }
.infoborderb { border-top: 1px solid rgba(255,255,255,.12); margin: 10px 0 26px; }
.copy-right { background: #0C1630; padding: 18px 0; text-align: center; color: #8FA2C4; font-size: 13px; }

/* ---------- Floating buttons ---------- */
.bootom-whatsapp {
    position: fixed; right: 22px; bottom: 22px; z-index: 900;
    background: #25d366; border-radius: 50%; padding: 12px; box-shadow: 0 6px 20px rgba(0,0,0,.25); line-height: 0;
}
.bootom-whatsapp svg { width: 30px; height: 30px; }
.scrollToTop {
    position: fixed; right: 22px; bottom: 88px; z-index: 900; background: var(--navy); color: #fff;
    width: 42px; height: 42px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
    text-decoration: none; box-shadow: 0 6px 20px rgba(0,0,0,.2);
}
.scrollToTop:hover { background: var(--gold); color: var(--navy); }

/* ---------- Buttons / forms (front) ---------- */
.btn { display: inline-block; padding: 10px 26px; border-radius: 30px; font-weight: 600; border: 0; cursor: pointer; font-size: 14px; text-decoration: none; }
.btn-gold { background: var(--gold); color: var(--navy); }
.btn-navy { background: var(--navy); color: #fff; }
.btn-outline { border: 2px solid var(--navy); color: var(--navy); background: transparent; }
.btn-outline:hover { background: var(--navy); color: #fff; }
.form-control { width: 100%; padding: 12px 14px; border: 1px solid #dde3ef; border-radius: 8px; font-size: 14px; background: #fff; }
.form-group { margin-bottom: 16px; }
label { font-weight: 600; color: var(--navy); font-size: 14px; }
.req { color: #d03e3e; }
.alert { padding: 13px 16px; border-radius: 8px; margin-bottom: 16px; font-size: 14px; }
.alert-success { background: #e4f7ec; color: #1d7a47; }
.alert-danger { background: #fde8e8; color: #b02a37; }
.alert-warning { background: #fff4d6; color: #8a6100; }
.alert-info { background: #e3f0fd; color: #1c5e9e; }

/* ---------- Page header (inner pages) ---------- */
.page-head { background: linear-gradient(135deg, var(--navy-2), var(--navy)); color: #fff; padding: 60px 0; text-align: center; }
.page-head h1 { color: #fff; margin: 0; font-size: 34px; }
.page-head .crumbs { color: #CBD8F2; font-size: 14px; }
.page-head .crumbs a { color: var(--gold); text-decoration: none; }

/* ---------- News list ---------- */
.news-item { background: #fff; border: 1px solid #eef1f7; border-radius: 12px; padding: 22px; margin-bottom: 20px; box-shadow: 0 4px 16px rgba(30,58,138,.05); }
.news-item h3 { margin: 0 0 6px; }
.news-item h3 a { color: var(--navy); text-decoration: none; }
.news-meta { color: var(--gold); font-size: 13px; font-weight: 600; margin-bottom: 8px; }

/* ---------- Gallery ---------- */
.gallery-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 20px; }
.gallery-item { border-radius: 12px; overflow: hidden; box-shadow: 0 6px 22px rgba(30,58,138,.1); position: relative; }
.gallery-item img { width: 100%; height: 220px; object-fit: cover; display: block; }
.gallery-item .cap { position: absolute; bottom: 0; left: 0; right: 0; background: linear-gradient(transparent, rgba(30,58,138,.85)); color: #fff; padding: 30px 14px 12px; font-size: 14px; }

/* ---------- Gallery albums ---------- */
.album-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 20px; }
.album-card {
    display: block; background: #fff; border-radius: 12px; overflow: hidden; text-decoration: none;
    box-shadow: 0 6px 22px rgba(30,58,138,.08); transition: all .25s ease;
}
.album-card:hover { transform: translateY(-6px); box-shadow: 0 14px 34px rgba(30,58,138,.16); }
.album-cover { position: relative; height: 150px; overflow: hidden; }
.album-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.album-cover::after { content: ''; position: absolute; bottom: 0; left: 0; right: 0; height: 45%; background: linear-gradient(transparent, rgba(16,28,51,.65)); }
.album-info { display: flex; align-items: center; gap: 12px; padding: 14px 16px; }
.album-info i { font-size: 36px; color: var(--gold); }
.album-name { display: block; color: var(--navy); font-weight: 700; font-size: 15px; line-height: 1.3; }
.album-count { display: block; color: #8893ab; font-size: 12.5px; }

/* ---------- Login page ---------- */
.auth-wrap { min-height: 100vh; background: linear-gradient(135deg, var(--navy-2), var(--navy)); display: flex; align-items: center; justify-content: center; padding: 30px; }
.auth-card { background: #fff; border-radius: 16px; box-shadow: 0 20px 60px rgba(0,0,0,.25); padding: 40px; width: 100%; max-width: 440px; }
.auth-card .logo { text-align: center; margin-bottom: 14px; }
.auth-card .logo a { display: inline-block; }
.auth-card .logo img { height: 60px; max-width: 100%; width: auto; display: block; margin: 0 auto; }
.auth-card h2 { text-align: center; margin: 0 0 4px; font-size: 24px; }
.auth-card .sub { text-align: center; color: #8893ab; font-size: 14px; margin-bottom: 22px; }

/* ---------- Login role selector ---------- */
.role-tabs { display: grid; grid-template-columns: repeat(auto-fit, minmax(118px, 1fr)); gap: 8px; margin-bottom: 20px; }
.role-tab {
    display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
    padding: 12px 8px; border: 1px solid #eef1f7; border-radius: 10px; background: var(--gray-bg);
    color: var(--navy); cursor: pointer; font-family: inherit; line-height: 1.2;
    font-size: 12px; font-weight: 600; text-align: center; transition: all .2s ease;
    text-decoration: none;
}
.role-tab i { font-size: 20px; color: var(--blue); }
.role-tab small { color: #8893ab; font-weight: 400; font-size: 10.5px; }
.role-tab:hover { border-color: var(--navy); transform: translateY(-2px); }
.role-tab.active { background: var(--navy); border-color: var(--navy); color: #fff; box-shadow: 0 8px 20px rgba(30,58,138,.25); }
.role-tab.active i { color: var(--gold); }
.role-tab.active small { color: #cdd8ef; }
@media (max-width: 767px) {
    .role-tabs { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 420px) {
    .role-tabs { grid-template-columns: repeat(2, 1fr); }
}

/* ---------- Admin / Panel layout ---------- */
.admin-body { margin: 0; }
.sb {
    --sb-bg: #0d0e12; --sb-link: #9a9cae; --sb-section: #636674;
    --sb-active: #415094; --sb-white: #fff; --sb-accent: #7c32ff;
    --sb-accent-grad: linear-gradient(#c738d8, #7c32ff); --sb-line: rgba(154,156,174,.35);
    background: var(--sb-bg); color: var(--sb-link); height: 100vh;
    width: 240px; position: fixed; top: 0; left: 0; padding: 20px 0; overflow-y: auto; z-index: 900;
}
.sb .brand { color: #fff; font-weight: 700; font-size: 17px; padding: 0 20px 18px; border-bottom: 1px solid rgba(255,255,255,.1); margin-bottom: 14px; }
.sb .brand small { display: block; color: var(--sb-accent); font-size: 11px; letter-spacing: 1px; font-weight: 400; }
.sb .sb-session { margin: 0 14px 12px; padding: 9px 12px; border-radius: 8px; background: rgba(255,255,255,.06); color: var(--sb-link); font-size: 12.5px; letter-spacing: .3px; }
.sb .sb-session i { margin-right: 6px; color: var(--sb-accent); }
.sb .sb-session b { color: #fff; font-weight: 600; }
.sb a { position: relative; color: var(--sb-link); text-decoration: none; display: block; padding: 11px 20px; font-size: 14px; transition: color .15s, background .15s; }
.sb a i { width: 22px; margin-right: 6px; color: #707db7; transition: color .15s; }
.sb .grp { padding: 14px 20px 6px; font-size: 11px; letter-spacing: 1px; text-transform: uppercase; color: var(--sb-section); }
.sb details { border-top: 1px solid rgba(255,255,255,.05); }
.sb summary { position: relative; color: var(--sb-link); cursor: pointer; padding: 11px 20px; font-size: 14px; list-style: none; display: flex; align-items: center; justify-content: space-between; user-select: none; transition: color .15s, background .15s; }
.sb summary::-webkit-details-marker { display: none; }
.sb summary i { width: 22px; margin-right: 6px; color: #707db7; transition: color .15s; }
.sb summary .arrow { font-size: 11px; color: var(--sb-section); transition: transform .2s, color .15s; }
.sb details[open] summary .arrow { transform: rotate(90deg); }
/* Left accent "line" that slides in on hover / active / open (like InfixEdu). */
.sb a::before, .sb summary::before {
    content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 0;
    background: var(--sb-accent-grad); opacity: 0; visibility: hidden;
    transition: width .2s ease, opacity .2s ease;
}
.sb a:hover, .sb a.active, .sb summary:hover, .sb details[open] > summary { background: var(--sb-active); color: var(--sb-white); }
.sb a:hover i, .sb a.active i, .sb summary:hover i, .sb details[open] > summary i { color: #fff; }
.sb a:hover::before, .sb a.active::before, .sb summary:hover::before, .sb details[open] > summary::before { width: 6px; opacity: 1; visibility: visible; }
/* Vertical connector line running down an opened submenu (like InfixEdu). */
.sb .sub { margin-left: 32px; padding: 2px 0 8px 18px; border-left: 1px solid var(--sb-line); }
.sb .sub a { padding: 8px 20px 8px 0; font-size: 13px; color: var(--sb-link); }
.sb .sub a::before { display: none; }
.sb .sub a:hover, .sb .sub a.active { background: rgba(255,255,255,.05); color: var(--sb-white); }
/* Nested submenu (Reports > Students Report > ...). Base rules above are
   written at one indent only, so a third level needs its own spacing. */
.sb .sub .submenu { border-top: 0; }
.sb .sub .submenu > summary { padding: 8px 20px 8px 0; font-size: 13px; font-weight: 500; }
.sb .sub .submenu > summary::before { display: none; }
.sb .sub .submenu > summary i { width: 18px; color: #707db7; }
.sb .sub .submenu > summary .arrow { font-size: 10px; }
.sb .sub .submenu > summary:hover, .sb .sub .submenu[open] > summary { background: rgba(255,255,255,.05); color: var(--sb-white); }
.sb .sub .submenu > summary:hover i, .sb .sub .submenu[open] > summary i { color: #fff; }
.sb .sub .submenu .sub { margin-left: 8px; padding: 0 0 4px 18px; }
.sb .sub .submenu .sub a { padding: 7px 20px 7px 0; font-size: 12.5px; }
/* ---------- Admin sidebar — Help/sidebar.php visual theme ----------
   Same look as Help/sidebar.php: dark #0d0e14 panel, #5b5e70 section labels,
   17px menu rows, plain submenu links (no icons), a ❯ chevron arrow, the 2px
   #4a4c5c submenu connector and white hover/active text. Scoped under
   .sb-help so the student/teacher panel sidebar keeps its original look. */
.sb-help {
    --sb-bg: #0d0e14; --sb-link: #9a9db0; --sb-section: #5b5e70;
    --sb-active: transparent; --sb-white: #fff; --sb-accent: #6b6fa8;
    --sb-line: #4a4c5c;
    width: 300px;
}
.sb-help::-webkit-scrollbar { width: 6px; }
.sb-help::-webkit-scrollbar-track { background: transparent; }
.sb-help::-webkit-scrollbar-thumb { background: #6b6fa8; border-radius: 6px; }
@media (min-width: 992px) { .sb-help ~ .main-wrap { margin-left: 300px; } }
.sb-help .brand { padding: 0 24px 18px; }
.sb-help .sb-session { margin: 0 16px 12px; }
.sb-help a { padding: 14px 24px; font-size: 17px; }
.sb-help a i { width: 34px; font-size: 18px; margin-right: 0; color: inherit; }
.sb-help .grp { padding: 28px 20px 8px; font-size: 13px; letter-spacing: 1px; color: var(--sb-section); text-transform: none; }
.sb-help details { border-top: 0; }
.sb-help summary { padding: 14px 24px; font-size: 17px; }
.sb-help summary i { width: 34px; font-size: 18px; margin-right: 0; color: inherit; }
.sb-help summary .arrow { width: auto; margin-right: 0; font-size: 12px; color: inherit; }
/* Help theme highlights with white text only — no accent bar, no fill. */
.sb-help a::before, .sb-help summary::before { display: none; }
.sb-help a:hover, .sb-help a.active,
.sb-help summary:hover, .sb-help details[open] > summary { background: transparent; color: var(--sb-white); }
.sb-help a:hover i, .sb-help a.active i,
.sb-help summary:hover i, .sb-help details[open] > summary i { color: var(--sb-white); }
.sb-help details[open] > summary .arrow { transform: rotate(90deg); }
.sb-help .sub { margin-left: 34px; padding: 2px 0 10px 22px; border-left: 2px solid var(--sb-line); }
.sb-help .sub a { padding: 11px 0; font-size: 16px; }
.sb-help .sub a:hover, .sb-help .sub a.active { background: transparent; color: var(--sb-white); }
.sb-help .sub .submenu > summary { padding: 11px 0; font-size: 16px; }
.sb-help .sub .submenu > summary i { width: 26px; font-size: 14px; color: inherit; }
.sb-help .sub .submenu > summary .arrow { width: auto; margin-right: 0; font-size: 10px; color: inherit; }
.sb-help .sub .submenu > summary:hover, .sb-help .sub .submenu[open] > summary { background: transparent; color: var(--sb-white); }
.sb-help .sub .submenu .sub { margin-left: 8px; padding: 0 0 6px 18px; }
.sb-help .sub .submenu .sub a { padding: 9px 0; font-size: 15px; }
/* Student Reports index: one page lists every report as a compact tile, three
   to a row, and the chosen one renders below. */
.rep-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.rep-list a { display: flex; align-items: center; gap: 10px; padding: 12px 14px; border: 1px solid #e6ebf3; border-radius: 10px; background: #fff; text-decoration: none; color: var(--text); font-size: 14px; font-weight: 500; transition: border-color .15s, background .15s, box-shadow .15s; }
.rep-list a:hover { border-color: rgba(30,58,138,.35); background: var(--gray-bg); color: var(--navy); }
.rep-list a.active { border-color: var(--navy); background: rgba(30,58,138,.06); box-shadow: inset 0 0 0 1px var(--navy); color: var(--navy); font-weight: 600; }
.rep-list a i { font-size: 15px; color: var(--navy); width: 18px; text-align: center; flex: none; }
.rep-list a span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@media (max-width: 991px) { .rep-list { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .rep-list { grid-template-columns: 1fr; } }
.main-wrap { margin-left: 240px; padding: 24px; min-height: 100vh; background: var(--gray-bg); }
.topbar { background: #fff; border-radius: 12px; padding: 14px 20px; display: flex; justify-content: space-between; align-items: center; margin-bottom: 22px; box-shadow: 0 4px 16px rgba(30,58,138,.06); }
.topbar-left { display: flex; align-items: center; gap: 12px; min-width: 0; }
.topbar h3 { margin: 0; font-size: 19px; min-width: 0; }
.menu-toggle { display: none; }
.sb-backdrop { display: none; }
.topbar .user { display: flex; align-items: center; gap: 10px; }
.avatar { width: 38px; height: 38px; border-radius: 50%; background: var(--navy); color: #fff; display: inline-flex; align-items: center; justify-content: center; font-weight: 700; }
.card { background: #fff; border-radius: 12px; padding: 20px; margin-bottom: 20px; box-shadow: 0 4px 16px rgba(30,58,138,.06); }
.card-title { margin: 0 0 16px; font-size: 17px; }
.instructions-box { background: #fff4d6; border: 1px solid #f0c14b; border-left: 5px solid #e8a012; border-radius: 10px; padding: 18px 20px; margin-bottom: 20px; box-shadow: 0 4px 16px rgba(232,160,18,.10); }
.instructions-box .card-title { color: #8a6100; }
.instructions-box ol { margin: 0 0 0 18px; padding: 0; line-height: 1.9; font-size: 14px; color: #6b5200; }
.instructions-box .muted { color: #8a6100; }
.section-title { margin: 22px 0 12px; font-size: 15px; color: var(--navy); border-bottom: 1px solid #eef1f7; padding-bottom: 8px; text-transform: uppercase; letter-spacing: .5px; }
.stat { border-radius: 12px; padding: 20px; color: #fff; margin-bottom: 20px; }
        .stat .num { font-size: 32px; font-weight: 700; }
        .stat .lbl { font-size: 13px; opacity: .9; text-transform: uppercase; letter-spacing: .5px; }
        .stat .ico { float: right; font-size: 30px; opacity: .5; }
        a.stat { display: block; color: #fff; text-decoration: none; transition: transform .12s ease, box-shadow .12s ease, filter .12s ease; }
        a.stat:hover { color: #fff; text-decoration: none; transform: translateY(-3px); box-shadow: 0 8px 18px rgba(0,0,0,.18); filter: brightness(1.06); }
        a.stat:focus, a.stat:active { color: #fff; text-decoration: none; }
        a.stat:hover .lbl, a.stat:hover .num, a.stat:hover .ico { text-decoration: none; }
.bg-navy { background: var(--navy); }
.bg-blue { background: var(--blue); }
.bg-gold { background: var(--gold); color: var(--navy); }
.bg-green { background: #2f8f6b; }
.bg-red { background: #D97706; }
.bg-orange { background: #F97316; }
.bg-purple { background: #7b5fc7; }
.table { width: 100%; border-collapse: collapse; font-size: 14px; }
.table th, .table td { padding: 11px 12px; border-bottom: 1px solid #eef1f7; text-align: left; vertical-align: middle; }
.table th { color: var(--navy); font-weight: 600; background: var(--gray-bg); }
.table tr:hover td { background: #fafbfe; }
/* Wide tables (broadsheet, reports) scroll inside their card instead of
   spilling past it - same role as .table-container in Help/help.txt. */
.table-responsive { width: 100%; overflow-x: auto; }
.badge { display: inline-block; padding: 4px 11px; border-radius: 30px; font-size: 12px; font-weight: 600; }
.badge-success { background: #e4f7ec; color: #1d7a47; }
.badge-warning { background: #fff4d6; color: #8a6100; }
.badge-danger { background: #fde8e8; color: #b02a37; }
.badge-info { background: #e3f0fd; color: #1c5e9e; }
.badge-secondary { background: #e9edf5; color: #5a6b8c; }
.badge-holiday { background: #fff1c2; color: #8a6100; }
.badge-reject { background: #f3d9fa; color: #7a1fa2; }
.btn-sm { padding: 6px 14px; font-size: 12.5px; }
.btn-danger { background: #D97706; color: #fff; }
.btn-success { background: #2f8f6b; color: #fff; }
.btn-info { background: var(--blue); color: #fff; }
.btn-warning { background: #e8a012; color: #fff; }
.btn-light { background: #e9edf5; color: var(--navy); }
.actions a, .actions form { display: inline-block; margin-right: 4px; }
.text-right { text-align: right; }
.mb20 { margin-bottom: 20px; }
.mt20 { margin-top: 20px; }
.muted { color: #8893ab; font-size: 13px; }
.hidden { display: none !important; }
.searchbar { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-bottom: 16px; }
.searchbar .form-control { max-width: 260px; }
.filters select, .filters input { margin-right: 8px; margin-bottom: 8px; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.pagination { display: flex; gap: 6px; margin-top: 16px; flex-wrap: wrap; }
.pagination a, .pagination span { padding: 7px 13px; border-radius: 8px; background: #fff; color: var(--navy); text-decoration: none; border: 1px solid #eef1f7; font-size: 13px; }
.pagination .cur { background: var(--navy); color: #fff; }
.photo-thumb { width: 42px; height: 42px; border-radius: 50%; object-fit: cover; }

/* ---------- Print ---------- */
@media print {
    .sb, .topbar, .no-print, .btn, .pagination { display: none !important; }
    .main-wrap { margin: 0; }
    /* Scrolling must not clip wide sheets on paper. */
    .table-responsive { overflow: visible; }
}

/* ---------- Responsive ---------- */
@media (max-width: 991px) {
    .col-md-3, .col-md-4, .col-md-6, .col-md-8, .col-md-9 { flex: 0 0 100%; max-width: 100%; }
    .col-md-offset-2, .col-md-offset-3 { margin-left: 0; }
    .carousel-track-inner > * { flex: 0 0 100%; }
    .navbar-toggle { display: block; margin-left: auto; }
    .navbar-nav { display: none; width: 100%; flex-direction: column; }
    .navbar-nav.open { display: flex; }
    .dropdown-menu { position: static; display: block; box-shadow: none; border-left: 3px solid var(--gold); margin: 0 4px 8px; }
    .header-extras { width: 100%; flex-wrap: wrap; justify-content: flex-start; gap: 12px 24px; margin-top: 12px; }
    .he-text { font-size: 11px; }
    .he-text span { font-size: 14px; }
    .logo-name { font-size: 20px; }
    .topbar-left { flex: 1 1 auto; min-width: 0; }
    .menu-toggle { display: inline-flex; align-items: center; justify-content: center; flex: none; background: var(--navy); color: #fff; border: none; width: 38px; height: 38px; border-radius: 8px; font-size: 18px; cursor: pointer; }
    .topbar h3 { font-size: 17px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
    .sb { position: fixed; left: 0; top: 0; width: 250px; transform: translateX(-100%); transition: transform .25s ease; z-index: 1001; }
    .sb.open { transform: translateX(0); }
    /* Admin sidebar on phones/tablets: wider drawer, slightly smaller type. */
    .sb-help { width: 300px; }
    .sb-help a,
    .sb-help summary { font-size: 15px; }
    .sb-help a i,
    .sb-help summary i { font-size: 16px; }
    .sb-help .sub a { font-size: 14px; }
    .sb-help .sub .submenu > summary { font-size: 14px; }
    .sb-help .sub .submenu > summary i { font-size: 13px; }
    .sb-help .sub .submenu .sub a { font-size: 13px; }
    .sb-backdrop { display: none; position: fixed; top: 0; right: 0; bottom: 0; left: 0; background: rgba(15, 23, 42, .45); z-index: 1000; }
    .sb-backdrop.show { display: block; }
    body.sb-open { overflow: hidden; }
    .main-wrap { margin-left: 0; }
    .grid2 { grid-template-columns: 1fr; }
    .topicon { justify-content: flex-start; }
}

/* ---------- Phones (Android / iOS) ---------- */
@media (max-width: 767px) {
    html, body { overflow-x: hidden; }

    /* Tables auto-size to their card: narrow tables fit, wide tables still
       scroll horizontally inside the card instead of breaking the page */
    .card { overflow-x: auto; }
    .card > .table,
    .card .table { width: max-content; max-width: 100%; }
    .table td, .table th { white-space: nowrap; }
    .table td:first-child { white-space: normal; }

    /* Compact header */
    header .container { padding: 12px 10px; }
    header .row { margin-left: 0; margin-right: 0; justify-content: center !important; }
    .logo { flex: 1 1 auto; gap: 8px; justify-content: center; min-width: 0; }
    .logo img { height: 36px; width: auto; max-width: 20vw; }
    .logo-name { font-size: 15px; line-height: 1.15; white-space: normal; overflow-wrap: anywhere; }
    .logo-tagline { font-size: 8px; letter-spacing: .5px; }
    header .header-extras { width: 100%; justify-content: center; text-align: center; }
    header .header-extras li { justify-content: center; }
    .he-text { font-size: 10px; }
    .he-text span { font-size: 12px; }
    .i-plain { font-size: 19px; margin-right: 6px; }
    .complainbtn { padding: 8px 16px; font-size: 13px; }

    /* News marquee stays compact */
    .newscontent { min-height: 34px; }
    .newstab { font-size: 10px; padding: 8px 12px; margin-right: 10px; }
    .marquee-wrap li a { font-size: 12px; margin-right: 30px; }

    /* Headings / spacing */
    .head-title { font-size: 22px; }
    .page-head { padding: 36px 0; }
    .page-head h1 { font-size: 24px; }
    .counter-main h3 { font-size: 28px; }
    .counter-main span { font-size: 12px; }
    .staffteamimg img { height: 250px; }

    /* Cards / forms breathe a bit more */
    .card { padding: 16px; }
    .service-box-content { padding: 24px 18px; }
    .auth-wrap { padding: 16px; }
    .auth-card { padding: 26px 20px; }
    .instructions-box { padding: 14px 16px; }

    /* App download stacks */
    .app-download-inner { flex-direction: column; text-align: center; gap: 14px; }
    .app-text { flex: 1 1 auto; }

    /* Buttons wrap nicely on stacked action rows */
    .text-center .btn { margin: 6px 4px; }
    .searchbar { align-items: stretch; }
    .searchbar .form-control { max-width: 100%; }

    /* Panel container breathes on phones */
    .main-wrap { padding: 12px; }
    .topbar { flex-wrap: wrap; row-gap: 10px; padding: 12px 14px; }
    .topbar-right { margin-left: auto; flex-wrap: wrap; justify-content: flex-end; }
}

/* ---------- Small phones ---------- */
@media (max-width: 420px) {
    .logo-name { font-size: 13px; }
    .logo img { height: 32px; }
    .header-extras { gap: 10px 16px; }
    .counter-main h3 { font-size: 24px; }

    /* Compact panel topbar: drop the language switch to save space */
    .lang-switch.admin { display: none; }
    .main-wrap { padding: 10px; }
    .topbar { padding: 10px 12px; }
    .topbar .user { gap: 7px; }
    .topbar .user > div:not(.avatar) { font-size: 12px; line-height: 1.35; }
    .topbar .user .muted { font-size: 10px; }
}

/* ============================================================
   Additions: Communication / Academics / System modules
   ============================================================ */

.topbar-right { display: flex; align-items: center; gap: 14px; }
.notif-bell { position: relative; color: #1c2d5b; font-size: 18px; }
.notif-bell .badge { position: absolute; top: -8px; right: -10px; font-size: 10px; }

.lang-switch { position: relative; }
.lang-switch.admin > a { font-size: 12px; color: #1c2d5b; text-decoration: none; border: 1px solid #d8ddf0; padding: 5px 10px; border-radius: 4px; display: inline-block; }
.lang-menu { position: absolute; top: 100%; right: 0; background: #fff; border: 1px solid #d8ddf0; border-radius: 6px; box-shadow: 0 4px 14px rgba(0,0,0,.12); z-index: 60; min-width: 150px; list-style: none; padding: 4px 0; margin: 4px 0 0; }
.lang-menu li a { display: block; padding: 8px 14px; font-size: 13px; color: #333; text-decoration: none; }
.lang-menu li a:hover { background: #f2f5ff; }
.lang-switch .complainbtn { display: inline-block; }

.scrollbox { max-height: 260px; overflow-y: auto; border: 1px solid #e6e9f4; border-radius: 6px; padding: 8px 10px; background: #fafbfe; }
.check-line { display: block; padding: 4px 0; font-weight: 400; cursor: pointer; }

.list-item { display: flex; align-items: center; gap: 8px; padding: 9px 12px; border-bottom: 1px solid #eef1f8; text-decoration: none; color: #333; }
.list-item:hover { background: #f2f5ff; }

.calendar-grid td { height: 74px; vertical-align: top; width: 14.28%; border: 1px solid #e6e9f4; padding: 4px; }
.calendar-grid th { text-align: center; font-size: 12px; color: #888; }
.cal-day { font-weight: 700; font-size: 13px; color: #1c2d5b; }
.calendar-grid td.today { background: #eef2ff; outline: 2px solid #1c2d5b; }
.cal-event { background: #22409a; color: #fff; font-size: 10px; padding: 1px 4px; border-radius: 3px; margin: 2px 0; overflow: hidden; white-space: nowrap; }

.timeline { position: relative; padding-left: 24px; }
.timeline:before { content: ""; position: absolute; left: 6px; top: 4px; bottom: 4px; width: 2px; background: #dfe5f6; }
.tl-item { position: relative; margin-bottom: 18px; }
.tl-item:before { content: ""; position: absolute; left: -24px; top: 6px; width: 12px; height: 12px; border-radius: 50%; background: #22409a; border: 2px solid #fff; box-shadow: 0 0 0 2px #dfe5f6; }
.tl-date { font-size: 11px; color: #8a93ab; text-transform: uppercase; letter-spacing: .5px; }
.tl-body { background: #f7f9ff; border: 1px solid #e6e9f4; border-radius: 8px; padding: 10px 14px; margin-top: 2px; }

.notify-item { border: 1px solid #e6e9f4; border-radius: 8px; padding: 12px 14px; margin-bottom: 10px; }
.notify-item.unread { border-left: 4px solid #22409a; background: #f7f9ff; }
.notify-item.unread .ni-head b { color: #22409a; }

.fee-pay-row { display: flex; justify-content: space-between; align-items: center; border: 1px solid #e6e9f4; border-radius: 8px; padding: 12px 14px; margin-bottom: 10px; }
.fee-pay-row form, .fee-pay-row button { margin: 0 0 0 6px; }

.btn-navy { background: #22409a; color: #fff; }
.btn-navy:hover, .btn-navy:focus { background: #1b3480; color: #fff; }

.d-flex { display: flex; }

/* Student profile identity card: barcode + QR block */
/* Student profile identity strip: horizontal band across the top, matching
     the reference layout. Photo + Admission/Roll on the left, then one column
     per attribute running left to right. */
  .idstrip { display: flex; flex-wrap: wrap; gap: 18px; align-items: flex-start; }
  .idstrip-id { display: flex; gap: 14px; align-items: center; flex: 0 0 auto; }
  .idstrip-photo {
    width: 104px; height: 104px; border-radius: 52px; object-fit: cover;
    border: 3px solid #eef1f7; flex: 0 0 auto;
  }
  .idstrip-name { margin: 0 0 6px; font-size: 19px; font-weight: 700; }
  .idstrip-pair { font-size: 13px; line-height: 1.5; }
  .idstrip-pair span {
    display: inline-block; width: 96px; color: #8a94a6; font-size: 12px;
  }
  .idstrip-pair b { font-weight: 600; }
  .idstrip-fields {
    display: flex; flex-wrap: wrap; flex: 1 1 auto;
    border-left: 1px solid #eef1f7;
  }
  .idfield {
    padding: 4px 18px; min-width: 108px;
    border-right: 1px solid #eef1f7;
  }
  .idfield:last-child { border-right: 0; }
  .idfield-lbl {
    display: block; font-size: 11px; text-transform: uppercase;
    letter-spacing: .4px; color: #8a94a6; margin-bottom: 3px;
  }
  .idfield b { display: block; font-size: 15px; font-weight: 600; }
  .idfield .badge { margin-top: 3px; }
  .idfield-sub { display: block; color: #8a94a6; font-size: 11px; margin-top: 3px; }
  /* Barcode + QR sit inside the band, so they need their own breathing room. */
  .idfield .barcode-svg { max-width: 100%; height: auto; }
  @media (max-width: 991px) {
    .idstrip-fields { border-left: 0; border-top: 1px solid #eef1f7; padding-top: 8px; }
    .idfield { border-right: 0; border-bottom: 1px solid #eef1f7; padding-bottom: 8px; }
  }

  .barcode-svg { max-width: 100%; height: auto; }
.barcode-text {
  font-family: 'Courier New', monospace;
  letter-spacing: 3px;
  font-size: 13px;
  color: #333;
  margin-top: 2px;
}
#qrBox { display: inline-block; }
#qrBox img, #qrBox canvas { display: block; }
@media print {
  .barcode-svg, #qrBox { max-width: 150px; }
}

/* Sibling cards: one card per sibling, each carrying its own admission no,
 * roll no, class, section, RTE, barcode and QR. Siblings are related to each
 * other, not to the student above, so they are shown as a card grid instead
 * of one continuous band. */
.sibcards {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); gap: 14px;
}
.sibcard { margin: 0; padding: 0; overflow: hidden; }
.sibcard .card-title { margin: 0; }
.sibcard-top {
  display: flex; align-items: baseline; gap: 6px; flex-wrap: wrap;
  padding: 10px 18px; background: #f7f9fd;
  border-bottom: 1px solid #eef1f7; font-size: 15px;
}
.sibcard .idstrip-fields { border-left: 0; }
@media (max-width: 991px) {
  .sibcard .idstrip-fields { border-left: 0; border-top: 0; }
}

/* ============================================================
   Phones: profile identity strip + result-panel tables
   ============================================================ */
@media (max-width: 767px) {
  /* Identity strip: fields wrap two-per-row with dividers instead of one
     tall column, and the barcode is capped so it cannot overflow. */
  .idstrip-fields { border-left: 0; border-top: 1px solid #eef1f7; padding-top: 8px; }
  .idfield { min-width: 50%; padding: 8px 12px; border-right: 0; border-bottom: 1px solid #eef1f7; }
  .idfield .barcode-svg { max-width: 150px; }

  /* Exam/result panels embed their own table; the .card rule cannot reach
     inside .panel, whose overflow:hidden would clip it. Let it scroll. */
  .panel { overflow-x: auto; }
  .panel .table { width: max-content; min-width: 100%; }
}
@media (max-width: 420px) {
  .idfield { min-width: 100%; }
  .sibcards { grid-template-columns: 1fr; }
}

/* ============================================================
   Student profile (Profile.mht reference): profile widget on the
   left, tabbed detail panel on the right.
   ============================================================ */
.profile-layout { margin-left: -10px; margin-right: -10px; }
.profile-layout > .col-md-3, .profile-layout > .col-md-9 { padding-left: 10px; padding-right: 10px; }
.profile-widget { padding: 0; overflow: hidden; border: 1px solid #3c8dbc; box-shadow: none; }
.profile-widget-head { padding: 12px 14px; background: #f7f7f7; border-bottom: 1px solid #eef1f7; overflow: hidden; }
.profile-widget-head .profile-avatar {
  width: 65px; height: 65px; object-fit: cover; float: left;
  border-radius: .5rem; border: 3px solid #fff;
  box-shadow: 0 2px 10px rgba(47,43,61,.16);
}
.profile-widget-head .profile-widget-name { margin: 5px 0 3px 80px; font-size: 19px; line-height: 1.25; color: #1b2a4a; }
.profile-widget-head .profile-widget-desc { margin-left: 80px; font-size: 13px; color: #55607a; }
.profile-widget-head .profile-widget-desc b { color: #00a5c8; font-weight: 600; }

.profile-actions { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; margin: 10px 0; padding: 0 6px; border-bottom: 1px solid #eef1f7; }
.profile-actions form { margin: 0; }
.profile-actions .pi-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: auto; height: auto; padding: 10px; border: 0; border-radius: 0;
  background: transparent; color: #43506a; font-size: 15px; text-decoration: none;
  cursor: pointer;
}
.profile-actions .pi-btn:hover { background: transparent; color: #22409a; }
.profile-actions .pi-btn[disabled] { opacity: .45; cursor: not-allowed; }
.profile-actions .pi-btn[disabled]:hover { background: transparent; color: #43506a; }

.profile-list { list-style: none; margin: 0; padding: 0; }
.profile-list li { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 14px; border-bottom: 1px solid #f0f2f7; }
.profile-list li:last-child { border-bottom: 0; }
.profile-list b { color: #334155; font-size: 14px; }
.profile-list .val { color: #00a5c8; font-weight: 600; font-size: 14px; text-align: right; }
.profile-list .profile-barcode-svg { max-width: 120px; height: 34px; }
.profile-list .profile-qr img, .profile-list .profile-qr canvas { width: 72px; height: 72px; display: block; }

.profile-tabs { display: flex; flex-wrap: wrap; gap: 0; border-bottom: 1px solid #eef1f7; margin: 0 0 14px; padding: 0 6px; background: #fbfcff; border-radius: 8px 8px 0 0; }
.profile-tabs .role-tab {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 12px 15px; margin: 0 1px -1px 0; border: 0;
  border-bottom: 3px solid transparent; border-radius: 0;
  background: transparent; color: #55607a; font-size: 13px; font-weight: 600;
  box-shadow: none; transform: none;
}
.profile-tabs .role-tab i { font-size: 14px; color: #8893ab; }
.profile-tabs .role-tab:hover { transform: none; background: #f2f5fb; color: #22409a; }
.profile-tabs .role-tab.active { background: transparent; color: #22409a; border-bottom-color: #22409a; box-shadow: none; }
.profile-tabs .role-tab.active i { color: #22409a; }

.tshadow { border: 1px solid #eef1f7; border-radius: 10px; margin-bottom: 18px; overflow: hidden; }
.tshadow .pagetitleh2 { margin: 0; background: #f3f5f9; padding: 10px 16px; font-size: 15px; color: #22409a; border-bottom: 1px solid #eef1f7; }
.table3 { width: 100%; border-collapse: collapse; font-size: 14px; }
.table3 td { padding: 10px 16px; border-bottom: 1px solid #f0f2f7; vertical-align: middle; }
.table3 tr:last-child td { border-bottom: 0; }
.table3 td:first-child { width: 35%; color: #55607a; }
.table3 td b { color: #1b2a4a; }
.table3 tr:nth-child(odd) td { background: #fafbfe; }
.table3 tr.bordertop td { border-top: 1px solid #e6e9f4; }

@media (max-width: 767px) {
  .profile-widget-head { padding: 18px 12px 14px; }
  .profile-list li { padding: 10px 12px; }
  .table3 td { padding: 9px 12px; }
  .table3 td:first-child { width: 42%; }
  .profile-tabs .role-tab { flex: 1 1 auto; justify-content: center; }
}

