/* ============================================================
   TinyTot — brand design system (landing + web console)
   ============================================================ */
:root {
  --primary: #5B8DEF;
  --primary-d: #3f6fd1;
  --purple: #9C7BF5;
  --secondary: #FFB347;
  --success: #4CAF8D;
  --danger: #E5697A;
  --teal: #35C2C1;
  --ink: #2D3142;
  --muted: #8A8FA3;
  --line: #E7E9F2;
  --bg: #F7F8FC;
  --card: #FFFFFF;
  --grad: linear-gradient(135deg, #5B8DEF 0%, #9C7BF5 100%);
  --grad-soft: linear-gradient(135deg, rgba(91,141,239,.10), rgba(156,123,245,.10));
  --shadow-sm: 0 1px 2px rgba(45,49,66,.06), 0 1px 3px rgba(45,49,66,.05);
  --shadow: 0 6px 24px rgba(45,49,66,.08);
  --shadow-lg: 0 18px 48px rgba(45,49,66,.16);
  --radius: 16px;
  --radius-sm: 10px;
  --maxw: 1160px;
  --font: 'Nunito', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
.container { max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }

/* ---- logo mark ---- */
.logo { display: inline-flex; align-items: center; gap: 10px; font-weight: 800; font-size: 20px; color: var(--ink); }
.logo .mark {
  width: 34px; height: 34px; border-radius: 11px; background: var(--grad);
  display: grid; place-items: center; box-shadow: 0 4px 12px rgba(91,141,239,.35);
  position: relative; flex: none;
}
.logo .mark::before, .logo .mark::after {
  content: ''; position: absolute; width: 5px; height: 5px; border-radius: 50%; background: #fff; top: 12px;
}
.logo .mark::before { left: 10px; } .logo .mark::after { right: 10px; }
.logo .mark span {
  position: absolute; bottom: 8px; width: 14px; height: 7px; border: 2.5px solid #fff;
  border-top: 0; border-radius: 0 0 14px 14px;
}

/* ---- buttons ---- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-family: var(--font); font-weight: 700; font-size: 15px; cursor: pointer;
  padding: 11px 20px; border-radius: 12px; border: 1.5px solid transparent;
  transition: transform .08s ease, box-shadow .2s ease, background .2s ease; white-space: nowrap;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--primary); color: #fff; box-shadow: 0 6px 16px rgba(91,141,239,.32); }
.btn-primary:hover { background: var(--primary-d); }
.btn-grad { background: var(--grad); color: #fff; box-shadow: 0 8px 20px rgba(91,141,239,.35); }
.btn-grad:hover { filter: brightness(1.04); }
.btn-ghost { background: #fff; color: var(--ink); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--primary); color: var(--primary); }
.btn-light { background: rgba(255,255,255,.16); color: #fff; border-color: rgba(255,255,255,.3); }
.btn-light:hover { background: rgba(255,255,255,.26); }
.btn-danger { background: var(--danger); color: #fff; }
.btn-sm { padding: 7px 14px; font-size: 13px; border-radius: 9px; }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .55; cursor: not-allowed; }

/* ============================================================
   LANDING
   ============================================================ */
.nav {
  position: sticky; top: 0; z-index: 50; background: rgba(247,248,252,.82);
  backdrop-filter: saturate(180%) blur(12px); border-bottom: 1px solid var(--line);
}
.nav .container { display: flex; align-items: center; gap: 28px; height: 68px; }
.nav .links { display: flex; gap: 26px; margin-left: 10px; }
.nav .links a { color: var(--muted); font-weight: 700; font-size: 15px; }
.nav .links a:hover { color: var(--ink); }
.nav .spacer { flex: 1; }
.nav .cta { display: flex; gap: 10px; align-items: center; }

.hero { padding: 70px 0 40px; position: relative; overflow: hidden; }
.hero::after {
  content: ''; position: absolute; inset: 0; z-index: -1;
  background: radial-gradient(60% 50% at 80% 0%, rgba(156,123,245,.14), transparent 60%),
              radial-gradient(50% 45% at 5% 10%, rgba(91,141,239,.12), transparent 60%);
}
.hero .container { display: grid; grid-template-columns: 1.05fr .95fr; gap: 48px; align-items: center; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px; font-weight: 800; font-size: 13px;
  color: var(--primary); background: var(--grad-soft); padding: 6px 14px; border-radius: 999px; margin-bottom: 18px;
}
.hero h1 { font-size: 52px; line-height: 1.08; font-weight: 800; letter-spacing: -.5px; }
.hero h1 .grad { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero p.sub { font-size: 19px; color: var(--muted); margin: 20px 0 28px; max-width: 520px; }
.hero .cta-row { display: flex; gap: 14px; flex-wrap: wrap; align-items: center; }
.hero .note { margin-top: 16px; color: var(--muted); font-size: 14px; display: flex; gap: 18px; flex-wrap: wrap; }
.hero .note b { color: var(--ink); }

/* hero mock */
.mock {
  background: #fff; border-radius: 20px; box-shadow: var(--shadow-lg); border: 1px solid var(--line);
  overflow: hidden; transform: rotate(.6deg);
}
.mock .bar { height: 40px; background: #fff; border-bottom: 1px solid var(--line); display: flex; align-items: center; gap: 6px; padding: 0 14px; }
.mock .bar i { width: 11px; height: 11px; border-radius: 50%; background: #e2e5f0; display: inline-block; }
.mock .body { padding: 18px; background: var(--bg); }
.mock .row { display: grid; grid-template-columns: repeat(2,1fr); gap: 12px; }
.mock .tile { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 14px; }
.mock .tile .k { font-size: 12px; color: var(--muted); font-weight: 700; }
.mock .tile .v { font-size: 26px; font-weight: 800; margin-top: 4px; }
.mock .tile .ic { width: 30px; height: 30px; border-radius: 8px; display: grid; place-items: center; margin-bottom: 8px; font-size: 16px; }
.mock .barrow { display: flex; gap: 4px; margin-top: 14px; height: 12px; }
.mock .barrow i { border-radius: 4px; }

/* section */
.section { padding: 72px 0; }
.section.alt { background: #fff; }
.section-head { text-align: center; max-width: 660px; margin: 0 auto 44px; }
.section-head .eyebrow { margin-bottom: 14px; }
.section-head h2 { font-size: 38px; font-weight: 800; letter-spacing: -.5px; }
.section-head p { color: var(--muted); font-size: 18px; margin-top: 12px; }

/* features */
.feat-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 20px; }
.feat {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 26px;
  transition: transform .15s ease, box-shadow .2s ease;
}
.section.alt .feat { background: var(--bg); }
.feat:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.feat .ic { width: 48px; height: 48px; border-radius: 13px; display: grid; place-items: center; font-size: 24px; margin-bottom: 16px; }
.feat h3 { font-size: 18px; font-weight: 800; margin-bottom: 8px; }
.feat p { color: var(--muted); font-size: 15px; }

/* loops / how it works */
.loops { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.loop { border-radius: var(--radius); padding: 32px; color: #fff; position: relative; overflow: hidden; }
.loop.daily { background: linear-gradient(135deg, #5B8DEF, #35C2C1); }
.loop.revenue { background: linear-gradient(135deg, #9C7BF5, #E5697A); }
.loop h3 { font-size: 22px; font-weight: 800; margin-bottom: 18px; }
.loop ol { list-style: none; display: flex; flex-direction: column; gap: 12px; }
.loop li { display: flex; align-items: center; gap: 12px; font-weight: 700; font-size: 15px; }
.loop li .n { width: 28px; height: 28px; border-radius: 8px; background: rgba(255,255,255,.22); display: grid; place-items: center; font-size: 13px; flex: none; }

/* roles */
.roles { display: grid; grid-template-columns: repeat(4,1fr); gap: 18px; }
.role { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.section.alt .role { background: var(--bg); }
.role .tag { font-size: 22px; margin-bottom: 12px; }
.role h4 { font-size: 17px; font-weight: 800; margin-bottom: 10px; }
.role ul { list-style: none; display: flex; flex-direction: column; gap: 7px; }
.role li { color: var(--muted); font-size: 14px; padding-left: 20px; position: relative; }
.role li::before { content: '✓'; position: absolute; left: 0; color: var(--success); font-weight: 800; }

/* screenshots */
.shots { display: flex; gap: 18px; overflow-x: auto; padding: 6px 0 16px; scroll-snap-type: x mandatory; }
.shots img { width: 230px; flex: none; border-radius: 22px; box-shadow: var(--shadow); border: 1px solid var(--line); scroll-snap-align: center; }

/* pricing */
.price-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 20px; align-items: stretch; }
.price {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 30px; display: flex; flex-direction: column;
}
.price.featured { border: 2px solid var(--primary); box-shadow: var(--shadow); position: relative; }
.price.featured .badge { position: absolute; top: -12px; left: 50%; transform: translateX(-50%); background: var(--grad); color: #fff; font-size: 12px; font-weight: 800; padding: 4px 14px; border-radius: 999px; }
.price h4 { font-size: 18px; font-weight: 800; }
.price .amt { font-size: 40px; font-weight: 800; margin: 12px 0 2px; }
.price .amt small { font-size: 15px; color: var(--muted); font-weight: 700; }
.price .desc { color: var(--muted); font-size: 14px; margin-bottom: 18px; }
.price ul { list-style: none; display: flex; flex-direction: column; gap: 10px; margin-bottom: 24px; flex: 1; }
.price li { font-size: 14px; padding-left: 24px; position: relative; }
.price li::before { content: '✓'; position: absolute; left: 0; color: var(--success); font-weight: 800; }

/* cta band */
.cta-band { background: var(--grad); border-radius: 28px; padding: 56px; text-align: center; color: #fff; box-shadow: var(--shadow-lg); }
.cta-band h2 { font-size: 34px; font-weight: 800; }
.cta-band p { font-size: 18px; opacity: .92; margin: 12px 0 26px; }

/* footer */
.footer { padding: 48px 0; border-top: 1px solid var(--line); color: var(--muted); }
.footer .container { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 16px; }
.footer .links { display: flex; gap: 22px; }
.footer .links a:hover { color: var(--ink); }

@media (max-width: 900px) {
  .hero .container { grid-template-columns: 1fr; }
  .hero h1 { font-size: 40px; }
  .feat-grid, .roles, .price-grid, .loops { grid-template-columns: 1fr; }
  .nav .links { display: none; }
  .section-head h2 { font-size: 30px; }
}

/* ============================================================
   WEB CONSOLE
   ============================================================ */
.login-wrap { min-height: 100vh; display: grid; place-items: center; padding: 24px;
  background: radial-gradient(60% 50% at 80% 0%, rgba(156,123,245,.12), transparent 60%),
              radial-gradient(50% 45% at 5% 100%, rgba(91,141,239,.12), transparent 60%), var(--bg); }
.login-card { width: 100%; max-width: 410px; background: #fff; border: 1px solid var(--line);
  border-radius: 22px; box-shadow: var(--shadow-lg); padding: 36px; }
.login-card .logo { font-size: 26px; justify-content: center; margin-bottom: 6px; }
.login-card .logo .mark { width: 44px; height: 44px; border-radius: 14px; }
.login-card .logo .mark::before, .login-card .logo .mark::after { top: 16px; }
.login-card .logo .mark span { bottom: 11px; }
.login-card .tag { text-align: center; color: var(--muted); margin-bottom: 24px; }
.field { margin-bottom: 14px; }
.field label { display: block; font-size: 13px; font-weight: 700; color: var(--muted); margin-bottom: 6px; }
.input, select.input, textarea.input {
  width: 100%; font-family: var(--font); font-size: 15px; color: var(--ink);
  padding: 11px 14px; border: 1.5px solid var(--line); border-radius: 11px; background: #fff; transition: border .15s; }
.input:focus { outline: none; border-color: var(--primary); }
textarea.input { resize: vertical; min-height: 76px; }
.demo-chips { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin-top: 8px; }
.chip { font-size: 13px; font-weight: 700; padding: 7px 12px; border-radius: 10px; border: 1.5px solid var(--line);
  background: #fff; cursor: pointer; transition: .15s; }
.chip:hover { border-color: var(--primary); color: var(--primary); }
.divider-txt { text-align: center; color: var(--muted); font-size: 13px; margin: 20px 0 10px; }

/* app shell */
.shell { display: grid; grid-template-columns: 244px 1fr; min-height: 100vh; }
.side { background: #fff; border-right: 1px solid var(--line); display: flex; flex-direction: column; position: sticky; top: 0; height: 100vh; }
.side .brand { padding: 20px 20px 14px; border-bottom: 1px solid var(--line); }
.side nav { padding: 12px; flex: 1; overflow-y: auto; }
.side nav a { display: flex; align-items: center; gap: 11px; padding: 10px 12px; border-radius: 11px;
  color: var(--muted); font-weight: 700; font-size: 14.5px; margin-bottom: 2px; cursor: pointer; }
.side nav a .ic { width: 20px; text-align: center; }
.side nav a:hover { background: var(--bg); color: var(--ink); }
.side nav a.active { background: var(--grad-soft); color: var(--primary); }
.side .who { padding: 14px; border-top: 1px solid var(--line); }
.side .who .name { font-weight: 800; font-size: 14px; }
.side .who .sub { font-size: 12px; color: var(--muted); margin-bottom: 10px; }
.main { min-width: 0; }
.topbar { height: 64px; background: rgba(247,248,252,.85); backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line); display: flex; align-items: center; gap: 16px; padding: 0 28px; position: sticky; top: 0; z-index: 20; }
.topbar h1 { font-size: 21px; font-weight: 800; }
.topbar .spacer { flex: 1; }
.content { padding: 26px 28px 48px; }

/* cards / stat */
.cards { display: grid; grid-template-columns: repeat(4,1fr); gap: 16px; margin-bottom: 22px; }
.stat { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; }
.stat .ic { width: 38px; height: 38px; border-radius: 11px; display: grid; place-items: center; font-size: 18px; margin-bottom: 12px; }
.stat .v { font-size: 26px; font-weight: 800; }
.stat .k { color: var(--muted); font-size: 13px; font-weight: 700; }
.panel { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); margin-bottom: 20px; overflow: hidden; }
.panel .ph { display: flex; align-items: center; gap: 12px; padding: 16px 20px; border-bottom: 1px solid var(--line); }
.panel .ph h3 { font-size: 16px; font-weight: 800; flex: 1; }
.panel .pb { padding: 8px 0; }

/* table */
table.tbl { width: 100%; border-collapse: collapse; }
table.tbl th { text-align: left; font-size: 12px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); font-weight: 800; padding: 10px 20px; }
table.tbl td { padding: 13px 20px; border-top: 1px solid var(--line); font-size: 14.5px; vertical-align: middle; }
table.tbl tr:hover td { background: #fbfcff; }
.avatar { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; font-size: 15px; flex: none; }
.cellrow { display: flex; align-items: center; gap: 10px; }

/* badges / chips */
.badge { display: inline-block; font-size: 12px; font-weight: 800; padding: 4px 10px; border-radius: 8px; }
.toolbar { display: flex; gap: 10px; align-items: center; margin-bottom: 16px; flex-wrap: wrap; }
.toolbar .spacer { flex: 1; }
.seg { display: inline-flex; background: #fff; border: 1px solid var(--line); border-radius: 11px; padding: 3px; gap: 2px; }
.seg button { border: 0; background: none; font-family: var(--font); font-weight: 700; font-size: 13.5px; color: var(--muted);
  padding: 7px 14px; border-radius: 9px; cursor: pointer; }
.seg button.active { background: var(--grad-soft); color: var(--primary); }

/* modal */
.modal-bg { position: fixed; inset: 0; background: rgba(45,49,66,.45); backdrop-filter: blur(2px); display: grid; place-items: center; z-index: 100; padding: 20px; }
.modal { background: #fff; border-radius: 20px; box-shadow: var(--shadow-lg); width: 100%; max-width: 480px; max-height: 90vh; overflow-y: auto; }
.modal .mh { padding: 22px 24px 0; }
.modal .mh h3 { font-size: 19px; font-weight: 800; }
.modal .mh p { color: var(--muted); font-size: 14px; margin-top: 4px; }
.modal .mb { padding: 18px 24px; }
.modal .mf { padding: 0 24px 22px; display: flex; gap: 10px; justify-content: flex-end; }

/* toast */
.toasts { position: fixed; bottom: 22px; right: 22px; display: flex; flex-direction: column; gap: 10px; z-index: 200; }
.toast { background: var(--ink); color: #fff; padding: 13px 18px; border-radius: 12px; font-weight: 700; font-size: 14px; box-shadow: var(--shadow-lg); animation: slideIn .2s ease; }
.toast.err { background: var(--danger); } .toast.ok { background: var(--success); }
@keyframes slideIn { from { transform: translateY(10px); opacity: 0; } }

/* misc */
.empty { text-align: center; color: var(--muted); padding: 50px 20px; }
.empty .big { font-size: 40px; margin-bottom: 10px; }
.spin { width: 30px; height: 30px; border: 3px solid var(--line); border-top-color: var(--primary); border-radius: 50%; animation: rot 1s linear infinite; margin: 50px auto; }
@keyframes rot { to { transform: rotate(360deg); } }
.muted { color: var(--muted); } .mini { font-size: 12.5px; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.progress { height: 12px; border-radius: 6px; background: var(--line); overflow: hidden; display: flex; }
@media (max-width: 820px) {
  .shell { grid-template-columns: 1fr; }
  .side { position: fixed; left: -260px; z-index: 60; transition: left .2s; width: 244px; }
  .side.open { left: 0; }
  .cards { grid-template-columns: 1fr 1fr; }
  .grid2 { grid-template-columns: 1fr; }
}
.burger { display: none; } @media (max-width: 820px) { .burger { display: inline-flex; } }
