/* ==========================================================================
   Luminar English — pages.css
   Page-specific styles
   ========================================================================== */

/* ---------- Home ---------- */
@media (min-width: 1024px) {
  .home-hero .hero-grid {
    grid-template-columns: 1.12fr 1fr;
  }
}
.home-hero .hero-title {
  font-size: clamp(30px, 3.9vw, 54px);
}
@media (max-width: 1023px) {
  .home-hero .hero-title {
    font-size: clamp(30px, 6.2vw, 48px);
  }
}
@media (min-width: 600px) {
  .home-hero .hero-title .l1,
  .home-hero .hero-title .l2 {
    white-space: nowrap;
  }
}
.home-hero .hero-title .l1 {
  color: var(--navy);
}
.home-hero .hero-title .l2 {
  color: var(--red);
}
.home-hero .features {
  max-width: 560px;
}
/* Tilted handwriting above the title. inline-block + bottom-left origin: the tilt only lifts the
   right end; a full-width box rotated about its centre dropped the left end onto the title */
.home-hero .hero-kicker {
  display: inline-block;
  margin-bottom: 22px;
  font-size: clamp(22px, 2.6vw, 32px);
  line-height: 1.25;
  transform: rotate(-4deg);
  transform-origin: left bottom;
}
.hero-tagline {
  margin-top: 10px;
  font-size: clamp(18px, 2vw, 24px);
  font-weight: 700;
  color: var(--navy);
}
.decor-crown,
.decor-plane {
  position: absolute;
  color: var(--gold);
  font-size: 34px;
  pointer-events: none;
}
.decor-plane {
  color: var(--red);
}

/* ---------- Teachers page ---------- */
.teachers-hero .features {
  margin-top: 36px;
}
.view-all {
  display: flex;
  justify-content: center;
  margin-top: 28px;
}

/* ---------- Tables (programme roadmap) ---------- */
.roadmap {
  display: grid;
  grid-template-columns: repeat(var(--steps, 4), minmax(0, 1fr));
  gap: 16px;
  counter-reset: step;
}
.roadmap-step {
  position: relative;
  padding: 22px 18px 20px;
  border: 1px solid color-mix(in srgb, var(--c, var(--red)) 18%, #fff);
  border-radius: var(--r);
  background: #fff;
  box-shadow: var(--sh-sm);
}
.roadmap-step::before {
  counter-increment: step;
  content: counter(step);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  margin-bottom: 12px;
  border-radius: 50%;
  background: var(--c-grad, var(--red));
  color: #fff;
  font-weight: 800;
}
.roadmap-step h4 {
  margin-bottom: 6px;
  font-size: 16px;
  font-weight: 800;
  color: var(--c, var(--red));
}
.roadmap-step p {
  font-size: 14px;
}
.roadmap-step .tag {
  margin-bottom: 8px;
}
@media (max-width: 1023px) {
  .roadmap {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 599px) {
  .roadmap {
    grid-template-columns: 1fr;
  }
}

.program-panel {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 36px;
  align-items: center;
  margin-bottom: 36px;
}
.program-panel h3 {
  font-size: clamp(24px, 3vw, 32px);
  font-weight: 900;
  color: var(--c);
  text-transform: uppercase;
}
.program-panel .lead {
  margin: 10px 0 18px;
  font-size: 16px;
}
.program-photo {
  position: relative;
  overflow: hidden;
  aspect-ratio: 4 / 3;
  border: 6px solid #fff;
  border-radius: var(--r-xl);
  box-shadow: var(--sh-lg);
}
.program-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.info-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 20px;
}
.info-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: var(--r-pill);
  background: var(--c-50);
  color: var(--c-700);
  font-size: 13.5px;
  font-weight: 700;
}
.info-chip .icon {
  font-size: 18px;
}
@media (max-width: 1023px) {
  .program-panel {
    grid-template-columns: 1fr;
  }
}

.skills {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}
.skill {
  padding: 22px 16px;
  border: 1px solid var(--line);
  border-radius: var(--r);
  background: #fff;
  text-align: center;
  box-shadow: var(--sh-sm);
}
.skill .why-icon {
  margin: 0 auto 12px;
}
.skill h4 {
  margin-bottom: 4px;
  font-size: 16px;
  font-weight: 800;
  color: var(--red);
}
.skill p {
  font-size: 13.5px;
}
@media (max-width: 767px) {
  .skills {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* ---------- Course detail pages ---------- */
.course-hero .hero-title .l1 {
  color: var(--c);
}
.target-schools {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
}
.target-schools li {
  padding: 10px 18px;
  border: 1.5px solid color-mix(in srgb, var(--c, var(--red)) 30%, #fff);
  border-radius: var(--r-pill);
  background: #fff;
  color: var(--c-700, var(--red-700));
  font-size: 14px;
  font-weight: 700;
}
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 36px;
  align-items: start;
}
.form-card {
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  background: #fff;
  box-shadow: var(--sh);
}
.form-card h2,
.form-card h3 {
  margin-bottom: 6px;
  font-size: 22px;
  font-weight: 900;
  color: var(--red);
  text-transform: uppercase;
}
.form-card > p {
  margin-bottom: 18px;
  font-size: 14px;
}
@media (max-width: 1023px) {
  .split {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 599px) {
  .form-card {
    padding: 22px 18px;
  }
}
/* ---------- About page ---------- */
.about-intro {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
}
.about-collage {
  position: relative;
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  grid-template-rows: 1fr 1fr;
  gap: 14px;
  aspect-ratio: 1 / 0.9;
}
.about-collage img {
  width: 100%;
  height: 100%;
  border: 5px solid #fff;
  border-radius: var(--r-lg);
  object-fit: cover;
  box-shadow: var(--sh);
}
.about-collage img:first-child {
  grid-row: 1 / 3;
}
.about-badge {
  position: absolute;
  left: -14px;
  bottom: 20px;
  padding: 14px 18px;
  border-radius: var(--r);
  background: var(--red);
  color: #fff;
  box-shadow: var(--sh-lg);
  text-align: center;
}
.about-badge b {
  display: block;
  font-size: 34px;
  font-weight: 900;
  line-height: 1;
}
.about-badge span {
  font-size: 13px;
}
@media (max-width: 767px) {
  .about-badge {
    left: 8px;
    bottom: 12px;
  }
}
.prose p + p {
  margin-top: 14px;
}
.prose h2 {
  margin-bottom: 14px;
}
.mission-grid .why-card {
  flex-direction: column;
}
.timeline {
  position: relative;
  max-width: 900px;
  margin: 0 auto;
  padding-left: 34px;
}
.timeline::before {
  content: "";
  position: absolute;
  left: 11px;
  top: 6px;
  bottom: 6px;
  width: 3px;
  border-radius: 3px;
  background: linear-gradient(var(--red), var(--red-200));
}
.timeline-item {
  position: relative;
  padding: 0 0 28px;
}
.timeline-item::before {
  content: "";
  position: absolute;
  left: -30px;
  top: 4px;
  width: 18px;
  height: 18px;
  border: 4px solid #fff;
  border-radius: 50%;
  background: var(--red);
  box-shadow: 0 0 0 3px var(--red-200);
}
.timeline-item .year {
  display: inline-block;
  margin-bottom: 4px;
  font-size: 20px;
  font-weight: 900;
  color: var(--red);
}
.timeline-item h4 {
  margin-bottom: 4px;
  font-size: 17px;
  font-weight: 800;
}
.timeline-item p {
  font-size: 14.5px;
}
.model-box {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0;
  overflow: hidden;
  border-radius: var(--r-lg);
  box-shadow: var(--sh);
}
.model-box > div {
  padding: 30px 22px;
  background: #fff;
  text-align: center;
}
.model-box > div:nth-child(2) {
  background: var(--red);
  color: #fff;
}
.model-box > div:nth-child(2) h4,
.model-box > div:nth-child(2) b {
  color: #fff;
}
.model-box b {
  display: block;
  font-size: 46px;
  font-weight: 900;
  line-height: 1;
  color: var(--red);
}
.model-box h4 {
  margin: 8px 0 6px;
  font-size: 17px;
  font-weight: 800;
}
.model-box p {
  font-size: 14px;
}
@media (max-width: 1023px) {
  .about-intro {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 767px) {
  .model-box {
    grid-template-columns: 1fr;
  }
}

/* ---------- News ---------- */
.filter-bar {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-bottom: 32px;
}
.filter-bar button {
  min-height: 42px;
  padding: 8px 18px;
  border: 1.5px solid var(--red-200);
  border-radius: var(--r-pill);
  background: #fff;
  color: var(--red);
  font-size: 14px;
  font-weight: 700;
}
.filter-bar button[aria-pressed="true"] {
  border-color: var(--red);
  background: var(--red);
  color: #fff;
}
.news-card {
  display: flex;
  flex-direction: column;
  height: 100%;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  background: #fff;
  box-shadow: var(--sh-sm);
  transition: transform 0.25s var(--ease), box-shadow 0.25s;
}
.news-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--sh);
}
.news-card[hidden] {
  display: none;
}
.news-thumb {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
}
.news-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s var(--ease);
}
.news-card:hover .news-thumb img {
  transform: scale(1.05);
}
.news-thumb .tag {
  position: absolute;
  left: 14px;
  top: 14px;
  background: #fff;
}
.news-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 10px;
  padding: 18px 20px 22px;
}
.news-meta {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--muted);
}
.news-body h3 {
  font-size: 17px;
  font-weight: 800;
  line-height: 1.35;
}
.news-body h3 a:hover {
  color: var(--red);
}
.news-body p {
  font-size: 14px;
}
.news-body .link-arrow {
  margin-top: auto;
  font-size: 14px;
}
.news-featured {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  margin-bottom: 32px;
}
.news-featured .news-thumb {
  aspect-ratio: auto;
  min-height: 320px;
}
.news-featured .news-body {
  justify-content: center;
  padding: 32px;
}
.news-featured h3 {
  font-size: clamp(20px, 2.4vw, 26px);
}
@media (max-width: 767px) {
  .news-featured {
    grid-template-columns: 1fr;
  }
  .news-featured .news-thumb {
    min-height: 220px;
  }
  .news-featured .news-body {
    padding: 20px;
  }
}
/* News article */
.article {
  max-width: 800px;
  margin: 0 auto;
}
.article-cover {
  overflow: hidden;
  margin-bottom: 28px;
  border-radius: var(--r-lg);
  box-shadow: var(--sh);
}
.article-cover img {
  width: 100%;
  aspect-ratio: 16 / 8;
  object-fit: cover;
}
.article-content {
  font-size: 16.5px;
  line-height: 1.8;
}
.article-content h2 {
  margin: 32px 0 12px;
  font-size: 24px;
  font-weight: 800;
  color: var(--red);
}
.article-content h3 {
  margin: 24px 0 10px;
  font-size: 19px;
  font-weight: 800;
}
.article-content p,
.article-content ul,
.article-content ol {
  margin-bottom: 16px;
}
.article-content ul {
  padding-left: 22px;
  list-style: disc;
}
.article-content ol {
  padding-left: 22px;
  list-style: decimal;
}
.article-content li + li {
  margin-top: 6px;
}
.article-content blockquote {
  margin: 24px 0;
  padding: 18px 22px;
  border-left: 4px solid var(--red);
  border-radius: 0 var(--r) var(--r) 0;
  background: var(--red-50);
  font-style: italic;
  color: var(--red-800);
}
.article-content p a {
  color: var(--red);
  font-weight: 700;
  text-decoration: underline;
}
/* Photo gallery in an article: CSS columns keep every photo uncropped with portrait and landscape mixed;
   a click opens the full photo */
.article-gallery {
  columns: 3 150px;
  column-gap: 12px;
  margin: 8px 0 28px;
}
.article-gallery a {
  display: block;
  margin-bottom: 12px;
  overflow: hidden;
  break-inside: avoid;
  border-radius: var(--r);
  box-shadow: var(--sh-sm);
  background: var(--red-50);
}
.article-gallery img {
  width: 100%;
  transition: transform 0.3s var(--ease);
}
.article-gallery a:hover img {
  transform: scale(1.03);
}
.article-figure {
  margin: 8px 0 28px;
}
.article-figure img {
  width: 100%;
  border-radius: var(--r-lg);
  box-shadow: var(--sh);
}
.article-figure figcaption {
  margin-top: 8px;
  font-size: 14px;
  text-align: center;
  color: var(--muted);
}
.article-share {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-top: 30px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
  font-weight: 700;
}
.article-share .socials {
  flex-wrap: wrap;
  gap: 10px;
  margin: 0;
}
.article-share .socials a,
.article-share .socials button {
  background: var(--red-50);
}
.share-status {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--navy);
}
/* Share links are filled in by main.js: without it the buttons would do nothing */
html:not(.js) .article-share {
  display: none;
}

/* ---------- Contact ---------- */
.contact-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 32px;
  align-items: start;
}
.contact-list {
  display: grid;
  gap: 14px;
}
.contact-item {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--r);
  background: #fff;
  box-shadow: var(--sh-sm);
}
.contact-item h3 {
  margin-bottom: 2px;
  font-size: 15px;
  font-weight: 800;
  color: var(--red);
}
.contact-item p,
.contact-item a {
  font-size: 15px;
  color: var(--ink);
}
.contact-item a:hover {
  color: var(--red);
}
.map-wrap {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--sh-sm);
}
.map-wrap iframe {
  width: 100%;
  height: 380px;
  border: 0;
}
@media (max-width: 1023px) {
  .contact-grid {
    grid-template-columns: 1fr;
  }
  /* mobile: show the form before the contact list + map */
  .contact-grid > :last-child {
    order: -1;
  }
}

/* ---------- Thank-you & 404 ---------- */
.center-page {
  display: flex;
  align-items: center;
  min-height: calc(100vh - var(--header-h) - 120px);
  padding: 60px 0;
  background: linear-gradient(160deg, #fff 0%, #ffeef1 60%, #ffe1e6 100%);
  text-align: center;
}
.center-card {
  max-width: 640px;
  margin: 0 auto;
  padding: 44px 32px;
  border-radius: var(--r-xl);
  background: #fff;
  box-shadow: var(--sh-lg);
}
.center-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 84px;
  height: 84px;
  margin-bottom: 18px;
  border-radius: 50%;
  background: linear-gradient(135deg, #ff3a44, var(--red-700));
  color: #fff;
  box-shadow: 0 14px 30px rgba(227, 27, 35, 0.35);
}
.center-icon .icon {
  font-size: 42px;
  stroke-width: 2.6;
}
.center-card h1 {
  margin-bottom: 12px;
  font-size: clamp(26px, 3.4vw, 36px);
  font-weight: 900;
  color: var(--red);
}
.center-card p {
  color: var(--text);
}
.center-card .hero-actions {
  justify-content: center;
}
.big-404 {
  font-size: clamp(80px, 16vw, 150px);
  font-weight: 900;
  line-height: 1;
  background: linear-gradient(135deg, #ff3a44, var(--navy));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
