/* Home page — Figma frame home (1:111) */

.intro {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--gap-intro);
  width: 100%;
  max-width: var(--width-content);
  /* Fill the first screen and center content (Figma's 1024px auto-layout intent) */
  min-height: 100vh; /* fallback */
  min-height: var(--height-intro);
  box-sizing: border-box;
  padding-inline: var(--space-3);
}

/* Hero name mark: Figma group 20:2876 (326×134).
   Scale via --hero-s only — transform/zoom/isolation on this box break mix-blend-mode. */
.hero {
  --hero-s: 1;
  position: relative;
  width: calc(326px * var(--hero-s));
  height: calc(134px * var(--hero-s));
  flex-shrink: 0;
}

.hero__mark {
  position: absolute;
  inset: 0;
}

.hero__name {
  position: absolute;
  inset: 0 auto auto 0;
  z-index: 0;
  margin: 0;
  font-family: var(--font-display);
  font-size: calc(var(--text-hero-size) * var(--hero-s));
  font-weight: var(--text-hero-weight);
  line-height: calc(var(--text-hero-line-height) * var(--hero-s));
  letter-spacing: calc(var(--text-hero-letter-spacing) * var(--hero-s));
  color: var(--color-ink-primary);
}

.hero__label {
  position: absolute;
  z-index: 5;
  font-family: var(--font-display);
  font-size: calc(var(--text-suffix-size) * var(--hero-s));
  font-weight: var(--text-suffix-weight);
  line-height: calc(var(--text-suffix-line-height) * var(--hero-s));
  letter-spacing: var(--text-suffix-letter-spacing);
}

.hero__label--portfolio {
  top: 0;
  left: calc(7px * var(--hero-s));
  width: calc(147px * var(--hero-s));
  color: var(--color-ink-meta);
  text-align: left;
}

.hero__label--year {
  top: 0;
  left: calc(171px * var(--hero-s));
  width: calc(147px * var(--hero-s));
  color: var(--color-ink-meta);
  text-align: right;
}

.hero__label--surname {
  top: calc(109px * var(--hero-s));
  left: calc(7px * var(--hero-s));
  width: calc(72px * var(--hero-s));
  color: var(--color-ink-name-suffix);
  text-align: left;
}

.hero__label--city {
  top: calc(109px * var(--hero-s));
  left: calc(245px * var(--hero-s));
  width: calc(72px * var(--hero-s));
  color: var(--color-ink-meta);
  text-align: right;
}

.hero__flower-outer,
.hero__flower-outer-solid,
.hero__flower-inner,
.hero__flower-star {
  position: absolute;
  top: calc(11.5px * var(--hero-s));
  left: calc(122px * var(--hero-s));
  display: block;
  width: calc(var(--size-flower) * var(--hero-s));
  height: calc(var(--size-flower) * var(--hero-s));
  pointer-events: none;
}

/* Figma: large petal SCREEN over "Paola" */
.hero__flower-outer {
  z-index: 1;
  mix-blend-mode: screen;
}

/* Figma: duplicate large petal, #F671FF @ 40% opacity, no blend */
.hero__flower-outer-solid {
  z-index: 2;
}

.hero__flower-inner {
  z-index: 3;
}

.hero__flower-star {
  z-index: 4;
}

/* Slow continuous spin — outer petals + center star */
.hero__flower-outer,
.hero__flower-outer-solid {
  transform-origin: 50% 50%;
  animation: flower-spin 90s linear infinite;
}

/* Star is offset in the viewBox — rotate around its own path bounds */
.hero__flower-star path {
  transform-box: fill-box;
  transform-origin: center;
  animation: flower-spin 90s linear infinite;
}

@keyframes flower-spin {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero__flower-outer,
  .hero__flower-outer-solid,
  .hero__flower-star path {
    animation: none;
  }
}

.intro__copy {
  display: flex;
  flex-direction: column;
  gap: var(--space-2-sm);
  width: 100%;
  max-width: var(--width-content);
}

.intro__description {
  width: 100%;
}

.intro__description strong {
  font-weight: 700;
}

.intro__link {
  display: inline-block;
  width: fit-content;
  color: var(--color-ink-primary);
  text-decoration: underline;
  text-underline-offset: 0.12em;
}

.intro__link:hover {
  opacity: 0.7;
}

/* Case study teaser */
.case-teaser {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--gap-case);
  width: 100%;
  padding-bottom: var(--pad-case-bottom);
}

.case-teaser__intro {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--gap-case);
  width: 100%;
  max-width: var(--width-content);
}

.case-teaser__title-block {
  display: flex;
  flex-direction: column;
  gap: var(--gap-case-title);
  width: 100%;
}

.case-teaser__description {
  width: 100%;
  max-width: var(--width-content);
}

.case-teaser__description p + p {
  margin-top: var(--text-case-body-line-height);
}

/* Figma stat-card (13:2023): row gap 8, tile pad 20, radius 8, fill #ECEFF6 */
.case-teaser__stats {
  display: flex;
  flex-direction: row;
  align-items: stretch;
  gap: var(--gap-stats);
  width: 100%;
  max-width: var(--width-content);
}

.stat-card {
  display: flex;
  flex: 1 1 0;
  flex-direction: column;
  gap: var(--gap-case-title);
  min-width: 0;
  margin: 0;
  padding: var(--pad-stat-card);
  background: var(--color-surface-visual);
  border-radius: var(--radius-stat-card);
}

.stat-card p {
  margin: 0;
}

.case-teaser__more {
  width: 100%;
  max-width: var(--width-content);
}

.case-teaser__visuals {
  display: flex;
  flex-direction: row;
  align-items: stretch;
  gap: var(--gap-visuals);
  width: 100%;
  max-width: var(--width-visuals);
}

.visual-card {
  display: flex;
  flex: 1 1 0;
  flex-direction: column;
  align-items: center;
  gap: var(--gap-visual-card);
  min-width: 0;
  max-width: var(--width-visual-card);
  padding: var(--pad-visual-card);
  background: var(--color-surface-visual);
  border-radius: var(--radius-visual-card);
}

.pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: var(--pad-pill-block) var(--pad-pill-inline);
  background: var(--color-pill-bg);
  border-radius: var(--radius-pill);
  font-family: var(--font-body);
  font-size: var(--text-caption-size);
  font-weight: var(--text-caption-weight);
  line-height: var(--text-pill-line-height);
  letter-spacing: var(--text-caption-letter-spacing);
  white-space: nowrap;
}

.pill--before {
  color: var(--color-before);
}

.pill--after {
  color: var(--color-after);
}

.visual-card__media {
  overflow: hidden;
  border-radius: var(--radius-media);
}

.visual-card__media--phone {
  width: var(--size-phone-w);
  max-width: 100%;
}

.visual-card__media--phone img,
.visual-card__media--phone video {
  width: 100%;
  height: auto;
  aspect-ratio: 246 / 533;
  object-fit: cover;
  border-radius: var(--radius-media);
}

.visual-card__media--wide {
  width: 100%;
  max-width: 476px;
}

.visual-card__media--wide img,
.visual-card__media--wide video {
  width: 100%;
  height: auto;
  border-radius: var(--radius-media);
  object-fit: cover;
}

.visual-card__media--msg-before {
  width: 100%;
  max-width: 460px;
}

.visual-card__media--msg-before img {
  width: 100%;
  height: auto;
  border-radius: var(--radius-media);
  object-fit: cover;
}

.visual-card__caption {
  width: 100%;
  max-width: 460px;
}

/* Responsive: stack visuals, scale hero */
@media (max-width: 1100px) {
  .case-teaser__visuals {
    flex-direction: column;
    align-items: center;
  }

  .visual-card {
    max-width: min(var(--width-visual-card), 100%);
    width: 100%;
  }
}

@media (max-width: 720px) {
  .intro {
    gap: var(--space-4);
    padding-block: var(--space-4);
  }

  /* Layout scale only — transform/zoom break mix-blend-mode: screen */
  .hero {
    --hero-s: 0.72;
  }

  .text-case-title {
    font-size: clamp(32px, 8vw, var(--text-case-title-size));
    line-height: 1.1;
    letter-spacing: -0.02em;
  }

  .case-teaser {
    padding-inline: var(--space-3);
  }
}
