@font-face {
  font-family: Cairo;
  src: url("assets/fonts/Cairo-Bold.ttf") format("truetype");
  font-weight: 700;
  font-display: swap;
}

@font-face {
  font-family: "Noto Sans Arabic";
  src: url("assets/fonts/NotoSansArabic-Regular.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}

@font-face {
  font-family: Montserrat;
  src: url("assets/fonts/Montserrat-Latin.woff2") format("woff2");
  font-weight: 400 700;
  font-display: swap;
}

:root {
  --cream: #f7e8d2;
  --gold: #e2a425;
  --orange: #d27728;
  --slate: #2b3439;
  --charcoal: #20292d;
  --ink: #263034;
  --muted: #535c5e;
  --copper: #874411;
  --canvas: #fbf4e9;
  --paper: #fffdf9;
  --line: #e8dac8;
  --edge: clamp(14px, 4vw, 36px);
  --page-width: 1192px;
  --heading-font: Cairo, "Noto Sans Arabic", sans-serif;
  --body-font: "Noto Sans Arabic", Montserrat, Arial, sans-serif;
  --shadow: 0 10px 32px rgba(58, 41, 22, .065);
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background-color: var(--canvas);
  background-image: linear-gradient(155deg, #fffaf3, var(--cream) 60%, #fff7ed);
  color: var(--ink);
  font-family: var(--body-font);
  line-height: 1.65;
}

main {
  position: relative;
  isolation: isolate;
  display: flow-root;
  overflow: clip;
}

main::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: 0 auto auto 50%;
  width: max(100%, 34rem);
  aspect-ratio: 1122 / 1402;
  transform: translateX(-50%);
  pointer-events: none;
  /* Match the cream around each group of dots in the artwork. */
  background:
    radial-gradient(ellipse 8% 4.6% at 17.5% 10.6%, #fcf6eb 78%, transparent),
    radial-gradient(ellipse 5.5% 9.5% at 96% 34.2%, #fcf5e9 77%, transparent),
    radial-gradient(ellipse 4.5% 9.4% at 4.8% 63.5%, #fcf5e9 77%, transparent),
    url("assets/branding/hyperteam-light-background.webp") center / 100% 100% no-repeat;
  mask-image: linear-gradient(#000 62%, transparent);
}

h1, h2, h3, p {
  margin: 0;
}

h1, h2, h3, nav, .eyebrow, .hero-link, .card-action, .closing-link {
  font-family: var(--heading-font);
  font-weight: 700;
  line-height: 1.35;
}

a {
  color: inherit;
  text-decoration: none;
}

a:focus-visible, button:focus-visible {
  outline: 2px solid var(--copper);
  outline-offset: 3px;
}

.skip-link {
  position: fixed;
  inset-block-start: 8px;
  inset-inline-start: 12px;
  z-index: 5;
  padding: 8px 16px;
  border-radius: 8px;
  background: var(--slate);
  color: var(--paper);
  transform: translateY(-140%);
}

.skip-link:focus {
  transform: none;
}

.topbar {
  background: var(--paper);
  border-block-end: 1px solid var(--line);
}

.topbar-inner, .section-wrap, .footer-inner {
  width: min(calc(100% - 2 * var(--edge)), var(--page-width));
  margin-inline: auto;
}

.topbar-inner, .footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px 16px;
}

.topbar-inner {
  min-height: 69px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  color: var(--slate);
  direction: ltr;
  white-space: nowrap;
  font: 700 13px/1 Montserrat, Arial, sans-serif;
  letter-spacing: .055em;
}

.brand img {
  object-fit: contain;
}

.brand b {
  color: var(--copper);
  font-weight: inherit;
}

nav {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 13px;
}

.nav-link, .nav-cta, .hero-link, .closing-link {
  display: inline-flex;
  white-space: nowrap;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  border-radius: 10px;
}

.nav-link {
  padding-inline: 8px;
}

.nav-cta {
  padding-inline: 14px;
  background: var(--slate);
  color: var(--paper);
}

.nav-cta span, .hero-link span, .closing-link span, .card-action span[aria-hidden] {
  font: 400 17px/1 Arial, sans-serif;
}

.nav-cta span {
  color: var(--gold);
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(0, .85fr);
  grid-template-areas: "copy art" "actions art";
  gap: 12px 16px;
  align-items: center;
  width: min(calc(100% - 2 * var(--edge)), var(--page-width));
  margin: 18px auto 0;
  padding: 20px clamp(20px, 4.3vw, 58px);
  border: 1px solid #3e4545;
  border-radius: 24px;
  background: radial-gradient(ellipse at 21% 50%, rgba(226, 164, 37, .13), transparent 41%),
              linear-gradient(125deg, var(--slate), var(--charcoal));
  color: var(--cream);
  box-shadow: 0 14px 32px rgba(43, 52, 57, .13);
}

.eyebrow {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-block-end: 5px;
  color: var(--copper);
  font-size: 12px;
}

.eyebrow::before {
  content: "";
  width: 7px;
  height: 7px;
  flex: none;
  border-radius: 2px;
  background: var(--gold);
}

.hero .eyebrow, .closing .eyebrow {
  color: #f2c76e;
}

.hero-title {
  margin-block-end: 7px;
  color: var(--paper);
  font-size: clamp(39px, 5vw, 68px);
  line-height: 1.12;
}

.hero-title em, .closing em {
  color: var(--gold);
  font-style: normal;
}

.hero-description {
  max-width: 550px;
  color: #f5e9d8;
  font-size: 14px;
  line-height: 1.85;
}

.hero-copy {
  grid-area: copy;
  align-self: end;
}

.hero-actions {
  grid-area: actions;
  align-self: start;
  flex-wrap: wrap;
  gap: 8px;
}

.hero-link {
  justify-content: center;
  gap: 5px;
  min-height: 46px;
  padding: 6px 11px;
  background: var(--cream);
  color: var(--charcoal);
  white-space: normal;
  text-align: center;
  font-size: 13px;
}

.hero-link-primary {
  background: var(--gold);
}

.hero-link-help {
  background: #efcd92;
}

.hero-art {
  grid-area: art;
  position: relative;
  isolation: isolate;
  justify-self: center;
  display: grid;
  place-items: center;
  width: min(100%, 206px);
  aspect-ratio: 1;
  border: 1px solid #8f744b;
  border-radius: 50%;
  background:
    radial-gradient(circle, transparent 60%, rgba(226, 164, 37, .25) 60.5%, transparent 61%),
    radial-gradient(circle, #faecd6 45%, #f4dfba 50%, transparent 51%);
}

.hero-orbit {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.hero-orbit::before, .hero-orbit::after {
  content: "";
  position: absolute;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 12px rgba(226, 164, 37, .45);
}

.hero-orbit::before {
  inset: 14% 12% auto auto;
}

.hero-orbit::after {
  inset: auto auto 15% 11%;
}

.hero-art img {
  width: 49%;
  height: auto;
  filter: drop-shadow(0 5px 6px rgba(43, 52, 57, .14));
}

@media (prefers-reduced-motion: no-preference) {
  .hero-orbit {
    animation: hero-orbit-sweep 3.8s cubic-bezier(.2, .65, .25, 1) both;
  }
}

@keyframes hero-orbit-sweep {
  from { transform: rotate(-95deg); }
  to { transform: rotate(0); }
}

nav a, .card-action, .qr-link, .qr-frame, .channel-card, .closing-link, .qr-close {
  transition: background-color .16s ease, border-color .16s ease,
              color .16s ease, box-shadow .16s ease, translate .16s ease;
}

.hero a:focus-visible, .closing a:focus-visible {
  outline-color: var(--gold);
}

.channels {
  padding-block: 25px 38px;
  scroll-margin-top: 14px;
}

.section-heading {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 12px 24px;
  margin-block-end: 15px;
}

.section-heading h2 {
  font-size: clamp(27px, 3.6vw, 45px);
  line-height: 1.15;
}

.section-note {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
}

.channel-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 13px;
}

.channel-card {
  --card-tint: #f4e8d8;
  --qr-rim: #e9d5b8;
  display: grid;
  grid-template-rows: 1fr auto auto;
  align-items: start;
  gap: 10px;
  min-width: 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 17px;
  background: linear-gradient(145deg, var(--card-tint), var(--paper) 95%);
  box-shadow: var(--shadow);
}

.channel-card.featured {
  --card-tint: #f7e6ba;
  --qr-rim: #e9bb58;
  border-color: #c59442;
}

.channel-card.priority {
  --card-tint: #e8e5de;
  --qr-rim: #ccc7bc;
  border-color: #c7bfb1;
}

.channel-card.priority[data-platform="instagram"] {
  --card-tint: var(--cream);
  --qr-rim: color-mix(in srgb, var(--cream) 72%, var(--gold));
  border-color: color-mix(in srgb, var(--cream) 53%, var(--gold));
}

.priority .card-action {
  background: var(--card-tint);
}

.card-details {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: start;
  gap: 8px 10px;
  min-width: 0;
}

.channel-icon {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 10px;
  background: var(--cream);
  color: var(--copper);
}

.featured .channel-icon {
  background: var(--slate);
  color: var(--gold);
}

.channel-icon svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.card-text {
  min-width: 0;
}

.card-details h3 {
  margin-block-end: 1px;
  font-size: 18px;
  line-height: 1.3;
}

.channel-handle {
  color: var(--muted);
  text-align: right;
  font: 400 11px/1.4 Montserrat, Arial, sans-serif;
  overflow-wrap: anywhere;
}

.channel-description {
  margin-block-start: 4px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.6;
}

.qr-link {
  display: grid;
  justify-items: center;
  gap: 6px;
  justify-self: center;
  width: min(100%, 152px);
  color: var(--copper);
  border-radius: 10px;
}

.qr-frame {
  display: block;
  width: 100%;
  aspect-ratio: 1;
  border: 5px solid var(--qr-rim);
  border-radius: 14px;
  background: white;
}

.qr-frame img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 9px;
}

.qr-caption {
  font: 700 11px/1.35 var(--heading-font);
}

.qr-caption span {
  margin-inline-start: 2px;
  font-family: Arial, sans-serif;
}

.card-action {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 46px;
  padding: 8px 12px;
  border: 1px solid #d5bb95;
  border-radius: 10px;
  background: #fcf0dc;
  color: var(--slate);
  font-size: 13px;
}

.featured .card-action {
  background: var(--gold);
  border-color: #c08a20;
  color: #20292d;
}

.channel-card.without-qr {
  grid-template-rows: 1fr auto;
}

.links-note {
  padding: 20px;
  border: 1px dashed var(--line);
  border-radius: 12px;
  color: var(--muted);
  text-align: center;
  font-size: 14px;
}

.student-help, .about, .closing {
  padding: clamp(20px, 3.2vw, 36px);
  border-radius: 19px;
  scroll-margin-top: 16px;
}

.student-help {
  margin-block: 14px;
  border: 1px solid var(--line);
  background: var(--paper);
}

.student-help h2 {
  margin-block-end: 12px;
  font-size: clamp(22px, 2.6vw, 32px);
}

.service-list {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.service-list li {
  padding: 12px;
  border-inline-start: 2px solid var(--gold);
  border-radius: 8px;
  background: var(--canvas);
}

.service-list h3 {
  margin-block-end: 3px;
  font-size: 16px;
}

.service-list p {
  color: var(--muted);
  font-size: 13px;
}

.about {
  display: grid;
  grid-template-columns: 1.25fr .75fr;
  gap: 20px;
  align-items: center;
  margin-block-start: 14px;
  border: 1px solid var(--line);
  border-inline-start: 3px solid var(--orange);
  background: linear-gradient(125deg, #fcf3e5, #f5e2c6);
}

.about h2 {
  margin-block-end: 5px;
  font-size: clamp(21px, 2.5vw, 30px);
}

.vision-copy h3 {
  margin-block-end: 3px;
  color: #f3ca7b;
  font-size: 16px;
}

.about p {
  color: var(--muted);
  font-size: 14px;
}

.vision-copy {
  padding: clamp(12px, 1.8vw, 22px);
  border-radius: 12px;
  background: linear-gradient(145deg, var(--slate), var(--charcoal));
}

.vision-copy p {
  color: var(--cream);
}

.closing {
  margin-block: 14px 28px;
  background: var(--slate);
  color: var(--cream);
  text-align: center;
}

.closing .eyebrow {
  justify-content: center;
}

.closing h2 {
  margin-block-end: 5px;
  color: var(--paper);
  font-size: clamp(24px, 3.3vw, 37px);
}

.falling-panel {
  position: relative;
  isolation: isolate;
}

.falling-marks {
  position: absolute;
  z-index: -1;
  inset: 0;
  overflow: hidden;
  border-radius: inherit;
  pointer-events: none;
}

.falling-mark {
  --mark-color: var(--gold);
  position: absolute;
  inset-block-start: 0;
  height: 100%;
  width: var(--mark-width);
}

.falling-mark::before {
  content: "";
  display: block;
  width: 100%;
  aspect-ratio: 100 / 193;
  background: var(--mark-color);
  -webkit-mask: url("assets/branding/hyperteam-circuit-shape.webp") center / contain no-repeat;
  mask: url("assets/branding/hyperteam-circuit-shape.webp") center / contain no-repeat;
  transform: translateY(-110%) rotate(var(--mark-angle));
}

.falling-mark:nth-child(3n) {
  --mark-color: var(--cream);
}

.welcome-copy {
  max-width: 580px;
  margin-inline: auto;
  font-size: 14px;
}

.closing-link {
  margin-block-start: 12px;
  padding-inline: 13px;
  border: 1px solid #957643;
  color: #f4ce83;
  font-size: 13px;
}

.footer {
  background: var(--paper);
  border-block-start: 1px solid var(--line);
}

.footer-inner {
  min-height: 66px;
  color: var(--muted);
  font-size: 11px;
}

.qr-dialog {
  width: min(420px, calc(100% - 28px));
  max-height: calc(100% - 28px);
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 19px;
  background: var(--paper);
  color: var(--ink);
  box-shadow: 0 24px 72px rgba(0, 0, 0, .25);
}

.qr-dialog:not([open]) {
  display: none;
}

.qr-dialog::backdrop {
  background: rgba(28, 35, 38, .76);
}

body:has(.qr-dialog[open]) {
  overflow: hidden;
}

.qr-dialog-inner {
  position: relative;
  padding: 22px 16px 16px;
  text-align: center;
}

.qr-close {
  position: absolute;
  inset: 7px auto auto 7px;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--slate);
  cursor: pointer;
  font: 400 29px/1 Arial, sans-serif;
}

.qr-dialog h2 {
  padding-inline: 38px;
  font-size: 23px;
}

.qr-dialog p {
  margin-block-start: 4px;
  color: var(--muted);
  font-size: 13px;
}

.qr-large {
  display: block;
  width: min(100%, 300px);
  height: auto;
  margin: 8px auto 12px;
  background: white;
}

a.card-action:active, .nav-cta:active, .qr-link:active, .qr-close:active {
  translate: 0 1px;
}

@media (hover: hover) {
  .nav-link:hover, .qr-close:hover {
    background: var(--cream);
  }

  .nav-cta:hover {
    background: #485353;
  }

  .hero-link:hover {
    background: var(--paper);
    translate: 0 -2px;
  }

  .channel-card:hover, .channel-card:focus-within {
    border-color: #c59442;
    box-shadow: 0 12px 32px rgba(73, 52, 25, .10);
  }

  .card-action:hover {
    background: #f5dfb8;
    border-color: #a87427;
  }

  .featured .card-action:hover {
    background: #f1bc49;
  }

  .qr-link:hover {
    color: var(--ink);
  }

  .qr-link:hover .qr-frame {
    border-color: #c59442;
    box-shadow: 0 0 0 3px rgba(226, 164, 37, .14);
  }

  .closing-link:hover {
    background: #474039;
    color: var(--paper);
  }
}

@media (max-width: 840px) {
  .channel-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .service-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 841px) {
  main::before {
    inset-block-start: -72px;
  }
}

@media (max-width: 580px) {
  .topbar-inner {
    min-height: 61px;
  }

  .brand {
    gap: 5px;
    font-size: 11px;
  }

  .brand img {
    width: 22px;
    height: 26px;
  }

  nav {
    gap: 3px;
    font-size: 11px;
  }

  .nav-cta, .nav-link {
    gap: 4px;
    padding-inline: 7px;
  }

  .nav-cta span {
    font-size: 13px;
  }

  .hero {
    grid-template-columns: minmax(0, 1fr) clamp(65px, 22vw, 120px);
    grid-template-areas: "copy art" "actions actions";
    gap: 8px;
    margin-block-start: 10px;
    padding: 12px;
    border-radius: 16px;
  }

  .hero-title {
    font-size: clamp(29px, 8.4vw, 43px);
  }

  .hero-description {
    font-size: 12px;
    line-height: 1.6;
  }

  .hero-link {
    padding-inline: 5px;
    font-size: 12px;
  }

  .hero-actions {
    display: grid;
    grid-template-columns: 1fr 1.27fr;
  }

  .hero-link-primary {
    grid-column: 1 / -1;
  }

  .section-heading {
    display: block;
    margin-block-end: 11px;
  }

  .section-heading h2 {
    margin-block-end: 5px;
  }

  .section-note {
    font-size: 12px;
  }

  .channels {
    padding-block: 19px 24px;
  }

  .channel-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 9px;
  }

  .channel-card {
    grid-template-columns: minmax(0, 1fr) clamp(110px, 31vw, 146px);
    grid-template-rows: auto auto;
    align-items: center;
    gap: 8px 10px;
    padding: 10px;
    border-radius: 14px;
  }

  .channel-card.without-qr .card-details {
    grid-column: 1 / -1;
  }

  .card-details {
    grid-template-columns: minmax(0, 1fr);
    gap: 4px;
  }

  .card-details h3 {
    font-size: 17px;
  }

  .channel-icon {
    width: 27px;
    height: 27px;
    border-radius: 8px;
  }

  .channel-icon svg {
    width: 15px;
    height: 15px;
  }

  .card-action {
    grid-column: 1 / -1;
    min-height: 46px;
  }

  .about {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .service-list {
    grid-template-columns: 1fr;
    gap: 8px;
  }

}

@media (max-width: 330px) {
  .topbar-inner {
    gap: 4px;
  }

  .brand {
    letter-spacing: 0;
  }

  .hero-title {
    font-size: 27px;
  }

  .hero {
    grid-template-columns: minmax(0, 1fr) 61px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *, *::before, *::after {
    transition: none !important;
  }

  .falling-marks {
    display: none;
  }
}
