/* Matchermind — public site (design A · Dial) */
:root {
  --bg: #F7F2EA;
  --card: #FFFFFF;
  --ink: #1F3A44;
  --muted: #4F6B75;
  --line: #E8E0D3;
  --teal: #4A8196;
  --teal-mid: #5994A0;
  --deep: #2F5F70;
  --mint: #E3F1EF;
  --coral: #F58B84;
  --coral-soft: #FDE3E0;
  --berry: #BF576E;
  --berry-ink: #9C3F55;
  --phone: #16262D;
  --radius-card: 28px;
  --wrap: 1200px;
  --font: 'Nunito', 'Noto Sans Devanagari', system-ui, -apple-system, 'Segoe UI', sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; }
a { color: var(--deep); }
a:hover { color: var(--ink); }
h1, h2, h3 { margin: 0; line-height: 1.1; font-weight: 900; letter-spacing: -0.02em; }
h2 { font-size: clamp(30px, 3.6vw, 44px); margin-bottom: 28px; }
h3 { font-size: 21px; letter-spacing: -0.01em; }
p { margin: 0; }
:focus-visible { outline: 3px solid var(--berry); outline-offset: 3px; border-radius: 8px; }
section[id] { scroll-margin-top: 16px; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding-left: 24px; padding-right: 24px; }
.wrap.narrow { max-width: 860px; }

.skip-link { position: absolute; left: 16px; top: -60px; background: var(--card); padding: 10px 14px; border-radius: 10px; z-index: 100; }
.skip-link:focus { top: 12px; }

.draft-banner { position: sticky; top: 0; z-index: 60; background: #FDF0D8; color: #6B4508; text-align: center; font-weight: 800; padding: 8px 16px; font-size: 15px; }

/* Header */
.site-header { position: relative; z-index: 20; }
.header-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-top: 18px; padding-bottom: 18px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); font-weight: 900; font-size: 22px; letter-spacing: -0.01em; }
.brand img { width: 40px; height: 40px; }
.main-nav { display: flex; gap: 28px; font-weight: 700; }
.main-nav a { color: var(--ink); text-decoration: none; }
.main-nav a:hover { color: var(--teal); }
.header-actions { display: flex; align-items: center; gap: 8px; }

.popover { position: relative; }
.popover > summary { list-style: none; }
.popover > summary::-webkit-details-marker { display: none; }
.pill-button {
  display: inline-flex; align-items: center; gap: 6px; height: 44px; padding: 0 14px;
  border-radius: 22px; border: 2px solid #CFE3E2; background: var(--card); color: var(--ink);
  font-weight: 800; font-size: 15px; cursor: pointer; user-select: none;
}
.pill-button svg { color: var(--teal); }
.pill-button .chev { color: var(--ink); transition: transform .2s ease; }
.popover[open] .pill-button .chev { transform: rotate(180deg); }
.pill-button.icon-only { width: 44px; padding: 0; justify-content: center; }
.pill-button.icon-only svg { color: var(--ink); }
.popover-panel {
  position: absolute; right: 0; top: calc(100% + 8px); z-index: 30; min-width: 220px;
  background: var(--card); border: 2px solid var(--line); border-radius: 20px; padding: 8px; margin: 0;
  box-shadow: 0 12px 32px rgba(31, 58, 68, .12);
}
.lang-list { list-style: none; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2px; min-width: 300px; }
.lang-list a, .menu-list a {
  display: flex; align-items: center; justify-content: space-between; gap: 8px; min-height: 44px; padding: 0 12px;
  border-radius: 12px; color: var(--ink); text-decoration: none; font-weight: 700;
}
.lang-list a:hover, .menu-list a:hover { background: var(--mint); }
.lang-list a[aria-current] { background: var(--mint); }
.lang-list a span { color: var(--teal); font-weight: 900; }
.menu-list { display: flex; flex-direction: column; min-width: 220px; }
.mobile-menu { display: none; }

/* Hero */
.hero { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); align-items: center; gap: 48px; padding-top: 28px; padding-bottom: 72px; }
.hero-text { display: flex; flex-direction: column; gap: 24px; }
.eyebrow { align-self: flex-start; padding: 8px 14px; border-radius: 999px; background: var(--coral-soft); color: var(--berry-ink); font-size: 14px; font-weight: 800; }
.hero h1 { font-size: clamp(38px, 5.2vw, 64px); line-height: 1.04; letter-spacing: -0.025em; }
.accent { color: var(--berry); }
.lead { font-size: 20px; color: var(--muted); max-width: 560px; }
.cta-row { display: flex; flex-wrap: wrap; align-items: center; gap: 20px; margin-top: 8px; }
.store-badge { display: inline-block; line-height: 0; border-radius: 12px; transition: transform .15s ease; }
.store-badge:hover { transform: translateY(-1px); }
.store-badge img { height: 56px; width: auto; }
.store-badge.on-dark { padding: 6px; background: var(--card); border-radius: 16px; }
.qr-card { display: flex; align-items: center; gap: 12px; padding: 8px 14px 8px 8px; border-radius: 16px; background: var(--card); border: 2px solid var(--line); }
.qr { display: block; line-height: 0; background: #fff; padding: 4px; border-radius: 8px; }
.qr svg { width: 64px; height: 64px; display: block; }
.qr-text { font-size: 14px; line-height: 1.35; color: var(--muted); max-width: 160px; }
.qr-text strong { display: block; color: var(--ink); }

.hero-visual { display: flex; flex-direction: column; align-items: center; gap: 8px; }
.dial { position: relative; width: min(500px, 100%); aspect-ratio: 1 / 1; }
.dial-logo { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero-phone {
  position: absolute; left: 50%; top: 50%; width: 34%; padding: 8px; border: 0; border-radius: 36px;
  background: var(--phone); cursor: pointer; transform: translate(-50%, -50%) rotate(-6deg);
  transition: transform .25s ease;
}
.hero-phone:hover { transform: translate(-50%, -50%) rotate(-3deg) scale(1.03); }
.hero-screen { position: relative; display: block; overflow: hidden; border-radius: 29px; aspect-ratio: 720 / 1565; background: #F4EEE5; }
.hero-shot { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transform: translateY(12px) scale(1.03); transition: opacity .9s ease, transform .9s ease; }
.hero-shot.is-active { opacity: 1; transform: none; }
.hero-caption { font-size: 15px; font-weight: 700; color: var(--muted); min-height: 1.5em; text-align: center; }

/* Stats */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 20px; padding-bottom: 80px; }
.stat { display: flex; align-items: center; gap: 20px; background: var(--card); border: 2px solid var(--line); border-radius: var(--radius-card); padding: 28px 32px; }
.stat-value { font-size: 64px; font-weight: 900; line-height: 1; }
.stat-value.teal { color: var(--teal); }
.stat-value.berry { color: var(--berry); }
.stat-label { font-size: 18px; font-weight: 700; line-height: 1.35; }

/* Gallery */
.gallery { padding-bottom: 88px; }
.gallery h2 { margin-bottom: 20px; }
.strip {
  --pad: max(24px, calc((100% - var(--wrap)) / 2 + 24px));
  position: relative; display: flex; gap: 28px; overflow-x: auto; scroll-snap-type: x mandatory;
  scroll-padding-left: var(--pad); padding: 8px var(--pad) 24px; scrollbar-width: none;
}
.strip::-webkit-scrollbar { display: none; }
.strip:focus-visible { outline-offset: -3px; }
.shot { flex: 0 0 auto; width: 240px; margin: 0; display: flex; flex-direction: column; gap: 14px; scroll-snap-align: start; }
.phone { border-radius: 38px; background: var(--phone); padding: 8px; outline: 4px solid transparent; outline-offset: 5px; transition: outline-color .5s ease; }
.phone img { display: block; width: 100%; height: auto; border-radius: 31px; }
.shot.is-flash .phone { outline-color: var(--coral); }
.shot figcaption { padding: 0 6px; }
.shot strong { display: block; font-size: 18px; font-weight: 900; line-height: 1.25; }
.shot figcaption span { display: block; font-size: 15px; line-height: 1.4; color: var(--muted); margin-top: 2px; }
.gallery-nav { display: flex; align-items: center; justify-content: center; gap: 12px; padding: 8px 24px 0; }
.round-button { flex: 0 0 auto; width: 48px; height: 48px; border-radius: 50%; border: 2px solid #CFE3E2; background: var(--card); color: var(--ink); display: inline-flex; align-items: center; justify-content: center; cursor: pointer; }
.round-button:hover { border-color: var(--teal-mid); }
.dots { display: flex; flex-wrap: wrap; justify-content: center; }
.dot { width: 26px; height: 44px; border: 0; padding: 0; background: transparent; display: inline-flex; align-items: center; justify-content: center; cursor: pointer; }
.dot span { display: block; width: 10px; height: 10px; border-radius: 5px; background: #C9D9D8; transition: width .3s ease, background-color .3s ease; }
.dot.is-active span { width: 28px; background: var(--teal); }
.no-js-hide { display: none; }
html:not(.js) .gallery-nav { display: none; }

/* Features */
.features { padding-bottom: 96px; }
.feature-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 20px; }
.card { background: var(--card); border: 2px solid var(--line); border-radius: var(--radius-card); }
.feature { padding: 28px; display: flex; flex-direction: column; gap: 12px; }
.feature p { font-size: 16px; color: var(--muted); }
.feature-icon { width: 56px; height: 56px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; color: var(--ink); flex: 0 0 auto; }
.feature-icon .emoji { font-size: 28px; line-height: 1; }
.feature-icon .custom-svg { display: inline-flex; width: 26px; height: 26px; }
.feature-icon .custom-svg svg { width: 100%; height: 100%; }

/* How it works */
.how { background: var(--mint); padding: 88px 0; }
.how h2 { margin-bottom: 40px; }
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 32px; }
.step { display: flex; flex-direction: column; gap: 14px; }
.step-num { width: 72px; height: 72px; border-radius: 50%; background: #F4EEE5; border: 8px solid var(--teal-mid); display: inline-flex; align-items: center; justify-content: center; font-size: 26px; font-weight: 900; color: var(--berry); flex: 0 0 auto; }
.step h3 { font-size: 22px; margin-bottom: 6px; }
.step p { color: #3E5A64; }

/* FAQ */
.faq { padding-top: 96px; padding-bottom: 96px; }
.faq h2 { margin-bottom: 24px; }
.faq-item { background: var(--card); border: 2px solid var(--line); border-radius: 22px; padding: 0 24px; margin-bottom: 12px; }
.faq-item summary { list-style: none; display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 64px; font-size: 19px; font-weight: 800; cursor: pointer; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item p { padding-bottom: 20px; color: var(--muted); }
.plus { position: relative; width: 18px; height: 18px; flex: 0 0 auto; }
.plus::before, .plus::after { content: ''; position: absolute; left: 0; top: 8px; width: 18px; height: 3px; border-radius: 2px; background: var(--teal); transition: transform .2s ease; }
.plus::after { transform: rotate(90deg); }
.faq-item[open] .plus::after { transform: rotate(0deg); }

/* Final CTA */
.final { padding-bottom: 88px; }
.final-card { background: var(--deep); color: #fff; border-radius: 40px; padding: 56px 48px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 32px; }
.final-card h2 { color: #fff; margin-bottom: 12px; }
.final-card p { font-size: 19px; color: #D6ECEA; }
.final-actions { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; }
.qr-final { padding: 8px; border-radius: 16px; }
.qr-final svg { width: 84px; height: 84px; }

/* Footer */
.site-footer { border-top: 2px solid var(--line); padding: 40px 0 48px; font-size: 15px; }
.footer-row { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 20px 32px; }
.footer-brand { display: flex; align-items: center; gap: 10px; font-weight: 800; }
.footer-links { display: flex; flex-wrap: wrap; gap: 4px 24px; font-weight: 700; }
.footer-links a { display: inline-flex; align-items: center; min-height: 44px; }
.footer-langs { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 4px 14px; color: var(--muted); font-weight: 600; }
.footer-langs a { color: var(--muted); text-decoration: none; }
.footer-langs a:hover, .footer-langs a[aria-current] { color: var(--ink); text-decoration: underline; }
.legal-note { margin-top: 16px; color: var(--muted); font-size: 14px; }

/* Sticky App Store bar (iPhone/iPad and narrow screens) */
.sticky-bar { display: none; position: fixed; left: 0; right: 0; bottom: 0; z-index: 40; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 16px calc(10px + env(safe-area-inset-bottom)); background: rgba(255, 255, 255, .96); border-top: 2px solid var(--line); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }
.sticky-app { display: flex; align-items: center; gap: 10px; }
.sticky-app img { width: 40px; height: 40px; }
.sticky-app strong { display: block; font-weight: 900; line-height: 1.2; }
.sticky-app small { display: block; font-size: 13px; font-weight: 600; color: var(--muted); }
.sticky-get { display: inline-flex; align-items: center; height: 44px; padding: 0 20px; border-radius: 12px; background: #141414; color: #fff; text-decoration: none; font-weight: 800; }
.sticky-get:hover { color: #fff; background: #000; }

html.is-ios .desktop-only { display: none; }
html.is-ios .sticky-bar { display: flex; }
html.is-ios body { padding-bottom: 76px; }

/* Tablet and below */
@media (max-width: 900px) {
  .main-nav { display: none; }
  .mobile-menu { display: block; }
  .hero { grid-template-columns: 1fr; gap: 24px; padding-bottom: 48px; }
  .hero-visual { order: 2; }
}

/* Phones */
@media (max-width: 640px) {
  body { font-size: 16px; padding-bottom: 76px; }
  .wrap { padding-left: 20px; padding-right: 20px; }
  .header-row { padding-top: 12px; padding-bottom: 12px; }
  .brand { font-size: 19px; }
  .brand img { width: 34px; height: 34px; }
  .lang-list { min-width: 0; width: calc(100vw - 40px); }
  .popover-panel { right: -52px; }
  .mobile-menu .popover-panel { right: 0; }
  .hero h1 { font-size: 36px; }
  .lead { font-size: 17px; }
  .cta-row .store-badge { align-self: stretch; }
  .desktop-only { display: none; }
  .sticky-bar { display: flex; }
  .dial { width: min(330px, 100%); }
  .hero-phone { border-radius: 26px; padding: 6px; }
  .hero-screen { border-radius: 21px; }
  .stats { padding-bottom: 48px; gap: 12px; }
  .stat { padding: 20px 22px; gap: 16px; border-radius: 24px; }
  .stat-value { font-size: 48px; }
  .stat-label { font-size: 16px; }
  h2 { font-size: 28px; margin-bottom: 20px; }
  .gallery { padding-bottom: 52px; }
  .strip { gap: 16px; --pad: 20px; }
  .shot { width: 210px; }
  .phone { border-radius: 32px; padding: 7px; }
  .phone img { border-radius: 26px; }
  .dot { width: 22px; }
  .dot span { width: 8px; height: 8px; }
  .dot.is-active span { width: 22px; }
  .round-button { width: 44px; height: 44px; }
  .features { padding-bottom: 56px; }
  .feature-grid { grid-template-columns: 1fr; gap: 12px; }
  .feature { display: grid; grid-template-columns: 48px minmax(0, 1fr); column-gap: 14px; row-gap: 4px; padding: 18px 20px; border-radius: 24px; }
  .feature-icon { grid-row: span 2; width: 48px; height: 48px; }
  .feature h3 { font-size: 18px; }
  .feature p { font-size: 15px; }
  .how { padding: 48px 0; }
  .how h2 { margin-bottom: 24px; }
  .steps { grid-template-columns: 1fr; gap: 22px; }
  .step { flex-direction: row; gap: 16px; align-items: flex-start; }
  .step-num { width: 56px; height: 56px; border-width: 6px; font-size: 20px; }
  .step h3 { font-size: 19px; margin-top: 4px; }
  .faq { padding-top: 56px; padding-bottom: 56px; }
  .faq-item { padding: 0 18px; border-radius: 20px; }
  .faq-item summary { font-size: 17px; min-height: 58px; }
  .final-card { padding: 32px 24px; border-radius: 32px; }
  .final-card p { font-size: 17px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero-shot, .hero-phone, .phone, .dot span, .plus::before, .plus::after { transition: none !important; }
}
