/* Fonts, type scale, screen shell. The kit is served from the repo root
   (npm run serve), so app assets resolve as /demo/assets/... */
@font-face { font-family: "DM Sans"; font-weight: 400; src: url(/demo/assets/fonts/dm_sans/DMSans-Regular.ttf); }
@font-face { font-family: "DM Sans"; font-weight: 500; src: url(/demo/assets/fonts/dm_sans/DMSans-Medium.ttf); }
@font-face { font-family: "DM Sans"; font-weight: 600; src: url(/demo/assets/fonts/dm_sans/DMSans-SemiBold.ttf); }
@font-face { font-family: "DM Sans"; font-weight: 700; src: url(/demo/assets/fonts/dm_sans/DMSans-Bold.ttf); }
@font-face { font-family: "DM Sans"; font-weight: 800; src: url(/demo/assets/fonts/dm_sans/DMSans-Bold.ttf); }

*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: "DM Sans", system-ui, sans-serif;
  color: var(--white);
  background: #144425;
  -webkit-font-smoothing: antialiased;
  font-weight: 500;
}
button { font: inherit; color: inherit; border: 0; background: none; padding: 0; cursor: pointer; }
input, textarea { font: inherit; color: inherit; }
p { margin: 0; }
h1, h2, h3, h4 { margin: 0; font-weight: 600; }

/* Type roles (lib/core/theme/app_typography.dart + app_theme.dart):
   caption 12, small 13, body 15, bodyLarge 16, title 18, titleLarge 22,
   headline 24, headlineLarge 28, display 32. Body medium (500), titles semibold (600). */
.display-l  { font-size: 57px; line-height: 64px; font-weight: 600; }
.display-m  { font-size: 45px; line-height: 52px; font-weight: 600; }
.display-s  { font-size: 36px; line-height: 44px; font-weight: 600; }
.headline-l { font-size: 32px; line-height: 40px; font-weight: 600; }
.headline-m { font-size: 28px; line-height: 36px; font-weight: 600; }
.headline-s { font-size: 24px; line-height: 32px; font-weight: 600; }
.title-l    { font-size: 22px; line-height: 28px; font-weight: 600; }
.title-m    { font-size: 18px; line-height: 24px; font-weight: 600; }
.title-s    { font-size: 15px; line-height: 20px; font-weight: 500; }
.body-l     { font-size: 16px; line-height: 24px; font-weight: 500; }
.body-m     { font-size: 15px; line-height: 20px; font-weight: 500; }
.body-s     { font-size: 13px; line-height: 16px; font-weight: 500; }
.label-l    { font-size: 15px; line-height: 20px; font-weight: 500; }
.label-m    { font-size: 13px; line-height: 16px; font-weight: 500; }
.label-s    { font-size: 12px; line-height: 16px; font-weight: 500; }
.bold { font-weight: 600; }
.normal { font-weight: 500; }
.c-primary { color: var(--accent); }
.c-w80 { color: var(--white-80); }
.c-w60 { color: var(--white-60); }
.c-w40 { color: var(--white-40); }
.c-grey { color: var(--grey-500); }
.c-bg { color: var(--bg); }
.c-error { color: var(--error); }
.ellipsis { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; min-width: 0; }

/* layout helpers */
.row { display: flex; align-items: center; }
.col { display: flex; flex-direction: column; }
.grow { flex: 1 1 0; min-width: 0; }
.between { justify-content: space-between; }
.center { justify-content: center; align-items: center; }
.gap-4 { gap: 4px; } .gap-8 { gap: 8px; } .gap-12 { gap: 12px; } .gap-16 { gap: 16px; } .gap-24 { gap: 24px; }
.px { padding-left: var(--pad); padding-right: var(--pad); }
.pt { padding-top: var(--pad); }
.mt-8 { margin-top: 8px; } .mt-16 { margin-top: 16px; } .mt-24 { margin-top: 24px; } .mt-32 { margin-top: 32px; }
.mb-8 { margin-bottom: 8px; } .mb-16 { margin-bottom: 16px; }
.hidden { display: none !important; }

/* Squircle: Flutter's RoundedSuperellipseBorder ≈ iOS continuous corners.
   corner-shape needs Chromium 139+ (the recorder uses Playwright Chromium);
   other browsers fall back to plain rounded corners. */
.sq { corner-shape: superellipse(1.6); }
@supports not (corner-shape: squircle) { .sq { corner-shape: initial; } }

/* ---------- screen shell ---------- */
.screen {
  position: relative;
  width: var(--screen-w);
  height: var(--screen-h);
  overflow: hidden;
  background: var(--page);
  color: var(--white);
  isolation: isolate;
}
.screen.plain-bg { background: var(--page); }
.statusbar {
  position: absolute; z-index: 50; top: 0; left: 0; right: 0;
  height: var(--safe-top);
  display: flex; align-items: center; justify-content: space-between;
  padding: 6px 30px 0 44px;
  font-size: 16px; font-weight: 600; letter-spacing: -0.2px; color: var(--white);
  pointer-events: none;
}
.statusbar .sb-right { display: flex; gap: 6px; align-items: center; }
.home-indicator {
  position: absolute; z-index: 50; bottom: 8px; left: 50%;
  width: 134px; height: 5px; margin-left: -67px;
  border-radius: 3px; background: currentColor; pointer-events: none;
}
/* the scrollable page body under the status bar */
.page {
  position: absolute; inset: 0;
  padding-top: var(--safe-top);
  overflow-y: auto; overflow-x: hidden;
  scrollbar-width: none;
}
.page::-webkit-scrollbar { display: none; }
.page.no-scroll { overflow: hidden; }
.page-fixed { position: absolute; inset: 0; padding-top: var(--safe-top); display: flex; flex-direction: column; }
.scroll { overflow-y: auto; scrollbar-width: none; flex: 1 1 auto; min-height: 0; }
.scroll::-webkit-scrollbar { display: none; }

/* icons (sprite symbols are injected by kit.js) */
.i { width: 24px; height: 24px; flex: none; display: inline-block; vertical-align: middle; color: currentColor; }
.i-14 { width: 14px; height: 14px; } .i-16 { width: 16px; height: 16px; } .i-18 { width: 18px; height: 18px; }
.i-20 { width: 20px; height: 20px; } .i-28 { width: 28px; height: 28px; } .i-32 { width: 32px; height: 32px; }
.i-40 { width: 40px; height: 40px; } .i-48 { width: 48px; height: 48px; } .i-60 { width: 60px; height: 60px; }
.i-12 { width: 12px; height: 12px; }
.i-24 { width: 24px; height: 24px; }
.i-bold path, .i-bold circle, .i-bold rect, .i-bold line, .i-bold polyline { stroke-width: 2.5; }
/* photo at the very top: light status bar */
.screen.photo-top .statusbar { color: #fff; }
