:root {
  --red: #e30613;
  --red-bright: #ff1a27;
  --ink: #0d0d0f;
  --ink-2: #17171b;
  --ink-3: #222228;
  --paper: #ffffff;
  --paper-2: #f5f5f7;
  --text-dark: #1b1b1f;
  --text-dark-muted: #4a4a52;
  --text-light: #ffffff;
  --text-light-muted: #d2d2d8;
  --radius: 18px;
  --shadow: 0 20px 50px rgba(0, 0, 0, 0.25);
  --font-head: "Outfit", system-ui, sans-serif;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --header-h: 72px;
}

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

html { scroll-behavior: smooth; scroll-padding-top: var(--header-h); }

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--text-light);
  background: var(--ink);
  -webkit-font-smoothing: antialiased;
}

img, video { max-width: 100%; display: block; }
a { color: inherit; }

h1, h2, h3, h4 { font-family: var(--font-head); line-height: 1.15; margin: 0; }

.container { width: min(1180px, 100% - 2.5rem); margin-inline: auto; }

/* ---------- Header ---------- */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 50;
  height: var(--header-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 clamp(1rem, 4vw, 3rem);
  transition: background 0.4s ease, box-shadow 0.4s ease;
}
.site-header.is-solid {
  background: rgba(13, 13, 15, 0.92);
  backdrop-filter: blur(10px);
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.35);
}

.brand { display: inline-flex; }
.brand img {
  height: 40px;
  width: auto;
  /* Keeps the light logo legible over bright hero photos. */
  filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.6));
}

.site-nav { display: flex; align-items: center; gap: 2rem; }
.site-nav a {
  text-decoration: none;
  font-weight: 600;
  font-size: 0.98rem;
  color: var(--text-light);
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.5);
  position: relative;
}
.site-nav a:not(.nav-cta)::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -4px;
  height: 2px;
  background: var(--red);
  transform: scaleX(0);
  transition: transform 0.3s ease;
}
.site-nav a:hover::after, .site-nav a:focus-visible::after { transform: scaleX(1); }
.nav-cta {
  background: var(--red);
  padding: 0.55rem 1.2rem;
  border-radius: 999px;
  text-shadow: none !important;
}
.nav-cta:hover { background: var(--red-bright); }

.nav-toggle {
  display: none;
  background: rgba(0, 0, 0, 0.45);
  border: 0;
  border-radius: 10px;
  padding: 10px;
  cursor: pointer;
}
.nav-toggle span {
  display: block;
  width: 24px; height: 2px;
  background: #fff;
  margin: 5px 0;
  transition: transform 0.3s ease, opacity 0.3s ease;
}
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Hero ---------- */
/* Sticky so the following screens slide up over it like a swipe. */
.hero {
  position: sticky;
  top: 0;
  z-index: 0;
  height: 100vh;
  height: 100svh;
  min-height: 520px;
  display: grid;
  place-items: center;
  overflow: hidden;
  isolation: isolate;
}

.hero-bg, .hero-slide, .hero-overlay { position: absolute; inset: 0; }
.hero-bg { z-index: -2; background: var(--ink); }
.hero-slide {
  background-size: cover;
  background-position: center;
  opacity: 0;
  transform: scale(1.02);
  transition: opacity 2s ease;
  will-change: opacity, transform;
}
.hero-slide.is-active {
  opacity: 1;
  animation: kenburns 62s ease-out forwards;
}
.hero-slide.is-active.alt { animation-name: kenburns-alt; }

@keyframes kenburns {
  from { transform: scale(1.02) translate(0, 0); }
  to   { transform: scale(1.16) translate(-2%, -1.5%); }
}
@keyframes kenburns-alt {
  from { transform: scale(1.16) translate(2%, 1%); }
  to   { transform: scale(1.02) translate(0, 0); }
}

.hero-overlay {
  z-index: -1;
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.55) 0%, rgba(0, 0, 0, 0.25) 35%, rgba(0, 0, 0, 0.45) 70%, rgba(0, 0, 0, 0.85) 100%),
    radial-gradient(ellipse at center, rgba(0, 0, 0, 0.15), rgba(0, 0, 0, 0.55));
}

.hero-content {
  text-align: center;
  padding: 0 1.25rem;
  max-width: 900px;
  will-change: transform, opacity;
}
.eyebrow {
  display: inline-block;
  margin: 0 0 1rem;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--text-light);
}
.eyebrow::before {
  content: "";
  display: inline-block;
  width: 28px; height: 3px;
  background: var(--red);
  vertical-align: middle;
  margin-right: 0.75rem;
  border-radius: 2px;
}
.eyebrow-dark { color: var(--text-dark); }

.hero h1 {
  font-size: clamp(2.5rem, 7vw, 5.25rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  text-shadow: 0 4px 30px rgba(0, 0, 0, 0.5);
  animation: rise 1s ease both 0.2s;
}
.section-title span { color: var(--red); }
.hero h1 span, .in-action .section-title span, .services .section-title span, .contact .section-title span { color: var(--red-bright); }

.hero-lead {
  margin: 1.25rem auto 2rem;
  max-width: 640px;
  font-size: clamp(1.05rem, 2vw, 1.25rem);
  color: #f0f0f3;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.6);
  animation: rise 1s ease both 0.45s;
}
.hero-actions {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
  animation: rise 1s ease both 0.7s;
}

@keyframes rise {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: none; }
}

.btn {
  display: inline-block;
  padding: 0.9rem 1.8rem;
  border-radius: 999px;
  font-weight: 600;
  font-size: 1rem;
  text-decoration: none;
  transition: transform 0.25s ease, background 0.25s ease, box-shadow 0.25s ease, color 0.25s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--red); color: #fff; box-shadow: 0 10px 30px rgba(227, 6, 19, 0.4); }
.btn-primary:hover { background: var(--red-bright); }
.btn-ghost { border: 2px solid rgba(255, 255, 255, 0.85); color: #fff; backdrop-filter: blur(4px); }
.btn-ghost:hover { background: #fff; color: var(--ink); }

/* Red scroll arrow */
.scroll-arrow {
  position: absolute;
  bottom: max(2rem, env(safe-area-inset-bottom));
  left: 50%;
  transform: translateX(-50%);
  width: 64px; height: 64px;
  padding: 8px;
  background: none;
  border: 0;
  cursor: pointer;
  animation: bob 1.8s ease-in-out infinite;
}
.scroll-arrow svg { width: 100%; height: 100%; overflow: visible; }
.scroll-arrow path {
  fill: none;
  stroke: var(--red-bright);
  stroke-width: 5;
  stroke-linecap: round;
  stroke-linejoin: round;
  filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.6));
}
.scroll-arrow path:first-child { opacity: 0.55; }
.scroll-arrow:focus-visible { outline: 3px solid #fff; outline-offset: 4px; border-radius: 50%; }

@keyframes bob {
  0%, 100% { transform: translate(-50%, 0); }
  50% { transform: translate(-50%, 12px); }
}

/* ---------- Panels (slide up over the hero) ---------- */
.panel {
  position: relative;
  z-index: 1;
  padding: clamp(4.5rem, 10vw, 7.5rem) 0;
}

.section-title {
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  text-align: center;
  margin-bottom: clamp(2rem, 5vw, 3.5rem);
}
.section-title-left { text-align: left; margin-bottom: 1.5rem; }

/* In Action */
.in-action {
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  align-items: center;
  background: linear-gradient(180deg, var(--ink) 0%, var(--ink-2) 100%);
  border-radius: 28px 28px 0 0;
  box-shadow: 0 -30px 60px rgba(0, 0, 0, 0.5);
}
.in-action .section-title { color: var(--text-light); }

.video-grid {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: clamp(1.25rem, 4vw, 3.5rem);
}
.video-card {
  margin: 0;
  border-radius: var(--radius);
  overflow: hidden;
  background: #000;
  box-shadow: var(--shadow);
  border: 1px solid rgba(255, 255, 255, 0.08);
  position: relative;
}
.video-card::before {
  content: "";
  position: absolute;
  top: 0; left: 0;
  width: 60px; height: 4px;
  background: var(--red);
  z-index: 1;
}
.video-card video {
  width: auto;
  height: min(64vh, 620px);
  object-fit: contain;
  background: #000;
}

/* About */
.about { background: var(--paper); color: var(--text-dark); }
.about-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
  margin-bottom: clamp(3rem, 7vw, 5rem);
}
.about-text p { color: var(--text-dark-muted); margin: 0 0 1rem; }

.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-top: 2rem;
}
.stats div { border-left: 3px solid var(--red); padding-left: 1rem; }
.stats strong {
  display: block;
  font-family: var(--font-head);
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  color: var(--text-dark);
  line-height: 1.1;
}
.stats span { font-size: 0.95rem; color: var(--text-dark-muted); font-weight: 500; }

.statements { display: grid; gap: 1.25rem; }
.statement {
  background: var(--ink);
  color: var(--text-light);
  padding: 2rem;
  border-radius: var(--radius);
  position: relative;
  overflow: hidden;
}
.statement::after {
  content: "";
  position: absolute;
  right: -30px; top: -30px;
  width: 120px; height: 120px;
  background: url("../public/objects/neatcare-object1.png") center / contain no-repeat;
  opacity: 0.18;
}
.statement h3 {
  color: var(--red-bright);
  font-size: 0.95rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  margin-bottom: 0.6rem;
}
.statement p { margin: 0; font-size: 1.2rem; font-family: var(--font-head); font-weight: 500; line-height: 1.45; }

.sub-title {
  font-size: clamp(1.5rem, 3vw, 2rem);
  text-align: center;
  margin-bottom: 2rem;
}
.values {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}
.values li {
  background: var(--paper-2);
  border-radius: var(--radius);
  padding: 1.6rem;
  border-top: 4px solid var(--red);
  transition: transform 0.3s ease, box-shadow 0.3s ease, opacity 0.8s ease;
}
.values li:hover { transform: translateY(-4px); box-shadow: 0 14px 30px rgba(0, 0, 0, 0.08); }
.values h4 { font-size: 1.2rem; margin-bottom: 0.4rem; color: var(--text-dark); }
.values p { margin: 0; color: var(--text-dark-muted); }

/* Services */
.services { background: var(--ink-2); text-align: center; }
.service-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1.25rem;
  text-align: left;
}
.service {
  background: var(--ink-3);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius);
  padding: 1.8rem;
  transition: transform 0.3s ease, border-color 0.3s ease, opacity 0.8s ease;
}
.service:hover { transform: translateY(-4px); border-color: var(--red); }
.service-num {
  font-family: var(--font-head);
  font-weight: 800;
  font-size: 0.95rem;
  color: var(--red-bright);
  letter-spacing: 0.1em;
}
.service h3 { font-size: 1.3rem; margin: 0.5rem 0 0.75rem; color: var(--text-light); }
.service p { margin: 0 0 0.75rem; color: var(--text-light-muted); font-size: 1rem; }
.service ul { margin: 0; padding: 0; list-style: none; }
.service li {
  position: relative;
  padding-left: 1.2rem;
  margin-bottom: 0.35rem;
  color: var(--text-light-muted);
  font-size: 1rem;
}
.service li::before {
  content: "";
  position: absolute;
  left: 0; top: 0.62em;
  width: 7px; height: 7px;
  border-top: 2px solid var(--red-bright);
  border-right: 2px solid var(--red-bright);
  transform: rotate(45deg);
}

/* Contact */
.contact {
  background: linear-gradient(135deg, var(--ink) 0%, #1d0507 100%);
}
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
}
.contact-lead { color: var(--text-light-muted); margin: 0 0 2rem; font-size: 1.1rem; }
.contact-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 1rem; }
.contact-list li {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-left: 4px solid var(--red);
  border-radius: 14px;
  padding: 1.1rem 1.4rem;
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}
.contact-label {
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--red-bright);
}
.contact-list a, .contact-plain {
  font-size: 1.1rem;
  font-weight: 500;
  color: var(--text-light);
  text-decoration: none;
  word-break: break-word;
}
.contact-list a:hover { text-decoration: underline; text-decoration-color: var(--red); }

/* Footer */
.site-footer {
  position: relative;
  z-index: 1;
  background: var(--paper);
  color: var(--text-dark-muted);
  text-align: center;
  padding: 2.5rem 1rem;
}
.site-footer img { height: 44px; width: auto; margin: 0 auto 0.75rem; }
.site-footer p { margin: 0; font-size: 0.95rem; }
.site-footer a { color: var(--text-dark); font-weight: 600; }

/* Scroll reveal */
.reveal { opacity: 0; transform: translateY(30px); transition: opacity 0.8s ease, transform 0.8s ease; }
.reveal.is-visible { opacity: 1; transform: none; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .about-grid, .contact-grid { grid-template-columns: 1fr; }
  .values { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 767px) {
  :root { --header-h: 64px; }
  .brand img { height: 32px; }
  .nav-toggle { display: block; }
  .site-nav {
    position: fixed;
    inset: var(--header-h) 0 auto 0;
    flex-direction: column;
    gap: 0;
    background: rgba(13, 13, 15, 0.97);
    padding: 0.5rem 1.25rem 1.5rem;
    transform: translateY(-130%);
    transition: transform 0.35s ease;
    z-index: -1;
  }
  .site-nav.is-open { transform: none; }
  .site-nav a { width: 100%; padding: 0.9rem 0; font-size: 1.1rem; border-bottom: 1px solid rgba(255, 255, 255, 0.08); }
  .site-nav a::after { display: none; }
  .nav-cta { margin-top: 1rem; text-align: center; border-bottom: 0 !important; }

  .eyebrow { font-size: 0.85rem; letter-spacing: 0.14em; }
  .eyebrow::before { width: 20px; margin-right: 0.5rem; }
  .video-card { width: 100%; }
  .video-card video { width: 100%; height: auto; max-height: 78vh; }
  .values { grid-template-columns: 1fr; }
  .stats { gap: 0.6rem; }
  .stats div { padding-left: 0.6rem; }
  .stats span { font-size: 0.88rem; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition-duration: 0.01ms !important; }
  .reveal { opacity: 1; transform: none; }
}
