/* =========================================================
   ALULA AI
   Opal edition
   ========================================================= */

:root {
  --opal: #dddcd8;
  --opal-light: #e8e7e3;
  --opal-blue: #b9dce2;
  --opal-lilac: #d2c6df;
  --opal-pink: #dfc5d1;
  --opal-gold: #d8c78f;

  --ink: #17232b;
  --ink-soft: #3f5058;
  --peacock: #176c73;
  --turquoise: #3f9299;
  --gold: #9b7d3f;

  --line: rgba(23, 35, 43, 0.16);
  --glass: rgba(232, 231, 227, 0.76);

  --page-width: 1180px;
  --text-width: 720px;

  --space-xs: 0.5rem;
  --space-sm: 1rem;
  --space-md: 2rem;
  --space-lg: 4rem;
  --space-xl: 7rem;

  --radius: 1.25rem;
}


/* =========================================================
   FOUNDATION
   ========================================================= */

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background: var(--opal);
}

body {
  min-height: 100vh;
  margin: 0;

  color: var(--ink);
  background:
    radial-gradient(
      circle at 15% 10%,
      rgba(220, 239, 241, 0.9),
      transparent 32rem
    ),
    radial-gradient(
      circle at 85% 25%,
      rgba(233, 227, 239, 0.75),
      transparent 30rem
    ),
    radial-gradient(
      circle at 55% 85%,
      rgba(241, 227, 232, 0.55),
      transparent 34rem
    ),
    linear-gradient(
      145deg,
      var(--opal-light),
      var(--opal) 55%,
      #ece9e2
    );

  font-family:
    Inter,
    "Helvetica Neue",
    Helvetica,
    Arial,
    sans-serif;

  font-size: 1rem;
  line-height: 1.65;

  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
}


/* =========================================================
   TYPOGRAPHY
   ========================================================= */

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

h1,
h2,
h3 {
  line-height: 1.08;
  font-weight: 500;
  letter-spacing: -0.035em;
}

h1 {
  max-width: 950px;
  margin-bottom: 1.75rem;

  font-size: clamp(3rem, 8vw, 7.4rem);
  line-height: 0.95;
}

h2 {
  margin-bottom: 1rem;
  font-size: clamp(1.7rem, 3vw, 2.7rem);
}

p {
  color: var(--ink-soft);
}

.eyebrow {
  margin-bottom: 1.5rem;

  color: var(--peacock);

  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}


/* =========================================================
   PAGE STRUCTURE
   ========================================================= */

main {
  width: min(calc(100% - 3rem), var(--page-width));
  margin-inline: auto;
}

.hero,
.page-hero,
.services-hero {
  position: relative;

  display: flex;
  min-height: 68vh;
  flex-direction: column;
  justify-content: center;

  padding: var(--space-xl) 0 var(--space-lg);
}

.hero::before,
.page-hero::before,
.services-hero::before {
  position: absolute;
  z-index: -1;
  top: 12%;
  right: 2%;

  width: min(32vw, 390px);
  aspect-ratio: 1;

  border: 1px solid rgba(79, 159, 163, 0.18);
  border-radius: 52% 48% 62% 38% / 44% 58% 42% 56%;

  background:
    linear-gradient(
      135deg,
      rgba(255, 255, 255, 0.42),
      rgba(220, 239, 241, 0.24),
      rgba(233, 227, 239, 0.28),
      rgba(232, 223, 195, 0.18)
    );

  box-shadow:
    inset 0 0 4rem rgba(255, 255, 255, 0.32),
    0 2rem 6rem rgba(23, 35, 43, 0.05);

  content: "";
  transform: rotate(-9deg);
}

.hero > p:not(.eyebrow),
.page-hero > p:not(.eyebrow),
.services-hero > p:not(.eyebrow) {
  max-width: 680px;
  margin-bottom: 2rem;

  font-size: clamp(1.1rem, 2vw, 1.35rem);
}


/* =========================================================
   LINKS / CALL TO ACTION
   ========================================================= */

.hero > a,
.page-hero > a,
.services-hero > a,
.error-page > a {
  align-self: flex-start;

  padding-bottom: 0.3rem;

  border-bottom: 1px solid var(--gold);

  color: var(--ink);

  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-decoration: none;

  transition:
    color 180ms ease,
    border-color 180ms ease;
}

.hero > a:hover,
.page-hero > a:hover,
.services-hero > a:hover,
.error-page > a:hover {
  border-color: var(--peacock);
  color: var(--peacock);
}


/* =========================================================
   SERVICES
   ========================================================= */

.services {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));

  margin-bottom: var(--space-xl);

  border-top: 1px solid var(--line);
  border-left: 1px solid var(--line);
}

.services article {
  min-height: 250px;
  padding: clamp(1.75rem, 4vw, 3.5rem);

  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);

  background: rgba(250, 248, 243, 0.32);

  transition:
    background 220ms ease,
    transform 220ms ease;
}

.services article:hover {
  background: rgba(255, 255, 255, 0.42);
}

.services article p {
  max-width: 470px;
  margin-bottom: 0;
}


/* =========================================================
   ABOUT
   ========================================================= */

.about {
  max-width: 900px;
  margin-bottom: var(--space-xl);
  padding: clamp(2rem, 5vw, 4.5rem);

  border: 1px solid var(--line);
  border-radius: var(--radius);

  background:
    linear-gradient(
      135deg,
      rgba(255, 255, 255, 0.36),
      rgba(220, 239, 241, 0.18),
      rgba(233, 227, 239, 0.2)
    );

  backdrop-filter: blur(14px);
}

.about h2 {
  max-width: 650px;
  margin-bottom: 2rem;
}

.about p {
  max-width: var(--text-width);
  font-size: 1.08rem;
}


/* =========================================================
   CONTACT
   ========================================================= */

.contact {
  max-width: 780px;
  margin-bottom: var(--space-xl);
  padding: clamp(2rem, 5vw, 4rem) 0;

  border-top: 1px solid var(--line);
}

.contact p {
  max-width: 650px;
  font-size: 1.08rem;
}

.contact a {
  color: var(--peacock);
  text-decoration-color: rgba(23, 108, 115, 0.35);
  text-underline-offset: 0.2em;
}


/* =========================================================
   404
   ========================================================= */

.error-page {
  align-items: center;
  text-align: center;
}

.error-page h1 {
  font-size: clamp(2.8rem, 7vw, 6rem);
}

.error-page > p:not(.eyebrow) {
  margin-inline: auto;
}

.ruby-slippers {
  margin: 0 0 2rem;

  font-size: clamp(3rem, 8vw, 6rem);
  line-height: 1;

  filter: drop-shadow(
    0 1rem 1.5rem rgba(167, 139, 80, 0.15)
  );
}


/* =========================================================
   ACCESSIBILITY
   ========================================================= */

a:focus-visible {
  outline: 2px solid var(--peacock);
  outline-offset: 5px;
}

::selection {
  background: var(--opal-blue);
  color: var(--ink);
}


/* =========================================================
   SMALL SCREENS
   ========================================================= */

@media (max-width: 760px) {
  :root {
    --space-xl: 5rem;
  }

  main {
    width: min(calc(100% - 2rem), var(--page-width));
  }

  .hero,
  .page-hero,
  .services-hero {
    min-height: auto;
    padding-top: 5rem;
  }

  .hero::before,
  .page-hero::before,
  .services-hero::before {
    top: 8%;
    right: -10%;
    width: 55vw;
  }

  .services {
    grid-template-columns: 1fr;
  }

  .services article {
    min-height: auto;
  }
}


/* =========================================================
   REDUCED MOTION
   ========================================================= */

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}

/* =========================================================
   Site header + footer
   ========================================================= */

.site-header {
  width: min(calc(100% - 3rem), var(--page-width));
  margin-inline: auto;
  padding: 1.5rem 0;

  border-bottom: 1px solid var(--line);

  color: var(--ink);
}

.site-footer {
  width: min(calc(100% - 3rem), var(--page-width));
  margin-inline: auto;
  padding: 2rem 0 3rem;

  border-top: 1px solid var(--line);

  color: var(--ink-soft);
  font-size: 0.9rem;
}

@media (max-width: 760px) {
  .site-header,
  .site-footer {
    width: min(calc(100% - 2rem), var(--page-width));
  }
}