/* ============================================================
   Permeon — landing page
   Single full-screen cinematic hero. Matches Figma node 316:3.
   Self-contained: no frameworks, no build step.
   ============================================================ */

:root {
  --text: #f4f4f4;
  --accent: #ff8400;
  --bg: #000000;

  --pad-x: 60px;
  --pad-y: 40px;

  --font-display: "REM", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-body: "Red Hat Display", system-ui, -apple-system, sans-serif;
}

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

html,
body {
  height: 100%;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img {
  display: block;
}

/* ---- Full-screen shell ---- */
.screen {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 100vh;
  min-height: 100svh;
  overflow: hidden;
}

/* ---- Earth backdrop ---- */
.backdrop {
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
}
.backdrop-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}
.backdrop-veil {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.2);
}

/* ---- Header ---- */
.topbar {
  display: flex;
  align-items: center;
  padding: var(--pad-y) var(--pad-x);
}
.logo {
  display: inline-flex;
  align-items: center;
  gap: 7.652px;
  text-decoration: none;
  color: var(--text);
}
.logo-mark {
  width: 32px;
  height: 32px;
  flex-shrink: 0;
}
.logo-word {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 28px;
  line-height: 1;
  letter-spacing: 0.02em; /* scales with font-size */
  color: var(--text);
  white-space: nowrap;
}

/* ---- Hero ---- */
.hero {
  flex: 1 0 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  padding-left: var(--pad-x);
  min-height: 0;
}
.headline {
  font-family: var(--font-display);
  font-weight: 500;
  /* Figma desktop: 56px. Scales down on narrower screens so the three
     fixed lines never overflow before the mobile layout takes over. */
  font-size: clamp(32px, 3.7vw, 56px);
  line-height: 1;
  letter-spacing: -0.02em; /* Figma: -1.12px @ 56 and -0.48px @ 24, both -0.02em */
  color: var(--text);
  text-transform: uppercase;
}
.dot {
  color: var(--accent);
}
.hl-mobile {
  display: none;
}

/* ---- Footer ---- */
.bottombar {
  display: flex;
  align-items: center;
  padding: var(--pad-y) var(--pad-x);
}
.copyright {
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 16px;
  line-height: 1;
  color: var(--text);
  white-space: nowrap;
}

/* ============================================================
   Mobile — matches Figma node 316:5 (402px frame).
   "AUTOMATING" sits on its own line, the rest wraps; padding,
   logo, and type all shrink to the mobile spec.
   ============================================================ */
@media (max-width: 640px) {
  :root {
    --pad-x: 24px;
    --pad-y: 48px;
  }

  .hl-desktop {
    display: none;
  }
  .hl-mobile {
    display: block;
  }

  .hero {
    padding-right: var(--pad-x); /* wrapped headline needs a right margin */
  }
  .headline {
    font-size: 24px;
  }

  .logo {
    gap: 4.174px;
  }
  .logo-mark {
    width: 24px;
    height: 24px;
  }
  .logo-word {
    font-size: 21.913px;
  }

  .copyright {
    font-size: 16px;
  }
}

@media (prefers-reduced-motion: reduce) {
  * {
    animation: none !important;
    transition: none !important;
  }
}
