/* The homepage uses the original gradient and content order. */
.home {
  --home-ink: #f4f3fa;
  --home-muted: #c6c8d6;
  --section-space: clamp(1.75rem, 5vw, 4rem);
  --home-radius: 1.4rem;
  --home-measure: 1080px;
  --frosted-surface: linear-gradient(145deg, #ffffff13, #ffffff06);
  --frosted-shadow: inset 0 1px 0 #ffffff24, 0 12px 32px #00000040;
  --accent: #eeeef1;
  --muted: var(--home-muted);
  background: #12141e;
  color: var(--home-ink);
}

.home footer { --muted: #c6c8d6; }

.home .container, .home .header-inner {
  width: min(calc(100% - 3rem), var(--home-measure));
}

.home main {
  background:
    radial-gradient(ellipse at 90% 26%, #352b48 0%, transparent 46%),
    radial-gradient(ellipse at 8% 55%, #253750 0%, transparent 55%),
    linear-gradient(155deg, #181d2a 0%, #202032 48%, #111520 100%);
}

.home .expertise,
.home .education-section > .container,
.home .services-layout {
  padding: clamp(1.25rem, 4.5vw, 3.25rem);
  border-radius: var(--home-radius);
  background: var(--frosted-surface);
  box-shadow: var(--frosted-shadow);
  backdrop-filter: blur(16px);
}

.home main > :is(.clients, .expertise, .services, .education-section, .contact) {
  margin-block: var(--section-space) 0;
}
.home main > :is(.clients, .services, .education-section) { padding-block: 0; }

.home .home-hero {
  border-radius: 0 0 clamp(1.5rem, 4vw, 3rem) clamp(1.5rem, 4vw, 3rem);
  background:
    radial-gradient(ellipse at 75% 62%, #c2abda34, transparent 57%),
    linear-gradient(180deg, #171b2dbd, #191b3575 82%),
    var(--gradient);
  text-align: center;
}

.home .home-hero-inner {
  display: grid;
  justify-items: center;
  gap: 1.15rem;
  padding-block: clamp(9rem, 15vw, 12.5rem) clamp(6.5rem, 10vw, 8.25rem);
}

.home .home-hero h1 {
  max-width: 20ch;
  font-family: Georgia, serif;
  font-size: clamp(2.85rem, 6.8vw, 5.75rem);
  font-weight: 400;
  line-height: 1.08;
  letter-spacing: -.015em;
  text-wrap: balance;
}

.home .home-hero h1 em {
  color: #ffffff;
  font-style: italic;
  font-weight: 400;
}

.home .home-hero p {
  max-width: 34ch;
  color: white;
  font-size: clamp(1.03rem, 2vw, 1.25rem);
  text-wrap: balance;
}

.home .home-hero .button { margin-top: .55rem; color: white; }
.home .highlights {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: .85rem;
  position: relative;
  margin-top: -2.75rem;
}

.home .highlights article {
  display: block;
  min-width: 0;
  padding: clamp(1.25rem, 3vw, 2rem);
  border-radius: var(--home-radius);
  background: var(--frosted-surface);
  box-shadow: var(--frosted-shadow);
  backdrop-filter: blur(14px);
}

.home .highlights img {
  width: 43px;
  height: 43px;
  padding: .55rem;
  border-radius: .8rem;
  background: #eaf3fb;
  filter: none;
}

.home .highlights article:nth-child(2) img { background: #e6edf4; }
.home .highlights article:nth-child(3) img { background: #e5eef3; }

.home .highlights h2 {
  margin-top: .85rem;
  font-size: 1.2rem;
  line-height: 1.2;
}

.home .highlights p { color: var(--home-muted); line-height: 1.6; }
.home :is(.expertise, .services, .education-section) h2 {
  font: 400 clamp(2.25rem, 5vw, 4rem)/1.08 Georgia, serif;
  letter-spacing: -.045em;
}
.home :is(.clients, .services) > .container {
  --muted: #4d5365;
  --accent: #465574;
  padding: clamp(1.25rem, 4.5vw, 3.25rem);
  border-radius: var(--home-radius);
  background: linear-gradient(135deg, #f6f7fb, #dce1ed);
  color: #25283a;
  box-shadow: var(--frosted-shadow);
}
.home .clients .logo-grid img { filter: invert(1); opacity: .92; }
.home .clients h2 { font-size: clamp(1.75rem, 4vw, 2.6rem); }
.home .logo-grid { grid-template-columns: repeat(6, minmax(0, 1fr)); gap: clamp(.35rem, 2.5vw, 2rem); margin-top: 1.5rem; }

.home .section-intro .lede { margin-top: .8rem; }
.skills-directory {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-top: 1.7rem;
  border-block: 1px solid #b8c3e030;
}
.skills-directory article {
  padding: 1.5rem clamp(1rem, 3vw, 2rem);
  border: 0;
  border-radius: 0;
  background: transparent;
}
.skills-directory article + article { border-left: 1px solid #b8c3e030; }
.skills-directory h3 { font-size: 1.12rem; }
.skills-directory p { line-height: 1.8; }

.services-layout {
  display: grid;
  grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr);
  align-items: center;
  gap: clamp(1.5rem, 5vw, 4rem);
}
.services-layout h2 {
  color: inherit;
  font: 400 clamp(2rem, 4vw, 3rem)/1.08 Georgia, serif;
  letter-spacing: -.035em;
}
.services-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: .65rem 1.25rem;
  margin-top: 1rem;
  color: var(--accent);
}
.services-actions .button { color: inherit; }
.service-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(.75rem, 2vw, 1.25rem);
}
.service-list article {
  min-width: 0;
  padding: clamp(1.2rem, 2.3vw, 1.65rem);
  border-radius: 1.05rem;
  background: #ffffffa8;
  box-shadow: inset 0 1px 0 #ffffff28, 0 5px 14px #25283a18;
}

.service-list h3 { margin: 0; font-size: 1.17rem; line-height: 1.2; }
.service-list p { margin-top: .65rem; color: var(--muted); }

.education-timeline {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1rem;
  margin-top: 2rem;
}
.education-timeline article {
  position: relative;
  padding: 1.05rem .5rem 0 0;
  border-top: 1px solid #abb8dd55;
}
.education-timeline article::before {
  position: absolute;
  top: -.29rem;
  left: 0;
  width: .5rem;
  height: .5rem;
  border-radius: 50%;
  background: #a7b4db;
  content: "";
}
.education-timeline time { display: block; margin-bottom: .6rem; color: var(--accent); font-size: .85rem; }
.education-timeline h3 + p { margin-top: .3rem; }

@media (max-width: 760px) {
  .home .container, .home .header-inner { width: calc(100% - 2rem); }
  .home .highlights { grid-template-columns: 1fr; margin-top: -1.75rem; }
  .skills-directory { grid-template-columns: 1fr; }
  .services-layout { grid-template-columns: 1fr; }
  .skills-directory article + article { border-left: 0; border-top: 1px solid #b8c3e030; }
  .education-timeline { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 1.5rem; }
}

@media (max-width: 440px) {
  .service-list { grid-template-columns: 1fr; }
  .education-timeline { grid-template-columns: 1fr; gap: 0; }
  .education-timeline article { padding: 0 0 1.4rem 1.15rem; border-top: 0; border-left: 1px solid #abb8dd55; }
  .education-timeline article::before { top: .42rem; left: -.29rem; }
  .education-timeline article:last-child { padding-bottom: 0; }
}

@media (hover: hover) {
  .home .highlights article:hover {
    box-shadow: 0 13px 25px #25374e20, 0 3px 7px #25374e0c;
  }
}

@media (hover: hover) and (prefers-reduced-motion: no-preference) {
  .home :is(.highlights article, .service-list article, .logo-grid img, .button) {
    transition: transform 240ms ease, box-shadow 240ms ease, background-color 180ms ease;
  }
  .home :is(.highlights article, .service-list article):hover { transform: translateY(-5px); }
  .home :is(.button, .logo-grid img):hover { transform: translateY(-2px); }
  .home .service-list article:hover { box-shadow: inset 0 1px #ffffff38, 0 12px 24px #25283a26; }
}

@media (prefers-reduced-motion: no-preference) {
  .home .home-hero-inner > * {
    animation: home-appear 650ms cubic-bezier(.22, .65, .32, 1) both;
  }

  .home .home-hero-inner p { animation-delay: 95ms; }
  .home .home-hero-inner .button { animation-delay: 190ms; }

  @supports (animation-timeline: view()) {
    .home :is(.clients .container, .expertise, .services-layout, .education-section .container, .contact-inner) {
      animation: home-appear 1ms ease-out both;
      animation-timeline: view();
      animation-range: entry 0% entry 80%;
    }
  }
}

@keyframes home-appear {
  from { opacity: .65; translate: 0 15px; }
  to { opacity: 1; translate: 0 0; }
}
