:root{
  --primary:#0A1628; --accent:#2962FF;
  --grad-start:#2962FF; --grad-mid:#7C3AED; --grad-end:#EC4899;
  --bg:#F0F2F5; --card:#FFFFFF;
  --text:#0A1628; --text2:#64748B; --text3:#94A3B8;
  --border:#E2E8F0;
  --success:#22C55E; --danger:#EF4444; --warning:#F59E0B;
  --nav-height: 64px;
  --app-height: 100vh;   /* перезапишется из JS */
}
*{box-sizing:border-box;margin:0;padding:0;-webkit-tap-highlight-color:transparent}
html{
  height:100%;
  overflow-x:hidden;
  -webkit-text-size-adjust:100%;
  text-size-adjust:100%;
}
body{
  height:100%;
  overflow-x:hidden;
  font-family:'Inter',system-ui,-apple-system,'Segoe UI',Roboto,sans-serif;
  background:#E2E8F0;
  color:var(--text);
  -webkit-font-smoothing:antialiased;
  -moz-osx-font-smoothing:grayscale;
  overscroll-behavior-y:none;
}
#app{
  max-width:480px;
  width:100%;
  margin:0 auto;
  /* Фоллбэк для браузеров без dvh */
  min-height: 100vh;
  min-height: var(--app-height, 100vh);
  background:var(--bg);
  position:relative;
  /* Отступ снизу под нижнее меню + safe-area */
  padding-bottom: calc(var(--nav-height) + 16px + env(safe-area-inset-bottom, 0px));
  overflow-x:hidden;
  box-shadow:0 0 40px rgba(10,22,40,.08);
  display:flex;
  flex-direction:column;
}
#app.no-pad{
  padding-bottom:0;
  min-height: 100vh;
  min-height: var(--app-height, 100vh);
}