@import url('https://fonts.googleapis.com/css2?family=Fira+Code:wght@400;500;600;700;800&display=swap');

:root{
  --black:#000;
  --ink:#111;
  --dark-grey:#222;
  --grey:#555;
  --muted:#777;
  --light-grey:#999;
  --paper:#fafafa;
  --white:#fff;

  --yellow:#FFF2A8;
  --green:#CFF5D2;
  --pink:#FFD6E7;
  --blue:#D9EFFF;
  --purple:#E7D8FF;
  --peach:#FFDDB8;
  --mint:#CDEFEA;
  --soft-grey:#E5E5E5;

  --border:3px solid #000;
  --shadow:4px 4px 0 #000;
  --font:"Fira Code",monospace;
}

*{box-sizing:border-box}
html{scroll-behavior:smooth}
body{
  margin:0;
  color:var(--ink);
  background:var(--paper);
  font-family:var(--font);
  line-height:1.6;
  overflow-x:hidden;
}
a{text-decoration:none;color:inherit}
button,input,textarea,select{font:inherit}
.container{width:min(1480px,94%);margin-inline:auto}

/* =========================
   TOP NAV
   ========================= */
.site-nav{
  position:sticky;
  top:0;
  z-index:100;
  background:var(--white);
  color:var(--ink);
  border-bottom:var(--border);
  box-shadow:none;
  padding:2px 0;
}
.nav-inner{
  min-height:76px;
  display:flex;
  align-items:center;
  gap:24px;
}
.brand{
  display:flex;
  align-items:center;
  gap:12px;
  margin-right:auto;
  white-space:nowrap;
  font-size:17px;
  font-weight:700;
}
.brand-icon{
  width:42px;
  height:42px;
  display:grid;
  place-items:center;
  background:var(--white);
  border:var(--border);
  border-radius:3px 5px 4px 2px;
  box-shadow:3px 3px 0 var(--black);
  color:var(--black);
  font-size:17px;
  font-weight:800;
  transform:rotate(-1deg);
}
.brand-name{font-size:17px;font-weight:700}

.main-nav{
  display:flex;
  align-items:center;
  height:100%;
  gap:8px;
}
.main-nav a{
  position:relative;
  display:flex;
  align-items:center;
  min-height:44px;
  padding:8px 12px;
  border:2px solid var(--black);
  border-radius:3px 5px 4px 2px;
  background:var(--yellow);
  box-shadow:2px 2px 0 var(--black);
  color:var(--black);
  font-size:18px;
  font-weight:600;
  line-height:1.2;
  text-decoration:none;
  transition:transform .18s ease,box-shadow .18s ease,background .18s ease;
  white-space:nowrap;
}
.main-nav a:hover,.main-nav a:focus-visible{background:var(--pink);box-shadow:1px 1px 0 var(--black);color:var(--black);text-decoration:none;transform:translate(1px,1px)}
.nav-icon{
  display:inline-grid;
  min-width:1.15em;
  height:1em;
  place-items:center;
  color:var(--black);
  font-size:1em;
  font-weight:700;
  line-height:1;
}

/* =========================
   HERO
   ========================= */
.hero-wrap{padding:26px 0 22px}
.hero-card{
  position:relative;
  isolation:isolate;
  overflow:hidden;
  min-height:510px;
  padding:52px;
  border:var(--border);
  border-radius:5px 7px 4px 6px;
  background:var(--white);
  box-shadow:7px 7px 0 var(--black);
}
.hero-card::before{
  content:"";
  position:absolute;
  inset:0;
  z-index:0;
  pointer-events:none;
  opacity:.45;
  background:
    repeating-linear-gradient(
      0deg,
      transparent 0,
      transparent 31px,
      rgba(0,0,0,.025) 32px
    );
}
.hero-copy{
  position:relative;
  z-index:6;
  width:min(760px,67%);
}
.hero-kicker{
  display:inline-block;
  padding:2px 6px;
  color:var(--black);
  background:var(--green);
  font-size:13px;
  font-weight:700;
  transform:rotate(-1deg);
}
.hero-title{
  margin:20px 0 12px;
  color:var(--black);
  font-size:clamp(3rem,5.25vw,5.2rem);
  line-height:1.02;
  letter-spacing:-.07em;
  font-weight:800;
}
.hero-title .gradient{
  position:relative;
  display:inline-block;
  width:auto;
  color:var(--black);
  background:none;
  -webkit-text-fill-color:var(--black);
  isolation:isolate;
}
.hero-title .gradient::before{
  content:"";
  position:absolute;
  z-index:-1;
  left:-9px;
  right:-9px;
  bottom:6px;
  height:48%;
  background:var(--yellow);
  border-radius:2px 6px 3px 5px;
  transform:rotate(-1.1deg);
  opacity:.9;
}
.hero-subtitle{
  margin:0;
  max-width:700px;
  color:var(--grey);
  font-size:18px;
  font-weight:500;
}
.hero-stats{
  display:flex;
  flex-wrap:wrap;
  gap:26px;
  margin-top:31px;
}
.hero-stat{
  display:flex;
  align-items:center;
  gap:10px;
}
.stat-icon{
  width:46px;
  height:46px;
  display:grid;
  place-items:center;
  border:var(--border);
  border-radius:4px;
  background:var(--white);
  color:var(--black);
  font-size:17px;
  font-weight:800;
  box-shadow:3px 3px 0 var(--black);
}
.stat-icon.green{background:var(--green)}
.stat-icon.purple{background:var(--purple)}
.stat-icon.orange{background:var(--peach)}
.stat-icon.pink{background:var(--pink)}
.stat-text strong{
  display:block;
  color:var(--black);
  font-size:15px;
  line-height:1.2;
}
.stat-text span{
  display:block;
  color:var(--grey);
  font-size:13px;
  line-height:1.3;
}
.hero-quote{
  margin-top:28px;
  color:var(--grey);
  font-style:italic;
  font-size:15px;
}
.hero-quote b{color:var(--black);font-style:normal}

/* Portrait remains in the same hero position, but the frame follows the new system. */
.hero-watermark{
  position:absolute;
  z-index:3;
  right:4.6%;
  top:35px;
  width:390px;
  height:390px;
  border-radius:50%;
  overflow:hidden;
  opacity:.95;
  border:var(--border);
  box-shadow:6px 6px 0 var(--black);
  background:var(--white);
}
.hero-watermark img{
  width:100%;
  height:100%;
  display:block;
  object-fit:cover;
  object-position:center 22%;
  filter:grayscale(.12) contrast(1.02);
}
.hero-watermark::before{
  content:"";
  position:absolute;
  inset:0;
  z-index:2;
  pointer-events:none;
  border-radius:50%;
  box-shadow:inset 0 0 0 10px rgba(255,255,255,.12);
}
.watermark-ring{
  position:absolute;
  inset:-12px;
  z-index:3;
  border-radius:50%;
  border:2px dashed var(--black);
  pointer-events:none;
}

/* =========================
   SECONDARY NAV
   ========================= */
.nav-strip{
  position:relative;
  top:auto;
  z-index:1;
  background:rgba(250,250,250,.96);
  border-bottom:0;
}
.nav-strip .container{
  display:flex;
  gap:7px;
  overflow-x:auto;
  padding:8px 0;
  scrollbar-width:thin;
}
.nav-strip a{
  flex:0 0 auto;
  padding:7px 12px;
  border:2px solid var(--black);
  border-radius:3px 5px 4px 2px;
  background:var(--yellow);
  box-shadow:2px 2px 0 var(--black);
  color:var(--black);
  font-size:14px;
  font-weight:600;
  line-height:1.2;
  transition:transform .18s ease,box-shadow .18s ease,background .18s ease;
}
.nav-strip a:hover{
  color:var(--black);
  background:var(--green);
  box-shadow:1px 1px 0 var(--black);
  transform:translate(1px,1px);
}

/* =========================
   OVERVIEW CARDS
   ========================= */
.overview{
  display:grid;
  grid-template-columns:repeat(4,minmax(0,1fr));
  gap:20px;
  padding:0 0 48px;
}
.overview-card{
  position:relative;
  min-height:255px;
  padding:22px 24px 74px;
  overflow:hidden;
  border:var(--border);
  border-radius:4px 6px 5px 3px;
  background:var(--white);
  box-shadow:var(--shadow);
  color:var(--black);
  transition:transform .18s ease,box-shadow .18s ease;
}
.overview-card:hover{
  transform:translate(2px,2px);
  box-shadow:2px 2px 0 var(--black);
}
.overview-card.green{background:var(--white)}
.overview-card.blue{background:var(--white)}
.overview-card.purple{background:var(--white)}
.overview-card.orange{background:var(--white)}
.overview-icon{
  width:52px;
  height:52px;
  display:grid;
  place-items:center;
  margin-bottom:15px;
  border:2px solid var(--black);
  border-radius:3px 5px 4px 2px;
  background:var(--white);
  color:var(--black);
  font-size:21px;
}
.overview-card.green .overview-icon{background:var(--green)}
.overview-card.blue .overview-icon{background:var(--blue)}
.overview-card.purple .overview-icon{background:var(--purple)}
.overview-card.orange .overview-icon{background:var(--peach)}
.overview-card h3{
  position:relative;
  display:inline-block;
  margin:0;
  font-size:21px;
  line-height:1.2;
  font-weight:800;
  isolation:isolate;
}
.overview-card h3::before{
  content:"";
  position:absolute;
  z-index:-1;
  left:-5px;
  right:-5px;
  bottom:2px;
  height:50%;
  transform:rotate(-1deg);
}
.overview-card:nth-child(1) h3::before{background:var(--yellow)}
.overview-card:nth-child(2) h3::before{background:var(--green)}
.overview-card:nth-child(3) h3::before{background:var(--pink)}
.overview-card:nth-child(4) h3::before{background:var(--blue)}
.overview-card .small{
  margin:5px 0 17px;
  color:var(--grey);
  font-size:15px;
  line-height:1.3;
  font-weight:600;
}
.overview-card p{
  margin:0;
  max-width:255px;
  color:var(--grey);
  font-size:15px;
  line-height:1.55;
}
.overview-card .count{
  position:absolute;
  left:24px;
  bottom:27px;
  margin:0;
  color:var(--grey);
  font-size:15px;
  font-weight:700;
  line-height:1;
  white-space:nowrap;
}
.card-arrow{
  position:absolute;
  right:22px;
  bottom:19px;
  width:43px;
  height:43px;
  display:grid;
  place-items:center;
  border:var(--border);
  border-radius:3px 5px 4px 2px;
  background:var(--white);
  color:var(--black);
  font-size:23px;
  line-height:1;
  z-index:4;
  box-shadow:3px 3px 0 var(--black);
  transition:transform .18s ease,box-shadow .18s ease;
}
.card-arrow:hover{
  transform:translate(2px,2px);
  box-shadow:1px 1px 0 var(--black);
}
.card-arrow:focus-visible{
  outline:3px dashed var(--black);
  outline-offset:3px;
}

/* =========================
   QUESTION SECTIONS
   ========================= */
.container.igcs-main{padding-top:22px}
main{padding-bottom:40px}
.class-section{margin-bottom:64px}
.section-head{
  display:flex;
  justify-content:space-between;
  gap:20px;
  align-items:flex-start;
  margin:24px 0 22px;
}
.section-head h2{
  position:relative;
  display:inline-block;
  margin:0;
  font-size:35px;
  line-height:1.15;
  letter-spacing:-.05em;
  isolation:isolate;
}
.section-head h2::before{
  content:"";
  position:absolute;
  z-index:-1;
  left:-6px;
  right:-6px;
  bottom:2px;
  height:42%;
  background:var(--green);
  transform:rotate(-.8deg);
}
.class-section:nth-of-type(2n) .section-head h2::before{background:var(--pink)}
.class-section:nth-of-type(3n) .section-head h2::before{background:var(--yellow)}
.section-head p{
  margin:9px 0 0;
  max-width:860px;
  color:var(--grey);
  font-size:14px;
}
.badge{
  flex:0 0 auto;
  padding:5px 10px;
  border:2px solid var(--black);
  border-radius:3px 5px 2px 4px;
  background:var(--yellow);
  color:var(--black);
  font-size:13px;
  font-weight:700;
  transform:rotate(1deg);
}
.topic{
  display:flex;
  align-items:center;
  gap:13px;
  margin:30px 0 14px;
  color:var(--black);
  font-size:17px;
  font-weight:700;
}
.topic::after{
  content:"";
  height:2px;
  background:var(--black);
  flex:1;
  opacity:.55;
}
.grid{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:15px;
}
.qcard{
  overflow:hidden;
  border:var(--border);
  border-radius:4px 5px 3px 6px;
  background:var(--white);
  box-shadow:3px 3px 0 var(--black);
  transition:transform .18s ease,box-shadow .18s ease;
}
.qcard:hover{
  transform:translate(2px,2px);
  box-shadow:1px 1px 0 var(--black);
}
.qcard summary{
  cursor:pointer;
  list-style:none;
  display:flex;
  gap:12px;
  align-items:flex-start;
  padding:17px 18px;
  color:var(--black);
  font-size:15px;
  font-weight:700;
}
.qcard summary::-webkit-details-marker{display:none}
.num{
  flex:0 0 auto;
  width:34px;
  min-height:31px;
  display:grid;
  place-items:center;
  padding:3px;
  border:2px solid var(--black);
  border-radius:3px;
  background:var(--yellow);
  color:var(--black);
  font-size:13px;
  font-weight:800;
}
.qcard:nth-child(4n+2) .num{background:var(--green)}
.qcard:nth-child(4n+3) .num{background:var(--pink)}
.qcard:nth-child(4n+4) .num{background:var(--blue)}
.qtext{padding-top:2px}
.qcard[open] summary{
  background:var(--soft-grey);
  border-bottom:2px solid var(--black);
}
.answer{
  padding:17px 18px 20px;
  color:var(--dark-grey);
  font-size:15px;
}
.answer p:first-child{margin-top:0}
.answer p:last-child{margin-bottom:0}
.label{
  display:inline-block;
  margin-bottom:8px;
  padding:1px 5px;
  background:var(--green);
  color:var(--black);
  font-size:13px;
  font-weight:800;
  text-transform:uppercase;
  letter-spacing:.08em;
}
pre{
  margin:9px 0 0;
  max-width:100%;
  overflow:auto;
  padding:15px 16px;
  border:var(--border);
  border-radius:3px 5px 4px 2px;
  background:#111;
  color:#fff;
  font:500 14px/1.6 "Fira Code",monospace;
}
code{font-family:"Fira Code",monospace}
:not(pre)>code{
  padding:1px 4px;
  border-bottom:2px solid var(--black);
  background:var(--yellow);
  color:var(--black);
  font-size:.92em;
}
.note{
  padding:12px 14px;
  border:2px solid var(--black);
  border-left:7px solid var(--black);
  background:var(--yellow);
  color:var(--black);
  border-radius:3px;
}
.bottom-quote{
  max-width:900px;
  margin:60px auto 46px;
  padding:30px 40px;
  text-align:center;
  color:var(--grey);
  font-size:19px;
  line-height:1.7;
  font-style:italic;
  border-top:var(--border);
  border-bottom:var(--border);
}
.bottom-quote .mark{
  font-size:2.2rem;
  color:var(--black);
  vertical-align:-.25em;
}
.bottom-quote .author{
  display:block;
  margin-top:7px;
  color:var(--black);
  font-size:15px;
  font-style:normal;
  font-weight:700;
}

/* =========================
   FOOTER
   ========================= */
footer.igcs-footer{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:var(--igcs-space-4);
  padding:calc(var(--igcs-space-5) - 11px) clamp(16px,3vw,34px);
  color:var(--igcs-grey);
  border-top:var(--igcs-border);
  background:var(--igcs-white);
  font-size:14px;
}
.back-to-top{
  position:fixed;
  z-index:95;
  right:20px;
  bottom:20px;
  display:grid;
  width:42px;
  height:42px;
  place-items:center;
  border:2px solid var(--black);
  border-radius:50%;
  background:transparent;
  color:var(--black);
  font-size:26px;
  font-weight:700;
  line-height:1;
  text-decoration:none;
  transition:transform .18s ease,background .18s ease;
}
.back-to-top:hover,.back-to-top:focus-visible{
  background:var(--green);
  transform:translateY(-2px);
}

/* =========================
   RESPONSIVE
   ========================= */
@media(max-width:1150px){
  .main-nav a{padding-left:10px;padding-right:10px}
  .hero-copy{width:70%}
  .hero-watermark{width:340px;height:340px;right:2%;top:54px}
  .overview{grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media(max-width:900px){
  .nav-inner{min-height:70px;flex-wrap:wrap;padding-block:10px}
  .main-nav{display:flex;order:3;width:100%;height:auto;justify-content:space-between;border-top:2px solid var(--black)}
  .main-nav a{min-height:42px;padding:7px 9px;font-size:16px}
  .hero-card{padding:38px 34px;min-height:525px}
  .hero-copy{width:100%}
  .hero-watermark{width:320px;height:320px;right:12px;top:155px;opacity:.28}
  .grid{grid-template-columns:1fr}
  .section-head{display:block}
  .badge{display:inline-block;margin-top:12px}
}
@media(max-width:620px){
  .container{width:94%}
  .brand-name{font-size:15px}
  .brand-icon{width:39px;height:39px;font-size:15px}
  .hero-wrap{padding:15px 0 18px}
  .hero-card{
    min-height:650px;
    padding:28px 22px;
    border-radius:4px 6px 3px 5px;
  }
  .hero-title{
    font-size:2.5rem;
    letter-spacing:-.06em;
  }
  .hero-subtitle{font-size:16px}
  .hero-stats{
    display:grid;
    grid-template-columns:1fr 1fr;
    gap:14px;
    margin-top:25px;
  }
  .stat-icon{width:40px;height:40px;font-size:16px}
  .stat-text strong{font-size:14px}
  .stat-text span{font-size:12px}
  .hero-watermark{
    width:245px;
    height:245px;
    right:50%;
    transform:translateX(50%);
    top:auto;
    bottom:28px;
    opacity:.95;
  }
  .hero-quote{
    position:absolute;
    left:22px;
    right:22px;
    bottom:286px;
    margin:0;
    font-size:13px;
  }
  .nav-strip .container{padding:7px 0}
  .nav-strip a{font-size:14px;padding:7px 10px}
  .overview{
    grid-template-columns:1fr;
    gap:14px;
    padding:0 0 32px;
  }
  .overview-card{min-height:220px}
  .section-head h2{font-size:27px}
  .topic{font-size:16px}
  .qcard summary{padding:14px;font-size:14px}
  .answer{padding:14px;font-size:14px}
  pre{font-size:12px;padding:12px}
  .bottom-quote{
    margin:45px auto 38px;
    padding:25px 18px;
    font-size:16px;
    line-height:1.65;
  }
  .bottom-quote .author{font-size:14px}
}
@media(max-width:390px){
  .hero-title{font-size:2.15rem}
  .hero-card{min-height:625px}
  .hero-watermark{width:215px;height:215px}
  .hero-quote{bottom:252px}
  .hero-stats{gap:10px}
  .stat-icon{width:36px;height:36px}
  .stat-text strong{font-size:13px}
  .stat-text span{font-size:11px}
  .section-head h2{font-size:24px}
  .bottom-quote{font-size:15px}
}
@media print{
  .site-nav,.nav-strip{display:none}
  body{background:#fff}
  .hero-card,.overview-card,.qcard{box-shadow:none}
  .qcard{break-inside:avoid}
  .qcard:not([open]) .answer{display:block}
}
