:root {
  --primary: #12343d;
  --primary-2: #0c2830;
  --accent: #24b7aa;
  --accent-pale: #e8f8f6;
  --ink: #152d35;
  --muted: #71858b;
  --line: #dce7e9;
  --paper: #fff;
  --surface: #f5f8f8;
  --danger: #b83b44;
  --shadow: 0 16px 50px rgba(16, 49, 58, .08);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; color: var(--ink); background: var(--surface); font-family: Arial, sans-serif; font-size: 14px; }
button, input, select, textarea, output { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; }
.site-container { width: min(1180px, calc(100% - 36px)); margin-inline: auto; }
.honeypot { position: fixed !important; left: -10000px !important; width: 1px !important; height: 1px !important; opacity: 0 !important; }

.button { min-height: 42px; display: inline-flex; align-items: center; justify-content: center; gap: 9px; border: 1px solid transparent; border-radius: 11px; padding: 0 17px; font-weight: 700; cursor: pointer; transition: transform .15s ease, box-shadow .15s ease, background .15s ease; }
.button:hover { transform: translateY(-1px); }
.button:disabled { opacity: .55; cursor: wait; transform: none; }
.button-primary { color: #fff; background: var(--primary); box-shadow: 0 10px 26px rgba(18, 52, 61, .17); }
.button-primary:hover { background: var(--primary-2); }
.button-light { color: var(--primary); background: #eff6f5; border-color: #d7e7e5; }
.button-ghost { color: var(--primary); background: #fff; border-color: var(--line); }
.button-large { min-height: 52px; padding-inline: 24px; }
.eyebrow { color: var(--accent); font-size: 12px; font-weight: 800; letter-spacing: .04em; }

.brand-lockup { min-width: 0; display: inline-flex; align-items: center; gap: 11px; }
.brand-lockup > span:last-child { min-width: 0; display: grid; gap: 3px; }
.brand-lockup strong { color: var(--primary); font-size: 13px; line-height: 1.25; white-space: nowrap; }
.brand-lockup small { color: #75898e; font-size: 8px; direction: ltr; text-align: right; white-space: nowrap; }
.brand-symbol { width: 43px; height: 43px; flex: 0 0 auto; border-radius: 13px; background: var(--primary); display: grid; place-items: center; transform: rotate(45deg); box-shadow: inset 0 0 0 4px rgba(255,255,255,.08); }
.brand-symbol i { width: 18px; height: 18px; border: 4px solid var(--accent); display: block; }
.brand-logo-image { width: auto; max-width: 115px; height: 52px; object-fit: contain; }
.brand-compact .brand-symbol { width: 35px; height: 35px; border-radius: 10px; }
.brand-compact .brand-symbol i { width: 14px; height: 14px; border-width: 3px; }
.brand-compact .brand-logo-image { max-width: 95px; height: 42px; }

.notice { margin: 0 0 16px; padding: 13px 16px; border: 1px solid; border-radius: 12px; line-height: 1.7; }
.notice ul { margin: 7px 0 0; padding-right: 20px; }
.notice-success { color: #146c5f; background: #e7f8f4; border-color: #bce8df; }
.notice-error { color: #9b333b; background: #fff0f1; border-color: #f0c9cc; }

/* Public form */
.public-header { height: 76px; background: rgba(255,255,255,.96); border-bottom: 1px solid #e4ecee; position: sticky; top: 0; z-index: 20; backdrop-filter: blur(14px); }
.header-inner { height: 100%; display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.brand-link { min-width: 0; }
.header-actions { display: flex; align-items: center; gap: 15px; }
.secure-note { display: inline-flex; align-items: center; gap: 7px; color: #71858a; font-size: 11px; }
.secure-note i { width: 8px; height: 8px; border-radius: 50%; background: #28b985; box-shadow: 0 0 0 4px #e1f6ee; }
.quote-hero { padding: 58px 0 93px; color: #fff; background: linear-gradient(120deg, var(--primary-2), var(--primary) 62%, #174d55); position: relative; overflow: hidden; }
.quote-hero::before, .quote-hero::after { content: ''; position: absolute; border: 1px solid rgba(255,255,255,.07); transform: rotate(45deg); }
.quote-hero::before { width: 350px; height: 350px; left: -120px; top: -185px; }
.quote-hero::after { width: 230px; height: 230px; right: 12%; bottom: -170px; }
.hero-grid { display: grid; grid-template-columns: minmax(0,1.25fr) minmax(320px,.75fr); gap: 70px; align-items: center; position: relative; z-index: 1; }
.quote-hero h1 { margin: 13px 0 16px; font-size: clamp(34px, 4.7vw, 59px); line-height: 1.13; letter-spacing: -.045em; }
.quote-hero h1 em { color: #71d9cf; font-style: normal; }
.quote-hero p { max-width: 680px; margin: 0; color: #c1d1d4; font-size: 15px; line-height: 1.85; }
.hero-points { margin-top: 25px; display: flex; flex-wrap: wrap; gap: 9px; }
.hero-points span { padding: 8px 12px; border: 1px solid rgba(255,255,255,.12); border-radius: 99px; color: #d4e2e4; background: rgba(255,255,255,.04); font-size: 10px; }
.hero-stat-card { padding: 26px; border: 1px solid rgba(255,255,255,.13); border-radius: 18px; background: rgba(255,255,255,.06); box-shadow: 0 25px 60px rgba(0,0,0,.14); }
.hero-stat-card > span { color: var(--accent); font-size: 10px; }
.hero-stat-card strong { display: block; margin: 10px 0; font-size: 24px; }
.hero-stat-card p { font-size: 12px; line-height: 1.8; }
.form-wrap { position: relative; margin-top: -52px; padding-bottom: 60px; z-index: 3; }
.request-form { display: grid; gap: 18px; }
.form-card { padding: 28px; border: 1px solid var(--line); border-radius: 19px; background: #fff; box-shadow: var(--shadow); }
.compact-card { padding-bottom: 23px; }
.section-heading { margin-bottom: 23px; display: flex; align-items: flex-start; gap: 13px; }
.section-heading > span { width: 38px; height: 38px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 11px; color: var(--primary); background: var(--accent-pale); font-weight: 800; }
.section-heading h2 { margin: 0 0 5px; font-size: 19px; }
.section-heading p { margin: 0; color: var(--muted); font-size: 11px; line-height: 1.6; }
.section-heading.with-action { align-items: center; }
.section-heading.with-action > div { flex: 1; }
.section-heading.small { margin-top: 24px; margin-bottom: 17px; }
.section-heading.small:first-child { margin-top: 0; }
.section-heading.small > span { width: 32px; height: 32px; font-size: 11px; }
.section-heading.small h2 { font-size: 16px; }
.form-grid { display: grid; gap: 15px; }
.form-grid.three { grid-template-columns: repeat(3,minmax(0,1fr)); }
.form-grid.two { grid-template-columns: repeat(2,minmax(0,1fr)); }
.span-full { grid-column: 1 / -1; }
.field { min-width: 0; display: grid; gap: 7px; }
.field > span, .mini-form label > span, .settings-form label > span, .settings-textareas label > span, .type-edit-form label > span { color: #5f747a; font-size: 10px; font-weight: 700; }
.field b { color: #d04f59; }
.field input, .field select, .field textarea, .mini-form input, .mini-form select, .settings-form input, .settings-form select, .settings-textareas textarea, .type-edit-form input { width: 100%; min-height: 44px; border: 1px solid #d7e3e5; border-radius: 10px; padding: 0 12px; color: var(--ink); background: #fbfcfc; outline: none; transition: border .15s, box-shadow .15s; }
.field textarea, .settings-textareas textarea { min-height: 85px; padding: 11px 12px; line-height: 1.75; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus, .mini-form input:focus, .settings-form input:focus, .settings-textareas textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 4px rgba(36,183,170,.09); background: #fff; }
.field input::placeholder, .field textarea::placeholder { color: #a7b3b6; }
.items-stack { display: grid; gap: 12px; }
.product-item { position: relative; display: grid; grid-template-columns: 62px minmax(0,1fr); gap: 16px; padding: 18px 19px; border: 1px solid #dce7e9; border-radius: 15px; background: #fafcfc; }
.item-number { padding-left: 14px; border-left: 1px solid #dce6e8; display: grid; align-content: center; justify-items: center; gap: 3px; }
.item-number span { color: #93a1a5; font-size: 8px; }
.item-number strong { color: var(--primary); font-size: 21px; }
.product-grid { display: grid; grid-template-columns: 1.45fr repeat(5,minmax(85px,.7fr)); gap: 12px; align-items: end; }
.product-type-field { grid-column: auto; }
.item-notes { grid-column: 1 / -1; }
.field.read-only output { min-height: 44px; display: flex; align-items: center; padding: 0 12px; border: 1px dashed #cbdadb; border-radius: 10px; color: #4b686d; background: #f0f6f6; font-size: 11px; }
.remove-item { position: absolute; left: -8px; top: -8px; width: 26px; height: 26px; border: 1px solid #f0ccd0; border-radius: 50%; color: var(--danger); background: #fff; cursor: pointer; font-size: 16px; }
.remove-item[hidden] { display: none; }
.quantity-summary { margin-top: 16px; padding: 15px 18px; display: grid; grid-template-columns: 130px minmax(170px,auto) 1fr; gap: 26px; align-items: center; border-radius: 13px; color: #fff; background: var(--primary); }
.quantity-summary > div { display: grid; gap: 4px; }
.quantity-summary span { color: #9fb3b8; font-size: 9px; }
.quantity-summary strong { font-size: 15px; }
.quantity-summary p { margin: 0; color: #b7c8cb; font-size: 9px; text-align: left; }
.submit-row { padding: 19px 22px; display: flex; align-items: center; justify-content: space-between; gap: 20px; border: 1px solid var(--line); border-radius: 16px; background: #fff; box-shadow: var(--shadow); }
.submit-row > div { display: grid; gap: 5px; }
.submit-row > div strong { font-size: 15px; }
.submit-row > div span { color: var(--muted); font-size: 10px; }
.client-error { margin: 0; }
.success-banner { margin-bottom: 18px; padding: 18px 20px; display: flex; align-items: center; gap: 15px; border: 1px solid #bce7dc; border-radius: 15px; color: #145e55; background: #e9f9f5; box-shadow: var(--shadow); }
.success-icon { width: 43px; height: 43px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 50%; color: #fff; background: #29ad92; font-size: 20px; }
.success-banner > div:nth-child(2) { display: grid; gap: 3px; }
.success-banner span { font-size: 10px; }
.success-banner strong { font-size: 16px; direction: ltr; text-align: right; }
.success-banner p { margin: 0; font-size: 11px; }
.public-footer { padding: 31px 0; border-top: 1px solid var(--line); background: #fff; }
.public-footer .site-container { display: flex; align-items: center; gap: 28px; }
.public-footer p { margin: 0; color: #72858a; font-size: 10px; }

/* Installer and login */
.install-body, .login-body { min-height: 100vh; background: linear-gradient(145deg, #eef5f5, #f9fbfb 50%, #e9f3f2); }
.install-shell { width: min(1120px, calc(100% - 34px)); min-height: 100vh; margin: auto; padding: 45px 0; display: grid; grid-template-columns: .75fr 1.25fr; gap: 28px; align-items: start; }
.install-intro { position: sticky; top: 45px; padding: 35px; border-radius: 22px; color: #fff; background: linear-gradient(145deg, var(--primary), var(--primary-2)); box-shadow: var(--shadow); }
.install-intro h1 { margin: 12px 0 14px; font-size: 34px; }
.install-intro p { margin: 0; color: #bfd0d3; line-height: 1.9; }
.requirements { margin-top: 27px; display: grid; gap: 9px; }
.requirements > div { min-height: 42px; padding: 9px 11px; display: flex; align-items: center; gap: 10px; border-radius: 10px; background: rgba(255,255,255,.07); font-size: 11px; }
.requirements b { width: 24px; height: 24px; display: grid; place-items: center; border-radius: 50%; }
.req-ok b { color: #fff; background: #2ba88c; }
.req-error b { color: #fff; background: #d45760; }
.install-card, .login-card { padding: 30px; border: 1px solid var(--line); border-radius: 20px; background: #fff; box-shadow: var(--shadow); }
.install-button { width: 100%; margin-top: 24px; }
.login-shell { width: min(940px, calc(100% - 34px)); min-height: 100vh; margin: auto; padding: 35px 0; display: grid; grid-template-columns: 1.05fr .95fr; align-items: stretch; }
.login-brand-panel { padding: 46px; display: flex; flex-direction: column; justify-content: space-between; border-radius: 0 24px 24px 0; color: #fff; background: linear-gradient(145deg, var(--primary), var(--primary-2)); }
.login-brand-panel .brand-lockup strong { color: #fff; }
.login-brand-panel .brand-lockup small { color: #a8c0c4; }
.login-brand-panel .brand-symbol { background: rgba(255,255,255,.1); }
.login-brand-panel h1 { margin: 12px 0; font-size: 37px; line-height: 1.3; }
.login-brand-panel p { color: #b9cbce; line-height: 1.8; }
.login-card { border-radius: 24px 0 0 24px; display: flex; flex-direction: column; justify-content: center; }
.login-card h2 { margin: 0 0 8px; font-size: 27px; }
.login-card > p { margin: 0 0 22px; color: var(--muted); }
.login-card form { display: grid; gap: 16px; }
.back-link { margin-top: 20px; color: #6c8186; text-align: center; font-size: 11px; }

/* Admin */
.admin-body { background: #f3f7f7; }
.admin-shell { min-height: 100vh; display: grid; grid-template-columns: 248px minmax(0,1fr); }
.admin-sidebar { height: 100vh; position: sticky; top: 0; z-index: 35; padding: 24px 16px 16px; display: flex; flex-direction: column; color: #fff; background: var(--primary-2); }
.sidebar-brand { min-height: 63px; padding: 0 7px 18px; border-bottom: 1px solid rgba(255,255,255,.1); overflow: hidden; }
.sidebar-brand .brand-lockup strong { color: #fff; font-size: 11px; }
.sidebar-brand .brand-lockup small { color: #809a9f; font-size: 6.5px; }
.sidebar-brand .brand-logo-image { filter: brightness(0) invert(1); max-width: 90px; }
.admin-nav { margin-top: 22px; display: grid; gap: 7px; }
.admin-nav a { min-height: 44px; padding: 0 13px; display: flex; align-items: center; gap: 11px; border-radius: 10px; color: #a9bcc0; font-size: 11px; font-weight: 700; }
.admin-nav a i { width: 8px; height: 8px; border: 2px solid #6e898f; border-radius: 2px; transform: rotate(45deg); }
.admin-nav a:hover { color: #fff; background: rgba(255,255,255,.05); }
.admin-nav a.active { color: #fff; background: rgba(36,183,170,.16); }
.admin-nav a.active i { border-color: var(--accent); background: var(--accent); }
.sidebar-user { margin-top: auto; padding: 13px 6px 0; border-top: 1px solid rgba(255,255,255,.1); display: grid; grid-template-columns: 35px minmax(0,1fr) 28px; gap: 9px; align-items: center; }
.avatar { width: 35px; height: 35px; display: grid; place-items: center; border-radius: 10px; color: var(--primary); background: #daf2ef; font-weight: 800; }
.sidebar-user > div { min-width: 0; display: grid; gap: 3px; }
.sidebar-user strong, .sidebar-user small { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sidebar-user strong { font-size: 9px; }
.sidebar-user small { color: #7f9a9f; font-size: 7px; direction: ltr; text-align: right; }
.sidebar-user button { width: 28px; height: 28px; border: 0; border-radius: 8px; color: #acc0c3; background: rgba(255,255,255,.06); cursor: pointer; }
.admin-main { min-width: 0; }
.admin-topbar { height: 72px; position: sticky; top: 0; z-index: 25; padding: 0 28px; display: flex; align-items: center; gap: 17px; border-bottom: 1px solid #dfe8e9; background: rgba(255,255,255,.95); backdrop-filter: blur(14px); }
.admin-topbar > div { display: grid; gap: 3px; margin-left: auto; }
.admin-topbar > div strong { font-size: 13px; }
.admin-topbar > div span { color: #7d8f94; font-size: 8px; }
.mobile-menu { display: none; }
.admin-content { width: min(1450px, 100%); margin: 0 auto; padding: 29px 28px 55px; }
.admin-page-title { margin-bottom: 18px; display: flex; align-items: flex-end; justify-content: space-between; gap: 25px; }
.admin-page-title h1 { margin: 7px 0 6px; font-size: 28px; letter-spacing: -.03em; }
.admin-page-title p { margin: 0; color: var(--muted); font-size: 11px; }
.stat-grid { margin-bottom: 17px; display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 12px; }
.stat-grid > div { padding: 17px 19px; border: 1px solid var(--line); border-radius: 14px; background: #fff; box-shadow: 0 8px 26px rgba(19,54,63,.035); }
.stat-grid span, .stat-grid small { display: block; color: var(--muted); font-size: 9px; }
.stat-grid strong { display: block; margin: 6px 0 3px; color: var(--primary); font-size: 27px; }
.workspace-grid { display: grid; grid-template-columns: 340px minmax(0,1fr); gap: 15px; align-items: start; }
.requests-panel, .review-panel, .admin-card { border: 1px solid var(--line); border-radius: 17px; background: #fff; box-shadow: 0 8px 30px rgba(19,54,63,.035); }
.requests-panel { position: sticky; top: 88px; overflow: hidden; }
.panel-toolbar { padding: 12px; display: grid; grid-template-columns: minmax(0,1fr) 105px; gap: 7px; border-bottom: 1px solid var(--line); }
.panel-toolbar input, .panel-toolbar select { min-width: 0; min-height: 38px; padding: 0 10px; border: 1px solid #d9e4e5; border-radius: 9px; background: #f8fbfb; outline: none; font-size: 9px; }
.panel-toolbar .button { grid-column: 1 / -1; min-height: 34px; font-size: 9px; }
.requests-list { max-height: calc(100vh - 240px); overflow-y: auto; }
.request-card { width: 100%; padding: 14px 13px; display: grid; grid-template-columns: minmax(0,1fr) auto; gap: 9px 12px; border-bottom: 1px solid #edf1f2; background: #fff; }
.request-card:hover { background: #f8fbfb; }
.request-card.active { background: #edf8f6; box-shadow: inset -3px 0 var(--accent); }
.request-card > div:first-child { min-width: 0; display: grid; gap: 4px; }
.request-card strong, .request-card span, .request-card small { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.request-card strong { font-size: 11px; }
.request-card span { color: #7a8b90; font-size: 8px; }
.request-card small { color: #9aa8ab; font-size: 7px; direction: ltr; text-align: right; }
.request-card > div:last-child { display: flex; flex-direction: column; align-items: flex-end; justify-content: space-between; gap: 7px; }
.request-card b { color: #819196; font-size: 7px; }
.status-chip { width: max-content; min-height: 22px; padding: 0 8px; display: inline-flex; align-items: center; border-radius: 99px; font-size: 8px; font-weight: 800; }
.status-new { color: #8c5c00; background: #fff0ce; }
.status-review { color: #2e6393; background: #e8f1fb; }
.status-sent { color: #0c7468; background: #dcf5f0; }
.status-cancelled { color: #8d4248; background: #f8e7e9; }
.review-panel { min-width: 0; padding: 21px; }
.empty-review, .empty-state { padding: 46px 20px; text-align: center; color: #839398; }
.empty-review { min-height: 420px; display: grid; place-content: center; gap: 7px; }
.empty-review strong { color: var(--ink); }
.review-head { padding-bottom: 17px; display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; border-bottom: 1px solid #e5edef; }
.review-head h2 { margin: 9px 0 5px; font-size: 21px; }
.review-head p { margin: 0; color: #829297; font-size: 9px; }
.quote-serial { min-width: 180px; padding: 10px 12px; display: grid; gap: 4px; border: 1px dashed #b9d0cf; border-radius: 10px; background: #f1f9f7; direction: ltr; text-align: left; }
.quote-serial span { color: #77908e; font-size: 8px; }
.quote-serial strong { color: var(--primary); font-size: 10px; }
.customer-info-grid { margin-top: 16px; display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 1px; border: 1px solid #e2eaeb; border-radius: 12px; background: #e2eaeb; overflow: hidden; }
.customer-info-grid > div { min-width: 0; padding: 10px 11px; display: grid; gap: 4px; background: #fafcfc; }
.customer-info-grid .wide { grid-column: span 4; }
.customer-info-grid span { color: #87969a; font-size: 8px; }
.customer-info-grid strong { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 9px; }
.customer-note { margin-top: 11px; padding: 11px 13px; border: 1px solid #eee0c3; border-radius: 11px; background: #fff9ec; }
.customer-note span { color: #987c3e; font-size: 8px; }
.customer-note p { margin: 5px 0 0; font-size: 10px; line-height: 1.7; }
.price-table-wrap, .catalog-table-wrap { margin-top: 15px; overflow-x: auto; }
.price-table, .catalog-table { width: 100%; min-width: 750px; border-collapse: collapse; }
.price-table th, .catalog-table th { padding: 9px; border-bottom: 1px solid #dfe8e9; color: #6d7f83; background: #f2f7f6; text-align: right; font-size: 7.5px; }
.price-table td, .catalog-table td { padding: 10px 9px; border-bottom: 1px solid #e8eeee; font-size: 9px; }
.price-table td:first-child { min-width: 185px; }
.price-table td:first-child strong, .price-table td:first-child span, .price-table td:first-child small { display: block; }
.price-table td:first-child span { margin-top: 3px; color: #75878b; font-size: 7px; }
.price-table td:first-child small { margin-top: 3px; color: #9aa6a8; font-size: 6.5px; }
.price-table input, .catalog-table input { width: 100%; min-width: 80px; min-height: 34px; padding: 0 7px; border: 1px solid #cfdddf; border-radius: 8px; outline: none; font-size: 9px; }
.adjustment-grid { margin-top: 15px; display: grid; grid-template-columns: repeat(3,minmax(0,.75fr)) minmax(210px,1.25fr); gap: 9px; }
.adjustment-grid > label, .adjustment-grid > div { display: grid; gap: 5px; }
.adjustment-grid span { color: #73858a; font-size: 8px; }
.adjustment-grid input { min-height: 38px; padding: 0 9px; border: 1px solid #d5e1e3; border-radius: 9px; outline: none; }
.adjustment-grid > div { padding: 9px 12px; border-radius: 11px; color: #fff; background: var(--primary); }
.adjustment-grid > div span { color: #9bb0b4; }
.adjustment-grid > div strong { font-size: 16px; }
.adjustment-grid > div small { color: #75d2c9; font-size: 7px; }
.admin-textarea { margin-top: 14px; display: grid; gap: 6px; }
.admin-textarea span { color: #6d7f83; font-size: 8px; }
.admin-textarea textarea { padding: 10px; border: 1px solid #d7e3e5; border-radius: 10px; resize: vertical; outline: none; line-height: 1.7; }
.review-actions, .issued-actions { margin-top: 15px; padding-top: 14px; display: flex; flex-wrap: wrap; gap: 8px; border-top: 1px solid #e5edef; }
.review-actions .button, .issued-actions .button, .share-button { min-height: 39px; font-size: 9px; }
.issued-actions { align-items: center; }
.issued-actions > div:first-child { min-width: 220px; flex: 1; display: grid; gap: 4px; }
.issued-actions > div span { color: #71858a; direction: ltr; text-align: right; font-size: 7px; word-break: break-all; }
.issued-actions form { display: inline-flex; }
.share-button { padding: 0 14px; border: 0; border-radius: 10px; display: inline-flex; align-items: center; justify-content: center; font-weight: 800; cursor: pointer; }
.share-button.whatsapp { color: #147747; background: #dff5e8; }
.share-button.email { color: #336796; background: #e7f0f9; }
.danger-row { margin-top: 10px; text-align: left; }
.text-danger { padding: 4px 7px; border: 0; color: var(--danger); background: transparent; cursor: pointer; font-size: 9px; }
.catalog-layout { margin-bottom: 15px; display: grid; grid-template-columns: .75fr 1.25fr; gap: 15px; }
.admin-card { padding: 21px; }
.admin-card h2 { margin: 0 0 16px; font-size: 16px; }
.mini-form, .settings-form { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px; }
.mini-form label, .settings-form label, .type-edit-form label { min-width: 0; display: grid; gap: 6px; }
.mini-form input, .mini-form select, .settings-form input, .settings-form select, .type-edit-form input { min-height: 40px; }
.mini-form .button { align-self: end; }
.variant-form { grid-template-columns: repeat(4,minmax(0,1fr)); }
.catalog-table-card { margin-bottom: 20px; }
.card-title-row { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; }
.card-title-row h2 { margin-bottom: 4px; }
.card-title-row p { margin: 0; color: var(--muted); font-size: 9px; }
.card-title-row select { min-width: 260px; min-height: 38px; padding: 0 9px; border: 1px solid #d7e3e5; border-radius: 9px; }
.type-edit-form { margin-top: 17px; padding: 14px; display: grid; grid-template-columns: 1.2fr 1.2fr .5fr auto auto; gap: 10px; align-items: end; border-radius: 12px; background: #f5f9f9; }
.check-field { min-height: 38px; display: flex !important; align-items: center; gap: 8px !important; color: #53696e; font-size: 9px; cursor: pointer; }
.check-field input { width: 16px !important; min-height: 16px !important; accent-color: var(--accent); }
.table-save { min-height: 31px; padding: 0 10px; display: inline-flex; align-items: center; justify-content: center; border: 0; border-radius: 8px; color: var(--primary); background: var(--accent-pale); cursor: pointer; font-size: 8px; font-weight: 800; }
.settings-grid { display: grid; grid-template-columns: minmax(0,1.35fr) minmax(300px,.65fr); gap: 15px; align-items: start; }
.settings-form .wide { grid-column: 1 / -1; }
.logo-preview { min-height: 110px; padding: 14px; display: grid; place-items: center; border: 1px dashed #cbdadc; border-radius: 13px; background: #f8fbfb; }
.logo-preview img { max-width: 230px; max-height: 95px; object-fit: contain; }
.logo-upload { margin-top: 12px; display: grid; gap: 8px; }
.logo-upload > input { width: 100%; padding: 7px; border: 1px solid #d6e2e4; border-radius: 9px; font-size: 8px; }
.settings-form.narrow { margin-top: 14px; }
.notes-settings { grid-column: 1 / -1; }
.settings-textareas { margin: 15px 0; display: grid; grid-template-columns: 1.2fr .8fr .8fr; gap: 12px; }
.settings-textareas label { display: grid; gap: 6px; }
.users-grid { display: grid; grid-template-columns: minmax(420px,.85fr) minmax(0,1.15fr); gap: 15px; align-items: start; }
.user-form { display: grid; gap: 15px; }
.permissions-box { padding: 14px; border: 1px solid #dce7e9; border-radius: 12px; background: #f8fbfb; }
.full-access { padding-bottom: 10px; border-bottom: 1px solid #dce6e8; font-weight: 800; }
.permission-grid { margin-top: 10px; display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 7px; }
.active-user { padding: 8px 10px; border-radius: 10px; background: #edf8f6; }
.users-list { display: grid; gap: 8px; }
.users-list article { padding: 11px; display: grid; grid-template-columns: 38px minmax(0,1fr) auto auto; gap: 10px; align-items: center; border: 1px solid #e1e9ea; border-radius: 11px; }
.users-list article > div { min-width: 0; display: grid; gap: 3px; }
.users-list strong, .users-list small, .users-list em { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.users-list strong { font-size: 10px; }
.users-list small { color: #788b8f; font-size: 8px; direction: ltr; text-align: right; }
.users-list em { color: #90a0a3; font-size: 7px; font-style: normal; }

/* Quote paper */
.quote-body { background: #e8eeee; }
.quote-screen { min-height: 100vh; padding: 1px 20px 55px; overflow-x: auto; }
.quote-actions { width: min(210mm, 100%); margin: 16px auto 0; display: flex; justify-content: flex-end; gap: 8px; position: sticky; top: 9px; z-index: 10; }
.quotation-paper { width: 210mm; min-height: 297mm; margin: 13px auto 0; padding: 10mm 11mm 8mm; position: relative; color: #101b1f; background: #fff; box-shadow: 0 22px 60px rgba(12,37,45,.14); font-family: Arial, sans-serif; }
.quotation-header { min-height: 35mm; padding: 5mm; display: grid; grid-template-columns: 42mm minmax(0,1fr); gap: 6mm; align-items: center; border: 1.4px solid var(--primary); border-radius: 12px; }
.quotation-brand { height: 25mm; padding-left: 5mm; display: grid; place-items: center; border-left: 1px solid #d8e2e4; overflow: hidden; }
.quotation-brand .brand-lockup > span:last-child { display: none; }
.quotation-brand .brand-logo-image { max-width: 38mm; max-height: 25mm; height: auto; }
.quotation-brand .brand-symbol { width: 16mm; height: 16mm; border-radius: 5mm; }
.company-heading h1 { margin: 0; font-size: 15px; line-height: 1.45; }
.company-heading h2 { margin: 1mm 0 2.5mm; color: #25525d; font: 700 10px Arial, sans-serif; direction: ltr; text-align: right; }
.company-lines { display: grid; grid-template-columns: 1fr 1.35fr; gap: 1.2mm 4mm; color: #41565c; font-size: 7.2px; }
.company-lines span:nth-child(n+3) { grid-column: span 2; }
.company-lines b { color: #142c34; }
.quotation-title { margin: 4mm 0 3mm; display: flex; align-items: stretch; justify-content: space-between; gap: 5mm; }
.quotation-title > div:first-child { display: flex; align-items: baseline; gap: 3mm; }
.quotation-title > div:first-child span { color: var(--primary); font: 800 8px Arial, sans-serif; letter-spacing: .15em; }
.quotation-title h3 { margin: 0; font-size: 22px; }
.serial-box { min-width: 49mm; padding: 2.3mm 4mm; display: flex; align-items: center; justify-content: space-between; gap: 4mm; border-radius: 8px; color: #fff; background: var(--primary); }
.serial-box span { color: #a8bdc2; font-size: 7px; }
.serial-box strong { color: #8be0d8; font: 800 9px Arial, sans-serif; }
.quote-meta-grid { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 1px; border: 1px solid #aebfc3; border-radius: 8px; background: #c9d5d7; overflow: hidden; }
.quote-meta-grid > div { min-width: 0; padding: 2.4mm 2.5mm; display: grid; gap: 1.2mm; background: #fff; }
.quote-meta-grid > div:nth-child(5), .quote-meta-grid > div:nth-child(6) { grid-column: span 2; }
.quote-meta-grid span { color: #667b80; font-size: 6.6px; }
.quote-meta-grid strong { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 8px; }
.quotation-table { width: 100%; margin-top: 3mm; border-collapse: collapse; table-layout: fixed; }
.quotation-table thead { display: table-header-group; }
.quotation-table tr { page-break-inside: avoid; }
.quotation-table th { padding: 2.5mm 1.5mm; border: 1px solid #1e414b; color: #fff; background: var(--primary); font-size: 6.7px; }
.quotation-table th:nth-child(1) { width: 7mm; }.quotation-table th:nth-child(2) { width: 22mm; }.quotation-table th:nth-child(4) { width: 17mm; }.quotation-table th:nth-child(5) { width: 15mm; }.quotation-table th:nth-child(6), .quotation-table th:nth-child(7) { width: 25mm; }
.quotation-table td { padding: 2.7mm 1.7mm; border: 1px solid #aebdc0; text-align: center; vertical-align: middle; font-size: 7.5px; }
.quotation-table tbody tr:nth-child(even) td { background: #f6f9f9; }
.quotation-table td:nth-child(3) { text-align: right; }
.quotation-table td:nth-child(3) strong, .quotation-table td:nth-child(3) span, .quotation-table td:nth-child(3) small { display: block; }
.quotation-table td:nth-child(3) span { margin-top: 1mm; color: #51696e; font-size: 6.8px; }
.quotation-table td:nth-child(3) small { margin-top: 1mm; color: #7d8c8f; font-size: 6.2px; }
.quote-totals { margin-top: 3mm; display: grid; grid-template-columns: minmax(0,1.5fr) 58mm; border: 1px solid #9eafb3; border-radius: 8px; overflow: hidden; }
.amount-words { padding: 4mm; display: flex; flex-direction: column; justify-content: center; background: #f6f9f9; }
.amount-words span { color: #65797e; font-size: 7px; }
.amount-words p { margin: 2mm 0 0; font-size: 9px; font-weight: 700; line-height: 1.8; }
.totals-list { border-right: 1px solid #b5c2c5; }
.totals-list > div { min-height: 8mm; padding: 1.7mm 3mm; display: flex; align-items: center; justify-content: space-between; gap: 3mm; border-bottom: 1px solid #d4dddf; }
.totals-list > div:last-child { border-bottom: 0; }
.totals-list span { color: #61767b; font-size: 7px; }
.totals-list strong { font: 700 8px Arial, sans-serif; }
.totals-list .grand-total { min-height: 11mm; color: #fff; background: var(--primary); }
.totals-list .grand-total span { color: #c1d0d3; font-size: 8px; }
.totals-list .grand-total strong { color: #8de0d8; font-size: 11px; }
.quotation-notes { margin-top: 3.5mm; padding-top: 2.5mm; border-top: 1.5px solid var(--primary); }
.quotation-notes h4 { margin: 0 0 1.5mm; font-size: 9px; }
.quotation-notes ol { margin: 0; padding-right: 5mm; display: grid; gap: .8mm; }
.quotation-notes li { color: #334b52; font-size: 7px; line-height: 1.55; }
.special-note { margin: 2mm 0 0; padding: 2mm 3mm; border-radius: 5px; color: #23484c; background: #f4f9f8; font-size: 7px; line-height: 1.6; }
.signatures { margin-top: 6mm; padding: 0 12mm; display: grid; grid-template-columns: 1fr 1fr; gap: 25mm; }
.signatures > div { min-height: 22mm; display: grid; justify-items: center; align-content: start; gap: 2mm; border-bottom: 1px dotted #63787d; }
.signatures span { color: #6e8186; font-size: 6.8px; }.signatures strong { font-size: 8px; }.signatures i { color: #829195; font-size: 6.5px; font-style: normal; }
.quotation-footer { position: absolute; right: 11mm; left: 11mm; bottom: 5mm; padding-top: 2mm; display: flex; justify-content: space-between; border-top: 1px solid #b5c2c5; color: #73858a; font-size: 6px; }
.not-found { min-height: 100vh; padding: 25px; display: grid; place-content: center; justify-items: center; text-align: center; }
.not-found > strong { color: var(--accent); font-size: 70px; }.not-found h1 { margin: 8px 0; }.not-found p { color: var(--muted); }

@media (max-width: 1250px) {
  .product-grid { grid-template-columns: 1.3fr repeat(3,minmax(90px,.7fr)); }
  .workspace-grid { grid-template-columns: 300px minmax(0,1fr); }
  .customer-info-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .customer-info-grid .wide { grid-column: span 2; }
  .adjustment-grid { grid-template-columns: repeat(3,minmax(0,1fr)); }
  .adjustment-grid > div { grid-column: 1 / -1; }
}

@media (max-width: 980px) {
  .hero-grid { grid-template-columns: 1fr; gap: 28px; }.hero-stat-card { max-width: 620px; }
  .form-grid.three { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .admin-shell { grid-template-columns: 1fr; }
  .admin-sidebar { position: fixed; right: -260px; width: 248px; transition: right .2s ease; box-shadow: -20px 0 50px rgba(0,0,0,.2); }
  body.sidebar-open .admin-sidebar { right: 0; }
  .mobile-menu { width: 39px; height: 39px; display: grid; place-items: center; border: 0; border-radius: 10px; color: var(--primary); background: #edf5f4; cursor: pointer; }
  .workspace-grid, .catalog-layout, .settings-grid, .users-grid { grid-template-columns: 1fr; }
  .requests-panel { position: static; }.requests-list { max-height: 420px; }.notes-settings { grid-column: auto; }
  .install-shell { grid-template-columns: 1fr; }.install-intro { position: static; }.login-shell { grid-template-columns: 1fr; }.login-brand-panel, .login-card { border-radius: 22px; }.login-brand-panel { min-height: 380px; }
}

@media (max-width: 700px) {
  .site-container { width: min(100% - 22px, 1180px); }
  .public-header { height: 68px; }.header-actions .secure-note { display: none; }.header-actions .button { min-height: 38px; padding-inline: 11px; font-size: 10px; }
  .brand-lockup strong { max-width: 185px; overflow: hidden; text-overflow: ellipsis; font-size: 10px; }.brand-lockup small { display: none; }.brand-symbol { width: 35px; height: 35px; border-radius: 10px; }.brand-logo-image { max-width: 85px; height: 42px; }
  .quote-hero { padding: 43px 0 80px; }.quote-hero h1 { font-size: 34px; }.quote-hero p { font-size: 13px; }.hero-stat-card { padding: 20px; }
  .form-wrap { margin-top: -42px; }.form-card { padding: 20px 14px; border-radius: 16px; }.section-heading { margin-bottom: 19px; }.section-heading.with-action { flex-wrap: wrap; }.section-heading.with-action .button { width: 100%; }
  .form-grid.three, .form-grid.two { grid-template-columns: 1fr; }.span-full { grid-column: auto; }
  .product-item { grid-template-columns: 1fr; padding: 16px 12px; }.item-number { padding: 0 0 8px; display: flex; justify-content: flex-start; gap: 7px; border-left: 0; border-bottom: 1px solid #dce6e8; }.item-number strong { font-size: 14px; }
  .product-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }.product-type-field, .item-notes { grid-column: 1 / -1; }.remove-item { left: 7px; top: 7px; }
  .quantity-summary { grid-template-columns: 1fr 1.5fr; gap: 12px; }.quantity-summary p { grid-column: 1 / -1; text-align: right; }
  .submit-row { align-items: stretch; flex-direction: column; }.submit-row .button { width: 100%; }.public-footer .site-container { align-items: flex-start; flex-direction: column; gap: 12px; }
  .install-shell { width: min(100% - 20px, 1120px); padding: 16px 0; }.install-intro, .install-card { padding: 22px 16px; }.install-intro h1 { font-size: 28px; }
  .login-shell { width: min(100% - 20px, 940px); padding: 12px 0; }.login-brand-panel { min-height: 290px; padding: 28px 21px; }.login-brand-panel h1 { font-size: 29px; }.login-card { padding: 25px 18px; }
  .admin-topbar { height: 64px; padding: 0 12px; }.admin-topbar .button { min-height: 35px; padding-inline: 9px; font-size: 8px; }.admin-topbar > div span { display: none; }
  .admin-content { padding: 20px 9px 45px; }.admin-page-title { align-items: stretch; flex-direction: column; }.admin-page-title h1 { font-size: 23px; }.admin-page-title .button { width: 100%; }
  .stat-grid { gap: 7px; }.stat-grid > div { padding: 12px 9px; }.stat-grid strong { font-size: 21px; }.stat-grid span, .stat-grid small { font-size: 7px; }
  .review-panel, .admin-card { padding: 15px 11px; border-radius: 14px; }.review-head { flex-direction: column; }.quote-serial { width: 100%; }
  .price-table-wrap { margin-inline: -11px; padding-inline: 11px; }.adjustment-grid { grid-template-columns: 1fr 1fr; }.adjustment-grid > label:nth-child(3) { grid-column: span 2; }
  .review-actions .button, .issued-actions .button, .issued-actions .share-button, .issued-actions form { flex: 1 1 calc(50% - 8px); }.issued-actions form .share-button { width: 100%; }.issued-actions > div:first-child { flex-basis: 100%; }
  .mini-form, .settings-form, .variant-form, .type-edit-form, .settings-textareas, .permission-grid { grid-template-columns: 1fr; }.settings-form .wide { grid-column: auto; }.card-title-row { align-items: stretch; flex-direction: column; }.card-title-row select { width: 100%; min-width: 0; }
  .users-list article { grid-template-columns: 35px minmax(0,1fr) auto; }.users-list article form { grid-column: 3; }
  .quote-screen { padding-inline: 8px; }.quote-actions { width: 100%; position: static; justify-content: stretch; }.quote-actions .button { flex: 1; padding-inline: 7px; font-size: 9px; }.quotation-paper { margin-right: 0; margin-left: 0; transform-origin: top right; }
}

@page { size: A4; margin: 0; }
@media print {
  html, body { width: 210mm; min-height: 297mm; background: #fff !important; print-color-adjust: exact; -webkit-print-color-adjust: exact; }
  .quote-screen { margin: 0; padding: 0; background: #fff; overflow: visible; }
  .quote-actions { display: none !important; }
  .quotation-paper { width: 210mm; min-height: 297mm; margin: 0; box-shadow: none; page-break-after: always; }
}
