/* Site de l'app, aux couleurs du design system Frello (frello/packages/ui-tokens), comme
   FrelloUI.swift côté app. Une seule feuille pour tools.frello.fr et les pages des apps. */

@font-face {
  font-family: "Comfortaa";
  src: url("fonts/Comfortaa-Bold.woff2") format("woff2");
  font-weight: 700;
  font-display: swap;
}
@font-face {
  font-family: "Atkinson Hyperlegible Next";
  src: url("fonts/AtkinsonHyperlegibleNext-Regular.ttf") format("truetype");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Atkinson Hyperlegible Next";
  src: url("fonts/AtkinsonHyperlegibleNext-SemiBold.ttf") format("truetype");
  font-weight: 600;
  font-display: swap;
}

:root {
  color-scheme: light dark;
  --background: #f5f5f5;
  --surface: #ffffff;
  --border: #d4d7dd;
  --text: #131927;
  --text-secondary: #394050;
  --text-tertiary: #646b7a;
  --accent: #524ff1;
  --accent-strong: #403cd9;
  --accent-soft: #e0e7ff;
  --accent-on-soft: #403cd9;
  --shadow: 0 0 8px rgba(189, 186, 186, 0.25);
  --radius: 16px;
}
@media (prefers-color-scheme: dark) {
  :root {
    --background: #131927;
    --surface: #1e2436;
    --border: #2c3346;
    --text: #f5f5f5;
    --text-secondary: #c2c7d0;
    --text-tertiary: #8d93a1;
    --accent: #8f8df6;
    --accent-strong: #524ff1;
    --accent-soft: #262a52;
    --accent-on-soft: #b9b7fa;
    --shadow: none;
  }
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--background);
  color: var(--text);
  font: 17px/1.55 "Atkinson Hyperlegible Next", -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
}

main { max-width: 880px; margin: 0 auto; padding: 72px 24px 40px; }

h1, h2 { font-family: "Comfortaa", ui-rounded, system-ui, sans-serif; font-weight: 700; line-height: 1.15; }
h1 { font-size: clamp(34px, 9vw, 52px); margin: 18px 0 6px; overflow-wrap: break-word; }
h2 { font-size: clamp(24px, 6vw, 30px); margin: 0 0 20px; }
h3 { font-size: 18px; margin: 0 0 6px; }
p { margin: 0 0 12px; }
a { color: var(--accent); }

.hero { text-align: center; margin-bottom: 64px; }
.hero .icon { width: 128px; height: 128px; }
.by { display: flex; align-items: baseline; justify-content: center; gap: 6px; color: var(--text-secondary); }
.logo { height: 20px; width: auto; color: var(--text); transform: translateY(4px); }
.tagline { font-size: 20px; color: var(--text-secondary); max-width: 620px; margin: 20px auto 28px; }

.button {
  display: inline-block;
  padding: 14px 28px;
  border-radius: 999px;
  background: var(--accent-strong);
  color: #ffffff;
  font-weight: 600;
  text-decoration: none;
}
.button:hover { background: #403cd9; }
.requirements { margin-top: 14px; font-size: 14px; color: var(--text-tertiary); }

.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; margin-bottom: 64px; }
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 24px;
}
@media (prefers-color-scheme: light) { .card { border-color: transparent; } }
.card p { color: var(--text-secondary); margin: 0; }

.steps { counter-reset: step; list-style: none; padding: 0; margin: 0 0 64px; display: grid; gap: 12px; }
.steps li {
  counter-increment: step;
  display: flex;
  gap: 16px;
  align-items: center;
  background: var(--surface);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 16px 20px;
}
.steps li::before {
  content: counter(step);
  flex: none;
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--accent-on-soft);
  font-weight: 600;
}

.prose { max-width: 680px; }
.prose h2 { margin-top: 40px; font-size: 24px; }
.prose p, .prose li { color: var(--text-secondary); }

footer {
  border-top: 1px solid var(--border);
  padding: 28px 24px 48px;
  text-align: center;
  font-size: 14px;
  color: var(--text-tertiary);
}
footer a { color: var(--text-secondary); }
kbd { font-family: inherit; font-weight: 600; }

/* Accueil de tools.frello.fr : une carte par app, entièrement cliquable. */
.apps { margin-bottom: 24px; }
.app { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; color: inherit; text-decoration: none; }
.app img { width: 72px; height: 72px; margin-bottom: 6px; }
.app p { flex: 1; }
.app .more { margin-top: 12px; color: var(--accent); font-weight: 600; }
.app:hover .more { text-decoration: underline; }
.center { text-align: center; }
