/* PETTO's website: the landing page, the legal pages, help, contact and about.
 *
 * Colours are the app's own tokens (src/theme/palette.js), each with a light
 * and a dark value. The page follows the system's appearance; the theme button
 * pins one with data-theme on <html>. Layout uses logical properties
 * (inline-start / inline-end), so the Arabic pages flip by themselves.
 *
 * The look (2026-10-14) follows the apple-design and emil-design-eng skills
 * (.claude/skills): the app's own surfaces (cards, hairlines, pill buttons,
 * inset grouped lists), size-specific tracking, a translucent header, and
 * motion that is short, eased out, origin-aware and off for reduced motion.
 * Everything moves with CSS alone: no script runs any animation. */

/* ---------- Tokens ---------- */

:root {
  color-scheme: light;

  --primary: #af674d;
  --primary-text: #9a5640; /* the brand colour for small text: 5.2:1 on the page (primary is 4.0:1) */
  --primary-soft: #fdf0ed;
  --on-primary: #ffffff; /* text on primary fills */
  --accent-text: #c2703f;
  --accent-tint: #fef3e7;
  --primary-wash: #fde8e0; /* the soft wash behind the hero phones */
  --success-light: #e6f4ea;
  --success-text: #4f7a56;
  --tint: #fdf3ec; /* hovered and pressed rows */

  --background-warm: #fdf5ef; /* the page */
  --background: #fefaf5; /* the footer and quiet bands */
  --card: #ffffff; /* cards and grouped lists */
  --header: rgb(253 245 239 / 0.72); /* the header's material: the page shows through, blurred */

  --text-primary: #1f2937;
  --text-secondary: #6b7280;
  --text-muted: #9ca3af;

  --card-line: #f0e8e0;
  --line: #eae2da;

  --shadow-card: 0 1px 2px rgb(122 74 54 / 0.04), 0 4px 16px rgb(122 74 54 / 0.06);
  --shadow-floating: 0 2px 6px rgb(122 74 54 / 0.06), 0 16px 40px rgb(122 74 54 / 0.16);

  /* Each care type's wash, from src/theme/care-types.ts. */
  --wash-feeding: #f8dbd2;
  --wash-medication: #cae2fa;
  --wash-exercise: #d8ecce;
  --wash-grooming: #ddd0fa;
  --wash-appointment: #fae8b0;
  --wash-custom: #f8d7ca;

  --gutter: 20px;
  --max: 1120px;
  --radius-panel: 36px; /* the big panels behind the screenshots */
  --radius-card: 24px; /* cards and grouped lists */
  --radius-row: 14px;

  /* Motion: strong ease-outs for things that arrive, a drawer curve for things that open. */
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-in-out: cubic-bezier(0.77, 0, 0.175, 1);
  --ease-drawer: cubic-bezier(0.32, 0.72, 0, 1);
  --press: 120ms; /* press feedback */
  --quick: 200ms; /* hovers, menus */
  --enter: 700ms; /* the landing page's one-time entrance */

  /* Figtree for everything, set tight as it grows; Fraunces only for the italic accent word.
     Arabic uses the system's Arabic for text and Noto Naskh Arabic for headings. */
  --font: "Figtree", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-accent: "Fraunces", "Iowan Old Style", Georgia, "Times New Roman", serif;
  --font-arabic: "SF Arabic", "Geeza Pro", "Noto Sans Arabic", "Segoe UI", Tahoma, sans-serif;
  --font-arabic-display: "Noto Naskh Arabic", "SF Arabic", "Geeza Pro", serif;
}

/* Warm "cocoa" darks, as in the app. */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;

    --primary: #bf7558;
    --primary-text: #d4906f;
    --primary-soft: #33241d;
    --accent-text: #f0a46c;
    --accent-tint: #3a2a1c;
    --primary-wash: #3a2620;
    --success-light: #1f2d23;
    --success-text: #8dbb95;
    --tint: #2f221c;

    --background-warm: #13100e;
    --background: #1b1714;
    --card: #221c19;
    --header: rgb(19 16 14 / 0.72);

    --text-primary: #f2ece6;
    --text-secondary: #ada39a;
    --text-muted: #857a72;

    --card-line: #332b26;
    --line: #40362f;

    --shadow-card: 0 1px 2px rgb(0 0 0 / 0.3), 0 4px 16px rgb(0 0 0 / 0.28);
    --shadow-floating: 0 2px 6px rgb(0 0 0 / 0.3), 0 16px 40px rgb(0 0 0 / 0.5);

    --wash-feeding: #513126;
    --wash-medication: #263c51;
    --wash-exercise: #355126;
    --wash-grooming: #342651;
    --wash-appointment: #514726;
    --wash-custom: #513326;
  }
}

:root[data-theme="dark"] {
  color-scheme: dark;

  --primary: #bf7558;
  --primary-text: #d4906f;
  --primary-soft: #33241d;
  --accent-text: #f0a46c;
  --accent-tint: #3a2a1c;
  --primary-wash: #3a2620;
  --success-light: #1f2d23;
  --success-text: #8dbb95;
  --tint: #2f221c;

  --background-warm: #13100e;
  --background: #1b1714;
  --card: #221c19;
  --header: rgb(19 16 14 / 0.72);

  --text-primary: #f2ece6;
  --text-secondary: #ada39a;
  --text-muted: #857a72;

  --card-line: #332b26;
  --line: #40362f;

  --shadow-card: 0 1px 2px rgb(0 0 0 / 0.3), 0 4px 16px rgb(0 0 0 / 0.28);
  --shadow-floating: 0 2px 6px rgb(0 0 0 / 0.3), 0 16px 40px rgb(0 0 0 / 0.5);

  --wash-feeding: #513126;
  --wash-medication: #263c51;
  --wash-exercise: #355126;
  --wash-grooming: #342651;
  --wash-appointment: #514726;
  --wash-custom: #513326;
}

/* ---------- Base ---------- */

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 84px;
  /* Lets a FAQ answer's height animate to "auto". */
  interpolate-size: allow-keywords;
}

body {
  margin: 0;
  background: var(--background-warm);
  color: var(--text-primary);
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  -webkit-tap-highlight-color: transparent;
  overflow-x: hidden;
}

:lang(ar) body,
body:lang(ar) {
  font-family: var(--font-arabic);
  font-size: 18px;
  line-height: 1.8;
}

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

img {
  height: auto;
}

a {
  color: inherit;
}

/* Taps answer at once: no double-tap zoom wait on links and buttons. */
a,
button,
summary {
  touch-action: manipulation;
}

h1,
h2,
h3,
p,
figure {
  margin: 0;
}

/* Headings in the same face as the text, heavier and tighter as they grow. */
h1,
h2,
h3 {
  color: var(--text-primary);
  font-family: var(--font);
  font-weight: 700;
  text-wrap: balance;
}

h1 {
  letter-spacing: -0.035em;
}

h2 {
  letter-spacing: -0.025em;
}

h3 {
  letter-spacing: -0.012em;
}

/* The one accent word, in a soft italic serif, in the brand colour. */
h1 em,
h2 em {
  color: var(--primary);
  font-family: var(--font-accent);
  font-optical-sizing: auto;
  font-style: italic;
  font-weight: 400;
  letter-spacing: -0.02em;
}

/* Arabic letters join: no tracking, its own heading face, and no italics. */
:lang(ar) :is(h1, h2, h3) {
  font-family: var(--font-arabic-display);
  letter-spacing: 0;
}

:lang(ar) :is(h1, h2) em {
  font-family: inherit;
  font-style: normal;
  font-weight: 700;
  letter-spacing: 0;
}

p {
  text-wrap: pretty;
}

::selection {
  background: var(--primary-wash);
  color: var(--text-primary);
}

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

.icon {
  width: 20px;
  height: 20px;
  flex: none;
}

/* Arrows point the way you read. */
[dir="rtl"] .icon--flip {
  transform: scaleX(-1);
}

.container {
  width: 100%;
  max-width: calc(var(--max) + 2 * var(--gutter));
  margin-inline: auto;
  padding-inline: max(var(--gutter), env(safe-area-inset-left)) max(var(--gutter), env(safe-area-inset-right));
}

.skip-link {
  position: absolute;
  inset-inline-start: 16px;
  top: -60px;
  z-index: 100;
  padding: 10px 16px;
  border-radius: 999px;
  background: var(--primary);
  color: var(--on-primary);
  font-weight: 600;
  text-decoration: none;
}

.skip-link:focus {
  top: 12px;
}

/* The mockups' drop shadows run off the bottom of their canvas; fade them
   out below the phones instead of ending on a hard line. */
.shadow-fade {
  -webkit-mask-image: linear-gradient(to bottom, #000 var(--fade-from, 90%), transparent);
  mask-image: linear-gradient(to bottom, #000 var(--fade-from, 90%), transparent);
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

/* ---------- Header: a translucent material over the page ---------- */

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

/* Where the browser ties styles to scrolling, the edge only appears once the page
   slides under the header, instead of a line that's always there. */
@supports (animation-timeline: scroll()) {
  .site-header {
    border-bottom-color: transparent;
    animation: header-edge linear both;
    animation-timeline: scroll(root);
    animation-range: 0 64px;
  }

  @keyframes header-edge {
    to {
      border-bottom-color: var(--line);
    }
  }
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 16px;
  height: 64px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-inline-end: auto;
  border-radius: 10px;
  text-decoration: none;
}

/* The logo changes with the screen (see the <picture> in each page): the icon above
   the wordmark on phones, the icon alone on tablets, the horizontal logo on desktop. */
.brand-logo {
  width: auto;
  height: 46px;
}

.site-footer .brand-logo {
  height: 76px;
}

@media (min-width: 600px) {
  .brand-logo {
    height: 34px;
  }

  .site-footer .brand-logo {
    height: 44px;
  }
}

@media (min-width: 960px) {
  .brand-logo {
    height: 36px;
  }
}

.header-links {
  display: none;
  gap: 2px;
}

/* Links are quiet pills: a soft fill under the pointer, the brand colour on the current page. */
.header-links a {
  padding: 7px 12px;
  border-radius: 999px;
  color: var(--text-secondary);
  font-size: 15px;
  font-weight: 500;
  letter-spacing: -0.005em;
  text-decoration: none;
  transition: color var(--quick) ease, background-color var(--quick) ease;
}

.header-links a[aria-current="page"] {
  color: var(--primary-text);
  background: var(--primary-soft);
}

@media (hover: hover) and (pointer: fine) {
  .header-links a:hover {
    color: var(--text-primary);
    background: var(--tint);
  }

  .header-links a[aria-current="page"]:hover {
    color: var(--primary-text);
    background: var(--primary-soft);
  }
}

/* Round header controls: the language, the theme and the phone menu. */
.lang-menu summary,
.nav-menu summary,
.theme-toggle {
  border: 1px solid var(--line);
  background: var(--card);
  color: var(--text-primary);
  cursor: pointer;
  transition: transform var(--press) var(--ease-out), background-color var(--quick) ease;
}

.lang-menu summary:active,
.nav-menu summary:active,
.theme-toggle:active {
  transform: scale(0.95);
}

@media (hover: hover) and (pointer: fine) {
  .lang-menu summary:hover,
  .nav-menu summary:hover,
  .theme-toggle:hover {
    background: var(--tint);
  }
}

/* On phones the header links move into a menu: a native <details>, like the
   language menu, so it works without JavaScript. */
.nav-menu {
  position: relative;
}

.nav-menu summary {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 999px;
  list-style: none;
}

.nav-menu summary::-webkit-details-marker,
.lang-menu summary::-webkit-details-marker {
  display: none;
}

.nav-menu .icon {
  width: 20px;
  height: 20px;
}

.nav-menu .icon-close,
.nav-menu[open] .icon-menu {
  display: none;
}

.nav-menu[open] .icon-close {
  display: block;
}

/* Both menus are popovers: they grow out of their button's corner, quickly, eased out. */
.nav-menu ul,
.lang-menu ul {
  position: absolute;
  inset-inline-end: 0;
  top: calc(100% + 8px);
  z-index: 60;
  margin: 0;
  padding: 6px;
  list-style: none;
  border: 1px solid var(--card-line);
  border-radius: 18px;
  background: var(--card);
  box-shadow: var(--shadow-floating);
  transform-origin: top right;
  transition: opacity var(--quick) var(--ease-out), transform var(--quick) var(--ease-out);
}

[dir="rtl"] :is(.nav-menu, .lang-menu) ul {
  transform-origin: top left;
}

@starting-style {
  :is(.nav-menu, .lang-menu)[open] ul {
    opacity: 0;
    transform: scale(0.96) translateY(-4px);
  }
}

.nav-menu ul {
  width: min(264px, calc(100vw - 2 * var(--gutter)));
}

.nav-menu ul a,
.lang-menu ul a {
  display: flex;
  align-items: center;
  gap: 10px;
  border-radius: 12px;
  color: var(--text-primary);
  text-decoration: none;
  transition: background-color var(--quick) ease;
}

.nav-menu ul a {
  padding: 12px;
  font-size: 16px;
  font-weight: 500;
}

.nav-menu ul a:active,
.lang-menu ul a:active {
  background: var(--tint);
}

@media (hover: hover) and (pointer: fine) {
  .nav-menu ul a:hover,
  .lang-menu ul a:hover {
    background: var(--tint);
  }
}

/* A dot marks the page you're on, and the language you're reading. */
.nav-menu ul a[aria-current="page"] {
  color: var(--primary-text);
  font-weight: 650;
}

.nav-menu ul a[aria-current="page"]::after,
.lang-menu ul a[aria-current="true"]::after {
  content: "";
  width: 7px;
  height: 7px;
  margin-inline-start: auto;
  border-radius: 999px;
  background: var(--primary);
}

@media (min-width: 720px) {
  .nav-menu {
    display: none;
  }
}

/* Six links don't fit on tablets; Terms stays in the footer there. */
@media (max-width: 959px) {
  .header-links .header-link--wide {
    display: none;
  }
}

/* The language menu: a native <details>, so it works without JavaScript. */
.lang-menu {
  position: relative;
}

.lang-menu summary {
  display: flex;
  align-items: center;
  gap: 8px;
  height: 40px;
  padding: 0 12px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 500;
  line-height: 1.2;
  list-style: none;
}

.lang-menu summary .icon {
  width: 14px;
  height: 14px;
  color: var(--text-muted);
  transition: transform var(--quick) var(--ease-out);
}

.lang-menu[open] summary .icon {
  transform: rotate(180deg);
}

.lang-menu .lang-short {
  display: none;
}

.lang-menu ul {
  min-width: 196px;
}

.lang-menu ul a {
  padding: 10px;
  font-size: 15px;
}

.lang-menu ul a[aria-current="true"] {
  font-weight: 600;
}

[lang="ar"].lang-name,
.lang-menu a[lang="ar"],
.footer-langs a[lang="ar"] {
  font-family: var(--font-arabic);
}

.flag {
  width: 22px;
  height: 16.5px;
  flex: none;
  border-radius: 3px;
  object-fit: cover;
  box-shadow: 0 0 0 1px var(--line);
}

.theme-toggle {
  display: inline-grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 999px;
  color: var(--text-secondary);
}

.theme-toggle .icon {
  width: 19px;
  height: 19px;
}

/* Shows the moon in light mode and the sun in dark mode. */
.theme-toggle .icon-sun,
:root[data-theme="dark"] .theme-toggle .icon-moon {
  display: none;
}

:root[data-theme="dark"] .theme-toggle .icon-sun {
  display: block;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .theme-toggle .icon-sun {
    display: block;
  }

  :root:not([data-theme="light"]) .theme-toggle .icon-moon {
    display: none;
  }
}

/* The theme changes with a short cross-fade (the button's script uses a view transition),
   not a sudden jump in brightness. */
::view-transition-old(root),
::view-transition-new(root) {
  animation-duration: 260ms;
  animation-timing-function: ease;
}

/* ---------- Buttons and badges ---------- */

.badges {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.badges a {
  display: block;
  border-radius: 10px;
  transition: transform var(--press) var(--ease-out), opacity var(--quick) ease;
}

.badges img {
  width: auto;
  height: 48px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  margin-top: 20px;
  padding: 12px 24px;
  border-radius: 999px;
  background: var(--primary);
  color: var(--on-primary);
  font-weight: 600;
  letter-spacing: -0.005em;
  text-decoration: none;
  user-select: none;
  -webkit-user-select: none;
  transition: transform var(--press) var(--ease-out), background-color var(--quick) ease;
}

.button .icon {
  width: 18px;
  height: 18px;
}

/* Everything you can press answers on the press itself. */
.button:active,
.badges a:active {
  transform: scale(0.97);
}

@media (hover: hover) and (pointer: fine) {
  .button:hover {
    background: color-mix(in srgb, var(--primary) 88%, var(--text-primary));
  }

  .badges a:hover {
    opacity: 0.86;
  }
}

/* ---------- Labels ---------- */

/* A small label above a heading: an icon in a soft circle, then a few words, in sentence case. */
.label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--primary-text);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: -0.005em;
}

.label-icon {
  display: inline-grid;
  place-items: center;
  flex: none;
  width: 28px;
  height: 28px;
  border-radius: 999px;
  background: var(--primary-soft);
  color: var(--primary-text);
}

.label-icon .icon {
  width: 15px;
  height: 15px;
}

:lang(ar) .label {
  font-size: 16px;
  letter-spacing: 0;
}

/* ---------- Home: hero ---------- */

.hero {
  position: relative;
  isolation: isolate;
  display: grid;
  gap: 40px;
  align-items: center;
  padding-block: 40px 32px;
}

.hero h1 {
  margin-top: 18px;
  font-size: clamp(42px, 6.4vw, 80px);
  line-height: 1.02;
  letter-spacing: -0.045em;
}

:lang(fr) .hero h1 {
  font-size: clamp(38px, 5.4vw, 68px);
}

:lang(ar) .hero h1 {
  font-size: clamp(38px, 5.4vw, 66px);
  line-height: 1.35;
}

.lead {
  max-width: 32rem;
  margin-top: 20px;
  color: var(--text-secondary);
  font-size: 19px;
  line-height: 1.5;
  letter-spacing: -0.01em;
}

:lang(ar) .lead {
  letter-spacing: 0;
}

.hero .badges {
  margin-top: 32px;
}

.pet-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 28px;
  color: var(--text-secondary);
  font-size: 15px;
}

.pet-avatars {
  display: flex;
  flex: none;
}

.pet-avatars img {
  width: 40px;
  height: 40px;
  border: 2.5px solid var(--background-warm);
  border-radius: 999px;
  background: var(--card);
}

.pet-avatars img + img {
  margin-inline-start: -10px;
}

/* The phones on a soft wash, with two task cards pinned beside them. */
.hero-visual {
  position: relative;
  width: 100%;
  max-width: 560px;
  margin-inline: auto;
}

.hero-visual::before {
  content: "";
  position: absolute;
  inset: 8% 6% 4%;
  z-index: -1;
  border-radius: 48px;
  background: var(--primary-wash);
}

.float-card {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px 10px 10px;
  border: 1px solid var(--card-line);
  border-radius: 18px;
  background: color-mix(in srgb, var(--card) 88%, transparent);
  -webkit-backdrop-filter: saturate(180%) blur(16px);
  backdrop-filter: saturate(180%) blur(16px);
  box-shadow: var(--shadow-floating);
  font-size: 13px;
  line-height: 1.3;
}

[dir="rtl"] .float-card {
  padding: 10px 10px 10px 14px;
}

.float-card strong {
  display: block;
  font-size: 14px;
  font-weight: 650;
  letter-spacing: -0.01em;
}

.float-card small {
  display: block;
  color: var(--text-secondary);
  font-size: 12.5px;
}

.float-card .care-tile {
  width: 40px;
  height: 40px;
  border-radius: 12px;
}

.float-card--done {
  inset-inline-start: -2%;
  bottom: 16%;
}

.float-card--reminder {
  inset-inline-end: 0;
  top: 8%;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 9px 3px 7px;
  border-radius: 999px;
  background: var(--success-light);
  color: var(--success-text);
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
}

.chip .icon {
  width: 13px;
  height: 13px;
}

@media (max-width: 520px) {
  .float-card {
    gap: 8px;
    padding: 8px 10px 8px 8px;
  }

  [dir="rtl"] .float-card {
    padding: 8px 8px 8px 10px;
  }

  .float-card .care-tile {
    width: 34px;
    height: 34px;
    border-radius: 10px;
  }

  .float-card strong {
    font-size: 13px;
  }

  .float-card small {
    font-size: 11.5px;
  }

  .float-card--done {
    inset-inline-start: 0;
    bottom: 10%;
  }

  .float-card--reminder {
    top: 2%;
  }

  .pet-row span {
    text-align: start;
  }
}

/* ---------- Sections ---------- */

.section {
  padding-block: 40px;
}

.section h2 {
  margin-top: 14px;
  font-size: clamp(32px, 4.4vw, 52px);
  line-height: 1.06;
  letter-spacing: -0.035em;
}

.section h2:first-child {
  margin-top: 0;
}

:lang(ar) .section h2 {
  line-height: 1.4;
}

.section-intro {
  max-width: 40rem;
}

.section-intro p {
  margin-top: 14px;
  color: var(--text-secondary);
  font-size: 18.5px;
  line-height: 1.5;
}

.section-intro p + p {
  margin-top: 12px;
}

/* Links in running text: a fine underline that thickens under the pointer. */
:is(.doc, .faq-answer, .features, .contact-ways, .team-bio, .split, .plans-note) a {
  color: var(--primary-text);
  font-weight: 600;
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
  transition: text-decoration-thickness var(--quick) ease;
}

@media (hover: hover) and (pointer: fine) {
  :is(.doc, .faq-answer, .features, .contact-ways, .team-bio, .split, .plans-note) a:hover {
    text-decoration-thickness: 2px;
  }
}

/* The three photos, each with its icon on the corner. */
.trio {
  display: grid;
  gap: 40px;
  margin: 44px 0 0;
  padding: 0;
  list-style: none;
}

.trio-photo {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-card);
  background: var(--card-line);
}

.trio-photo img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  transition: scale 600ms var(--ease-out);
}

@media (hover: hover) and (pointer: fine) {
  .trio li:hover .trio-photo img {
    scale: 1.03;
  }
}

.trio-photo .label-icon {
  position: absolute;
  inset-inline-start: 14px;
  bottom: 14px;
  width: 44px;
  height: 44px;
  background: color-mix(in srgb, var(--card) 86%, transparent);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  box-shadow: var(--shadow-card);
}

.trio-photo .label-icon .icon {
  width: 21px;
  height: 21px;
}

.trio h3 {
  margin-top: 20px;
  font-size: 21px;
  line-height: 1.25;
  font-weight: 650;
}

.trio p {
  margin-top: 6px;
  color: var(--text-secondary);
  font-size: 16px;
}

:lang(ar) .trio p {
  font-size: 17px;
}

/* Every kind of care: the app's own illustrations on their washes, as cards. */
.care-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin: 40px 0 0;
  padding: 0;
  list-style: none;
}

.care-grid li {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 22px 10px 18px;
  border: 1px solid var(--card-line);
  border-radius: var(--radius-card);
  background: var(--card);
  box-shadow: var(--shadow-card);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: -0.01em;
  text-align: center;
}

:lang(ar) .care-grid li {
  letter-spacing: 0;
}

.care-tile {
  display: grid;
  place-items: center;
  flex: none;
  width: 72px;
  height: 72px;
  border-radius: 22px;
}

.care-tile img {
  width: 72%;
  height: 72%;
  object-fit: contain;
}

.care-grid .care-tile {
  border-radius: 999px;
  transition: transform 400ms var(--ease-out);
}

@media (hover: hover) and (pointer: fine) {
  .care-grid li:hover .care-tile {
    transform: translateY(-3px) rotate(-6deg);
  }
}

.care-tile--feeding { background: var(--wash-feeding); }
.care-tile--medication { background: var(--wash-medication); }
.care-tile--exercise { background: var(--wash-exercise); }
.care-tile--grooming { background: var(--wash-grooming); }
.care-tile--appointment { background: var(--wash-appointment); }
.care-tile--custom { background: var(--wash-custom); }

/* Feature rows: words on one side, the app on a washed panel on the other. */
.split {
  display: grid;
  gap: 32px;
  align-items: center;
}

.split p {
  margin-top: 14px;
  color: var(--text-secondary);
  font-size: 18px;
  line-height: 1.55;
}

/* A margin note: a fine rule in the brand colour beside quieter words. */
.split .note {
  margin-top: 20px;
  padding-inline-start: 14px;
  border-inline-start: 2px solid var(--primary);
  color: var(--text-secondary);
  font-size: 15.5px;
  line-height: 1.5;
}

.split + .split,
.split + .bento {
  margin-top: 80px;
}

.panel {
  position: relative;
  overflow: hidden;
  display: grid;
  place-items: center;
  padding: 44px 20px 4px;
  border-radius: var(--radius-panel);
  background: var(--panel-wash);
}

.panel img {
  position: relative;
  width: 100%;
  max-width: 520px;
}

.panel--pet {
  --panel-wash: var(--wash-feeding);
}

.panel--routine {
  --panel-wash: var(--wash-medication);
}

.panel--assistant {
  --panel-wash: var(--wash-grooming);
}

.panel--health {
  --panel-wash: var(--wash-appointment);
  padding: 72px 16px 56px;
}

/* The app's own illustration, standing in for a screen. */
.panel--health img {
  max-width: 300px;
}

/* The widget's phone runs off the panel's bottom edge. */
.panel--widget {
  --panel-wash: var(--wash-exercise);
  align-items: end;
  padding: 64px 36px 0;
}

.panel--widget img {
  max-width: 500px;
}

.panel--plus {
  --panel-wash: var(--wash-custom);
}

/* Two cards whose phones run off their edges. */
.bento {
  display: grid;
  gap: 20px;
}

.bento-card {
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  border-radius: var(--radius-panel);
  background: var(--panel-wash);
}

.bento-card--reminders {
  --panel-wash: var(--wash-appointment);
}

.bento-card--pets {
  --panel-wash: var(--wash-exercise);
}

.bento-copy {
  position: relative;
  padding: 32px 28px 8px;
}

.bento-card--pets .bento-copy {
  padding: 8px 28px 32px;
}

.bento-copy h3 {
  margin-top: 14px;
  font-size: 28px;
  line-height: 1.12;
  letter-spacing: -0.025em;
}

:lang(ar) .bento-copy h3 {
  line-height: 1.45;
  letter-spacing: 0;
}

.bento-copy p {
  margin-top: 10px;
  color: var(--text-secondary);
  font-size: 16.5px;
}

.bento-card img {
  position: relative;
  width: 100%;
  max-width: 580px;
  margin-inline: auto;
}

.bento-card--reminders img {
  margin-top: auto;
}

/* ---------- PETTO Plus: the free plan beside Plus ---------- */

.plans {
  width: 100%;
  margin-top: 24px;
  border-collapse: separate;
  border-spacing: 0;
  overflow: hidden;
  border: 1px solid var(--card-line);
  border-radius: var(--radius-card);
  background: var(--card);
  box-shadow: var(--shadow-card);
  font-size: 15.5px;
}

.plans th,
.plans td {
  padding: 13px 16px;
  border-bottom: 1px solid var(--line);
  text-align: start;
  vertical-align: middle;
}

.plans tbody tr:last-child :is(th, td) {
  border-bottom: 0;
}

.plans thead th {
  color: var(--text-muted);
  font-size: 13.5px;
  font-weight: 600;
}

.plans tbody th {
  color: var(--text-primary);
  font-weight: 500;
}

/* The numbers take only the room they need, so the row names stay on one line. */
.plans td {
  width: 1%;
  min-width: 76px;
  color: var(--text-secondary);
  font-variant-numeric: tabular-nums;
  text-align: center;
  white-space: nowrap;
}

/* The Plus column sits on the brand's soft wash. */
.plans :is(td, th):last-child {
  background: var(--primary-soft);
  color: var(--primary-text);
  font-weight: 650;
}

.plans thead th:last-child {
  color: var(--primary-text);
  font-weight: 700;
}

.plans-note {
  margin-top: 16px;
  color: var(--text-muted) !important;
  font-size: 15px !important;
}

/* ---------- Made for your everyday ---------- */

.everyday {
  display: grid;
  gap: 40px;
  align-items: center;
}

.everyday-art {
  position: relative;
  isolation: isolate;
  width: 100%;
  max-width: 440px;
  margin-inline: auto;
}

.everyday-art::before {
  content: "";
  position: absolute;
  inset: 8%;
  z-index: -1;
  border-radius: 50%;
  background: var(--wash-grooming);
}

/* A ruled index of small features: an icon, a title and a line, no boxes. */
.features {
  display: grid;
  gap: 0 40px;
  margin: 32px 0 0;
  padding: 0;
  list-style: none;
}

.features li {
  padding-block: 20px 24px;
  border-top: 1px solid var(--line);
}

.features .label-icon {
  width: 36px;
  height: 36px;
  border-radius: 12px;
}

.features .label-icon .icon {
  width: 19px;
  height: 19px;
}

.features h3 {
  margin-top: 12px;
  font-size: 18px;
  line-height: 1.3;
  font-weight: 650;
}

.features p {
  margin-top: 6px;
  color: var(--text-secondary);
  font-size: 15.5px;
}

:lang(ar) .features p {
  font-size: 16.5px;
}

.flags {
  display: flex;
  gap: 8px;
  margin-top: 12px;
}

/* ---------- The closing card: words and badges on the brand colour, beside a photo ---------- */

.cta-card {
  position: relative;
  overflow: hidden;
  display: grid;
  border-radius: var(--radius-panel);
  background: var(--primary);
  color: var(--on-primary);
}

.cta-copy {
  position: relative;
  padding: 44px 28px;
}

.cta-copy h2 {
  margin-top: 0;
  color: var(--on-primary);
  font-size: clamp(38px, 5vw, 60px);
  line-height: 1.02;
  letter-spacing: -0.04em;
}

:lang(ar) .cta-copy h2 {
  line-height: 1.35;
  letter-spacing: 0;
}

.cta-copy p {
  margin-top: 12px;
  font-size: 18px;
  opacity: 0.92;
}

.cta-copy .badges {
  margin-top: 28px;
}

.cta-logo {
  width: 64px;
  height: 64px;
  margin-bottom: 24px;
  border-radius: 18px;
  box-shadow: 0 0 0 5px color-mix(in srgb, var(--on-primary) 16%, transparent);
}

.cta-paw {
  position: absolute;
  inset-inline-end: 24px;
  bottom: -24px;
  width: 140px;
  height: 140px;
  color: var(--on-primary);
  opacity: 0.08;
  transform: rotate(-16deg);
}

.cta-card > img {
  width: 100%;
  height: 100%;
  min-height: 260px;
  object-fit: cover;
}

/* ---------- Footer ---------- */

.site-footer {
  margin-top: 48px;
  padding-block: 48px max(40px, env(safe-area-inset-bottom));
  background: var(--background);
  border-top: 1px solid var(--line);
  color: var(--text-secondary);
  font-size: 15px;
}

.footer-top {
  display: grid;
  gap: 28px;
}

/* The tagline under the logo, set large like a sign-off. */
.footer-top > div > p {
  max-width: 20ch;
  margin-top: 16px;
  color: var(--text-primary);
  font-size: 24px;
  font-weight: 650;
  line-height: 1.2;
  letter-spacing: -0.025em;
}

:lang(ar) .footer-top > div > p {
  font-family: var(--font-arabic-display);
  line-height: 1.5;
  letter-spacing: 0;
}

.footer-links,
.footer-langs {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 24px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.footer-links a,
.footer-langs a {
  text-decoration: none;
  transition: color var(--quick) ease;
}

.footer-langs a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.footer-links a[aria-current],
.footer-langs a[aria-current] {
  color: var(--text-primary);
}

@media (hover: hover) and (pointer: fine) {
  .footer-links a:hover,
  .footer-langs a:hover {
    color: var(--text-primary);
  }
}

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px 24px;
  margin-top: 36px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
  color: var(--text-muted);
  font-size: 13.5px;
}

:lang(ar) .footer-bottom {
  font-size: 14.5px;
}

/* ---------- Legal pages ---------- */

.doc-head {
  max-width: 52rem;
  padding-block: 56px 32px;
}

/* Page titles: large and tight, like the hero. */
:is(.doc-head, .about-hero, .not-found) h1 {
  font-size: clamp(40px, 6vw, 72px);
  line-height: 1.02;
  letter-spacing: -0.045em;
}

:lang(ar) :is(.doc-head, .about-hero, .not-found) h1 {
  line-height: 1.35;
  letter-spacing: 0;
}

.doc-meta {
  margin-top: 16px;
  color: var(--text-muted);
  font-size: 15px;
}

.doc-note {
  margin-top: 20px;
  padding: 14px 16px;
  border-radius: var(--radius-row);
  background: var(--accent-tint);
  color: var(--text-primary);
  font-size: 15px;
}

.doc-grid {
  display: grid;
  gap: 32px;
  align-items: start;
  padding-bottom: 48px;
}

.toc {
  display: none;
  font-size: 14.5px;
}

/* On phones the contents fold away above the text, in a grouped card. */
.toc-mobile {
  overflow: hidden;
  border: 1px solid var(--card-line);
  border-radius: var(--radius-card);
  background: var(--card);
  font-size: 15px;
}

.toc-mobile summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  color: var(--text-primary);
  font-weight: 600;
  list-style: none;
  cursor: pointer;
}

.toc-mobile summary::-webkit-details-marker {
  display: none;
}

/* A chevron drawn with borders, so no markup changes: it turns as the list opens. */
.toc-mobile summary::after {
  content: "";
  width: 8px;
  height: 8px;
  margin-inline-end: 4px;
  border-right: 2px solid var(--text-muted);
  border-bottom: 2px solid var(--text-muted);
  transform: translateY(-2px) rotate(45deg);
  transition: transform var(--quick) var(--ease-out);
}

.toc-mobile[open] summary::after {
  transform: translateY(2px) rotate(225deg);
}

.toc-mobile ol {
  margin: 0;
  padding: 4px 8px 10px;
  border-top: 1px solid var(--line);
  list-style: none;
}

.toc-mobile a {
  display: block;
  padding: 8px 10px;
  border-radius: 10px;
  color: var(--text-secondary);
  text-decoration: none;
}

.toc-mobile a:active {
  background: var(--tint);
}

.toc h2 {
  color: var(--text-muted);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0;
}

:lang(ar) .toc h2 {
  font-family: var(--font-arabic);
  font-size: 14px;
}

.toc ol {
  display: grid;
  gap: 2px;
  margin: 12px 0 0;
  padding: 0;
  list-style: none;
}

.toc a {
  display: block;
  padding: 6px 12px;
  border-radius: 10px;
  color: var(--text-secondary);
  line-height: 1.4;
  text-decoration: none;
  transition: color var(--quick) ease, background-color var(--quick) ease;
}

/* Rows answer the press, as in the app's lists. */
.toc a:active {
  background: var(--tint);
}

@media (hover: hover) and (pointer: fine) {
  .toc a:hover {
    color: var(--text-primary);
    background: var(--tint);
  }
}

.doc {
  max-width: 46rem;
}

.doc section + section {
  margin-top: 44px;
  padding-top: 36px;
  border-top: 1px solid var(--line);
}

/* A section reached from the contents flashes softly, so you see where you landed. */
.doc section:target h2 {
  animation: landed 1.4s var(--ease-out);
}

@keyframes landed {
  from {
    color: var(--primary-text);
  }
}

.doc h2 {
  font-size: 26px;
  line-height: 1.2;
  letter-spacing: -0.025em;
}

.doc h3 {
  margin-top: 28px;
  font-size: 18.5px;
  font-weight: 650;
}

.doc p,
.doc li {
  color: var(--text-secondary);
  font-size: 16.5px;
  line-height: 1.7;
}

:lang(ar) .doc :is(p, li) {
  font-size: 17.5px;
  line-height: 1.85;
}

:lang(ar) .doc :is(h2, h3) {
  line-height: 1.5;
}

.doc p {
  margin-top: 12px;
}

.doc ul {
  margin: 12px 0 0;
  padding-inline-start: 22px;
}

.doc li + li {
  margin-top: 8px;
}

.doc li::marker {
  color: var(--text-muted);
}

.doc strong {
  color: var(--text-primary);
  font-weight: 600;
}

/* What's still to be filled in before launch. */
mark.fill {
  padding: 1px 2px;
  border-radius: 4px;
  background: var(--accent-tint);
  color: var(--accent-text);
}

mark.fill mark.fill {
  padding: 0;
  background: transparent;
}

/* ---------- Help and contact ---------- */

.doc-lead {
  max-width: 38rem;
  margin-top: 16px;
  color: var(--text-secondary);
  font-size: 19px;
  line-height: 1.5;
}

.help-grid {
  display: grid;
  gap: 40px;
  align-items: start;
  padding-bottom: 64px;
}

.help-h2 {
  margin-bottom: 8px;
  font-size: 30px;
  line-height: 1.15;
  letter-spacing: -0.03em;
}

:lang(ar) .help-h2 {
  line-height: 1.5;
  letter-spacing: 0;
}

/* Topics read like a settings screen: a quiet heading over an inset grouped list. */
.faq-group {
  margin: 36px 0 10px;
  padding-inline: 18px;
  color: var(--text-secondary);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: -0.005em;
}

:lang(ar) .faq-group {
  font-family: var(--font-arabic);
  font-size: 16px;
  letter-spacing: 0;
}

.help-h2 + .faq-group {
  margin-top: 16px;
}

/* Questions fold open with <details>, so they work without JavaScript. */
.faq {
  overflow: hidden;
  border: 1px solid var(--card-line);
  border-radius: var(--radius-card);
  background: var(--card);
  box-shadow: var(--shadow-card);
}

.faq-item + .faq-item {
  border-top: 1px solid var(--line);
}

.faq-item summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 17px 18px;
  color: var(--text-primary);
  font-size: 17px;
  font-weight: 600;
  letter-spacing: -0.012em;
  line-height: 1.4;
  list-style: none;
  cursor: pointer;
  transition: background-color var(--quick) ease;
}

:lang(ar) .faq-item summary {
  letter-spacing: 0;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary:active {
  background: var(--tint);
}

@media (hover: hover) and (pointer: fine) {
  .faq-item summary:hover {
    background: var(--tint);
  }
}

.faq-item summary .icon {
  width: 18px;
  height: 18px;
  color: var(--text-muted);
  transition: transform 300ms var(--ease-out), color var(--quick) ease;
}

.faq-item[open] summary .icon {
  color: var(--primary-text);
  transform: rotate(180deg);
}

/* Where the browser allows it, an answer slides open to its height instead of appearing at once. */
.faq-item::details-content {
  block-size: 0;
  overflow: hidden;
  transition: block-size 300ms var(--ease-drawer), content-visibility 300ms allow-discrete;
}

.faq-item[open]::details-content {
  block-size: auto;
}

.faq-answer {
  padding: 0 18px 20px;
}

.faq-answer p {
  max-width: 44rem;
  color: var(--text-secondary);
  font-size: 16px;
  line-height: 1.65;
}

:lang(ar) .faq-answer p {
  font-size: 17px;
  line-height: 1.85;
}

.faq-answer strong {
  color: var(--text-primary);
  font-weight: 600;
}

.contact-card {
  padding: 28px;
  border: 1px solid var(--card-line);
  border-radius: var(--radius-card);
  background: var(--card);
  box-shadow: var(--shadow-card);
}

.contact-card .label-icon,
.contact-ways .label-icon {
  width: 44px;
  height: 44px;
  border-radius: 14px;
}

.contact-card .label-icon .icon,
.contact-ways .label-icon .icon {
  width: 22px;
  height: 22px;
}

.contact-card h2 {
  margin-top: 16px;
  font-size: 24px;
  line-height: 1.2;
}

.contact-card > p {
  margin-top: 8px;
  color: var(--text-secondary);
}

.contact-card .contact-email {
  margin-top: 10px;
  color: var(--text-muted);
  font-size: 14.5px;
  word-break: break-all;
}

.contact-inapp {
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}

.contact-inapp h3 {
  font-size: 16.5px;
  font-weight: 650;
}

.contact-inapp p {
  margin-top: 6px;
  color: var(--text-secondary);
  font-size: 15.5px;
}

@media (min-width: 960px) {
  .help-grid {
    grid-template-columns: 1fr 340px;
    gap: 64px;
  }

  .contact-card:not(.contact-write) {
    position: sticky;
    top: 88px;
  }
}

/* ---------- Contact ---------- */

.contact-page {
  display: grid;
  gap: 40px;
  align-items: start;
  padding-bottom: 64px;
}

.contact-main {
  display: grid;
  gap: 48px;
}

/* The ways to reach us, as one grouped list. */
.contact-ways {
  display: grid;
  margin: 8px 0 0;
  padding: 0;
  overflow: hidden;
  border: 1px solid var(--card-line);
  border-radius: var(--radius-card);
  background: var(--card);
  box-shadow: var(--shadow-card);
  list-style: none;
}

.contact-ways li {
  display: flex;
  gap: 16px;
  padding: 20px 18px;
}

.contact-ways li + li {
  border-top: 1px solid var(--line);
}

.contact-ways h3 {
  font-size: 17.5px;
  line-height: 1.35;
  font-weight: 650;
}

.contact-ways p,
.contact-tips > p:not(.doc-note) {
  margin-top: 6px;
  color: var(--text-secondary);
  font-size: 16px;
  line-height: 1.6;
}

:lang(ar) .contact-ways p,
:lang(ar) .contact-tips > p:not(.doc-note) {
  font-size: 17px;
  line-height: 1.85;
}

.contact-ways strong {
  color: var(--text-primary);
  font-weight: 600;
}

.contact-links {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 20px;
}

/* The robot on a soft wash, as on the landing page. */
.contact-art {
  position: relative;
  isolation: isolate;
  width: 100%;
  max-width: 320px;
  margin-inline: auto;
}

.contact-art::before {
  content: "";
  position: absolute;
  inset: 8%;
  z-index: -1;
  border-radius: 50%;
  background: var(--wash-grooming);
}

@media (min-width: 960px) {
  .contact-page {
    grid-template-columns: 1fr 400px;
    gap: 64px;
  }

  .contact-art {
    position: sticky;
    top: 88px;
    max-width: none;
  }
}

/* ---------- About ---------- */

.about-hero {
  padding-block: 48px 8px;
}

.about-hero h1 {
  margin-top: 16px;
}

.about-hero .lead {
  margin-top: 18px;
}

.about-photo {
  overflow: hidden;
  border-radius: var(--radius-panel);
}

/* A few plain facts about the app, in a row of quiet cards. */
.about-facts {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  margin: 36px 0 0;
  padding: 0;
  list-style: none;
}

.about-facts li {
  padding: 22px 20px;
  border: 1px solid var(--card-line);
  border-radius: var(--radius-card);
  background: var(--card);
  box-shadow: var(--shadow-card);
}

.about-facts strong {
  display: block;
  color: var(--primary-text);
  font-size: 40px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  line-height: 1.05;
  letter-spacing: -0.04em;
}

:lang(ar) .about-facts strong {
  letter-spacing: 0;
}

.about-facts span {
  display: block;
  margin-top: 6px;
  color: var(--text-secondary);
  font-size: 15px;
  line-height: 1.45;
}

/* The person behind PETTO: photo, words, and every way to reach them. */
.team-card {
  display: grid;
  gap: 28px;
  margin-top: 36px;
  padding: 28px;
  border: 1px solid var(--card-line);
  border-radius: var(--radius-panel);
  background: var(--card);
  box-shadow: var(--shadow-card);
}

.team-photo {
  width: 168px;
  height: 168px;
  border-radius: 999px;
  background: var(--primary-soft);
  object-fit: cover;
}

.team-card h3 {
  font-size: 30px;
  line-height: 1.15;
  letter-spacing: -0.03em;
}

.team-role {
  margin-top: 4px;
  color: var(--primary-text);
  font-weight: 600;
}

.team-place {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 6px;
  color: var(--text-muted);
  font-size: 15px;
}

.team-place .icon {
  width: 16px;
  height: 16px;
}

.team-bio {
  margin-top: 16px;
  color: var(--text-secondary);
}

.team-bio + .team-bio {
  margin-top: 10px;
}

.team-links {
  display: grid;
  gap: 10px;
  margin: 24px 0 0;
  padding: 0;
  list-style: none;
}

.team-links a {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border: 1px solid var(--card-line);
  border-radius: 18px;
  background: var(--background);
  text-decoration: none;
  transition: transform var(--press) var(--ease-out), border-color var(--quick) ease;
}

.team-links a:active {
  transform: scale(0.98);
}

@media (hover: hover) and (pointer: fine) {
  .team-links a:hover {
    border-color: var(--primary);
  }
}

.team-links .label-icon {
  width: 40px;
  height: 40px;
  border-radius: 12px;
}

.team-links .label-icon .icon {
  width: 20px;
  height: 20px;
}

.team-links small {
  display: block;
  color: var(--text-muted);
  font-size: 13px;
  line-height: 1.3;
}

.team-links span span {
  display: block;
  color: var(--text-primary);
  font-size: 15.5px;
  font-weight: 600;
  line-height: 1.4;
  overflow-wrap: anywhere;
}

/* ---------- 404 ---------- */

.not-found {
  max-width: 36rem;
  padding-block: 96px 64px;
}

.not-found p {
  margin-top: 16px;
  color: var(--text-secondary);
  font-size: 19px;
}

.not-found a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 28px;
  padding: 12px 22px;
  border-radius: 999px;
  background: var(--primary);
  color: var(--on-primary);
  font-weight: 600;
  text-decoration: none;
  transition: transform var(--press) var(--ease-out);
}

.not-found a:active {
  transform: scale(0.97);
}

.not-found a .icon {
  width: 18px;
  height: 18px;
}

/* ---------- Larger screens ---------- */

@media (min-width: 600px) {
  .team-links {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 720px) {
  :root {
    --gutter: 32px;
  }

  .header-links {
    display: flex;
  }

  .trio {
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
  }

  .trio-photo img {
    aspect-ratio: 4 / 5;
  }

  .care-grid {
    grid-template-columns: repeat(6, 1fr);
  }

  .features {
    grid-template-columns: repeat(2, 1fr);
  }

  .footer-top {
    grid-template-columns: 1.4fr 1fr 1fr;
    align-items: start;
  }

  .about-facts {
    grid-template-columns: repeat(4, 1fr);
  }

  .team-card {
    grid-template-columns: auto 1fr;
    gap: 40px;
    padding: 40px;
  }

  .team-photo {
    width: 200px;
    height: 200px;
  }
}

@media (min-width: 960px) {
  .section {
    padding-block: 72px;
  }

  .hero {
    grid-template-columns: 1.05fr 1fr;
    gap: 56px;
    padding-block: 80px 64px;
  }

  .split {
    grid-template-columns: 1fr 1.1fr;
    gap: 72px;
  }

  /* Every other row puts its picture first. */
  .split--reverse > :first-child {
    order: 2;
  }

  .split + .split,
  .split + .bento {
    margin-top: 120px;
  }

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

  .everyday {
    grid-template-columns: 0.85fr 1.15fr;
    gap: 64px;
  }

  .cta-card {
    grid-template-columns: 1.05fr 1fr;
  }

  .cta-copy {
    padding: 64px 56px;
  }

  .about-hero {
    padding-block: 72px 16px;
  }

  .doc-head {
    padding-block: 72px 40px;
  }

  .doc-grid {
    grid-template-columns: 220px 1fr;
    gap: 72px;
  }

  .toc-mobile {
    display: none;
  }

  .toc {
    display: block;
    position: sticky;
    top: 88px;
    max-height: calc(100vh - 110px);
    overflow-y: auto;
  }
}

@media (max-width: 520px) {
  .lang-menu .lang-name {
    display: none;
  }

  .lang-menu .lang-short {
    display: inline;
  }

  .plans {
    font-size: 15px;
  }

  .plans th,
  .plans td {
    padding: 12px 10px;
  }

  .plans td {
    min-width: 58px;
  }
}

@media (max-width: 420px) {
  .badges img {
    height: 44px;
  }
}

/* ==========================================================================
   Motion
   Short and eased out, with a purpose: the landing page arrives once,
   content settles in as it scrolls into view, and the screenshots meet you
   half-way. All of it is CSS, and none of it runs with reduced motion.
   ========================================================================== */

@media (prefers-reduced-motion: no-preference) {
  /* The hero arrives once: the words in a quick stagger, then the phones, then the cards. */
  .hero > div:first-child > * {
    animation: enter var(--enter) var(--ease-out) both;
  }

  .hero > div:first-child > :nth-child(2) { animation-delay: 60ms; }
  .hero > div:first-child > :nth-child(3) { animation-delay: 120ms; }
  .hero > div:first-child > :nth-child(4) { animation-delay: 180ms; }
  .hero > div:first-child > :nth-child(5) { animation-delay: 240ms; }

  .hero-visual > img {
    animation: enter-media 900ms var(--ease-out) 120ms both;
  }

  .hero-visual::before {
    animation: enter-wash 900ms var(--ease-out) both;
  }

  .float-card {
    animation: enter-card 600ms var(--ease-out) 650ms both;
  }

  .float-card--reminder {
    animation-delay: 780ms;
  }

  /* The other pages' titles arrive the same way, more briefly. */
  :is(.doc-head, .about-hero .split > div:first-child, .not-found) > * {
    animation: enter 500ms var(--ease-out) both;
  }

  :is(.doc-head, .about-hero .split > div:first-child, .not-found) > :nth-child(2) { animation-delay: 50ms; }
  :is(.doc-head, .about-hero .split > div:first-child, .not-found) > :nth-child(3) { animation-delay: 100ms; }

  .about-photo {
    animation: enter-media 800ms var(--ease-out) 100ms both;
  }

  /* Where the browser ties animation to scrolling (Safari 26, Chrome, Edge), content settles
     in as it enters the screen and follows the scroll both ways. Elsewhere it simply shows. */
  @supports (animation-timeline: view()) {
    .section-intro,
    .trio li,
    .care-grid li,
    .section .split > div:not(.panel),
    .features li,
    .about-facts li,
    .team-card,
    .faq,
    .contact-ways,
    .plans {
      animation: settle linear both;
      animation-timeline: view();
      animation-range: entry 0% entry 55%;
    }

    /* Neighbours follow a moment later, like a stagger. */
    .trio li:nth-child(2),
    .care-grid li:nth-child(even),
    .features li:nth-child(even),
    .about-facts li:nth-child(even) {
      animation-range: entry 8% entry 65%;
    }

    .trio li:nth-child(3),
    .care-grid li:nth-child(3n) {
      animation-range: entry 14% entry 72%;
    }

    /* Panels and cards grow into place, the screenshot inside rising to meet you. */
    .panel,
    .bento-card,
    .cta-card {
      animation: grow linear both;
      animation-timeline: view();
      animation-range: entry 0% cover 35%;
    }

    .panel > img,
    .bento-card > img {
      animation: lift linear both;
      animation-timeline: view();
      animation-range: entry 10% cover 50%;
    }

    /* The hero's task cards drift apart a little as the page scrolls away. */
    .hero-visual .float-card {
      animation:
        enter-card 600ms var(--ease-out) 650ms both,
        drift-up linear both;
      animation-timeline: auto, scroll(root);
      animation-range: normal, 0 600px;
    }

    .hero-visual .float-card--reminder {
      animation:
        enter-card 600ms var(--ease-out) 780ms both,
        drift-down linear both;
      animation-timeline: auto, scroll(root);
      animation-range: normal, 0 600px;
    }
  }
}

@keyframes enter {
  from {
    opacity: 0;
    transform: translateY(14px);
    filter: blur(4px);
  }
}

@keyframes enter-media {
  from {
    opacity: 0;
    transform: translateY(24px) scale(0.97);
  }
}

@keyframes enter-wash {
  from {
    opacity: 0;
    transform: scale(0.94);
  }
}

@keyframes enter-card {
  from {
    opacity: 0;
    transform: translateY(10px) scale(0.94);
  }
}

@keyframes settle {
  from {
    opacity: 0;
    transform: translateY(28px);
  }
}

@keyframes grow {
  from {
    opacity: 0.4;
    transform: scale(0.96);
  }
}

@keyframes lift {
  from {
    transform: translateY(48px);
  }
}

@keyframes drift-up {
  to {
    translate: 0 -28px;
  }
}

@keyframes drift-down {
  to {
    translate: 0 22px;
  }
}

/* Reduced motion keeps the colour changes that explain things, and nothing that moves. */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    transition-property: color, background-color, border-color, opacity !important;
  }

  .faq-item::details-content {
    transition: none;
  }

  ::view-transition-old(root),
  ::view-transition-new(root) {
    animation: none;
  }
}

/* Frosted surfaces turn solid for people who ask for less transparency. */
@media (prefers-reduced-transparency: reduce) {
  .site-header {
    background: var(--background-warm);
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }

  .float-card,
  .trio-photo .label-icon {
    background: var(--card);
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }
}

/* More contrast: stronger edges on every card and control. */
@media (prefers-contrast: more) {
  :root {
    --card-line: var(--text-muted);
    --line: var(--text-muted);
  }

  .header-links a,
  .doc p,
  .doc li,
  .faq-answer p {
    color: var(--text-primary);
  }
}
