/* ==================================================
   PAGES-PRIMARY CSS
   Purpose:
   - Highlights
   - Cards (grid-3, grid-4)
   - Mission & Vision grids
   - Headteacher Message
   - Gallery previews
   - Page Hero Images
   ================================================== */

.page-hero {
  width: 100%;
  max-width: 1200px;
  margin: 30px auto;
  height: 420px;
  border-radius: 18px;
  overflow: hidden;
}

.page-hero img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

@media (max-width: 992px) { .page-hero { height: 300px; } }
@media (max-width: 600px) { .page-hero { height: 200px; border-radius: 12px; } }

/* ================= HIGHLIGHTS SECTION ================= */
.highlights {
  padding: 50px 20px;
  background: #f9f9f9;
}

.highlights .container.grid-3 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 25px;
}

.highlights .card {
  background: #ffffff;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 5px 15px rgba(0,0,0,0.1);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
}

.highlights .card:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 25px rgba(0,0,0,0.15);
}

.highlights .card .image-box {
  height: 180px;
  overflow: hidden;
  border-radius: 12px 12px 0 0;
}

.highlights .card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.highlights .card img:hover {
  transform: scale(1.05);
}

.highlights .card h3 {
  padding: 15px;
  font-size: 1.2rem;
  color: var(--primary);
}

.highlights .card p {
  padding: 0 15px 15px 15px;
  font-size: 0.95rem;
  color: #555;
  line-height: 1.5;
}

/* ================= FEATURES SECTION ================= */

.features {
  max-width: 1200px;
  margin: 0 auto;
  padding: 60px 20px;
}

/* Card grid */
.features .cards {
  display: grid;
  grid-template-columns: repeat(4, 1fr); /* Desktop: 4 cards */
  gap: 30px;
}

/* Individual card */
.features .card {
  background: #ffffff;
  border-radius: 14px;
  padding: 20px;
  box-shadow: 0 8px 20px rgba(0,0,0,0.08);
  display: flex;
  flex-direction: column;
}

/* Image container */
.features .image-box {
  width: 100%;
  height: 220px;
  border-radius: 12px;
  overflow: hidden;
  margin-bottom: 15px;
}

/* Image sizing fix */
.features .image-box img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Headings */
.features .card h4 {
  color: var(--primary);
  margin-bottom: 10px;
  font-size: 1.1rem;
}

/* Text */
.features .card p {
  font-size: 0.95rem;
  line-height: 1.6;
  color: #444;
}

/* ================= FEATURES SECTION ================= */

.features {
  max-width: 1200px;
  margin: 0 auto;
  padding: 60px 20px;
}

/* Card grid */
.features .cards {
  display: grid;
  grid-template-columns: repeat(4, 1fr); /* Desktop: 4 cards */
  gap: 30px;
}

/* Individual card */
.features .card {
  background: #ffffff;
  border-radius: 14px;
  padding: 20px;
  box-shadow: 0 8px 20px rgba(0,0,0,0.08);
  display: flex;
  flex-direction: column;
}

/* Image container */
.features .image-box {
  width: 100%;
  height: 220px;
  border-radius: 12px;
  overflow: hidden;
  margin-bottom: 15px;
}

/* Image sizing fix */
.features .image-box img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Headings */
.features .card h4 {
  color: var(--primary);
  margin-bottom: 10px;
  font-size: 1.1rem;
}

/* Text */
.features .card p {
  font-size: 0.95rem;
  line-height: 1.6;
  color: #444;
}

/* ===== Tablet: 2 cards per row ===== */
@media (max-width: 992px) {
  .features .cards {
    grid-template-columns: repeat(2, 1fr);
  }

  .features .image-box {
    height: 200px;
  }
}

/* ===== Mobile: 1 card per row ===== */
@media (max-width: 576px) {
  .features .cards {
    grid-template-columns: 1fr;
  }

  .features .image-box {
    height: 180px;
  }

  .features .card {
    padding: 18px;
  }
}


/* ================= MISSION & VISION GRID ================= */
.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 30px;
  margin: 40px 0;
}

.info-box {
  background: #f8f8f8;
  padding: 25px 20px;
  border-radius: 15px;
  text-align: center;
  box-shadow: 0 8px 20px rgba(0,0,0,0.08);
  transition: transform 0.3s ease, box-shadow 0.3s ease, background 0.3s ease;
}

.info-box:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 30px rgba(0,0,0,0.12);
  background: #e2e6f2;
}

.info-box h3 {
  font-size: 1.5rem;
  color: var(--primary);
  margin-bottom: 15px;
}

.info-box p {
  font-size: 1rem;
  line-height: 1.7;
  color: #333;
}

/* ==================================================
   FEATURES SECTION (CARDS)
   ================================================== */

.features-section {
  padding: 70px 20px;
  background: #f8f9fc;
}

/* ================= GRID ================= */
.features-grid {
  max-width: 1200px;
  margin: auto;
  display: grid;
  grid-template-columns: 1fr;
  gap: 30px;
}

/* Tablet */
@media (min-width: 640px) {
  .features-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Desktop */
@media (min-width: 992px) {
  .features-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

/* ================= CARD ================= */
.feature-item {
  background: #ffffff;
  border-radius: 18px;
  overflow: hidden;
  text-align: center;
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.12);
  transition: transform 0.35s ease, box-shadow 0.35s ease;
  display: flex;
  flex-direction: column;
}

.feature-item:hover {
  transform: translateY(-10px);
  box-shadow: 0 22px 55px rgba(0, 0, 0, 0.18);
}

/* ================= IMAGE ================= */
.feature-image {
  width: 100%;
  aspect-ratio: 16 / 9; /* perfect image ratio */
  overflow: hidden;
  background: #eaeaea;
}

.feature-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.feature-item:hover .feature-image img {
  transform: scale(1.1);
}

/* ================= TEXT ================= */
.feature-item h4 {
  font-size: 1.1rem;
  margin: 18px 16px 8px;
  color: #2b2f66;
}

.feature-item p {
  font-size: 0.95rem;
  line-height: 1.6;
  color: #555;
  padding: 0 18px 22px;
}

/* ================= MOBILE REFINEMENT ================= */
@media (max-width: 480px) {
  .features-section {
    padding: 50px 16px;
  }

  .feature-item h4 {
    font-size: 1.05rem;
  }

  .feature-item p {
    font-size: 0.9rem;
  }
}

/* ================= ACCESSIBILITY ================= */
.feature-item img {
  display: block;
  max-width: 100%;
  height: auto;
}

/* ================= SUBTLE ENTRANCE ANIMATION ================= */
.feature-item {
  animation: featureFade 0.6s ease both;
}

@keyframes featureFade {
  from {
    opacity: 0;
    transform: translateY(15px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ================= HEADTEACHER MESSAGE ================= */
.headteacher-message {
  max-width: 1100px;
  margin: 60px auto;
  padding: 30px;
  display: flex;
  gap: 40px;
  align-items: flex-start;
  background: #ffffff;
}

.headteacher-image {
  flex: 0 0 260px;
}

.headteacher-image img {
  width: 100%;
  height: 320px;
  object-fit: cover;
  border-radius: 16px;
  display: block;
  box-shadow: 0 10px 30px rgba(0,0,0,0.12);
}

.headteacher-message .message {
  flex: 1;
}

.headteacher-message h1 {
  font-size: 1.8rem;
  color: var(--primary);
  margin-bottom: 10px;
}

.headteacher-message h3 {
  font-size: 1.1rem;
  color: #444;
  margin-bottom: 15px;
}

.headteacher-message p {
  font-size: 1rem;
  line-height: 1.7;
  color: #555;
  margin-bottom: 15px;
}

.signature {
  margin-top: 25px;
  font-style: italic;
  color: #333;
}

.signature-name {
  margin-top: 5px;
  font-weight: 700;
  color: var(--primary);
}

.signature-role {
  font-weight: normal;
  color: #666;
}
/* ================= FOOTER ================= */

.site-footer {
  background: var(--secondary);
  color: #ffffff;
  padding: 70px 20px 30px;
  font-size: 14px;
}

/* ================= LAYOUT ================= */

.footer-content {
  max-width: 1200px;
  margin: auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 45px;
  text-align: center;
}

/* ================= COLUMNS ================= */

.footer-col {
  animation: footerFadeUp 0.8s ease forwards;
}

/* Headings */
.footer-col h4 {
  color: #ffffff;
  font-size: 16px;
  margin-bottom: 15px;
  letter-spacing: 0.5px;
}

/* Paragraphs */
.footer-col p {
  color: #ffffff;
  line-height: 1.7;
  margin-bottom: 10px;
  opacity: 0.9;
}

/* ================= BRAND ================= */

.footer-brand img {
  max-height: 70px;
  margin-bottom: 15px;
  transition: transform 0.4s ease;
}

.footer-brand img:hover {
  transform: scale(1.08);
}

.footer-brand {
  text-align: center;
}

.footer-brand img {
  display: block;
  margin: 0 auto 15px;
}


/* ================= QUICK LINKS ================= */

.footer-links ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-links li {
  margin-bottom: 10px;
}

.footer-links a {
  color: #ffffff;
  text-decoration: none;
  position: relative;
  transition: all 0.3s ease;
}

/* Arrow animation */
.footer-links a::before {
  content: "›";
  position: absolute;
  left: -15px;
  opacity: 0;
  transition: all 0.3s ease;
}

.footer-links a:hover {
  color: var(--accent);
  padding-left: 10px;
}

.footer-links a:hover::before {
  opacity: 1;
  left: 0;
}

/* ================= CONTACT LINKS ================= */

.footer-contact a {
  color: #ffffff;
  text-decoration: none;
  transition: color 0.3s ease;
}

.footer-contact a:hover {
  color: var(--accent);
}

/* ================= SOCIAL ICONS ================= */

.social-icons {
  margin-top: 15px;
  display: flex;
  justify-content: center;
  gap: 12px;
}

.social-icons a {
  width: 40px;
  height: 40px;
  background: rgba(255,255,255,0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  color: #ffffff;
  font-size: 16px;
  transition: all 0.3s ease;
}

.social-icons a:hover {
  background: var(--accent);
  color: var(--secondary);
  transform: translateY(-4px) scale(1.1);
}

/* ================= NEWSLETTER ================= */

.footer-newsletter form {
  display: flex;
  flex-direction: column;
  gap: 12px;
  align-items: center;
}

.footer-newsletter input {
  width: 100%;
  max-width: 260px;
  padding: 12px 16px;
  border-radius: 30px;
  border: none;
  outline: none;
  font-size: 14px;
}

.footer-newsletter button {
  background: var(--accent);
  color: var(--secondary);
  border: none;
  padding: 12px 26px;
  border-radius: 30px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  transition: all 0.3s ease;
}

.footer-newsletter button:hover {
  background: #ffffff;
  color: var(--secondary);
  transform: translateY(-3px);
}

/* ================= FOOTER BOTTOM ================= */

.footer-bottom {
  margin-top: 45px;
  padding-top: 20px;
  border-top: 1px solid rgba(255,255,255,0.2);
  text-align: center;
}

.footer-bottom p {
  color: #ffffff;
  font-size: 13px;
  opacity: 0.85;
}

/* ================= ANIMATION ================= */

@keyframes footerFadeUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ================= RESPONSIVE ================= */

@media (max-width: 768px) {
  .footer-content {
    gap: 35px;
  }
}

