*{box-sizing:border-box}
body{margin:0;background:#07101e;color:#eef3f8;font-family:Inter,Arial,sans-serif}
a{text-decoration:none;color:inherit}
.wrap{width:min(1180px,calc(100% - 28px));margin:auto}

.topbar{background:#091321;border-bottom:1px solid #ffffff12;position:sticky;top:0;z-index:20}
.topbar-inner{min-height:68px;display:flex;justify-content:space-between;align-items:center}
.brand{display:flex;align-items:center;gap:10px}
.brand>span{width:40px;height:40px;border-radius:11px;background:linear-gradient(135deg,#7051ff,#9968ff);display:grid;place-items:center;font-size:11px;font-weight:900}
.brand div{display:grid}
.brand b{font-size:14px}
.brand small{font-size:8px;color:#748197}
nav{display:flex;gap:7px}
nav a{font-size:9px;font-weight:800;padding:8px 10px;border:1px solid #ffffff12;border-radius:7px;color:#c4cddb}
.logout{background:#7253ff;color:#fff!important}

.main{padding:28px 0 60px}
.page-title{display:flex;justify-content:space-between;align-items:end;margin-bottom:17px}
.eyebrow{font-size:8px;letter-spacing:.15em;color:#78869b;font-weight:900}
.page-title h1{font-size:34px;margin:4px 0 0}
.market-status{font-size:8px;font-weight:900;padding:8px 10px;border-radius:999px;border:1px solid #ffffff14}
.market-status.open{color:#63ddb1}
.market-status.open_result{color:#ebcf65}
.market-status.complete{color:#72b8ff}
.market-status.closed{background:#401824;color:#ff8a9a}

.card{background:linear-gradient(180deg,#111d31,#0e1829);border:1px solid #ffffff12;border-radius:15px;padding:18px;box-shadow:0 14px 40px #0003}

.date-panel{
  margin-bottom:15px;
  background:linear-gradient(135deg,#101d32,#132441);
  border:1px solid #7558ff55;
  border-radius:15px;
  padding:17px 19px;
  display:grid;
  grid-template-columns:auto 1fr auto;
  align-items:end;
  gap:18px;
}
.date-heading{display:flex;align-items:center;gap:10px}
.date-heading>span{width:32px;height:32px;border-radius:9px;background:#7558ff;display:grid;place-items:center;font-size:10px;font-weight:900}
.date-heading small{display:block;font-size:7px;color:#8996a9;font-weight:900;letter-spacing:.12em}
.date-heading h2{margin:3px 0 0;font-size:21px}
.date-form{display:flex;align-items:end;gap:8px}
.date-form input{min-width:220px}
.date-day{font-size:11px;color:#9eabbc;font-weight:800;padding-bottom:10px}

label{display:grid;gap:6px;color:#95a2b5;font-size:8px;font-weight:900}
input,select{background:#091321;color:#fff;border:1px solid #ffffff12;border-radius:8px;padding:10px 11px;outline:none;width:100%}
input:focus,select:focus{border-color:#765aff}

.btn{border:0;border-radius:8px;color:#fff;padding:11px 13px;font-size:9px;font-weight:900;cursor:pointer}
.primary,.purple{background:linear-gradient(135deg,#7051ff,#9869ff)}
.secondary{background:#1a2941}
.blue{background:linear-gradient(135deg,#2566d9,#4988ff)}
.green{background:linear-gradient(135deg,#149b73,#28c198)}
.band{background:linear-gradient(135deg,#b51f3c,#f04d65);font-size:11px}
.band small{display:block;font-size:8px;margin-top:3px;opacity:.9}
.full{width:100%}

.publish-layout{display:grid;grid-template-columns:1.2fr .8fr;gap:15px;margin-bottom:15px}
.section-head{display:flex;justify-content:space-between;align-items:flex-start;margin-bottom:15px}
.section-head h2{font-size:20px;margin:4px 0 0}
.main-publisher form{display:grid;gap:11px}
.input-grid{display:grid;grid-template-columns:1fr .38fr 1fr .38fr;gap:8px;align-items:end}

.ank-card{background:#091321;border:1px solid #ffffff0f;border-radius:8px;padding:10px;display:grid;text-align:center}
.ank-card span{font-size:7px;color:#758397}
.ank-card strong{font-size:23px}

.jodi-preview-box{background:#091321;border:1px solid #ffffff0f;border-radius:10px;padding:13px;display:grid;text-align:center;gap:3px}
.jodi-preview-box span{font-size:8px;color:#758397;font-weight:900}
.jodi-preview-box strong{font-size:38px;color:#ff6479}
.jodi-preview-box small{font-size:7px;color:#647286}
.publish-buttons{display:grid;grid-template-columns:1fr 1fr;gap:8px}

.preview-card h2{margin:4px 0 12px}
.public-result{min-height:105px;background:#091321;border:1px solid #ffffff0f;border-radius:11px;display:flex;align-items:center;justify-content:center;gap:7px;font-size:25px}
.public-result strong{font-size:37px}
.public-result strong.red{color:#ff5268}
.public-result strong.green{color:#4cdbad}
.public-result strong.blue{color:#73a6ff}
.market-control-title{font-size:8px;color:#748196;font-weight:900;letter-spacing:.12em;margin:15px 0 7px}
.market-buttons{display:grid;grid-template-columns:.75fr 1.25fr;gap:8px}
.band-help{font-size:8px;line-height:1.5;color:#7f8da1;margin:9px 0 0}
.band-help strong{color:#ff8595}

.history{margin-bottom:15px}
.history .section-head a{font-size:8px;color:#aa98ff;font-weight:900}
.table-scroll{overflow:auto}
table{width:100%;min-width:950px;border-collapse:collapse}
th,td{text-align:left;padding:9px 7px;border-bottom:1px solid #ffffff0d}
th{font-size:7px;color:#6e7c91;letter-spacing:.08em}
td{font-size:9px;color:#bec8d6}
.date-link{color:#a996ff;font-weight:900}
.jodi{font-size:14px}
.jodi.red{color:#ff5268}
.jodi.green{color:#4cdbad}
.jodi.blue{color:#73a6ff}

.history-market{font-size:7px;font-weight:900}
.history-market.closed{color:#ff8292}
.history-market.complete{color:#72b8ff}
.history-market.open_result{color:#e5cb65}
.history-market.open{color:#63dcb0}

.actions{display:flex;gap:4px}
.actions form{margin:0}
.mini{font-size:7px;font-weight:900;padding:5px 7px;border:1px solid #ffffff12;border-radius:5px;background:#17243a;color:#bec8d6;cursor:pointer}
.danger{background:#381b24;color:#ff8393}

.security summary{cursor:pointer;font-size:11px;font-weight:900}
.security[open] summary{margin-bottom:12px}
.security form{display:grid;grid-template-columns:1fr 1fr 1fr auto;gap:8px;align-items:end}

.alert{padding:10px 12px;border-radius:8px;margin-bottom:13px;font-size:9px;font-weight:900}
.alert.success{background:#12392e;color:#73dfba}
.alert.error{background:#381a23;color:#ff8d9c}

.login-bg{min-height:100vh;background:radial-gradient(circle at top,#142a4c,#07101e 55%)}
.login-shell{min-height:100vh;display:grid;place-items:center}
.login-card{width:min(400px,calc(100% - 30px));background:#111d31;border:1px solid #ffffff12;border-radius:16px;padding:24px;display:grid;gap:13px;text-align:center}
.login-card .logo{width:50px;height:50px;border-radius:14px;background:linear-gradient(135deg,#7051ff,#9968ff);display:grid;place-items:center;margin:auto;font-weight:900}
.login-card h1{margin:0}
.login-card p{margin:0;color:#7e8ca0;font-size:9px}
.login-card label{text-align:left}
.login-card>a{font-size:8px;color:#8492a5}

@media(max-width:850px){
  .publish-layout{grid-template-columns:1fr}
  .input-grid{grid-template-columns:1fr 1fr}
  .security form{grid-template-columns:1fr}
  .date-panel{grid-template-columns:1fr}
}
@media(max-width:560px){
  .wrap{width:calc(100% - 18px)}
  .topbar-inner{padding:10px 0;align-items:flex-start}
  .brand b{display:none}
  nav{flex-wrap:wrap}
  .page-title{flex-direction:column;align-items:flex-start;gap:9px}
  .page-title h1{font-size:28px}
  .date-form{flex-direction:column;align-items:stretch}
  .date-form input{min-width:0}
  .input-grid{grid-template-columns:1fr}
  .publish-buttons,.market-buttons{grid-template-columns:1fr}
}
