/* Look follows my.oscs.in: orange and teal, white rounded cards, slate text, bottom menu on phones. */
:root {
  --orange: #F7941D; --orange-dark: #E8820C; --orange-text: #A85400; --orange-soft: #FFF3E6;
  --teal: #2F86A6; --teal-text: #256F8A; --teal-light: #74B7CE; --teal-soft: #E6F4F9;
  --text: #0f172a; --text-2: #334155; --muted: #5b6b80; --line: #e2e8f0;
  --green: #15803d; --green-soft: #dcfce7; --red: #b91c1c; --red-soft: #fee2e2; --amber: #92400e; --amber-soft: #fef3c7;
  --shadow: 0 1px 3px rgba(15, 23, 42, .08);
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; min-height: 100vh; color: var(--text);
  font-family: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Noto Sans", Arial, sans-serif; line-height: 1.45;
  background: linear-gradient(to bottom right, #FFF3E6, #fff, #E6F4F9) fixed;
}
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; }
h1, h2, p { margin: 0; }
h1 { font-size: 22px; }
h2 { font-size: 17px; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid var(--teal-light); outline-offset: 2px; }

.strip { height: 4px; background: linear-gradient(to right, var(--orange), var(--teal-light)); }
header.top { position: sticky; top: 0; z-index: 20; background: rgba(255, 255, 255, .95); border-bottom: 1px solid rgba(247, 148, 29, .2); }
.top-in { max-width: 960px; margin: 0 auto; padding: 9px 16px; display: flex; align-items: center; gap: 12px; }
.brand { display: flex; align-items: center; gap: 9px; font-weight: 700; white-space: nowrap; }
.brand img { width: 36px; height: 36px; display: block; }
nav a { text-decoration: none; color: #475569; font-weight: 600; font-size: 14px; }
nav.wide { display: flex; gap: 4px; margin-left: 12px; }
nav.wide a { padding: 7px 12px; border-radius: 8px; }
nav.wide a:hover, .logout:hover { background: #f1f5f9; }
nav.wide a[aria-current] { background: var(--orange-soft); color: var(--orange-text); }
.logout { margin-left: auto; border: 0; background: none; color: #475569; font-size: 14px; min-height: 40px; padding: 8px; border-radius: 8px; }
nav.phone { display: none; }
main, .stack { display: grid; gap: 16px; }
main { max-width: 960px; margin: 0 auto; padding: 18px 16px 40px; }
main > *, .stack > *, .card > *, .two > * { min-width: 0; }

/* Orange like my.oscs.in when all is well, red when OTPs cannot be sent. */
.hero { border-radius: 20px; padding: 20px 22px; color: #fff; background: linear-gradient(to right, #dc2626, #b91c1c); box-shadow: 0 8px 20px rgba(220, 38, 38, .2); display: grid; gap: 4px; justify-items: start; }
.hero.ok { background: linear-gradient(to right, var(--orange), var(--orange-dark)); box-shadow: 0 8px 20px rgba(247, 148, 29, .25); }
.hero .small { font-size: 15px; font-weight: 600; }
.hero .big { font-size: 24px; font-weight: 800; line-height: 1.25; overflow-wrap: anywhere; }
.hero .btn { margin-top: 10px; }

.card { background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 16px; box-shadow: var(--shadow); display: grid; gap: 12px; align-content: start; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.tiles { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.tile { background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 14px; text-align: center; box-shadow: var(--shadow); }
.tile b { display: block; font-size: 26px; }
.tile span { font-size: 14px; color: var(--text-2); font-weight: 600; }
.tile.sent b { color: var(--teal-text); }
.tile.verified b { color: var(--green); }
.tile.failed b { color: var(--red); }
.tile.refused b { color: var(--orange-text); }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; align-items: start; }

.muted { color: var(--muted); font-size: 14px; }
.center { text-align: center; }
.row { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.note { border-radius: 12px; padding: 12px 14px; font-size: 14px; background: var(--teal-soft); color: #164e63; overflow-wrap: anywhere; display: grid; gap: 8px; justify-items: start; }
.note.bad { background: var(--red-soft); color: #7f1d1d; }
.note.warn { background: var(--amber-soft); color: #78350f; }
.note.good { background: var(--green-soft); color: #14532d; }
.badge { display: inline-block; border-radius: 12px; padding: 3px 10px; font-size: 13px; font-weight: 600; background: #f1f5f9; color: var(--text-2); }
.badge.good { background: var(--green-soft); color: var(--green); }
.badge.bad { background: var(--red-soft); color: var(--red); }
.badge.warn { background: var(--amber-soft); color: var(--amber); }

.btn { display: inline-flex; align-items: center; justify-content: center; text-decoration: none; border: 1px solid #cbd5e1; background: #fff; border-radius: 12px; padding: 9px 15px; min-height: 44px; font-size: 15px; font-weight: 600; color: var(--text-2); }
.btn:hover { background: #f8fafc; }
.btn:disabled { opacity: .55; cursor: default; }
.btn.primary { border: 0; color: #fff; font-size: 16px; font-weight: 700; background: linear-gradient(to right, var(--orange), var(--orange-dark)); box-shadow: 0 4px 12px rgba(247, 148, 29, .3); }
.btn.primary:hover { background: var(--orange-dark); }
.btn.danger { color: var(--red); border-color: #fca5a5; }
.btn.danger:hover { background: var(--red-soft); }

form { display: grid; gap: 12px; }
label { display: grid; gap: 5px; font-size: 14px; font-weight: 600; color: var(--text-2); }
label small { font-weight: 400; color: var(--muted); }
input, select { width: 100%; min-height: 44px; border: 1px solid #94a3b8; border-radius: 12px; padding: 9px 12px; background: #fff; font-size: 16px; }
input:focus, select:focus { border-color: var(--orange-dark); outline: 3px solid rgba(247, 148, 29, .25); outline-offset: 0; }
.error { color: var(--red); font-size: 14px; font-weight: 600; }
.fields { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; align-items: end; }

.login { min-height: 100vh; display: grid; place-items: center; padding: 16px; }
.login-card { width: 100%; max-width: 400px; background: #fff; border-radius: 24px; overflow: hidden; border: 1px solid rgba(247, 148, 29, .3); box-shadow: 0 20px 40px rgba(247, 148, 29, .12); }
.login-card .strip { height: 8px; }
.login-body { padding: 24px; display: grid; gap: 14px; }
.login-body > * { min-width: 0; }
.login-body > img { width: 60px; margin: 0 auto; }
.login-body > h1, .login-body > h1 + p { text-align: center; }
.login-body form .primary { flex: 1; }

.qr { display: grid; gap: 14px; justify-items: center; }
.qr img, .qr .wait { width: 100%; max-width: 300px; border-radius: 16px; }
.qr img { border: 1px solid var(--line); padding: 8px; background: #fff; }
.qr .wait { aspect-ratio: 1; display: grid; place-items: center; text-align: center; border: 2px dashed var(--teal-light); background: var(--teal-soft); color: var(--teal-text); padding: 16px; }
ol { margin: 0; padding-left: 22px; }
.secret { font-family: ui-monospace, Consolas, monospace; overflow-wrap: anywhere; background: #f1f5f9; border-radius: 10px; padding: 8px 10px; font-size: 14px; }
.codes { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.codes .secret { font-size: 12.500px; text-align: center; padding: 8px 4px; }

.line { display: flex; justify-content: space-between; align-items: center; gap: 12px; border-top: 1px solid var(--line); padding: 10px 0; }
.line:first-child { border-top: 0; }
.line > div { min-width: 0; overflow-wrap: anywhere; }
.line .right { text-align: right; flex: none; max-width: 48%; }
table { border-collapse: collapse; width: 100%; font-size: 15px; }
th, td { text-align: right; padding: 9px 6px; border-top: 1px solid var(--line); }
th:first-child, td:first-child { text-align: left; overflow-wrap: anywhere; }
thead th { border-top: 0; color: var(--muted); font-size: 13px; }

dialog { border: 0; border-radius: 20px; padding: 20px; width: 460px; max-width: calc(100vw - 24px); max-height: calc(100vh - 32px); overflow: auto; box-shadow: 0 20px 60px rgba(15, 23, 42, .3); color: var(--text); }
dialog::backdrop { background: rgba(15, 23, 42, .5); }
dialog > div { display: grid; gap: 14px; }
.toast { position: fixed; left: 50%; bottom: 84px; transform: translateX(-50%); background: var(--text); color: #fff; padding: 11px 16px; border-radius: 12px; z-index: 50; width: max-content; max-width: calc(100vw - 32px); font-size: 15px; }
svg.ic { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

@media (max-width: 719px) {
  nav.wide { display: none; }
  nav.phone {
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 20; display: grid; grid-template-columns: repeat(5, 1fr);
    background: #fff; border-top: 1px solid var(--line); padding-bottom: env(safe-area-inset-bottom);
  }
  nav.phone a { display: grid; justify-items: center; align-content: center; gap: 2px; min-height: 58px; font-size: 12px; }
  nav.phone a[aria-current] { color: var(--orange-text); }
  main { padding: 14px 12px 96px; }
  .tiles { grid-template-columns: 1fr 1fr; }
  .two, .fields { grid-template-columns: 1fr; }
  .hero .big { font-size: 21px; }
}
