/* ============================================================
   Sailing Companion — sailing-companion.com
   Static landing page styles
   ============================================================ */

:root {
  --navy: #0F3B62;
  --navy-dark: #08243F;
  --navy-light: #1E5687;
  --accent: #4D9EE3;
  --ink: #0F1A2A;
  --muted: #5A6B82;
  --hairline: #E2E8EF;
  --surface: #FFFFFF;
  --surface-tint: #F5F8FB;
  --max-width: 1140px;
  --radius: 14px;
  --shadow-sm: 0 1px 2px rgba(15, 26, 42, 0.06);
  --shadow-md: 0 8px 24px rgba(15, 26, 42, 0.08);
  --shadow-lg: 0 24px 60px rgba(15, 26, 42, 0.14);
}

@media (prefers-color-scheme: dark) {
  :root {
    --ink: #ECF1F8;
    --muted: #9AAAC0;
    --hairline: #1B2A3D;
    --surface: #0A1422;
    --surface-tint: #0F1E33;
    --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 24px 60px rgba(0, 0, 0, 0.55);
  }
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 17px;
  line-height: 1.55;
  color: var(--ink);
  background: var(--surface);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 32px;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3 { color: var(--ink); margin: 0; font-weight: 700; letter-spacing: -0.02em; }
h1 { font-size: clamp(2.4rem, 4.8vw, 3.6rem); line-height: 1.05; }
h2 { font-size: clamp(1.6rem, 2.5vw, 2.1rem); line-height: 1.15; }
h3 { font-size: 1.18rem; line-height: 1.3; }

p { margin: 0; }

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

.site-header {
  position: sticky;
  top: -1px;
  z-index: 50;
  background: rgba(255, 255, 255, 0.97);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  padding-top: env(safe-area-inset-top);
}
@media (prefers-color-scheme: dark) {
  .site-header { background: rgba(10, 20, 34, 0.92); }
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 18px;
  padding-bottom: 18px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  text-decoration: none;
  font-weight: 700;
  flex-shrink: 0;        /* brand (icon + name) always keeps priority — never squeezed */
  white-space: nowrap;
}
.brand:hover { text-decoration: none; }
.brand-logo {
  width: 36px;
  height: 36px;
  border-radius: 7px;
  box-shadow: var(--shadow-sm);
}
.brand-name { font-size: 1.4rem; letter-spacing: -0.01em; white-space: nowrap; }

.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
  min-width: 0;          /* allow the nav side to shrink so the brand never wraps */
  flex-wrap: nowrap;
}
.nav-links a {
  color: var(--muted);
  font-size: 0.95rem;
  font-weight: 500;
}
.nav-links a.btn {
  color: #FFFFFF;
}
.nav-links a:hover { color: var(--ink); text-decoration: none; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 7px 16px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.9rem;
  transition: transform 0.15s ease, background 0.15s ease, color 0.15s ease;
  cursor: pointer;
  border: 1px solid transparent;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn-ghost {
  background: var(--navy);
  color: #FFFFFF;
}
.btn-ghost:hover { background: var(--accent); }
.btn-secondary {
  background: transparent;
  color: var(--ink);
  border-color: var(--hairline);
}
.btn-secondary:hover { background: var(--surface-tint); }

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

.hero {
  background:
    radial-gradient(ellipse 80% 60% at 20% 0%, rgba(77,158,227,0.18), transparent 60%),
    radial-gradient(ellipse 60% 50% at 100% 30%, rgba(15,59,98,0.10), transparent 60%),
    linear-gradient(180deg, var(--surface), var(--surface));
  padding: 80px 0 100px;
}

.hero-inner {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 64px;
  align-items: center;
}

.hero-eyebrow {
  display: inline-block;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 14px;
}

.hero-lead {
  margin-top: 22px;
  color: var(--muted);
  font-size: 1.18rem;
  max-width: 540px;
}

.hero-actions {
  display: flex;
  gap: 14px;
  margin-top: 36px;
  flex-wrap: wrap;
  align-items: center;
}

.app-store-badge {
  display: inline-block;
  line-height: 0;
  border-radius: 9px;
  overflow: hidden;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.app-store-badge:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
  text-decoration: none;
}
.app-store-badge--large img { width: 220px; height: auto; }

.hero-meta {
  margin-top: 22px;
  color: var(--muted);
  font-size: 0.92rem;
}

.hero-visual {
  display: flex;
  justify-content: center;
}
.hero-logo {
  width: min(360px, 100%);
  height: auto;
  transition: transform 0.4s ease;
}
.hero-logo:hover { transform: scale(1.02) rotate(-1deg); }

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

/* Reveal-on-scroll base: anything with data-reveal starts hidden and fades in when .is-visible is added by JS. */
[data-reveal] {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
[data-reveal].is-visible {
  opacity: 1;
  transform: translateY(0);
}
.feature-card[data-reveal] {
  transition: opacity 0.7s ease, transform 0.7s ease, box-shadow 0.2s ease;
  transition-delay: var(--reveal-delay, 0ms);
}

/* ─── Hero Slider ─────────────────────────────── */
.hero-slider {
  position: relative;
  height: 60vh;
  min-height: 400px;
  overflow: hidden;
}

.slide {
  position: absolute;
  inset: 0;
  overflow: hidden;
}

/* Slide backgrounds */
.slide-bg {
  position: absolute;
  inset: 0;
  background-image: url('assets/hero.webp');
  background-position: right center;
  background-size: cover;
}

@media (prefers-color-scheme: dark) {
  .slide-bg { background-image: url('assets/hero_dark.webp'); }
}

@media (min-width: 1100px) {
  .hero-slider { height: min(calc(100vw / 1.7917), 768px); }
  .slide-bg { background-position: 65% center; }
  .slide-2 .slide-bg { background-position: 33% center; }
}

/* Slide content */
.slide-content {
  position: relative;
  z-index: 1;
  height: 100%;
  display: flex;
  align-items: center;
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding-left: 32px;
  padding-right: 32px;
  box-sizing: border-box;
}

/* Headline */
.cinematic-headline {
  color: #fff;
  font-size: clamp(2.04rem, 4.08vw, 3.06rem);
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: -0.02em;
  text-align: left;
  text-shadow: 0 2px 20px rgba(0,0,0,0.5);
}
@media (max-width: 800px) { .cinematic-headline { display: none; } }

/* ─── Section common ─────────────────────────────── */

section { padding: 90px 0; }

.section-title {
  text-align: center;
  margin-bottom: 12px;
}
.section-lead {
  text-align: center;
  color: var(--muted);
  font-size: 1.08rem;
  margin-bottom: 56px;
  max-width: 640px;
  margin-left: auto;
  margin-right: auto;
}

/* ─── Features ──────────────────────────────────── */

.features { background: var(--surface-tint); }

.features .section-title,
.features .section-lead {
  color: var(--text-primary);
}

.features .feature-card {
  background: var(--surface);
  color: var(--text-primary);
}

@media (prefers-color-scheme: dark) {
  .features .feature-card {
    background: var(--surface);
    color: #e8edf5;
  }
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}

.feature-card {
  background: var(--surface);
  padding: 22px 24px;
  border-radius: var(--radius);
  border: 1px solid var(--hairline);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  display: grid;
  grid-template-columns: auto 1fr;
  grid-template-areas:
    "icon  title"
    "body  body";
  column-gap: 14px;
  row-gap: 8px;
  align-items: center;
}
.feature-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}
.feature-card .feature-icon {
  grid-area: icon;
  width: 44px;
  height: 44px;
  margin-bottom: 0;
}
.feature-card h3 {
  grid-area: title;
  margin: 0;
  font-size: 1.05rem;
  line-height: 1.25;
}
.feature-card p {
  grid-area: body;
  margin: 0;
  color: var(--muted);
  font-size: 0.94rem;
  line-height: 1.5;
}

.feature-icon {
  width: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(77,158,227,0.16), rgba(15,59,98,0.10));
  color: var(--navy);
  margin-bottom: 18px;
}
@media (prefers-color-scheme: dark) {
  .feature-icon { color: var(--accent); }
  .what-is-num {
    color: #FFFFFF;
    background: linear-gradient(135deg, rgba(77,158,227,0.35), rgba(15,59,98,0.25));
  }
}

/* ─── Screenshots ────────────────────────────────── */

.screenshot-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  align-items: end;
}

.phone {
  margin: 0;
  text-align: center;
}
.phone img {
  width: 100%;
  max-width: 280px;
  height: auto;
  display: block;
  margin: 0 auto;
  filter: drop-shadow(0 16px 32px rgba(15,26,42,0.18));
}
.phone--featured img {
  max-width: 320px;
  transform: translateY(-12px);
}
.phone figcaption {
  margin-top: 18px;
  color: var(--muted);
  font-weight: 500;
}

/* ─── Languages ──────────────────────────────────── */

.languages { background: var(--surface-tint); }

.language-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
}
.language-list li {
  background: var(--surface);
  border: 1px solid var(--hairline);
  border-radius: 10px;
  padding: 12px 16px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.flag-img {
  width: 28px;
  height: 18px;
  border-radius: 3px;
  object-fit: cover;
  flex-shrink: 0;
}

/* ─── Reviews Marquee ───────────────────────────── */

.reviews {
  padding: 80px 0 100px;
  background-image: linear-gradient(rgba(15,59,98,0.92), rgba(8,36,63,0.95)), url('assets/reviews-bg.webp');
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
}
.reviews .section-title { color: #fff; }
.reviews .section-lead { color: rgba(255,255,255,0.8); }
.reviews-marquee {
  position: relative;
  overflow: hidden;
  margin-top: 40px;
}
.reviews-fade {
  position: relative;
  overflow: hidden;
}
.reviews-fade::before,
.reviews-fade::after {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0;
  width: 80px;
  z-index: 2;
  pointer-events: none;
}
.reviews-fade::before {
  left: 0;
  background: linear-gradient(to right, rgba(8,36,63,0.95), transparent);
}
.reviews-fade::after {
  right: 0;
  background: linear-gradient(to left, rgba(8,36,63,0.95), transparent);
}
.reviews-track {
  display: flex;
  gap: 20px;
  width: max-content;
  animation: marquee-scroll 60s linear infinite;
}
.reviews-track:hover {
  animation-play-state: paused;
}
@keyframes marquee-scroll {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}
.review-card {
  flex: 0 0 320px;
  background: var(--surface);
  border: 1px solid var(--hairline);
  border-radius: 14px;
  padding: 24px;
  box-shadow: 0 2px 12px rgba(0,0,0,0.06);
}
.review-stars {
  font-size: 1.1rem;
  letter-spacing: 2px;
  color: #f5a623;
  margin-bottom: 12px;
}
.review-text {
  font-size: 0.95rem;
  line-height: 1.55;
  color: var(--ink);
  margin-bottom: 16px;
}
.review-author {
  display: flex;
  align-items: center;
  gap: 10px;
}
.review-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  color: #fff;
  font-size: 0.9rem;
}
.review-avatar--blue   { background: #3b82f6; }
.review-avatar--teal   { background: #14b8a6; }
.review-avatar--navy   { background: #1e3a5f; }
.review-avatar--amber  { background: #f59e0b; }
.review-avatar--coral  { background: #f97316; }
.review-avatar--violet { background: #8b5cf6; }
.review-avatar--sea    { background: #0ea5e9; }
.review-avatar--sky    { background: #6366f1; }
.review-meta {
  font-size: 0.82rem;
  color: var(--muted);
}

@media (prefers-reduced-motion: reduce) {
  .reviews-track {
    animation: none;
    flex-wrap: wrap;
    width: 100%;
    justify-content: center;
  }
}

/* ─── Screenshots Carousel ─────────────────────── */

/* ─── Screenshots carousel ─────────────────────────── */
.screenshots {
  padding: 80px 0;
  position: relative;
  overflow: hidden;
  isolation: isolate;
  --shots-bg: url('assets/cockpit_landscape.jpg');   /* light-mode background image */
}
@media (prefers-color-scheme: dark) {
  .screenshots { --shots-bg: url('assets/cockpit_landscape_dark.webp'); }  /* dark-mode background image */
}
.screenshots::before {
  content: '';
  position: absolute;
  inset: -40px;
  background: var(--shots-bg) center / cover no-repeat;
  filter: saturate(1.05);
  transform: scale(1.08);
  z-index: -2;
}
.screenshots::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, 0.5);
  z-index: -1;
}
@media (prefers-color-scheme: dark) {
  .screenshots::after { background: rgba(8, 17, 28, 0.5); }
}
.screenshots > * { position: relative; z-index: 1; }

.carousel {
  position: relative;
  max-width: 1000px;
  margin: 40px auto 0;
  padding: 0 58px;
}

.carousel-stage {
  --slide-w: clamp(210px, 25vw, 275px);   /* desktop / landscape iPad: ~3 visible */
  display: flex;
  gap: clamp(16px, 2.5vw, 26px);
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  align-items: center;
  padding: 22px calc(50% - var(--slide-w) / 2);
}
.carousel-stage::-webkit-scrollbar { display: none; }

.carousel-item {
  flex: 0 0 var(--slide-w);
  scroll-snap-align: center;
  scroll-snap-stop: always;
  margin: 0;
  opacity: 0.8;
  transform: scale(0.84);
  transition: transform 0.45s cubic-bezier(0.25, 0.46, 0.45, 0.94), opacity 0.45s ease;
  will-change: transform, opacity;
}
.carousel-item.is-center {
  opacity: 1;
  transform: scale(1);
  z-index: 2;
}
@media (prefers-reduced-motion: reduce) {
  .carousel-stage { scroll-behavior: auto; }
  .carousel-item { transition: none; }
}

.carousel-item-inner {
  width: 100%;
  aspect-ratio: 1080 / 2347;
  border-radius: 13% / 6%;
  overflow: hidden;
  background: transparent;
  box-shadow: 0 4px 10px rgba(15, 26, 42, 0.35);
}
@media (prefers-color-scheme: dark) {
  .carousel-item-inner {
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.55);
  }
}
.carousel-item-inner img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.carousel-item.is-center .carousel-item-inner {
  box-shadow: 0 6px 14px rgba(15, 26, 42, 0.45);
}
@media (prefers-color-scheme: dark) {
  .carousel-item.is-center .carousel-item-inner {
    box-shadow: 0 6px 14px rgba(0, 0, 0, 0.65);
  }
}

.carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: 1px solid var(--hairline);
  background: var(--surface);
  color: var(--ink);
  cursor: pointer;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 5;
  box-shadow: var(--shadow-sm);
  transition: background 0.2s, color 0.2s, transform 0.15s;
}
.carousel-btn:hover { background: var(--navy); color: #fff; }
.carousel-btn:active { transform: translateY(-50%) scale(0.94); }
.carousel-btn--prev { left: 0; }
.carousel-btn--next { right: 0; }
@media (min-width: 768px) {
  .carousel-btn { display: flex; }
}

.carousel-meta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-top: 24px;
}
.carousel-dots {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: center;
  max-width: 320px;
}
.carousel-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  border: none;
  background: var(--hairline);
  cursor: pointer;
  padding: 0;
  transition: background 0.2s, transform 0.2s;
}
.carousel-dot[aria-selected="true"] {
  background: var(--accent);
  transform: scale(1.3);
}
.carousel-counter {
  font-size: 0.85rem;
  color: var(--muted);
}

@media (max-width: 767px) {
  .carousel { max-width: 100vw; width: 100vw; margin-left: calc(50% - 50vw); padding: 0; }
  .carousel-stage { --slide-w: min(65vw, 270px); }
}

/* ─── Social Video ──────────────────────────────── */

.social-video {
  padding: 80px 0;
  text-align: center;
  background: var(--surface);
}
.video-wrapper {
  max-width: 320px;
  margin: 40px auto 0;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}
.video-wrapper video {
  width: 100%;
  height: auto;
  display: block;
}

/* ─── What Is / The Deal ────────────────────────── */

.what-is {
  padding: 80px 0;
  position: relative;
}
.what-is-accordion {
  max-width: 760px;
  margin: 0 auto;
}
.what-is-row {
  background: var(--surface);
  border: 1px solid var(--hairline);
  border-radius: 14px;
  margin-bottom: 14px;
  overflow: hidden;
  transition: box-shadow 0.2s ease;
}
.what-is-row[open] {
  box-shadow: var(--shadow-md);
}
.what-is-row summary {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 22px 24px;
  cursor: pointer;
  list-style: none;
  font-weight: 700;
  color: var(--ink);
}
.what-is-row summary::-webkit-details-marker { display: none; }
.what-is-num {
  flex: 0 0 52px;
  height: 52px;
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(77,158,227,0.16), rgba(15,59,98,0.10));
  color: var(--navy);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  font-weight: 800;
}
.what-is-title {
  flex: 1;
  font-size: 1.12rem;
}
.what-is-icon {
  flex: 0 0 24px;
  height: 24px;
  position: relative;
}
.what-is-icon::before,
.what-is-icon::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  background: var(--muted);
  transition: transform 0.2s ease, background 0.2s ease;
}
.what-is-icon::before {
  width: 12px;
  height: 2px;
  transform: translate(-50%, -50%);
}
.what-is-icon::after {
  width: 2px;
  height: 12px;
  transform: translate(-50%, -50%);
}
.what-is-row[open] .what-is-icon::after {
  transform: translate(-50%, -50%) rotate(90deg);
  opacity: 0;
}
.what-is-row[open] .what-is-icon::before {
  background: var(--accent);
}
.what-is-row[open] .what-is-num {
  background: linear-gradient(135deg, rgba(77,158,227,0.28), rgba(15,59,98,0.18));
  color: var(--accent);
}
.what-is-body {
  padding: 0 24px 24px;
  color: var(--muted);
  line-height: 1.65;
  font-size: 1rem;
}

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

.cta {
  background: linear-gradient(135deg, var(--navy), var(--navy-light));
  color: #fff;
  padding: 56px 0;
}
.cta h2 { color: #fff; font-size: clamp(1.8rem, 3vw, 2.4rem); }
.cta-inner { text-align: center; }
.cta p { color: rgba(255,255,255,0.85); margin: 12px 0 28px; }
.cta-note { font-size: 0.88rem; opacity: 0.7; margin-top: 18px; }

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

.site-footer {
  background: var(--navy-dark);
  color: rgba(255, 255, 255, 0.75);
  padding: 40px 0;
}
.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 18px;
}
.footer-brand {
  display: flex;
  align-items: center;
  gap: 12px;
}
.footer-logo {
  width: 28px;
  height: 28px;
  border-radius: 6px;
}
.footer-links {
  display: flex;
  gap: 22px;
  flex-wrap: wrap;
}
.footer-links a {
  color: rgba(255, 255, 255, 0.75);
  font-size: 0.95rem;
}
.footer-links a:hover { color: #fff; text-decoration: none; }

.footer-social {
  display: flex;
  gap: 14px;
}
.social-icon {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255, 255, 255, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.15);
  transition: color 0.2s, border-color 0.2s, transform 0.15s;
}
.social-icon:hover {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.4);
  transform: translateY(-2px);
}

/* ─── Legal pages ────────────────────────────────── */

.legal {
  max-width: 760px;
  margin: 0 auto;
  padding: 60px 32px 120px;
}
.legal h1 { font-size: 2rem; margin-bottom: 8px; }
.legal .legal-eyebrow {
  color: var(--muted);
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 18px;
}
.legal h2 { font-size: 1.25rem; margin-top: 36px; margin-bottom: 12px; }
.legal p { margin-bottom: 14px; color: var(--ink); }
.legal address {
  font-style: normal;
  background: var(--surface-tint);
  border-radius: 10px;
  padding: 16px 18px;
  margin: 18px 0 24px;
  border: 1px solid var(--hairline);
}
.legal a.back {
  display: inline-block;
  margin-top: 32px;
  color: var(--muted);
  font-size: 0.95rem;
}

/* ─── Responsive ────────────────────────────────── */

@media (max-width: 900px) {
  .hero-inner { grid-template-columns: 1fr; gap: 36px; }
  .hero-visual { order: -1; }
  .hero-logo { width: 220px; }
  .feature-grid { grid-template-columns: repeat(2, 1fr); }
  .screenshot-row { grid-template-columns: 1fr; gap: 40px; }
  .phone--featured img { transform: none; }
  .nav-links { gap: 14px; }
  .nav-links a:not(.btn) { display: none; }
}

@media (max-width: 560px) {
  section { padding: 64px 0; }
  .hero { padding: 56px 0 72px; }
  .feature-grid { grid-template-columns: 1fr; }
  .feature-card h3 { font-size: 1.21rem; }
  .container { padding: 0 20px; }
  .footer-inner { flex-direction: column; align-items: flex-start; }
  .nav-links .btn { padding: 5px 12px; font-size: 0.82rem; }
  .header-inner { padding-top: 22px; padding-bottom: 22px; }

  /* On phones the brand + language selector take priority.
     Sacrifice the "Get the app" button before the language selector,
     and compact the selector to flag + chevron (full names stay in its menu). */
  .nav-links .btn-ghost { display: none; }
  .lang-switcher .lang-details > summary > span { display: none; }
}

/* Extra-narrow phones: trim the brand name a touch so it still never wraps. */
@media (max-width: 380px) {
  .brand-name { font-size: 1.2rem; }
  .brand-logo { width: 32px; height: 32px; }
}

.slide-2 .slide-bg { background-image: url('assets/watch_cockpit_bright.webp'); }
@media (prefers-color-scheme: dark) {
  .slide-2 .slide-bg { background-image: url('assets/watch_cockpit_dark.webp'); }
}
.slide-2 .slide-bg { background-position: 33% center; }
.slide-2 .slide-content {
  position: absolute;
  right: 0;
  left: auto;
  height: 100%;
  display: flex;
  align-items: center;
  max-width: 40%;
  padding-left: 0;
  padding-right: 16px;
  box-sizing: border-box;
}
.slide-2 .cinematic-headline { text-align: right; }

@media (max-width: 800px) {
  .slide-2 .slide-bg { background-position: 45% center; }
}

/* ── Cockpit Showcase ── */
.cockpit-showcase {
  position: relative;
  width: 100%;
  margin: 0;
  padding: 0;
  overflow: hidden;
}
.cockpit-showcase picture {
  display: block;
  width: 100%;
  height: 0;
  padding-bottom: 55.81%; /* 768/1376 aspect ratio */
  position: relative;
  overflow: hidden;
}
.cockpit-showcase img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.cockpit-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding-left: 32px;
  padding-right: 32px;
  box-sizing: border-box;
  z-index: 1;
}
@media (max-width: 768px) {
  .cockpit-showcase picture {
    padding-bottom: 0;
    height: 60vh;
    min-height: 400px;
  }
  .cockpit-showcase img {
    object-position: 80% center;
  }
}
