:root{font-family:Inter,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;color:#182230;background:#f5f7fb;font-synthesis:none;--primary:#3157d5;--primary-dark:#2343b0;--muted:#687386;--border:#e5e9f2;--card:#fff;--green:#12805c;--red:#c43d4b}
*{box-sizing:border-box}body{margin:0;min-height:100vh}a{color:var(--primary);text-decoration:none}button,input,textarea,select{font:inherit}button,.btn{border:0;border-radius:11px;background:var(--primary);color:#fff;padding:11px 16px;font-weight:700;cursor:pointer;display:inline-flex;align-items:center;justify-content:center;gap:7px}button:hover,.btn:hover{background:var(--primary-dark)}button:disabled{opacity:.55;cursor:not-allowed}.btn.secondary,button.secondary{background:#eef2ff;color:#2948ad}.btn.ghost,button.ghost{background:transparent;color:var(--muted);border:1px solid var(--border)}.btn.danger,button.danger{background:#fff0f1;color:var(--red)}.container{width:min(1120px,calc(100% - 32px));margin:auto}.topbar{height:72px;background:#fff;border-bottom:1px solid var(--border);display:flex;align-items:center}.topbar-inner{display:flex;align-items:center;justify-content:space-between;gap:16px}.brand{font-size:21px;font-weight:850;color:#182230;letter-spacing:-.6px}.brand span{color:var(--primary)}.navlinks{display:flex;gap:18px;align-items:center;color:var(--muted);font-size:14px}.hero{padding:70px 0 54px;display:grid;grid-template-columns:1.2fr .8fr;gap:42px;align-items:center}.eyebrow{display:inline-block;background:#e9edff;color:#2948ad;padding:7px 11px;border-radius:999px;font-size:12px;font-weight:800;letter-spacing:.04em}.hero h1{font-size:clamp(38px,6vw,62px);line-height:1.06;letter-spacing:-2.5px;margin:18px 0}.hero p{font-size:17px;line-height:1.7;color:var(--muted);max-width:590px}.hero-actions{display:flex;gap:12px;flex-wrap:wrap;margin-top:24px}.hero-card,.card,.auth-card,.stat-card{background:var(--card);border:1px solid var(--border);border-radius:18px;padding:23px;box-shadow:0 8px 30px #17255408}.hero-card{padding:28px}.hero-card h3{margin:0 0 8px}.muted{color:var(--muted)}.small{font-size:13px}.section{padding:30px 0 58px}.section-title{display:flex;align-items:end;justify-content:space-between;gap:20px;margin-bottom:20px}.section-title h2{margin:0;font-size:26px;letter-spacing:-.7px}.grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:16px}.survey-card{display:flex;flex-direction:column;gap:12px}.survey-card h3{margin:0}.survey-card p{color:var(--muted);line-height:1.55;margin:0;flex:1}.reward{font-weight:850;color:var(--green)}.pill{display:inline-flex;padding:5px 9px;border-radius:999px;font-size:12px;font-weight:750;background:#edf0f7;color:#566174}.pill.pending{background:#fff4d8;color:#875b00}.pill.approved,.pill.paid,.pill.active{background:#e2f8ee;color:#08744f}.pill.rejected,.pill.suspended{background:#ffe9ec;color:#b5263b}.footer{padding:26px 0;border-top:1px solid var(--border);color:var(--muted);font-size:13px}.auth-wrap{min-height:calc(100vh - 72px);display:grid;place-items:center;padding:36px 16px}.auth-card{width:min(450px,100%);padding:30px}.auth-card h1{margin:0 0 8px}.field{display:flex;flex-direction:column;gap:7px;margin:16px 0}.field label{font-size:13px;font-weight:750;color:#3e4858}.field input,.field textarea,.field select{width:100%;border:1px solid #dce2ee;border-radius:10px;padding:12px 13px;background:#fff;color:#182230;outline:none}.field input:focus,.field textarea:focus,.field select:focus{border-color:var(--primary);box-shadow:0 0 0 3px #3157d51c}.field textarea{min-height:100px;resize:vertical}.form-error,.notice{padding:11px 13px;border-radius:10px;background:#fff0f1;color:#b5263b;font-size:13px}.notice.success{background:#e2f8ee;color:#08744f}.hidden{display:none!important}.empty{padding:30px;text-align:center;color:var(--muted);border:1px dashed #d7ddea;border-radius:14px}.table-wrap{overflow:auto;border:1px solid var(--border);border-radius:14px;background:#fff}table{width:100%;border-collapse:collapse;min-width:680px}th,td{text-align:left;padding:13px 15px;border-bottom:1px solid var(--border);font-size:13px;vertical-align:top}th{background:#f9faff;color:#667085;font-size:11px;text-transform:uppercase;letter-spacing:.06em}tr:last-child td{border-bottom:0}.inline-form{display:flex;gap:10px;flex-wrap:wrap}.inline-form input{flex:1;min-width:150px}.bottomnav{display:none}.loading{padding:25px;color:var(--muted)}.question{padding:17px 0;border-bottom:1px solid var(--border)}.question:last-child{border-bottom:0}.option{display:flex;gap:9px;align-items:center;margin:10px 0;color:#485366}.option input{width:auto}.admin-shell{display:grid;grid-template-columns:220px minmax(0,1fr);gap:22px;padding-top:28px;padding-bottom:50px}.sidebar{align-self:start;position:sticky;top:18px}.sidebar a{display:block;padding:11px 12px;border-radius:10px;color:#566174;margin:3px 0}.sidebar a.active,.sidebar a:hover{background:#e9edff;color:#2948ad}.content{min-width:0}.page-head{display:flex;align-items:center;justify-content:space-between;gap:16px;margin:4px 0 24px}.page-head h1{margin:0;font-size:28px;letter-spacing:-.7px}.stat-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px;margin-bottom:20px}.stat-card .label{color:var(--muted);font-size:13px}.stat-card .value{font-size:28px;font-weight:850;margin-top:10px}.stack{display:grid;gap:14px}.actions{display:flex;gap:7px;flex-wrap:wrap}.actions button{padding:8px 10px;font-size:12px}.mono{font-family:ui-monospace,SFMono-Regular,monospace;overflow-wrap:anywhere}
@media(max-width:800px){.hero{grid-template-columns:1fr;padding:45px 0 30px}.grid{grid-template-columns:repeat(2,minmax(0,1fr))}.admin-shell{grid-template-columns:1fr}.sidebar{position:static;display:flex;overflow:auto;gap:4px;padding-bottom:5px}.sidebar a{white-space:nowrap}.stat-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.navlinks{gap:10px}.navlinks a:not(.btn){display:none}}
@media(max-width:560px){.container{width:min(100% - 24px,1120px)}.topbar{height:62px}.grid{grid-template-columns:1fr}.hero h1{letter-spacing:-1.5px}.hero-card,.card,.auth-card{padding:19px}.section-title{align-items:start;flex-direction:column}.stat-grid{gap:9px}.stat-card{padding:15px}.stat-card .value{font-size:23px}.bottomnav{display:flex;position:fixed;z-index:10;bottom:0;left:0;right:0;background:#fff;border-top:1px solid var(--border);padding:7px 5px calc(7px + env(safe-area-inset-bottom));justify-content:space-around}.bottomnav a{font-size:10px;color:#687386;display:grid;gap:3px;text-align:center;min-width:0}.bottomnav a span{font-size:18px}.bottomnav a.active{color:var(--primary);font-weight:800}body.has-bottomnav{padding-bottom:75px}.page-head{align-items:start;flex-direction:column}.auth-wrap{min-height:calc(100vh - 62px)}}

/* Theme variables and dark mode */
:root{color-scheme:light;--page:#f5f7fb;--text:#182230;--surface:#fff;--surface-soft:#f9faff;--field-bg:#fff;--field-border:#dce2ee;--nav-bg:#fff;--table-head:#f9faff;--secondary-bg:#eef2ff;--secondary-text:#2948ad}
body{background:var(--page);color:var(--text)}
.topbar,.bottomnav{background:var(--nav-bg)}
.brand{color:var(--text)}
.hero-card,.card,.auth-card,.stat-card,.table-wrap{background:var(--surface)}
.field label{color:var(--text)}
.field input,.field textarea,.field select{background:var(--field-bg);color:var(--text);border-color:var(--field-border)}
th{background:var(--table-head)}
.btn.secondary,button.secondary{background:var(--secondary-bg);color:var(--secondary-text)}
.theme-toggle{flex-shrink:0;min-width:42px;width:42px;height:42px;padding:0;border:1px solid var(--border);border-radius:12px;background:var(--surface);color:var(--text);font-size:18px}
.theme-toggle:hover{background:var(--secondary-bg)}
html[data-theme="dark"]{color-scheme:dark;--page:#0b1020;--text:#e7ecf5;--surface:#121a2b;--surface-soft:#172136;--field-bg:#0d1525;--field-border:#2b3850;--nav-bg:#101829;--border:#28344a;--table-head:#172136;--muted:#a1aec3;--secondary-bg:#202e4b;--secondary-text:#c4d2ff;--green:#54d6a3;--red:#ff7c8b}
html[data-theme="dark"] .topbar{border-color:var(--border)}
html[data-theme="dark"] .brand{color:var(--text)}
html[data-theme="dark"] .eyebrow{background:#202e4b;color:#c4d2ff}
html[data-theme="dark"] .pill{background:#263248;color:#c8d1e1}
html[data-theme="dark"] .pill.pending{background:#493a1c;color:#ffd98a}
html[data-theme="dark"] .pill.approved,html[data-theme="dark"] .pill.paid,html[data-theme="dark"] .pill.active{background:#153d35;color:#7ee7bd}
html[data-theme="dark"] .pill.rejected,html[data-theme="dark"] .pill.suspended{background:#48242d;color:#ff9aa6}
html[data-theme="dark"] .btn.danger,html[data-theme="dark"] button.danger{background:#48242d;color:#ff9aa6}
html[data-theme="dark"] .table-wrap{border-color:var(--border)}
html[data-theme="dark"] td,html[data-theme="dark"] th{border-color:var(--border)}
html[data-theme="dark"] .quick-link{color:var(--text)}
html[data-theme="dark"] .quick-link .icon{background:#202e4b}
html[data-theme="dark"] .json-hint{background:var(--surface-soft);color:var(--muted)}
html[data-theme="dark"] .sidebar a{color:var(--muted)}
html[data-theme="dark"] .sidebar a.active,html[data-theme="dark"] .sidebar a:hover{background:#202e4b;color:#c4d2ff}
html[data-theme="dark"] .option{color:var(--muted)}
html[data-theme="dark"] .empty{border-color:var(--border)}
html[data-theme="dark"] .notice.success{background:#153d35;color:#7ee7bd}
html[data-theme="dark"] .form-error,html[data-theme="dark"] .notice{background:#48242d;color:#ff9aa6}
html[data-theme="dark"] .footer{border-color:var(--border)}
html[data-theme="dark"] section[style*="background:#fff"]{background:var(--page)!important}

html[data-theme="dark"] .admin-label{color:var(--muted)}
html[data-theme="dark"] .json-hint{background:var(--surface-soft);color:var(--muted)}
html[data-theme="dark"] .table-wrap{background:var(--surface)}
html[data-theme="dark"] .bottomnav{border-color:var(--border)}
html[data-theme="dark"] .bottomnav a{color:var(--muted)}
html[data-theme="dark"] .bottomnav a.active{color:var(--secondary-text)}


/* OAuth sign-in options */
.oauth-divider{display:flex;align-items:center;gap:12px;color:var(--muted);font-size:12px;margin:20px 0 14px}
.oauth-divider:before,.oauth-divider:after{content:"";height:1px;background:var(--border);flex:1}
.oauth-options{display:grid;gap:10px;margin-bottom:18px}
.oauth-btn{display:flex;align-items:center;justify-content:center;gap:10px;width:100%;min-height:46px;border:1px solid var(--border);border-radius:11px;background:var(--surface);color:var(--text);font-weight:750;padding:10px 14px}
.oauth-btn:hover{background:var(--surface-soft)}
.oauth-icon{display:grid;place-items:center;width:23px;height:23px;border-radius:50%;background:#fff;color:#4285f4;border:1px solid #e5e7eb;font-weight:900}
.telegram-oauth{display:flex;justify-content:center;min-height:44px;overflow:hidden}
.telegram-oauth iframe{max-width:100%}
.oauth-note{margin:0;text-align:center;line-height:1.5}
