
:root{
  --ink:#16222f;--blue:#3769e8;--blue2:#edf2ff;--paper:#f5f7fb;--white:#fff;
  --muted:#697586;--line:#dfe5ee;--green:#1f8c67;--danger:#bd3c3c;
}
*{box-sizing:border-box}
html{scroll-behavior:smooth}
body{margin:0;background:var(--paper);color:var(--ink);font-family:Inter,Arial,Helvetica,sans-serif;line-height:1.5}
button,input,select,textarea{font:inherit}
.topbar{height:76px;background:#fff;border-bottom:1px solid var(--line);display:flex;align-items:center;justify-content:space-between;padding:0 4vw;position:sticky;top:0;z-index:40}
.brand{display:flex;align-items:center;gap:11px;text-decoration:none}
.brand-mark{width:42px;height:42px;border-radius:13px;background:var(--blue);color:#fff;display:grid;place-items:center;font-weight:900;font-size:21px}
.brand strong,.brand small{display:block}.brand strong{font-size:15px}.brand small{font-size:10px;color:var(--muted)}
.top-note{font-size:12px;color:var(--muted);font-weight:700}
.page{max-width:1600px;margin:auto;padding:45px 3vw 70px}
.intro{display:grid;grid-template-columns:1.2fr .8fr;gap:40px;align-items:end;margin-bottom:36px}
.pill{display:inline-block;background:var(--blue2);color:var(--blue);font-size:10px;letter-spacing:.16em;font-weight:900;padding:7px 10px;border-radius:999px}
.intro h1{font:700 clamp(42px,5vw,72px)/.98 Arial,sans-serif;letter-spacing:-.045em;margin:16px 0 18px;max-width:850px}
.intro p{font-size:17px;color:var(--muted);max-width:760px}
.intro-card{justify-self:end;width:min(390px,100%);background:#fff;border:1px solid var(--line);border-radius:22px;padding:24px;box-shadow:0 14px 40px rgba(41,57,79,.06)}
.intro-card strong{display:block;margin-bottom:12px}.intro-card span{display:block;font-size:13px;padding:7px 0;color:#455365}
.tool-layout{display:grid;grid-template-columns:minmax(0,1.22fr) minmax(400px,.78fr);gap:22px;align-items:start}
.form-panel{display:grid;gap:16px}
.section-card{background:#fff;border:1px solid var(--line);border-radius:20px;padding:24px}
.section-head{display:flex;gap:15px;align-items:flex-start;margin-bottom:20px}
.section-head>span,.head-left>span{width:34px;height:34px;border-radius:10px;background:var(--blue2);color:var(--blue);display:grid;place-items:center;font-size:11px;font-weight:900;flex:0 0 auto}
.section-head h2{font-size:18px;margin:1px 0 2px}.section-head p{font-size:12px;color:var(--muted);margin:0}
.section-head.split{justify-content:space-between}.head-left{display:flex;gap:15px}
.two-col{display:grid;grid-template-columns:1fr 1fr;gap:16px}
.grid{display:grid;gap:12px}.g2{grid-template-columns:1fr 1fr}.g4{grid-template-columns:repeat(4,1fr)}
label{font-size:11px;font-weight:800;color:#536071;display:block}
input,select,textarea{width:100%;margin-top:6px;border:1px solid #d9e0ea;background:#fff;border-radius:10px;padding:12px;color:#15212e;outline:none}
input:focus,select:focus,textarea:focus{border-color:#8ca9ef;box-shadow:0 0 0 3px rgba(55,105,232,.09)}
textarea{resize:vertical}
.small-btn{border:1px solid #cfd9e8;background:#fff;color:var(--blue);font-weight:900;border-radius:10px;padding:9px 12px;cursor:pointer}
.items-wrap{overflow-x:auto}
.items-head,.invoice-line{display:grid;grid-template-columns:minmax(180px,2.2fr) 70px 78px 105px 95px 115px 38px;gap:8px;align-items:center;min-width:750px}
.items-head{font-size:9px;text-transform:uppercase;letter-spacing:.08em;color:#7c8795;padding:0 4px 8px}
.invoice-line{padding:9px 0;border-top:1px solid #eef1f5}
.invoice-line input,.invoice-line select{margin:0;padding:10px 8px;font-size:12px}
.line-total{font-weight:900;font-size:12px;text-align:right}
.remove-line{width:32px;height:32px;border:0;border-radius:9px;background:#fff0f0;color:var(--danger);cursor:pointer;font-weight:900}
.warning{background:#fff8e8;border:1px solid #f0dca9;border-radius:16px;padding:18px}.warning strong{font-size:12px}.warning p{font-size:11px;color:#6f6042;margin:4px 0 0}
.generate-bar{background:#172738;color:#fff;border-radius:20px;padding:20px 22px;display:flex;align-items:center;justify-content:space-between;gap:20px;position:sticky;bottom:14px;z-index:20;box-shadow:0 18px 42px rgba(22,34,47,.20)}
.generate-bar small,.generate-bar strong{display:block}.generate-bar small{font-size:10px;color:#b9c3ce}.generate-bar strong{font-size:24px}
.generate-bar button{border:0;background:#5a83f0;color:#fff;font-weight:900;border-radius:12px;padding:14px 22px;cursor:pointer}
.preview-sticky{position:sticky;top:98px}
.preview-toolbar{display:flex;justify-content:space-between;font-size:9px;letter-spacing:.08em;color:#8791a0;margin:0 4px 8px}
.invoice-preview{background:#fff;border:1px solid var(--line);border-radius:20px;padding:32px;min-height:720px;box-shadow:0 14px 40px rgba(41,57,79,.05)}
.pv-top{display:flex;justify-content:space-between;gap:25px;padding-bottom:25px;border-bottom:2px solid #202c39}.pv-top small,.pv-parties small{font-size:9px;letter-spacing:.15em;color:#87909c}.pv-top h3{font-size:27px;margin:4px 0}.pv-dates{display:flex;flex-direction:column;gap:4px;text-align:right;font-size:10px}.pv-dates i{font-style:normal;color:#707a87}
.pv-parties{display:grid;grid-template-columns:1fr 1fr;gap:28px;padding:26px 0}.pv-parties div{display:flex;flex-direction:column}.pv-parties strong{font-size:13px;margin:5px 0}.pv-parties span{font-size:10px;color:#727c88}
.pv-table{border-top:1px solid var(--line)}.pv-row{display:grid;grid-template-columns:1.8fr .55fr .8fr .9fr;gap:10px;padding:10px 0;border-bottom:1px solid #edf0f4;font-size:10px}.pv-row span:last-child{text-align:right}.pv-head{font-weight:900;color:#687381;font-size:9px}
.pv-totals{width:62%;margin-left:auto;margin-top:25px}.pv-totals div{display:flex;justify-content:space-between;padding:6px 0;font-size:11px}.pv-grand{border-top:2px solid #243241;margin-top:5px;padding-top:10px!important;font-size:15px!important}
.modal{position:fixed;inset:0;background:rgba(18,28,39,.55);display:none;align-items:center;justify-content:center;padding:20px;z-index:100}
.modal.open{display:flex}.modal-card{width:min(470px,100%);background:#fff;border-radius:24px;padding:34px;position:relative;box-shadow:0 30px 80px rgba(0,0,0,.20)}
.modal-close{position:absolute;right:14px;top:10px;border:0;background:none;font-size:28px;cursor:pointer}.modal-badge{font-size:9px;letter-spacing:.16em;color:var(--blue);font-weight:900}.modal-card h2{font-size:32px;margin:10px 0}.modal-card p{color:var(--muted)}.modal-card a{display:inline-block;margin-top:8px;background:var(--blue);color:#fff;text-decoration:none;font-weight:900;padding:12px 16px;border-radius:11px}
footer{padding:25px 4vw;background:#fff;border-top:1px solid var(--line);display:flex;justify-content:space-between;font-size:10px;color:#7b8796}
@media(max-width:1150px){.tool-layout{grid-template-columns:1fr}.preview-panel{order:-1}.preview-sticky{position:static}.invoice-preview{min-height:auto}.two-col{grid-template-columns:1fr}.g4{grid-template-columns:1fr 1fr}}
@media(max-width:700px){.top-note{display:none}.page{padding:30px 14px 50px}.intro{grid-template-columns:1fr}.intro-card{justify-self:stretch}.intro h1{font-size:45px}.section-card{padding:18px}.g2,.g4{grid-template-columns:1fr}.invoice-preview{padding:20px}.pv-parties{grid-template-columns:1fr}.generate-bar{flex-direction:column;align-items:stretch}.generate-bar button{width:100%}.preview-toolbar{display:none}footer{flex-direction:column;gap:5px}}

/* V2 refinements */
.intro h1{
  font-size:clamp(34px,4vw,58px);
  line-height:1.02;
  max-width:780px;
}

.generate-bar{
  width:min(520px,100%);
  margin-left:auto;
  border-radius:16px;
  padding:14px 16px;
  position:sticky;
  bottom:14px;
  display:grid;
  grid-template-columns:minmax(0,1fr) auto;
  align-items:center;
  gap:14px;
}

.generate-bar small{
  font-size:9px;
  line-height:1.2;
  margin-bottom:3px;
}

.generate-bar strong{
  font-size:20px;
}

.generate-bar button{
  padding:12px 16px;
  white-space:nowrap;
}

@media(max-width:700px){
  .intro h1{font-size:38px}
  .generate-bar{
    width:100%;
    grid-template-columns:1fr;
    margin-left:0;
  }
  .generate-bar button{width:100%}
}

/* V3 — WebLight brand refresh */
:root{
  --ink:#f5f7fb;
  --blue:#6f8cff;
  --blue2:#202839;
  --paper:#0f1520;
  --white:#ffffff;
  --muted:#9ca8b8;
  --line:#2d3747;
  --green:#28c891;
  --danger:#e56d6d;
  --panel:#171f2b;
  --panel2:#1c2633;
  --accent:#9db1ff;
}

body{
  background:
    radial-gradient(circle at 75% 0%,rgba(107,126,168,.14),transparent 36%),
    linear-gradient(180deg,#0e141f,#111824 56%,#0f1520);
  color:var(--ink);
}

.topbar{
  background:rgba(13,19,29,.95);
  border-bottom:1px solid #2a3444;
  box-shadow:0 10px 30px rgba(0,0,0,.16);
}

.brand strong{font-size:16px;text-transform:lowercase;color:#fff}
.brand small{color:#8e9aab}
.brand-mark{
  background:linear-gradient(180deg,#f9fbff,#d7dfeb);
  color:#101722;
  border:1px solid rgba(255,255,255,.35);
  box-shadow:0 0 28px rgba(255,255,255,.10);
  position:relative;
}
.brand-mark:before,
.brand-mark:after{
  content:"";
  position:absolute;
  width:2px;
  height:7px;
  background:#95a0af;
  top:-5px;
  left:50%;
  transform-origin:center 26px;
}
.brand-mark:before{transform:translateX(-50%) rotate(-28deg)}
.brand-mark:after{transform:translateX(-50%) rotate(28deg)}
.brand-mark .bulb{
  font-size:0;
  width:14px;
  height:18px;
  border:2px solid #111722;
  border-radius:50% 50% 45% 45%;
  display:block;
  position:relative;
}
.brand-mark .bulb:after{
  content:"";
  position:absolute;
  width:8px;
  height:4px;
  border-top:2px solid #111722;
  border-bottom:2px solid #111722;
  left:1px;
  bottom:-7px;
}

.top-note{color:#8f9bad}

.page{max-width:1600px}

.pill{
  background:#1e2a3b;
  color:#a8b8ff;
  border:1px solid #2e3a4e;
}

.intro h1{color:#fff}
.intro p{color:#9ca8b8}
.intro-card,
.section-card,
.invoice-preview{
  background:linear-gradient(180deg,#18212d,#141c27);
  border-color:#2d3747;
  box-shadow:0 18px 48px rgba(0,0,0,.16);
}
.intro-card strong{color:#fff}
.intro-card span{color:#b4beca}

.section-head>span,.head-left>span{
  background:#222d40;
  color:#9cb0ff;
}
.section-head h2{color:#f6f8fb}
.section-head p{color:#8490a0}

label{color:#aab4c1}

input,select,textarea{
  background:#111923;
  border-color:#303b4c;
  color:#f5f7fb;
}
input::placeholder,textarea::placeholder{color:#657184}
input:focus,select:focus,textarea:focus{
  border-color:#7189e8;
  box-shadow:0 0 0 3px rgba(113,137,232,.10);
}

.small-btn{
  background:#111923;
  border-color:#344054;
  color:#aab8ff;
}

.items-head{color:#7f8a99}
.invoice-line{border-top-color:#283242}
.line-total{color:#fff}
.remove-line{background:#2b1d22;color:#ff9aa8}

.warning{
  background:#251f14;
  border-color:#5a4a2f;
}
.warning p{color:#cabd9d}

.generate-bar{
  background:linear-gradient(135deg,#222d3d,#16202d);
  border:1px solid #3b4658;
  box-shadow:0 16px 46px rgba(0,0,0,.26);
}
.generate-bar button{
  background:linear-gradient(135deg,#8ba0ff,#627ef0);
}
.generate-bar small{color:#93a0b0}

.preview-toolbar{color:#7c8797}
.pv-top{border-bottom-color:#dbe1ea}
.pv-top small,.pv-parties small{color:#778493}
.pv-dates i,.pv-parties span{color:#a5afbb}
.pv-table{border-top-color:#2d3747}
.pv-row{border-bottom-color:#283141;color:#dfe5ec}
.pv-head{color:#8893a2}
.pv-grand{border-top-color:#dbe1ea}

.modal{background:rgba(4,9,15,.72)}
.modal-card{
  background:linear-gradient(180deg,#1a2330,#121923);
  border:1px solid #303b4c;
  color:#fff;
}
.modal-card p{color:#9ca8b8}
.modal-card a{background:#7189e8}
.modal-badge{color:#a4b5ff}

.save-company-box{
  margin-top:8px;
  padding:14px;
  border:1px solid #303b4c;
  border-radius:12px;
  background:#111923;
}
.save-company-check{
  display:flex;
  gap:9px;
  align-items:flex-start;
  font-size:11px;
  color:#d6dce4;
}
.save-company-check input{
  width:auto;
  margin:2px 0 0;
}
.clear-saved-btn{
  margin-top:10px;
  border:1px solid #3c495b;
  background:#1a2431;
  color:#9eacc0;
  border-radius:9px;
  padding:8px 10px;
  font-size:10px;
  font-weight:800;
  cursor:pointer;
}
.save-company-box small{
  display:block;
  margin-top:9px;
  color:#6f7c8d;
  font-size:9px;
}

footer{
  background:#0b111a;
  border-top-color:#26303f;
  color:#6f7d90;
}

/* V4 — lighter WebLight contrast */
:root{
  --ink:#1a2430;
  --blue:#4f67d8;
  --blue2:#eef1f7;
  --paper:#eef2f6;
  --white:#ffffff;
  --muted:#6f7a88;
  --line:#d5dce5;
  --green:#1f9b72;
  --danger:#bd3c3c;
  --panel:#ffffff;
  --panel2:#f7f9fb;
  --accent:#7f91e6;
}

body{
  background:
    radial-gradient(circle at 82% 0%,rgba(39,50,68,.07),transparent 32%),
    linear-gradient(180deg,#edf1f5 0%,#f8fafc 44%,#eef2f6 100%);
  color:#1a2430;
}

.topbar{
  background:#171e2a;
  border-bottom:0;
  box-shadow:0 8px 24px rgba(27,35,47,.12);
}

.brand{
  gap:10px;
}
.brand img{
  width:150px;
  height:50px;
  object-fit:cover;
  object-position:center;
  border-radius:8px;
  display:block;
}
.brand strong{
  color:#fff;
  font-size:15px;
}
.brand small{
  color:#aeb7c4;
}
.top-note{
  color:#b8c1cc;
}

.pill{
  background:#e4e9f1;
  color:#3e4e72;
  border:1px solid #d2d9e4;
}

.intro h1{
  color:#17222e;
}
.intro p{
  color:#657180;
}
.intro-card,
.section-card,
.invoice-preview{
  background:#fff;
  border-color:#d9e0e8;
  box-shadow:0 12px 34px rgba(35,48,66,.07);
}
.intro-card strong{color:#1c2733}
.intro-card span{color:#526070}

.section-head>span,.head-left>span{
  background:#eef1f7;
  color:#4f67d8;
}
.section-head h2{color:#1d2732}
.section-head p{color:#74808d}
label{color:#4f5d6c}

input,select,textarea{
  background:#f9fbfc;
  border-color:#d4dce6;
  color:#1c2631;
}
input::placeholder,textarea::placeholder{color:#9aa4b0}
input:focus,select:focus,textarea:focus{
  border-color:#8a9be3;
  box-shadow:0 0 0 3px rgba(79,103,216,.08);
}

.small-btn{
  background:#f7f9fb;
  border-color:#d6deea;
  color:#4f67d8;
}
.items-head{color:#788492}
.invoice-line{border-top-color:#e7ebf0}
.line-total{color:#1e2a35}
.remove-line{background:#fff0f0;color:#bd3c3c}

.warning{
  background:#fff8e8;
  border-color:#f0dca9;
}
.warning p{color:#6f6042}

.generate-bar{
  background:#263244;
  border:0;
  box-shadow:0 12px 30px rgba(27,38,52,.16);
}
.generate-bar button{
  background:#667eea;
}
.generate-bar small{color:#bdc7d4}

.preview-toolbar{color:#7d8793}
.pv-top{border-bottom-color:#263244}
.pv-top small,.pv-parties small{color:#7e8995}
.pv-dates i,.pv-parties span{color:#77818c}
.pv-table{border-top-color:#dfe5ec}
.pv-row{border-bottom-color:#e9edf2;color:#2e3945}
.pv-head{color:#6f7b88}
.pv-grand{border-top-color:#273241}

.modal{
  background:rgba(19,28,39,.55);
}
.modal-card{
  background:#fff;
  border:1px solid #d7dee8;
  color:#1b2530;
}
.modal-card p{color:#6c7784}
.modal-card a{background:#526bdc}
.modal-badge{color:#526bdc}

.save-company-box{
  border-color:#d9e0e8;
  background:#f8fafc;
}
.save-company-check{
  color:#4d5a68;
}
.clear-saved-btn{
  border-color:#d3dbe6;
  background:#fff;
  color:#647181;
}
.save-company-box small{
  color:#87919d;
}

footer{
  background:#202a38;
  border-top:0;
  color:#aab4c1;
}


/* V5 — approved weblight brand + gold accents + mobile optimization */
:root{
  --wl-bg:#f2f3f4;
  --wl-bg-2:#e9ebed;
  --wl-card:#ffffff;
  --wl-ink:#161a1f;
  --wl-charcoal:#20252b;
  --wl-muted:#6d747d;
  --wl-line:#d9dde1;
  --wl-gold:#e5ad22;
  --wl-gold-soft:#f7e9b6;
  --wl-gold-deep:#b98514;
  --wl-shadow:0 18px 45px rgba(23,29,35,.08);
}
body{
  background:
    radial-gradient(circle at 78% 0%,rgba(255,255,255,.95),transparent 32%),
    linear-gradient(180deg,var(--wl-bg) 0%,#f8f9fa 48%,#eef0f2 100%);
  color:var(--wl-ink);
}
.topbar{
  height:82px;
  background:rgba(255,255,255,.94);
  border-bottom:1px solid rgba(32,37,43,.08);
  backdrop-filter:blur(12px);
  box-shadow:0 8px 28px rgba(25,31,37,.05);
}
.brand{gap:12px;min-width:0}
.brand-logo{
  width:164px;height:48px;object-fit:cover;object-position:center;border-radius:8px;display:block;
}
.brand-tools{
  border-left:1px solid #d9dde1;padding-left:11px;display:flex;flex-direction:column;line-height:1.05;
}
.brand-tools strong{color:var(--wl-charcoal);font-size:14px;text-transform:lowercase}
.brand-tools small{color:#7a8189;font-size:9px;margin-top:4px}
.top-note{color:#69717a}
.page{max-width:1560px;padding-top:38px}
.intro{
  grid-template-columns:minmax(0,1.15fr) minmax(300px,.85fr);
  align-items:center;
}
.intro h1{color:#171b20;font-size:clamp(36px,4vw,58px);max-width:780px}
.intro p{color:#68707a;max-width:720px}
.pill{
  background:#fff7dc;color:#8a6612;border:1px solid #ecd58d;box-shadow:none;
}
.intro-side{
  display:grid;gap:13px;justify-self:end;width:min(430px,100%);
}
.brand-visual{
  height:118px;border-radius:20px;overflow:hidden;border:1px solid #dde1e5;
  background:#e9ebed;box-shadow:var(--wl-shadow);
}
.brand-visual img{
  width:100%;height:100%;object-fit:cover;object-position:center 50%;display:block;
}
.intro-card{width:100%;justify-self:stretch;border-top:3px solid var(--wl-gold)}
.section-card,.invoice-preview{
  background:rgba(255,255,255,.96);border-color:#dfe3e7;box-shadow:var(--wl-shadow);
}
.section-head>span,.head-left>span{
  background:#fff6d8;color:#926c13;border:1px solid #f0dfa9;
}
.small-btn{color:#705310;border-color:#ead69a;background:#fffaf0}
.small-btn:hover{background:#fff3cc}
input:focus,select:focus,textarea:focus{
  border-color:#d0a53a;box-shadow:0 0 0 3px rgba(229,173,34,.12);
}
.generate-bar{
  background:#222831;border:1px solid #323943;box-shadow:0 16px 36px rgba(25,31,37,.18);
}
.generate-bar button{
  background:linear-gradient(135deg,#edbd3b,#d49d17);color:#1b1d20;
  box-shadow:0 6px 18px rgba(185,133,20,.22);
}
.generate-bar button:hover{filter:brightness(1.03)}
.warning{background:#fffaf0;border-color:#ead9a5}
.warning strong{color:#6e5419}.warning p{color:#756846}
.pv-top{border-bottom-color:#222831}.pv-grand{border-top-color:#222831}
.preview-toolbar{color:#858c94}
.save-company-box{background:#fafbfc;border-color:#dfe3e7}
.save-company-check input{accent-color:#d8a31d}
.modal-card{border-top:4px solid var(--wl-gold)}
.modal-card a{background:#222831}.modal-badge{color:#9a7318}
footer{background:#222831;color:#c0c6cc}

@media(max-width:1100px){
  .intro{grid-template-columns:1fr;gap:24px}
  .intro-side{
    justify-self:stretch;width:100%;
    grid-template-columns:minmax(0,.8fr) minmax(260px,1fr);
    align-items:stretch;
  }
  .brand-visual{height:auto;min-height:150px}
  .tool-layout{grid-template-columns:1fr}
  .preview-panel{order:2}
  .preview-sticky{position:static}
}

@media(max-width:700px){
  body{background:#f2f3f4}
  .topbar{height:66px;padding:0 14px}
  .brand-logo{width:116px;height:36px;border-radius:6px}
  .brand-tools{padding-left:8px}
  .brand-tools strong{font-size:12px}
  .brand-tools small{display:none}
  .top-note{display:none}

  .page{padding:22px 12px 38px}
  .intro{margin-bottom:20px;gap:18px}
  .pill{font-size:9px;padding:6px 9px}
  .intro h1{
    font-size:37px;line-height:.98;letter-spacing:-.04em;margin:13px 0 14px;
  }
  .intro p{font-size:14px;line-height:1.55}
  .intro-side{grid-template-columns:1fr}
  .brand-visual{min-height:0;height:104px;border-radius:16px}
  .intro-card{padding:18px;border-radius:16px}

  .section-card{padding:17px 14px;border-radius:16px}
  .section-head{gap:10px;margin-bottom:16px}
  .section-head>span,.head-left>span{width:30px;height:30px;border-radius:8px}
  .section-head h2{font-size:16px}
  .section-head p{font-size:11px}
  .section-head.split{gap:12px;align-items:flex-start}
  .section-head.split .small-btn{
    padding:8px 9px;font-size:10px;flex:0 0 auto;
  }

  input,select,textarea{
    min-height:46px;font-size:16px;padding:11px 12px;
  }
  textarea{min-height:88px}
  label{font-size:10px}

  .items-wrap{overflow:visible}
  .items-head{display:none}
  .invoice-line{
    min-width:0;grid-template-columns:1fr 1fr;gap:8px;
    padding:14px 0;border-top:1px solid #e7eaee;
  }
  .invoice-line .i-name{grid-column:1 / -1}
  .invoice-line .line-total{
    display:flex;align-items:center;justify-content:flex-start;min-height:44px;
    padding:0 10px;background:#f5f6f7;border-radius:9px;
  }
  .invoice-line .remove-line{justify-self:end;align-self:center}

  .warning{border-radius:14px;padding:14px}
  .generate-bar{
    position:sticky;bottom:8px;width:100%;grid-template-columns:1fr auto;
    padding:11px 12px;border-radius:14px;gap:10px;
  }
  .generate-bar small{font-size:8px}
  .generate-bar strong{font-size:17px}
  .generate-bar button{width:auto;padding:11px 13px;font-size:12px}

  .preview-panel{margin-top:4px}
  .invoice-preview{padding:16px;border-radius:16px;min-height:auto}
  .pv-top{gap:12px;padding-bottom:18px}
  .pv-top h3{font-size:21px}
  .pv-parties{grid-template-columns:1fr;gap:16px;padding:18px 0}
  .pv-row{
    grid-template-columns:minmax(0,1.5fr) .48fr .74fr .85fr;
    gap:5px;font-size:8px;
  }
  .pv-totals{width:100%}
  .save-company-box{padding:12px}
  .save-company-check{font-size:10px}
  footer{padding:20px 14px;font-size:9px}
}

@media(max-width:390px){
  .brand-logo{width:104px}
  .brand-tools strong{font-size:11px}
  .intro h1{font-size:33px}
  .generate-bar{grid-template-columns:1fr}
  .generate-bar button{width:100%}
}


/* V6 — logo centering refinement */
.brand{
  display:flex;
  align-items:center;
}
.brand-logo{
  object-fit:contain;
  object-position:center;
  background:transparent;
  padding:0;
}
.brand > .brand-logo{
  flex:0 0 auto;
}
.brand-tools{
  justify-content:center;
}

@media(max-width:700px){
  .brand-logo{
    object-fit:contain;
    object-position:center;
  }
}


/* V7 — true visual centering of weblight wordmark */
.brand-logo{
  object-fit:contain !important;
  object-position:50% 50% !important;
  display:block;
}


/* V8 — chitanță opțională */
.optional-tag{
  display:inline-block;
  margin-left:7px;
  padding:3px 7px;
  border-radius:999px;
  background:#fff6d8;
  border:1px solid #ecd58d;
  color:#8a6612;
  font-size:8px;
  font-weight:900;
  vertical-align:middle;
}
.receipt-card{
  border-top:3px solid var(--wl-gold);
}
.receipt-toggle{
  display:flex;
  align-items:flex-start;
  gap:11px;
  cursor:pointer;
  padding:14px;
  background:#fafbfc;
  border:1px solid #dfe3e7;
  border-radius:12px;
}
.receipt-toggle input{
  width:auto;
  min-height:0;
  margin:2px 0 0;
  accent-color:#d8a31d;
}
.receipt-toggle span{
  display:flex;
  flex-direction:column;
  gap:3px;
}
.receipt-toggle strong{
  font-size:12px;
  color:#2b3138;
}
.receipt-toggle small{
  font-size:9px;
  color:#7b828a;
}
.receipt-fields{
  margin-top:14px;
  padding-top:14px;
  border-top:1px solid #e3e6e9;
}
.receipt-fields[hidden]{display:none!important}
.receipt-note{
  margin-bottom:12px;
  padding:10px 12px;
  border-radius:10px;
  background:#fff4e6;
  border:1px solid #efcfaa;
  color:#7a4d1f;
  font-size:10px;
  font-weight:700;
}
.receipt-note.ok{
  background:#edf8ef;
  border-color:#bfdfc4;
  color:#315f38;
}
.receipt-help{
  display:block;
  margin-top:10px;
  color:#858b92;
  font-size:9px;
  line-height:1.5;
}
.g3{
  grid-template-columns:repeat(3,minmax(0,1fr));
}

@media(max-width:700px){
  .g3{grid-template-columns:1fr}
  .receipt-toggle{padding:12px}
  .receipt-toggle strong{font-size:11px}
}


/* =========================================================
   V9 — weblight.ro official brand integration
   ========================================================= */
:root{
  --wl-yellow:#ffbf00;
  --wl-yellow-2:#ffd34e;
  --wl-yellow-soft:#fff3bf;
  --wl-black:#111214;
  --wl-charcoal:#1e2023;
  --wl-graphite:#2a2d31;
  --wl-cream:#fbfaf7;
  --wl-white:#fff;
  --wl-gray:#697078;
  --wl-line:#dedede;
  --wl-shadow:0 22px 55px rgba(17,18,20,.09);
}

body{
  background:
    radial-gradient(circle at 88% 3%,rgba(255,191,0,.13),transparent 24%),
    linear-gradient(180deg,#fbfaf7 0%,#f3f3f1 58%,#ececea 100%) !important;
  color:var(--wl-black);
}

.topbar{
  min-height:86px;
  height:auto;
  background:rgba(251,250,247,.96)!important;
  border-bottom:1px solid rgba(17,18,20,.09)!important;
  box-shadow:0 8px 30px rgba(17,18,20,.05)!important;
  padding-top:10px;
  padding-bottom:10px;
}

.brand-v9{gap:14px}
.brand-logo-v9{
  width:230px!important;
  height:58px!important;
  object-fit:contain!important;
  object-position:left center!important;
}
.brand-tools{
  border-left:1px solid #d9d9d5!important;
}
.brand-tools strong{color:#111214!important}
.brand-tools small{color:#777b80!important}
.top-note{
  color:#202225!important;
  background:#fff3bf;
  border:1px solid #f1d46a;
  padding:8px 11px;
  border-radius:999px;
}

.page{padding-top:30px}

.intro-v9{
  min-height:390px;
  align-items:stretch;
  margin-bottom:30px;
  gap:22px;
}
.intro-copy{
  background:var(--wl-black);
  color:#fff;
  border-radius:30px;
  padding:50px clamp(28px,4vw,60px);
  position:relative;
  overflow:hidden;
  box-shadow:var(--wl-shadow);
}
.intro-copy:after{
  content:"";
  position:absolute;
  right:-90px;
  bottom:-120px;
  width:360px;
  height:360px;
  border-radius:50%;
  background:radial-gradient(circle,rgba(255,191,0,.38),rgba(255,191,0,0) 68%);
}
.intro-copy .pill{
  background:#ffbf00!important;
  color:#111214!important;
  border:0!important;
}
.intro-v9 h1{
  color:#fff!important;
  max-width:820px;
  font-size:clamp(42px,5vw,76px)!important;
  line-height:.94!important;
  margin:20px 0 18px!important;
}
.intro-v9 h1 span{color:var(--wl-yellow)}
.intro-v9 p{
  color:#d8dade!important;
  max-width:650px;
  font-size:16px;
}
.intro-benefits{
  display:flex;
  flex-wrap:wrap;
  gap:8px;
  margin-top:26px;
  position:relative;
  z-index:2;
}
.intro-benefits span{
  background:#26282c;
  border:1px solid #383b40;
  color:#f2f2f2;
  border-radius:999px;
  padding:8px 11px;
  font-size:10px;
  font-weight:800;
}
.brand-hero-panel{
  min-height:390px;
  position:relative;
  border-radius:30px;
  overflow:hidden;
  background:#fff;
  border:1px solid #e0ded8;
  box-shadow:var(--wl-shadow);
}
.brand-hero-panel>img{
  width:100%;
  height:100%;
  object-fit:cover;
  object-position:center;
  display:block;
}
.brand-hero-caption{
  position:absolute;
  left:18px;
  right:18px;
  bottom:18px;
  background:rgba(17,18,20,.93);
  color:#fff;
  border:1px solid rgba(255,255,255,.14);
  backdrop-filter:blur(10px);
  border-radius:18px;
  padding:12px 14px;
  display:flex;
  align-items:center;
  gap:11px;
}
.brand-hero-caption img{
  width:42px;
  height:42px;
  object-fit:contain;
  border-radius:10px;
  background:#fff;
  padding:4px;
}
.brand-hero-caption strong,
.brand-hero-caption small{display:block}
.brand-hero-caption strong{font-size:13px}
.brand-hero-caption small{font-size:9px;color:#bbbfc4;margin-top:2px}

.tool-layout{gap:20px}
.form-panel{gap:14px}

.section-card,
.invoice-preview{
  background:rgba(255,255,255,.97)!important;
  border:1px solid #dededb!important;
  box-shadow:var(--wl-shadow)!important;
}

.section-card{
  border-radius:22px!important;
  position:relative;
  overflow:hidden;
}
.section-card:after{
  content:"";
  position:absolute;
  width:120px;height:120px;
  right:-35px;top:-45px;
  background:url('../assets/weblight-bulb-icon.png?v=9') center/contain no-repeat;
  opacity:.025;
  pointer-events:none;
}
.section-card:hover{border-color:#d4c27b!important}

.brand-step{
  background:var(--wl-yellow)!important;
  color:#111!important;
  border:1px solid #dfa900!important;
  box-shadow:0 5px 14px rgba(255,191,0,.18);
  position:relative;
  overflow:hidden;
}
.brand-step i{
  position:absolute;
  width:9px;height:9px;
  right:2px;bottom:2px;
  border-radius:50%;
  background:#111;
  opacity:.16;
}

.section-head h2{color:#191a1c!important}
.section-head p{color:#777c81!important}
label{color:#53575c!important}
input,select,textarea{
  background:#fbfbfa!important;
  border-color:#d8d9d7!important;
  color:#18191b!important;
}
input:focus,select:focus,textarea:focus{
  border-color:#e1ae12!important;
  box-shadow:0 0 0 3px rgba(255,191,0,.16)!important;
}

.small-btn{
  background:#111214!important;
  border-color:#111214!important;
  color:#ffca24!important;
}
.small-btn:hover{background:#25272a!important}

.save-company-box,
.receipt-toggle{
  background:#faf9f5!important;
  border-color:#e0ddd3!important;
}
.save-company-check input,
.receipt-toggle input{accent-color:#ffbf00!important}

.receipt-card{
  border-top:4px solid var(--wl-yellow)!important;
}
.optional-tag{
  background:#fff1b0!important;
  color:#624b00!important;
  border-color:#e6c752!important;
}

.warning{
  background:#fff8dc!important;
  border-color:#ead272!important;
}
.warning strong{color:#463600!important}
.warning p{color:#665b34!important}

.generate-bar{
  width:min(650px,100%)!important;
  background:linear-gradient(135deg,#151618,#222529)!important;
  border:1px solid #313438!important;
  box-shadow:0 18px 42px rgba(17,18,20,.25)!important;
  grid-template-columns:auto minmax(0,1fr) auto!important;
}
.generate-brand-icon{
  width:42px;height:42px;
  object-fit:contain;
  border-radius:11px;
  background:#fff;
  padding:4px;
}
.generate-bar button{
  background:linear-gradient(135deg,#ffcf36,#ffb900)!important;
  color:#111214!important;
  box-shadow:0 7px 20px rgba(255,191,0,.22)!important;
}
.generate-bar button:hover{transform:translateY(-1px);filter:brightness(1.02)}

.preview-toolbar{
  color:#747a81!important;
  font-weight:800;
}
.invoice-preview{
  border-radius:24px!important;
  overflow:hidden;
  padding-top:0!important;
}
.preview-brandbar{
  margin:0 -32px 28px;
  padding:14px 20px;
  background:#faf9f5;
  border-bottom:1px solid #e1dfd8;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
}
.preview-brandbar img{
  width:145px;
  height:36px;
  object-fit:contain;
  object-position:left center;
}
.preview-brandbar span{
  color:#8b8d8f;
  font-size:8px;
  font-weight:800;
  letter-spacing:.07em;
  text-transform:uppercase;
}
.pv-top{border-bottom-color:#111214!important}
.pv-grand{border-top-color:#111214!important}

.modal{background:rgba(17,18,20,.68)!important}
.modal-card{
  border:1px solid #dbd8cf!important;
  border-top:5px solid var(--wl-yellow)!important;
  overflow:hidden;
}
.modal-card:after{
  content:"";
  position:absolute;
  right:-50px;bottom:-55px;
  width:160px;height:160px;
  background:url('../assets/weblight-bulb-icon.png?v=9') center/contain no-repeat;
  opacity:.05;
}
.modal-brand{
  display:flex;
  align-items:center;
  gap:10px;
  margin-bottom:10px;
}
.modal-brand img{
  width:150px;
  height:38px;
  object-fit:contain;
  object-position:left center;
}
.modal-card h2{color:#151618!important}
.modal-card a{
  background:#111214!important;
  color:#ffca24!important;
}
.modal-badge{color:#9a7318!important}

.footer-v9{
  background:#141517!important;
  color:#c6c8ca!important;
  align-items:center;
  gap:20px;
}
.footer-brand{
  display:flex;
  align-items:center;
  gap:12px;
}
.footer-brand img{
  width:150px;
  height:38px;
  object-fit:contain;
  filter:drop-shadow(0 0 0 transparent);
  background:#fff;
  border-radius:8px;
  padding:4px 7px;
}
.footer-brand span{color:#9fa2a6}

@media(max-width:1100px){
  .intro-v9{grid-template-columns:1fr!important}
  .brand-hero-panel{min-height:310px}
}
@media(max-width:700px){
  .topbar{min-height:72px!important}
  .brand-logo-v9{width:145px!important;height:42px!important}
  .brand-tools small{display:none!important}
  .intro-v9{min-height:0}
  .intro-copy{padding:30px 20px;border-radius:22px}
  .intro-v9 h1{font-size:42px!important}
  .brand-hero-panel{min-height:220px;border-radius:22px}
  .brand-hero-caption{left:10px;right:10px;bottom:10px}
  .generate-bar{
    grid-template-columns:auto 1fr!important;
  }
  .generate-bar button{
    grid-column:1 / -1;
  }
  .preview-brandbar{
    margin:0 -16px 20px;
  }
  .preview-brandbar img{width:118px;height:30px}
  .preview-brandbar span{display:none}
  .footer-v9{align-items:flex-start}
  .footer-brand{flex-direction:column;align-items:flex-start}
}


/* =========================================================
   V10 — clean brand framing
   ========================================================= */
.brand-hero-clean{
  display:grid;
  place-items:center;
  min-height:390px;
  padding:34px;
  background:
    radial-gradient(circle at 50% 18%, rgba(255,191,0,.10), transparent 38%),
    linear-gradient(180deg,#fff 0%,#faf9f5 100%);
}
.brand-showcase{
  width:min(100%,560px);
  min-height:280px;
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  text-align:center;
  border:1px solid #e4e1d9;
  border-radius:24px;
  background:#fff;
  padding:42px 32px 30px;
  box-shadow:0 18px 42px rgba(17,18,20,.07);
  position:relative;
  overflow:hidden;
}
.brand-showcase:before{
  content:"";
  position:absolute;
  left:0;right:0;top:0;
  height:5px;
  background:linear-gradient(90deg,#ffbf00,#ffd950,#ffbf00);
}
.brand-showcase>img{
  width:min(88%,460px);
  height:auto;
  max-height:150px;
  object-fit:contain;
  object-position:center;
  display:block;
  margin:0 auto;
}
.brand-showcase-copy{
  margin-top:24px;
  padding-top:18px;
  width:min(100%,390px);
  border-top:1px solid #ece9e1;
}
.brand-showcase-copy strong,
.brand-showcase-copy span{
  display:block;
}
.brand-showcase-copy strong{
  font-size:13px;
  color:#1b1c1e;
  letter-spacing:.01em;
}
.brand-showcase-copy span{
  font-size:11px;
  color:#7f8387;
  margin-top:3px;
}
.brand-hero-caption{display:none!important}

.generate-bar{
  grid-template-columns:minmax(0,1fr) auto!important;
}
.generate-brand-icon{display:none!important}

.footer-brand{
  display:flex;
  align-items:center;
  gap:12px;
}
.footer-brand>span{
  display:flex;
  flex-direction:column;
  gap:2px;
  color:#fff!important;
}
.footer-brand>span strong{
  color:#fff;
  font-size:11px;
}
.footer-brand>span small{
  color:#aeb1b5;
  font-size:9px;
}
.footer-brand img{
  width:150px;
  height:38px;
  object-fit:contain;
  object-position:center;
  background:#fff;
  border-radius:8px;
  padding:4px 7px;
}
.brand-tools strong{
  font-size:10px!important;
  letter-spacing:.01em;
}
.brand-tools small{
  font-size:9px!important;
}

@media(max-width:700px){
  .brand-hero-clean{min-height:260px;padding:18px}
  .brand-showcase{min-height:220px;padding:30px 18px 22px}
  .brand-showcase>img{width:92%;max-height:110px}
  .generate-bar{grid-template-columns:1fr!important}
}
