@import url('https://fonts.googleapis.com/css2?family=Vazirmatn:wght@300;400;500;600;700;800&display=swap');
:root{--navy:#102b58;--blue:#1769df;--cyan:#eaf3ff;--ink:#17243a;--muted:#66758b;--line:#dce5f1;--bg:#f4f7fb;--accent:#1769df;--surface:#fff}
html[data-theme="2"]{--accent:#0f9f8f;--blue:#0f9f8f;--navy:#123e49}html[data-theme="3"]{--accent:#9a4dd2;--blue:#8b45c5;--navy:#3a245d}html[data-theme="4"]{--accent:#d97706;--blue:#d97706;--navy:#57300d}html[data-theme="5"]{--accent:#d43d70;--blue:#d43d70;--navy:#5b1737}html[data-theme="6"]{--accent:#3f7b50;--blue:#3f7b50;--navy:#183c2b}html[data-theme="7"]{--accent:#087eae;--blue:#087eae;--navy:#10364c}html[data-theme="8"]{--accent:#64748b;--blue:#64748b;--navy:#27364c}
*{box-sizing:border-box}body{margin:0;background:var(--bg);color:var(--ink);font-family:Vazirmatn,Tahoma,sans-serif;line-height:1.8}.topbar{background:linear-gradient(100deg,var(--navy),var(--accent));color:#fff;padding:12px max(3vw,16px);display:flex;align-items:center;justify-content:space-between;gap:12px}.brand{font-size:19px;font-weight:800;color:#fff;text-decoration:none}.brand small{display:block;font-size:10px;font-weight:400}.topbar nav{display:flex;gap:15px;flex-wrap:wrap}.topbar nav a{color:#fff;text-decoration:none;font-size:13px}.container{width:min(1180px,94%);margin:24px auto 55px}footer{text-align:center;color:#718096;padding:18px;font-size:11px}.btn{display:inline-flex;align-items:center;justify-content:center;border:0;border-radius:10px;background:var(--blue);color:#fff;padding:9px 16px;font:inherit;font-weight:700;text-decoration:none;cursor:pointer}.btn.secondary{background:#e8f1ff;color:#174b91}.btn.purple{background:#7144bd}.panel,.stat,.product-card{background:#fff;border:1px solid var(--line);border-radius:15px;padding:17px;box-shadow:0 5px 18px #16375b08;margin:14px 0}.form-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:10px}label{display:block;font-size:13px;font-weight:600;margin:8px 0}input,textarea,select{width:100%;border:1px solid #ced9e8;border-radius:9px;padding:10px;background:#fff;font:inherit;margin-top:4px}textarea{resize:vertical}.notice{padding:10px 14px;border-radius:9px;background:#edf4ff;margin:10px 0}.notice.success{background:#e8f8ef;color:#17663a}.notice.error{background:#fff0f0;color:#a52c2c}.table-wrap{overflow:auto;background:#fff;border-radius:12px;border:1px solid var(--line);margin:12px 0}table{width:100%;border-collapse:collapse;min-width:600px}th,td{text-align:right;padding:10px;border-bottom:1px solid #e8edf4;font-size:12px}th{background:#f0f5fc;color:#27476f}.stats{display:grid;grid-template-columns:repeat(4,1fr);gap:12px}.stat span{display:block;color:var(--muted)}.stat b{font-size:24px;color:var(--accent)}.theme-grid{display:grid;grid-template-columns:repeat(8,1fr);gap:9px}.theme-option{border:1px solid var(--line);border-radius:10px;padding:8px;text-align:center;background:#fff}.theme-option input{width:auto}.swatches{display:flex;height:25px;border-radius:7px;overflow:hidden}.swatches i{flex:1;background:hsl(calc(attr(data-theme-preview number)*25),65%,45%)}.swatches i:nth-child(2){background:#102b58}.swatches i:nth-child(3){background:#f0b429}.product-grid,.article-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:14px}.product-card{display:flex;flex-direction:column;gap:5px}.product-image{height:120px;border-radius:10px;background:linear-gradient(135deg,#e7effb,#d1e4ff);display:grid;place-items:center;color:#456}.product-card strong{color:var(--accent)}.product-card small{color:var(--muted)}.invoice{background:#fff;padding:clamp(16px,3vw,38px);border:1px solid var(--line);border-radius:12px;max-width:950px;margin:18px auto}.invoice-head{display:flex;justify-content:space-between;align-items:center;gap:16px}.invoice-head h1{margin:0;font-size:20px}.invoice-meta{text-align:left;font-size:12px}.company-logo{width:55px;height:55px;border-radius:14px;background:#e8f1ff;color:#174b91;display:grid;place-items:center;font-size:23px;font-weight:800}.totals{max-width:370px;margin:18px 0 18px auto;background:#f4f7fb;padding:12px 18px;border-radius:10px}.totals h2{color:var(--accent)}.invoice-footer{display:grid;grid-template-columns:1fr 1fr 130px;gap:12px;align-items:end;margin-top:30px}.sign-box{height:85px;border:1px dashed #9aa9bd;border-radius:8px;margin-top:8px}.qr img{width:100px;height:100px}.qr small{display:block;font-size:9px}.toolbar{display:flex;gap:8px;flex-wrap:wrap}.sms-drop{position:relative}.sms-drop summary{list-style:none}.sms-drop[open]{background:#fff;border:1px solid var(--line);border-radius:10px;padding:8px}.sms-part{display:block;padding:7px;color:var(--accent);text-decoration:none;font-size:12px}.article-body{line-height:2.1}.muted{color:var(--muted)}
@media(max-width:850px){.theme-grid{grid-template-columns:repeat(4,1fr)}.product-grid,.article-grid{grid-template-columns:repeat(2,1fr)}.stats{grid-template-columns:repeat(2,1fr)}}@media(max-width:560px){.topbar{align-items:flex-start;flex-direction:column}.topbar nav{gap:10px}.container{margin-top:15px}.form-grid{grid-template-columns:1fr}.product-grid,.article-grid{grid-template-columns:repeat(2,1fr);gap:8px}.product-card{padding:10px}.product-image{height:85px}.invoice-head{align-items:flex-start;flex-direction:column}.invoice-meta{text-align:right}.invoice-footer{grid-template-columns:1fr 1fr}.qr{grid-column:1/-1}.theme-grid{grid-template-columns:repeat(4,1fr)}}
@media print{body{background:#fff}.topbar,footer,.no-print,.toolbar{display:none!important}.container{width:100%;margin:0}.invoice{border:0;box-shadow:none;margin:0;max-width:none;padding:8mm}.table-wrap{overflow:visible}table{min-width:0}th,td{font-size:9pt;padding:5px}}
