/* Marketing landing — Solar Monitor (aligned with app.css) */
:root {
  --m-bg: #E8F0F4;
  --m-surface: #FFFFFF;
  --m-heading: #0F2436;
  --m-body: #4A6275;
  --m-primary: #0B8A72;
  --m-primary-hover: #096F5C;
  --m-soft: #DDF3EC;
  --m-accent: #E59B0F;
  --m-accent-soft: #FFF3D6;
  --m-chart-blue: #2B6DE5;
  --m-border: #D5E0EA;
  --m-dark: #0A1B2E;
  --m-dark-text: #9DB0C3;
  --m-radius: 14px;
  --m-max: 1120px;
  --m-font: "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --m-header-h: 72px;
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--m-header-h) + 16px); }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .m-fade, .m-hero-visual { animation: none !important; transition: none !important; }
}
body.m-body {
  margin: 0;
  font-family: var(--m-font);
  color: var(--m-body);
  background:
    radial-gradient(ellipse 80% 50% at 100% -10%, rgba(229,155,15,.12), transparent 55%),
    radial-gradient(ellipse 60% 40% at 0% 0%, rgba(11,138,114,.10), transparent 50%),
    var(--m-bg);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--m-primary); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--m-primary-hover); }
.m-wrap { width: min(100% - 2rem, var(--m-max)); margin-inline: auto; }
.m-section { padding: 5rem 0; }
.m-section--tight { padding: 3.5rem 0; }
.m-section--dark { background: var(--m-dark); color: var(--m-dark-text); }
.m-section--dark h2, .m-section--dark h3 { color: #fff; }
.m-section--soft { background: var(--m-soft); }
.m-kicker {
  display: inline-block;
  font-size: .8rem;
  font-weight: 600;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--m-primary);
  margin: 0 0 .75rem;
}
.m-h1 {
  margin: 0 0 1rem;
  font-size: clamp(2rem, 4vw, 3rem);
  line-height: 1.15;
  letter-spacing: -.02em;
  color: var(--m-heading);
  font-weight: 700;
}
.m-h2 {
  margin: 0 0 .85rem;
  font-size: clamp(1.5rem, 2.6vw, 2rem);
  line-height: 1.25;
  letter-spacing: -.015em;
  color: var(--m-heading);
  font-weight: 700;
}
.m-lead { margin: 0 0 1.5rem; font-size: 1.1rem; max-width: 40rem; }
.m-note { margin: 1rem 0 0; font-size: .9rem; color: #5a6b7d; }
.m-btn:focus-visible,
.m-nav-links a:focus-visible,
.m-brand:focus-visible,
.m-menu-btn:focus-visible,
.m-footer a:focus-visible,
.m-optional summary:focus-visible,
.m-faq summary:focus-visible {
  outline: 3px solid rgba(11,138,114,.45);
  outline-offset: 2px;
}
.m-hero-visual img,
.m-shot img {
  width: 100%;
  height: auto;
}

/* Header */
.m-header {
  position: sticky; top: 0; z-index: 50;
  min-height: var(--m-header-h);
  background: rgba(255,255,255,.88);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent;
  transition: background .2s ease, border-color .2s ease, box-shadow .2s ease;
}
.m-header.is-scrolled {
  background: rgba(255,255,255,.97);
  border-bottom-color: var(--m-border);
  box-shadow: 0 8px 24px rgba(10,27,46,.06);
}
.m-header-inner {
  min-height: var(--m-header-h);
  display: flex; align-items: center; gap: 1.5rem;
}
.m-brand {
  display: inline-flex; align-items: center; gap: .7rem;
  flex-shrink: 0;
  color: var(--m-heading); text-decoration: none;
}
.m-brand:hover, .m-brand:focus-visible { color: var(--m-heading); text-decoration: none; }
.m-brand-mark {
  width: 36px; height: 36px; border-radius: 10px;
  background: linear-gradient(145deg, #0EA5A0 0%, var(--m-primary) 55%, #096F5C 100%);
  color: #fff;
  display: grid; place-items: center;
  box-shadow: 0 1px 0 rgba(255,255,255,.25) inset, 0 2px 6px rgba(11,138,114,.28);
}
.m-brand-mark svg { width: 18px; height: 18px; }
.m-brand-text {
  display: flex; flex-direction: column; line-height: 1.15; gap: .15rem;
}
.m-brand-text strong {
  font-size: 1.02rem; font-weight: 700; letter-spacing: -.02em;
}
.m-brand-text small {
  font-size: .68rem; font-weight: 600; letter-spacing: .02em;
  color: var(--m-body); text-transform: none;
}
.m-nav {
  display: flex; align-items: center; flex: 1; justify-content: center; min-width: 0;
}
.m-nav-links {
  display: flex; align-items: center; justify-content: center;
  flex-wrap: nowrap; gap: 1.15rem;
}
.m-nav-links a {
  position: relative;
  color: var(--m-body);
  text-decoration: none;
  font-size: .88rem;
  font-weight: 600;
  white-space: nowrap;
  padding: .45rem 0;
  transition: color .15s ease;
}
.m-nav-links a::after {
  content: "";
  position: absolute; left: 0; right: 0; bottom: 0;
  height: 2px; border-radius: 2px;
  background: var(--m-primary);
  transform: scaleX(0); transform-origin: left;
  transition: transform .18s ease;
}
.m-nav-links a:hover,
.m-nav-links a:focus-visible {
  color: var(--m-heading);
  text-decoration: none;
}
.m-nav-links a:hover::after,
.m-nav-links a:focus-visible::after { transform: scaleX(1); }
.m-nav-actions {
  display: flex; align-items: center; gap: .55rem; flex-shrink: 0; margin-left: auto;
}
.m-nav-actions .m-btn { min-height: 40px; padding: 0 .95rem; font-size: .86rem; }
.m-nav-mobile-only { display: none !important; }
.m-menu-btn {
  display: none; border: 1px solid var(--m-border); background: #fff;
  border-radius: 10px; width: 42px; height: 42px; cursor: pointer; padding: 0;
}
.m-menu-btn span { display: block; width: 18px; height: 2px; background: var(--m-heading); margin: 4px auto; border-radius: 1px; }

/* Buttons — beat global `a` and `.m-nav a` color rules */
.m-btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 42px; padding: 0 1.05rem; border-radius: 10px;
  font-weight: 600; font-size: .9rem; text-decoration: none; border: 1px solid transparent;
  cursor: pointer; transition: background .15s ease, color .15s ease, border-color .15s ease;
  white-space: nowrap;
}
.m-btn:focus-visible { outline: 3px solid rgba(11,138,114,.35); outline-offset: 2px; }
a.m-btn--primary,
.m-btn--primary { background: var(--m-primary); color: #fff !important; }
a.m-btn--primary:hover,
.m-btn--primary:hover { background: var(--m-primary-hover); color: #fff !important; }
a.m-btn--secondary,
.m-btn--secondary { background: #fff; color: var(--m-heading) !important; border-color: var(--m-border); }
a.m-btn--secondary:hover,
.m-btn--secondary:hover { border-color: #c5d0dc; color: var(--m-heading) !important; }
a.m-btn--ghost,
.m-btn--ghost { background: transparent; color: var(--m-heading) !important; }
a.m-btn--ghost:hover,
.m-btn--ghost:hover { background: rgba(20,38,56,.05); color: var(--m-heading) !important; }
a.m-btn--dark,
.m-btn--dark { background: #fff; color: var(--m-dark) !important; }
a.m-btn--dark:hover,
.m-btn--dark:hover { background: var(--m-soft); color: var(--m-dark) !important; }
.m-btn-row { display: flex; flex-wrap: wrap; gap: .75rem; }

/* Hero */
.m-hero { padding: 3.5rem 0 4rem; }
.m-hero-grid {
  display: grid; gap: 2.5rem; align-items: center;
  grid-template-columns: 1.05fr .95fr;
}
.m-hero-visual {
  border: 0; border-radius: 0; overflow: visible;
  background: transparent; box-shadow: none;
}
.m-hero-devices {
  position: relative;
  display: grid;
  grid-template-columns: 1fr;
  align-items: end;
  max-width: 520px;
  margin-inline: auto;
}
.m-device {
  background: linear-gradient(165deg, #0C2438 0%, #0A1B2E 100%);
  box-shadow: 0 22px 48px rgba(10,27,46,.22), 0 2px 0 rgba(255,255,255,.06) inset;
}
.m-device img {
  display: block; width: 100%; height: 100%;
  object-fit: cover; object-position: top center;
  background: #fff;
}
.m-device-desktop {
  border-radius: 14px;
  padding: 10px 10px 12px;
  border: 1px solid rgba(255,255,255,.08);
  max-width: 560px;
}
.m-device-desktop .m-device-bar {
  display: flex; align-items: center; gap: 6px;
  margin-bottom: 8px; padding: 0 2px;
}
.m-device-desktop .m-device-bar span {
  width: 8px; height: 8px; border-radius: 50%;
  background: rgba(255,255,255,.22);
}
.m-device-desktop .m-device-bar span:nth-child(1) { background: #FF5F57; }
.m-device-desktop .m-device-bar span:nth-child(2) { background: #FEBC2E; }
.m-device-desktop .m-device-bar span:nth-child(3) { background: #28C840; }
.m-device-desktop .m-device-screen {
  border-radius: 6px;
  overflow: hidden;
  aspect-ratio: 16 / 10;
  background: #fff;
}
.m-device-phone {
  width: min(38%, 168px);
  justify-self: end;
  margin-top: -42%;
  margin-right: 2%;
  border-radius: 26px;
  padding: 8px;
  border: 2px solid rgba(255,255,255,.12);
  position: relative;
  z-index: 2;
}
.m-device-phone::before {
  content: "";
  display: block;
  width: 36%;
  height: 4px;
  border-radius: 99px;
  background: rgba(255,255,255,.18);
  margin: 2px auto 6px;
}
.m-device-phone .m-device-screen {
  border-radius: 16px;
  overflow: hidden;
  aspect-ratio: 9 / 19.5;
  background: #fff;
}
.m-device-tablet {
  border-radius: 18px;
  padding: 12px;
  border: 1px solid rgba(255,255,255,.1);
  max-width: 280px;
}
.m-device-tablet .m-device-screen {
  border-radius: 8px;
  overflow: hidden;
  aspect-ratio: 3 / 4;
  background: #fff;
}
.m-shot .m-device-desktop { max-width: 100%; }
.m-devices-row {
  display: flex; flex-wrap: wrap; gap: 1.25rem;
  align-items: flex-end; justify-content: center;
}
.m-devices-row .m-device-phone {
  width: 140px; margin: 0; justify-self: auto;
}
.m-shot-label {
  font-size: .75rem; font-weight: 600; color: #6b7c8f;
  padding: .55rem .9rem; border-bottom: 1px solid var(--m-border); background: #fafcfd;
}
.m-shot-label--float {
  border: 0; background: transparent; padding: 0 0 .65rem;
  color: var(--m-body);
}
.m-card {
  background: var(--m-surface); border: 1px solid var(--m-border);
  border-radius: var(--m-radius); padding: 1.35rem 1.4rem;
  box-shadow: 0 1px 0 rgba(20,38,56,.02);
}
.m-grid-3 { display: grid; gap: 1rem; grid-template-columns: repeat(3, 1fr); }
.m-grid-2 { display: grid; gap: 1.25rem; grid-template-columns: repeat(2, 1fr); }
.m-grid-4 { display: grid; gap: 1rem; grid-template-columns: repeat(4, 1fr); }
.m-card h3 { margin: 0 0 .45rem; color: var(--m-heading); font-size: 1.05rem; }
.m-card p { margin: 0; font-size: .95rem; }
.m-problem-num {
  width: 28px; height: 28px; border-radius: 8px; background: var(--m-soft);
  color: var(--m-primary); display: grid; place-items: center;
  font-size: .8rem; font-weight: 700; margin-bottom: .7rem;
}

/* Benefits / walkthrough */
.m-benefit-grid { display: grid; gap: 1rem; grid-template-columns: repeat(3, 1fr); }
.m-split {
  display: grid; gap: 2rem; align-items: center;
  grid-template-columns: 1fr 1fr;
}
.m-split--flip > :first-child { order: 2; }
.m-split--flip > :last-child { order: 1; }
.m-shot {
  border: 0; border-radius: 0; overflow: visible; background: transparent;
  box-shadow: none;
}
.m-shot .m-device { width: 100%; }
.m-shot .m-shot-label { margin-bottom: .35rem; }
.m-steps { display: grid; gap: 1rem; grid-template-columns: repeat(4, 1fr); counter-reset: step; }
.m-step { position: relative; }
.m-step::before {
  counter-increment: step; content: counter(step);
  display: grid; place-items: center;
  width: 32px; height: 32px; border-radius: 999px;
  background: var(--m-primary); color: #fff; font-weight: 700; font-size: .85rem;
  margin-bottom: .75rem;
}

/* Compatibility cards */
.m-compat {
  display: grid; gap: .75rem;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
}
.m-compat-card {
  display: flex; flex-direction: column; gap: .55rem;
  padding: 1rem 1.1rem;
  border: 1px solid var(--m-border);
  border-radius: 12px;
  background: #fff;
}
.m-compat-head {
  display: flex; align-items: flex-start; justify-content: space-between; gap: .75rem;
}
.m-compat-head strong {
  color: var(--m-heading); font-size: 1rem; line-height: 1.3;
}
.m-compat-body {
  margin: 0; font-size: .9rem; color: var(--m-body); line-height: 1.45;
}
.m-badge {
  flex-shrink: 0; font-size: .72rem; font-weight: 700; letter-spacing: .02em;
  padding: .28rem .55rem; border-radius: 999px;
  max-width: 9.5rem; text-align: center; line-height: 1.25;
  white-space: normal;
}
.m-badge--ok { background: var(--m-soft); color: var(--m-primary); }
.m-badge--eval { background: #E8EEF3; color: #4A6275; }

.m-bullets { margin: 1rem 0 0; padding-left: 1.1rem; color: var(--m-body); }
.m-bullets li { margin: .35rem 0; }
.m-demo-list { margin-top: 1.25rem; }
.m-demo-list h3 { color: #fff; font-size: 1rem; margin: 0 0 .55rem; }
.m-demo-list ul { margin: 0; padding-left: 1.1rem; }
.m-demo-list li { margin: .3rem 0; }
.m-footer-operated { margin-top: .65rem; font-size: .9rem; color: #9aabbc; }
.m-hero-visual--lg { min-height: 280px; }

.m-optional {
  margin-top: 1.1rem;
  border: 1px solid var(--m-border);
  border-radius: 12px;
  padding: .15rem 1rem 1rem;
  background: #fafcfd;
}
.m-optional summary {
  cursor: pointer; list-style: none; padding: .9rem 0 .35rem;
  color: var(--m-heading); font-weight: 600; font-size: .95rem;
}
.m-optional summary::-webkit-details-marker { display: none; }
.m-req { font-weight: 500; color: #6b7c8f; font-size: .78rem; margin-left: .2rem; }
.m-field-label { font-size: .88rem; font-weight: 600; color: var(--m-heading); }
.m-check-grid--compact { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: .35rem .65rem; }
.m-check-grid--compact .m-check { font-size: .85rem; }

/* FAQ */
.m-faq details {
  border: 1px solid var(--m-border); border-radius: 12px; background: #fff;
  padding: .15rem 1rem; margin-bottom: .65rem;
}
.m-faq summary {
  cursor: pointer; list-style: none; padding: .95rem 0;
  color: var(--m-heading); font-weight: 600;
}
.m-faq summary::-webkit-details-marker { display: none; }
.m-faq details[open] summary { border-bottom: 1px solid var(--m-border); }
.m-faq details p { margin: .85rem 0 1rem; }

/* Form */
.m-form {
  background: #fff; border: 1px solid var(--m-border); border-radius: 18px;
  padding: 1.5rem; box-shadow: 0 12px 30px rgba(20,38,56,.05);
}
.m-form-grid { display: grid; gap: 1rem; grid-template-columns: 1fr 1fr; }
.m-field { display: flex; flex-direction: column; gap: .35rem; }
.m-field--full { grid-column: 1 / -1; }
.m-field label { font-size: .88rem; font-weight: 600; color: var(--m-heading); }
.m-field input, .m-field select, .m-field textarea {
  min-height: 44px; border: 1px solid var(--m-border); border-radius: 10px;
  padding: .65rem .8rem; font: inherit; color: var(--m-heading); background: #fff;
}
.m-field textarea { min-height: 110px; resize: vertical; }
.m-field input:focus, .m-field select:focus, .m-field textarea:focus {
  outline: 3px solid rgba(11,138,114,.25); border-color: var(--m-primary);
}
.m-check-grid { display: grid; gap: .4rem .8rem; grid-template-columns: repeat(2, minmax(0,1fr)); }
.m-check { display: flex; gap: .45rem; align-items: flex-start; font-size: .9rem; color: var(--m-heading); }
.m-hp { position: absolute; left: -9999px; opacity: 0; height: 0; width: 0; overflow: hidden; }
.m-error { color: #C0352B; font-size: .85rem; margin: 0; }
.m-success {
  border: 1px solid #9FD4C4; background: var(--m-soft); color: #096F5C;
  border-radius: 12px; padding: 1rem 1.1rem; margin-bottom: 1rem;
}
.m-form-note { font-size: .82rem; color: #6b7c8f; margin: .5rem 0 0; }

/* Footer */
.m-footer { background: var(--m-dark); color: var(--m-dark-text); padding: 3rem 0 2rem; }
.m-footer a { color: #d7e0ea; text-decoration: none; }
.m-footer a:hover { color: #fff; }
.m-footer-grid { display: grid; gap: 1.5rem; grid-template-columns: 1.4fr 1fr 1fr 1fr; }
.m-footer h3 { color: #fff; font-size: .95rem; margin: 0 0 .75rem; }
.m-footer ul { list-style: none; margin: 0; padding: 0; }
.m-footer li { margin: 0 0 .45rem; }
.m-footer-bottom {
  margin-top: 2rem; padding-top: 1.25rem; border-top: 1px solid #14324A;
  display: flex; flex-wrap: wrap; gap: .75rem 1.25rem; justify-content: space-between;
  font-size: .85rem;
}

@media (max-width: 1024px) {
  .m-nav-links { gap: 1rem; }
  .m-nav-links a { font-size: .85rem; }
}
@media (max-width: 960px) {
  .m-hero-grid, .m-split, .m-split--flip > :first-child, .m-split--flip > :last-child,
  .m-grid-3, .m-grid-4, .m-benefit-grid, .m-steps, .m-footer-grid {
    grid-template-columns: 1fr;
  }
  .m-device-phone {
    width: min(40%, 150px);
    margin-top: -34%;
  }
  .m-device-desktop { max-width: 100%; }
  .m-split--flip > :first-child, .m-split--flip > :last-child { order: initial; }
  .m-nav { flex: 0; }
  .m-nav-links { display: none; }
  .m-nav-desktop-only { display: none !important; }
  .m-menu-btn { display: inline-grid; place-items: center; }
  .m-header { position: sticky; }
  .m-brand-text small { display: none; }
  .m-header.is-open .m-nav-links {
    display: flex !important;
    flex-direction: column;
    align-items: stretch;
    position: absolute;
    left: 0; right: 0;
    top: 100%;
    background: #fff;
    border-bottom: 1px solid var(--m-border);
    box-shadow: 0 12px 24px rgba(20,38,56,.08);
    padding: .75rem 1.25rem 1.1rem;
    gap: 0;
    z-index: 60;
  }
  .m-header.is-open .m-nav-links a::after { display: none; }
  .m-header.is-open .m-nav-links a {
    padding: .85rem 0;
    border-bottom: 1px solid var(--m-border);
    white-space: normal;
  }
  .m-header.is-open .m-nav-links a:last-child { border-bottom: 0; }
  .m-header.is-open .m-nav-mobile-only { display: block !important; }
  .m-header.is-open .m-nav-cta {
    margin-top: .5rem;
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    border-radius: 10px;
    background: var(--m-primary);
    color: #fff !important;
    font-weight: 600;
    border-bottom: 0 !important;
  }
  .m-check-grid { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .m-form-grid, .m-grid-2 { grid-template-columns: 1fr; }
}
