/* ==========================================================================
   Regal Sunbeam Schools - site overrides (loaded after main.css)
   ========================================================================== */

/* 1. Icons -----------------------------------------------------------------
   Some pages use Font Awesome 6 class names (fa-solid / fa-regular / fa-light / fa-brands)
   while the bundled stylesheet is Font Awesome 5 Pro. Map them onto the same font files
   so those icons stop rendering as empty squares. */
.fa-solid, .fa-regular, .fa-light, .fa-brands {
  -moz-osx-font-smoothing: grayscale; -webkit-font-smoothing: antialiased;
  display: inline-block; font-style: normal; font-variant: normal; text-rendering: auto; line-height: 1;
}
.fa-solid   { font-family: "Font Awesome 5 Pro";    font-weight: 900; }
.fa-regular { font-family: "Font Awesome 5 Pro";    font-weight: 400; }
.fa-light   { font-family: "Font Awesome 5 Pro";    font-weight: 300; }
.fa-brands  { font-family: "Font Awesome 5 Brands"; font-weight: 400; }
.fa-location-dot:before { content: "\f3c5"; }

/* 2. Page width: nothing may be wider than the screen ---------------------- */
html { -webkit-text-size-adjust: 100%; width: 100%; max-width: 100%; overflow-x: hidden; }
body { width: 100%; max-width: 100%; overflow-x: hidden; position: relative; }
img, video, iframe, table { max-width: 100%; }
@media (max-width: 991.98px) {
  .container, .container-fluid, .container-sm, .container-md, .container-lg {
    width: 100%; max-width: 100%; padding-left: 16px; padding-right: 16px;
  }
}
@media (max-width: 767.98px) {
  section, header, footer, .fix { max-width: 100%; }
  .swiper, .swiper-container { max-width: 100%; overflow: hidden; }
  .row { --bs-gutter-x: 1.25rem; }
}

/* 3. Preloader: crest inside a slightly bigger spinning ring ------------------ */
.preloader .animation-preloader .spinner-wrap {
  position: relative; width: 11.5em; height: 11.5em; margin: 0 auto 3em auto;
}
.preloader .animation-preloader .spinner-wrap .spinner {
  width: 100%; height: 100%; margin: 0; border-width: 4px;
}
.preloader .animation-preloader .preloader-logo {
  position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
  height: 68%; width: auto; max-width: 74%; object-fit: contain;
  animation: regalPreloaderPulse 2s ease-in-out infinite;
}
@keyframes regalPreloaderPulse {
  0%, 100% { transform: translate(-50%, -50%) scale(1); }
  50%      { transform: translate(-50%, -50%) scale(1.06); }
}
@media (max-width: 767px) {
  .preloader .animation-preloader .spinner-wrap { width: 9.5em; height: 9.5em; margin: 0 auto 1.5em auto; }
}

/* 4. Brand lock-up (crest + school name) --------------------------------------- */
.brand-lockup { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; }
.brand-lockup .brand-crest {
  display: inline-flex; align-items: center; justify-content: center; flex: 0 0 auto;
  background: #fff; border-radius: 14px; padding: 4px 7px; box-shadow: 0 2px 10px rgba(0, 0, 0, .14);
}
.brand-lockup .brand-crest img { height: 56px; width: auto; display: block; }
.brand-lockup .brand-name {
  display: flex; flex-direction: column; text-align: left; color: #fff;
  font-family: "Quicksand", sans-serif; font-weight: 700; font-size: 21px; line-height: 1.05;
}
.brand-lockup .brand-name small {
  font-size: 12px; font-weight: 700; letter-spacing: .22em; text-transform: uppercase; opacity: .92; margin-top: 3px;
}
.brand-lockup-dark .brand-name,
.header-1.sticky .brand-lockup .brand-name,
.header-4 .brand-lockup .brand-name { color: var(--header); }
.offcanvas__logo .brand-lockup .brand-crest img { height: 48px; }
@media (max-width: 575.98px) {
  .brand-lockup { gap: 8px; }
  .brand-lockup .brand-crest img { height: 44px; }
  .brand-lockup .brand-name { font-size: 16px; }
  .brand-lockup .brand-name small { font-size: 10px; letter-spacing: .18em; }
}

/* 5. Admin login: icon (+ label) in the navbar, full button elsewhere ----------------- */
.admin-login-icon {
  position: relative; display: inline-flex; align-items: center; gap: 9px; margin-right: 14px;
  padding: 5px 16px 5px 5px; border-radius: 999px; line-height: 1;
  font-family: "Quicksand", sans-serif; font-weight: 700; font-size: 14px; color: #fff;
  background: rgba(255, 255, 255, .16); border: 1px solid rgba(255, 255, 255, .4);
  transition: all .3s ease;
}
.admin-login-icon i {
  width: 36px; height: 36px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center;
  background: var(--theme-color); color: #fff; font-size: 15px; flex: 0 0 auto;
}
.admin-login-icon:hover, .admin-login-icon:focus-visible { background: var(--theme-color-2); border-color: var(--theme-color-2); color: #fff; }
.header-4 .admin-login-icon, .header-1.sticky .admin-login-icon {
  color: var(--header); background: #f4f1ff; border-color: #e0d9ff;
}
.header-4 .admin-login-icon:hover, .header-1.sticky .admin-login-icon:hover { color: #fff; background: var(--theme-color-2); border-color: var(--theme-color-2); }
.admin-login-label { white-space: nowrap; }
/* narrower screens: icon only, label appears as a tooltip on hover / focus / long-press */
@media (max-width: 1399.98px) {
  .admin-login-icon { padding: 4px; margin-right: 10px; }
  .admin-login-label { display: none; }
  .admin-login-icon::after {
    content: attr(aria-label); position: absolute; top: calc(100% + 10px); right: 0; z-index: 30;
    background: var(--header); color: #fff; font-size: 12px; font-weight: 600; padding: 5px 10px; border-radius: 8px;
    white-space: nowrap; opacity: 0; transform: translateY(-4px); pointer-events: none; transition: all .2s ease;
  }
  .admin-login-icon:hover::after, .admin-login-icon:focus-visible::after { opacity: 1; transform: translateY(0); }
}
@media (max-width: 1199.98px) { .header-right .theme-btn { display: none; } }
.admin-login-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  background-color: var(--theme-color) !important; color: #fff !important;
}
.admin-login-btn i { font-size: 16px; }
.admin-login-btn:hover { background-color: var(--theme-color-2) !important; }
.footer-admin-btn { margin-top: 22px; }
.admin-login-item > a { font-weight: 700; }
.admin-login-item > a i { margin-right: 6px; }

/* website forms (enquiry.php) */
.hp-field { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.form-message { display: none; margin-top: 14px; padding: 10px 14px; border-radius: 8px; font-weight: 600; font-size: 15px; line-height: 1.4; }
.form-message.success, .form-message.error { display: block; }
.form-message.success { background: #e6f7ec; color: #0a7d3c; }
.form-message.error { background: #fdeaea; color: #b42318; }
