/* =========================================================
   MEIRELLESSOFTWARE — DESIGN TOKENS

   Color
   --navy-950  #071021   deep background (footer, dark section)
   --navy-900  #0B1B33   panel / card on dark
   --blue-600  #1D4ED8   primary electric blue (dev / MeirellesStock)
   --blue-400  #4C8DFF   lighter blue for accents on dark bg
   --teal-500  #14B8A6   care accent (MeirellesCare)
   --paper     #F6F8FC   light background
   --ink       #0B1220   body text on light
   --slate-500 #64748B   muted text

   Type
   Display  — "Space Grotesk"   headlines, brand mark
   Body     — "Inter"           paragraphs, UI
   Mono     — "JetBrains Mono"  eyebrows, badges, data, terminal lines
   ========================================================= */

:root{
  --navy-950:#071021;
  --navy-900:#0B1B33;
  --blue-600:#1D4ED8;
  --blue-500:#2F6FED;
  --blue-400:#5B93FF;
  --teal-500:#14B8A6;
  --teal-400:#3FD4C2;
  --paper:#F6F8FC;
  --paper-alt:#EEF2FA;
  --ink:#0B1220;
  --slate-500:#5B6778;
  --slate-300:#9AA5B4;
  --line:#E1E7F0;

  --font-display:'Plus Jakarta Sans', sans-serif;
  --font-body:'Inter', sans-serif;
  --font-mono:'JetBrains Mono', monospace;

  --wrap:1180px;
  --radius:16px;
  --radius-sm:10px;
}

*,*::before,*::after{ box-sizing:border-box; }
html{ scroll-behavior:smooth; }
body{
  margin:0;
  font-family:var(--font-body);
  color:var(--ink);
  background:var(--paper);
  -webkit-font-smoothing:antialiased;
  line-height:1.6;
}
img{ max-width:100%; display:block; }
a{ color:inherit; text-decoration:none; }
h1,h2,h3,h4{
  font-family:var(--font-display);
  line-height:1.1;
  margin:0 0 .5em;
  letter-spacing:-0.01em;
}
p{ margin:0 0 1em; color:var(--slate-500); }
.mono{ font-family:var(--font-mono); }
.wrap{ max-width:var(--wrap); margin:0 auto; padding:0 24px; }

@media (prefers-reduced-motion: reduce){
  html{ scroll-behavior:auto; }
  *{ animation-duration:.001ms !important; transition-duration:.001ms !important; }
}

/* ---------- scroll rail (signature element) ---------- */
.scroll-rail{
  position:fixed; top:0; left:0; height:3px; width:0%;
  background:linear-gradient(90deg, var(--blue-600), var(--teal-500));
  z-index:1000;
  transition:width .1s linear;
}

/* ---------- buttons ---------- */
.btn{
  display:inline-flex; align-items:center; gap:8px;
  padding:13px 24px;
  border-radius:999px;
  font-weight:600;
  font-size:.95rem;
  border:1.5px solid transparent;
  transition:transform .15s ease, box-shadow .15s ease, background .15s ease, border-color .15s ease, color .15s ease;
  cursor:pointer;
  white-space:nowrap;
}
.btn-primary{
  background:var(--ink);
  color:#fff;
  box-shadow:0 1px 0 rgba(0,0,0,.05);
}
.btn-primary:hover{ transform:translateY(-2px); box-shadow:0 10px 24px -8px rgba(11,18,32,.4); }
.btn-ghost{
  background:transparent;
  border-color:var(--line);
  color:var(--ink);
}
.btn-ghost:hover{ border-color:var(--ink); transform:translateY(-2px); }
.btn-text{
  padding:13px 4px;
  color:var(--blue-600);
  font-weight:600;
}
.btn-text:hover{ text-decoration:underline; }
.btn-lg{ padding:16px 30px; font-size:1rem; }
.btn-nav{
  background:var(--ink); color:#fff; padding:10px 20px; font-size:.88rem;
}

.section--dark .btn-ghost{ border-color:rgba(255,255,255,.25); color:#fff; }
.section--dark .btn-ghost:hover{ border-color:#fff; }

/* ---------- nav ---------- */
.nav{
  position:sticky; top:0; z-index:100;
  background:var(--paper);
  border-bottom:1px solid transparent;
  transition:border-color .2s ease;
}
.nav.is-scrolled{ border-color:var(--line); box-shadow:0 1px 0 rgba(11,18,32,.03); }
.nav-inner{
  display:flex; align-items:center; justify-content:space-between;
  padding:18px 24px;
}
.brand{ display:flex; align-items:center; gap:10px; }
.brand-symbol{ height:30px; width:auto; }
.brand-wordmark{ height:16px; width:auto; }
.footer-brand{ display:flex; flex-direction:column; align-items:flex-start; }
.footer-brand .brand-symbol{ height:34px; margin-bottom:10px; }
.footer-brand .brand-wordmark{ height:18px; margin-bottom:14px; }
.nav-links{ display:flex; gap:32px; }
.nav-links a{
  font-size:.92rem; font-weight:500; color:var(--slate-500);
  transition:color .15s ease;
}
.nav-links a:hover{ color:var(--ink); }
.nav-toggle{
  display:none; flex-direction:column; gap:5px;
  background:none; border:none; padding:8px; cursor:pointer;
}
.nav-toggle span{ width:22px; height:2px; background:var(--ink); display:block; }

/* ---------- eyebrow / headings ---------- */
.eyebrow{
  display:inline-block;
  font-size:.8rem;
  color:var(--blue-600);
  background:rgba(29,78,216,.08);
  padding:6px 12px;
  border-radius:999px;
  margin-bottom:18px;
  letter-spacing:-0.01em;
}
.section--dark .eyebrow{ color:var(--teal-400); background:rgba(20,184,166,.12); }

/* ---------- hero ---------- */
.hero{ padding:56px 0 80px; overflow:hidden; }
.hero-grid{
  display:grid;
  grid-template-columns:1.05fr .95fr;
  gap:56px;
  align-items:center;
}
.hero-title{
  font-size:clamp(2.4rem, 4.4vw, 3.6rem);
  font-weight:600;
  color:var(--ink);
}
.ink-underline{
  position:relative;
  white-space:nowrap;
}
.ink-underline::after{
  content:"";
  position:absolute; left:0; right:0; bottom:.06em; height:.34em;
  background:linear-gradient(90deg, var(--blue-400), var(--teal-400));
  z-index:-1; opacity:.45; border-radius:3px;
}
.hero-sub{
  font-size:1.08rem;
  max-width:52ch;
  margin-bottom:32px;
}
.hero-actions{ display:flex; gap:14px; margin-bottom:56px; flex-wrap:wrap; }
.hero-stats{
  display:grid; grid-template-columns:repeat(3,1fr); gap:20px;
  border-top:1px solid var(--line); padding-top:28px;
}
.stat{ display:flex; flex-direction:column; gap:6px; }
.stat-num{ font-size:1.3rem; font-weight:600; color:var(--ink); }
.stat-label{ font-size:.82rem; color:var(--slate-500); line-height:1.35; }

/* hero device mockups */
.hero-visual{ position:relative; height:520px; }
.device-stack{ position:relative; width:100%; height:100%; }

.device{
  position:absolute;
  background:var(--navy-950);
  border-radius:14px;
  box-shadow:0 30px 60px -20px rgba(7,16,33,.35);
  overflow:hidden;
}
.device img{ width:100%; height:100%; object-fit:cover; object-position:top; }

.device-laptop{
  width:82%; left:0; top:6%;
  aspect-ratio:16/9.4;
  padding:14px 14px 0;
  border:1px solid rgba(255,255,255,.06);
}
.device-laptop img{ border-radius:4px; height:calc(100% - 0px); }
.device-cam{
  position:absolute; top:6px; left:50%; transform:translateX(-50%);
  width:6px; height:6px; border-radius:50%; background:#1f2b40;
}

.device-phone{
  width:34%; right:2%; bottom:2%;
  aspect-ratio:9/18.5;
  border:6px solid var(--navy-950);
  box-shadow:0 24px 50px -16px rgba(7,16,33,.45), 0 0 0 1.5px rgba(255,255,255,.06);
}
.device-notch{
  position:absolute; top:0; left:50%; transform:translateX(-50%);
  width:34%; height:16px; background:var(--navy-950);
  border-radius:0 0 10px 10px; z-index:2;
}

.chip{
  position:absolute;
  font-size:.72rem; font-weight:600;
  padding:7px 12px; border-radius:999px;
  background:#fff; box-shadow:0 8px 20px -6px rgba(11,18,32,.25);
  border:1px solid var(--line);
}
.chip-windows{ top:2%; left:6%; color:var(--blue-600); }
.chip-android{ bottom:26%; right:34%; color:var(--teal-500); }

/* ---------- generic section ---------- */
.section{ padding:88px 0; }
.section-head{ max-width:640px; margin-bottom:48px; }
.section-head h2{ font-size:clamp(1.9rem,3vw,2.5rem); color:var(--ink); }
.section-sub{ font-size:1.05rem; }
.section--dark{ background:var(--navy-950); color:#fff; }
.section--dark h2, .section--dark h3{ color:#fff; }
.section--dark p{ color:#B7C1D4; }
.section-head--dark{ margin-left:auto; margin-right:auto; text-align:center; }
.section--dark .section-head{ margin-left:auto; margin-right:auto; text-align:center; max-width:600px; }

/* ---------- products ---------- */
.product{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:64px;
  align-items:center;
  padding:48px 0;
}
.product:first-child{ padding-top:0; }
.product:last-child{ padding-bottom:0; }
.product + .product{ border-top:1px solid var(--line); }
.product--care{ grid-template-columns:1fr 1fr; }
.product--care .product-body{ order:1; }
.product--care .product-media{ order:2; }

.product-logo{ height:40px; width:auto; margin-bottom:18px; }
.product h3{ font-size:1.9rem; color:var(--ink); margin-bottom:6px; }
.product-tagline{ font-size:1.08rem; color:var(--ink); font-weight:500; margin-bottom:14px; }
.product-desc{ max-width:52ch; }

.feature-chips{
  list-style:none; margin:0 0 24px; padding:0;
  display:flex; flex-wrap:wrap; gap:8px;
}
.feature-chips li{
  font-size:.82rem; color:var(--ink);
  background:var(--paper-alt);
  border:1px solid var(--line);
  padding:7px 13px; border-radius:999px;
}
.platform-badges{ display:flex; gap:10px; margin-bottom:28px; }
.badge{
  font-size:.75rem; font-weight:600; padding:6px 12px;
  border-radius:6px; letter-spacing:.02em;
}
.product--stock .badge{ background:rgba(29,78,216,.1); color:var(--blue-600); }
.product--care .badge{ background:rgba(20,184,166,.12); color:#0F8F80; }

.product-actions{ display:flex; align-items:center; gap:20px; flex-wrap:wrap; }

/* product media / mockup pairs */
.product-media{ position:relative; }
.mockup-pair{ position:relative; height:420px; }
.mockup-pair--reverse{ }

.frame{
  position:absolute;
  border-radius:14px;
  overflow:hidden;
  box-shadow:0 26px 50px -18px rgba(11,18,32,.3);
  border:1px solid var(--line);
  background:#fff;
}
.frame img{ width:100%; height:100%; object-fit:cover; object-position:top; }

.frame-phone{
  width:210px; aspect-ratio:9/18.5;
  left:22%; top:6%;
  border:6px solid var(--navy-950);
  z-index:2;
}
.frame-phone--back{
  left:auto; right:16%; top:16%;
  transform:rotate(6deg);
  opacity:.9; z-index:1;
}

.frame-laptop{
  width:88%; left:0; top:4%;
  aspect-ratio:16/10;
  z-index:2;
  background:var(--navy-950);
  padding-top:22px;
}
.frame-laptop-bar{
  position:absolute; top:0; left:0; right:0; height:22px;
  background:var(--navy-950);
  display:flex; align-items:center; gap:5px; padding-left:10px;
}
.frame-laptop-bar::before, .frame-laptop-bar::after{
  content:""; width:7px; height:7px; border-radius:50%; background:#3a4863;
}
.frame-laptop--back{
  left:auto; right:0; top:18%;
  width:72%;
  transform:rotate(-4deg);
  opacity:.92; z-index:1;
}

/* ---------- services ---------- */
.services-grid{
  display:grid; grid-template-columns:repeat(4,1fr); gap:24px;
}
.service-card{
  background:var(--navy-900);
  border:1px solid rgba(255,255,255,.08);
  border-radius:var(--radius);
  padding:28px 22px;
}
.service-icon{
  display:inline-block; font-size:.85rem; color:var(--teal-400);
  margin-bottom:18px;
}
.service-card h3{ font-size:1.15rem; margin-bottom:10px; }
.service-card p{ font-size:.92rem; margin:0; }

/* ---------- about ---------- */
.about-grid{
  display:grid; grid-template-columns:.8fr 1.2fr; gap:64px; align-items:center;
}
.about-media{ position:relative; height:340px; display:flex; align-items:center; justify-content:center; }
.about-symbol{ width:280px; height:auto; filter:drop-shadow(0 24px 48px rgba(11,18,32,.2)); }
.about-copy h2{ font-size:clamp(1.8rem,2.6vw,2.3rem); }
.about-lead{ font-size:1.1rem; color:var(--ink); font-weight:500; }
.about-copy p{ max-width:60ch; }

/* ---------- cta ---------- */
.section--cta{
  text-align:center;
  background:linear-gradient(180deg, var(--paper) 0%, var(--paper-alt) 100%);
}
.cta-wrap{ max-width:640px; margin:0 auto; }
.cta-wrap h2{ font-size:clamp(2rem,3.4vw,2.7rem); }
.cta-actions{ display:flex; gap:16px; justify-content:center; margin-top:32px; flex-wrap:wrap; }

/* ---------- footer ---------- */
.footer{ background:var(--navy-950); color:#8B96AA; padding:72px 0 24px; }
.footer-inner{
  display:grid; grid-template-columns:1.4fr 1fr 1fr 1fr; gap:40px;
  padding-bottom:48px; border-bottom:1px solid rgba(255,255,255,.08);
}
.footer-brand p{ margin-top:0; max-width:32ch; font-size:.9rem; }
.footer-col h4{
  font-family:var(--font-body); font-size:.78rem; text-transform:uppercase;
  letter-spacing:.06em; color:#5C6A83; margin-bottom:16px; font-weight:600;
}
.footer-col a{ display:block; font-size:.92rem; margin-bottom:10px; transition:color .15s ease; }
.footer-col a:hover{ color:#fff; }
.footer-bottom{ padding-top:24px; font-size:.82rem; }

/* ---------- reveal-on-scroll ---------- */
[data-reveal]{
  opacity:0; transform:translateY(18px);
  transition:opacity .6s ease, transform .6s ease;
}
[data-reveal].is-visible{ opacity:1; transform:none; }

/* =========================================================
   RESPONSIVE
   ========================================================= */
@media (max-width: 980px){
  .hero-grid{ grid-template-columns:1fr; }
  .hero-visual{ height:420px; margin-top:40px; }
  .product, .product--care{ grid-template-columns:1fr; }
  .product--care .product-body{ order:2; }
  .product--care .product-media{ order:1; }
  .services-grid{ grid-template-columns:repeat(2,1fr); }
  .about-grid{ grid-template-columns:1fr; }
  .about-media{ height:260px; margin-bottom:12px; }
  .footer-inner{ grid-template-columns:1fr 1fr; }
}

@media (max-width: 720px){
  .nav-links, .btn-nav{ display:none; }
  .nav-toggle{ display:flex; }
  .nav.is-open .nav-links{
    display:flex; flex-direction:column; gap:0;
    position:absolute; top:100%; left:0; right:0;
    background:var(--paper); border-bottom:1px solid var(--line);
    padding:12px 24px 20px;
  }
  .nav.is-open .nav-links a{ padding:12px 0; border-bottom:1px solid var(--line); }
  .hero{ padding:36px 0 64px; }
  .hero-stats{ grid-template-columns:1fr; gap:16px; }
  .section{ padding:72px 0; }
  .services-grid{ grid-template-columns:1fr; }
  .footer-inner{ grid-template-columns:1fr; gap:32px; }
  .frame-phone{ width:150px; left:10%; }
  .frame-phone--back{ display:none; }
  .frame-laptop--back{ display:none; }
  .mockup-pair{ height:300px; }
}
