:root { --brand:#2563eb; --brand-soft:#e9f1ff; --navy:#102a43; --ink:#263b53; --muted:#6d7d8d; --bg:#f4f7fb; --card:#fff; --line:#dce5ee; --danger:#c0392b; --success:#15803d; --warning:#9a6700; --radius:16px; --radius-small:12px; --space:16px; --shadow:0 10px 32px rgba(16,42,67,.08); --transition:150ms ease; font-family:Inter,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif; color:var(--ink); background:var(--bg); }
* { box-sizing:border-box; }
html { min-width:320px; scroll-behavior:smooth; }
body { margin:0; min-height:100vh; background:var(--bg); }
button,input,select,textarea { font:inherit; }
button { cursor:pointer; }
button:disabled { cursor:not-allowed; opacity:.55; }
.hidden { display:none !important; }
.muted,.help-note { color:var(--muted); }
.eyebrow { color:var(--brand); font-size:.7rem; font-weight:850; letter-spacing:.08em; text-transform:uppercase; }
h1,h2,h3,p { margin-top:0; }
h1 { margin-bottom:8px; color:var(--navy); font-size:clamp(1.8rem,3vw,2.5rem); letter-spacing:-.04em; }
h2 { margin-bottom:4px; color:var(--navy); font-size:1.15rem; letter-spacing:-.02em; }
h3 { margin-bottom:4px; color:var(--navy); font-size:1rem; }
.role-screen { min-height:100vh; display:grid; place-items:center; padding:24px; background:radial-gradient(circle at 15% 10%,var(--brand-soft),transparent 38%),var(--bg); }
.welcome-card { width:min(470px,100%); padding:42px; border:1px solid var(--line); border-radius:24px; background:var(--card); box-shadow:var(--shadow); }
.role-brand { min-height:62px; display:flex; align-items:center; margin-bottom:24px; }
.role-logo { width:170px; max-height:70px; object-fit:contain; object-position:left center; }
.logo-fallback { width:62px; height:62px; display:grid; place-items:center; border-radius:18px; background:var(--brand); color:#fff; font-size:1.45rem; font-weight:900; }
.role-company { display:block; margin-top:18px; color:var(--muted); }
.role-actions { display:grid; gap:12px; margin-top:28px; }
.role-choice { min-height:74px; display:grid; gap:4px; padding:16px 18px; border:1px solid var(--line); border-radius:var(--radius-small); background:#fff; color:var(--navy); text-align:left; transition:transform var(--transition),border-color var(--transition),box-shadow var(--transition); }
.role-choice:hover { border-color:var(--brand); box-shadow:var(--shadow); transform:translateY(-1px); }
.role-choice span { font-weight:850; }
.role-choice small { color:var(--muted); }
.role-choice.primary { border-color:var(--brand); background:var(--brand); color:#fff; }
.role-choice.primary small { color:#dbe8ff; }
.app-shell { min-height:100vh; padding-left:232px; }
.topbar { position:sticky; top:0; z-index:15; min-height:76px; display:flex; align-items:center; justify-content:space-between; gap:16px; padding:14px 30px; border-bottom:1px solid var(--line); background:rgba(255,255,255,.92); backdrop-filter:blur(12px); }
.brand-block { display:flex; align-items:center; gap:12px; min-width:0; }
.brand-block .brand-logo { width:46px; height:46px; object-fit:contain; border-radius:12px; }
.brand-block .logo-fallback { width:46px; height:46px; border-radius:12px; font-size:1rem; }
.brand-block strong,.brand-block small { display:block; }
.brand-block strong { color:var(--navy); }
.brand-block small { max-width:440px; margin-top:3px; overflow:hidden; color:var(--muted); font-size:.74rem; text-overflow:ellipsis; white-space:nowrap; }
.top-actions { display:flex; align-items:center; gap:12px; }
.role-badge,.tag { display:inline-flex; align-items:center; min-height:30px; padding:5px 10px; border-radius:999px; background:var(--brand-soft); color:var(--brand); font-size:.72rem; font-weight:800; }
.text-button,.back-link { border:0; background:transparent; color:var(--brand); font-weight:800; }
.text-button { padding:10px 4px; }
.main-nav { position:fixed; inset:0 auto 0 0; z-index:20; width:232px; display:flex; flex-direction:column; gap:6px; padding:22px 14px; border-right:1px solid var(--line); background:#fff; }
.nav-button { min-height:48px; display:flex; align-items:center; gap:10px; padding:11px 14px; border:0; border-radius:12px; background:transparent; color:var(--muted); font-weight:800; text-align:left; transition:background var(--transition),color var(--transition); }
.nav-button:hover,.nav-button.active { background:var(--brand-soft); color:var(--brand); }
.nav-icon { width:22px; color:currentColor; font-size:1.2rem; text-align:center; }
.count-badge { min-width:22px; margin-left:auto; padding:2px 7px; border-radius:99px; background:var(--brand); color:#fff; font-size:.7rem; text-align:center; }
main { width:min(1180px,100%); margin:0 auto; padding:34px 32px 140px; }
.view { min-height:60vh; }
.page-heading,.item-heading,.section-heading { display:flex; align-items:flex-end; justify-content:space-between; gap:16px; margin-bottom:22px; }
.page-heading h1,.item-heading h1 { margin-bottom:0; }
.primary-button,.outline-button,.whatsapp-button { min-height:46px; display:inline-flex; align-items:center; justify-content:center; gap:6px; padding:11px 16px; border:1px solid var(--brand); border-radius:12px; font-weight:850; transition:filter var(--transition),transform var(--transition),box-shadow var(--transition); }
.primary-button { background:var(--brand); color:#fff; }
.outline-button { background:#fff; color:var(--brand); border-color:var(--line); }
.primary-button:hover,.outline-button:hover,.whatsapp-button:hover { box-shadow:var(--shadow); transform:translateY(-1px); }
.whatsapp-button { border-color:#25d366; background:#25d366; color:#073b1b; }
.search-large,.catalog-line-filter,.saved-filters label:not(.search-large) { display:grid; gap:7px; color:var(--muted); font-size:.76rem; font-weight:800; }
.search-large input,.catalog-line-filter select,.saved-filters select,.field input,.field select,.config-form input,.config-form textarea,.client-grid input,.client-grid textarea { width:100%; min-height:48px; padding:12px 14px; border:1px solid var(--line); border-radius:12px; outline:0; background:#fff; color:var(--ink); }
.search-large input:focus,.catalog-line-filter select:focus,.saved-filters select:focus,.field input:focus,.field select:focus,.config-form input:focus,.config-form textarea:focus,.client-grid input:focus,.client-grid textarea:focus { border-color:var(--brand); box-shadow:0 0 0 3px var(--brand-soft); }
.search-large { margin-bottom:18px; }
.search-large.compact { margin:0; }
.catalog-line-filter { width:min(260px,100%); margin:16px 0; }
.filter-chips { display:flex; gap:8px; overflow-x:auto; padding:2px 1px 8px; scrollbar-width:thin; }
.filter-chip { min-height:42px; flex:0 0 auto; padding:9px 14px; border:1px solid var(--line); border-radius:999px; background:#fff; color:var(--muted); font-weight:800; white-space:nowrap; }
.filter-chip.selected { border-color:var(--brand); background:var(--brand-soft); color:var(--brand); }
.filter-chip small { margin-left:3px; }
.catalog-results,.home-section,.budget-items-section { display:grid; gap:18px; }
.catalog-group { display:grid; gap:10px; }
.catalog-group .section-heading { margin-bottom:0; }
.catalog-group .section-heading h2 { color:var(--muted); font-size:.78rem; font-weight:700; }
.catalog-grid,.home-popular-grid { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:12px; }
.catalog-card,.home-type-card { min-height:260px; display:grid; align-content:start; gap:8px; padding:12px; border:1px solid var(--line); border-radius:var(--radius); background:#fff; color:var(--ink); text-align:left; box-shadow:0 3px 12px rgba(16,42,67,.03); transition:border-color var(--transition),box-shadow var(--transition),transform var(--transition); }
.catalog-card:hover,.home-type-card:hover { border-color:var(--brand); box-shadow:var(--shadow); transform:translateY(-2px); }
.catalog-mini,.home-type-drawing { min-height:154px; display:grid; place-items:center; overflow:hidden; border-radius:12px; background:#f7fafc; }
.catalog-mini svg,.home-type-drawing svg { width:100%; height:150px; }
.catalog-card-type { width:max-content; padding:4px 7px; border-radius:999px; background:var(--brand-soft); color:var(--brand); font-size:.65rem; font-weight:850; }
.catalog-card strong,.home-type-card strong { color:var(--navy); line-height:1.2; }
.catalog-card small,.home-type-card small { color:var(--muted); }
.home-hero { display:flex; align-items:center; justify-content:space-between; gap:24px; margin-bottom:22px; padding:30px; border-radius:24px; background:linear-gradient(135deg,var(--brand),#16386f); color:#fff; box-shadow:var(--shadow); }
.home-hero h1 { margin:5px 0 8px; color:#fff; }
.home-hero p { max-width:600px; margin:0; color:#dbe8ff; }
.home-hero .eyebrow { color:#c6dcff; }
.hero-action { border-color:#fff; background:#fff; color:var(--brand); white-space:nowrap; }
.home-shortcuts { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:12px; margin-bottom:28px; }
.shortcut-card { min-height:116px; display:grid; grid-template-columns:auto 1fr; grid-template-rows:auto auto; gap:4px 12px; padding:18px; border:1px solid var(--line); border-radius:var(--radius); background:#fff; color:var(--ink); text-align:left; }
.shortcut-card:hover { border-color:var(--brand); }
.shortcut-card .shortcut-icon { grid-row:1 / span 2; width:48px; height:48px; display:grid; place-items:center; border-radius:14px; background:var(--brand-soft); color:var(--brand); font-size:1.5rem; }
.shortcut-card strong { align-self:end; color:var(--navy); }
.shortcut-card small { color:var(--muted); }
.muted-shortcut { border-style:dashed; }
.home-section { margin-top:28px; }
.home-budget-list,.saved-list { display:grid; gap:10px; }
.home-budget-card,.saved-card { display:flex; align-items:center; justify-content:space-between; gap:16px; padding:16px 18px; border:1px solid var(--line); border-radius:var(--radius); background:#fff; }
.home-budget-card > div:first-child,.saved-main { display:grid; gap:4px; min-width:0; }
.home-budget-card strong,.saved-main strong { color:var(--navy); }
.home-budget-card span:not(.eyebrow),.saved-main span { color:var(--muted); font-size:.78rem; }
.home-budget-side,.saved-side { display:grid; justify-items:end; gap:5px; white-space:nowrap; }
.home-budget-side > strong,.saved-side > strong { color:var(--navy); font-size:1.05rem; }
.status-chip { display:inline-flex; align-items:center; padding:5px 8px; border-radius:999px; font-size:.68rem; font-weight:850; }
.status-borrador { background:#eef2f6; color:#596979; }.status-enviado { background:#fff4d6; color:#906400; }.status-aceptado { background:#ddf6e5; color:#16723a; }.status-rechazado { background:#ffe4e1; color:#a52b22; }
.home-empty { margin-top:28px; }
.empty-state { display:grid; justify-items:center; gap:8px; padding:38px; border:1px dashed var(--line); border-radius:var(--radius); background:#fff; color:var(--muted); text-align:center; }
.empty-state strong { color:var(--navy); }
.large-empty { min-height:310px; align-content:center; }
.empty-icon { color:var(--brand); font-size:2.4rem; }
.skeleton-panel,.skeleton-grid > div { min-height:160px; border-radius:var(--radius); background:linear-gradient(90deg,#edf2f7,#fff,#edf2f7); background-size:220% 100%; animation:skeleton 1.2s infinite; }
.skeleton-grid { display:grid; grid-template-columns:repeat(4,1fr); gap:12px; }.skeleton-grid > div { min-height:260px; }
@keyframes skeleton { to { background-position:-220% 0; } }
.back-link { margin-bottom:18px; padding:0; }
.item-heading { align-items:center; }
.item-drawing-card { max-width:100%; margin-bottom:18px; padding:16px; border:1px solid var(--line); border-radius:var(--radius); background:#fff; box-shadow:0 5px 18px rgba(16,42,67,.04); }
.item-drawing { height:min(270px,30vh); display:grid; place-items:center; overflow:hidden; border-radius:12px; background:linear-gradient(145deg,#f7fbff,#fff); }
.item-drawing svg { width:100%; height:100%; }.drawing-alt { margin:10px 0 0; color:var(--muted); font-size:.76rem; text-align:center; }
.drawing-skeleton { width:50%; height:60%; border-radius:12px; background:linear-gradient(90deg,#edf2f7,#fff,#edf2f7); background-size:220% 100%; animation:skeleton 1.2s infinite; }
.item-form { display:grid; gap:12px; padding-bottom:110px; }
.item-step { display:grid; grid-template-columns:38px 1fr; gap:14px; padding:20px; border:1px solid var(--line); border-radius:var(--radius); background:#fff; }
.step-number { width:32px; height:32px; display:grid; place-items:center; border-radius:50%; background:var(--brand-soft); color:var(--brand); font-weight:900; }
.item-step h3 { margin:4px 0 16px; font-size:1.12rem; }
.measure-grid,.form-grid,.config-grid,.client-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:12px; }
.field,.config-form label,.client-grid label { display:grid; gap:7px; color:var(--muted); font-size:.76rem; font-weight:800; }
.field-technical { display:none; }.technical-options[open] .field-technical { display:grid; }
.field-error { min-height:0; color:var(--danger); font-size:.72rem; }.field.has-error input,.field.has-error select,.field.has-error .segmented span { border-color:var(--danger); }
.field-full,.wide { grid-column:1/-1; }
.segmented { display:flex; flex-wrap:wrap; gap:7px; }.segmented label { display:flex; min-height:48px; }.segmented input { position:absolute; width:1px; height:1px; opacity:0; }.segmented span { display:grid; place-items:center; padding:10px 13px; border:1px solid var(--line); border-radius:12px; background:#fff; color:var(--ink); }.segmented input:checked + span { border-color:var(--brand); background:var(--brand-soft); color:var(--brand); font-weight:850; }
.color-grid { display:flex; flex-wrap:wrap; gap:9px; }.color-swatch { min-width:65px; min-height:66px; display:grid; justify-items:center; gap:3px; padding:5px; border:2px solid #fff; border-radius:12px; background:#fff; box-shadow:0 0 0 1px var(--line); }.color-swatch span { width:30px; height:30px; border-radius:50%; background:var(--swatch); border:1px solid rgba(0,0,0,.15); }.color-swatch small { max-width:60px; overflow:hidden; color:var(--muted); font-size:.58rem; text-overflow:ellipsis; white-space:nowrap; }.color-swatch.selected { box-shadow:0 0 0 3px var(--brand); }.more-colors,.optional-interiors,.technical-options { width:100%; margin-top:8px; }.more-colors summary,.optional-interiors summary,.technical-options summary { padding:8px 0; color:var(--brand); cursor:pointer; font-weight:850; }.color-grid-rest { display:flex; flex-wrap:wrap; gap:8px; padding-top:8px; }.selection-name,.drawing-alt { color:var(--muted); }.habitual-sizes { display:grid; gap:7px; margin-top:13px; color:var(--muted); font-size:.76rem; font-weight:850; }.habitual-sizes > div { display:flex; flex-wrap:wrap; gap:7px; }.size-choice { min-height:44px; padding:9px 11px; border:1px solid var(--line); border-radius:10px; background:#f8fafc; color:var(--navy); font-weight:800; }.stepper { display:flex; align-items:center; max-width:180px; }.stepper button { min-width:46px; height:48px; border:1px solid var(--line); background:#f8fafc; color:var(--brand); font-size:1.25rem; font-weight:900; }.stepper button:first-child { border-radius:12px 0 0 12px; }.stepper button:last-child { border-radius:0 12px 12px 0; }.stepper input { min-width:54px; height:48px; border:1px solid var(--line); border-left:0; border-right:0; background:#fff; color:var(--navy); text-align:center; }.item-price-bar,.budget-bar { position:fixed; right:0; bottom:0; z-index:14; display:flex; align-items:center; justify-content:space-between; gap:18px; width:calc(100% - 232px); padding:12px 32px; border-top:1px solid var(--line); background:rgba(255,255,255,.96); box-shadow:0 -8px 28px rgba(16,42,67,.08); backdrop-filter:blur(12px); }.item-price-bar > div:first-child,.budget-bar > div:first-child { display:grid; gap:3px; }.item-price-bar span,.budget-bar span { color:var(--muted); font-size:.74rem; }.item-price-bar strong,.budget-bar strong { color:var(--navy); font-size:1.35rem; }.item-bar-actions,.budget-bar-actions { display:flex; align-items:center; gap:8px; }.detail-sheet {}
.budget-items-section { margin-bottom:20px; }.budget-items { display:grid; gap:12px; }.budget-item { display:grid; grid-template-columns:150px 1fr auto; gap:14px; align-items:start; padding:14px; border:1px solid var(--line); border-radius:var(--radius); background:#fff; }.budget-item-drawing { height:130px; display:grid; place-items:center; border-radius:12px; background:#f7fafc; overflow:hidden; }.budget-item-drawing svg { width:100%; height:100%; }.budget-item-info { display:grid; gap:4px; }.budget-item-info h3 { margin:0; }.budget-item-info p { margin:0; color:var(--muted); font-size:.78rem; }.budget-item-total { color:var(--navy); font-size:1.1rem; white-space:nowrap; }.budget-item-footer { grid-column:2/-1; display:flex; align-items:center; justify-content:space-between; gap:12px; }.compact.stepper,.compact.stepper button,.compact.stepper input { height:42px; min-height:42px; }.compact.stepper button { min-width:40px; }.item-menu { position:relative; }.item-menu summary { list-style:none; cursor:pointer; padding:8px 12px; border:1px solid var(--line); border-radius:10px; color:var(--muted); font-size:1.2rem; }.item-menu summary::-webkit-details-marker { display:none; }.item-menu > div { position:absolute; right:0; bottom:calc(100% + 6px); z-index:4; display:grid; min-width:125px; padding:6px; border:1px solid var(--line); border-radius:12px; background:#fff; box-shadow:var(--shadow); }.item-menu button { border:0; background:#fff; padding:10px; color:var(--brand); text-align:left; }.budget-client { display:grid; gap:14px; margin-top:20px; padding:20px; border:1px solid var(--line); border-radius:var(--radius); background:#fff; }.budget-client .section-heading { margin-bottom:0; }.budget-bar > div:first-child { margin-right:auto; }.budget-bar-actions { justify-content:flex-end; }
.saved-filters { display:grid; grid-template-columns:1fr 210px; align-items:end; gap:12px; margin-bottom:18px; }.saved-card { align-items:flex-start; }.saved-main { grid-template-columns:auto 1fr; gap:12px; }.saved-number { color:var(--brand); font-size:1.1rem; font-weight:900; }.saved-side { justify-items:end; }.status-select { min-height:34px; padding:5px 9px; border:0; border-radius:999px; font-size:.72rem; font-weight:850; }.saved-actions { display:flex; flex-wrap:wrap; justify-content:flex-end; gap:8px; }.saved-actions .text-button { padding:4px; font-size:.75rem; }
.config-form { display:grid; gap:22px; }.config-section { display:grid; gap:14px; padding:20px; border:1px solid var(--line); border-radius:var(--radius); background:#fff; }.config-section .section-heading { margin:0; }.config-actions { display:flex; justify-content:flex-end; }.logo-config { display:flex; align-items:center; gap:18px; }.logo-preview { width:180px; height:92px; display:grid; place-items:center; overflow:hidden; border:1px dashed var(--line); border-radius:12px; color:var(--muted); }.logo-preview img { max-width:100%; max-height:100%; object-fit:contain; }
.sheet-overlay { position:fixed; inset:0; z-index:30; display:flex; align-items:flex-end; justify-content:center; padding:20px; background:rgba(16,42,67,.36); }.bottom-sheet { width:min(600px,100%); max-height:80vh; overflow:auto; padding:22px; border-radius:20px 20px 0 0; background:#fff; box-shadow:0 -10px 40px rgba(16,42,67,.18); }.sheet-heading { display:flex; align-items:center; justify-content:space-between; gap:12px; }.icon-button { width:44px; height:44px; border:0; border-radius:12px; background:var(--brand-soft); color:var(--brand); font-size:1.5rem; }.detail-total { display:flex; justify-content:space-between; align-items:center; padding:14px 0; border-bottom:1px solid var(--line); }.detail-total span { color:var(--muted); }.detail-total strong { color:var(--navy); font-size:1.4rem; }.detail-rows { display:grid; gap:8px; padding:14px 0; }.detail-row,.cut-list > div { display:flex; justify-content:space-between; gap:12px; padding:9px 0; border-bottom:1px solid #edf1f5; }.detail-row span,.cut-list span { color:var(--muted); }.technical-details { margin-top:16px; padding-top:14px; border-top:1px solid var(--line); }.technical-details summary { color:var(--brand); cursor:pointer; font-weight:850; }.warning-list { margin:10px 0; padding:12px 14px 12px 28px; border-radius:12px; background:#fff8e6; color:var(--warning); font-size:.8rem; }.add-notice { display:grid; justify-items:center; text-align:center; }.add-notice > div { display:flex; gap:8px; }.success-icon { width:48px; height:48px; display:grid; place-items:center; border-radius:50%; background:#ddf6e5; color:var(--success); font-size:1.5rem; font-weight:900; }
.toast { position:fixed; right:20px; bottom:20px; z-index:50; max-width:min(380px,calc(100vw - 40px)); padding:14px 16px; border-radius:12px; background:var(--navy); color:#fff; box-shadow:var(--shadow); transform:translateY(160%); transition:transform var(--transition); }.toast.show { transform:translateY(0); }
.print-sheet { display:none; }
@media (max-width:1000px) { .catalog-grid,.home-popular-grid { grid-template-columns:repeat(3,minmax(0,1fr)); } }
@media (max-width:760px) { .app-shell { padding-left:0; padding-bottom:70px; }.topbar { min-height:64px; padding:10px 16px; }.main-nav { inset:auto 0 0; width:100%; height:70px; flex-direction:row; justify-content:space-around; padding:6px 8px; border-top:1px solid var(--line); border-right:0; box-shadow:0 -5px 20px rgba(16,42,67,.08); }.nav-button { min-width:0; min-height:56px; flex:1; flex-direction:column; justify-content:center; gap:1px; padding:5px 3px; font-size:.67rem; text-align:center; }.nav-icon { height:22px; font-size:1.1rem; }.count-badge { position:absolute; margin:0 0 29px 31px; padding:1px 5px; }.item-price-bar,.budget-bar { width:100%; padding:10px 14px; }.item-price-bar { align-items:flex-start; flex-direction:column; gap:8px; }.item-bar-actions,.budget-bar-actions { width:100%; }.item-bar-actions > .primary-button,.budget-bar-actions > .whatsapp-button { flex:1; }.budget-bar { align-items:flex-start; flex-direction:column; gap:8px; }.budget-bar-actions { justify-content:stretch; }.budget-bar-actions button { flex:1; }.catalog-grid,.home-popular-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }.catalog-card { min-height:220px; }.catalog-mini,.home-type-drawing { min-height:110px; }.catalog-mini svg,.home-type-drawing svg { height:110px; } main { padding:22px 14px 150px; }.home-hero { align-items:flex-start; flex-direction:column; padding:24px; }.hero-action { width:100%; }.home-shortcuts { grid-template-columns:1fr; }.page-heading,.item-heading { align-items:flex-start; flex-direction:column; }.measure-grid,.form-grid,.config-grid,.client-grid,.saved-filters { grid-template-columns:1fr; }.wide { grid-column:auto; }.budget-item { grid-template-columns:100px 1fr; }.budget-item-total { grid-column:2; grid-row:1; justify-self:end; }.budget-item-footer { grid-column:1/-1; }.saved-card { flex-direction:column; }.saved-side { width:100%; justify-items:start; }.saved-actions { justify-content:flex-start; }.logo-config { align-items:flex-start; flex-direction:column; }.welcome-card { padding:28px 22px; } }
@media (max-width:430px) { .brand-block small { display:none; }.brand-block,.brand-block span { min-width:0; }.brand-block strong { display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }.top-actions { gap:4px; flex-shrink:0; }.home-budget-card { align-items:flex-start; flex-direction:column; }.home-budget-side { width:100%; align-items:start; justify-items:start; }.item-step { grid-template-columns:30px 1fr; gap:10px; padding:14px; }.step-number { width:28px; height:28px; }.item-bar-actions { flex-wrap:wrap; }.item-bar-actions .stepper { order:3; width:100%; max-width:none; }.item-bar-actions .stepper input { flex:1; }.item-bar-actions .outline-button,.item-bar-actions .primary-button { flex:1; }.budget-item { grid-template-columns:1fr; }.budget-item-drawing { height:120px; }.budget-item-total { grid-column:auto; grid-row:auto; justify-self:start; }.budget-item-footer { grid-column:auto; } }
@page { size:A4; margin:12mm; }
@media print { body { background:#fff; } body > *:not(#printSheet) { display:none !important; } #printSheet { display:block; color:#111; font-family:Arial,sans-serif; font-size:10pt; }.print-header { display:flex; justify-content:space-between; gap:20px; padding-bottom:7mm; margin-bottom:5mm; border-bottom:2px solid #111; }.print-brand { display:flex; align-items:flex-start; gap:5mm; }.print-logo { width:27mm; height:18mm; object-fit:contain; }.print-logo-placeholder { width:27mm; height:18mm; display:grid; place-items:center; border:1px dashed #999; color:#777; font-size:8pt; }.print-header h1 { margin:0 0 2mm; font-size:18pt; }.print-header p { margin:1mm 0; font-size:8.5pt; }.print-meta { display:grid; gap:1.5mm; text-align:right; font-size:8.5pt; }.print-client { padding:3mm; margin-bottom:5mm; border:1px solid #ccc; font-size:9pt; }.print-table-head,.print-row { display:grid; grid-template-columns:27mm 1fr 13mm 27mm 29mm; gap:3mm; align-items:center; }.print-table-head { padding:2mm 0; border-bottom:1.5px solid #111; font-size:8pt; font-weight:700; text-transform:uppercase; }.print-row { min-height:38mm; padding:3mm 0; border-bottom:1px solid #ccc; break-inside:avoid; }.print-row-drawing svg { width:27mm; max-height:34mm; }.print-row-description { display:grid; gap:1.3mm; font-size:8.5pt; }.print-row-description strong { font-size:10pt; }.print-row-description span { display:block; }.print-total { margin-top:6mm; text-align:right; font-size:17pt; font-weight:800; }.print-conditions { margin-top:8mm; padding-top:3mm; border-top:1px solid #ccc; font-size:8pt; break-inside:avoid; }.print-conditions ul { margin:2mm 0 0; padding-left:5mm; } }

/* Ajustes de la corrección 3e: las capas fijas quedan por encima de la navegación. */
:root { --brand:#2563eb; --nav-height:70px; --sidebar-width:232px; }
.icon { width:1.25rem; height:1.25rem; flex:0 0 auto; }
.nav-icon { width:22px; height:22px; display:grid; place-items:center; }
.nav-brand { display:flex; align-items:center; gap:9px; min-height:62px; margin-bottom:12px; padding:4px 8px 16px; border-bottom:1px solid var(--line); color:var(--navy); }
.nav-brand .brand-logo { width:42px; height:42px; object-fit:contain; border-radius:12px; }
.nav-brand .logo-fallback { width:42px; height:42px; border-radius:12px; font-size:.9rem; }
.nav-brand strong { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
#changeRole { border:0; cursor:pointer; }
.item-drawing-card { position:sticky; top:92px; z-index:5; }
.item-drawing-card .drawing-alt:empty { display:none; }
.item-price-bar,.budget-bar { width:calc(100% - var(--sidebar-width)); }
.toast { visibility:hidden; opacity:0; pointer-events:none; transform:translateY(calc(100% + 32px)); }
.toast.show { visibility:visible; opacity:1; pointer-events:auto; transform:translateY(0); }
@media (max-width:760px) {
  .app-shell { padding-left:0; padding-bottom:var(--nav-height); }
  .main-nav { height:var(--nav-height); }
  .item-price-bar,.budget-bar { bottom:calc(var(--nav-height) + env(safe-area-inset-bottom)); width:100%; }
  main { padding-bottom:calc(220px + var(--nav-height) + env(safe-area-inset-bottom)); }
  .item-form { padding-bottom:calc(220px + env(safe-area-inset-bottom)); }
  .nav-brand { display:none; }
  .item-drawing-card { top:64px; max-height:30vh; padding:8px; }
  .item-drawing-card .item-drawing { height:min(180px,24vh); }
  .item-drawing-card .drawing-alt { margin:4px 0 0; }
}

/* Tabla de cortes del dueño en la hoja de detalle. */
.detail-table { width:100%; border-collapse:collapse; margin-top:12px; font-size:.78rem; }
.detail-table th,.detail-table td { text-align:left; padding:8px 4px; border-bottom:1px solid #edf1f5; }
.detail-table th { color:var(--muted); font-weight:700; }
.php-login { display:grid; gap:12px; max-width:360px; margin:20px auto 0; text-align:left; }
.php-login h2,.php-login p { margin:0; }
.php-login label { display:grid; gap:5px; }
.php-login input,.php-login select { width:100%; min-height:48px; padding:12px 14px; border:1px solid var(--line); border-radius:12px; background:#fff; color:var(--navy); font:inherit; font-size:1rem; }
.php-login input:focus,.php-login select:focus { outline:2px solid var(--brand); outline-offset:1px; border-color:var(--brand); }
.php-login label > span:first-child { font-weight:700; color:var(--navy); }
.password-field { display:grid; grid-template-columns:1fr auto; gap:8px; align-items:center; }
.password-toggle { min-height:48px; border-radius:12px; padding:0 10px; border:1px solid var(--line); border-radius:8px; background:#fff; color:var(--navy); cursor:pointer; }

/* Ítem en el celular: modo enfocado, sin la navegación inferior y con la barra del precio en dos filas. */
@media (max-width:760px) {
  .item-mode .main-nav { display:none; }
  .item-mode .app-shell { padding-bottom:0; }
  .item-mode .item-price-bar { bottom:0; padding-bottom:calc(10px + env(safe-area-inset-bottom)); }
  .item-mode main { padding-bottom:24px; }
  .item-mode .item-form { padding-bottom:calc(140px + env(safe-area-inset-bottom)); }
}
@media (max-width:430px) {
  .item-price-bar { display:grid; grid-template-columns:minmax(0,1fr) auto; align-items:center; gap:8px 10px; }
  .item-price-bar strong { font-size:1.25rem; }
  .item-bar-actions { display:contents; }
  .item-bar-actions .stepper { order:0; width:auto; max-width:140px; }
  .item-bar-actions .outline-button,.item-bar-actions .primary-button { min-height:46px; }
  /* El dibujo fijo ya trae las cotas: sin el texto de abajo y más bajo, para dejar lugar al formulario. */
  .item-drawing-card { padding:6px; }
  .item-drawing-card .item-drawing { height:min(150px,19vh); }
  .item-drawing-card .drawing-alt { display:none; }
}
