/* Popup overlay */
.popup-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.7);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 9999;
}

/* Popup box */
.popup-content {
  position: relative;
  background: #fff;
  max-width: 400px;
  width: 90%;
  border-radius: 8px;
  overflow: hidden;
  text-align: center;
  box-shadow: 0 20px 40px rgba(0,0,0,0.4);
}

/* Image */
.popup-image {
  width: 100%;
  height: auto;
  display: block;
}

/* Register button */
.popup-register {
  display: block;
  background: #cfa45c; /* gold tone – tweak if needed */
  color: #000;
  text-decoration: none;
  font-weight: 700;
  padding: 14px;
  font-size: 16px;
}

.popup-register:hover {
  background: #b8924f;
}

/* Close button */
.popup-close {
  position: absolute;
  top: 6px;
  right: 10px;
	color: #fff;
  background: none;
  border: none;
  font-size: 28px;
  cursor: pointer;
  line-height: 1;
}
/* == Language Selector == */
#gtranslate {
	position: fixed;
	left: 0;
	bottom: 0;
	top: 150px;
	z-index: 9999;
}
#gtranslate-tab {
	position: fixed;
	right: 15px;
	float: right;
	cursor: pointer;
	text-align: center;
	width: 60px;
	height: 60px;
	background-color: #fff;
	border-radius: 50%;
	border: solid 4px #2e59d7;
}
#gtranslate-tab svg {
	padding-top: 22px;
}
#gtranslate-tab:hover {
	background-color: #2e59d7;
	border: solid 4px #2e59d7;
}
#gtranslate-tab:hover .fa-language {
	color: #fff;
}
#gtranslate-form {
	position: fixed;
	float: right;
	background-color: transparent;
	width: 167px;
	margin-right: 80px;
	margin-top: 28px;
	right: 0;
	height: inherit;
	z-index: 9999 !important;
	padding-left: 5px;
	padding-right: 10px;
	-moz-border-radius: 0;
	-webkit-border-radius: 0;
	border-radius: 0;
}
.fa-language {
	margin-top: 3px;
}

#twitter {
	position: fixed;
	left: 0;
	bottom: 0;
	top: 220px;
	z-index: 9999;
}
#twitter-tab {
	position: fixed;
	right: 15px;
	float: right;
	cursor: pointer;
	text-align: center;
	width: 60px;
	height: 60px;
	background-color: #fff;
	border-radius: 50%;
	border: solid 4px #2e59d7;
}
#twitter-tab svg {
	padding-top: 22px;
}
#twitter-tab:hover {
	background-color: #2e59d7;
	border: solid 4px #2e59d7;
}
#twitter-tab:hover .fa-brands {
	color: #fff;
}
.fa-brands {
	margin-top: 11px;
}

/* == Site Search Button == */
#sitesearch {
	position: fixed;
	left: 0;
	top: 80px;
	bottom: 0;
	z-index: 9999;
}
#sitesearch-tab {
	position: fixed;
	right: 15px;
	float: right;
	cursor: pointer;
	text-align: center;
	width: 60px;
	height: 60px;
	background-color: #fff;
	border-radius: 50%;
	border: solid 4px #2e59d7;
}
#sitesearch-tab svg {
	margin-top: 9px;
	padding: 15px;
	color: #fff;
}
#sitesearch-form {
	position: fixed;
	float: right;
	background-color: transparent;
	width: 167px;
	margin-right: 75px;
	margin-top: 25px;
	right: 0;
	height: inherit;
	z-index: 9999 !important;
	padding-left: 5px;
	padding-right: 10px;
	background-clip: 'padding-box';
	-moz-border-radius: 0;
	-webkit-border-radius: 0;
	border-radius: 0;
}
#sitesearch-tab svg {
	padding-top: 22px;
	color: #26AF61 !important;
}
#sitesearch-tab:hover {
	background-color: #2e59d7;
	border: solid 4px #2e59d7;
}

#sitesearch-tab:hover .fa-search {
	color: #fff;
}
.fa-search {
	margin-top: 3px;
	padding-top: 8px;
}

.fas {
}
.fa-search {
	color: #2e59d7;
}
.fa-language {
	color: #2e59d7;
	padding-top: 8px;
}
#facebook,
#instagram {
  position: fixed;
  left: 0;
  z-index: 9999;
}

#facebook { top: 290px; }
#instagram { top: 360px; }

#facebook-tab,
#instagram-tab {
  position: fixed;
  right: 15px;
  width: 60px;
  height: 60px;
  background: #fff;
  border-radius: 50%;
  border: solid 4px #2e59d7;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

#facebook-tab:hover,
#instagram-tab:hover {
  background: #2e59d7;
}

#facebook-tab:hover .fa-brands,
#instagram-tab:hover .fa-brands {
  color: #fff;
}
.fa-x-twitter {
	color: #2e59d7;
}
	
.fa-facebook-f {
	margin-top: 0;
	color: #2e59d7;
}
.fa-instagram {
	margin-top: 0;
	color: #2e59d7;
}
/* === HOMEPAGE CAROUSEL � TRUE CROSSFADE === */
/* == Homepage Slideshow == */
.slideshow-box:before {
    content: "";
    display: block;
    position: absolute;
    width: 100%;
    height: 300px;
    background: url(/webcontent/webimage/menu-overlay.png) repeat-x top left;
    top: 0;
    left: 0;
	z-index: 1;
	transform: scale(1);
    transition: transform 0.8s ease;
}
.slideshow-box:after {
    content: "";
    display: block;
    position: absolute;
    width: 100%;
    height: 100%;
    background: url(/webcontent/webimage/home-slider-mask-new1.png) repeat-x bottom left;
    bottom: 0;
    left: 0;
	z-index: 1;
}
.slideshow-box {
	height: 90vh;
	width: 100%;
	position: relative;
	margin-top: 80px;
}
#slide-1 { background-image: url("/webcontent/webimage/open-new1.png"); }
#slide-2 { background-image: url("/webcontent/webimage/img_8888.jpg"); background-position: 40% 50%; }
#slide-3 { background-image: url("/webcontent/webimage/home-slide-4.jpg"); background-position: 40% 50%; }
#slide-4 { background-image: url("/webcontent/webimage/img_8913.jpg"); background-position: 40% 50%; }
#slide-5 { background-image: url("/webcontent/webimage/img_8354.jpg"); }
#slide-6 { background-image: url("/webcontent/webimage/img_8643.jpg"); }
#slide-7 { background-image: url("/webcontent/webimage/img_9029.jpg"); }
.fill {
	width: 95%;
	height: 90vh;
	background-position: center top;
	background-size: cover;
	background-repeat: no-repeat;
}
#myCarousel {
	position: relative;
	width: 100%;
	z-index:0;
}
.carousel-inner {
	height: 100%;
}
.carousel-fade .carousel-inner .item {
	opacity: 0;
	transition-property: opacity;
}
.carousel-fade .carousel-inner .active {
	opacity: 1;
}
.carousel-fade .carousel-inner .active.left,
.carousel-fade .carousel-inner .active.right {
	left: 0;
	opacity: 0;
	z-index: 1;
}
.carousel-fade .carousel-inner .next.left,
.carousel-fade .carousel-inner .prev.right {
	opacity: 1;
}
.carousel-fade .carousel-control {
	z-index: 2;
}
@media all and (transform-3d), (-webkit-transform-3d) {
	.carousel-fade .carousel-inner > .item.next,
	.carousel-fade .carousel-inner > .item.active.right {
		opacity: 0;
		-webkit-transform: translate3d(0, 0, 0);
		transform: translate3d(0, 0, 0);
	}
	.carousel-fade .carousel-inner > .item.prev,
	.carousel-fade .carousel-inner > .item.active.left {
		opacity: 0;
		-webkit-transform: translate3d(0, 0, 0);
		transform: translate3d(0, 0, 0);
	}
	.carousel-fade .carousel-inner > .item.next.left,
	.carousel-fade .carousel-inner > .item.prev.right,
	.carousel-fade .carousel-inner > .item.active {
		opacity: 1;
		-webkit-transform: translate3d(0, 0, 0);
		transform: translate3d(0, 0, 0);
	}
}
.carousel-caption {
	bottom: 25vh;
}
.carousel-caption h1 {
	text-transform: uppercase;
}
.carousel-caption h1 small {
	color: #fff;
	text-transform: lowercase;
}
/* === welcome message on carousel === */
.welcome-message-home {
	position: absolute;
	left:0;
	right: 0;
	bottom: 45px;
	margin: 0 auto;
	z-index: 5;
	background-color: rgba(46, 89, 215, 0.3);
}
.welcome-message-home h2 span {
	color: #fff;
	font-size: 3.0vw;
	text-align: center;
	font-weight: 500;
}
.welcome-message-home h2 {
	color: #fff;
	font-size: 2.0vw;
	text-align: center;
	font-weight: 200!important;
}

/* === FEATURE BOXES === */
#feature-boxes {
  padding: 40px 0; background: #fff; text-align: center;
}
.feature-box {
  background-size: cover; background-position: center;
  height: 220px; position: relative; overflow: hidden;
  transition: all 0.4s ease; margin-bottom: 20px;
}
.feature-box a {
  color: #fff; text-decoration: none;
  position: absolute; top: 0; left: 0; width: 100%; height: 100%;
  background: rgba(0,0,0,0.35);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.4em; font-weight: 600; text-transform: uppercase;
  transition: all 0.4s ease;
}
.feature-box:hover {
  filter: grayscale(100%);
  transform: scale(1.05);
}
.feature-box:hover a {
  background: rgba(0,0,0,0.55);
}

/* === SIDE PANEL === */
#side-panel {
  position: fixed;
  left: -260px;                   /* wider to match tab */
  bottom: 50%;
  transform: translateY(50%);     /* vertically centres panel */
  width: 260px;
  background: #2e59d7;
  color: #fff;
  z-index: 9999;
  transition: left 0.3s ease;
  padding: 7px 20px 7px 30px;   /* space from tab */
  border-radius: 0 0 0 0;
  display: flex;
  flex-direction: column;
  justify-content: center;        /* vertically centres content */
}

#side-panel.open {
  left: 0;
}

/* Semicircle toggle button */
#panel-toggle {
  position: absolute;
  right: -50px;
  top: 50%;
  transform: translateY(-50%);    /* aligns perfectly with panel */
  width: 50px;
  height: 80px;
  background: #2e59d7;
  border: none;
  color: #fff;
  border-radius: 0 40px 40px 0;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  animation: pulseTab 2s ease-in-out infinite;
  z-index: 10000;
}

#panel-toggle i {
  font-size: 22px;
  color: #fff;
}

#panel-toggle:hover i {
  color: #002263;
}

/* Pulse animation */
@keyframes pulseTab {
  0%   { transform: translateY(-50%) scale(1); }
  50%  { transform: translateY(-50%) scale(1.06); }
  100% { transform: translateY(-50%) scale(1); }
}
/* Stop pulsing when panel is open */
#side-panel.open #panel-toggle {
    animation: none !important;
    transform: translateY(-50%) scale(1) !important;
}

/* Hide on mobile */
@media (max-width: 768px) {
  #side-panel { display: none; }
}

#side-panel a {
  color: #fff !important;
}


/* === RIGHT SLIDE-IN CONTACT PANEL === */
#contact-panel {
  position: fixed;
  top: 0;
  right: -400px;
  width: 360px;
  height: 100%;
  background: #021c41;
  color: #fff;
  z-index: 9999;
  transition: right .4s ease;
  padding: 30px 20px;
  box-shadow: -3px 0 10px rgba(0,0,0,.3);
}
#contact-panel.open { right: 0; }

#contact-close {
  position: absolute;
  top: 10px;
  right: 10px;
  background: transparent;
  border: none;
  color: #fff;
  font-size: 20px;
}
#contact-panel h3 {
  margin-top: 40px;
  font-weight: 600;
  text-align: center;
}
#contact-panel .form-control {
  margin-bottom: 15px;
  border-radius: 4px;
  border: none;
  box-shadow: none;
}
#contact-panel .btn-primary {
  background: #fff;
  color: #0164ff;
  border: none;
  font-weight: 600;
  transition: background .3s ease;
}
#contact-panel .btn-primary:hover {
  background: #e9e9e9;
}
/* === SUCCESS OVERLAY === */
#success-overlay {
  position: fixed;
  top: -100px;
  left: 0;
  width: 100%;
  background: #28a745;
  color: #fff;
  text-align: center;
  padding: 20px;
  z-index: 10000;
  transition: top 0.6s ease;
}
#success-overlay.visible {
  top: 0;
}
#success-overlay .success-box {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}
#success-overlay i {
  font-size: 22px;
}

/* === FEATURE BOX FIX === */
#feature-boxes a { cursor: pointer; }

/* Mobile */
@media (max-width: 768px){
  #contact-panel { width: 100%; right: -100%; }
}

/* ==============================
   HOUSEPOINTS
================================ */
.housepoints { margin: 60px 0 40px; }
.housepoints a { text-decoration: none; }
.housepoints h2 {
  color: var(--pink);
  font-weight: 900;
}

.sl-housepoints {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 20px;
  padding: 0 10px;
}

.sl-hp-entry {
  flex: 1 1 calc(25% - 20px);
  max-width: 25%;
  min-width: 220px;
  padding: 20px;
  text-align: center;
}
.sl-hp-house {
  font-weight: bold;
  font-size: 1.5em;
  margin-top: 10px;
}
.sl-hp-points {
  font-size: 2em;
  margin-top: 10px;
}
/* Housepoints: place markers (1st/2nd/3rd/4th) */
.sl-hp-entry { 
  position: relative; 
  overflow: visible; /* ensure the badge can sit above the box */
	background-color: #fff;
	padding-top: 20px;
}

.place-label {
  position: absolute;
  top: 35px;                 /* anchor at top edge of the box */
  left: 50%;
  transform: translate(-50%, -110%); /* sit above and centred */
  background: #ffd700;    /* gold badge */
  color: #000;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 12px;
  font-size: 0.9em;
  line-height: 1;
  z-index: 10;            /* above winner pulse and content */
  display: none;          /* toggled by .show */
  box-shadow: 0 2px 6px rgba(0,0,0,.15);
}

/* little pointer under the badge */
.place-label::after {
  content: "";
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  bottom: -6px;
  border: 6px solid transparent;
  border-top-color: #ffd700;
}

/* show state (set by JS) */
.place-label.show { 
  display: inline-block;
  animation: fadeInLabel 0.5s ease-in forwards;
}

/* keep it tidy on small screens */
@media (max-width: 575px) {
  .place-label {
    font-size: 0.8em;
    transform: translate(-50%, -115%);
  }
}

/* Winner highlight */
.sl-hp-entry.winner::before { animation: pulse-winner 1.5s infinite; }
@keyframes pulse-winner {
  0% { transform: scale(1); }
  50% { transform: scale(1.1); }
  100% { transform: scale(1); }
}

/* Housepoint images */
[data-housename="Livingstone"]::before,
[data-housename="Nightingale"]::before,
[data-housename="Scott"]::before {
    content: "";
    display: inline-block;
    width: 120px;
    height: 120px;
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    margin: 20px auto;
}

[data-housename="Livingstone"]::before {
    background-image: url('/webcontent/webimage/livingstone.png');
}
[data-housename="Nightingale"]::before {
    background-image: url('/webcontent/webimage/nightingale.png');
}
[data-housename="Scott"]::before {
    background-image: url('/webcontent/webimage/scott.png');
}


/* House-specific colours */
[data-housename="Livingstone"] .sl-hp-house { color: #a92122; }
[data-housename="Nightingale"] .sl-hp-house { color: #f0aa3b; }
[data-housename="Scott"] .sl-hp-house { color: #589a51; }

.housepoints-row h2 {
	
  font-family: "Quicksand", sans-serif;
	margin-bottom: -20px;
	color: #fff!important;
}
.housepoints-row a:hover {
	text-decoration: none!important;
}
.housepoints-row {
	background-color: #2e59d7;
}
/* =========================
   HERO VIDEO – WITH SIDE SPACE
========================= */

/* Let Bootstrap container-fluid be 100% wide, no tricks */
.hero-video{
  position: relative;
  width: 100%;
  height: auto;           /* let the frame control height */
  margin-left: 0;
  overflow: visible;
  background: transparent;
  padding: 0;             /* keep container clean */
}

/* This is the “boxed” area with left/right spacing */
.hero-video__inner{
  position: relative;
  max-width: 1400px;      /* adjust to taste */
  margin: 0 auto;
  padding: 0 0;        /* <<< LEFT/RIGHT SPACE */
}

/* Keep aspect ratio */
.hero-video__frame{
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: #000;
}

/* Fill the box */
.hero-video__frame iframe{
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

/* Overlay covers only the boxed video */
.hero-video__inner .video-overlay{
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.15);
  z-index: 2;
  pointer-events: none;
}

/* Welcome text sits over the boxed video */
.hero-video__inner .welcome-message-home{
  position: absolute;
  z-index: 3;
  left: 0;
  right: 0;
  bottom: 45px;           /* keep your preferred positioning */
}

/* Mobile spacing */
@media (max-width: 768px){
  .hero-video__inner{
    padding: 0 15px;      /* smaller side space on mobile */
  }
}

.hero-video iframe{
  pointer-events: none;
}


/* === SPLIT CAROUSEL (FIXED) === */

.split-carousel {
  position: relative;
  min-height: 420px;
	margin-left:-15px;
}

/* Each slide must be a positioning context */
.split-carousel .item {
  position: relative;
  height: 420px;
}

/* Background image layer */
.split-carousel .fill {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center;
  z-index: 1;
}

/* Text overlay */
.carousel-text {
  position: absolute;
  bottom: 30px;
  left: 30px;
  right: 30px;
  z-index: 3;
  background: rgba(46, 89, 215, 0.75);
  padding: 20px 25px;
  color: #fff;
}

.carousel-text h3 {
  margin: 0 0 6px;
  color: #fff !important;
}

.carousel-text p {
	font-size: 20px;
	font-weight: 900;
  margin: 0;
  color: #fff;
}

/* Mobile */
@media (max-width: 768px) {
  .split-carousel .item {
    height: 300px;
  }

  .carousel-text {
    bottom: 20px;
    left: 20px;
    right: 20px;
    padding: 15px;
  }
}
/* Prevent slide stacking flash during fade */
.split-carousel .carousel-inner {
  position: relative;
  height: 420px;
  overflow: hidden;
}

.split-carousel .carousel-inner > .item {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.split-content {
	margin-right: -15px;
    padding-right: 0px;
}
.page-paragraph h1 {
	margin-top: 0px;
}

#mainbody {
	margin-bottom: 0px;
}
/* Fix header + nav as one unit (stops overlay creep / thick bar) */
#header-stack{
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 9999;
  background: #fff;
}

/* Remove Bootstrap navbar spacing/borders that can show as a line */
#header-stack .navbar{
  margin: 0 !important;
  border: 0 !important;
  box-shadow: none !important;
}

/* Lock welcome header so it doesn't jump */
.welcome-header{
  margin: 0 !important;
  background: #2e59d7;
  padding: 14px 15px;
}
.welcome-header h3{
  margin: 0 !important;
  line-height: 1.2;
}

/* Push page content down so hero video starts UNDER the fixed header stack */
body{
  padding-top: 120px; /* adjust if needed (see note below) */
}

/* Make sure the video/overlay never sits above the header */
.hero-video,
.hero-video iframe,
.hero-video .video-overlay{
  z-index: 1;
}
/* HERO VIDEO: keep aspect ratio on all devices */
.hero-video{
  position: relative;
  overflow: hidden;
	margin-top: -10px;
}

/* 16:9 container (change to 56.25% if you prefer the padding method) */
.hero-video__frame{
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;  /* keeps the ratio */
}

/* If you want it to behave like a hero section, give it a minimum height */
@media (max-width: 767px){
  .hero-video__frame{
    min-height: 220px;   /* tweak to taste */
  }
}

/* Make the iframe fill the ratio box */
.hero-video__frame iframe{
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

/* Ensure your overlay sits above the video */
.hero-video .video-overlay{
  position: absolute;
  inset: 0;
  z-index: 2;
}

/* Ensure text sits above overlay */
.hero-video .welcome-message-home{
  position: absolute;
  z-index: 3;
  left: 0;
  right: 0;
  /* keep your existing positioning here */
}
/* iPhone fix: force true 16:9 sizing (no extra height = no black bars) */
.hero-video { height: auto !important; }

.hero-video__frame{
  aspect-ratio: 16 / 9;
  height: auto !important;
  min-height: 0 !important;
  background: transparent !important;
}
.content-split {
	padding-right: 0px;
}