@font-face {
  font-family: "Inter";
  src: url("/fonts/inter-v18-latin-regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Inter";
  src: url("/fonts/inter-v18-latin-500.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg: #1d1d1d;
  --card: #232323;
  --footer: #191919;
  --text: #ffffff;
  --muted: #8a8a8a;
  --accent: #af1616;
  --divider: #000000;
  --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
}

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

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-weight: 400;
  font-size: 1rem;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  font-weight: 500;
  margin: 0;
}

/* Hero */
.hero {
  position: relative;
  background: #2a2a2a;
  /* ~2.1:1 on desktop, never shorter than 320px. Avoid aspect-ratio + min-height,
     which widens the box past the viewport on phones. */
  height: max(320px, calc(100vw / 2.1));
  overflow: hidden;
}

.hero-img {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 85% 30%;
}

.brand {
  position: absolute;
  top: 16px;
  left: 16px;
  color: var(--text);
  font-weight: 500;
  font-size: 1.25rem;
  letter-spacing: -0.01em;
  text-decoration: none;
  text-shadow: 0 1px 6px rgb(0 0 0 / 0.55);
}

/* Sections
   Mobile first: sections size to their content. On desktop (>=1024px)
   each one fills the viewport with its content centered vertically. */
/* Sections run full width (so the divider spans the page); the side padding
   keeps content within 1120px on wide screens. */
.section {
  --gutter: 16px;
  padding: 56px max(var(--gutter), calc((100% - 1120px) / 2));
}

.section + .section {
  border-top: 1px solid var(--divider);
}

.section-title {
  text-align: center;
  font-size: 1.75rem;
  letter-spacing: -0.02em;
  margin-bottom: 24px;
}

/* Flex so a short last row centers instead of hugging the left */
.grid {
  --cols: 1;
  --gap: 16px;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--gap);
}

.grid > .card {
  flex: 0 0 calc((100% - (var(--cols) - 1) * var(--gap)) / var(--cols));
}

.card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  background: var(--card);
  border-radius: 4px;
  padding: 24px 20px;
}

.card h3 {
  color: var(--accent);
  font-size: 1.125rem;
  letter-spacing: -0.01em;
  overflow-wrap: anywhere;
}

.card p {
  font-size: 0.9375rem;
  margin: 12px 0 20px;
  flex-grow: 1;
}

.btn {
  display: inline-block;
  padding: 8px 18px;
  border: 1px solid var(--accent);
  color: var(--accent);
  font-size: 0.875rem;
  text-decoration: none;
  transition: background-color 0.15s, color 0.15s;
}

.btn:hover,
.btn:focus-visible {
  background: var(--accent);
  color: var(--text);
}

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

/* Contact */
.contact {
  text-align: center;
}

.contact .section-title {
  margin-bottom: 8px;
}

.contact p {
  margin: 0;
  font-size: 1.125rem;
}

.email {
  color: var(--text);
  text-decoration: none;
}

.email:hover {
  text-decoration: underline;
}

/* Footer */
.footer {
  background: var(--footer);
  color: var(--muted);
  text-align: center;
  font-size: 0.8125rem;
  padding: 16px;
}

.footer p {
  margin: 0;
}

/* Tablet */
@media (min-width: 641px) {
  .section {
    --gutter: 32px;
    padding-block: 72px;
  }

  .grid {
    --cols: 2;
    --gap: 20px;
  }
}

/* Desktop */
@media (min-width: 1024px) {
  .section {
    min-height: 100vh;
    min-height: 100svh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    --gutter: 40px;
    padding-block: 80px;
  }

  .section-title {
    font-size: 2rem;
    margin-bottom: 32px;
  }

  .grid {
    --cols: 3;
    --gap: 24px;
  }

  .card {
    padding: 28px 28px 32px;
  }
}
