/* Loafo website. Colours, fonts and shapes are the app's own (see DESIGN_SYSTEM.md). No external requests: fonts are served from /assets/fonts. */
@font-face { font-family: "Gluten"; src: url("assets/fonts/gluten.ttf") format("truetype"); font-weight: 100 900; font-display: swap; }
@font-face { font-family: "Figtree"; src: url("assets/fonts/figtree.ttf") format("truetype"); font-weight: 300 900; font-display: swap; }

:root {
  --bg: #FBF4E8; --surface: #FFFBF3; --alt: #F3E4CC; --hair: #E4D3B8;
  --ink: #3A2A1F; --soft: #7A6452; --crust: #9A5B26;
  --blue: #2E4BA0; --blue-deep: #1C2E70; --honey: #E0A33A; --tape: #EBD9A9; --label: #F7E7C2;
  --green: #3E8F5A; --green-bg: #EEF6EE; --green-line: #CFE4CF;
  --blue-bg: #EAF0FB; --blue-line: #C9D6F2; --red: #C2503F; --red-bg: #FBEDEA; --red-line: #F0CFC8;
  --shadow: 0 18px 36px rgba(58, 42, 31, .16);
  --wrap: 1120px;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: "Figtree", system-ui, sans-serif; font-size: 17px; line-height: 1.55; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--blue); text-underline-offset: 3px; }
.wrap { width: min(var(--wrap), calc(100% - 48px)); margin-inline: auto; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--blue); color: #fff; padding: 10px 16px; border-radius: 12px; z-index: 10; }
.skip:focus { left: 8px; }
:focus-visible { outline: 3px solid var(--honey); outline-offset: 3px; border-radius: 10px; }

/* header */
.top { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 28px 0 0; flex-wrap: wrap; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink); font-family: "Gluten", sans-serif; font-weight: 700; font-size: 30px; }
.brand img { width: 44px; height: 44px; border-radius: 12px; }
nav { display: flex; gap: 8px; }
nav a { text-decoration: none; color: var(--soft); font-weight: 600; padding: 10px 18px; border-radius: 999px; }
nav a:hover { background: var(--alt); }
nav a[aria-current="page"] { background: var(--blue); color: #fff; }

/* type */
h1, h2, h3 { font-family: "Gluten", sans-serif; font-weight: 700; margin: 0; line-height: 1.1; letter-spacing: 0; }
h1 { font-size: clamp(42px, 7vw, 68px); line-height: 1.06; }
h2 { font-size: clamp(30px, 4.4vw, 40px); }
.lead { font-size: 20px; font-weight: 500; color: var(--soft); line-height: 1.5; max-width: 34em; margin: 0; }
section { margin-top: 88px; }
.sec-head { display: grid; gap: 16px; margin-bottom: 26px; justify-items: start; }

/* buttons: same as the app's (blue with a darker foot) */
.btn { display: inline-block; text-decoration: none; font-weight: 700; font-size: 17px; padding: 15px 26px; border-radius: 18px; }
.btn.primary { background: var(--blue); color: #fff; box-shadow: 0 4px 0 var(--blue-deep); }
.btn.primary:hover { transform: translateY(1px); box-shadow: 0 3px 0 var(--blue-deep); }
.btn.secondary { background: var(--surface); color: var(--ink); border: 1px solid var(--hair); padding: 14px 24px; }
.btn.gold { background: #FFD36E; color: var(--ink); box-shadow: 0 4px 0 #9A6A12; }
.btn[aria-disabled="true"] { background: var(--alt); color: var(--soft); box-shadow: none; cursor: default; border: 1px dashed var(--hair); }
.btns { display: flex; gap: 14px; flex-wrap: wrap; align-items: center; }

/* hero */
.hero { display: grid; grid-template-columns: 1.05fr 1fr; gap: 56px; align-items: center; margin-top: 44px; }
.hero .text { display: grid; gap: 22px; justify-items: start; }
.hero-art { position: relative; padding-bottom: 60px; }
.hero-art .stage { border-radius: 34px; border: 1px solid var(--hair); box-shadow: var(--shadow); width: 92%; aspect-ratio: 4 / 3; object-fit: cover; }
.hero-art .widget { position: absolute; right: 0; bottom: 0; width: 34%; border-radius: 26px; box-shadow: 0 10px 24px rgba(58, 42, 31, .2); transform: rotate(-3deg); animation: bob 5s ease-in-out infinite; }
.mood { position: absolute; left: 4%; bottom: 20px; display: flex; align-items: center; gap: 10px; background: var(--surface); border: 1px solid var(--hair); border-radius: 999px; padding: 8px 18px 8px 8px; font-weight: 600; box-shadow: 0 6px 16px rgba(58, 42, 31, .12); }
.mood .dot { width: 32px; height: 32px; border-radius: 50%; background: #E4EBFA; display: grid; place-items: center; }
@keyframes bob { 50% { transform: rotate(-3deg) translateY(-6px); } }
@media (prefers-reduced-motion: reduce) { .hero-art .widget { animation: none; } html { scroll-behavior: auto; } }

/* cards */
.cards { display: grid; gap: 20px; }
.cards.four { grid-template-columns: repeat(4, 1fr); }
.cards.three { grid-template-columns: repeat(3, 1fr); }
.cards.two { grid-template-columns: repeat(2, 1fr); }
.card { background: var(--surface); border: 1px solid var(--hair); border-radius: 26px; padding: 26px 24px 28px; display: grid; gap: 12px; align-content: start; }
.card h3 { font-family: "Figtree", sans-serif; font-weight: 700; font-size: 20px; line-height: 1.3; }
.card p { margin: 0; color: var(--soft); font-size: 16px; }
.art { width: 64px; height: 64px; flex: none; }

/* growth bar divider */
.bar { display: flex; align-items: center; gap: 10px; margin-top: 64px; }
.bar i { flex: 0 0 200px; height: 12px; border-radius: 6px; background: var(--tape); overflow: hidden; display: block; }
.bar i b { display: block; height: 100%; background: var(--honey); }
.bar span { color: var(--soft); font-weight: 500; margin-left: 10px; }

/* permissions */
.perm { padding: 26px 28px 28px; border-radius: 28px; gap: 16px; }
.perm.good { background: var(--green-bg); border-color: var(--green-line); }
.perm header { display: flex; align-items: center; gap: 14px; }
.perm h3 { font-size: 22px; }
.perm dl { margin: 0; display: grid; gap: 14px; }
.perm dt { font-size: 12px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--crust); }
.perm dd { margin: 2px 0 0; color: var(--ink); font-size: 16px; }

/* data */
.data { border-radius: 28px; padding: 28px; gap: 16px; }
.data h3 { display: flex; align-items: center; gap: 10px; font-size: 22px; }
.data h3::before { content: ""; width: 14px; height: 14px; border-radius: 50%; background: var(--tone); flex: none; }
.data ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 12px; }
.data li { position: relative; padding-left: 20px; color: var(--ink); font-size: 16px; }
.data li::before { content: ""; position: absolute; left: 0; top: .6em; width: 7px; height: 7px; border-radius: 50%; background: var(--tone); }
.data.green { --tone: var(--green); background: var(--green-bg); border-color: var(--green-line); }
.data.blue { --tone: var(--blue); background: var(--blue-bg); border-color: var(--blue-line); }
.data.red { --tone: var(--red); background: var(--red-bg); border-color: var(--red-line); }

.partner h3 { font-family: "Gluten", sans-serif; font-size: 26px; }
.partner a { font-weight: 700; }

/* contact banner */
.banner { background: var(--blue); color: #fff; border-radius: 40px; padding: 44px 56px 0; display: grid; grid-template-columns: 1fr auto; gap: 40px; align-items: end; overflow: hidden; margin-top: 88px; }
.banner .text { display: grid; gap: 16px; padding-bottom: 44px; justify-items: start; }
.banner h2 { color: #fff; font-size: clamp(32px, 4.6vw, 44px); }
.banner p { margin: 0; color: #DCE5FA; font-size: 18px; font-weight: 500; max-width: 30em; }
.banner img { width: 250px; }
.btn.ghost { background: transparent; color: #fff; border: 2px solid rgba(255, 255, 255, .55); padding: 13px 24px; }
.btn.ghost:hover { background: rgba(255, 255, 255, .12); }
.todo { background: repeating-linear-gradient(45deg, #FFD36E, #FFD36E 8px, #FFE29A 8px, #FFE29A 16px); }

/* home: app screenshots, feature rows, questions */
.shot { display: block; height: auto; border-radius: 28px; border: 3px solid var(--ink); box-shadow: var(--shadow); background: var(--surface); }
.gallery { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.gallery figure { margin: 0; display: grid; gap: 16px; justify-items: center; align-content: start; text-align: center; }
.gallery .shot { width: 100%; max-width: 240px; }
.gallery figcaption { display: grid; gap: 4px; max-width: 240px; }
.gallery figcaption strong { font-size: 18px; line-height: 1.3; }
.gallery figcaption span { color: var(--soft); font-size: 15px; }
.row { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; }
.row.flip .row-text { order: 2; }
.row-text { display: grid; gap: 18px; justify-items: start; }
.row-shots { display: flex; justify-content: center; align-items: flex-start; gap: 22px; }
.row-shots .shot { width: min(46%, 260px); }
.row-shots .shot + .shot { margin-top: 40px; }
.row-shots.one .shot { width: min(70%, 300px); }
.ticks { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.ticks li { position: relative; padding-left: 34px; font-size: 17px; }
.ticks li::before { content: ""; position: absolute; left: 0; top: 2px; width: 22px; height: 22px; border-radius: 50%; background: #D9EBD9 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%233E8F5A' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 12.5l4 4 8-9'/%3E%3C/svg%3E") center / 14px no-repeat; }
.faq { display: grid; gap: 12px; max-width: 820px; }
.faq details { background: var(--surface); border: 1px solid var(--hair); border-radius: 22px; padding: 0 24px; }
.faq summary { cursor: pointer; padding: 20px 0; font-weight: 700; font-size: 18px; list-style: none; display: flex; justify-content: space-between; align-items: center; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--blue); font-weight: 800; font-size: 26px; line-height: 1; flex: none; }
.faq details[open] summary::after { content: "\2212"; }
.faq p { margin: 0 0 20px; color: var(--soft); }

/* boxes strip (home) */
.boxes { display: grid; grid-template-columns: repeat(6, 1fr); gap: 14px; }
.boxes figure { margin: 0; background: var(--surface); border: 1px solid var(--hair); border-radius: 24px; padding: 14px 8px 12px; text-align: center; }
.boxes img { width: 100%; max-width: 110px; margin: 0 auto; }
.boxes figcaption { font-weight: 700; font-size: 14px; margin-top: 4px; }
.step-n { width: 44px; height: 44px; border-radius: 50%; background: var(--honey); color: #fff; font-family: "Gluten", sans-serif; font-weight: 700; font-size: 22px; display: grid; place-items: center; }
.showcase { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: center; }
.showcase img { border-radius: 26px; box-shadow: var(--shadow); width: 100%; }

/* text pages */
.doc { display: grid; gap: 16px; max-width: 760px; }
.doc .card { padding: 26px 28px; }
.doc .card h3 { font-size: 22px; }

footer { margin: 72px 0 0; padding: 0 0 56px; display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; color: var(--soft); font-weight: 500; font-size: 15px; }
footer nav a { padding: 0 0 0 22px; background: none; color: var(--blue); font-weight: 600; }
footer nav a:hover { background: none; text-decoration: underline; }

/* launch email list (home hero) */
/* The official Google Play badge, in the hero and the "Ready to scroll less?" band. */
.play { display: inline-block; border-radius: 12px; line-height: 0; transition: transform .15s ease; }
.play img { display: block; width: 188px; height: auto; }
.play:hover { transform: translateY(-2px); }
.play:focus-visible { outline: 3px solid var(--blue); outline-offset: 4px; }
.get { display: flex; align-items: center; gap: 24px 32px; flex-wrap: wrap; background: var(--surface); border: 1px solid var(--hair); border-radius: 30px; padding: 24px 32px; box-shadow: 0 10px 24px rgba(58, 42, 31, .08); }
.get > img { width: 96px; height: auto; flex: none; }
.get > div { flex: 1 1 220px; display: grid; gap: 6px; }
.get h2 { margin: 0; }
.get .lead { margin: 0; }
footer .tm { flex-basis: 100%; order: 3; font-size: 13px; font-weight: 400; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.quiet { color: var(--blue); font-weight: 700; text-decoration: none; }
.quiet:hover { text-decoration: underline; }
.note { margin: 18px 0 0; }
.note a { color: var(--blue); font-weight: 700; text-decoration: none; }

@media (max-width: 980px) {
  .hero { grid-template-columns: 1fr; gap: 36px; }
  .cards.four { grid-template-columns: repeat(2, 1fr); }
  .cards.three, .boxes { grid-template-columns: repeat(2, 1fr); }
  .boxes { grid-template-columns: repeat(3, 1fr); }
  .showcase { grid-template-columns: 1fr; }
  .gallery { grid-template-columns: repeat(2, 1fr); row-gap: 36px; }
  .row { grid-template-columns: 1fr; gap: 32px; }
  .row.flip .row-text { order: 0; }
  .banner { grid-template-columns: 1fr; padding: 36px 28px 0; }
  .banner img { width: 190px; justify-self: center; }
}
@media (max-width: 680px) {
  body { font-size: 16px; }
  section { margin-top: 64px; }
  .cards.four, .cards.two, .cards.three { grid-template-columns: 1fr; }
  .boxes { grid-template-columns: repeat(2, 1fr); }
  .bar i { flex: 1 1 0; } .bar span { display: none; }
  .lead { font-size: 18px; }
  .hero-art .stage { width: 100%; } .hero-art .widget { width: 38%; right: -6px; }
  .perm, .data { padding: 22px 20px 24px; }
  .gallery { gap: 16px; }
  .row-shots { gap: 14px; }
  .row-shots .shot { width: 47%; border-radius: 22px; }
  .row-shots.one .shot { width: 72%; }
  .row-shots .shot + .shot { margin-top: 28px; }
  .faq details { padding: 0 18px; }
}

/* pick your level (home): the app's rich card, gradient + ink edge + stitched line + ledge */
.levels { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; align-items: stretch; }
.level { --top: #EEF2FC; --bot: #D5DEF5; --edge: #1F3470; --stitch: #93A5DC; --tag: #2E4BA0;
  position: relative; display: flex; flex-direction: column; align-items: center; text-align: center; padding: 22px 20px 26px; border-radius: 28px;
  background: linear-gradient(180deg, var(--top), var(--bot)); border: 2px solid var(--edge); box-shadow: 0 6px 0 var(--edge); }
.level::before { content: ""; position: absolute; inset: 6px; border: 2px dashed var(--stitch); border-radius: 22px; pointer-events: none; }
.level.medium { --top: #FFE7B8; --bot: #F6C778; --edge: #7A4A12; --stitch: #B9843E; --tag: #9A5B26; }
.level.hard { --top: #FDE6DE; --bot: #F4B8A4; --edge: #7A2A18; --stitch: #C9765E; --tag: #A2381F; }
.level-art { width: 120px; height: auto; margin: 0 auto 6px; display: block; }
.level-name { margin: 0; font-weight: 800; font-size: 14px; letter-spacing: 2px; text-transform: uppercase; color: var(--tag); }
.level h3 { margin: 4px 0 8px; }
.level p { margin: 0 0 18px; }
.level .shot { width: 74%; height: auto; margin-top: auto; } /* all three phones sit at the bottom, whatever the text length */
@media (max-width: 980px) {
  .levels { grid-template-columns: 1fr; max-width: 460px; margin: 0 auto; }
}
