/* Scruby Cleaner — site styles. Brand: cocoa ink, amber, cream foam, sky bubbles; Nunito (OFL).
   Mobile first: the base rules are the 320–600px layout, min-width queries add columns. Sizes are
   fluid (clamp) between a 320px phone and a 1280px desktop, so there are few hard steps. */
@font-face {
  font-family: 'Nunito';
  src: url('/fonts/nunito.woff2') format('woff2');
  font-weight: 200 1000;
  font-display: swap;
}

:root {
  --ink: #3A2416;
  --ink-soft: #6B4A33;
  --cream: #FFF7EC;
  --peach: #FFE2BE;
  --amber: #F7B26E;
  --amber-deep: #EE8740;
  --link: #B4561E;
  --night: #1B120C;
  --card: #FFFFFF;
  --line: rgba(58,36,22,.12);
  --radius: clamp(20px, 1.2vw + 16px, 28px);
  /* Side gutter: 16px on a 320px phone, 32px from ~640px up. Respects the notch in landscape. */
  --gutter: max(clamp(16px, 5vw, 32px), env(safe-area-inset-left), env(safe-area-inset-right));
  --header-h: 64px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-padding-top: 16px; }
body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font: 600 clamp(16px, .2vw + 15.4px, 18px)/1.55 'Nunito', ui-rounded, system-ui, sans-serif;
  overflow-wrap: break-word;
  overflow-x: clip;
}
a { color: var(--link); text-underline-offset: .15em; }
a:hover { color: #8A3F12; }
a:focus-visible { outline: 3px solid var(--amber-deep); outline-offset: 3px; border-radius: 6px; }
img, svg { max-width: 100%; }
h1, h2, h3 { line-height: 1.12; margin: 0; text-wrap: balance; }
p { margin: 0; }
ul { margin: 0; padding: 0; }
.muted { color: var(--ink-soft); }
.wrap { width: 100%; max-width: 1264px; margin: 0 auto; padding-left: var(--gutter); padding-right: var(--gutter); }
.hide-sm { display: none !important; }

/* Header: compact on phones (~30px logo, slim pill), roomier and sticky from 900px. */
.top { position: relative; z-index: 10; background: rgba(255,247,236,.92); }
.top-in { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: var(--header-h); padding-top: 10px; padding-bottom: 10px; }
.logo { display: flex; align-items: center; min-height: 44px; flex-shrink: 1; min-width: 0; }
.logo img { display: block; height: clamp(28px, 2vw + 22px, 44px); width: auto; }
.nav { display: flex; align-items: center; gap: clamp(4px, 1.2vw, 16px); font-weight: 800; flex-shrink: 0; }
.nav a { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; min-width: 44px; padding: 0 8px; color: var(--ink); text-decoration: none; border-radius: 12px; }
.nav a:not(.pill):hover { color: var(--link); }
.pill, .nav .pill { position: relative; display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 0 clamp(16px, 1.2vw + 10px, 22px); border-radius: 999px; background: var(--ink); color: var(--cream) !important; font-weight: 800; font-size: clamp(15px, .3vw + 14px, 17px); text-decoration: none; white-space: nowrap; }
.pill:hover { background: #24160D; }
.doc .top { border-bottom: 1px solid rgba(58,36,22,.08); }

/* Footer */
.foot { border-top: 1px solid rgba(58,36,22,.08); font-size: 15px; font-weight: 700; }
.foot-in { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; padding-top: 28px; padding-bottom: max(28px, env(safe-area-inset-bottom)); }
.foot img { display: block; width: 40px; height: auto; }
.foot nav { display: flex; flex-wrap: wrap; column-gap: 20px; }
.foot nav a { display: inline-flex; align-items: center; min-height: 44px; }

/* Shared bits */
.eyebrow { display: block; color: var(--link); font-size: 14px; font-weight: 900; letter-spacing: .06em; text-transform: uppercase; }
.card { background: var(--card); border-radius: var(--radius); padding: clamp(20px, 1.5vw + 15px, 32px); box-shadow: 0 1px 0 rgba(58,36,22,.06), 0 18px 40px rgba(58,36,22,.06); }
.glyph { flex-shrink: 0; width: 48px; height: 48px; border-radius: 15px; display: flex; align-items: center; justify-content: center; }
.glyph svg { width: 24px; height: 24px; }
.tag { display: inline-block; padding: 1px 9px; border-radius: 999px; background: var(--ink); color: var(--cream); font-size: 13px; font-weight: 900; letter-spacing: .02em; vertical-align: 1px; }
.checks { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.checks li { position: relative; padding-left: 30px; }
.checks li::before { content: ''; position: absolute; left: 0; top: .2em; width: 20px; height: 20px; border-radius: 50%; background: var(--peach) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23B4561E' stroke-width='3.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 12.5l4 4L18 8'/%3E%3C/svg%3E") center / 14px no-repeat; }

/* Home: hero */
.hero { position: relative; overflow: hidden; background: linear-gradient(180deg, var(--cream) 0%, var(--peach) 62%, var(--amber) 100%); padding-top: clamp(16px, 3vw, 48px); }
/* The bottom edge is a row of foam, so the kitten sinks into the bath instead of being cut off. */
.hero::after { content: ''; position: absolute; z-index: 2; left: 0; right: 0; bottom: -1px; height: 26px; pointer-events: none;
  background:
    radial-gradient(circle at 50% 100%, var(--cream) 0 15px, transparent 16px) 26px 100% / 52px 26px repeat-x,
    radial-gradient(circle at 50% 100%, var(--cream) 0 22px, transparent 23px) 0 100% / 52px 26px repeat-x; }
.hero-grid { position: relative; display: grid; grid-template-columns: minmax(0, 1fr); gap: 32px; align-items: center; }
.hero-copy { display: flex; flex-direction: column; gap: clamp(16px, 1vw + 12px, 24px); }
.hero h1 { font-size: clamp(34px, 3.4vw + 23px, 64px); line-height: 1.04; font-weight: 900; letter-spacing: -.02em; }
.lead { font-size: clamp(17px, .5vw + 15.5px, 21px); color: var(--ink-soft); max-width: 34em; }
.cta { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; }
.store { display: inline-flex; align-items: center; justify-content: center; gap: 12px; min-height: 60px; padding: 0 26px 0 20px; border-radius: 18px; background: var(--night); color: var(--cream); text-decoration: none; box-shadow: 0 12px 28px rgba(58,36,22,.25); }
.store:hover { color: var(--cream); background: #000; }
.store span { display: flex; flex-direction: column; line-height: 1.1; }
.store small { font-size: 12px; font-weight: 600; opacity: .8; }
.store strong { font-size: 21px; font-weight: 800; }
.hero .cta .store { flex: 1 1 100%; }
.promises { list-style: none; display: flex; flex-direction: column; gap: 6px; font-size: 16px; font-weight: 800; color: var(--ink-soft); }
.promises li { display: flex; align-items: flex-start; gap: 8px; }
.promises svg { flex-shrink: 0; margin-top: .1em; color: var(--link); }
.hero-art { display: flex; justify-content: center; align-items: flex-end; }
.art { position: relative; width: min(100%, 420px); }
.art img { display: block; width: 100%; height: auto; aspect-ratio: 1; object-fit: cover; border-radius: 32px 32px 0 0; box-shadow: 0 -10px 60px rgba(238,135,64,.35); }
/* Bubbles hang around the picture (sized and placed in % of it), never over the copy. */
.bubble { position: absolute; aspect-ratio: 1; border-radius: 50%; border: 2px solid rgba(255,255,255,.85); background: radial-gradient(circle at 30% 28%, rgba(255,255,255,.95), rgba(170,212,240,.35) 45%, rgba(170,212,240,.12) 70%); box-shadow: inset -6px -8px 14px rgba(120,170,210,.25); pointer-events: none; }
/* Phones: the picture spans the column, so the side bubbles stay inside it. */
.bubble.b1 { width: 13%; left: 3%; top: 14%; }
.bubble.b2 { width: 7%; left: 16%; top: -5%; }
.bubble.b3 { width: 11%; right: 3%; top: 34%; }
.bubble.b4 { width: 5%; right: 14%; top: -3%; }

/* Home: sections */
.section { padding-top: clamp(56px, 5vw + 40px, 112px); display: flex; flex-direction: column; gap: clamp(24px, 1.5vw + 20px, 40px); }
.section-head { display: flex; flex-direction: column; gap: 12px; max-width: 680px; }
.section-head.center { align-items: center; text-align: center; margin: 0 auto; }
.section h2, .split h2 { font-size: clamp(28px, 1.6vw + 23px, 44px); font-weight: 900; letter-spacing: -.01em; }
.section-head p, .split p { font-size: clamp(17px, .25vw + 16px, 19px); color: var(--ink-soft); }

.features { display: grid; grid-template-columns: minmax(0, 1fr); gap: 12px; }
/* Phones: icon beside the text, so a list of cards stays a short scroll. */
.feature { display: grid; grid-template-columns: 44px minmax(0, 1fr); column-gap: 16px; row-gap: 4px; align-items: start; background: var(--card); border-radius: 22px; padding: 18px; box-shadow: 0 1px 0 rgba(58,36,22,.06), 0 18px 40px rgba(58,36,22,.06); }
.feature .glyph { grid-row: span 2; width: 44px; height: 44px; border-radius: 14px; }
.feature .glyph svg { width: 22px; height: 22px; }
.feature h3 { font-size: 18px; font-weight: 800; }
.feature p { font-size: 16px; color: var(--ink-soft); }

.split { display: grid; grid-template-columns: minmax(0, 1fr); gap: 32px; align-items: center; padding-top: clamp(56px, 5vw + 40px, 112px); }
.split-copy { display: flex; flex-direction: column; align-items: flex-start; gap: 14px; max-width: 600px; }
/* Phones: the words first, then the screen. The phone sits on a warm panel that fills its column. */
.phones { order: 2; display: flex; justify-content: center; align-items: center; padding: 32px 16px; border-radius: var(--radius); background: radial-gradient(120% 80% at 50% 0%, #FFEBD2 0%, var(--peach) 55%, #FFD3A0 100%); }
.phone { width: 240px; max-width: 100%; border-radius: 36px; border: 8px solid var(--night); overflow: hidden; box-shadow: 0 30px 60px rgba(58,36,22,.28); background: var(--night); }
.phone img { display: block; width: 100%; height: auto; }

.rings { list-style: none; display: flex; flex-direction: column; gap: 14px; margin: 4px 0; }
.rings li { position: relative; padding-left: 40px; color: var(--ink-soft); font-size: 16.5px; }
.rings li::before { content: ''; position: absolute; left: 0; top: 1px; width: 26px; height: 26px; border-radius: 50%; border: 5px solid var(--ring); box-sizing: border-box; }
.rings strong { display: block; color: var(--ink); font-size: 18px; font-weight: 900; }

.duo { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; }
.card.big { display: flex; flex-direction: column; gap: 12px; }
.card.big h2 { font-size: clamp(24px, 1vw + 21px, 32px); font-weight: 900; margin-top: 4px; }
.card.big p { color: var(--ink-soft); }
.card .note { margin-top: auto; padding: 12px 14px; border-radius: 14px; background: var(--cream); color: var(--ink); }

.privacy { margin-top: clamp(56px, 5vw + 40px, 112px); background: var(--ink); color: var(--cream); }
.privacy-in { display: flex; flex-direction: column; align-items: flex-start; gap: clamp(24px, 1.5vw + 20px, 40px); padding-top: clamp(56px, 5vw + 40px, 104px); padding-bottom: clamp(56px, 5vw + 40px, 104px); }
.privacy .eyebrow { color: var(--amber); }
.privacy h2 { font-size: clamp(28px, 1.6vw + 23px, 44px); font-weight: 900; letter-spacing: -.01em; }
.vows { list-style: none; display: grid; grid-template-columns: minmax(0, 1fr); gap: 12px; width: 100%; }
.vows li { display: grid; grid-template-columns: 48px minmax(0, 1fr); gap: 16px; align-items: center; padding: 18px; border-radius: 22px; background: rgba(255,247,236,.06); border: 1px solid rgba(255,247,236,.1); }
.vows .glyph { background: rgba(247,178,110,.18); color: var(--amber); }
.vows p { color: rgba(255,247,236,.9); font-size: clamp(17px, .25vw + 16px, 19px); }
.privacy a { color: var(--amber); font-weight: 800; }
.privacy a:hover { color: #FFD3A3; }
.more { display: inline-flex; align-items: center; min-height: 44px; }

.plans { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; width: 100%; max-width: 960px; margin: 0 auto; }
.plan { display: flex; flex-direction: column; gap: 16px; }
.plan h3 { font-size: 24px; font-weight: 900; }
.plan.pro { background: var(--ink); color: var(--cream); }
.plan.pro .checks li::before { background-color: rgba(247,178,110,.22); background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23F7B26E' stroke-width='3.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 12.5l4 4L18 8'/%3E%3C/svg%3E"); }
.fine { font-size: 15px; max-width: 46em; }
#pro .fine { margin: 0 auto; text-align: center; }
#pro .cta { justify-content: center; padding-bottom: clamp(56px, 5vw + 40px, 112px); }
#pro .cta .store { flex: 1 1 100%; }

/* Legal pages: a readable column (~70 characters), breathing room under the header, tables that
   turn into stacked cards on phones. */
.legal { max-width: calc(760px + 2 * var(--gutter)); padding-top: clamp(32px, 4vw + 20px, 72px); padding-bottom: clamp(48px, 4vw + 32px, 96px); font-weight: 600; }
.legal h1 { font-size: clamp(32px, 2vw + 26px, 48px); font-weight: 900; letter-spacing: -.01em; margin-bottom: clamp(12px, 1vw + 8px, 20px); }
.legal h2 { font-size: clamp(21px, .8vw + 18.5px, 27px); font-weight: 900; margin: clamp(32px, 2vw + 24px, 48px) 0 12px; scroll-margin-top: 16px; }
.legal h3 { font-size: clamp(18px, .3vw + 17px, 20px); font-weight: 800; margin: 24px 0 8px; }
.legal p, .legal li { color: #4A3222; }
.legal p + p { margin-top: 12px; }
.legal ul, .legal ol { padding-left: 22px; margin: 10px 0; }
.legal li + li { margin-top: 6px; }
.legal a { overflow-wrap: anywhere; }
.legal code { font: 600 .92em ui-monospace, Menlo, monospace; background: var(--peach); padding: 1px 5px; border-radius: 5px; overflow-wrap: anywhere; }
.legal .table { margin: 16px 0 20px; }
.legal table { border-collapse: collapse; width: 100%; font-size: 15.5px; line-height: 1.5; }
.legal th, .legal td { text-align: left; vertical-align: top; overflow-wrap: anywhere; }
/* Phones: every row is a card; the first cell is its title, the rest are labelled by their column. */
.legal thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.legal table, .legal tbody, .legal tr, .legal td { display: block; }
.legal tbody { display: flex; flex-direction: column; gap: 10px; }
.legal tr { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 14px 16px; }
.legal td + td { margin-top: 10px; }
.legal td:first-child { color: var(--ink); }
.legal td + td::before { content: attr(data-label); display: block; margin-bottom: 2px; color: var(--link); font-size: 12px; font-weight: 900; letter-spacing: .05em; text-transform: uppercase; }

.notfound { padding-top: clamp(56px, 6vw + 32px, 120px); padding-bottom: clamp(72px, 6vw + 48px, 140px); display: flex; flex-direction: column; align-items: center; text-align: center; gap: 16px; }
.notfound img { width: clamp(88px, 6vw + 64px, 120px); height: auto; }
.notfound .pill { min-height: 48px; padding: 0 24px; }
.notfound h1 { font-size: clamp(30px, 1.5vw + 25px, 42px); font-weight: 900; }

/* ≥ 480px: buttons stop stretching edge to edge, simple two-up grids. */
@media (min-width: 480px) {
  .hero .cta .store, #pro .cta .store { flex: 0 0 auto; }
}

@media (min-width: 640px) {
  :root { --header-h: 76px; }
  .foot-in { flex-direction: row; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 24px; }
  .features, .duo, .plans { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
  .art { width: min(100%, 440px); }
  .bubble.b1 { width: 15%; left: -6%; top: 12%; }
  .bubble.b3 { width: 12%; right: -5%; top: 30%; }
  .feature { display: flex; flex-direction: column; gap: 12px; padding: 26px; border-radius: var(--radius); }
  .feature .glyph { width: 52px; height: 52px; border-radius: 16px; }
  .feature .glyph svg { width: 26px; height: 26px; }
  .feature h3 { font-size: 21px; }
  .feature p { font-size: 16px; }
  /* Wide enough for a real table again. */
  .legal thead { position: static; width: auto; height: auto; overflow: visible; clip-path: none; white-space: normal; display: table-header-group; }
  .legal table { display: table; }
  .legal tbody { display: table-row-group; }
  .legal tr { display: table-row; background: none; border: 0; border-radius: 0; padding: 0; }
  .legal th, .legal td { display: table-cell; padding: 12px 14px; border-bottom: 1px solid var(--line); overflow-wrap: break-word; }
  .legal td + td { margin-top: 0; }
  .legal td + td::before { content: none; }
  .legal th { font-weight: 800; background: rgba(255,226,190,.5); }
  .legal th:first-child { border-top-left-radius: 12px; }
  .legal th:last-child { border-top-right-radius: 12px; }
}

@media (min-width: 720px) {
  .hide-sm { display: inline-flex !important; }
  /* Tablets: the words beside the screen already, with a slimmer phone. */
  .split { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 40px; }
  .split .phones { order: 0; align-self: stretch; padding: 40px 24px; }
  .split.flip .phones { order: 2; }
  .phone { width: 230px; }
}

@media (min-width: 900px) {
  /* Sticky only where there is height to spare; on phones it would eat the reading space. */
  .top { position: sticky; top: 0; background: rgba(255,247,236,.86); -webkit-backdrop-filter: saturate(1.4) blur(14px); backdrop-filter: saturate(1.4) blur(14px); border-bottom: 1px solid rgba(58,36,22,.06); }
  html { scroll-padding-top: calc(var(--header-h) + 16px); }
  .legal h2 { scroll-margin-top: calc(var(--header-h) + 16px); }
  .hero { padding-top: clamp(40px, 4vw, 72px); }
  .hero-grid { grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); gap: clamp(40px, 4vw, 72px); align-items: end; }
  .hero-copy { align-self: center; padding-bottom: 56px; }
  .art { width: min(100%, 520px); }
  .art img { border-radius: 44px 44px 0 0; }
  .split { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(48px, 5vw, 88px); }
  .phone { width: 260px; border-radius: 42px; border-width: 9px; }
  .features.four { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .vows { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
  .vows li { grid-template-columns: minmax(0, 1fr); align-items: start; align-content: start; gap: 16px; padding: 26px; border-radius: var(--radius); }
  .vows .glyph { width: 52px; height: 52px; border-radius: 16px; }
}

@media (min-width: 1100px) {
  .features:not(.four) { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .split .phones { padding: 56px 32px; }
  .phone { width: 280px; border-radius: 44px; }
}

@media (min-width: 900px) and (max-width: 1099px) {
  .features.four { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
  .bubble { animation: float 9s ease-in-out infinite; }
  .bubble:nth-child(2n) { animation-duration: 12s; animation-delay: -3s; }
  @keyframes float { 50% { transform: translateY(-14px); } }
}
