/* Meina Tech — shared stylesheet
   Theme: "ocean glass" — sea-glass aqua + seafoam on warm sand,
   frosted translucent surfaces, deep-ocean ink. */

:root {
  /* surfaces */
  --bg: #f7fbfa;
  --bg-sand: #faf6ef;
  --bg-raised: #ffffff;
  --glass: rgba(255, 255, 255, 0.62);
  --glass-strong: rgba(255, 255, 255, 0.85);

  /* lines */
  --line: #dfe9e7;
  --line-strong: #c6d8d5;

  /* ink */
  --text: #12333b;
  --text-dim: #4e6b73;
  --text-faint: #7f959b;

  /* sea glass */
  --aqua: #2aa8a0;
  --aqua-deep: #14707a;
  --aqua-soft: #d6efec;
  --seafoam: #7fc9ae;
  --coral: #ff8a6b;
  --glow: rgba(42, 168, 160, 0.16);

  --maxw: 1120px;
  --pad: 24px;
  --radius: 16px;

  --shadow-sm: 0 1px 2px rgba(18, 51, 59, 0.05),
    0 4px 14px rgba(18, 51, 59, 0.05);
  --shadow-md: 0 2px 6px rgba(18, 51, 59, 0.06),
    0 14px 40px rgba(18, 51, 59, 0.09);

  --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: var(--aqua-deep);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

.wrap {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 var(--pad);
}

/* ── Typography ─────────────────────────────────────── */

h1,
h2,
h3 {
  line-height: 1.14;
  letter-spacing: -0.022em;
  margin: 0 0 0.5em;
  font-weight: 650;
}

h1 {
  font-size: clamp(2.3rem, 5.5vw, 3.8rem);
  letter-spacing: -0.035em;
}

h2 {
  font-size: clamp(1.7rem, 3.4vw, 2.4rem);
}

h3 {
  font-size: 1.16rem;
}

p {
  margin: 0 0 1.15em;
}

.lede {
  font-size: clamp(1.05rem, 2vw, 1.3rem);
  color: var(--text-dim);
  max-width: 60ch;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--mono);
  font-size: 0.73rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--aqua-deep);
  background: var(--aqua-soft);
  border-radius: 999px;
  padding: 6px 13px;
  margin-bottom: 1.3rem;
}

.muted {
  color: var(--text-dim);
}

.accent {
  color: var(--aqua);
}

/* ── Header ─────────────────────────────────────────── */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(247, 251, 250, 0.72);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid var(--line);
}

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: 70px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  font-weight: 650;
  letter-spacing: -0.015em;
  font-size: 1.08rem;
}

.brand:hover {
  text-decoration: none;
}

.brand svg {
  width: 28px;
  height: 28px;
  flex: none;
}

.nav {
  display: flex;
  align-items: center;
  gap: 6px;
}

.nav a {
  color: var(--text-dim);
  font-size: 0.94rem;
  padding: 8px 13px;
  border-radius: 9px;
  transition: color 0.15s ease, background 0.15s ease;
}

.nav a:hover {
  color: var(--text);
  background: var(--aqua-soft);
  text-decoration: none;
}

.nav a[aria-current="page"] {
  color: var(--text);
  font-weight: 550;
}

.nav .btn {
  padding: 9px 16px;
  margin-left: 6px;
}

/* ── Buttons ────────────────────────────────────────── */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 13px 22px;
  border-radius: 11px;
  font-size: 0.96rem;
  font-weight: 550;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.12s ease, background 0.15s ease,
    border-color 0.15s ease, box-shadow 0.15s ease;
}

.btn:hover {
  text-decoration: none;
  transform: translateY(-1px);
}

.btn-primary {
  background: var(--aqua);
  color: #fff;
  box-shadow: 0 6px 18px var(--glow);
}

.btn-primary:hover {
  background: var(--aqua-deep);
  box-shadow: 0 10px 24px var(--glow);
}

.btn-ghost {
  border-color: var(--line-strong);
  color: var(--text);
  background: var(--glass);
}

.btn-ghost:hover {
  background: var(--bg-raised);
  border-color: var(--aqua);
}

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 2rem;
}

/* ── Sections ───────────────────────────────────────── */

section {
  padding: 92px 0;
}

.section-sand {
  background: var(--bg-sand);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.section-head {
  max-width: 62ch;
  margin-bottom: 3rem;
}

/* ── Hero ───────────────────────────────────────────── */

.hero {
  position: relative;
  padding: 112px 0 104px;
  overflow: hidden;
}

.hero-art {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.95;
}

.hero::after {
  /* wash the art out toward the left so the type stays legible */
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
      100deg,
      var(--bg) 0%,
      rgba(247, 251, 250, 0.94) 38%,
      rgba(247, 251, 250, 0.55) 62%,
      rgba(247, 251, 250, 0.15) 100%
    ),
    linear-gradient(to bottom, transparent 65%, var(--bg) 100%);
  pointer-events: none;
}

.hero .wrap {
  position: relative;
  z-index: 2;
}

.hero h1 {
  max-width: 15ch;
}

.hero .lede {
  max-width: 50ch;
}

/* ── Cards ──────────────────────────────────────────── */

.grid {
  display: grid;
  gap: 24px;
  /* min() so the track can shrink below 285px on narrow phones instead of overflowing. */
  grid-template-columns: repeat(auto-fit, minmax(min(285px, 100%), 1fr));
}

/* Four tiles: 4 across on desktop, 2 across on tablet — never a lone orphan. */
.grid-4 {
  grid-template-columns: repeat(4, 1fr);
}

@media (max-width: 980px) {
  .grid-4 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 560px) {
  .grid-4 {
    grid-template-columns: 1fr;
  }
}

.card {
  background: var(--bg-raised);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: transform 0.18s ease, box-shadow 0.18s ease,
    border-color 0.18s ease;
}

.card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: var(--line-strong);
}

.card img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-bottom: 1px solid var(--line);
}

.card-body {
  padding: 26px;
}

.card-body h3 {
  margin-bottom: 0.4em;
}

.card-body p {
  color: var(--text-dim);
  font-size: 0.96rem;
  margin: 0;
}

/* ── Feature tiles (frosted glass, no image) ────────── */

.feature {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
  background: var(--glass-strong);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  box-shadow: var(--shadow-sm);
}

.feature .num {
  display: inline-block;
  font-family: var(--mono);
  font-size: 0.76rem;
  color: var(--aqua-deep);
  letter-spacing: 0.1em;
  margin-bottom: 1rem;
}

.feature h3 {
  margin-bottom: 0.4em;
}

.feature p {
  color: var(--text-dim);
  font-size: 0.96rem;
  margin: 0;
}

/* ── Split (image + text) ───────────────────────────── */

.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.split img {
  border-radius: var(--radius);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-md);
}

@media (max-width: 800px) {
  .split {
    grid-template-columns: 1fr;
    gap: 34px;
  }
}

/* ── Stats ──────────────────────────────────────────── */

.stats {
  display: grid;
  /* Sits inside a half-width .split column, so 160px minimums wrap. */
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-top: 2.5rem;
}

@media (max-width: 400px) {
  .stats {
    grid-template-columns: 1fr;
  }
}

.stat .n {
  font-size: 2.3rem;
  font-weight: 650;
  letter-spacing: -0.03em;
  color: var(--aqua-deep);
}

.stat .l {
  font-size: 0.88rem;
  color: var(--text-faint);
}

/* ── CTA band ───────────────────────────────────────── */

.cta {
  text-align: center;
  background: radial-gradient(
      ellipse 70% 120% at 50% 0%,
      var(--aqua-soft),
      transparent 70%
    ),
    var(--bg);
}

.cta .lede {
  margin-left: auto;
  margin-right: auto;
}

.cta .btn-row {
  justify-content: center;
}

/* ── Contact ────────────────────────────────────────── */

.contact-grid {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 60px;
  align-items: start;
}

@media (max-width: 860px) {
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 42px;
  }
}

.field {
  margin-bottom: 18px;
}

.field label {
  display: block;
  font-size: 0.88rem;
  color: var(--text-dim);
  margin-bottom: 7px;
}

.field input,
.field textarea {
  width: 100%;
  background: var(--bg-raised);
  border: 1px solid var(--line-strong);
  border-radius: 11px;
  color: var(--text);
  font: inherit;
  font-size: 0.96rem;
  padding: 12px 14px;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.field textarea {
  min-height: 150px;
  resize: vertical;
}

.field input:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--aqua);
  box-shadow: 0 0 0 3px var(--glow);
}

.contact-note {
  font-size: 0.86rem;
  color: var(--text-faint);
  margin-top: 14px;
}

.contact-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--glass-strong);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  box-shadow: var(--shadow-sm);
  padding: 30px;
}

.contact-card dt {
  font-size: 0.78rem;
  color: var(--text-faint);
  text-transform: uppercase;
  letter-spacing: 0.11em;
  margin-top: 22px;
}

.contact-card dt:first-of-type {
  margin-top: 0;
}

.contact-card dd {
  margin: 6px 0 0;
  font-size: 1rem;
}

/* ── Footer ─────────────────────────────────────────── */

.site-footer {
  background: var(--bg-sand);
  border-top: 1px solid var(--line);
  padding: 46px 0;
  color: var(--text-faint);
  font-size: 0.9rem;
}

.site-footer .wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  align-items: center;
  justify-content: space-between;
}

.site-footer a {
  color: var(--text-dim);
}

.site-footer nav {
  display: flex;
  gap: 22px;
  flex-wrap: wrap;
}

/* ── Accessibility & motion ─────────────────────────── */

:focus-visible {
  outline: 2px solid var(--aqua);
  outline-offset: 3px;
  border-radius: 4px;
}

.skip {
  position: absolute;
  left: -9999px;
}

.skip:focus {
  left: 12px;
  top: 12px;
  z-index: 100;
  background: var(--bg-raised);
  padding: 10px 16px;
  border-radius: 8px;
  box-shadow: var(--shadow-md);
}

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

@media (max-width: 640px) {
  body {
    font-size: 16px;
  }
  section {
    padding: 66px 0;
  }
  .hero {
    padding: 76px 0 66px;
  }
  .nav a {
    padding: 8px 9px;
    font-size: 0.9rem;
  }
  .nav .btn {
    display: none;
  }
}

@media (max-width: 380px) {
  /* Brand + nav no longer fit on one line — let the nav drop beneath it. */
  .site-header .wrap {
    flex-wrap: wrap;
    gap: 0 8px;
    padding-top: 10px;
    padding-bottom: 10px;
  }
  .nav {
    width: 100%;
    justify-content: space-between;
  }
  .nav a {
    padding: 6px 4px;
  }
}

/* Honeypot — off-screen rather than display:none, which some bots detect. */
.hp {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}
