/* Cosy Studio — the one stylesheet of cosystudio.app.
   The look comes from the Lovable pass of 22.11.2026 (project «Cosy Studio Website», brief
   docs/design/LOVABLE_SITE_BRIEF.md), carried over by hand into plain HTML: no scripts, no web fonts.
   Tokens are the app's (App/Sources/DesignSystem/Tokens/DSColor.swift): terracotta is action and links, ochre is
   paid, green is done; paint colours appear only in artwork and decoration. The font is the system's rounded face:
   on iPhone and Mac that is SF Pro Rounded, the app's own. */

:root {
  color-scheme: light dark;
  --paper: #F6EDDF;
  --surface: #FFFAF2;
  --raised: #FFFFFF;
  --text: #3B2A20;
  --text2: #7E6857;
  --accent: #B9471A;
  --accent-soft: #D9643A;
  --ochre: #E9B44C;
  --success: #3E7843;
  --line: #E6D8C4;
  --on-accent: #FFF8F0;
  --dot: rgba(160, 120, 80, 0.07);
  /* An even 1 px hairline all round (the border); depth only from a soft shadow, never a solid lip under it. */
  --shadow-card: 0 1px 2px rgba(59, 42, 32, 0.05), 0 8px 24px rgba(59, 42, 32, 0.08);
  /* A shadow that follows the picture's own rounded shape. */
  --shadow-art: drop-shadow(0 8px 14px rgba(59, 42, 32, 0.16));

  /* Paint, for artwork and decoration only. */
  --paint-ochre: #E9B44C;
  --paint-terracotta: #D9643A;
  --paint-sky: #BFDCEB;
  --paint-green: #5F9A63;
  --paint-ink: #4A3428;

  --font: ui-rounded, "SF Pro Rounded", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --wrap: 64rem;
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #24211D;
    --surface: #302C26;
    --raised: #3D3730;
    --text: #F6EDDF;
    --text2: #C6B5A3;
    --accent: #EF956F;
    --accent-soft: #EF956F;
    --ochre: #E9BE64;
    --success: #91BC91;
    --line: #51483D;
    --on-accent: #35241B;
    --dot: rgba(198, 181, 163, 0.07);
    --shadow-card: 0 1px 2px rgba(0, 0, 0, 0.20), 0 8px 24px rgba(0, 0, 0, 0.28);
    --shadow-art: drop-shadow(0 10px 14px rgba(0, 0, 0, 0.35));
  }
}

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

html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--text);
  /* The app's paper: a faint dot every 6 px. */
  background-color: var(--paper);
  background-image: radial-gradient(var(--dot) 1px, transparent 1.2px);
  background-size: 6px 6px;
  overflow-x: hidden;
}

main { flex: 1; width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 20px; }

a { color: var(--accent); text-underline-offset: 3px; text-decoration-thickness: 1.5px; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 8px; }
img, svg { display: block; }

h1, h2, h3 { margin: 0; line-height: 1.15; font-weight: 800; }
p, ul, ol { margin: 0; }

.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 12px; z-index: 10; background: var(--raised); padding: 8px 12px; border-radius: 12px; }

/* ---- Header and footer ---- */

.site-header {
  width: 100%;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 20px 20px 8px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 1.125rem;
  font-weight: 800;
  color: var(--text);
  text-decoration: none;
}
.brand img { width: 36px; height: 36px; border-radius: 10px; box-shadow: 0 1px 3px rgba(59, 42, 32, 0.18); }
.site-nav { display: flex; flex-wrap: wrap; gap: 4px; margin: 0 -8px; font-size: 0.95rem; }
.site-nav a {
  color: var(--text2);
  text-decoration: none;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: 999px;
  transition: background-color .15s, color .15s;
}
.site-nav a:hover { color: var(--accent); background: var(--surface); }
.site-nav a[aria-current="page"] { color: var(--text); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); }

.site-footer { margin-top: 96px; border-top: 1px dashed var(--line); }
.site-footer .inner {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 40px 20px;
  font-size: 0.875rem;
  color: var(--text2);
}
.site-footer nav { display: flex; flex-wrap: wrap; gap: 8px 20px; font-weight: 600; }
.site-footer nav a { text-decoration: none; }
.site-footer nav a:hover { text-decoration: underline; }
.site-footer .copy { margin-top: 20px; }
.site-footer .legal { margin-top: 8px; font-size: 0.75rem; }

/* ---- Building blocks ---- */

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 22px;
  box-shadow: var(--shadow-card);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 52px;
  padding: 0 28px;
  border-radius: 999px;
  background: var(--accent);
  color: var(--on-accent);
  font-weight: 700;
  text-decoration: none;
  transition: transform .15s ease, filter .15s ease;
}
.btn:hover { transform: translateY(-1px); filter: brightness(1.05); }
.btn:active { transform: translateY(0); filter: brightness(0.95); }

.small { font-size: 0.875rem; font-weight: 600; color: var(--text2); }

/* Paint dots and the brush stroke under a title. */
.dots { width: 112px; height: 32px; margin-bottom: 24px; }
.dots.sm { width: 96px; height: 28px; margin-bottom: 20px; }
.dots circle:nth-child(1) { fill: var(--paint-ochre); }
.dots circle:nth-child(2) { fill: var(--paint-terracotta); opacity: .9; }
.dots circle:nth-child(3) { fill: var(--paint-sky); }
.dots circle:nth-child(4) { fill: var(--paint-green); opacity: .9; }
.dots circle:nth-child(5) { fill: var(--paint-ink); }
.titled { position: relative; display: inline-block; }
.stroke {
  position: absolute;
  left: 0;
  bottom: -8px;
  width: 100%;
  height: 16px;
  color: var(--accent-soft);
}
.stroke.ochre { color: var(--paint-ochre); }
.stroke path { fill: none; stroke: currentColor; stroke-width: 7; stroke-linecap: round; opacity: .55; }
.check circle { fill: currentColor; }
.check path { fill: none; stroke: var(--surface); stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }

.section-title { font-size: 1.5rem; margin-bottom: 20px; }

/* ---- Studio page ---- */

.studio-hero { position: relative; padding: 48px 0 64px; display: grid; align-items: center; gap: 40px; }
.hero-mark { display: none; width: 200px; height: auto; transform: rotate(-6deg); filter: var(--shadow-art); }
.studio-hero h1 { font-size: 3rem; letter-spacing: -0.025em; }
.studio-hero .lede { position: relative; margin-top: 32px; max-width: 36rem; font-size: 1.25rem; color: var(--text2); }

.app-card { display: grid; gap: 24px; padding: 20px; }
.app-card .art {
  display: block;
  max-width: 260px;
  transform: rotate(-2deg);
  transition: transform .2s ease;
}
.app-card .art:hover { transform: rotate(0deg); }
/* The bee is the app icon itself: a paper square with the icon's rounded corners. */
.app-card .art img, .hero-art .bee { width: 100%; height: auto; border-radius: 22.37%; box-shadow: var(--shadow-card); }
.app-card h3 { font-size: 1.875rem; }
.app-card h3 a { color: inherit; text-decoration: none; }
.app-card .small { margin-top: 4px; }
.app-card .text { margin-top: 16px; max-width: 65ch; font-size: 1.125rem; }
.actions { margin-top: 24px; display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; padding: 0; list-style: none; font-weight: 600; }

.studio-about { margin-top: 80px; max-width: 42rem; }
.studio-about p { font-size: 1.125rem; }
.studio-about p + p { margin-top: 16px; }

/* ---- App page ---- */

.app-hero { display: grid; gap: 40px; align-items: center; padding: 40px 0 80px; }
.app-hero h1 { font-size: 3.75rem; letter-spacing: -0.025em; }
.app-hero .tagline { margin-top: 28px; font-size: 1.5rem; font-weight: 700; line-height: 1.3; }
.app-hero .text { margin-top: 20px; max-width: 36rem; font-size: 1.125rem; color: var(--text2); }
.pill {
  display: inline-block;
  margin-top: 24px;
  padding: 8px 16px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text2);
}
.hero-art { position: relative; width: 100%; max-width: 22rem; margin: 0 auto; padding: 8px; }
.hero-art .bee { transform: rotate(2deg); }
.hero-art .dots { position: absolute; left: 8px; bottom: -40px; margin: 0; }

.steps { display: grid; gap: 20px; padding: 0; list-style: none; }
.steps li { padding: 24px; }
.steps .num {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  margin-bottom: 16px;
  border-radius: 50%;
  font-size: 1.25rem;
  font-weight: 800;
  color: #3B2A20;            /* ink on paint, in both themes */
  box-shadow: inset 0 -3px 0 rgba(0, 0, 0, .12);
}
.steps li:nth-child(1) .num { background: var(--paint-ochre); }
.steps li:nth-child(2) .num { background: var(--paint-sky); }
.steps li:nth-child(3) .num { background: var(--paint-green); }
.steps h3 { font-size: 1.25rem; }
.steps p { margin-top: 8px; color: var(--text2); }
.app-how .section-title { font-size: 1.875rem; margin-bottom: 24px; }

.pair { display: grid; gap: 20px; margin-top: 64px; }
.pair .card { position: relative; overflow: hidden; padding: 24px; }
.pair h2 { font-size: 1.5rem; }
.pair p { margin-top: 16px; font-size: 1.125rem; }
.with-check { display: flex; align-items: center; gap: 12px; }
.with-check .check { width: 32px; height: 32px; flex: none; color: var(--success); }
.pro-chip {
  position: absolute;
  top: 20px;
  right: 20px;
  padding: 4px 12px;
  border-radius: 999px;
  background: var(--ochre);
  color: #3B2A20;
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.08em;
}
.pro-bar { margin-top: 20px; width: 96px; height: 6px; border-radius: 999px; background: var(--ochre); }

/* ---- Support ---- */

.page-hero { padding: 40px 0; }
.page-hero h1 { font-size: 2.25rem; letter-spacing: -0.025em; }
.page-hero .lede { margin-top: 20px; max-width: 36rem; font-size: 1.125rem; color: var(--text2); }

.contact { display: flex; flex-direction: column; gap: 20px; padding: 24px; }
.contact .address { font-size: 1.25rem; font-weight: 800; overflow-wrap: anywhere; }
.contact .small { margin-top: 4px; font-weight: 400; }
.contact .btn { flex: none; align-self: flex-start; }

.faq-section { margin-top: 64px; max-width: 48rem; }
.faq-list { display: grid; gap: 12px; }
details.faq { padding: 4px 20px; }
details.faq summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 0;
  font-size: 1.125rem;
  font-weight: 700;
  list-style: none;
  cursor: pointer;
}
details.faq summary::-webkit-details-marker { display: none; }
details.faq .chev {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: none;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--raised);
  color: var(--accent);
  box-shadow: inset 0 0 0 1px var(--line);
  transition: transform .2s ease;
}
details.faq .chev svg { width: 16px; height: 16px; }
details.faq .chev path { stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; }
details.faq[open] .chev { transform: rotate(45deg); }
details.faq .answer { border-top: 1px dashed var(--line); padding: 16px 0 20px; color: var(--text2); }

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

.legal-page { max-width: 40rem; margin: 0 auto; padding-top: 40px; }
.legal-page h1 { font-size: 2.25rem; letter-spacing: -0.025em; }
.legal-page .small { margin-top: 12px; }
.intro { position: relative; overflow: hidden; margin-top: 32px; padding: 24px; }
.intro .with-check { align-items: flex-start; font-size: 1.125rem; font-weight: 700; line-height: 1.35; }
.intro .with-check .check { width: 24px; height: 24px; margin-top: 2px; }
.intro p + p { margin-top: 12px; }
.intro .with-check + p { margin-top: 16px; }
.note { margin-top: 32px; padding: 24px; }

.prose { font-size: 1.0625rem; line-height: 1.75; }
.prose > p:first-child { margin-top: 32px; }
.prose h2 { margin: 48px 0 12px; font-size: 1.375rem; line-height: 1.3; }
.prose p, .prose ul { margin: 0 0 16px; }
.prose ul { padding-left: 1.3em; }
.prose li + li { margin-top: 6px; }
.prose strong { font-weight: 700; }

/* «What stays on your iPhone»: each row a small card on a phone, one table card from 768 px. */
.data-table { display: block; width: 100%; margin: 24px 0; border-collapse: collapse; font-size: 1rem; }
.data-table thead { display: none; }
.data-table tbody { display: grid; gap: 12px; }
.data-table tr { display: block; padding: 20px; }
.data-table td { display: block; vertical-align: top; }
.data-table td + td { margin-top: 12px; }
.data-table td:first-child { font-weight: 700; }
.data-table td[data-label]::before {
  content: attr(data-label);
  display: block;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text2);
}

/* ---- Wider screens ---- */

@media (min-width: 640px) {
  main { padding: 0 32px; }
  .site-header { padding: 32px 32px 8px; }
  .site-footer .inner { padding: 40px 32px; }
  .studio-hero { padding: 80px 0 96px; }
  .studio-hero h1 { font-size: 4.5rem; }
  .studio-hero .lede { font-size: 1.5rem; line-height: 1.625; }
  .app-card { grid-template-columns: 220px 1fr; gap: 40px; padding: 32px; }
  .app-hero h1 { font-size: 4.5rem; }
  .app-hero .tagline { font-size: 1.875rem; }
  .pair .card, .contact { padding: 32px; }
  .contact { flex-direction: row; align-items: center; justify-content: space-between; }
  .contact .address { font-size: 1.5rem; }
  .contact .btn { align-self: center; }
  .page-hero { padding: 64px 0 40px; }
  .page-hero h1 { font-size: 3.75rem; }
  .page-hero .lede { font-size: 1.25rem; }
  .legal-page { padding-top: 64px; }
  .legal-page h1 { font-size: 3rem; }
  .intro, .note { padding: 32px; }
  details.faq { padding: 4px 24px; }
}

@media (min-width: 768px) {
  .app-hero { grid-template-columns: 1.1fr 1fr; padding-top: 64px; }
  .hero-art { max-width: 26rem; }
  .studio-hero { grid-template-columns: 1fr auto; }
  .hero-mark { display: block; margin-right: 24px; }
  .steps { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .pair { grid-template-columns: repeat(2, minmax(0, 1fr)); }

  .data-table {
    display: table;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 22px;
    background: var(--surface);
    box-shadow: var(--shadow-card);
    border-collapse: separate;
    border-spacing: 0;
    table-layout: fixed;
  }
  .data-table th:nth-child(1) { width: 36%; }
  .data-table th:nth-child(2) { width: 30%; }
  .data-table thead { display: table-header-group; }
  .data-table tbody { display: table-row-group; }
  .data-table tr { display: table-row; padding: 0; }
  .data-table tr.card { border: 0; border-radius: 0; background: none; box-shadow: none; }
  .data-table th {
    padding: 12px 16px;
    background: var(--raised);
    text-align: left;
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--text2);
  }
  .data-table td { display: table-cell; padding: 16px; border-top: 1px solid var(--line); }
  .data-table td + td { margin-top: 0; }
  .data-table td[data-label]::before { display: none; }
}

@media (prefers-color-scheme: dark) {
  .dots circle:nth-child(5) { fill: #8A7462; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; }
}
