:root {
  --teal: #2f6666;
  --teal-dark: #1a4545;
  --teal-light: #e8f2f2;
  --teal-muted: #5a8a8a;
  --bg: #fafbfc;
  --bg-hero: linear-gradient(180deg, #ffffff 0%, #f4f8f8 55%, #eef4f4 100%);
  --card: #ffffff;
  --text: #1e2a2a;
  --muted: #5c6b6b;
  --border: #dde8e8;
  --pill: #dceeee;
  --shadow: 0 8px 32px rgba(26, 69, 69, 0.08);
  --shadow-card: 0 4px 24px rgba(26, 69, 69, 0.06);
  --radius: 12px;
  --nav-h: 64px;
  --safe-x: max(16px, env(safe-area-inset-left));
  --safe-x-r: max(16px, env(safe-area-inset-right));
  --safe-top: max(16px, env(safe-area-inset-top));
  --safe-bottom: max(24px, env(safe-area-inset-bottom));
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "DM Sans", system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

body.demo-fs-open {
  overflow: hidden;
}

h1, h2, h3, h4, .serif {
  font-family: "Fraunces", Georgia, serif;
  font-weight: 500;
  letter-spacing: -0.02em;
}

a {
  color: var(--teal);
}

img {
  max-width: 100%;
  height: auto;
}

/* Password gate */
.gate {
  position: fixed;
  inset: 0;
  z-index: 300;
  display: grid;
  place-items: center;
  padding: 24px;
  background:
    radial-gradient(ellipse at 30% 20%, rgba(47, 102, 102, 0.35), transparent 50%),
    linear-gradient(160deg, var(--teal-dark) 0%, var(--teal) 45%, #123333 100%);
}

.gate[hidden],
.page[hidden] {
  display: none !important;
}

.gate-card {
  width: min(400px, 100%);
  background: rgba(255, 255, 255, 0.98);
  border-radius: 16px;
  padding: 36px 32px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.25);
}

.gate-eyebrow {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--teal);
  margin-bottom: 10px;
}

.gate-card h1 {
  font-size: 28px;
  color: var(--teal-dark);
}

.gate-copy {
  margin-top: 10px;
  color: var(--muted);
  font-size: 14px;
}

.gate-form {
  margin-top: 22px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.gate-form label {
  font-size: 12px;
  font-weight: 700;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.gate-form input {
  border: 1.5px solid var(--border);
  border-radius: 10px;
  padding: 12px 14px;
  font-family: inherit;
  font-size: 15px;
  outline: none;
}

.gate-form input:focus {
  border-color: var(--teal);
}

.gate-error {
  color: #c62828;
  font-size: 13px;
  font-weight: 600;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 18px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
  border: 1px solid var(--border);
  color: var(--teal-dark);
  background: #fff;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.15s ease, border-color 0.15s ease;
}

.btn:hover {
  border-color: var(--teal-muted);
  background: var(--teal-light);
}

.btn.primary {
  background: var(--teal-dark);
  color: #fff;
  border-color: var(--teal-dark);
}

.btn.primary:hover {
  background: var(--teal);
  border-color: var(--teal);
}

/* Page shell */
.page {
  min-height: 100vh;
}

.container {
  width: min(1120px, 100%);
  margin: 0 auto;
  padding-inline: var(--safe-x);
  padding-inline-end: var(--safe-x-r);
}

/* Top navigation */
.site-nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  padding-top: var(--safe-top);
}

.site-nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: var(--nav-h);
  padding-block: 8px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--teal-dark);
}

.brand-monogram {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--teal-dark);
  color: #fff;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.02em;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}

.brand-name {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  line-height: 1.2;
}

.nav-toggle {
  display: none;
  appearance: none;
  border: 0;
  background: transparent;
  width: 44px;
  height: 44px;
  border-radius: 8px;
  cursor: pointer;
  position: relative;
}

.nav-toggle span,
.nav-toggle span::before,
.nav-toggle span::after {
  display: block;
  position: absolute;
  left: 11px;
  right: 11px;
  height: 2px;
  background: var(--teal-dark);
  border-radius: 2px;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.nav-toggle span {
  top: 50%;
  transform: translateY(-50%);
}

.nav-toggle span::before {
  content: "";
  top: -7px;
}

.nav-toggle span::after {
  content: "";
  top: 7px;
}

.nav-toggle[aria-expanded="true"] span {
  background: transparent;
}

.nav-toggle[aria-expanded="true"] span::before {
  top: 0;
  transform: rotate(45deg);
}

.nav-toggle[aria-expanded="true"] span::after {
  top: 0;
  transform: rotate(-45deg);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 8px 24px;
  list-style: none;
}

.nav-links a {
  font-size: 14px;
  font-weight: 600;
  color: var(--muted);
  text-decoration: none;
  padding: 8px 4px;
  transition: color 0.15s ease;
}

.nav-links a:hover {
  color: var(--teal-dark);
}

/* Hero */
.hero {
  background: var(--bg-hero);
  padding:
    clamp(32px, 6vw, 64px) 0
    clamp(36px, 7vw, 72px);
  border-bottom: 1px solid var(--border);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

.hero-copy {
  min-height: 0;
}

.hero-welcome {
  font-family: "Fraunces", Georgia, serif;
  font-size: clamp(2rem, 5vw, 3.25rem);
  font-weight: 500;
  color: var(--teal-dark);
  line-height: 1.15;
  margin-bottom: 12px;
}

.hero-typewriter {
  min-height: 2.6em;
  margin-bottom: 16px;
}

.hero-line {
  font-size: clamp(1.125rem, 2.5vw, 1.5rem);
  color: var(--muted);
  line-height: 1.5;
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 0.4s ease, transform 0.4s ease;
}

.hero-line.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.hero-line .cursor {
  display: inline-block;
  width: 2px;
  height: 1em;
  background: var(--teal);
  margin-left: 2px;
  vertical-align: text-bottom;
  animation: blink 1s step-end infinite;
}

@keyframes blink {
  50% { opacity: 0; }
}

.hero-subtitle {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--teal);
  margin-bottom: 24px;
}

.hero-side {
  display: flex;
  align-items: flex-end;
  justify-content: flex-end;
}

.hero-photo {
  margin: 0;
  width: 100%;
  max-width: 360px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-card);
  overflow: hidden;
  line-height: 0;
}

.hero-photo img {
  display: block;
  width: 100%;
  height: auto;
  margin: 0;
  padding: 0;
  background: #fff;
}

.contact-block {
  padding: 20px 22px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-card);
}

.contact-label {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--teal);
  margin-bottom: 12px;
}

.contact-links {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.contact-link {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  font-weight: 600;
  color: var(--teal-dark);
  text-decoration: none;
}

.contact-link:hover {
  color: var(--teal);
}

.contact-icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  color: var(--teal);
}

.contact-meta {
  margin-top: 12px;
  font-size: 12px;
  color: var(--muted);
}

/* Achievement cards */
.achievement-cards {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  margin-top: 20px;
}

.achievement-cards.two-up {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: stretch;
}

.achievement-cards.two-up .achievement-card {
  height: 100%;
  display: flex;
  flex-direction: column;
}

.achievement-cards.two-up .achievement-card p:last-child {
  flex: 1;
}

.achievement-card {
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 22px;
  box-shadow: var(--shadow-card);
}

.case-card .achievement-card {
  background: #ffffff;
  border: 1px solid #c5dede;
  border-radius: var(--radius);
  padding: 20px 22px;
  box-shadow: 0 4px 24px rgba(26, 69, 69, 0.08);
}

.case-card.featured .achievement-card {
  border-color: #d0e0e0;
}

.case-card:not(.featured) .achievement-cards {
  background: #f4f8f8;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
}

.achievement-value {
  font-family: "Fraunces", Georgia, serif;
  font-size: clamp(1.25rem, 2.2vw, 1.5rem);
  font-weight: 600;
  color: var(--teal-dark);
  line-height: 1.1;
  margin-bottom: 6px;
}

.achievement-card h3 {
  font-family: "DM Sans", system-ui, sans-serif;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--teal);
  margin-bottom: 6px;
  line-height: 1.3;
}

.achievement-card p:last-child {
  font-size: 14px;
  color: var(--muted);
  line-height: 1.5;
  margin-bottom: 0;
}

/* Keep achievement typography inside case cards — overrides .case-card h3 */
.case-card .achievement-card h3 {
  font-family: "DM Sans", system-ui, sans-serif;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--teal);
  margin-bottom: 6px;
  line-height: 1.3;
}

.case-card .achievement-value {
  font-family: "Fraunces", Georgia, serif;
  font-size: clamp(1.25rem, 2.2vw, 1.5rem);
  font-weight: 600;
  color: var(--teal-dark);
  line-height: 1.1;
  margin-bottom: 6px;
}

.case-card .achievement-value.is-compact {
  font-size: clamp(1rem, 1.8vw, 1.2rem);
  letter-spacing: -0.02em;
}

.case-card .achievement-card p:not(.achievement-value) {
  font-size: 14px;
  color: var(--muted);
  line-height: 1.5;
  margin-bottom: 0;
}

/* Sections */
.section {
  padding: clamp(48px, 8vw, 80px) 0;
}

.section.muted {
  background: #f4f8f8;
}

.section-eyebrow {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--teal);
  margin-bottom: 12px;
}

.section-title {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  color: var(--teal-dark);
  margin-bottom: 12px;
  max-width: 20ch;
}

.section-lead {
  font-size: 16px;
  color: var(--muted);
  max-width: 52ch;
  margin-bottom: 40px;
}

/* Case study cards */
.cards-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

.case-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: clamp(24px, 4vw, 32px);
  box-shadow: var(--shadow-card);
  transition: box-shadow 0.2s ease, border-color 0.2s ease;
}

.case-card:hover {
  box-shadow: var(--shadow);
  border-color: #c5dede;
}

.case-card.featured {
  border-color: #b8d4d4;
  background: linear-gradient(135deg, #fff 0%, #f8fbfb 100%);
}

.case-badge {
  display: inline-block;
  background: var(--teal-dark);
  color: #fff;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 6px 10px;
  border-radius: 6px;
  margin-bottom: 16px;
}

.case-badge.amber {
  background: #e8a317;
  color: #1a1408;
}

.case-company {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--teal-muted);
  margin-bottom: 8px;
}

.case-company a {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid rgba(47, 102, 102, 0.3);
}

.case-company a:hover {
  color: var(--teal);
  border-bottom-color: var(--teal);
}

.case-card h3 {
  font-size: clamp(1.25rem, 3vw, 1.625rem);
  color: var(--teal-dark);
  margin-bottom: 12px;
  line-height: 1.25;
}

.case-lead {
  font-size: 15px;
  line-height: 1.65;
  color: var(--text);
  margin-bottom: 12px;
}

.case-lead:last-of-type {
  margin-bottom: 0;
}

.case-points {
  margin: 12px 0 0 18px;
  font-size: 14px;
}

.case-points li {
  margin-bottom: 6px;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 20px;
}

.tag {
  background: var(--pill);
  color: var(--teal-dark);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.02em;
  padding: 6px 12px;
  border-radius: 999px;
}

.metrics-row {
  display: flex;
  flex-wrap: wrap;
  gap: 16px 28px;
  margin-top: 20px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
}

.metric {
  min-width: 0;
}

.metric-value {
  display: block;
  font-family: "Fraunces", Georgia, serif;
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--teal-dark);
  line-height: 1.2;
}

.metric-label {
  display: block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  margin-top: 4px;
}

.case-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 20px;
  align-items: center;
}

.store-cta-label {
  font-size: 13px;
  font-weight: 700;
  color: var(--teal-dark);
  margin-top: 16px;
  margin-bottom: 8px;
}

.store-badges {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}

.store-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 0;
  text-decoration: none;
  height: 40px;
  width: 135px;
  overflow: hidden;
}

.store-badge img {
  display: block;
  height: 40px;
  width: 135px;
  object-fit: contain;
}

.company-name {
  font-weight: 800;
  color: var(--teal-dark);
}

a.company-name {
  text-decoration: none;
  border-bottom: 1px solid rgba(26, 69, 69, 0.25);
}

a.company-name:hover {
  color: var(--teal);
  border-bottom-color: var(--teal);
}

/* Demo disclosures */
.softspot-demos,
.design-studies-demos {
  margin-top: 24px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.demo-disclosure {
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
  background: #fff;
  width: 100%;
  max-width: 100%;
  min-width: 0;
}

.demo-disclosure-trigger {
  list-style: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 16px;
  font-size: 15px;
  font-weight: 700;
  color: var(--teal-dark);
  background: var(--teal-light);
  transition: background 0.15s ease;
  border-radius: 10px;
  width: 100%;
  min-width: 0;
}

.demo-disclosure[open] .demo-disclosure-trigger {
  border-radius: 10px 10px 0 0;
  border-bottom: 1px solid var(--border);
}

.demo-disclosure-trigger::-webkit-details-marker,
.demo-disclosure-trigger::marker {
  display: none;
  content: "";
}

.demo-disclosure-trigger:hover {
  background: #d8ecec;
}

.demo-disclosure-label {
  flex: 1;
  min-width: 0;
  overflow-wrap: anywhere;
}

.demo-disclosure-chevron {
  flex-shrink: 0;
  font-size: 22px;
  line-height: 1;
  color: var(--teal);
  transition: transform 0.2s ease;
}

.demo-disclosure[open] .demo-disclosure-chevron {
  transform: rotate(90deg);
}

.demo-disclosure-panel {
  padding: 0 16px 18px;
  overflow: hidden;
  max-width: 100%;
  min-width: 0;
}

.demo-caption {
  margin: 8px 0 14px;
  font-size: 13px;
  line-height: 1.55;
  color: var(--muted);
  overflow-wrap: anywhere;
}

.demo-caption-mobile {
  display: none;
}

@media (max-width: 767px) {
  .demo-caption-mobile {
    display: block;
  }

  details[data-demo-fs] .demo-disclosure-panel .softspot-demo,
  details[data-demo-fs] .demo-disclosure-panel .softspot-web-demo {
    display: none;
  }

  details[data-demo-fs] .demo-disclosure-panel > .demo-caption:not(.demo-caption-mobile) {
    display: none;
  }

  details[data-demo-fs][open] .demo-disclosure-trigger {
    border-radius: 10px;
    border-bottom: none;
  }

  details[data-demo-fs] .demo-disclosure-panel {
    display: none;
  }
}

@media (min-width: 768px) {
  .demo-caption-mobile {
    display: none !important;
  }
}

.softspot-demo {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  max-width: 100%;
}

.phone-preview-full {
  width: min(390px, 100%);
  max-width: 390px;
  margin-inline: auto;
  aspect-ratio: 454 / 851;
  height: auto;
  max-height: none;
  position: relative;
  background: transparent;
  overflow: hidden;
  touch-action: manipulation;
}

.phone-preview-full .phone-iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
  background: transparent;
  touch-action: manipulation;
  pointer-events: auto;
}

.softspot-web-demo {
  display: flex;
  flex-direction: column;
  width: 100%;
  max-width: 100%;
  min-width: 0;
}

.browser-preview {
  width: 100%;
  max-width: 100%;
  aspect-ratio: 16 / 10;
  height: auto;
  min-height: 420px;
  max-height: min(640px, 78vh);
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid rgba(26, 69, 69, 0.12);
  box-shadow: 0 16px 48px rgba(26, 69, 69, 0.1);
  background: #eef4f4;
  position: relative;
  touch-action: manipulation;
}

.browser-iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
  background: #eef4f4;
  touch-action: manipulation;
  pointer-events: auto;
}

/* Why me */
.strengths-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

.strength-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow-card);
}

.strength-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: var(--teal-light);
  color: var(--teal-dark);
  display: grid;
  place-items: center;
  font-size: 20px;
  margin-bottom: 14px;
}

.strength-card h3 {
  font-family: "DM Sans", system-ui, sans-serif;
  font-size: 16px;
  font-weight: 700;
  color: var(--teal-dark);
  margin-bottom: 8px;
  letter-spacing: 0;
}

.strength-card p {
  font-size: 14px;
  color: var(--muted);
  line-height: 1.55;
}

.hard-skills {
  margin-top: clamp(36px, 6vw, 56px);
  padding-top: clamp(28px, 5vw, 40px);
  border-top: 1px solid var(--border);
}

.hard-skills-title {
  font-family: "DM Sans", system-ui, sans-serif;
  font-size: clamp(1.25rem, 2.5vw, 1.5rem);
  font-weight: 700;
  color: var(--teal-dark);
  margin-bottom: 16px;
  letter-spacing: 0;
}

.hard-skills-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.skill-chip {
  background: #fff;
  border: 1px solid var(--border);
  color: var(--teal-dark);
  font-size: 13px;
  font-weight: 600;
  padding: 8px 14px;
  border-radius: 999px;
  box-shadow: var(--shadow-card);
}

/* Footer */
.footer {
  padding: 32px 0 calc(32px + var(--safe-bottom));
  border-top: 1px solid var(--border);
  text-align: center;
  color: var(--muted);
  font-size: 14px;
}

.footer a {
  color: var(--teal);
  text-decoration: none;
  font-weight: 600;
}

.footer a:hover {
  text-decoration: underline;
}

.footer .small {
  margin-top: 8px;
  font-size: 12px;
}

/* Fullscreen demo shell */
.demo-fs {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  flex-direction: column;
  background: var(--teal-dark);
}

.demo-fs[hidden] {
  display: none !important;
}

.demo-fs-bar {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 14px;
  padding-top: max(10px, env(safe-area-inset-top));
  background: rgba(26, 69, 69, 0.96);
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.demo-fs-note {
  flex: 1;
  min-width: 0;
  margin: 0;
  color: #f4f8f8;
  font-size: 13px;
  font-weight: 600;
}

.demo-fs-close {
  flex: 0 0 auto;
  appearance: none;
  border: 0;
  border-radius: 999px;
  padding: 10px 16px;
  font-family: inherit;
  font-size: 14px;
  font-weight: 700;
  color: var(--teal-dark);
  background: #fff;
  cursor: pointer;
}

.demo-fs-frame {
  flex: 1;
  width: 100%;
  min-height: 0;
  border: 0;
  background: #fff;
}

/* Responsive */
@media (min-width: 640px) {
  .strengths-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .achievement-cards {
    grid-template-columns: repeat(3, 1fr);
  }

  .achievement-cards.two-up {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .case-card:not(.featured) .achievement-cards {
    padding: 16px;
  }
}

@media (min-width: 768px) {
  .hero-grid {
    grid-template-columns: 1.05fr 0.95fr;
    grid-template-rows: auto 1fr;
    grid-template-areas:
      "copy photo"
      "contact photo";
    align-items: stretch;
    gap: 20px 40px;
  }

  .hero-copy {
    grid-area: copy;
    align-self: start;
  }

  .hero-side {
    grid-area: photo;
    align-self: stretch;
    justify-content: flex-end;
    align-items: flex-end;
  }

  .contact-block {
    grid-area: contact;
    align-self: end;
  }

  .hero-photo {
    margin-left: auto;
    align-self: flex-end;
  }

  .cards-grid {
    grid-template-columns: 1fr;
  }

  .strengths-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 767px) {
  .nav-toggle {
    display: block;
  }

  .nav-links {
    position: absolute;
    top: calc(100% + var(--safe-top));
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: rgba(255, 255, 255, 0.98);
    border-bottom: 1px solid var(--border);
    padding: 8px var(--safe-x) 16px;
    box-shadow: var(--shadow);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
  }

  .nav-links.is-open {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
  }

  .nav-links a {
    padding: 14px 8px;
    border-bottom: 1px solid var(--border);
  }

  .nav-links li:last-child a {
    border-bottom: 0;
  }

  .site-nav-inner {
    position: relative;
  }

  .demo-disclosure-panel {
    padding: 0 var(--safe-x) 16px;
  }

  .demo-disclosure-trigger {
    padding: 14px var(--safe-x);
    font-size: 14px;
  }

  .phone-preview-full {
    width: 100%;
    max-width: min(320px, 100%);
    aspect-ratio: 454 / 851;
    max-height: none;
  }

  .browser-preview {
    width: 100%;
    max-width: 100%;
    aspect-ratio: 10 / 13;
    min-height: 320px;
    max-height: min(560px, 75vh);
  }

  .store-badges {
    width: 100%;
  }
}

@media (max-width: 480px) {
  .hero-welcome {
    font-size: 1.75rem;
  }

  .hero-line {
    font-size: 1rem;
  }

  .case-card {
    padding: 20px 16px;
  }

  .contact-block {
    padding: 18px 16px;
  }

  .browser-preview {
    aspect-ratio: 3 / 4;
    max-height: min(440px, 68vh);
    border-radius: 10px;
  }

  .strengths-grid {
    grid-template-columns: 1fr;
  }
}
