

*,
*::before,
*::after {
  box-sizing: border-box;
}

html, body{
  background: #020617;
background-repeat: no-repeat;
  background-attachment: fixed;   /* optional, for a nice “stuck” background effect */
  background-size: cover;
  scroll-behavior: smooth;
  font-family: Arial, Helvetica, sans-serif;
}

.section-container {
  display: flex;
  width: 100%;
  max-width: 1200px;
  margin: 3% auto;
  text-align: center;
}

.section-header{
  width: 80%;
  text-align: center;
  font-family: Arial, Helvetica, sans-serif;
  margin: 11% auto 0% auto;
}

.section-header h3{
  font-size: 4rem;
  color:#6D98E3;
  font-weight: 600;

}

.section-header p{
  font-size: 1.5rem;
  font-weight: 500;
  color: #020617;
  background: #fff;
  padding: 2rem 3rem;
  border: 1px solid #fff;
  border-radius: 1.5rem;
}

.grid-container {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-template-rows: repeat(2, 200px); /* adjust height as needed */
  gap: 0; /* we will draw our own lines */
  border: 0.5px solid transparent; /* transparent outer border */
  width: 100%;
  max-width: 1200px;
  margin: 3% auto;
  background: #fff;
  border-radius: 1.5rem;
  opacity: 0.9;
}

.grid-item {
  display: flex;
  justify-content: center;
  align-items: center;
  border: 0.1px solid #f0f0f0; /* draws all lines */
}

/* Remove outside borders (so only internal lines remain) */
.grid-item:nth-child(-n+4) {
  border-top-color: transparent;
}

.grid-item:nth-last-child(-n+4) {
  border-bottom-color: transparent;
}

.grid-item:nth-child(4n + 1) {
  border-left-color: transparent;
}

.grid-item:nth-child(4n) {
  border-right-color: transparent;
}
.grid-header{
  width: 80%;
  text-align: center;
  font-family: Arial, Helvetica, sans-serif;
  margin: 11% auto 0% auto;
}

.grid-header h3{
  font-size: 4rem;
  color:#6D98E3;
  font-weight: 600;
}

.grid-header p{
  font-size: 1.8rem;
  font-weight: 400;
  color: #fff;
}

canvas{
  position: relative;
  background: transparent; /* Background Color of slot */
  height: 100%;
  width: 100%;
  margin-top: 8%;
  z-index: 1;
}


#sub-head{
  font-size: 32px;
  padding-top: 3%;
  padding-bottom: 1%;
  text-align: center;
  color: #ffffff;
  font-weight: 500;
  opacity: 0;
  font-family: Arial, Helvetica, sans-serif;
  transition: opacity 2s ease; 
}

#sub-head.active {
  opacity: 1;
}

#cards{
  opacity: 0;
  transition: opacity 2s ease;
}

#cards.active {
  opacity: 1;
}

#navbar {
  display: grid;
  min-height: 100px;
  grid-auto-flow: column;
  background-color: #fcfcfc;
  grid-gap: 1.5em;
  padding: 0 40px;
  -webkit-box-shadow: -1px 4px 5px 0px rgba(209, 205, 209, 1);
  -moz-box-shadow: -1px 4px 5px 0px rgba(209, 205, 209, 1);
  box-shadow: -1px 4px 5px 0px rgba(209, 205, 209, 1);
}

#logo {
  display: grid;
  justify-content: start;
  align-content: center;
  font-family: "Open Sans", sans-serif;
  font-size: 30px;
  font-weight: 700;
  color: #000;
  text-transform: uppercase;
}

.logo span {
  color: #0474bc;
}

#links {
  display: grid;
  justify-content: left;
  align-content: center;
  grid-auto-flow: column;
  grid-gap: 2.5em;
  font-family: "Open Sans", sans-serif;
}

#links a {
  position: relative;
  text-decoration: none;
  display: inline-block;
  color: #020617;
  text-transform: uppercase;
  font-weight: bold;
  font-size: 1.5rem;
}

/* Color change */
#links a:hover {
  color: #6D98E3;
  
}

/* Underline bar (collapsed in center by default) */
#links a::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -4px;
  transform: translateX(-50%);
  width: 0%;
  height: 3px;
  background: #6D98E3;
  transition: width 0.35s ease;
  box-shadow: 0 2px 4px rgba(4, 116, 188, 0.4);
  border-radius: 2px;
}

/* Expand underline outward from center */
#links a:hover::after {
  width: 100%;
}

/* =======================
******* Mobile Menu ******
========================*/
.sidenav {
  height: 100%;
  width: 0;
  position: fixed;
  z-index: 2000;
  top: 0;
  left: 0;
  background-color: #fff;
  overflow-x: hidden;
  transition: 0.5s;
  padding-top: 60px;
}

.sidenav a {
  padding: 8px 8px 8px 32px;
  text-decoration: none;
  font-size: 25px;
  color: #020617;
  display: block;
  transition: 0.3s;
}

.sidenav a:hover {
  color: #6D98E3;
}

.sidenav .closebtn {
  position: absolute;
  top: 0;
  right: 25px;
  font-size: 36px;
  margin-left: 50px;
}

a {
  font-family: "Open Sans", sans-serif;
}

.card-container{
  display: flex;
  flex-direction: row;
  justify-content: center;   /* centers cards horizontally */
  align-items: center;       /* centers cards vertically (optional) */
  gap: 3rem;
  margin: 4%;
}

.card {
  border: 1px solid #6D98E3;
  position: relative;
  padding: 2rem;
  background: #020617;
  overflow: hidden;
  border-radius: 1rem;
  color: #fff;
  width: 33%;
}

.card::before {
  content: "";
  width: 1000px;
  height: 1000px;
  position: absolute;
  left: 50%;
  top: 50%;
  animation: rotating 3s infinite cubic-bezier(0.45, 0, 0.55, 1);
  transform-origin: center;
  background: conic-gradient(rgba(255,255,255,.6), transparent, transparent, rgba(255,255,255,.3), transparent, transparent, rgba(255,255,255,.6))
}

.card::after {
  content: "";
  width: calc(100% - 8px);
  height: calc(100% - 8px);
  position: absolute;
  left: 4px;
  top: 4px;
  background: inherit;
  border-radius: .8rem;
  z-index: 1;
}

.card-content {
  position: relative;
  z-index: 10;
  text-align: center;
  font-family: Helvetica;
}

@keyframes rotating {
  from {
    transform: translate(-500px, -500px) rotate(0deg);
  }
  to {
    transform: translate(-500px, -500px) rotate(360deg);
  }
}

h2 {
  font-size: 1.75rem;
}
.card-content p {
  font-size: 1.25rem;
}
button {
  background: #F59E0B;
  border: 2px solid #F59E0B;
  border-radius: 4px;
  padding: 8px 16px;
  color: black;
  background-image: linear-gradient(to right, #f97316, #F59E0B);
  margin: 1rem 0 0 0;
  text-shadow: 1px 1px 3px #F59E0B;
  font-size: 1.1rem;
  width: 13rem;
  cursor: pointer;
}


.sticky-container {
  position: relative;
  display: flex;
  flex-direction: column;
  max-width: 100%;
  gap: 24px;
  margin: 30px auto;
  height: 4040px;
  align-items: center;
  background: #fff;
  padding: 90px;
}

.sticky-container h3{
  font-size: 4rem;
  color:#6D98E3;
  font-weight: 600;
  font-family: Arial, Helvetica, sans-serif;
  text-align: center;
}

.sticky-card {
  width: 100%;
  margin: 0 20px;
  box-sizing: border-box;
  background: #020617;
  min-height: 400px;
  border-radius: 32px;
  position: sticky;
  display:flex;
  flex-direction: column;
  align-items: center;
  justify-content: start; 
}

.sticky-card .subject{
  width: 48%;
}

.sticky-card h4 {
  font-family : 'system-ui', sans-serif;
  font-size: 4.5rem;
  font-weight: medium;
  color: #f97316;
}

.sticky-card a{
  margin-bottom: 5%;
  text-decoration: none;
  font-size: 2.1rem;
  color: #f97316; 
  font-weight: bold;
  padding: 0.5rem 0.75rem;
  background: #fff;
  border: 1px solid #f97316;
  border-radius: 1.5rem;
  transition: 0.5s ease;
}

.sticky-card a:hover{
color: #fff;
background: #f97316;
}

.sticky-card td {
  font-family : 'system-ui', sans-serif;
  font-size: 1.5rem;
  font-weight: medium;
  color: #020617;
}

.one {
  top: 50px;
  background: #fff;
  border: 3px solid #020617;
}
.two {
  top: 80px;
  background: #fff;
  border: 3px solid #020617;
}
.three {
  top: 110px;
  background: #fff;
  border: 3px solid #020617;
}

.four {
  top: 140px;
  background: #fff;
  border: 3px solid #020617;
}

.five {
  top: 170px;
  background: #fff;
  border: 3px solid #020617;
}

.six {
  top: 200px;
  background: #fff;
  border: 3px solid #020617;
}

.seven {
  top: 230px;
  background: #fff;
  border: 3px solid #020617;
}

.eight {
  top: 260px;
  background: #fff;
  border: 3px solid #020617;
}

.contact-header{
  background: #fff;
  padding: 20px 0px;
  text-align: center;
}
.contact-header h3{
  font-size: 4rem;
  color:#6D98E3;
  font-weight: 600;
  font-family: Arial, Helvetica, sans-serif;
}

#form-wrapper {
  width: 100%;
  max-width: 700px;
  margin: 4rem auto;
  padding: 3rem;
  background: #020617;
  border-radius: 20px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.15);
  border: 2px solid #ffffff;
}

#form-wrapper form {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

#form-wrapper input,
#form-wrapper textarea {
  width: 100%;
  padding: 1rem 1.2rem;
  font-size: 1.1rem;
  font-family: Arial, Helvetica, sans-serif;
  color: #020617;
  background: #f7f7f7;
  border: 2px solid #e2e8f0;
  border-radius: 12px;
  transition: all 0.25s ease;
}

#form-wrapper input::placeholder,
#form-wrapper textarea::placeholder {
  color: #64748b;
  letter-spacing: 0.03em;
}

#form-wrapper input:focus,
#form-wrapper textarea:focus {
  background: #ffffff;
  border-color: #6D98E3;
  box-shadow: 0 0 0 3px rgba(109,152,227,0.3);
  outline: none;
}

#form-wrapper textarea {
  min-height: 180px;
  resize: vertical;
}

#form-wrapper button {
  width: 100%;
  padding: 1rem 1.2rem;
  font-size: 1.25rem;
  font-weight: 600;
  color: #fff;
  background: linear-gradient(to right, #6D98E3, #020617);
  border: none;
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.3s ease;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

#form-wrapper button:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(32, 6, 23, 0.3);
}

#form-wrapper button:active {
  transform: translateY(0px);
  box-shadow: none;
}

/* Mobile to Tablet  */
@media (min-width: 320px) and (max-width: 767px) {
  #links,
  .mobile-menu {
    display: none;
  }
  #logo {
    display: inline-grid;
    grid-template-columns: auto auto;
    grid-gap: 70px;
  }
}

/* Tablet to Desktop */
@media (min-width: 768px) {
  .mobile-btn {
    display: none;
  }
}


@media (max-width: 768px) {
  canvas {
    height: 20%;
  }
  .card-container{
    display: flex;
    flex-direction: column;
    flex-wrap: wrap;
  }
  .card{
    width: 90%;
  }
  #sub-head{
    font-size: 22px;
  } 
  .grid-container {
    grid-template-columns: repeat(2, 1fr);
    grid-template-rows: repeat(4, 150px); /* adjust height if needed */
    width: 90%;
  }
  .grid-header p{
    font-size: 1.3rem;
  }
  .grid-header h3{
    font-size: 2.5rem;
  }

  /* Recalculate borders for mobile layout */

  /* Remove top borders on first row */
  .grid-item:nth-child(-n+2) {
    border-top-color: transparent;
  }

  /* Remove bottom borders on last row */
  .grid-item:nth-last-child(-n+2) {
    border-bottom-color: transparent;
  }

  /* Remove left borders for column 1 */
  .grid-item:nth-child(2n + 1) {
    border-left-color: transparent;
  }

  /* Remove right borders for column 2 */
  .grid-item:nth-child(2n) {
    border-right-color: transparent;
  }
  .section-header h3{
  font-size: 2.5rem;

}

.section-header p{
  font-size: 1rem;
}

/* Container: full width, small padding, still tall enough for sticky stack */
  .sticky-container {
    max-width: 100%;
    width: 100%;
    padding: 24px 12px;   /* reduce padding to avoid overflow */
    margin: 16px auto;
    height: 3200px;       /* keep a tall scroll area for sticky */
    gap: 16px;
  }

  .sticky-container h3{
    font-size: 2.5rem;
  }

  /* Cards: stay sticky, but fit viewport */
  .sticky-card {
    width: 100%;
    margin: 0;            /* remove 0 20px */
    padding: 20px 16px;   /* add internal padding so content stays on card */
    min-height: 320px;    /* slightly smaller for mobile */
    position: sticky;     /* keep sticky */
    display: flex;
    align-items: flex-start; /* don't center; helps text stay inside */
  }
  .sticky-card a{
    font-size: 1.3rem;
    margin-top: 1rem;
  }

  /* Reduce top offsets so cards don't smush */
  .one   { top: 16px; }
  .two   { top: 48px; }
  .three { top: 80px; }
  .four  { top: 112px; }
  .five  { top: 144px; }
  .six  { top: 176px; }
  .seven  { top: 208px; }
  .eight  { top: 240px; }

  /* Typography scaling + containment */
  .sticky-card h4 {
    font-size: 1.6rem;
    width: 100%;
    text-align: left;
    margin: 0 0 12px 0;
    display: flex;
  }

  .sticky-card table {
    width: 100%;
    border-collapse: collapse;
  }

  .sticky-card td {
    font-size: 1rem;
    word-break: break-word;  /* prevents long text from pushing width */
    display: flex;
  }
  }