body.theme-shell {
  background: #ffffff;
  color: #111a2e;
}
main {
  display: grid;
  gap: 5rem;
}
.achievement,
.news-section {
  padding: 0;
}

/* School intro heading sizes */
.school-intro-box h2 {
  color: #4e008a;
  font-size: 30px;
  line-height: 1.2;
}
@media (max-width: 768px) {
  .school-intro-box h2 {
    font-size: 24px;
  }
}

/* Page skeleton */
body.bgschool-is-loading .bgschool-page-skeleton {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}
.bgschool-page-skeleton {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: grid;
  place-items: center;
  background: #fff;
  opacity: 0;
  visibility: hidden;
  transition: opacity .32s ease, visibility .32s ease;
  pointer-events: none;
}
.bgschool-page-skeleton__card {
  width: min(420px, 78vw);
  display: grid;
  gap: .85rem;
}
.bgschool-skel {
  border-radius: 14px;
  background: linear-gradient(90deg, rgba(16, 2, 73, .06), rgba(16, 2, 73, .14), rgba(16, 2, 73, .06));
  background-size: 200% 100%;
  animation: bgschool-skel 1.15s ease-in-out infinite;
}
.bgschool-skel--logo {
  height: 3.2rem;
  width: 9rem;
  margin: 0 auto;
  border-radius: 999px;
}
.bgschool-skel--line { height: .9rem; }
.bgschool-skel--line-sm {
  height: .7rem;
  width: 70%;
  margin: 0 auto;
}
@keyframes bgschool-skel {
  0% { background-position: 100% 0; }
  100% { background-position: -100% 0; }
}

/* Lazyload + image skeleton */
img.lazyload,
img.lazyloading {
  background: linear-gradient(90deg, #efeaf8, #f7f4fc, #efeaf8);
  background-size: 200% 100%;
  animation: bgschool-skel 1.15s ease-in-out infinite;
  color: transparent;
}
img.lazyloaded,
img.lazyload.is-loaded {
  animation: none;
  background: none;
  color: inherit;
}
.img-skel {
  position: relative;
  overflow: hidden;
  background: #efeaf8;
}
.img-skel::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,.55), transparent);
  transform: translateX(-100%);
  animation: bgschool-shimmer 1.2s infinite;
}
.img-skel.is-ready::after {
  display: none;
}
@keyframes bgschool-shimmer {
  100% { transform: translateX(100%); }
}

/* Footer social + map */
.footer-social {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}
.footer-social a {
  width: 40px;
  height: 40px;
  display: inline-grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, .12);
  color: #fff !important;
  text-decoration: none !important;
  transition: background .25s ease, transform .25s ease;
}
.footer-social a:hover {
  background: var(--gold, #ffb347);
  color: #100249 !important;
  transform: translateY(-2px);
}
.footer-hotline {
  margin-top: 10px;
  font-weight: 800;
}
.footer-hotline a {
  color: #ffb347 !important;
  text-decoration: none !important;
}
.footer-map {
  margin-top: 28px;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 18px 40px rgba(0, 0, 0, .28);
  border: 1px solid rgba(255, 255, 255, .12);
}
.footer-map iframe {
  display: block;
  width: 100%;
  height: 240px;
  border: 0;
}
.footer-map-wrap {
  grid-column: 1 / -1;
}

/* Contact map */
.contact-map {
  margin-top: 18px;
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 16px 36px rgba(16, 2, 73, .12);
}
.contact-map iframe {
  display: block;
  width: 100%;
  height: 220px;
  border: 0;
}

/* Gallery detail */
.gallery-detail {
  padding: 40px 0 80px;
}
.gallery-detail-card {
  background: #fff;
  padding: 34px;
  box-shadow: 0 20px 50px rgba(16, 2, 73, .08);
}
.gallery-detail-meta {
  display: flex;
  gap: 18px;
  flex-wrap: wrap;
  margin-bottom: 18px;
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
  color: #15286b;
}
.gallery-detail-sapo {
  font-size: 1.08rem;
  line-height: 1.7;
  font-weight: 600;
  color: #0f1b3d;
  margin: 0 0 28px;
}
.gallery-detail-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}
.gallery-detail-item {
  position: relative;
  display: block;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border-radius: 18px;
  background: #100249;
  cursor: pointer;
}
.gallery-detail-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform .45s ease;
}
.gallery-detail-item:hover img {
  transform: scale(1.05);
}
.gallery-detail-item figcaption {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 14px 16px;
  color: #fff;
  font-size: 13px;
  background: linear-gradient(180deg, transparent, rgba(16, 2, 73, .72));
}

/* Blog related */
.blog-related {
  margin-top: 48px;
  padding-top: 28px;
  border-top: 1px solid #ffe0c2;
}
.blog-related h3 {
  margin: 0 0 22px;
  font-size: 22px;
  color: #100249;
}
.blog-related .news-list {
  padding: 0;
}

.news-feature h3,
.news-item h4,
.news-hitem h4 {
  font-weight: 600;
}
.features-home {
  border-top-left-radius: 100px;
  border-bottom-right-radius: 100px;
  overflow: hidden;
  border-top-right-radius: 15px;
  border-bottom-left-radius: 15px;
}
.program-tile {
  color: #fff;
}
.brand-logo {
  height: 60px;
  width: 60px;
  background: #fff;
  display: grid;
  justify-content: center;
  align-items: center;
  border-radius: 50%;
}

.thtl-gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 15px;
}
.thtl-gallery-card,
.thtl-gallery-more {
  position: relative;
  display: block;
  min-height: 230px;
  overflow: hidden;
  background: #100249;
  box-shadow: 0 24px 60px rgba(229, 106, 10, 0.14);
  border-radius: 25px;
}
.thtl-gallery-card::before,
.thtl-gallery-more::before {
  content: "";
  position: absolute;
  inset: 16px;
  border: 1px solid rgba(255, 239, 221, 0.45);
  border-radius: 20px;
  z-index: 1;
}
.thtl-gallery-card img,
.thtl-gallery-card__placeholder {
  width: 100%;
  height: 100%;
  display: block;
}
.thtl-gallery-card img {
  object-fit: cover;
}
.thtl-gallery-card__placeholder,
.thtl-gallery-more {
  background: linear-gradient(135deg, #110149 0%, #100249 100%);
}
.thtl-gallery-card__overlay,
.thtl-gallery-more__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(92, 46, 10, .05) 0%, rgb(16 2 73 / 40%) 100%);
  z-index: 1;
}
.thtl-gallery-card__content,
.thtl-gallery-more__content {
  position: absolute;
  left: 20px;
  right: 20px;
  bottom: 20px;
  z-index: 2;
  color: #fff;
}
.thtl-gallery-card__content h3 {
  margin: 0;
  font-size: clamp(18px, 2vw, 26px);
  line-height: 1.12;
  font-weight: 900;
  color: #fff2df;
}
.thtl-gallery-card__content p {
  margin: 10px 0 0;
  font-size: 14px;
  line-height: 1.55;
  color: rgba(255, 244, 235, 0.92);
}
.thtl-gallery-more {
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  text-decoration: none;
}
.thtl-gallery-more__content {
  position: relative;
  left: auto;
  right: auto;
  bottom: auto;
}
.thtl-gallery-more__count {
  display: block;
  font-size: clamp(34px, 4vw, 54px);
  line-height: 1;
  font-weight: 900;
  color: #fff;
}
.thtl-gallery-more__label {
  display: block;
  margin-top: 10px;
  font-size: 15px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: rgba(255, 244, 235, 0.96);
}

@media (prefers-reduced-motion: reduce) {
  .bgschool-skel,
  img.lazyload,
  img.lazyloading,
  .img-skel::after {
    animation: none !important;
  }
  .wow {
    visibility: visible !important;
    animation: none !important;
  }
}

@media (max-width: 991px) {
  .thtl-gallery-section {
    padding: 70px 0;
  }
  .thtl-gallery-grid,
  .gallery-detail-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .footer-map iframe,
  .contact-map iframe {
    height: 200px;
  }
}
@media (max-width: 640px) {
  .thtl-gallery-grid,
  .gallery-detail-grid {
    grid-template-columns: 1fr;
    gap: 14px;
  }
  .thtl-gallery-card,
  .thtl-gallery-more {
    min-height: 180px;
    border-radius: 20px;
  }
  .thtl-gallery-card::before,
  .thtl-gallery-more::before {
    inset: 10px;
    border-radius: 14px;
  }
  .thtl-gallery-card__content,
  .thtl-gallery-more__content {
    left: 14px;
    right: 14px;
    bottom: 14px;
  }
  .thtl-gallery-card__content h3 {
    font-size: 17px;
  }
  .thtl-gallery-card__content p,
  .thtl-gallery-more__label {
    font-size: 13px;
  }
  .gallery-detail-card {
    padding: 22px;
  }
}

/* Keep list helpers outside the 2-col article grid */
.news-list > .blog-search-form,
.news-list > .pager-wrap,
.news-list > .blog-empty,
.thtl-gallery-section > .pager-wrap,
.thtl-gallery-section > .blog-empty {
  grid-column: 1 / -1;
}
.news-list > .blog-search-form {
  margin-bottom: 10px;
}

/* ===== Blog detail (Melaka-inspired layout, bgschool look) ===== */
.bg-article-page {
  padding: 48px 0 80px;
  max-width: 1280px;
}
.bg-article-breadcrumb {
  margin-bottom: 22px;
  font-size: 13px;
  color: #6b7896;
}
.bg-article-breadcrumb__list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.bg-article-breadcrumb a {
  color: #6b7896;
  text-decoration: none;
}
.bg-article-breadcrumb a:hover {
  color: #100249;
}
.bg-article-header {
  max-width: 820px;
  margin: 0 auto;
}
.bg-article-eyebrow {
  display: inline-block;
  text-transform: uppercase;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .1em;
  color: #100249;
  border-bottom: 2px solid #ffb347;
  padding-bottom: 8px;
  margin: 0 0 16px;
}
.bg-article-title {
  margin: 0;
  font-family: "Fraunces", serif;
  font-size: clamp(20px, 4.5vw, 25px);
  line-height: 1.5;
  color: #0f1b3d;
}
.bg-article-meta {
  margin: 16px 0 0;
  font-size: 13px;
  font-weight: 700;
  color: #6b7896;
}
.bg-article-summary {
  margin: 22px 0 0;
  font-size: 1.15rem;
  line-height: 1.75;
  font-weight: 500;
  color: #516079;
}
.bg-article-cover {
  margin: 36px auto 0;
  max-width: 980px;
}
.bg-article-cover img {
  width: 100%;
  height: clamp(260px, 42vw, 420px);
  object-fit: cover;
  display: block;
  border-radius: 24px;
  box-shadow: 0 24px 60px rgba(16, 2, 73, .12);
}
.bg-article-content-wrap {
  margin-top: 42px;
}

.bg-article-layout {
  display: grid;
  gap: 1.75rem;
  grid-template-columns: 1fr;
  align-items: start;
}
.bg-share-rail { order: 3; }
.bg-article-main { order: 1; min-width: 0; }
.bg-article-rail { order: 2; }

.bg-share-rail__inner {
  display: flex;
  flex-wrap: wrap;
  gap: .65rem;
  align-items: center;
}
.bg-share-rail__label {
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: #100249;
  opacity: .55;
  margin-right: .25rem;
}
.bg-share-btn {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 999px;
  border: 1px solid rgba(16, 2, 73, .16);
  background: #fff;
  color: #100249;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background .2s ease, border-color .2s ease, color .2s ease;
  cursor: pointer;
  text-decoration: none;
}
.bg-share-btn svg { width: 1rem; height: 1rem; }
.bg-share-btn:hover,
.bg-share-btn.is-copied {
  background: #100249;
  border-color: #100249;
  color: #fff;
}

.bg-article-rail__sticky { display: grid; gap: 1rem; }
.bg-toc,
.bg-side-gallery {
  border-radius: 1.25rem;
  border: 1px solid #ffe0c2;
  background: #fff;
  padding: 1rem 1.1rem;
  box-shadow: 0 12px 30px rgba(16, 2, 73, .06);
}
.bg-toc__title,
.bg-side-gallery__title {
  font-size: .78rem;
  font-weight: 800;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: #100249;
  margin: 0 0 .75rem;
}
.bg-toc .ai-toc,
.bg-toc .ai-sub-toc {
  list-style: none;
  margin: 0;
  padding: 0;
}
.bg-toc .ai-sub-toc { padding-left: .9rem; margin-top: .25rem; }
.bg-toc li a {
  display: block;
  padding: .35rem 0;
  color: rgba(15, 27, 61, .72);
  text-decoration: none;
  font-size: .92rem;
  line-height: 1.45;
}
.bg-toc li a:hover { color: #100249; }

.bg-side-gallery__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: .45rem;
}
.bg-side-gallery__item {
  position: relative;
  display: block;
  aspect-ratio: 1;
  overflow: hidden;
  border-radius: .85rem;
  background: #efeaf8;
}
.bg-side-gallery__item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.bg-side-gallery__item.is-hidden { display: none; }
.bg-side-gallery__item.is-more .bg-side-gallery__more {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(16, 2, 73, .62);
  color: #fff;
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: .04em;
  text-align: center;
  padding: .35rem;
}

.prose-like .bg-lg-item {
  display: block;
  margin: 1.5rem auto;
  max-width: 100%;
  text-align: center;
}
.prose-like h2,
.prose-like h3 {
  margin-top: 2rem;
  font-family: "Fraunces", serif;
  color: #0f1b3d;
  line-height: 1.2;
}
.prose-like h2 { font-size: clamp(1.5rem, 2.4vw, 2rem); }
.prose-like h3 { font-size: clamp(1.2rem, 2vw, 1.45rem); }
.prose-like p {
  margin-top: 1rem;
  font-size: 1.05rem;
  line-height: 1.85;
  color: #516079;
}
.prose-like a {
  color: #100249;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.prose-like ul,
.prose-like ol {
  margin-top: 1rem;
  padding-left: 1.25rem;
}
.prose-like li {
  margin-top: .5rem;
  font-size: 1.05rem;
  line-height: 1.85;
  color: #516079;
}
.prose-like img {
  display: block;
  margin-left: auto;
  margin-right: auto;
  max-width: 100%;
  height: auto;
  border-radius: 1.1rem;
}
.prose-like figure { text-align: center; margin: 1.5rem auto; }
.prose-like figcaption {
  margin-top: .5rem;
  font-size: .9rem;
  font-style: italic;
  color: #6b7896;
}
.bg-table-scroll { width: 100%; overflow-x: auto; margin: 1.5rem 0; }
.prose-like table {
  width: 100%;
  border-collapse: collapse;
  background: #fff;
  border: 1px solid #ffe0c2;
}
.prose-like th,
.prose-like td {
  border: 1px solid #ffe0c2;
  padding: .7rem .85rem;
  text-align: left;
  vertical-align: top;
  font-size: 1rem;
  line-height: 1.55;
  color: #516079;
}
.prose-like th {
  background: rgba(255, 179, 71, .14);
  color: #0f1b3d;
  font-weight: 700;
}

.bg-article-source {
  margin-top: 1.5rem;
  font-size: .9rem;
  color: #6b7896;
}
.bg-article-source a { color: #100249; }

.bg-post-tags {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem;
  margin-top: 1.75rem;
}
.bg-post-tag {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  border: 1px solid #ffe0c2;
  background: #fff;
  padding: .35rem .85rem;
  font-size: .8rem;
  font-weight: 700;
  color: #100249;
  text-decoration: none;
}
.bg-post-tag:hover {
  background: #100249;
  border-color: #100249;
  color: #fff;
}

.bg-blog-cta {
  margin-top: 2.5rem;
  border-radius: 1.5rem;
  border: 1px solid #ffe0c2;
  background: linear-gradient(145deg, #fff8ef 0%, #ffffff 100%);
  padding: 1.75rem 1.5rem;
  box-shadow: 0 16px 40px rgba(16, 2, 73, .06);
}
.bg-blog-cta h2 {
  margin: 0;
  font-family: "Fraunces", serif;
  font-size: clamp(1.4rem, 2.4vw, 1.85rem);
  color: #100249;
}
.bg-blog-cta p {
  margin: .75rem 0 0;
  color: #516079;
  line-height: 1.7;
}
.bg-blog-cta__actions {
  margin-top: 1.25rem;
  display: flex;
  flex-wrap: wrap;
  gap: .75rem;
}
.bg-blog-cta__btn {
  display: inline-block;
  border-radius: 999px;
  padding: .75rem 1.5rem;
  text-align: center;
  font-size: .875rem;
  font-weight: 800;
  text-decoration: none !important;
  transition: background .2s ease, border-color .2s ease, color .2s ease;
}
.bg-blog-cta__btn--primary {
  background: #100249;
  color: #fff;
}
.bg-blog-cta__btn--primary:hover { background: #4e008a; }
.bg-blog-cta__btn--outline {
  border: 1px solid rgba(16, 2, 73, .2);
  color: #100249;
  background: #fff;
}
.bg-blog-cta__btn--outline:hover {
  border-color: #100249;
  background: rgba(16, 2, 73, .05);
}

.bg-toc { position: relative; }
.bg-toc__list {
  max-height: 14.5rem;
  overflow: hidden;
  position: relative;
}
.bg-toc.is-collapsed .bg-toc__list:after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 3.25rem;
  background: linear-gradient(to bottom, rgba(255,255,255,0), rgba(255,255,255,.96) 70%);
  pointer-events: none;
}
.bg-toc__more {
  display: none;
  width: 100%;
  margin-top: .65rem;
  border: 0;
  background: transparent;
  color: #100249;
  font-size: .82rem;
  font-weight: 800;
  cursor: pointer;
  text-align: left;
  padding: 0;
}
.bg-toc.is-collapsed .bg-toc__more {
  display: inline-flex;
  align-items: center;
  gap: .35rem;
}
.bg-toc-drawer {
  position: fixed;
  inset: 0;
  z-index: 120;
  pointer-events: none;
  visibility: hidden;
}
.bg-toc-drawer.is-open {
  pointer-events: auto;
  visibility: visible;
}
.bg-toc-drawer__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(16, 2, 73, .42);
  opacity: 0;
  transition: opacity .22s ease;
}
.bg-toc-drawer.is-open .bg-toc-drawer__backdrop { opacity: 1; }
.bg-toc-drawer__panel {
  position: absolute;
  top: 0; right: 0;
  width: min(25vw, 22rem);
  min-width: 17rem;
  height: 100%;
  background: #fff;
  border-left: 1px solid #ffe0c2;
  box-shadow: -18px 0 50px rgba(16, 2, 73, .16);
  transform: translateX(104%);
  transition: transform .24s ease;
  display: flex;
  flex-direction: column;
}
.bg-toc-drawer.is-open .bg-toc-drawer__panel { transform: translateX(0); }
.bg-toc-drawer__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.1rem 1.15rem;
  border-bottom: 1px solid #ffe0c2;
}
.bg-toc-drawer__title {
  font-size: .82rem;
  font-weight: 800;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: #100249;
  margin: 0;
}
.bg-toc-drawer__close {
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 999px;
  border: 1px solid #ffe0c2;
  background: #fff;
  color: #100249;
  font-size: 1.25rem;
  line-height: 1;
  cursor: pointer;
}
.bg-toc-drawer__body {
  flex: 1;
  overflow: auto;
  padding: 1rem 1.15rem 1.5rem;
  -webkit-overflow-scrolling: touch;
}
.bg-toc-drawer__body .ai-toc,
.bg-toc-drawer__body .ai-sub-toc { list-style: none; margin: 0; padding: 0; }
.bg-toc-drawer__body .ai-sub-toc { padding-left: .9rem; margin-top: .25rem; }
.bg-toc-drawer__body li a {
  display: block;
  padding: .4rem 0;
  color: rgba(15, 27, 61, .76);
  text-decoration: none;
  font-size: .95rem;
  line-height: 1.45;
}
.bg-toc-drawer__body li a:hover { color: #100249; }
body.toc-drawer-open { overflow: hidden; }

@media (min-width: 1024px) {
  .bg-article-layout {
    grid-template-columns: 3.5rem minmax(0, 1fr) 17rem;
    gap: 1.5rem;
    align-items: start;
  }
  .bg-share-rail,
  .bg-article-rail {
    order: 0;
    position: sticky;
    top: 6.5rem;
    align-self: start;
    z-index: 1;
  }
  .bg-article-main { order: 0; }
  .bg-share-rail__inner {
    position: static;
    flex-direction: column;
    align-items: center;
  }
  .bg-share-rail__label {
    writing-mode: vertical-rl;
    transform: rotate(180deg);
    margin: 0 0 .35rem;
  }
}
@media (max-width: 1023px) {
  .bg-toc-drawer__panel { width: min(86vw, 22rem); }
  .bg-article-page { padding: 28px 0 56px; }
  .bg-article-cover img { border-radius: 18px; }
}
