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

:root {
  --bg: oklch(12% 0 0);
  --surface: oklch(16% 0 0);
  --text: oklch(92% 0 0);
  --text-muted: oklch(55% 0 0);
  --accent: oklch(75% 0.15 70);
  --accent-dim: oklch(60% 0.12 70);
  --border-default: oklch(22% 0 0);
  --radius-card: 10px;
  --radius-pill: 100px;
  --season-tint: oklch(25% 0.04 95 / 0.15);
}

[data-season="winter"] { --season-tint: oklch(25% 0.03 230 / 0.15); }
[data-season="spring"] { --season-tint: oklch(25% 0.04 25 / 0.15); }
[data-season="summer"] { --season-tint: oklch(25% 0.04 95 / 0.15); }
[data-season="autumn"] { --season-tint: oklch(25% 0.04 50 / 0.15); }

.season-canvas {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

header,
main,
footer {
  position: relative;
  z-index: 1;
}

html {
  background: var(--bg);
  color: var(--text);
  font-family: 'Space Grotesk', -apple-system, system-ui, sans-serif;
  font-size: 1rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: -1;
  background:
    radial-gradient(ellipse 80% 50% at 50% 20%, var(--season-tint), transparent 70%);
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: -1;
  opacity: 0.035;
  filter: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.75' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E#n");
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.75' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

body {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
}

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

/* ── Header ── */
header {
  padding: clamp(1.5rem, 2vw, 2.5rem) clamp(1.5rem, 5vw, 4rem);
}

.wordmark {
  font-size: 1.35rem;
  font-weight: 300;
  letter-spacing: 0.4em;
  color: var(--text);
  text-transform: uppercase;
}

/* ── Main ── */
main {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.hero {
  padding: clamp(3rem, 6vw, 7rem) clamp(1.5rem, 5vw, 4rem) clamp(3rem, 5vw, 5rem);
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  width: 100%;
}

.hero-logo {
  height: clamp(60px, 5vw + 30px, 100px);
  width: auto;
  margin-bottom: 2rem;
}

.cards-section {
  padding: clamp(2rem, 4vw, 4rem) clamp(1.5rem, 5vw, 4rem) clamp(4rem, 7vw, 8rem);
  width: 100%;
  max-width: 1280px;
}

/* ── Cards ── */
.card-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
}

@media (min-width: 768px) {
  .card-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
  }
}

.card {
  background: var(--surface);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-card);
  padding: 1.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  overflow: hidden;
}

.card-media {
  margin: -1.75rem -1.75rem 0.25rem;
  height: 200px;
  display: flex;
  align-items: center;
  justify-content: center;
  background:
    radial-gradient(ellipse 60% 80% at 50% 100%, oklch(22% 0.04 70 / 0.5), transparent 70%),
    linear-gradient(180deg, oklch(10% 0 0) 0%, oklch(14% 0 0) 100%);
  border-bottom: 1px solid var(--border-default);
  overflow: hidden;
  position: relative;
}

.card-media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 60%, oklch(16% 0 0 / 0.4) 100%);
  pointer-events: none;
}

.card-media img {
  height: 88%;
  width: auto;
  max-width: 90%;
  object-fit: contain;
  border-radius: 14px;
  box-shadow:
    0 1px 0 oklch(100% 0 0 / 0.06) inset,
    0 18px 40px oklch(0% 0 0 / 0.55),
    0 4px 12px oklch(0% 0 0 / 0.35);
  position: relative;
  z-index: 1;
}

@media (prefers-reduced-motion: no-preference) {
  .card-media img {
    transition: transform 380ms cubic-bezier(0.16, 1, 0.3, 1);
  }

  .card:hover .card-media img {
    transform: translateY(-4px) scale(1.04);
  }
}

@media (prefers-reduced-motion: no-preference) {
  .card {
    transition: transform 220ms ease, border-color 220ms ease;
  }

  .card:hover {
    transform: translateY(-4px);
    border-color: var(--accent);
  }
}

.card-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.card-logo {
  width: 36px;
  height: 36px;
  object-fit: contain;
  flex-shrink: 0;
  border-radius: 6px;
}

.card-logo-invert {
  filter: invert(1);
}

.card-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text);
  line-height: 1.2;
}

.card-desc {
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.5;
}

.card-stat {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-top: auto;
}

.card-link {
  display: inline-block;
  margin-top: 0.5rem;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: 0.03em;
}

@media (prefers-reduced-motion: no-preference) {
  .card-link {
    transition: color 150ms ease;
  }

  .card-link:hover {
    color: var(--accent-dim);
  }
}

.card-apps {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 0.75rem;
}

.card-apps a {
  display: inline-flex;
  align-items: center;
}

.card-apps img {
  height: 38px;
  width: auto;
  display: block;
}

@media (prefers-reduced-motion: no-preference) {
  .card-apps a {
    transition: opacity 150ms ease, transform 150ms ease;
  }

  .card-apps a:hover {
    opacity: 0.85;
    transform: translateY(-1px);
  }
}

/* ── Buttons ── */
.cta {
  display: inline-block;
  background: var(--accent);
  color: oklch(12% 0 0);
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: 0.04em;
  padding: 0.8rem 1.75rem;
  border-radius: var(--radius-pill);
}

@media (prefers-reduced-motion: no-preference) {
  .cta {
    transition: background 200ms ease, transform 150ms ease;
  }

  .cta:hover {
    background: var(--accent-dim);
    transform: translateY(-2px);
  }
}

/* ── Footer ── */
footer {
  padding: clamp(1.5rem, 2.5vw, 2.5rem) clamp(1.5rem, 5vw, 4rem);
  border-top: 1px solid var(--border-default);
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  align-items: center;
  justify-content: space-between;
}

.footer-name {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.footer-email {
  font-size: 0.85rem;
  color: var(--text-muted);
}

@media (prefers-reduced-motion: no-preference) {
  .footer-email {
    transition: color 150ms ease;
  }

  .footer-email:hover {
    color: var(--text);
  }
}

.footer-year {
  font-size: 0.85rem;
  color: var(--text-muted);
}
