:root {
  --ink: #152238;
  --muted: #64748b;
  --bg: #eef3f8;
  --surface: #ffffff;
  --line: #dce6f1;
  --green-950: #07152b;
  --green-900: #102a4f;
  --green-700: #0a84ff;
  --green-600: #2563eb;
  --lime: #fff200;
  --blue: #0a84ff;
  --amber: #f99c00;
  --red: #ef3340;
  --purple: #7c62e8;
  --cyan: #00bbd4;
  --shadow: 0 18px 50px rgba(16, 42, 79, .11);
}

@font-face { font-family: TavanirUI; src: url('/assets/tavanir-ui.woff2') format('woff2'); font-display: swap; }

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; min-height: 100vh; background: var(--bg); color: var(--ink); font-family: TavanirUI, Vazirmatn, IRANSans, Tahoma, Arial, sans-serif; font-size: 14px; }
button, input, select, textarea { font: inherit; }
button { color: inherit; }
a { color: inherit; }
.hidden { display: none !important; }

.login-page { min-height: 100vh; display: grid; grid-template-columns: minmax(320px, .9fr) minmax(520px, 1.1fr); background: #07152b; color: white; overflow: hidden; }
.login-visual { position: relative; padding: 56px clamp(32px, 6vw, 90px); display: flex; flex-direction: column; justify-content: space-between; isolation: isolate; }
.login-visual::before { content: ""; position: absolute; inset: 0; z-index: -2; background: radial-gradient(circle at 18% 20%, rgba(255,242,0,.18), transparent 28%), radial-gradient(circle at 80% 85%, rgba(10,132,255,.28), transparent 34%), linear-gradient(145deg,#102a4f,#050b17 78%); }
.login-visual::after { content: "25°"; position: absolute; left: -35px; bottom: -80px; font-weight: 900; font-size: clamp(170px, 25vw, 360px); color: rgba(255,255,255,.035); z-index: -1; }
.login-brand { display: flex; align-items: center; gap: 12px; }
.brand-mark { width: 48px; height: 48px; display: grid; place-items: center; border-radius: 50%; background: #fff200; color: var(--green-950); font-weight: 900; font-size: 20px; box-shadow: 0 12px 30px rgba(255,242,0,.2); overflow: hidden; }
.brand-mark img { width: 100%; height: 100%; display: block; }
.login-brand b { display: block; font-size: 20px; }
.login-brand small { color: rgba(255,255,255,.55); }
.hero-copy { max-width: 640px; }
.hero-copy .pill { display: inline-flex; padding: 7px 11px; border: 1px solid rgba(255,242,0,.26); border-radius: 99px; color: #fff77e; background: rgba(255,242,0,.08); }
.hero-copy h1 { font-size: clamp(38px,5vw,72px); line-height: 1.15; margin: 22px 0 14px; letter-spacing: -2px; }
.hero-copy p { color: rgba(255,255,255,.66); line-height: 2; font-size: 16px; max-width: 560px; }
.flow-preview { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-top: 34px; }
.flow-preview span { border: 1px solid rgba(255,255,255,.12); background: rgba(255,255,255,.06); padding: 9px 12px; border-radius: 11px; font-size: 12px; }
.flow-preview i { color: var(--lime); font-style: normal; }
.login-foot { color: rgba(255,255,255,.45); font-size: 12px; }
.login-panel { background: #f6f9f7; color: var(--ink); padding: 40px clamp(24px,5vw,80px); display: grid; place-items: center; }
.login-box { width: min(520px,100%); }
.eyebrow { color: var(--green-700); font-weight: 800; font-size: 11px; letter-spacing: .05em; }
.login-box h2 { font-size: 29px; margin: 7px 0; }
.login-box > p { color: var(--muted); margin: 0 0 26px; }
.demo-users { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 22px; }
.demo-user { display: flex; gap: 11px; text-align: right; align-items: center; padding: 12px; border: 1px solid var(--line); background: white; border-radius: 15px; cursor: pointer; transition: .2s; }
.demo-user:hover { transform: translateY(-2px); border-color: #a3d2bf; box-shadow: var(--shadow); }
.demo-user .role-avatar { width: 42px; height: 42px; flex: 0 0 auto; }
.demo-user b,.demo-user small { display: block; }
.demo-user small { color: var(--muted); margin-top: 3px; font-size: 10px; direction: ltr; text-align: right; }
.field { display: grid; gap: 7px; margin-bottom: 15px; }
.field label { font-size: 12px; font-weight: 700; }
.control { width: 100%; border: 1px solid var(--line); background: white; color: var(--ink); border-radius: 13px; padding: 12px 14px; outline: 0; transition: .2s; }
.control:focus { border-color: #70b99b; box-shadow: 0 0 0 4px rgba(13,150,104,.1); }
textarea.control { resize: vertical; min-height: 92px; line-height: 1.8; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.btn { border: 1px solid var(--line); background: white; border-radius: 12px; padding: 10px 14px; cursor: pointer; transition: .18s; display: inline-flex; align-items: center; justify-content: center; gap: 7px; text-decoration: none; }
.btn:hover { transform: translateY(-1px); box-shadow: 0 7px 20px rgba(20,61,47,.1); }
.btn.primary { background: var(--green-700); border-color: var(--green-700); color: white; }
.btn.dark { background: var(--green-950); border-color: var(--green-950); color: white; }
.btn.soft { background: #e9f6f0; color: var(--green-700); border-color: #d3ebe0; }
.btn.warn { background: #fff3df; color: #9a6100; border-color: #f5ddb5; }
.btn.danger { background: #fff0f0; color: #bd3f3f; border-color: #f3d2d2; }
.btn.wide { width: 100%; padding: 13px; font-weight: 800; }
.login-error { color: #bd3f3f; background: #fff0f0; border-radius: 10px; padding: 9px 11px; margin-bottom: 12px; display: none; }

.app-shell { min-height: 100vh; display: grid; grid-template-columns: 264px minmax(0,1fr); }
.sidebar { position: sticky; top: 0; height: 100vh; color: #e8f2ee; background: var(--green-950); padding: 22px 15px; display: flex; flex-direction: column; z-index: 20; }
.sidebar-brand { display: flex; align-items: center; gap: 11px; padding: 0 8px 20px; }
.sidebar-brand .brand-mark { width: 42px; height: 42px; border-radius: 14px; font-size: 16px; }
.sidebar-brand b { display: block; font-size: 17px; }
.sidebar-brand small { color: rgba(255,255,255,.45); }
.event-mini { background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.08); border-radius: 16px; padding: 13px; margin-bottom: 17px; }
.event-mini small { color: rgba(255,255,255,.44); }
.event-mini b { display: block; margin: 5px 0 10px; }
.progress { height: 6px; background: #e7eeeb; border-radius: 99px; overflow: hidden; }
.progress > i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg,var(--green-600),#5ad497); }
.event-mini .progress { background: rgba(255,255,255,.1); }
.event-mini .progress i { background: var(--lime); }
.nav { display: grid; gap: 4px; overflow: auto; }
.nav button { border: 1px solid transparent; color: #b8c9c2; background: transparent; text-align: right; padding: 10px 12px; border-radius: 11px; cursor: pointer; display: flex; align-items: center; gap: 10px; }
.nav button:hover { color: white; background: rgba(255,255,255,.05); }
.nav button.active { color: #e9ffb6; background: rgba(203,242,105,.1); border-color: rgba(203,242,105,.14); }
.nav .nav-icon { width: 22px; text-align: center; font-size: 16px; }
.sidebar-user { margin-top: auto; padding: 15px 7px 0; border-top: 1px solid rgba(255,255,255,.08); display: grid; grid-template-columns: 38px 1fr auto; align-items: center; gap: 9px; }
.role-avatar { width: 38px; height: 38px; border-radius: 12px; background: #dff7cc; color: #173c2e; display: grid; place-items: center; font-weight: 900; }
.sidebar-user b,.sidebar-user small { display: block; }
.sidebar-user small { color: rgba(255,255,255,.45); font-size: 10px; margin-top: 2px; }
.logout { color: #e9b5b5; border: 0; background: transparent; font-size: 18px; cursor: pointer; }
.workspace { min-width: 0; }
.topbar { height: 72px; position: sticky; top: 0; z-index: 15; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 0 28px; border-bottom: 1px solid var(--line); background: rgba(255,255,255,.88); backdrop-filter: blur(14px); }
.breadcrumb small { color: var(--muted); }
.breadcrumb b { display: block; margin-top: 3px; }
.top-actions { display: flex; gap: 8px; align-items: center; }
.icon-button { border: 1px solid var(--line); width: 38px; height: 38px; border-radius: 11px; background: white; cursor: pointer; }
.notification-dot { position: relative; }
.notification-dot::after { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--red); position: absolute; right: 5px; top: 5px; border: 2px solid white; }
.mobile-toggle { display: none; }
.page { padding: 26px; max-width: 1580px; margin: auto; }
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 18px; margin-bottom: 21px; }
.page-head h1 { font-size: 27px; margin: 5px 0 4px; }
.page-head p { margin: 0; color: var(--muted); }
.page-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.stats { display: grid; grid-template-columns: repeat(4,1fr); gap: 13px; margin-bottom: 16px; }
.card { border: 1px solid var(--line); background: var(--surface); border-radius: 18px; box-shadow: 0 1px 0 rgba(10,45,34,.02); }
.stat-card { padding: 17px; position: relative; overflow: hidden; }
.stat-card::after { content: ""; position: absolute; width: 86px; height: 86px; border-radius: 50%; background: var(--tint,#e8f5ef); left: -25px; top: -32px; }
.stat-top { display: flex; justify-content: space-between; color: var(--muted); }
.stat-icon { width: 35px; height: 35px; display: grid; place-items: center; border-radius: 11px; background: var(--tint,#e8f5ef); }
.stat-card strong { display: block; font-size: 25px; margin: 13px 0 2px; }
.trend-up { color: var(--green-700); }
.muted { color: var(--muted); }
.small { font-size: 11px; }
.grid-2 { display: grid; grid-template-columns: minmax(0,1.5fr) minmax(290px,.72fr); gap: 15px; margin-bottom: 15px; }
.grid-equal { display: grid; grid-template-columns: 1fr 1fr; gap: 15px; margin-bottom: 15px; }
.panel { padding: 19px; }
.panel-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
.panel-head h2 { margin: 0 0 4px; font-size: 16px; }
.panel-head p { margin: 0; color: var(--muted); font-size: 11px; }
.donut-wrap { display: grid; place-items: center; padding: 10px 0 15px; }
.donut { --p: 74%; width: 150px; aspect-ratio: 1; border-radius: 50%; display: grid; place-items: center; background: conic-gradient(var(--green-600) var(--p),#e9efec 0); position: relative; }
.donut::before { content: ""; width: 106px; aspect-ratio: 1; border-radius: 50%; background: white; }
.donut-label { position: absolute; text-align: center; }
.donut-label b { font-size: 28px; display: block; }
.health-list { display: grid; gap: 10px; }
.health-row { display: grid; grid-template-columns: 105px 1fr 38px; gap: 8px; align-items: center; }
.health-row span { font-size: 11px; }
.task-list,.activity-list,.submission-list { display: grid; gap: 9px; }
.task-row { display: grid; grid-template-columns: 44px minmax(0,1fr) auto; gap: 11px; align-items: center; border: 1px solid var(--line); padding: 11px; border-radius: 13px; transition: .18s; }
.task-row:hover { border-color: #b8d9cb; transform: translateX(-2px); }
.task-check { width: 40px; height: 40px; border-radius: 12px; background: #eef6f2; display: grid; place-items: center; color: var(--green-700); font-weight: 900; }
.task-row b { display: block; margin-bottom: 4px; }
.meta { color: var(--muted); font-size: 10px; display: flex; gap: 10px; flex-wrap: wrap; }
.badge { display: inline-flex; align-items: center; justify-content: center; padding: 5px 8px; border-radius: 99px; font-size: 10px; font-weight: 800; white-space: nowrap; }
.badge.green { color: #08704c; background: #def5ea; }
.badge.amber { color: #956000; background: #fff0d2; }
.badge.red { color: #b23d3d; background: #ffe6e6; }
.badge.blue { color: #2d62c9; background: #e4edff; }
.badge.purple { color: #674cc9; background: #eee9ff; }
.badge.gray { color: #60716a; background: #edf1ef; }
.activity { display: grid; grid-template-columns: 10px 1fr auto; gap: 10px; align-items: start; padding: 8px 0; border-bottom: 1px solid #edf1ef; }
.activity:last-child { border: 0; }
.activity-dot { width: 8px; height: 8px; border-radius: 50%; margin-top: 6px; background: var(--green-600); box-shadow: 0 0 0 5px #e6f5ef; }
.activity b { display: block; font-size: 12px; }
.activity p { color: var(--muted); font-size: 10px; margin: 4px 0 0; }
.activity time { color: var(--muted); font-size: 9px; white-space: nowrap; }
.chart { height: 235px; padding: 12px 6px 25px; display: flex; align-items: flex-end; gap: 11px; background: repeating-linear-gradient(to bottom,transparent 0,transparent 47px,#edf1ef 48px); border-bottom: 1px solid var(--line); }
.chart-group { height: 100%; flex: 1; display: flex; align-items: flex-end; gap: 4px; position: relative; }
.chart-group::after { content: attr(data-label); position: absolute; top: calc(100% + 7px); width: 100%; text-align: center; color: var(--muted); font-size: 9px; }
.bar { flex: 1; border-radius: 6px 6px 2px 2px; background: #cfe8de; min-width: 7px; }
.bar.main { background: linear-gradient(#3bc38b,#087a55); }
.table-wrap { overflow: auto; }
table { width: 100%; border-collapse: collapse; }
th { color: var(--muted); background: #f8faf9; font-size: 10px; font-weight: 700; text-align: right; padding: 11px 14px; }
td { padding: 12px 14px; border-top: 1px solid #edf1ef; white-space: nowrap; }
tbody tr:hover { background: #fbfdfc; }
.company-cell { display: flex; align-items: center; gap: 9px; }
.company-logo { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 10px; color: white; font-weight: 900; background: var(--green-700); }
.company-cell b,.company-cell small { display: block; }
.company-cell small { color: var(--muted); font-size: 9px; margin-top: 3px; }
.score { font-weight: 900; color: var(--green-700); }

.process-hero { background: linear-gradient(135deg,#0a3329,#0b6849); color: white; border: 0; padding: 22px; position: relative; overflow: hidden; }
.process-hero::after { content: "25°"; position: absolute; left: -20px; bottom: -42px; font-size: 120px; font-weight: 900; color: rgba(255,255,255,.05); }
.process-hero p { color: rgba(255,255,255,.62); }
.process-meta { display: flex; gap: 17px; flex-wrap: wrap; margin-top: 18px; color: rgba(255,255,255,.72); font-size: 11px; }
.process-flow { display: flex; align-items: stretch; gap: 9px; overflow-x: auto; padding: 10px 2px 18px; }
.stage { min-width: 190px; flex: 1; background: white; border: 1px solid var(--line); border-radius: 15px; padding: 14px; position: relative; }
.stage:not(:last-child)::after { content: "←"; position: absolute; left: -17px; top: 50%; color: var(--green-600); font-weight: 900; }
.stage-num { width: 28px; height: 28px; border-radius: 9px; display: grid; place-items: center; background: #e8f6ef; color: var(--green-700); font-weight: 900; margin-bottom: 10px; }
.stage b { display: block; }
.stage p { color: var(--muted); font-size: 10px; line-height: 1.7; margin: 7px 0 0; }
.type-grid { display: grid; grid-template-columns: repeat(4,1fr); gap: 11px; }
.type-card { border: 1px solid var(--line); border-radius: 14px; padding: 14px; background: white; }
.type-card .type-icon { font-size: 22px; margin-bottom: 9px; }
.type-card b { display: block; }
.type-card p { color: var(--muted); font-size: 10px; line-height: 1.7; min-height: 34px; }
.type-card footer { display: flex; justify-content: space-between; border-top: 1px solid #edf1ef; padding-top: 9px; font-size: 10px; }

.kanban { display: grid; grid-template-columns: repeat(4,minmax(230px,1fr)); gap: 12px; overflow-x: auto; align-items: start; }
.kanban-col { background: #edf3f0; border-radius: 16px; padding: 11px; min-height: 420px; }
.kanban-head { display: flex; align-items: center; justify-content: space-between; padding: 3px 3px 12px; }
.kanban-head b { font-size: 12px; }
.count { width: 24px; height: 24px; border-radius: 8px; background: white; display: grid; place-items: center; font-size: 10px; }
.kanban-card { background: white; border: 1px solid var(--line); border-radius: 13px; padding: 12px; margin-bottom: 9px; cursor: pointer; }
.kanban-card:hover { box-shadow: var(--shadow); }
.kanban-card b { display: block; line-height: 1.7; }
.kanban-card p { color: var(--muted); font-size: 10px; line-height: 1.7; }
.kanban-card footer { display: flex; justify-content: space-between; align-items: center; margin-top: 10px; }
.avatar-sm { width: 25px; height: 25px; border-radius: 8px; display: grid; place-items: center; color: white; background: var(--purple); font-size: 9px; font-weight: 800; }

.review-card { display: grid; grid-template-columns: minmax(0,1fr) auto; gap: 15px; padding: 16px; border-bottom: 1px solid var(--line); }
.review-card:last-child { border: 0; }
.review-title { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.review-card h3 { font-size: 14px; margin: 0; }
.review-card p { color: var(--muted); font-size: 11px; line-height: 1.8; }
.review-meta { display: flex; gap: 15px; flex-wrap: wrap; font-size: 10px; color: var(--muted); }
.review-score { min-width: 120px; text-align: center; border-right: 1px solid var(--line); padding-right: 15px; }
.review-score strong { display: block; font-size: 27px; color: var(--green-700); }
.review-actions { display: flex; gap: 6px; margin-top: 10px; }

.wizard { display: grid; grid-template-columns: 220px minmax(0,1fr); gap: 16px; }
.wizard-steps { background: var(--green-950); color: white; border-radius: 18px; padding: 15px; align-self: start; position: sticky; top: 90px; }
.wizard-step { display: grid; grid-template-columns: 31px 1fr; gap: 9px; padding: 10px 7px; color: rgba(255,255,255,.5); }
.wizard-step i { width: 29px; height: 29px; border-radius: 9px; border: 1px solid rgba(255,255,255,.15); display: grid; place-items: center; font-style: normal; }
.wizard-step.active { color: white; }
.wizard-step.active i { background: var(--lime); color: var(--green-950); border-color: var(--lime); }
.wizard-step b { display: block; font-size: 11px; }
.wizard-step small { font-size: 9px; color: inherit; }
.form-card { padding: 21px; }
.form-section { border-bottom: 1px solid var(--line); margin-bottom: 18px; padding-bottom: 8px; }
.form-section:last-child { border: 0; margin: 0; }
.form-section h3 { font-size: 14px; margin: 0 0 15px; }
.upload { border: 1.5px dashed #b7d4c8; background: #f6faf8; border-radius: 14px; padding: 22px; text-align: center; cursor: pointer; color: var(--muted); }
.upload input { display: none; }
.upload b { display: block; color: var(--ink); margin-bottom: 5px; }
.score-preview { border-radius: 15px; background: #eaf7f1; padding: 14px; display: flex; align-items: center; justify-content: space-between; gap: 15px; }
.score-preview strong { font-size: 25px; color: var(--green-700); }
.score-breakdown { display: flex; gap: 8px; flex-wrap: wrap; }
.score-breakdown span { background: white; border: 1px solid #d9ebe3; padding: 6px 8px; border-radius: 9px; font-size: 10px; }
.empty { padding: 45px 20px; text-align: center; color: var(--muted); }
.empty-icon { font-size: 35px; display: block; margin-bottom: 9px; }

.report-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 13px; }
.report-card { padding: 17px; }
.report-card .report-icon { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; background: #e9f5ef; color: var(--green-700); font-size: 20px; }
.report-card h3 { margin: 12px 0 5px; font-size: 14px; }
.report-card p { min-height: 40px; color: var(--muted); font-size: 10px; line-height: 1.8; }

.modal { position: fixed; inset: 0; z-index: 100; display: none; place-items: center; padding: 18px; }
.modal.open { display: grid; }
.modal-backdrop { position: absolute; inset: 0; background: rgba(4,27,22,.72); backdrop-filter: blur(6px); }
.modal-card { width: min(620px,100%); max-height: calc(100vh - 36px); overflow: auto; position: relative; background: white; border-radius: 21px; padding: 22px; box-shadow: 0 30px 90px rgba(0,0,0,.28); animation: pop .2s ease; }
.modal-head { display: flex; justify-content: space-between; align-items: start; margin-bottom: 19px; }
.modal-head h2 { margin: 4px 0 0; font-size: 20px; }
.modal-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 18px; }
.toast { position: fixed; left: 22px; bottom: 22px; z-index: 120; background: var(--green-950); color: white; border-radius: 12px; padding: 11px 15px; box-shadow: var(--shadow); opacity: 0; transform: translateY(80px); transition: .25s; }
.toast.show { opacity: 1; transform: translateY(0); }
@keyframes pop { from { opacity: 0; transform: scale(.96); } }

@media(max-width:1100px) {
  .app-shell { grid-template-columns: 82px minmax(0,1fr); }
  .sidebar { padding-inline: 10px; }
  .sidebar-brand { justify-content: center; }
  .sidebar-brand > div:last-child,.event-mini,.nav button span:not(.nav-icon),.sidebar-user > div:nth-child(2),.sidebar-user .logout { display: none; }
  .nav button { justify-content: center; }
  .sidebar-user { grid-template-columns: 1fr; justify-items: center; }
  .stats { grid-template-columns: repeat(2,1fr); }
  .type-grid { grid-template-columns: repeat(2,1fr); }
}

@media(max-width:760px) {
  .login-page { grid-template-columns: 1fr; }
  .login-visual { min-height: 310px; padding: 30px 24px; }
  .login-foot { display: none; }
  .hero-copy h1 { font-size: 38px; margin-top: 18px; }
  .hero-copy p { font-size: 13px; }
  .flow-preview { display: none; }
  .login-panel { padding: 30px 18px; }
  .demo-users,.form-row { grid-template-columns: 1fr; }
  .app-shell { display: block; }
  .sidebar { position: fixed; right: 0; transform: translateX(105%); width: 260px; transition: .25s; box-shadow: -20px 0 60px rgba(0,0,0,.2); }
  .sidebar.open { transform: translateX(0); }
  .sidebar-brand { justify-content: flex-start; }
  .sidebar-brand > div:last-child,.event-mini,.nav button span:not(.nav-icon),.sidebar-user > div:nth-child(2),.sidebar-user .logout { display: block; }
  .nav button { justify-content: flex-start; }
  .sidebar-user { grid-template-columns: 38px 1fr auto; justify-items: initial; }
  .mobile-toggle { display: inline-grid; place-items: center; }
  .topbar { padding: 0 13px; }
  .page { padding: 18px 12px; }
  .page-head { align-items: flex-start; flex-direction: column; }
  .stats,.grid-2,.grid-equal,.report-grid,.type-grid,.wizard { grid-template-columns: 1fr; }
  .wizard-steps { position: static; display: flex; overflow: auto; }
  .wizard-step { min-width: 150px; }
  .review-card { grid-template-columns: 1fr; }
  .review-score { border-right: 0; border-top: 1px solid var(--line); padding: 12px 0 0; text-align: right; }
  .kanban { grid-template-columns: repeat(4,260px); }
  .top-actions .top-label { display: none; }
}

/* Tavanir visual system */
body { background-color: #eef3f8; background-image: radial-gradient(circle at 1px 1px,rgba(10,132,255,.055) 1px,transparent 0); background-size: 24px 24px; }
.sidebar { background: linear-gradient(180deg,#07152b 0%,#102a4f 62%,#07152b 100%); box-shadow: -12px 0 40px rgba(7,21,43,.12); }
.sidebar::before { content:""; position:absolute; inset:0; pointer-events:none; opacity:.18; background: linear-gradient(135deg,transparent 42%,rgba(10,132,255,.18) 42.5%,transparent 43%), radial-gradient(circle at 50% 8%,rgba(255,242,0,.18),transparent 22%); }
.sidebar > * { position: relative; }
.sidebar-brand .brand-mark { border: 2px solid rgba(255,255,255,.8); }
.event-mini { background: linear-gradient(145deg,rgba(10,132,255,.18),rgba(255,255,255,.045)); border-color: rgba(79,167,255,.23); }
.event-mini .progress i { background: linear-gradient(90deg,#fff200,#f99c00); box-shadow:0 0 13px rgba(255,242,0,.55); }
.nav button.active { color:#fff; background:linear-gradient(90deg,rgba(10,132,255,.27),rgba(10,132,255,.08)); border-color:rgba(89,176,255,.32); box-shadow:inset -3px 0 #fff200; }
.topbar { border-bottom-color:#d7e4f2; box-shadow:0 8px 26px rgba(16,42,79,.055); }
.breadcrumb b::before { content:""; display:inline-block; width:7px; height:7px; background:#00bb7f; border-radius:50%; margin-left:7px; box-shadow:0 0 0 5px rgba(0,187,127,.11); }
.eyebrow { color:#0a84ff; }
.btn.primary { background:linear-gradient(135deg,#0a84ff,#2563eb); border-color:#0a84ff; box-shadow:0 9px 25px rgba(10,132,255,.2); }
.btn.soft { background:#e8f3ff; border-color:#cfe6ff; color:#066ccf; }
.card { border-color:#dce6f1; box-shadow:0 1px 0 rgba(10,42,80,.03),0 11px 35px rgba(16,42,79,.045); }
.stat-card { border-top:3px solid #0a84ff; }
.stat-card:nth-child(3n) { border-top-color:#f99c00; }
.stat-card:nth-child(4n) { border-top-color:#ef3340; }
.stat-card::before { content:""; position:absolute; width:5px; height:34px; border-radius:8px; background:#fff200; right:0; top:18px; }
.progress > i { background:linear-gradient(90deg,#0a84ff,#00bbd4); box-shadow:0 0 10px rgba(10,132,255,.18); }
.donut { background:conic-gradient(#0a84ff var(--p),#e6edf5 0); box-shadow:inset 0 0 0 1px rgba(10,132,255,.06),0 0 35px rgba(10,132,255,.1); }
.chart { background:repeating-linear-gradient(to bottom,transparent 0,transparent 47px,#e4ebf4 48px); }
.bar { background:#d9e8f8; animation:barRise .85s cubic-bezier(.2,.75,.2,1) both; transform-origin:bottom; }
.bar.main { background:linear-gradient(#15b5ec,#0a84ff 58%,#174fc5); box-shadow:0 5px 15px rgba(10,132,255,.2); }
.chart-group:nth-child(3n) .bar.main { background:linear-gradient(#fff659,#f99c00); }
.task-check,.stage-num,.report-card .report-icon { background:#e7f3ff; color:#0a84ff; }
.task-row:hover { border-color:#a8d2fb; }
.process-hero,.ai-section { background:linear-gradient(135deg,#07152b,#123d70 65%,#0a84ff); }
.process-hero::before { content:""; position:absolute; inset:0; background:radial-gradient(circle at 16% 10%,rgba(255,242,0,.18),transparent 24%),linear-gradient(120deg,transparent 65%,rgba(0,187,212,.14)); pointer-events:none; }
.process-hero > * { position:relative; }
.wizard-steps { background:linear-gradient(180deg,#07152b,#123d70); }
.wizard-step.active i { background:#fff200; border-color:#fff200; color:#07152b; }
.score,.trend-up { color:#066fd2; }
.company-logo { background:#0a84ff; }
.badge.green { background:#e2f8ef; color:#007a53; }
.activity-dot { background:#0a84ff; box-shadow:0 0 0 5px #e4f2ff; }
.login-panel { background:linear-gradient(145deg,#f8fbff,#edf4fb); }
.login-box { animation:panelIn .7s ease both; }
.hero-copy { animation:heroIn .8s .08s ease both; }
.login-visual .brand-mark { width:58px; height:58px; }
.flow-preview span { border-color:rgba(93,175,255,.22); background:rgba(10,132,255,.1); }
.flow-preview i { color:#fff200; }

/* Animated Iran province heatmap */
.heatmap-card { margin-bottom:15px; overflow:hidden; color:#eef7ff; border:0; background:linear-gradient(145deg,#061226 0%,#0b2445 55%,#123d70 100%); position:relative; isolation:isolate; }
.heatmap-card::before { content:""; position:absolute; inset:-40%; z-index:-1; background:radial-gradient(circle at 25% 46%,rgba(10,132,255,.21),transparent 26%),radial-gradient(circle at 78% 25%,rgba(0,187,212,.15),transparent 24%),radial-gradient(circle at 58% 82%,rgba(255,242,0,.08),transparent 18%); animation:mapAurora 10s ease-in-out infinite alternate; }
.heatmap-head { display:flex; align-items:flex-end; justify-content:space-between; gap:18px; padding:21px 22px 0; }
.heatmap-head h2 { margin:8px 0 4px; font-size:21px; }
.heatmap-head p { color:#98b2cc; margin:0; font-size:11px; }
.live-indicator { display:inline-flex; align-items:center; gap:7px; border:1px solid rgba(0,226,155,.28); background:rgba(0,187,127,.1); color:#91ffd4; border-radius:99px; padding:5px 9px; font-size:10px; }
.live-indicator i { width:7px; height:7px; border-radius:50%; background:#00e29b; box-shadow:0 0 0 0 rgba(0,226,155,.55); animation:livePulse 2s infinite; }
.metric-switch { display:flex; background:rgba(255,255,255,.07); border:1px solid rgba(255,255,255,.1); border-radius:12px; padding:4px; }
.metric-switch button { border:0; background:transparent; color:#91a9c0; border-radius:8px; padding:7px 11px; cursor:pointer; }
.metric-switch button.active { background:#fff; color:#123d70; box-shadow:0 6px 20px rgba(0,0,0,.2); }
.heatmap-layout { display:grid; grid-template-columns:minmax(0,1.7fr) minmax(260px,.62fr); gap:12px; padding:12px 18px 18px; }
.iran-map-panel { min-height:500px; position:relative; border:1px solid rgba(255,255,255,.08); border-radius:17px; overflow:hidden; background:linear-gradient(145deg,rgba(2,11,24,.54),rgba(12,39,72,.4)); }
.iran-map-panel::after { content:""; position:absolute; inset:0; pointer-events:none; background-image:linear-gradient(rgba(255,255,255,.025) 1px,transparent 1px),linear-gradient(90deg,rgba(255,255,255,.025) 1px,transparent 1px); background-size:30px 30px; mask-image:linear-gradient(to bottom,#000,transparent); }
.map-watermark { position:absolute; right:18px; top:15px; color:rgba(255,255,255,.28); font-size:10px; letter-spacing:.06em; }
.iran-heatmap { width:100%; height:445px; display:block; position:relative; z-index:2; filter:drop-shadow(0 18px 30px rgba(0,0,0,.24)); }
.iran-outline { fill:rgba(10,132,255,.07); stroke:rgba(121,190,255,.27); stroke-width:2; }
.iran-grid { fill:url(#gridPattern); stroke:none; }
.province-cell { cursor:pointer; outline:0; transition:filter .2s; }
.province-cell polygon { stroke:#0b2749; stroke-width:3; transition:transform .2s,filter .2s,fill .35s; transform-box:fill-box; transform-origin:center; }
.province-cell:hover polygon,.province-cell:focus polygon { transform:scale(1.11); stroke:#fff; filter:url(#mapGlow); }
.province-cell.is-selected polygon { stroke:#fff200; stroke-width:4; transform:scale(1.1); filter:url(#mapGlow); }
.province-cell text { text-anchor:middle; pointer-events:none; fill:#fff; font-family:TavanirUI,Tahoma,sans-serif; }
.province-short { font-size:9px; font-weight:800; }
.province-value { font-size:8px; fill:#dcecff!important; }
.province-cell.heat-1 polygon,.heat-legend .heat-1 { fill:#ef3340; background:#ef3340; }
.province-cell.heat-2 polygon,.heat-legend .heat-2 { fill:#f99c00; background:#f99c00; }
.province-cell.heat-3 polygon,.heat-legend .heat-3 { fill:#f8d348; background:#f8d348; }
.province-cell.heat-3 text { fill:#14243a; }
.province-cell.heat-4 polygon,.heat-legend .heat-4 { fill:#00bbd4; background:#00bbd4; }
.province-cell.heat-5 polygon,.heat-legend .heat-5 { fill:#0a84ff; background:#0a84ff; }
.real-map .province-cell { stroke:#0a2342; stroke-width:1.15; vector-effect:non-scaling-stroke; transition:fill .35s,filter .2s,opacity .2s; transform:none; }
.real-map .province-cell:hover,.real-map .province-cell:focus { stroke:#fff; stroke-width:2; filter:url(#mapGlow); opacity:.94; }
.real-map .province-cell.is-selected { stroke:#fff200; stroke-width:3; filter:url(#mapGlow); }
.real-map .province-cell.heat-1 { fill:#ef3340; }
.real-map .province-cell.heat-2 { fill:#f99c00; }
.real-map .province-cell.heat-3 { fill:#f8d348; }
.real-map .province-cell.heat-4 { fill:#00bbd4; }
.real-map .province-cell.heat-5 { fill:#0a84ff; }
.province-map-label { pointer-events:none; }
.province-map-label text { text-anchor:middle; fill:#fff; font-weight:800; paint-order:stroke; stroke:#07152b; stroke-width:2.5px; stroke-linejoin:round; font-family:TavanirUI,Tahoma,sans-serif; }
.province-map-label .province-value { font-size:6.5px; fill:#ddecfb; font-weight:700; }
.sea-label { fill:#56a7e8; opacity:.42; font-size:10px; text-anchor:middle; font-style:italic; }
.map-loading { fill:#9bb3ca; text-anchor:middle; font-size:12px; }
.map-attribution { color:#6886a3; font-size:8px; margin:0 5px; }
.score-preview { background:linear-gradient(135deg,#eaf4ff,#f7fbff); border:1px solid #d3e8ff; }

/* Automated submission analysis */
.analysis-hero { display:grid; grid-template-columns:145px 1fr; gap:18px; align-items:center; color:#fff; background:linear-gradient(135deg,#07152b,#123d70); border-radius:17px; padding:18px; position:relative; overflow:hidden; }
.analysis-hero::after { content:""; width:170px; height:170px; border:22px solid rgba(255,242,0,.055); border-radius:50%; position:absolute; left:-70px; top:-85px; }
.analysis-ring { --analysis:80%; width:125px; aspect-ratio:1; border-radius:50%; background:conic-gradient(#fff200 var(--analysis),rgba(255,255,255,.1) 0); display:grid; place-items:center; position:relative; box-shadow:0 0 35px rgba(10,132,255,.22); }
.analysis-ring::before { content:""; width:91px; aspect-ratio:1; border-radius:50%; background:#0b2445; position:absolute; }
.analysis-ring span { position:relative; text-align:center; }
.analysis-ring b,.analysis-ring small { display:block; }
.analysis-ring b { font-size:30px; color:#fff200; }
.analysis-ring small { color:#9bb4cc; font-size:9px; }
.analysis-hero h3 { margin:9px 0 4px; font-size:17px; }
.analysis-hero p { color:#a9bfd3; font-size:10px; line-height:1.8; margin:0; }
.analysis-points { display:flex; align-items:baseline; gap:7px; margin-top:11px; }
.analysis-points strong { font-size:25px; color:#fff200; }
.analysis-points span { color:#d7e8f8; font-size:10px; }
.analysis-points small { color:#79bfff; font-size:9px; margin-right:auto; }
.analysis-components { display:grid; gap:9px; margin:17px 0; }
.analysis-row { display:grid; grid-template-columns:135px 1fr 58px; gap:9px; align-items:center; }
.analysis-row span,.analysis-row b { font-size:10px; }
.analysis-row b { text-align:left; color:#0a67c7; }
.analysis-notes { display:grid; grid-template-columns:1fr 1fr; gap:10px; }
.analysis-notes > div { border:1px solid var(--line); background:#f8fbfe; border-radius:13px; padding:12px; }
.analysis-notes h4 { margin:0 0 8px; font-size:11px; }
.analysis-notes p { margin:5px 0; font-size:9px; line-height:1.75; }
.analysis-good { color:#087a55; }
.analysis-warn { color:#a96600; }
.heat-legend { display:flex; align-items:center; justify-content:center; gap:5px; color:#8da8c1; font-size:9px; position:relative; z-index:3; margin-top:-2px; }
.heat-legend i { width:25px; height:6px; border-radius:4px; }
.heatmap-insight { display:flex; flex-direction:column; gap:9px; }
.selected-province { border:1px solid rgba(255,255,255,.1); background:linear-gradient(145deg,rgba(255,255,255,.1),rgba(10,132,255,.13)); border-radius:16px; padding:16px; position:relative; overflow:hidden; }
.selected-province::after { content:""; width:100px; height:100px; border:15px solid rgba(255,242,0,.08); border-radius:50%; position:absolute; left:-45px; top:-45px; }
.selected-orb { width:33px; height:33px; display:grid; place-items:center; border-radius:11px; background:#fff200; color:#07152b; margin-bottom:13px; box-shadow:0 8px 20px rgba(255,242,0,.18); }
.selected-province small { color:#92abc3; }
.selected-province h3 { margin:4px 0 8px; font-size:18px; }
.selected-province strong { display:block; font-size:32px; color:#fff200; }
.selected-province p { color:#9bb3ca; font-size:10px; }
.selected-province .progress { background:rgba(255,255,255,.1); }
.selected-province .progress i { background:linear-gradient(90deg,#fff200,#00bbd4); }
.map-kpis { display:grid; grid-template-columns:repeat(3,1fr); gap:6px; }
.map-kpis div { background:rgba(255,255,255,.06); border:1px solid rgba(255,255,255,.075); border-radius:12px; padding:10px; }
.map-kpis span,.map-kpis b { display:block; }
.map-kpis span { color:#86a0ba; font-size:8px; }
.map-kpis b { color:#fff; margin-top:5px; font-size:12px; }
.danger-text { color:#ff8b91!important; }
.leader-list { background:rgba(255,255,255,.045); border:1px solid rgba(255,255,255,.07); border-radius:14px; padding:10px; flex:1; }
.leader-list h4 { margin:2px 3px 9px; font-size:11px; color:#9bb3ca; }
.leader-list button { width:100%; border:0; border-bottom:1px solid rgba(255,255,255,.06); background:transparent; color:#fff; display:grid; grid-template-columns:27px 1fr auto; gap:8px; align-items:center; text-align:right; padding:8px 3px; cursor:pointer; }
.leader-list button:last-child { border:0; }
.leader-list button:hover { background:rgba(10,132,255,.1); }
.leader-list .rank { width:25px; height:25px; border-radius:8px; display:grid; place-items:center; background:rgba(10,132,255,.18); color:#7ec0ff; font-weight:800; }
.leader-list b,.leader-list small { display:block; }
.leader-list b { font-size:10px; }
.leader-list small { color:#7892ac; font-size:8px; margin-top:2px; }
.leader-list strong { color:#fff200; font-size:11px; }

@keyframes barRise { from { transform:scaleY(0); opacity:.35; } }
@keyframes panelIn { from { opacity:0; transform:translateY(16px); } }
@keyframes heroIn { from { opacity:0; transform:translateX(22px); } }
@keyframes livePulse { 70% { box-shadow:0 0 0 8px rgba(0,226,155,0); } }
@keyframes mapAurora { to { transform:translate(7%,4%) rotate(5deg) scale(1.08); } }

@media(max-width:900px) {
  .heatmap-layout { grid-template-columns:1fr; }
  .heatmap-insight { display:grid; grid-template-columns:1fr 1fr; }
  .leader-list { grid-column:1/-1; }
}
@media(max-width:620px) {
  .heatmap-head { align-items:flex-start; flex-direction:column; }
  .metric-switch { width:100%; }
  .metric-switch button { flex:1; }
  .iran-map-panel { min-height:390px; }
  .iran-heatmap { height:350px; }
  .heatmap-layout { padding:10px; }
  .heatmap-insight { grid-template-columns:1fr; }
  .leader-list { grid-column:auto; }
  .map-kpis { grid-template-columns:repeat(3,1fr); }
  .analysis-hero { grid-template-columns:1fr; text-align:center; }
  .analysis-ring { margin:auto; }
  .analysis-points { justify-content:center; flex-wrap:wrap; }
  .analysis-points small { margin:0; width:100%; }
  .analysis-notes { grid-template-columns:1fr; }
  .analysis-row { grid-template-columns:105px 1fr 50px; }
}

@media(prefers-reduced-motion:reduce) {
  .bar,.heatmap-card::before,.live-indicator i,.login-box,.hero-copy { animation:none!important; }
}
