/* Free invoice studio. The form keeps the generator look and the preview is the visitor's own document.
   Self contained so it renders the same inside the marketing frame and the template pages.
   Preview sizes use em, where 1em is 10pt on the printed page, so the screen preview and the print match the PDF. */
.studio,.studio-print-root{--s-font:'Inter',ui-sans-serif,system-ui,-apple-system,'Segoe UI',Roboto,sans-serif;--s-navy:#11254e;--s-ink:#141d33;--s-blue:#295bb1;--s-line:#dce5ee;--s-line-2:#ccd9e7;--s-wash:#f6f9fd;--s-muted:#565c6c;--brand:#1f3a5f;--brand-on:#fff;--brand-ink:#1f3a5f;--brand-tint:#e9ebef;font-family:var(--s-font);color:var(--s-ink)}
.studio *,.studio *:before,.studio *:after{box-sizing:border-box}
/* Embedded on the template pages: no marketing frame, so reset spacing and use the page font for the form. */
.studio-embed .studio{--s-font:var(--font-mobilify-sans),ui-sans-serif,system-ui,-apple-system,'Segoe UI',Roboto,sans-serif;padding:0;background:none}
.studio-embed .studio .wrap{width:auto;max-width:none;margin-inline:0}
.studio-embed .studio :is(p,h1,h2,h3,dl,dd,figure){margin:0}
.studio-embed .studio img{display:block;max-width:100%}
.studio-embed>p[role=status]{margin:16px 0 0;padding:12px 14px;border-radius:8px;background:#f1f7ff;color:#173e72;font:600 14px/1.5 var(--font-mobilify-sans),sans-serif}
.studio .generator{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:clamp(24px,3.5vw,56px);align-items:start}
.studio .gen-left{display:grid;gap:16px;min-width:0}
.studio .gen-intro{display:grid;gap:8px}
.studio .gen-intro .eyebrow{margin:0;font:600 12.5px/1.2 var(--s-font);letter-spacing:.14em;text-transform:uppercase;color:var(--s-blue)}
.studio .gen-intro h1,.studio .gen-intro h2{margin:0;font-size:clamp(28px,2.7vw,42px);line-height:1.06;letter-spacing:-.026em;font-weight:600;color:var(--s-navy)}
.studio .gen-intro .lede{margin:0;font-size:clamp(15px,1.15vw,18px);line-height:1.55;color:var(--s-muted);max-width:58ch}
.studio .gen-form{display:grid;gap:18px;padding:clamp(16px,1.8vw,24px);border-radius:24px;background:#fff;border:1px solid var(--s-line);box-shadow:0 1px 2px rgba(17,37,78,.06),0 12px 32px -12px rgba(17,37,78,.18)}
.studio-group{margin:0;padding:0;border:0;display:grid;gap:12px;min-width:0}
.studio-group+.studio-group{padding-top:16px;border-top:1px solid var(--s-line)}
.studio-group>legend{padding:0;margin-bottom:12px;font:700 13px/1.2 var(--s-font);letter-spacing:.06em;text-transform:uppercase;color:var(--s-navy)}
.studio .fields{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
.studio .fields .wide{grid-column:1/-1}
.studio .gen-form label,.studio-label{display:grid;gap:8px;text-transform:none;letter-spacing:0;font:600 12.5px/1.2 var(--s-font);color:var(--s-navy);min-width:0}
.studio .gen-form input:not([type=radio]):not([type=file]):not([type=color]),.studio .gen-form select,.studio .gen-form textarea{width:100%;min-width:0;min-height:42px;margin:0;padding:0 12px;border:1px solid var(--s-line-2);border-radius:10px;background:var(--s-wash);font:500 15px/1.2 var(--s-font);color:var(--s-ink)}
.studio .gen-form textarea{padding:10px 12px;line-height:1.4;resize:vertical;min-height:64px}
.studio .gen-form input:focus,.studio .gen-form select:focus,.studio .gen-form textarea:focus{background:#fff;border-color:var(--s-blue);outline:0;box-shadow:0 0 0 3px rgba(41,91,177,.15)}
.studio .gen-form input[readonly]{color:var(--s-muted)}
.studio .gen-form input[type=color]{width:100%;height:42px;padding:3px;border:1px solid var(--s-line-2);border-radius:10px;background:#fff;cursor:pointer}
.studio-brand-row{display:grid;grid-template-columns:minmax(0,1.4fr) minmax(0,1fr);gap:12px;align-items:end}
.studio-logo{display:grid;gap:8px;min-width:0}
.studio-logo-row{display:flex;align-items:center;gap:12px;min-height:42px}
.studio-logo-row img{max-height:42px;max-width:120px;width:auto;height:auto;object-fit:contain}
.studio .gen-form .studio-upload{display:inline-flex;align-items:center;justify-content:center;min-height:42px;padding:0 16px;border:1px dashed var(--s-line-2);border-radius:10px;background:#fff;color:var(--s-blue);font:600 14px/1 var(--s-font);cursor:pointer;position:relative;white-space:nowrap}
.studio-upload input{position:absolute;inset:0;opacity:0;cursor:pointer;width:100%}
.studio-upload:focus-within{outline:2px solid var(--s-blue);outline-offset:2px}
.studio-ghost{border:0;background:none;color:var(--s-muted);font:600 13px/1 var(--s-font);text-decoration:underline;cursor:pointer;padding:8px 4px;white-space:nowrap}
.studio-layouts{margin:0;padding:0;border:0;display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px;min-width:0}
.studio-layouts legend{padding:0;margin-bottom:8px;font:600 12.5px/1.2 var(--s-font);color:var(--s-navy)}
.studio .gen-form .studio-layout{position:relative;gap:6px;font-weight:600;font-size:12.5px;text-align:center;cursor:pointer}
.studio-layout input{position:absolute;opacity:0;width:1px;height:1px}
.studio-thumb{display:block;aspect-ratio:17/22;border:1px solid var(--s-line-2);border-radius:6px;background:#fff;position:relative;overflow:hidden;transition:border-color .2s,box-shadow .2s}
.studio-thumb i{position:absolute;display:block;left:14%;right:14%;height:4%;background:#e2e6ec;border-radius:1px}
.studio-thumb i:nth-child(1){top:12%;right:56%;height:7%;background:var(--brand)}
.studio-thumb i:nth-child(2){top:34%;height:30%;background:repeating-linear-gradient(#e2e6ec 0 2px,transparent 2px 7px)}
.studio-thumb i:nth-child(3){top:74%;left:58%;height:5%;background:var(--brand)}
.studio-thumb-classic:after{content:"";position:absolute;left:14%;right:14%;top:25%;height:2px;background:var(--brand)}
.studio-thumb-modern:before{content:"";position:absolute;left:0;top:0;bottom:0;width:6%;background:var(--brand)}
.studio-thumb-modern:after{content:"";position:absolute;left:14%;right:14%;top:23%;height:7%;background:var(--brand-tint)}
.studio-thumb-bold:before{content:"";position:absolute;left:0;right:0;top:0;height:27%;background:var(--brand)}
.studio-thumb-bold i:nth-child(1){background:#fff}
.studio-thumb-minimal i:nth-child(1),.studio-thumb-minimal i:nth-child(3){background:#9aa3af}
.studio-layout input:checked+.studio-thumb{border-color:var(--s-blue);box-shadow:0 0 0 2px var(--s-blue)}
.studio-layout input:focus-visible+.studio-thumb{outline:2px solid var(--s-blue);outline-offset:3px}
.studio .items{display:grid;gap:8px}
.studio .item{display:grid;grid-template-columns:minmax(0,2fr) minmax(0,.7fr) minmax(0,.9fr) 36px;gap:8px;align-items:end}
.studio .remove{height:42px;padding:0;border:1px solid var(--s-line);border-radius:10px;background:#fff;color:var(--s-muted);cursor:pointer;display:grid;place-items:center}
.studio .remove:hover{color:#b42318;border-color:#f3c7c0}
.studio .remove:disabled{opacity:.4;cursor:default}
.studio .generator-tools{display:flex;justify-content:space-between;align-items:end;gap:12px;flex-wrap:wrap}
.studio .generator-tools>button{display:inline-flex;align-items:center;gap:8px;border:1px dashed var(--s-line-2);background:#fff;color:var(--s-blue);font-weight:600;border-radius:10px;min-height:42px;padding:0 16px;cursor:pointer}
.studio .generator-tools label{width:170px}
.studio-tax{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
.studio .hint{margin:0;font-size:13px;line-height:1.45;color:var(--s-muted)}
.studio .hint a{color:var(--s-blue)}
.studio .gen-foot{display:flex;align-items:center;justify-content:space-between;gap:12px;padding-top:16px;border-top:1px solid var(--s-line);flex-wrap:wrap}
.studio .gen-foot .hint{max-width:30ch}
.studio-actions{display:flex;gap:10px;flex-wrap:wrap}
.studio .studio-btn{display:inline-flex;align-items:center;justify-content:center;min-height:50px;padding:0 22px;border-radius:999px;font:600 15px/1 var(--s-font);cursor:pointer;border:1px solid var(--s-line-2);background:#fff;color:var(--s-navy)}
.studio .studio-btn-primary{border:0;background:var(--s-navy);color:#fff;box-shadow:0 10px 24px -10px rgba(17,37,78,.55)}
.studio .studio-btn-primary:hover{background:#0b1b3d}
.studio .studio-btn:disabled{opacity:.6;cursor:progress}
.studio-pitch{margin:0;padding-top:28px;font-size:15px;color:var(--s-muted)}
.studio-pitch a{color:var(--s-blue);font-weight:600}
.studio .gen-preview{position:sticky;top:96px;min-width:0}
.studio .gen-preview .note{margin:12px 0 0;text-align:center;font-size:13px;color:var(--s-muted)}

/* The document preview */
.sd-wrap{container-type:inline-size;width:100%}
.sd{position:relative;width:100%;aspect-ratio:8.5/11;padding:4.8em;display:flex;flex-direction:column;background:#fff;color:#111827;font:400 calc(100cqw/61.2)/1.35 Helvetica,Arial,sans-serif;text-align:left;border-radius:6px;box-shadow:0 2px 4px rgba(17,37,78,.05),0 40px 80px -32px rgba(17,37,78,.35);-webkit-box-decoration-break:clone;box-decoration-break:clone}
.sd.sd-a4{aspect-ratio:210/297;font-size:calc(100cqw/59.53)}
.sd p,.sd dl,.sd dd{margin:0}
.sd small,.sd dt{display:block;font-size:.75em;font-weight:700;letter-spacing:.02em;color:var(--brand-ink)}
.sd-head{display:flex;justify-content:space-between;align-items:flex-start;gap:2em}
.sd-from{display:grid;justify-items:start;gap:.3em;max-width:26em;min-width:0}
.sd-logo{display:block;max-width:16em;max-height:6em;width:auto;height:auto;margin-bottom:1.1em}
.sd-logo[hidden]{display:none}
.sd-biz{font-size:1.5em;font-weight:700;line-height:1.2;overflow-wrap:anywhere}
.sd-lines{display:block;font-size:.9em;line-height:1.33;color:#5b6472;white-space:pre-line;overflow-wrap:anywhere}
.sd-lines:empty{display:none}
.sd-title{display:grid;justify-items:end;gap:.5em;text-align:right;flex:none}
.sd-title b{font-size:2.6em;line-height:1;font-weight:700;color:var(--brand-ink)}
.sd-title span{color:#5b6472}
.sd-rule{height:.2em;margin:1.6em 0 2.6em;background:var(--brand)}
.sd-chips{display:none}
.sd-info{display:flex;justify-content:space-between;gap:2em;margin-bottom:2.4em}
.sd-party{display:grid;align-content:start;gap:.35em;max-width:26em;min-width:0}
.sd-party b{font-size:1.1em;overflow-wrap:anywhere}
.sd-meta{display:grid;align-content:start;gap:.6em;width:21em;flex:none}
.sd-meta div{display:flex;justify-content:space-between;gap:1.5em}
.sd-meta dd{font-size:.95em;text-align:right;overflow-wrap:anywhere}
.sd-meta div:has(dd:empty){display:none}
.sd-table{width:100%;border-collapse:collapse;table-layout:fixed}
.sd-table th{padding:.7em .8em;font-size:.8em;font-weight:700;text-transform:uppercase;text-align:right;color:var(--brand-ink);border-bottom:.15em solid var(--brand)}
.sd-table th:nth-child(2){width:7em}.sd-table th:nth-child(3){width:9.5em}.sd-table th:nth-child(4){width:10.5em}
.sd-table td{padding:.8em;text-align:right;vertical-align:top;border-bottom:.05em solid #e2e6ec;overflow-wrap:anywhere}
.sd-table th:first-child,.sd-table td:first-child{text-align:left}
.sd-table tr{break-inside:avoid}
.sd-foot{display:flex;justify-content:space-between;gap:2em;margin-top:1.4em;break-inside:avoid}
.sd-notes{display:grid;align-content:start;gap:1em;max-width:25em;min-width:0}
.sd-notes p{display:grid;gap:.35em;font-size:.9em}
.sd-notes p:has(span:empty){display:none}
.sd-sum{display:grid;align-content:start;gap:.55em;width:23em;flex:none}
.sd-sum p{display:flex;justify-content:space-between;gap:1em;font-size:.95em}
.sd-sum p>span{color:#5b6472}
.sd-sum p:not(.sd-total) b{font-weight:400}
.sd-sum p:has(b:empty){display:none}
.sd-sum .sd-total{margin-top:.4em;padding-top:.8em;border-top:.15em solid var(--brand);font-size:1em;align-items:baseline}
.sd-total>span{color:#111827!important;font-weight:700}
.sd-total b{font-size:1.3em}
.sd-sign{display:grid;grid-template-columns:1fr 1fr;gap:2em;margin-top:3.2em}
.sd-sign span{padding-top:.5em;border-top:.06em solid #5b6472;font-size:.8em;color:#5b6472}
.sd-thanks{margin-top:2.6em!important;font-size:.95em;color:#5b6472}
.sd-end{margin-top:auto;padding-top:2.4em;text-align:center;font-size:.75em}
.sd-end a{color:#5b6472;text-decoration:none}
.sd-no{font-style:normal}
/* Modern */
.sd-modern:before{content:"";position:absolute;left:0;top:0;bottom:0;width:1em;background:var(--brand);border-radius:6px 0 0 6px}
.sd-modern .sd-title b{font-size:1.2em}
.sd-modern .sd-title span{font-size:2em;font-weight:700;color:#111827}
.sd-modern .sd-no,.sd-minimal .sd-no{display:none}
.sd-modern .sd-rule{display:none}
.sd-modern .sd-chips{display:grid;grid-auto-flow:column;grid-auto-columns:1fr;gap:1em;margin:2.4em 0 2.2em;padding:1.2em 1.4em;background:var(--brand-tint)}
.sd-modern .sd-chips p{display:grid;gap:.55em}
.sd-modern .sd-chips b{font-size:1.1em}
.sd-modern .sd-chips p:has(b:empty){display:none}
.sd-modern .sd-meta div:not(.sd-service){display:none}
.sd-modern .sd-table thead tr{background:var(--brand-tint)}
.sd-modern .sd-table th{border:0}
.sd-modern .sd-table td{border:0}
.sd-modern .sd-table tbody tr:nth-child(even){background:#f7f8fa}
.sd-modern .sd-total,.sd-bold .sd-total{margin-inline:-1em 0;padding:.8em 1em;border:0;background:var(--brand-tint)}
.sd-modern .sd-total>span,.sd-modern .sd-total b{color:var(--brand-ink)!important}
/* Bold header */
.sd-bold .sd-head{margin:-4.8em -4.8em 0;padding:2.8em 4.8em 2.6em;background:var(--brand);color:var(--brand-on);border-radius:6px 6px 0 0}
.sd-bold .sd-lines,.sd-bold .sd-title span,.sd-bold .sd-title b{color:inherit}
.sd-bold .sd-title b{font-size:3em}
.sd-bold .sd-logo{box-sizing:content-box;padding:.8em;background:#fff;max-height:5.2em;max-width:15em}
.sd-bold .sd-rule{height:0;margin:0 0 3em;background:none}
.sd-bold .sd-table thead tr{background:var(--brand)}
.sd-bold .sd-table th{color:var(--brand-on);border:0}
.sd-bold .sd-total{background:var(--brand)}
.sd-bold .sd-total>span,.sd-bold .sd-total b{color:var(--brand-on)!important}
/* Minimal */
.sd-minimal small,.sd-minimal dt,.sd-minimal .sd-table th{color:#5b6472}
.sd-minimal .sd-title b{font-size:1.1em;color:#5b6472}
.sd-minimal .sd-title span{color:#111827}
.sd-minimal .sd-logo{max-height:4em;max-width:12em}
.sd-minimal .sd-biz{font-size:1.3em}
.sd-minimal .sd-rule{height:.06em;background:#e2e6ec}
.sd-minimal .sd-table th{border-bottom:.06em solid #e2e6ec}
.sd-minimal .sd-total{border-top:.06em solid #e2e6ec}
.sd-minimal .sd-total b{color:var(--brand-ink)}

@media (max-width:1100px){.studio .fields{grid-template-columns:1fr 1fr}}
@media (max-width:900px){.studio .generator{grid-template-columns:1fr}.studio .gen-preview{position:static}}
@media (max-width:560px){
 .studio .fields,.studio-brand-row,.studio-tax{grid-template-columns:1fr}
 .studio-layouts{grid-template-columns:repeat(4,minmax(0,1fr));gap:8px}
 .studio .item{grid-template-columns:minmax(0,1.6fr) minmax(0,.7fr) minmax(0,.9fr) 32px}
 .studio .generator-tools label{width:100%}
 .studio-actions,.studio .studio-btn{width:100%}
 .studio-actions .studio-btn{flex:1 1 0}
}

/* Print only the document, at the chosen paper size. The page rule is added by the Print button. */
.studio-print-root{display:none}
@media print{
 html.studio-printing body>*:not(.studio-print-root){display:none!important}
 html.studio-printing .studio-print-root{display:block!important}
 html.studio-printing,html.studio-printing body{margin:0;padding:0;background:#fff}
 .studio-print-root .sd{aspect-ratio:auto;min-height:10.9in;border-radius:0;box-shadow:none;-webkit-print-color-adjust:exact;print-color-adjust:exact}
 .studio-print-root .sd.sd-a4{min-height:295mm}
 .studio-print-root .sd-bold .sd-head,.studio-print-root .sd-modern:before{border-radius:0}
}
