 :root{
    --ink:#12181B; --paper:#EAEBE3; --paper-2:#DFE1D6;
    --deep:#0B1420; --deep-2:#111D2B; --amber:#E0A526;
    --rust:#C1440E; --steel:#48606E;
    --line: rgba(18,24,27,0.14); --line-deep: rgba(234,235,227,0.16);
  }
  *{box-sizing:border-box;} html{scroll-behavior:smooth;}
  body{margin:0; background:var(--paper); color:var(--ink); font-family:'IBM Plex Sans', sans-serif; font-size:16px; line-height:1.55;}
  h1,h2,h3,.display{font-family:'Space Grotesk', sans-serif; font-weight:700; letter-spacing:-0.01em; margin:0;}
  .mono{font-family:'IBM Plex Mono', monospace;}
  a{color:inherit;} img{max-width:100%;display:block;}
  section{position:relative;}
  .wrap{max-width:1080px; margin:0 auto; padding:0 28px; position: relative;}
  @media (min-width:900px){.wrap{padding-left:96px;}}

  /* ---------- WELL-LOG RAIL ---------- */
  #rail{
    position:fixed; top:0; left:0; width:64px; height:100%; 
    background:transparent; z-index:200; display:none; 
    flex-direction:column; align-items:center; padding:20px 0; 
    mix-blend-mode: difference; color: white;
  }
  @media (min-width:900px){ #rail{display:flex;} }
  #rail .brand-mark{
    color:white; font-family:'IBM Plex Mono',monospace; 
    font-size:11px; writing-mode:vertical-rl; letter-spacing:0.12em; 
    margin-bottom:18px;
  }
  #rail .track{
    position:relative; flex:1; width:1px; 
    background:rgba(255, 255, 255, 0.3); margin:6px 0 10px 0;
  }
  #rail .tick{
    position:absolute; left:0; transform:translate(-50%,-50%); 
    display:flex; align-items:center; gap:8px; cursor:pointer; padding:6px 0;
  }
  #rail .tick .dot{
    width:7px;height:7px;border-radius:50%; 
    background:rgba(255, 255, 255, 0.5); border:none; 
    transition:background .2s, transform .2s;
  }
  #rail .tick .depth{
    font-family:'IBM Plex Mono',monospace; font-size:9px; color:white; 
    white-space:nowrap; position:absolute; left:14px; opacity:0; 
    transform:translateX(-4px); transition:opacity .2s, transform .2s;
  }
  #rail .tick:hover .depth, #rail .tick.active .depth{ opacity:1; transform:translateX(0); }
  #rail .tick.active .dot{ background:white; transform:scale(1.3); }

/* ---------- NAV & LOGOS ---------- */
  #topnav{position:sticky; top:0; z-index:150; background:var(--deep); color:var(--paper); display:flex; align-items:center; justify-content:space-between; padding:14px 20px; border-bottom:1px solid var(--line-deep);}
  @media (min-width:900px){ #topnav{display:none;} }
  #topnav .logo{font-family:'Space Grotesk';font-weight:700;color:var(--amber);font-size:14px;letter-spacing:.02em;}
  #topnav button{background:none;border:1px solid var(--line-deep);color:var(--paper); padding:8px 10px;border-radius:4px;font-family:'IBM Plex Mono';font-size:11px;}
  #mobilemenu{display:none; position:fixed; inset:0; z-index:300; background:var(--deep); color:var(--paper); padding:80px 30px 30px;}
  #mobilemenu.open{display:block;}
  #mobilemenu a{display:block; padding:14px 0; border-bottom:1px solid var(--line-deep); font-family:'Space Grotesk'; font-size:20px; text-decoration:none;}
  #mobilemenu .close{position:absolute; top:22px; right:24px; background:none;border:none; color:var(--paper); font-size:26px;}

  .desktop-logos {
    position: absolute; top: 80px; left: 28px; 
    display: flex; align-items: center; gap: 12px; z-index: 100;
  }
  .desktop-logos img {height: 85px; width: auto; object-fit: contain;}
  .logo-divider {width: 2px; height: 74px; background: rgba(255,255,255,0.4);}
  
@media (min-width: 900px) { 
    .desktop-logos { top: 40px; left: 96px; } 
    .desktop-logos img { height: 85px; } /* Keeps them large on desktop */
    .logo-divider { height: 74px; } /* Matches the larger logos */
  }

  /* ---------- HERO ---------- */
  /* Increased top padding to 210px so your 85px mobile logos don't hit the text */
  #home{background:var(--deep); color:var(--paper); padding:210px 0 80px; overflow:hidden;}
  .hero-grid{display:grid; gap:40px;}
  
  /* FIXED: The media query now wraps BOTH the padding and the grid layout */
  @media (min-width: 900px) {
    #home { padding: 120px 0 80px; } 
    .hero-grid { grid-template-columns: 1.1fr 0.9fr; align-items: center; }
  }
  
  .eyebrow{font-family:'IBM Plex Mono'; font-size:12px; letter-spacing:.14em; color:var(--amber); text-transform:uppercase; margin-bottom:18px; display:flex; align-items:center; gap:10px;}
  .eyebrow::before{content:"";width:22px;height:1px;background:var(--amber);}
  #home h1{font-size:clamp(2.2rem, 5vw, 3.6rem); line-height:1.05; color:var(--paper);}
  #home h1 span{color:var(--amber);}
  #home p.lede{margin-top:22px; max-width:46ch; color:rgba(234,235,227,0.75); font-size:1.05rem;}
  .cta-row{display:flex; gap:14px; margin-top:32px; flex-wrap:wrap;}
  .btn{display:inline-block; padding:13px 22px; border-radius:3px; font-family:'IBM Plex Mono'; font-size:13px; letter-spacing:.03em; text-decoration:none; border:1px solid transparent; cursor:pointer;}
  .btn-primary{background:var(--amber); color:var(--deep); font-weight:600;}
  .btn-primary:hover{background:#f0b746;}
  .btn-ghost{border-color:var(--line-deep); color:var(--paper); background:transparent;}
  .btn-ghost:hover{border-color:var(--amber); color:var(--amber);}
  .rig-svg{width:100%; height:auto; max-width:420px; margin:0 auto;}

  /* ---------- AWARD BADGES ---------- */
  .award-badges {
    background: #ffffff; border-radius: 16px; padding: 12px 16px; 
    display: inline-flex; align-items: center; gap: 14px; 
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25); 
    margin: 0 28px 32px 28px; 
    z-index: 10;
  }
  .award-badges img {width: 60px; height: 60px; object-fit: contain;}
  @media (min-width: 860px) { 
    .award-badges { 
      margin: 0;
      position: absolute; 
      top: 28px; 
      right: 28px; 
    } 
  }

  /* ---------- SECTION SCAFFOLDING ---------- */
  .section-pad{padding:76px 0;}
  .section-head{display:flex; align-items:baseline; gap:18px; margin-bottom:40px; flex-wrap:wrap;}
  .section-num{font-family:'IBM Plex Mono'; font-size:12px; color:var(--rust);}
  .section-head h2{font-size:clamp(1.6rem,3vw,2.2rem);}
  .section-rule{flex:1; height:1px; background:var(--line); min-width:40px;}
  .light-on-dark{background:var(--deep-2); color:var(--paper);}
  .light-on-dark .section-rule{background:var(--line-deep);}
  .light-on-dark .section-num{color:var(--amber);}

/* ---------- ABOUT ---------- */
  .about-grid{display:grid; gap:32px;}
  @media (min-width:800px){ .about-grid{grid-template-columns:1fr 1fr;} }
  .stat-strip{display:grid; grid-template-columns:repeat(2,1fr); gap:18px; margin-top:28px;}
  @media (min-width:600px){ .stat-strip{grid-template-columns:repeat(4,1fr);} }
  .stat{border-top:2px solid var(--rust); padding-top:10px;}
  .stat .num{font-family:'Space Grotesk'; font-size:1.8rem; font-weight:700;}
  .stat .lbl{font-family:'IBM Plex Mono'; font-size:11px; color:var(--steel); text-transform:uppercase;}

  /* ---------- TEAM ---------- */
  .team-grid{display:grid; gap:22px; grid-template-columns:repeat(2,1fr);}
  @media (min-width:700px){ .team-grid{grid-template-columns:repeat(4,1fr);} }
  .card{background:var(--paper-2); border:1px solid var(--line); border-radius:4px; padding:18px;}
  .avatar{width:100%; aspect-ratio:1; border-radius:3px; background:linear-gradient(135deg, var(--steel), var(--deep)); display:flex; align-items:center; justify-content:center; color:var(--amber); font-family:'IBM Plex Mono'; font-size:12px; margin-bottom:14px;}
  .card h3{font-size:1rem; color:var(--steel);}
  .card .role{font-family:'IBM Plex Mono'; font-size:11px; color:var(--rust); margin-top:4px; text-transform:uppercase;}
  
  /* LinkedIn Button */
  .btn-li {display: inline-flex; align-items: center; justify-content: center; background: var(--steel); color: var(--paper); text-decoration: none; padding: 4px 10px; border-radius: 3px; font-family: 'IBM Plex Mono'; font-size: 10px; margin-top:12px; transition: background 0.2s;}
  .btn-li:hover { background: #0077b5; }

 /* ---------- EVENTS ---------- */
  .event-row{
    display:grid; grid-template-columns:90px 1fr; gap:20px;
    padding:20px 0; border-bottom:1px solid var(--line);
  }
  .event-row:first-child{border-top:1px solid var(--line);}
  .event-date{font-family:'IBM Plex Mono'; font-size:12px; color:var(--rust);}
  .event-tag{
    display:inline-block; font-family:'IBM Plex Mono'; font-size:10px;
    padding:2px 8px; border:1px solid var(--line); border-radius:20px; margin-top:8px;
  }

  /* ---------- MEMBERSHIP & FORMS ---------- */
  .tier-grid{display:grid; gap:22px;}
  @media (min-width:800px){ .tier-grid{grid-template-columns:repeat(2,1fr);} }
  .tier{background:var(--deep-2); color:var(--paper); border-radius:4px; padding:26px; border:1px solid var(--line-deep);}
  .tier.featured{border-color:var(--amber);}
  .tier h3{color:var(--amber); font-size:1.1rem;}
  .tier .price{font-family:'Space Grotesk'; font-size:1.8rem; font-weight:700; margin:10px 0;}
  .tier .price span{font-size:1rem; color:rgba(234,235,227,.5); font-weight:400;}
  .tier ul{padding-left:18px; margin:16px 0 0; font-size:.92rem; color:rgba(234,235,227,.8);}
  .tier li{margin-bottom:8px;}

  .payment-box{background:var(--deep); border:1px solid var(--amber); border-radius:4px; padding:32px; margin-top:40px;}
  .bank-details{background:var(--deep-2); padding:20px; border-radius:4px; font-family:'IBM Plex Mono'; font-size:13px; margin-bottom:24px; border-left:4px solid var(--amber);}
  
  form{display:grid; gap:14px;}
  input,textarea{width:100%; padding:12px 14px; border:1px solid var(--line-deep); background:var(--deep); color:var(--paper); border-radius:3px; font-family:'IBM Plex Sans';}
  textarea{min-height:120px; resize:vertical;}
  input[type="file"]{padding: 8px; font-family: 'IBM Plex Mono'; font-size: 12px; background:var(--deep-2);}
  label{font-family:'IBM Plex Mono'; font-size:11px; color:var(--amber); text-transform:uppercase;}

/* ---------- MAGAZINE ---------- */
  .magazine-content {
    display: flex;
    flex-direction: column; /* Stacks the logo neatly above the text on mobile */
    align-items: flex-start;
    gap: 20px; /* Forces space between the logo and text */
  }
  
  .corner-logo {
    position: relative !important;
    width: 120px !important;
    height: auto;
    opacity: 0.9;
    margin: 0 !important;
  }
  
@media(min-width: 900px) {
    .magazine-content {
      display: block; 
      position: relative; /* Creates a safe boundary for the logo */
    }
    .corner-logo {
      position: absolute !important; 
      top: -10px !important; /* Safely tucks it below the header line */
      right: 0 !important; /* Snaps it to the far right of the text block */
      width: 150px !important; /* Slightly larger for desktop */
    }
  }

  /* Grid of Editions */
  .edition-grid {display: grid; gap: 40px; padding: 80px 0;}
  @media(min-width: 768px) { .edition-grid {grid-template-columns: repeat(2, 1fr);} }
  
  .edition-card {background: #fff; border: 1px solid var(--paper-2); border-radius: 8px; overflow: hidden; display: flex; flex-direction: column;}
 .edition-cover {
    width: 100%; 
    background: var(--steel); 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    color: var(--paper); 
    font-family: 'IBM Plex Mono';
  }

  .edition-cover img {
    width: 100%; 
    height: auto; 
    display: block;
  }
  .edition-info {padding: 24px; display: flex; flex-direction: column; flex: 1;}
  .edition-info .date {font-family: 'IBM Plex Mono'; font-size: 11px; color: var(--rust); text-transform: uppercase;}
  .edition-info h2 {margin: 10px 0; font-size: 1.4rem;}
  .edition-info p {color: var(--steel); font-size: 0.95rem; margin-bottom: 24px;}
  
  .btn-download {margin-top:auto; align-self: flex-start; background: var(--amber); color: var(--deep); padding: 10px 18px; border-radius: 4px; font-family: 'IBM Plex Mono'; font-size: 12px; font-weight: 600;}
  .btn-download:hover {background: #f0b746;}

  /* ---------- RESOURCES ---------- */
  .res-list{display:grid; gap:16px;}
  .res-item{
    display:flex; justify-content:space-between; align-items:center; gap:16px;
    padding:16px 18px; background:var(--paper-2); border:1px solid var(--line); border-radius:4px;
  }
  .res-item .tag{font-family:'IBM Plex Mono'; font-size:10px; color:var(--rust);}

  /* ---------- GALLERY ---------- */
  .gal-grid{display:grid; grid-template-columns:repeat(2,1fr); gap:14px;}
  @media (min-width:700px){ .gal-grid{grid-template-columns:repeat(4,1fr);} }
  .gal-item{
    aspect-ratio:4/3; border-radius:4px;
    background:repeating-linear-gradient(45deg, var(--paper-2), var(--paper-2) 10px, #d7d9cc 10px, #d7d9cc 20px);
    display:flex; align-items:center; justify-content:center;
    font-family:'IBM Plex Mono'; font-size:10px; color:var(--steel); text-align:center; padding:8px;
  }

  /* ---------- ALUMNI ---------- */
  .alumni-grid{display:grid; gap:22px;}
  @media (min-width:800px){ .alumni-grid{grid-template-columns:repeat(3,1fr);} }
  .alumni-card{border-left:3px solid var(--amber); padding-left:18px;}
  .alumni-card .quote{font-size:.98rem; margin-top:10px; color:var(--ink);}
  .alumni-card .who{font-family:'IBM Plex Mono'; font-size:11px; color:var(--steel); margin-top:12px;}

  /* ---------- FAQ ---------- */
  .faq-item{border-bottom:1px solid var(--line);}
  .faq-q{
    width:100%; text-align:left; background:none; border:none; cursor:pointer;
    padding:20px 0; display:flex; justify-content:space-between; align-items:center;
    font-family:'Space Grotesk'; font-size:1.02rem; font-weight:600; 
    color:var(--paper); /* Changed from --ink so it is readable on the dark background */
  }
  .faq-q .plus{font-family:'IBM Plex Mono'; color:var(--rust); font-size:20px; transition:transform .2s;}
  .faq-item.open .plus{transform:rotate(45deg);}
  .faq-a{max-height:0; overflow:hidden; transition:max-height .25s ease;}
  .faq-a p{padding-bottom:20px; margin:0; color:var(--amber); max-width:62ch;}

/* ---------- SPONSORS & PARTNERS ---------- */
  .sponsor-grid {
    display: flex;
    align-items: center; /* This is the magic rule that centers them vertically */
    justify-content: flex-start; /* Aligns the logos to the left */
    gap: 60px; /* Adds space between the logos */
    flex-wrap: wrap; /* Ensures they wrap neatly on mobile screens */
    margin-top: 32px;
  }
  
  .sponsor-box {
    display: flex;
    justify-content: center;
  }

  .sponsor-box img {
    max-height: 140px; /* Restricts the height so they stay proportional */
    width: auto;
    object-fit: contain;
  }

  /* ---------- NEWS ---------- */
  .news-grid{display:grid; gap:24px;}
  @media (min-width:800px){ .news-grid{grid-template-columns:repeat(3,1fr);} }
  .news-card .date{font-family:'IBM Plex Mono'; font-size:11px; color:var(--rust);}
  .news-card h3{margin-top:10px; font-size:1.05rem;}
  .news-card p{color:var(--steel); font-size:.92rem;}

  /* ---------- CONTACT ---------- */
  .contact-grid{display:grid; gap:36px;}
  @media (min-width:800px){ .contact-grid{grid-template-columns:1fr 1fr;} }
  form{display:grid; gap:14px;}
  input,textarea{
    width:100%; padding:12px 14px; border:1px solid var(--line-deep);
    background:var(--deep); color:var(--paper); border-radius:3px; font-family:'IBM Plex Sans';
  }
  textarea{min-height:120px; resize:vertical;}
  label{font-family:'IBM Plex Mono'; font-size:11px; color:var(--amber); text-transform:uppercase;}
  
  .social-row {
    display: flex; 
    gap: 16px; 
    margin-top: 24px;
  }
  .social-row a {
    border: 2px solid var(--amber);
    border-radius: 50%; 
    width: 48px; 
    height: 48px;
    display: flex; 
    align-items: center; 
    justify-content: center; 
    font-family: 'IBM Plex Mono'; 
    font-size: 14px;
    font-weight: 600;
    color: var(--amber);
    text-decoration: none;
    transition: all 0.2s ease;
  }
  .social-row a:hover {
    background: var(--amber);
    color: var(--deep);
    transform: translateY(-3px);
  }

  /* ---------- FOOTER ---------- */
  footer{background:var(--deep); color:rgba(234,235,227,.5); padding:30px 0; font-family:'IBM Plex Mono'; font-size:11px; text-align:center;}
  ::selection{background:var(--amber); color:var(--deep);}

  /* ---------- MAGAZINE PAGE ---------- */
  .top-bar {background: var(--deep); padding: 30px; display:flex; justify-content:space-between; align-items:center;}
  .top-bar a {color: var(--amber); font-family: 'IBM Plex Mono'; font-size: 13px; text-decoration:none;}
  /* Fixes the size of the University and SPE logos in the magazine header */
  .top-bar a img {
    height: 70px; 
    width: auto;
    object-fit: contain;
  }
  
  /* Restores the vertical white line between them */
  .top-bar .logo-divider {
    width: 2px; 
    height: 60px; 
    background: rgba(255,255,255,0.4);
  }

  .mag-hero {background: var(--paper-2); padding: 80px 0; border-bottom: 1px solid rgba(0,0,0,0.1); text-align: center;}
  .mag-hero h1 {font-size: 3rem; color: var(--deep);}
  .mag-hero p {max-width: 600px; margin: 20px auto 0; color: var(--steel);}
  
  .edition-grid {display: grid; gap: 40px; padding: 80px 0;}
  @media(min-width: 768px) { .edition-grid {grid-template-columns: repeat(2, 1fr);} }
  
  .edition-card {background: #fff; border: 1px solid var(--paper-2); border-radius: 8px; overflow: hidden; display: flex; flex-direction: column;}
  .edition-cover {width: 100%; background: var(--steel); display: flex; align-items: center; justify-content: center; color: var(--paper); font-family: 'IBM Plex Mono';}
  .edition-cover img {width: 100%; height: auto; display: block;}
  
  .edition-info {padding: 24px; display: flex; flex-direction: column; flex: 1;}
  .edition-info .date {font-family: 'IBM Plex Mono'; font-size: 11px; color: var(--rust); text-transform: uppercase;}
  .edition-info h2 {margin: 10px 0; font-size: 1.4rem;}
  .edition-info p {color: var(--steel); font-size: 0.95rem; margin-bottom: 24px;}
  
  .btn-download {margin-top:auto; align-self: flex-start; background: var(--amber); color: var(--deep); padding: 10px 18px; border-radius: 4px; font-family: 'IBM Plex Mono'; font-size: 12px; font-weight: 600;}
  .btn-download:hover {background: #f0b746;}

  .edition-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
  }
  
  .edition-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.15);
  }

  /* ---------- FEATURED LATEST EDITION ---------- */
  .featured-edition {
    grid-column: 1 / -1; /* Forces the card to span the entire width of the grid */
  }
  
  /* The "NEW" Badge */
  .badge-new {
    background: var(--rust);
    color: var(--paper);
    padding: 3px 8px;
    border-radius: 12px;
    font-family: 'IBM Plex Mono';
    font-size: 10px;
    font-weight: 600;
    margin-left: 12px;
    vertical-align: middle;
  }

  /* Desktop layout for the featured card */
  @media(min-width: 768px) {
    .featured-edition {
      flex-direction: row; /* Places the cover and text side-by-side */
      align-items: stretch;
    }
    .featured-edition .edition-cover {
      width: 45%; /* Cover takes up nearly half the card */
      border-right: 1px solid var(--paper-2);
    }
    .featured-edition .edition-info {
      width: 55%;
      padding: 40px; /* Gives the text more breathing room */
      justify-content: center;
    }
    .featured-edition h2 {
      font-size: 2rem; /* Makes the title larger */
    }
  }

/* ---------- ACHIEVEMENTS & HERO SLIDER ---------- */
.achieve-hero {
  position: relative;
  width: 100%;
  height: 65vh;
  min-height: 420px;
  background: var(--deep);
  overflow: hidden;
  padding-top: 80px;
}

.slider-container {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

.slide {
  position: absolute;
  top: 0; 
  left: 0; 
  right: 0; 
  bottom: 0;
  opacity: 0;
  z-index: 0; 
  visibility: hidden; 
  transition: opacity 0.8s ease-in-out, visibility 0.8s ease-in-out;
}

.slide.active {
  opacity: 1;
  z-index: 1; 
  visibility: visible;
}

.slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(0.65);
}

.slide-caption {
  position: absolute;
  bottom: 50px;
  left: 28px;
  right: 28px;
  max-width: 1080px;
  margin: 0 auto;
  color: var(--paper);
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(1.4rem, 3vw, 2.2rem);
  font-weight: 700;
  text-shadow: 0 2px 10px rgba(0,0,0,0.7);
  z-index: 2;
}

.slider-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(11, 20, 32, 0.6);
  border: 1px solid var(--line-deep);
  color: var(--paper);
  font-size: 20px;
  padding: 12px 16px;
  cursor: pointer;
  z-index: 10;
  transition: background 0.2s;
}

.slider-btn:hover {
  background: var(--amber);
  color: var(--deep);
}

.slider-btn.prev { left: 16px; }
.slider-btn.next { right: 16px; }

.slider-dots {
  position: absolute;
  bottom: 18px;
  width: 100%;
  display: flex;
  justify-content: center;
  gap: 8px;
  z-index: 10;
}

.slider-dots .dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.4);
  cursor: pointer;
  transition: background 0.3s;
}

.slider-dots .dot.active {
  background: var(--amber);
  width: 24px;
  border-radius: 12px;
}

/* ---------- AWARDS LIST ---------- */
.awards-list {
  display: flex;
  flex-direction: column;
  gap: 50px;
  margin-top: 30px;
}

.award-item {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  align-items: center;
  background: var(--deep-2);
  border: 1px solid var(--line-deep);
  border-radius: 6px;
  overflow: hidden;
}

.award-img img {
  width: 100%;
  height: 260px;
  object-fit: cover;
  display: block;
}

.award-info {
  padding: 24px;
}

.award-year {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 12px;
  color: var(--amber);
  font-weight: 600;
}

.award-info h3 {
  font-size: 1.5rem;
  color: var(--paper);
  margin: 8px 0 12px;
}

.award-info p {
  color: rgba(234, 235, 227, 0.8);
  font-size: 0.95rem;
  line-height: 1.6;
}

@media (min-width: 768px) {
  .award-item {
    grid-template-columns: 1fr 1fr;
  }
  .award-item.reverse .award-img {
    order: 2;
  }
  .award-img img {
    height: 100%;
    min-height: 280px;
  }
}

/* Archive Teaser Banner */
.archive-banner {
  margin-top: 60px;
  padding: 32px;
  background: var(--deep-2);
  border: 1px solid var(--amber);
  border-radius: 6px;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
}

.archive-banner h3 {
  color: var(--paper);
  font-size: 1.3rem;
  margin-bottom: 6px;
}

.archive-banner p {
  color: rgba(234, 235, 227, 0.75);
  margin: 0;
  font-size: 0.95rem;
}

/* ---------- AWARDS LIST ---------- */
.awards-list {
  display: flex;
  flex-direction: column;
  gap: 50px;
  margin-top: 30px;
}

.award-item {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  align-items: center;
  background: var(--deep-2);
  border: 1px solid var(--line-deep);
  border-radius: 6px;
  overflow: hidden;
}

.award-img img {
  width: 100%;
  height: 260px;
  object-fit: cover;
  display: block;
}

.award-info {
  padding: 24px;
}

.award-year {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 12px;
  color: var(--amber);
  font-weight: 600;
}

.award-info h3 {
  font-size: 1.5rem;
  color: var(--paper);
  margin: 8px 0 12px;
}

.award-info p {
  color: rgba(234, 235, 227, 0.8);
  font-size: 0.95rem;
  line-height: 1.6;
}

@media (min-width: 768px) {
  .award-item {
    grid-template-columns: 1fr 1fr;
  }
  .award-item.reverse .award-img {
    order: 2;
  }
  .award-img img {
    height: 100%;
    min-height: 280px;
  }
}

/* Archive Teaser Banner */
.archive-banner {
  margin-top: 60px;
  padding: 32px;
  background: var(--deep-2);
  border: 1px solid var(--amber);
  border-radius: 6px;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
}

.archive-banner h3 {
  color: var(--paper);
  font-size: 1.3rem;
  margin-bottom: 6px;
}

.archive-banner p {
  color: rgba(234, 235, 227, 0.75);
  margin: 0;
  font-size: 0.95rem;
}

/* ---------- ARCHIVE ACCORDION & PHOTO GRID ---------- */
.archive-list {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.archive-card {
  background: var(--deep-2);
  border: 1px solid var(--line-deep);
  border-radius: 6px;
  overflow: hidden;
}

.archive-summary {
  padding: 24px;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
}

.archive-date {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  color: var(--amber);
  text-transform: uppercase;
}

.archive-summary h3 {
  color: var(--paper);
  font-size: 1.35rem;
  margin: 6px 0 8px;
}

.archive-summary p {
  color: rgba(234, 235, 227, 0.8);
  font-size: 0.95rem;
  max-width: 60ch;
  margin: 0;
}

.archive-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.gallery-drawer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease-out;
  background: rgba(0, 0, 0, 0.2);
  border-top: 1px solid transparent;
}

.gallery-drawer.open {
  max-height: 1200px;
  border-top-color: var(--line-deep);
  padding: 24px;
}

.photo-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
}

@media (min-width: 768px) {
  .photo-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.photo-grid img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  border-radius: 4px;
  border: 1px solid var(--line-deep);
  transition: transform 0.2s ease;
}

.photo-grid img:hover {
  transform: scale(1.03);
}

  /* Import the Arabic Font */
@import url('https://fonts.googleapis.com/css2?family=IBM+Plex+Sans+Arabic:wght@400;500;600&display=swap');

/* Apply font and spacing adjustments ONLY when the page is Arabic */
html[dir="rtl"] body {
  font-family: 'IBM Plex Sans Arabic', sans-serif;
  font-size: 115%; /* Arabic requires roughly 10-20% larger text for equivalent readability */
  line-height: 1.8; /* Increased line height prevents diacritics from overlapping the line above */
}

/* Fix any left-aligned elements to right-aligned for Arabic */
html[dir="rtl"] .faq-q {
  text-align: right; 
}

/* =========================================
   RTL (ARABIC) OVERRIDES
========================================= */

/* 1. Flip the Logos to the right side */
html[dir="rtl"] .desktop-logos {
  left: auto;
  right: 28px;
}

/* 2. Adjust Desktop View for Logos and Container Padding */
@media (min-width: 900px) {
  html[dir="rtl"] .desktop-logos {
    left: auto;
    right: 96px;
  }
  
  /* Flips the desktop container indent to the right so it aligns with the logos */
  html[dir="rtl"] .wrap {
    padding-left: 28px; 
    padding-right: 96px; 
  }
}

/* 3. Additional Layout Fixes for RTL Consistency */
html[dir="rtl"] #rail {
  left: auto;
  right: 0;
}

html[dir="rtl"] #rail .tick .depth {
  left: auto;
  right: 14px;
  transform: translateX(4px);
}

html[dir="rtl"] #mobilemenu .close {
  right: auto;
  left: 24px;
}

html[dir="rtl"] .alumni-card {
  border-left: none;
  padding-left: 0;
  border-right: 3px solid var(--amber);
  padding-right: 18px;
}

html[dir="rtl"] .bank-details {
  border-left: none;
  border-right: 4px solid var(--amber);
}

@media (min-width: 860px) { 
  html[dir="rtl"] .award-badges { 
    right: auto;
    left: 28px; 
  } 
}

/* Moves the magazine logo to the left side on desktop for RTL */
@media (min-width: 900px) {
  html[dir="rtl"] .corner-logo {
    right: auto !important;
    left: 0 !important;
  }
}

/* =========================================
   LANGUAGE SWITCHER
========================================= */

/* Desktop Button */
.desktop-lang {
  display: none; /* Hides it on mobile screens */
  position: absolute;
  top: 40px;
  right: 28px;
  z-index: 200;
}

@media (min-width: 900px) {
  .desktop-lang {
    display: block; /* Shows it only on desktop */
    right: 280px;   /* Clears space next to the award badges */
  }
  
  html[dir="rtl"] .desktop-lang {
    right: auto;
    left: 280px; /* Mirrors it correctly for the Arabic version */
  }
}

.desktop-lang a {
  display: inline-block;
  padding: 8px 16px;
  border: 1px solid rgba(255,255,255,0.3);
  color: var(--paper);
  text-decoration: none;
  font-family: 'IBM Plex Sans', sans-serif;
  font-size: 13px;
  font-weight: 500;
  border-radius: 4px;
  transition: all 0.2s ease;
  background: rgba(11, 20, 32, 0.4);
  backdrop-filter: blur(4px);
}

.desktop-lang a:hover {
  border-color: var(--amber);
  color: var(--amber);
}

/* Mobile Button */
.mobile-lang {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 6px 10px;
  border: 1px solid rgba(255,255,255,0.3);
  border-radius: 4px;
  color: var(--paper);
  text-decoration: none;
  font-family: 'IBM Plex Sans', sans-serif;
  font-size: 11px;
}

.mobile-lang:hover {
  border-color: var(--amber);
  color: var(--amber);
}

/* RTL (Arabic) Overrides for Language Switcher */
html[dir="rtl"] .desktop-lang {
  right: auto;
  left: 28px;
}

@media (min-width: 900px) {
  .desktop-lang {
    right: 280px; /* Pushes the button to the left of the award badges */
  }
  
  html[dir="rtl"] .desktop-lang {
    right: auto;
    left: 280px; /* Mirrors it correctly for the Arabic version */
  }
}

/* Fix for Slider Arrows in RTL */
html[dir="rtl"] .slider-btn.prev {
  left: auto;
  right: 16px;
}

html[dir="rtl"] .slider-btn.next {
  right: auto;
  left: 16px;
}

/* Fix Arabic text in the vertical rail */
html[dir="rtl"] #rail .brand-mark {
  letter-spacing: normal; 
  font-family: 'IBM Plex Sans Arabic', sans-serif;
  font-size: 13px; /* Slightly larger to balance the missing letter spacing */
}