* { box-sizing: border-box; }
body { margin: 0; font-family: "Segoe UI", Arial, sans-serif; background: #f5f0e8; color: #182126; }
a { color: inherit; text-decoration: none; }
.app-shell { display: grid; grid-template-columns: 260px 1fr; min-height: 100vh; }
.sidebar { background: #103b35; color: #fff; padding: 32px 20px; }
.brand h1 { margin: 10px 0 0; font-size: 28px; }
.eyebrow { font-size: 12px; text-transform: uppercase; letter-spacing: .18em; color: #70c1b0; }
.nav { display: grid; gap: 8px; margin-top: 32px; }
.nav a { padding: 12px 14px; border-radius: 14px; background: rgba(255,255,255,.04); }
.nav a:hover { background: rgba(255,255,255,.12); }
.content { padding: 24px; }
.topbar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 24px; }
.topbar h2 { margin: 6px 0 0; font-size: 30px; }
.user-box { display: flex; gap: 12px; align-items: center; }
.card { background: #fff; border-radius: 24px; padding: 24px; box-shadow: 0 18px 48px rgba(16,59,53,.08); }
.grid { display: grid; gap: 20px; }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.stat-card span { display: block; font-size: 13px; color: #5b6870; }
.stat-card strong { display: block; margin-top: 10px; font-size: 34px; }
.toolbar { display: flex; gap: 12px; margin-bottom: 18px; }
.toolbar.wrap { flex-wrap: wrap; }
.customer-section-nav { margin-top: 20px; }
.table { width: 100%; border-collapse: collapse; }
.table th, .table td { padding: 12px 10px; border-bottom: 1px solid #e6ebe9; text-align: left; font-size: 14px; }
.table-sort-link { display: inline-flex; align-items: center; gap: 4px; font-weight: 600; color: inherit; text-decoration: none; }
.table-sort-link:hover { color: #176d61; }
.table-row-link { cursor: pointer; transition: background .12s ease; }
.table-row-link:hover { background: #f7fbfa; }
.table-row-link.is-active { background: #edf7f5; }
.row-link-text { display: block; color: inherit; text-decoration: none; }
.button { display: inline-flex; align-items: center; justify-content: center; border: none; border-radius: 12px; padding: 11px 16px; cursor: pointer; }
.button.primary { background: #b76836; color: #fff; }
.button.secondary { background: #edf7f5; color: #176d61; }
.button.small { padding: 8px 12px; font-size: 12px; }
.badge { display: inline-flex; padding: 6px 10px; border-radius: 999px; font-size: 12px; background: #edf7f5; color: #176d61; }
.badge-danger { background: #ffe7e7; color: #a43737; }
.badge-warning { background: #fff4d8; color: #9a6a00; }
.badge-muted { background: #eceff1; color: #63717b; }
.muted { color: #65727b; }
.info-list { display: grid; gap: 12px; margin-top: 18px; }
.info-list div { display: flex; justify-content: space-between; gap: 12px; padding-bottom: 8px; border-bottom: 1px solid #eef2f0; }
.stack { display: grid; gap: 12px; }
.item-list { display: grid; gap: 18px; }
.item-row { padding: 18px; border: 1px solid #dce7e3; border-radius: 18px; background: #fbfcfc; }
.item-row-footer { display: flex; align-items: end; justify-content: space-between; gap: 16px; }
.contact-card, .list-card { border: 1px solid #dce7e3; border-radius: 18px; padding: 16px; display: grid; gap: 6px; }
.task-filter-bar { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 18px; align-items: end; }
.task-card { gap: 10px; }
.task-card-meta { display: flex; flex-wrap: wrap; gap: 8px; }
.offer-form-card { padding: 28px; }
.offer-form-header { display: flex; justify-content: space-between; align-items: start; gap: 20px; margin-bottom: 24px; }
.offer-form-header h3 { margin: 8px 0; font-size: 30px; }
.offer-form-header-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.offer-sheet-preview { display: grid; grid-template-columns: minmax(0, 1.8fr) minmax(280px, 340px); gap: 18px; align-items: start; }
.offer-sheet-main, .offer-sheet-sidebar { display: grid; gap: 24px; }
.offer-sheet-top { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; align-items: start; }
.offer-sheet-block { background: #fffdf9; border: 1px solid #e6ddd2; border-radius: 24px; padding: 18px; box-shadow: inset 0 1px 0 rgba(255,255,255,.7); }
.offer-sheet-block h3 { margin: 6px 0 10px; font-size: 18px; }
.offer-sheet-address { margin-top: 8px; border-top: 1px solid #eee3d4; padding-top: 12px; line-height: 1.6; color: #3f4a50; }
.offer-metadata { background: linear-gradient(180deg, #fff8ef 0%, #fffdf9 100%); }
.offer-document-items { display: grid; gap: 12px; }
.offer-position-table { display: grid; gap: 10px; }
.offer-position-table-head, .offer-position-row { display: grid; grid-template-columns: minmax(260px, 1.9fr) 90px 90px 120px 110px 100px 130px 120px; gap: 12px; align-items: start; }
.offer-position-table-head { padding: 0 8px 2px; font-size: 11px; font-weight: 700; color: #5a6a6f; text-transform: uppercase; letter-spacing: .04em; }
.offer-position-row { padding: 12px; background: #fcfbf9; border: 1px solid #e8dfd3; border-radius: 20px; }
.offer-position-row label { margin-bottom: 0; }
.offer-position-main { display: grid; gap: 8px; }
.offer-position-actions { display: flex; align-items: end; justify-content: end; min-height: 100%; }
.summary-card { position: static; }
.summary-list { margin-top: 10px; }
.summary-list strong { font-size: 15px; }
.login-page { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 24px; }
.login-card { width: 100%; max-width: 420px; }
label { display: grid; gap: 8px; margin-bottom: 14px; font-size: 14px; }
input, textarea, select { width: 100%; border: 1px solid #dce7e3; border-radius: 14px; padding: 12px 14px; background: #f8faf9; font: inherit; }
.alert.error { margin-bottom: 16px; padding: 12px 14px; border-radius: 14px; background: #ffe7e7; color: #9d2f2f; }
.checkbox-row { display: flex; align-items: center; gap: 10px; }
.settings-logo-preview { display: block; margin-top: 8px; max-width: 180px; max-height: 90px; object-fit: contain; border: 1px solid #dce7e3; border-radius: 12px; background: #fff; padding: 8px; }
.print-body { background: #fff; color: #1a1a1a; padding: 24px; font-size: 11px; }
.print-toolbar { display: flex; gap: 12px; margin-bottom: 24px; }
.print-document { width: 210mm; min-height: 297mm; max-width: 210mm; margin: 0 auto; background: #fff; padding: 0 15mm 15mm; }
.print-logo-row { display: grid; grid-template-columns: 1fr 220px; align-items: start; min-height: 72px; }
.print-company-address { max-width: 360px; font-size: 14px; line-height: 1.5; margin-top: 30px; margin-left: 30px; text-decoration: underline; }
.print-company-line { margin-bottom: 8px; font-weight: 600; }
.print-logo-box { min-height: 80px; min-width: 180px; display: flex; justify-content: end; align-items: start; }
.print-logo { max-width: 180px; max-height: 90px; object-fit: contain; }
.print-recipient { margin: 30px 0 0 30px; font-size: 14px; }
.offer-company-address { margin-top: 12px; margin-left: 0; max-width: none; width: calc(100% - 220px); font-size: 10px; line-height: 1.2; text-decoration: underline; white-space: nowrap; }
.offer-print-header-row { display: grid; grid-template-columns: minmax(0, 1fr) 70mm; gap: 8mm; margin-top: 8px; align-items: start; }
.offer-recipient-block { margin: 0; font-size: 12px; line-height: 1.45; }
.offer-meta-plain { width: 70mm; margin-left: auto; font-size: 12px; line-height: 1.45; }
.offer-meta-plain div { display: grid; grid-template-columns: 28mm 1fr; gap: 4mm; }
.offer-meta-plain div span { display: block; text-align: right; white-space: nowrap; }
.offer-title-row { margin: 14px 0 8px; }
.offer-title-row h1 { margin: 0; font-size: 26px; font-weight: 700; }
.print-intro { margin: 10px 0 14px; line-height: 1.5; }
.print-table { width: 100%; border-collapse: collapse; margin: 22px 0; font-size: 13px; }
.print-table th, .print-table td { border-bottom: 1px solid #d8d8d8; padding: 10px 8px; text-align: left; vertical-align: top; }
.print-table thead th { font-size: 14px; }
.print-table tfoot th { font-size: 15px; }
.print-table .align-right { text-align: right; }
.offer-print-table { margin-top: 8px; }
.offer-summary-layout { display: grid; grid-template-columns: minmax(0, 1fr) 70mm; gap: 8mm; margin-top: 2px; }
.offer-summary-plain { width: 70mm; margin-left: auto; font-size: 12px; line-height: 1.45; }
.offer-summary-plain div { display: grid; grid-template-columns: 38mm 1fr; gap: 4mm; padding: 2px 0; }
.offer-summary-plain div span { display: block; text-align: right; white-space: nowrap; }
.offer-payment-terms { margin-top: 12px; max-width: 62%; font-size: 12px; line-height: 1.5; }
.offer-payment-title { margin-bottom: 8px; }
.print-footer-bank { margin-top: 22px; padding-top: 10px; border-top: 1px solid #d8d0c4; display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 8mm; font-size: 11px; color: #1a1a1a; width: 100%; }
.offer-footer-bank { align-items: start; }
.offer-footer-bank > div { min-width: 0; }
.print-text-block { white-space: pre-wrap; line-height: 1.6; }
.email-preview { margin-top: 18px; border: 1px solid #dce7e3; border-radius: 18px; padding: 18px; background: #fbfcfc; white-space: pre-wrap; line-height: 1.6; }
.drop-upload-zone { display: grid; gap: 8px; place-items: center; min-height: 180px; border: 2px dashed #9fc1ba; border-radius: 20px; background: #f7fbfa; color: #28574f; text-align: center; padding: 24px; cursor: pointer; transition: .15s ease; }
.drop-upload-zone.is-dragover { background: #edf7f5; border-color: #176d61; }
.drop-upload-zone small { color: #65727b; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
@page { size: A4 portrait; margin: 12mm 10mm 12mm; }

@media print {
  .no-print { display: none !important; }
  html, body { width: 210mm; }
  body.print-body { padding: 0; margin: 0; font-size: 11px; }
  .print-document { width: 100%; max-width: none; min-height: 273mm; padding: 0 0 32mm; position: relative; }
  .offer-print-header-row { grid-template-columns: 1fr 70mm; gap: 8mm; }
  .offer-meta-plain, .offer-summary-plain { width: 70mm; }
  .offer-meta-plain div { grid-template-columns: 28mm 1fr; gap: 4mm; }
  .offer-summary-plain div { grid-template-columns: 38mm 1fr; gap: 4mm; }
  .offer-footer-bank {
    display: grid !important;
    grid-template-columns: 1fr 1fr 1fr !important;
    gap: 8mm !important;
    width: 100% !important;
    position: fixed;
    left: 10mm;
    right: 10mm;
    bottom: 10mm;
    margin: 0;
    padding-top: 6mm;
    background: #fff;
  }
}
@media (max-width: 1100px) {
  .app-shell, .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .task-filter-bar { grid-template-columns: 1fr; }
  .offer-sheet-preview, .offer-sheet-top, .offer-position-table-head, .offer-position-row { grid-template-columns: 1fr; }
  .offer-position-table-head { display: none; }
  .summary-card { position: static; }
  .offer-print-header-row, .offer-summary-layout { grid-template-columns: 1fr; }
  .offer-payment-terms, .offer-company-address { max-width: 100%; width: 100%; white-space: normal; }
}


:root {
  --bg: #f4f6f3;
  --surface: #ffffff;
  --surface-alt: #f8faf8;
  --line: #dfe6df;
  --text: #16312a;
  --muted: #64756f;
  --brand: #0f3b34;
  --brand-2: #c57b49;
  --brand-soft: #ebf3f1;
}
body { background: linear-gradient(135deg, #eef2ee 0%, #f6f3ee 100%); color: var(--text); }
.sidebar { background: linear-gradient(180deg, #0f3b34 0%, #0a2824 100%); border-right: 1px solid rgba(255,255,255,.08); }
.sidebar-tagline { margin: 8px 0 0; color: rgba(255,255,255,.72); font-size: 13px; line-height: 1.45; }
.nav a { border: 1px solid rgba(255,255,255,.06); backdrop-filter: blur(8px); }
.nav a:hover { transform: translateX(2px); }
.content { padding: 28px; }
.card { border: 1px solid rgba(15,59,52,.08); box-shadow: 0 20px 55px rgba(16,40,35,.08); }
.topbar { padding: 0 4px; }
.button { gap: 8px; font-weight: 600; transition: transform .12s ease, box-shadow .12s ease, background .12s ease; }
.button:hover { transform: translateY(-1px); box-shadow: 0 8px 18px rgba(15,59,52,.12); }
.button.primary { background: linear-gradient(135deg, var(--brand-2), #af6230); }
.button.secondary { background: var(--brand-soft); color: var(--brand); }
.badge { background: #eef5f0; color: var(--brand); }
.badge-success { background: #e8f5ef; color: #16613f; }
.workflow-hint { display: inline-flex; align-items: center; padding: 12px 14px; border-radius: 14px; background: #fff7ef; color: #8a5a2c; border: 1px solid #efd8c3; font-size: 14px; }
.workflow-banner { margin-bottom: 18px; padding: 14px 16px; border-radius: 16px; border: 1px solid #efd8c3; background: #fff8f1; color: #8a5a2c; }
.table { border-collapse: separate; border-spacing: 0 10px; }
.table thead th { border-bottom: none; font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; }
.table tbody td { background: #fff; border-top: 1px solid #edf1ed; border-bottom: 1px solid #edf1ed; }
.table tbody td:first-child { border-left: 1px solid #edf1ed; border-radius: 18px 0 0 18px; }
.table tbody td:last-child { border-right: 1px solid #edf1ed; border-radius: 0 18px 18px 0; }
.table-row-link:hover td { background: #f8fcfa; }
.toolbar.wrap { row-gap: 8px; }
.item-row { background: linear-gradient(180deg, #ffffff 0%, #fbfcfb 100%); }
input, textarea, select { background: #fbfdfb; }
input:disabled, textarea:disabled, select:disabled, button:disabled { opacity: .7; cursor: not-allowed; }
@media (max-width: 900px) { .content { padding: 18px; } .table { display: block; overflow-x: auto; } }


/* Sollox refresh */
body { background: #020b08; color: #eef7f1; }
.site-shell { min-height: 100vh; }
.site-header { position: sticky; top: 0; z-index: 30; display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 18px 34px; background: rgba(1, 10, 8, 0.92); border-bottom: 1px solid rgba(174, 212, 101, 0.12); backdrop-filter: blur(14px); }
.site-brand { display: flex; align-items: baseline; gap: 12px; }
.site-logo { font-size: 2.35rem; font-weight: 800; letter-spacing: 0.04em; color: #a6d25f; text-decoration: none; }
.site-subtitle { color: rgba(255,255,255,0.72); font-size: 0.95rem; }
.site-nav { display: flex; gap: 22px; flex-wrap: wrap; }
.site-nav a { color: #edf6ef; text-decoration: none; font-weight: 500; }
.site-nav a:hover { color: #a6d25f; }
.site-user { display: flex; align-items: center; gap: 12px; color: rgba(255,255,255,0.82); }
.site-main { max-width: 1280px; margin: 0 auto; padding: 28px 32px 56px; }
.page-header { margin-bottom: 18px; }
.card, .list-card, .contact-card, .item-row { background: linear-gradient(180deg, rgba(9,24,20,0.94), rgba(5,16,13,0.96)); border: 1px solid rgba(174, 212, 101, 0.14); box-shadow: 0 16px 50px rgba(0,0,0,0.24); color: #eef7f1; }
input, select, textarea { background: rgba(255,255,255,0.06); color: #f4fbf6; border: 1px solid rgba(174, 212, 101, 0.18); }
input:disabled, select:disabled, textarea:disabled { opacity: 0.72; }
.table { background: transparent; }
.table thead th { color: #a6d25f; border-bottom-color: rgba(174, 212, 101, 0.18); }
.table td { border-bottom-color: rgba(174, 212, 101, 0.1); }
.table-row-link:hover td { background: rgba(166, 210, 95, 0.08); }
.button { border-radius: 14px; }
.button.primary { background: #a6d25f; color: #08110d; border-color: #a6d25f; }
.button.secondary { background: rgba(255,255,255,0.04); color: #eef7f1; border-color: rgba(174, 212, 101, 0.18); }
.button.secondary:hover { background: rgba(166, 210, 95, 0.12); }
.eyebrow { color: #a6d25f; letter-spacing: 0.22em; text-transform: uppercase; font-size: 0.74rem; font-weight: 700; }
.muted { color: rgba(255,255,255,0.72); }
.project-hero { display: flex; justify-content: space-between; align-items: center; gap: 20px; margin-bottom: 20px; padding: 28px; border-radius: 28px; background: radial-gradient(circle at top left, rgba(166,210,95,0.14), transparent 35%), linear-gradient(180deg, rgba(5,18,15,0.97), rgba(4,12,10,0.98)); }
.project-hero h3 { margin: 8px 0 0; font-size: 2rem; }
.stats-grid, .project-stats-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; margin: 20px 0; }
.stat-card { padding: 22px; border-radius: 22px; }
.stat-card span, .stat-card small { color: rgba(255,255,255,0.72); }
.stat-card strong { display: block; font-size: 1.8rem; margin: 8px 0 4px; }
.workflow-card { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 18px; }
.workflow-step { border: 1px solid rgba(174, 212, 101, 0.12); border-radius: 18px; padding: 16px; display: flex; align-items: center; gap: 12px; background: rgba(255,255,255,0.03); }
.workflow-step strong { width: 34px; height: 34px; display: inline-flex; align-items: center; justify-content: center; border-radius: 999px; background: rgba(166,210,95,0.12); color: #a6d25f; }
.workflow-step.active { border-color: rgba(166,210,95,0.45); background: rgba(166,210,95,0.08); }
.project-tabs-card { margin-bottom: 18px; }
.project-tab-bar .button { min-width: 110px; text-align: center; }
.section-header-bar { justify-content: space-between; margin-bottom: 14px; }
.workflow-hint { color: #d5efae; }
.offer-form-card { border-radius: 28px; }
.offer-sheet-sidebar hr { border: 0; border-top: 1px solid rgba(174, 212, 101, 0.12); margin: 12px 0; }
.alert.error { margin-bottom: 16px; padding: 14px 16px; border-radius: 14px; background: rgba(190, 61, 61, 0.16); color: #ffd7d7; border: 1px solid rgba(255,120,120,0.25); }
.table-actions { justify-content: flex-end; }
.feature-list { margin: 12px 0 0; padding-left: 18px; display: grid; gap: 10px; }
.feature-list li { color: rgba(255,255,255,0.82); }
.badge, .badge-success, .badge-warning, .badge-danger, .badge-muted { border: 1px solid transparent; }
.badge-success { background: rgba(166,210,95,0.14); color: #d8f3a6; border-color: rgba(166,210,95,0.24); }
.badge-warning { background: rgba(255,193,7,0.16); color: #ffe597; border-color: rgba(255,193,7,0.26); }
.badge-danger { background: rgba(230,85,85,0.18); color: #ffbcbc; border-color: rgba(230,85,85,0.28); }
.badge-muted { background: rgba(255,255,255,0.08); color: rgba(255,255,255,0.74); border-color: rgba(255,255,255,0.12); }
@media (max-width: 1100px) { .stats-grid, .project-stats-grid, .workflow-card { grid-template-columns: repeat(2, minmax(0, 1fr)); } .site-header { flex-wrap: wrap; } }
@media (max-width: 720px) { .site-main { padding: 20px 16px 44px; } .project-hero, .site-header { padding: 18px; } .stats-grid, .project-stats-grid, .workflow-card { grid-template-columns: 1fr; } .site-nav { gap: 12px; } }


body { background: #020a07; color: #f6fbf0; }
.site-shell { min-height: 100vh; }
.site-header { position: sticky; top: 0; z-index: 10; display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 18px 34px; border-bottom: 1px solid rgba(166,210,95,0.12); background: rgba(2,10,7,0.96); backdrop-filter: blur(14px); }
.site-brand { display: flex; align-items: baseline; gap: 14px; }
.site-logo { font-size: 28px; font-weight: 800; letter-spacing: .02em; color: #a6d25f; }
.site-subtitle { font-size: 14px; color: rgba(255,255,255,0.72); }
.site-nav { display: flex; flex-wrap: wrap; gap: 18px; }
.site-nav a { color: rgba(255,255,255,0.82); }
.site-nav a:hover { color: #a6d25f; }
.site-user { display: flex; align-items: center; gap: 12px; color: rgba(255,255,255,0.82); }
.site-main { padding: 28px 34px 48px; max-width: 1360px; margin: 0 auto; }
.page-header { display:none; }

.card { background: linear-gradient(180deg, rgba(5,18,12,0.96), rgba(3,13,9,0.98)); color: #f4f9ee; border: 1px solid rgba(166,210,95,0.14); box-shadow: 0 18px 48px rgba(0,0,0,.22); }
.card.compact { padding: 18px; }
.dashboard-hero { display: flex; align-items: center; justify-content: space-between; gap: 24px; margin-bottom: 20px; border-radius: 28px; background: radial-gradient(circle at top center, rgba(166,210,95,0.08), transparent 38%), linear-gradient(90deg, rgba(8,25,17,0.98), rgba(2,13,9,0.98)); }
.dashboard-hero h3, .project-hero h3 { font-size: 2rem; margin: 6px 0 10px; }
.eyebrow { color: #a6d25f; }
.muted, .stat-card small, .stat-card span { color: rgba(255,255,255,0.72); }
label span { color: rgba(255,255,255,0.74); }
input, textarea, select { background: rgba(255,255,255,0.04); color: #f5fbef; border: 1px solid rgba(255,255,255,0.12); }
input:focus, textarea:focus, select:focus { outline: none; border-color: rgba(166,210,95,0.38); box-shadow: 0 0 0 3px rgba(166,210,95,0.1); }
.button { border-radius: 14px; font-weight: 600; }
.button.primary { background: #a6d25f; color: #0b140d; }
.button.secondary { background: rgba(255,255,255,0.06); color: #f5fbef; border: 1px solid rgba(255,255,255,0.1); }
.button.secondary:hover { border-color: rgba(166,210,95,0.28); color: #a6d25f; }
.table { width: 100%; }
.table th, .table td { border-bottom: 1px solid rgba(255,255,255,0.08); color: #f4f9ee; }
.table th { color: #a6d25f; font-size: 12px; text-transform: uppercase; letter-spacing: .12em; }
.table-row-link:hover { background: rgba(166,210,95,0.05); }
.table-actions { margin-bottom: 0; }
.stat-card strong { color: #fff; }
.project-tabs-card .button.primary { background: rgba(166,210,95,0.18); color: #dff4b7; border: 1px solid rgba(166,210,95,0.26); }
.project-tabs-card .button.secondary { background: transparent; }
.workflow-banner { margin-bottom: 18px; padding: 14px 16px; border-radius: 14px; background: rgba(166,210,95,0.1); color: #e1f2c1; border: 1px solid rgba(166,210,95,0.2); }
.offer-sheet-sidebar, .offer-sheet-block, .item-row { background: rgba(255,255,255,0.03); border-color: rgba(255,255,255,0.08); }
hr { border-color: rgba(255,255,255,0.08); }
@media (max-width: 960px) {
  .dashboard-hero, .project-hero, .site-header { flex-direction: column; align-items: flex-start; }
  .offer-sheet-preview, .offer-sheet-top, .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
}

.card.subtle{background:rgba(255,255,255,.03);border:1px solid rgba(161,201,93,.12)}
.table.compact td,.table.compact th{padding:10px 12px;font-size:14px}
.text-muted{opacity:.75}
.workflow-banner{margin:12px 0;padding:12px 14px;border-radius:12px;background:rgba(161,201,93,.12);border:1px solid rgba(161,201,93,.25)}


.billing-legend{display:flex;gap:10px;flex-wrap:wrap}
.billing-table .billing-row td{vertical-align:middle}
.billing-row-open td{box-shadow: inset 0 0 0 1px rgba(166,210,95,0.12)}
.billing-row-partial td{box-shadow: inset 0 0 0 1px rgba(255,193,7,0.12)}
.billing-row-complete td{opacity:.72}
.billing-row.is-disabled td{opacity:.6}
.billing-progress{width:100%;height:8px;border-radius:999px;background:rgba(255,255,255,.08);overflow:hidden;margin-bottom:6px}
.billing-progress-bar{height:100%;background:linear-gradient(90deg,#a6d25f,#d9f39d)}
.billing-table small{color:rgba(255,255,255,.72)}
.invoice-type-stack{display:grid;gap:4px}

.site-nav a.is-active,
.site-subnav a.is-active {
  color: #a6d25f;
}
.site-nav-group {
  position: relative;
  display: inline-flex;
  align-items: center;
}
.site-subnav {
  position: absolute;
  top: calc(100% + 10px);
  left: 0;
  min-width: 220px;
  display: none;
  flex-direction: column;
  gap: 6px;
  padding: 12px;
  border-radius: 16px;
  background: rgba(6, 18, 14, 0.98);
  border: 1px solid rgba(166,210,95,0.15);
  box-shadow: 0 18px 40px rgba(0,0,0,0.28);
}
.site-nav-group:hover .site-subnav,
.site-nav-group:focus-within .site-subnav {
  display: flex;
}
.site-subnav a {
  padding: 10px 12px;
  border-radius: 12px;
  color: rgba(255,255,255,0.82);
  background: rgba(255,255,255,0.03);
}
.site-subnav a:hover {
  background: rgba(166,210,95,0.1);
  color: #a6d25f;
}
.finance-subnav {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 18px;
}
.finance-subnav .button.is-active {
  background: #a6d25f;
  color: #08110d;
}

/* Final Sollox UI cleanup 2026-04-18 */
:root {
  --crm-bg: #020a07;
  --crm-surface: #071510;
  --crm-surface-2: #0a1a14;
  --crm-surface-3: #0e2018;
  --crm-line: rgba(166,210,95,0.14);
  --crm-line-strong: rgba(166,210,95,0.24);
  --crm-text: #f4f9ee;
  --crm-text-muted: rgba(244,249,238,0.72);
  --crm-brand: #a6d25f;
}

body {
  background: var(--crm-bg);
  color: var(--crm-text);
}

.card,
.list-card,
.contact-card,
.item-row,
.offer-sheet-block,
.offer-sheet-sidebar,
.workflow-step,
.workflow-banner,
.project-hero,
.dashboard-hero,
.stat-card {
  background: linear-gradient(180deg, rgba(8,22,16,0.98), rgba(4,12,9,0.99));
  color: var(--crm-text);
  border-color: var(--crm-line);
}

.table,
.table.compact {
  width: 100%;
  border-collapse: collapse !important;
  border-spacing: 0 !important;
  border: 1px solid var(--crm-line);
  background: transparent;
}

.table,
.table thead,
.table tbody,
.table tr,
.table th,
.table td {
  border-radius: 0 !important;
}

.table thead th {
  padding: 12px 10px;
  background: rgba(166,210,95,0.04);
  color: var(--crm-brand);
  border-bottom: 1px solid var(--crm-line-strong);
}

.table tbody tr {
  background: transparent;
}

.table tbody td,
.table tbody th {
  background: var(--crm-surface-2) !important;
  color: var(--crm-text) !important;
  border-top: 0 !important;
  border-left: 0 !important;
  border-right: 0 !important;
  border-bottom: 1px solid rgba(255,255,255,0.08) !important;
}

.table tbody tr:last-child td,
.table tbody tr:last-child th {
  border-bottom: 0 !important;
}

.table-row-link:hover,
.table-row-link.is-active {
  background: transparent;
}

.table-row-link:hover td,
.table-row-link:hover th {
  background: var(--crm-surface-3) !important;
}

.table-actions,
.table-actions .toolbar {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
}

.row-link-text,
.table td a,
.table th a {
  color: inherit;
}

.button,
.badge,
.alert.error,
.workflow-banner,
.workflow-step,
.site-subnav,
.site-subnav a,
input,
select,
textarea {
  border-radius: 10px;
}

.muted,
.text-muted,
.table small,
small,
label span,
.stat-card span,
.stat-card small {
  color: var(--crm-text-muted);
}

.site-subnav {
  border-radius: 0;
}

@media (max-width: 900px) {
  .table {
    display: table;
    overflow-x: visible;
  }
}


/* Fix 2026-04-18: finance submenu should only appear on hover or focus */
.site-nav-group .site-subnav { display:none !important; }
.site-nav-group:hover .site-subnav,
.site-nav-group:focus-within .site-subnav { display:flex !important; }


/* Settings + submenu fix 2026-04-18 */
.site-nav{overflow:visible}
.site-nav-group{position:relative;z-index:40}
.site-nav-group > a{display:inline-flex;align-items:center;gap:8px}
.site-subnav{
  display:flex !important;
  visibility:hidden;
  opacity:0;
  pointer-events:none;
  transform:translateY(6px);
  transition:opacity .14s ease, transform .14s ease, visibility .14s ease;
}
.site-nav-group:hover .site-subnav,
.site-nav-group:focus-within .site-subnav{
  visibility:visible;
  opacity:1;
  pointer-events:auto;
  transform:translateY(0);
}
.settings-subnav{display:flex;flex-wrap:wrap;gap:10px;margin-top:12px}
.settings-panel[hidden]{display:none !important}
.settings-nav-card{position:sticky;top:0;z-index:5}
.settings-range-card{min-height:100%}
.badge.neutral{background:rgba(255,255,255,.06);border:1px solid rgba(255,255,255,.14);color:rgba(255,255,255,.78)}
@media (max-width:900px){.settings-nav-card{position:static}}

.page-header-with-actions{display:flex;align-items:flex-end;justify-content:space-between;gap:16px;flex-wrap:wrap}.page-actions{margin-bottom:0}.table-responsive{width:100%;overflow-x:auto}.align-right{text-align:right}.badge.success{background:rgba(88,186,119,.18);color:#baf0c9;border:1px solid rgba(88,186,119,.3)}.badge.warning{background:rgba(230,183,74,.16);color:#ffe29f;border:1px solid rgba(230,183,74,.28)}


/* Einheitliches Listen-Design wie in der Dokumentenauflistung */
.table.table-workflow {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0 8px;
}
.table.table-workflow thead th {
    border-bottom: 0;
    padding: 8px 12px;
    font-size: 12px;
    letter-spacing: .04em;
    text-transform: uppercase;
    color: #5a6a6f;
}
.table.table-workflow tbody tr {
    background: #fffdf9;
    box-shadow: 0 1px 0 rgba(16,59,53,.06);
}
.table.table-workflow tbody td {
    border-top: 1px solid #e8dfd3;
    border-bottom: 1px solid #e8dfd3;
    padding: 14px 12px;
    vertical-align: top;
}
.table.table-workflow tbody td:first-child {
    border-left: 1px solid #e8dfd3;
    border-top-left-radius: 16px;
    border-bottom-left-radius: 16px;
}
.table.table-workflow tbody td:last-child {
    border-right: 1px solid #e8dfd3;
    border-top-right-radius: 16px;
    border-bottom-right-radius: 16px;
}
.document-items {
    margin-top: 18px;
}
.document-items .item-row {
    background: #fffdf9;
    border-color: #e8dfd3;
    border-radius: 20px;
    box-shadow: 0 1px 0 rgba(16,59,53,.06);
}
.document-items .item-row + .item-row {
    margin-top: 8px;
}
.document-items .toolbar h3 {
    margin: 0;
}


/* 2026-05-10 flat-doc-tables: Einheitliches Listen-/Tabellen-Design ohne gerundete Tabellenzellen */
.table,
.table.table-workflow,
.table.compact {
  width: 100% !important;
  border-collapse: collapse !important;
  border-spacing: 0 !important;
  border: 1px solid var(--crm-line, rgba(255,255,255,.12)) !important;
  background: transparent !important;
}
.table *,
.table.table-workflow *,
.table.compact * {
  border-radius: 0 !important;
}
.table thead th,
.table.table-workflow thead th,
.table.compact thead th {
  padding: 12px 10px !important;
  border-bottom: 1px solid var(--crm-line-strong, rgba(255,255,255,.18)) !important;
  background: rgba(166,210,95,0.04) !important;
  color: var(--crm-brand, #a6d25f) !important;
  text-transform: none !important;
  letter-spacing: normal !important;
}
.table tbody tr,
.table.table-workflow tbody tr,
.table.compact tbody tr {
  background: transparent !important;
  box-shadow: none !important;
}
.table tbody td,
.table tbody th,
.table.table-workflow tbody td,
.table.table-workflow tbody th,
.table.compact tbody td,
.table.compact tbody th {
  padding: 12px 10px !important;
  border: 0 !important;
  border-bottom: 1px solid rgba(255,255,255,.08) !important;
  background: var(--crm-surface-2, #111b18) !important;
  color: var(--crm-text, #f4f7f5) !important;
  vertical-align: top !important;
}
.table tbody tr:last-child td,
.table tbody tr:last-child th,
.table.table-workflow tbody tr:last-child td,
.table.table-workflow tbody tr:last-child th {
  border-bottom: 0 !important;
}
.offer-position-table,
.invoice-position-table,
.change-order-position-table,
.contract-position-table,
.position-table {
  gap: 0 !important;
  border: 1px solid var(--crm-line, rgba(255,255,255,.12)) !important;
  border-radius: 0 !important;
  overflow: visible !important;
}
.offer-position-table-head,
.offer-position-row,
.invoice-position-row,
.change-order-position-row,
.contract-position-row,
.position-row,
.item-row {
  border-radius: 0 !important;
  box-shadow: none !important;
}
.offer-position-row,
.invoice-position-row,
.change-order-position-row,
.contract-position-row,
.position-row {
  border-left: 0 !important;
  border-right: 0 !important;
  border-top: 0 !important;
  border-bottom: 1px solid var(--crm-line, rgba(255,255,255,.12)) !important;
  background: var(--crm-surface-2, #111b18) !important;
}
.offer-position-table-head {
  border-bottom: 1px solid var(--crm-line-strong, rgba(255,255,255,.18)) !important;
  padding: 12px !important;
  background: rgba(166,210,95,0.04) !important;
}
.document-items .item-row {
  border-radius: 0 !important;
  box-shadow: none !important;
}

/* 2026-05-10 brand-position-fields: Firmenfarben für Angebots-/Positionsfelder statt weiße Karten */
:root {
  --crm-bg: #020a07;
  --crm-surface: #071510;
  --crm-surface-2: #0a1a14;
  --crm-surface-3: #0e2018;
  --crm-line: rgba(166,210,95,0.18);
  --crm-line-strong: rgba(166,210,95,0.32);
  --crm-text: #f4f9ee;
  --crm-text-muted: rgba(244,249,238,0.74);
  --crm-brand: #a6d25f;
  --crm-brand-soft: rgba(166,210,95,0.09);
}

/* Positionen in Angeboten/Rechnungen/Nachträgen: keine weißen Flächen, keine schlecht lesbaren Texte */
.document-items,
.offer-document-items,
.position-table,
.offer-position-table,
.invoice-position-table,
.change-order-position-table,
.contract-position-table {
  color: var(--crm-text) !important;
}

.document-items .toolbar h3,
.offer-document-items .toolbar h3,
.position-table h3 {
  color: var(--crm-text) !important;
}

.document-items .item-list,
.offer-document-items .item-list {
  gap: 14px !important;
}

.document-items .item-row,
.offer-document-items .item-row,
.item-row,
.offer-position-row,
.invoice-position-row,
.change-order-position-row,
.contract-position-row,
.position-row {
  background: linear-gradient(180deg, rgba(10,26,20,0.98), rgba(5,15,11,0.99)) !important;
  border: 1px solid var(--crm-line) !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  color: var(--crm-text) !important;
}

.document-items .item-row label,
.document-items .item-row label span,
.offer-document-items .item-row label,
.offer-document-items .item-row label span,
.item-row label,
.item-row label span {
  color: var(--crm-text-muted) !important;
}

.document-items .item-row input,
.document-items .item-row textarea,
.document-items .item-row select,
.offer-document-items .item-row input,
.offer-document-items .item-row textarea,
.offer-document-items .item-row select,
.item-row input,
.item-row textarea,
.item-row select {
  background: rgba(255,255,255,0.055) !important;
  color: var(--crm-text) !important;
  border: 1px solid rgba(166,210,95,0.20) !important;
  border-radius: 0 !important;
  box-shadow: none !important;
}

.document-items .item-row input:focus,
.document-items .item-row textarea:focus,
.document-items .item-row select:focus,
.offer-document-items .item-row input:focus,
.offer-document-items .item-row textarea:focus,
.offer-document-items .item-row select:focus,
.item-row input:focus,
.item-row textarea:focus,
.item-row select:focus {
  border-color: var(--crm-brand) !important;
  box-shadow: 0 0 0 2px rgba(166,210,95,0.12) !important;
  outline: none !important;
}

.document-items .item-row input[readonly],
.item-row input[readonly] {
  background: rgba(166,210,95,0.075) !important;
  color: #e9f7cf !important;
}

.offer-position-table-head,
.invoice-position-table-head,
.change-order-position-table-head,
.contract-position-table-head,
.position-table-head {
  background: var(--crm-brand-soft) !important;
  border: 1px solid var(--crm-line-strong) !important;
  border-radius: 0 !important;
  color: var(--crm-brand) !important;
}

.table tbody td,
.table tbody th,
.table.table-workflow tbody td,
.table.table-workflow tbody th,
.table.compact tbody td,
.table.compact tbody th {
  background: var(--crm-surface-2) !important;
  color: var(--crm-text) !important;
}

.table tbody tr:hover td,
.table tbody tr:hover th,
.table-row-link:hover td,
.table-row-link:hover th {
  background: var(--crm-surface-3) !important;
}

/* Browser-Autofill darf die dunklen Felder nicht weiß färben */
input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus,
textarea:-webkit-autofill,
select:-webkit-autofill {
  -webkit-text-fill-color: var(--crm-text) !important;
  transition: background-color 99999s ease-in-out 0s !important;
  box-shadow: 0 0 0 1000px #0a1a14 inset !important;
}

/* 2026-05-10 offer-position-collapse: Angebotspositionen zu-/aufklappbar */
.document-items .item-row {
  padding: 0 !important;
  overflow: hidden !important;
}
.document-items .item-row-summary {
  display: flex !important;
  align-items: end !important;
  gap: 12px !important;
  padding: 18px 20px !important;
  background: linear-gradient(180deg, rgba(10,26,20,0.98), rgba(5,15,11,0.99)) !important;
}
.document-items .item-row-summary-fields {
  flex: 1 1 auto !important;
  margin: 0 !important;
}
.document-items .item-row-summary label {
  margin: 0 !important;
}
.document-items .item-row-summary input {
  min-height: 44px !important;
}
.document-items .item-toggle {
  flex: 0 0 auto !important;
  white-space: nowrap !important;
  border-color: rgba(166,210,95,0.55) !important;
  color: var(--crm-brand, #a6d25f) !important;
}
.document-items .item-row-details {
  display: block !important;
  padding: 0 20px 20px !important;
  border-top: 1px solid rgba(166,210,95,0.16) !important;
}
.document-items .item-row.is-collapsed .item-row-details {
  display: none !important;
}
.document-items .item-row.is-expanded {
  border-color: rgba(166,210,95,0.48) !important;
}
.document-items .item-row.is-expanded .item-row-summary {
  background: linear-gradient(180deg, rgba(18,38,28,0.98), rgba(7,21,16,0.99)) !important;
}
@media (max-width: 900px) {
  .document-items .item-row-summary {
    align-items: stretch !important;
    flex-direction: column !important;
  }
  .document-items .item-toggle {
    width: 100% !important;
  }
}


/* 2026-05-10: Clean CC checkbox block on document email form */
.email-cc-box {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 18px 20px;
  border: 1px solid rgba(99, 180, 65, 0.35);
  background: rgba(6, 26, 18, 0.72);
}
.email-cc-box .email-cc-title {
  display: block;
  margin-bottom: 2px;
  color: #f5fff0;
}
.email-cc-option {
  display: flex !important;
  align-items: center;
  justify-content: flex-start;
  gap: 10px;
  width: fit-content;
  max-width: 100%;
  margin: 0;
  color: #f5fff0;
  font-weight: 600;
  line-height: 1.35;
  cursor: pointer;
}
.email-cc-option input[type="checkbox"] {
  appearance: auto;
  -webkit-appearance: checkbox;
  display: inline-block;
  flex: 0 0 auto;
  width: 18px !important;
  min-width: 18px !important;
  max-width: 18px !important;
  height: 18px !important;
  min-height: 18px !important;
  margin: 0;
  padding: 0;
  border: 1px solid rgba(99, 180, 65, 0.65);
  accent-color: #63b441;
  vertical-align: middle;
}
.email-cc-option span {
  display: inline-block;
}
.email-cc-option .muted {
  font-weight: 500;
}
