/* Mila website. Plain CSS, system fonts, no build step. */

:root {
  color-scheme: light dark;

  --bg: #ffffff;
  --bg-alt: #f2f7f5;
  --surface: #ffffff;
  --text: #10201c;
  --muted: #4a5a55;
  --border: #d9e4df;
  --brand: #157260;          /* app icon gradient top */
  --brand-deep: #0b332c;     /* app icon gradient bottom */
  --brand-text: #0f5f50;     /* links on --bg, 7:1 */
  --button-bg: #157260;
  --button-bg-hover: #0f5f50;
  --button-text: #ffffff;
  --focus: #1a73e8;
  --code-bg: #0f1d1a;
  --code-text: #d7efe8;
  --speaker-a: #157260;
  --speaker-b: #8a4b08;
  --speaker-c: #5b3fa8;
  --shadow: 0 18px 50px -20px rgba(11, 51, 44, 0.35);

  --radius: 14px;
  --wrap: 1080px;
  --font: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", system-ui, Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0b1513;
    --bg-alt: #101f1b;
    --surface: #132521;
    --text: #e6efec;
    --muted: #a5b8b2;
    --border: #23392f;
    --brand-text: #5fd3b4;
    --button-bg: #3cbf9d;
    --button-bg-hover: #5fd3b4;
    --button-text: #04130f;
    --focus: #8ab4f8;
    --code-bg: #07100e;
    --speaker-a: #5fd3b4;
    --speaker-b: #f0a75a;
    --speaker-c: #b9a4f5;
    --shadow: 0 18px 50px -20px rgba(0, 0, 0, 0.7);
  }
}

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

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}

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

img, svg { display: block; max-width: 100%; height: auto; }

a { color: var(--brand-text); text-underline-offset: 0.18em; }
a:hover { text-decoration-thickness: 2px; }

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

code, kbd, pre { font-family: var(--mono); font-size: 0.92em; }
kbd {
  display: inline-block;
  padding: 0 0.4em;
  border: 1px solid var(--border);
  border-bottom-width: 2px;
  border-radius: 6px;
  background: var(--bg-alt);
  line-height: 1.5;
}
p code, li code {
  padding: 0.05em 0.35em;
  border-radius: 5px;
  background: var(--bg-alt);
  border: 1px solid var(--border);
  overflow-wrap: anywhere;
}

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 20px;
}

.skip-link {
  position: absolute;
  left: 12px;
  top: -100px;
  z-index: 10;
  padding: 0.6rem 1rem;
  background: var(--surface);
  color: var(--text);
  border: 2px solid var(--focus);
  border-radius: 8px;
}
.skip-link:focus { top: 12px; }

/* Header */

.site-header {
  border-bottom: 1px solid var(--border);
}
.header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 64px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  color: var(--text);
  font-weight: 700;
  font-size: 1.2rem;
  text-decoration: none;
}
.nav {
  display: flex;
  gap: 1.4rem;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 0.97rem;
}
.nav a { color: var(--muted); text-decoration: none; }
.nav a:hover { color: var(--text); text-decoration: underline; }

/* Hero */

.hero {
  padding: clamp(3rem, 8vw, 6rem) 0 clamp(2.5rem, 6vw, 4.5rem);
  background:
    radial-gradient(1100px 480px at 50% -10%, color-mix(in srgb, var(--brand) 16%, transparent), transparent 70%),
    var(--bg);
}
.hero-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}
.hero-icon {
  width: 128px;
  height: 128px;
  margin-bottom: 1.5rem;
  filter: drop-shadow(0 10px 24px rgba(11, 51, 44, 0.28));
}
h1 {
  margin: 0;
  font-size: clamp(2.4rem, 6.4vw, 4.2rem);
  line-height: 1.06;
  letter-spacing: -0.03em;
  font-weight: 800;
  text-wrap: balance;
}
.lede {
  max-width: 36rem;
  margin: 1.25rem 0 2rem;
  color: var(--muted);
  font-size: clamp(1.1rem, 2.2vw, 1.3rem);
  text-wrap: pretty;
}

.download-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.7rem;
  min-height: 64px;
  padding: 1.05rem 2.4rem;
  border-radius: 999px;
  background: var(--button-bg);
  color: var(--button-text);
  font-size: 1.3rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  text-decoration: none;
  box-shadow: var(--shadow);
  transition: background-color 0.15s ease, transform 0.15s ease;
}
.download-button:hover { background: var(--button-bg-hover); transform: translateY(-1px); }
.download-button:active { transform: translateY(0); }
.download-button:focus-visible { outline-offset: 4px; border-radius: 999px; }
.download-button-small { min-height: 54px; padding: 0.85rem 1.9rem; font-size: 1.12rem; }

.download-meta {
  margin: 1.1rem 0 0.25rem;
  color: var(--muted);
  font-size: 0.97rem;
}
.download-alt { margin: 0; font-size: 0.93rem; }

/* Languages badge in the hero */

.langs {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  margin: 0 0 1.1rem;
  padding: 0.35rem 1.1rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  font-weight: 700;
  font-size: 1.05rem;
}
.lang-amp { color: var(--brand-text); }
.lede-he {
  margin: -1.2rem 0 2rem;
  color: var(--text);
  font-size: clamp(1.1rem, 2.2vw, 1.3rem);
  font-weight: 600;
}

/* App screenshot */

.shot { margin-top: clamp(2.5rem, 6vw, 4rem); }
.shot img {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  filter: drop-shadow(0 24px 40px rgba(11, 51, 44, 0.28));
}

/* Hebrew and English */

.lang-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
  gap: 1rem;
  margin: 0;
  padding: 0;
  list-style: none;
}
.lang-cards > li {
  padding: 1.4rem 1.5rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}
.lang-cards > li:first-child { border: 2px solid var(--button-bg); }
.lang-card-title {
  display: flex;
  align-items: baseline;
  gap: 0.6rem;
  margin: 0 0 0.6rem;
  font-size: 1.4rem;
  font-weight: 800;
}
.lang-cards ul { margin: 0; padding-left: 1.2rem; color: var(--muted); display: grid; gap: 0.3rem; }
.lang-note { margin: 1.2rem 0 0; color: var(--muted); font-size: 0.98rem; }

/* Sections */

.section { padding: clamp(3.5rem, 8vw, 5.5rem) 0; }
.section-alt { background: var(--bg-alt); border-block: 1px solid var(--border); }
h2 {
  margin: 0 0 0.6rem;
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  line-height: 1.15;
  letter-spacing: -0.02em;
  text-wrap: balance;
}
h3 { margin: 0 0 0.35rem; font-size: 1.1rem; line-height: 1.3; }
.section-lede { margin: 0 0 2.25rem; max-width: 40rem; color: var(--muted); font-size: 1.12rem; }

.features {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 240px), 1fr));
  gap: 1rem;
  margin: 0;
  padding: 0;
  list-style: none;
}
.features li {
  padding: 1.3rem 1.3rem 1.4rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}
.features p { margin: 0; color: var(--muted); font-size: 0.98rem; }

/* On-prem */

.modes {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
  gap: 1rem;
  margin: 0 0 clamp(2rem, 5vw, 3rem);
  padding: 0;
  list-style: none;
}
.modes li {
  padding: 1.4rem 1.5rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}
.modes li.mode-main {
  border: 2px solid var(--button-bg);
  background: color-mix(in srgb, var(--button-bg) 8%, var(--surface));
}
.modes p { margin: 0; color: var(--muted); }
.modes h3 { font-size: 1.3rem; }
.mode-label {
  margin-bottom: 0.3rem !important;
  color: var(--brand-text) !important;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.teams {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
  gap: clamp(2rem, 5vw, 3.5rem);
  align-items: start;
}
.eyebrow {
  margin: 0 0 0.5rem;
  color: var(--brand-text);
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.teams-copy > p { color: var(--muted); }
.checks { margin: 0 0 1.5rem; padding: 0; list-style: none; display: grid; gap: 0.9rem; }
.checks li {
  position: relative;
  padding-left: 2rem;
  color: var(--muted);
}
.checks li strong { color: var(--text); }
.checks li::before {
  content: "\2713";
  position: absolute;
  left: 0;
  top: 0.22em;
  display: grid;
  place-items: center;
  width: 1.3rem;
  height: 1.3rem;
  border-radius: 50%;
  background: var(--button-bg);
  color: var(--button-text);
  font-size: 0.8rem;
  font-weight: 800;
  line-height: 1;
}
.teams-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.6rem 1.4rem;
  margin: 0;
}
.button-secondary {
  display: inline-flex;
  align-items: center;
  min-height: 46px;
  padding: 0.6rem 1.3rem;
  border-radius: 999px;
  border: 2px solid var(--button-bg);
  color: var(--brand-text);
  font-weight: 700;
  text-decoration: none;
}
.button-secondary:hover { background: color-mix(in srgb, var(--button-bg) 10%, transparent); }
.button-secondary:focus-visible { border-radius: 999px; }
.text-link { font-weight: 600; }

.config { margin: 0; }
.config figcaption {
  padding: 0.55rem 1rem;
  border-radius: var(--radius) var(--radius) 0 0;
  background: #1a2d29;
  color: #a5c7bd;
  font-family: var(--mono);
  font-size: 0.82rem;
}
.config-note {
  margin: 0.7rem 0 0;
  color: var(--muted);
  font-size: 0.88rem;
}
.config pre {
  margin: 0;
  padding: 1.1rem 1.2rem;
  border-radius: 0 0 var(--radius) var(--radius);
  background: var(--code-bg);
  color: var(--code-text);
  font-size: 0.82rem;
  line-height: 1.6;
  overflow-x: auto;
}

/* Requirements */

.reqs {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 230px), 1fr));
  gap: 1rem 2rem;
  margin: 1.5rem 0 0;
}
.reqs div { padding-top: 0.9rem; border-top: 2px solid var(--border); }
.reqs dt { font-weight: 700; }
.reqs dd { margin: 0.2rem 0 0; color: var(--muted); font-size: 0.98rem; }

/* Closing call to action */

.closing-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.4rem;
  text-align: center;
}
.closing h2 { margin: 0; }

/* Footer */

.site-footer {
  padding: 2rem 0 2.5rem;
  border-top: 1px solid var(--border);
  color: var(--muted);
  font-size: 0.92rem;
}
.footer-row p { margin: 0.3rem 0; }

/* Small screens */

@media (max-width: 820px) {
  .teams { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 560px) {
  .wrap { padding: 0 16px; }
  .nav { gap: 1rem; font-size: 0.93rem; }
  .nav li:first-child { display: none; }
  .br-wide { display: none; }
  .download-button { width: 100%; max-width: 360px; padding-inline: 1.5rem; }
}

@media print {
  .site-header nav, .download-button, .skip-link { display: none; }
}
