/* ==========================================================================
   Belasitsa B2B Portal — design system (Pastry theme edition)
   Visual language adapted from the NicDark "Pastry" bakery theme:
   Cormorant headings in dusty rose, Alegreya body copy, blush square buttons,
   cocoa-brown blocks, pink-to-white gradient sections, airy centered headers.
   ========================================================================== */

:root {
  /* Surfaces */
  --bg: #FFFFFF;
  --surface: #FFFFFF;
  --surface-2: #FBF3F1;          /* soft blush panel */
  --blush-grad: linear-gradient(180deg, #F3DCD8 0%, #FBF3F1 60%, #FFFFFF 100%);
  --line: #EFE1DE;
  --line-strong: #E0CFCA;

  /* Ink */
  --ink: #533633;                /* cocoa — headings, dark blocks */
  --ink-2: #6B5552;
  --muted: #8A7B79;
  --muted-2: #B3A7A5;
  --body: #747474;               /* theme body gray */

  /* Theme palette */
  --accent: #E0BDB6;             /* blush — primary buttons */
  --accent-dark: #CFA399;
  --accent-soft: #F6E7E4;
  --rose: #CFAAA3;               /* heading rose */
  --cocoa: #533633;
  --cocoa-soft: #6A4A46;
  --caramel: #C7A88A;            /* sesame / tahini accent */
  --caramel-soft: #F3EADF;
  --sage: #8FA58F;               /* OK / natural */
  --sage-soft: #EAF0EA;

  /* Legacy names still used across modules — re-pointed to the theme palette */
  --red: #C4766D;  --red-dark: #A85C53; --red-soft: #F8E6E3;
  --green: #7E9A7A; --green-dark: #5F7D5B; --green-soft: #EAF0EA;
  --gold: #C7A88A;  --gold-dark: #A68564; --gold-soft: #F3EADF;
  --blue: #7F8FA6;  --blue-soft: #EEF1F5;

  /* Typography */
  --font-ui: "Comfortaa", "Segoe UI", system-ui, Arial, sans-serif;
  --font-body: "Comfortaa", "Segoe UI", system-ui, sans-serif;
  --font-display: "Comfortaa", "Segoe UI", system-ui, sans-serif;

  /* Shape — the theme uses square corners and soft, warm shadows */
  --r-sm: 0;
  --r: 0;
  --r-lg: 0;
  --shadow-sm: 0 1px 2px rgba(83, 54, 51, 0.06);
  --shadow: 0 10px 30px rgba(83, 54, 51, 0.10);
  --shadow-lg: 0 24px 60px rgba(83, 54, 51, 0.22);

  /* Layout */
  --container: 1200px;
  --gutter: 16px;
  --header-h: 84px;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.6;
  color: var(--body);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}
img, svg { display: block; max-width: 100%; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: var(--accent-dark); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4 { margin: 0; font-family: var(--font-display); line-height: 1.15; color: var(--ink); font-weight: 500; letter-spacing: 0; }
h1 { font-size: clamp(38px, 5vw, 64px); }
h2 { font-size: clamp(32px, 3.6vw, 46px); color: var(--rose); }
h3 { font-size: 26px; }
h4 { font-size: 17px; font-family: var(--font-ui); font-weight: 500; }
p { margin: 0 0 14px; }
small { font-size: 13px; }
table { border-collapse: collapse; width: 100%; }
hr { border: 0; border-top: 1px solid var(--line); margin: 24px 0; }
code { font-family: ui-monospace, "Cascadia Mono", Consolas, monospace; font-size: 0.9em; }
:focus-visible { outline: 2px solid var(--accent-dark); outline-offset: 2px; }

/* ---------- Layout ---------- */
.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 var(--gutter); }
.section { padding: 72px 0; }
.section-head { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 10px; margin: 0 auto 44px; max-width: 760px; }
.section-head .eyebrow { font-family: var(--font-body); font-style: italic; font-size: 18px; font-weight: 400; letter-spacing: 0.02em; text-transform: none; color: var(--body); }
.section-head h2::after { content: ""; display: block; width: 46px; height: 2px; background: var(--accent); margin: 16px auto 0; }
.section-head p { color: var(--body); font-size: 17px; max-width: 700px; }
.grid { display: grid; gap: 24px; }
.grid-2 { grid-template-columns: 1fr; }
.grid-3 { grid-template-columns: 1fr; }
.grid-4 { grid-template-columns: 1fr 1fr; }
@media (min-width: 720px) {
  .grid-2 { grid-template-columns: 1fr 1fr; }
  .grid-3 { grid-template-columns: repeat(3, 1fr); }
}
@media (min-width: 1024px) {
  .grid-4 { grid-template-columns: repeat(4, 1fr); }
  .section { padding: 100px 0; }
}
.stack { display: flex; flex-direction: column; gap: 12px; }
.row { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.row.between { justify-content: space-between; }
.right { text-align: right; }
.muted { color: var(--muted); }
.hidden { display: none !important; }
.nowrap { white-space: nowrap; }
.mono { font-family: ui-monospace, "Cascadia Mono", Consolas, monospace; font-size: 0.92em; }
.mt-8 { margin-top: 8px; } .mt-16 { margin-top: 16px; } .mt-24 { margin-top: 24px; } .mt-32 { margin-top: 32px; }
.mb-8 { margin-bottom: 8px; } .mb-16 { margin-bottom: 16px; } .mb-24 { margin-bottom: 24px; }

/* ---------- Cards ---------- */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow-sm); }
.card-body { padding: 24px; }
.card-head { padding: 18px 24px; border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.card-head h3 { font-family: var(--font-display); font-size: 22px; font-weight: 600; color: var(--ink); }
.card-foot { padding: 18px 24px; border-top: 1px solid var(--line); background: var(--surface-2); }

/* ---------- Buttons (theme: square, blush, Roboto) ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 12px 26px; border-radius: 0; border: 1px solid transparent;
  font-family: var(--font-ui); font-weight: 500; font-size: 14px; line-height: 1.2; letter-spacing: 0.03em; white-space: nowrap;
  transition: background .18s, border-color .18s, color .18s, transform .08s, box-shadow .18s;
  text-decoration: none !important;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-dark); }
.btn-dark { background: var(--cocoa); color: #fff; }
.btn-dark:hover { background: #3F2826; }
.btn-green { background: var(--sage); color: #fff; }
.btn-green:hover { background: var(--green-dark); }
.btn-gold { background: var(--caramel); color: #fff; }
.btn-gold:hover { background: var(--gold-dark); }
.btn-outline { background: transparent; border-color: var(--cocoa); color: var(--cocoa); }
.btn-outline:hover { background: var(--cocoa); color: #fff; }
.btn-ghost { background: transparent; color: var(--ink-2); }
.btn-ghost:hover { background: var(--surface-2); }
.btn-light { background: #fff; color: var(--ink); border-color: var(--line); }
.btn-light:hover { border-color: var(--cocoa); }
.btn-sm { padding: 9px 16px; font-size: 13px; }
.btn-xs { padding: 5px 10px; font-size: 12px; }
.btn-lg { padding: 15px 36px; font-size: 15px; }
.btn-block { width: 100%; }
.btn[disabled] { opacity: 0.5; cursor: not-allowed; }
.btn-icon { padding: 8px; }
.btn svg { width: 18px; height: 18px; flex: none; }

/* ---------- Badges / pills ---------- */
.badge {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 11px; border-radius: 999px; font-family: var(--font-ui); font-size: 12px; font-weight: 500; line-height: 1.5;
  background: var(--surface-2); color: var(--ink-2); border: 1px solid transparent;
}
.badge-red { background: var(--accent-soft); color: var(--red-dark); }
.badge-green { background: var(--sage-soft); color: var(--green-dark); }
.badge-gold { background: var(--caramel-soft); color: var(--gold-dark); }
.badge-blue { background: var(--blue-soft); color: var(--blue); }
.badge-ink { background: var(--cocoa); color: #fff; }
.badge-outline { background: transparent; border-color: var(--line-strong); }
.dot { width: 8px; height: 8px; border-radius: 50%; background: currentColor; display: inline-block; }

/* ---------- Forms (theme: underline inputs) ---------- */
.field { display: flex; flex-direction: column; gap: 6px; }
.field label, .label { font-family: var(--font-ui); font-size: 12.5px; font-weight: 500; letter-spacing: 0.04em; text-transform: uppercase; color: var(--ink-2); }
.field .hint { font-size: 12px; color: var(--muted); text-transform: none; letter-spacing: 0; }
.input, .select, .textarea {
  width: 100%; padding: 10px 2px; border: 0; border-bottom: 1px solid var(--line-strong); border-radius: 0;
  background: transparent; font-family: var(--font-ui); font-size: 14.5px; color: var(--ink); transition: border-color .15s;
}
.input::placeholder, .textarea::placeholder { color: var(--muted-2); }
.input:focus, .select:focus, .textarea:focus { border-bottom-color: var(--cocoa); outline: none; }
.input-sm, .select-sm { padding: 6px 2px; font-size: 13px; }
.textarea { min-height: 96px; resize: vertical; }
.select { appearance: none; -webkit-appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%238A7B79' stroke-width='2.5'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 6px center; padding-right: 26px; }
.form-grid { display: grid; grid-template-columns: 1fr; gap: 18px; }
@media (min-width: 720px) { .form-grid { grid-template-columns: 1fr 1fr; gap: 20px 28px; } .form-grid .span-2 { grid-column: span 2; } }
.input-group { display: flex; gap: 12px; }
.checkbox { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; color: var(--body); }
.checkbox input { margin-top: 4px; accent-color: var(--accent-dark); }

/* Boxed inputs where density matters (tables, pickers, search, chat) */
.table .input-sm, .table .select-sm, .picker-tools .input-sm, .archive-filters .input, .archive-filters .select, .catalog-search .input, .chat-input .input, .rfq-item input, .note-form .input, .note-form .select, .modal .input, .modal .select {
  border: 1px solid var(--line-strong); padding-left: 10px; padding-right: 10px; background: #fff;
}
.table .select-sm, .note-form .select, .modal .select, .archive-filters .select { padding-right: 26px; }

/* ---------- Tables ---------- */
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; border: 1px solid var(--line); background: #fff; }
.table { font-family: var(--font-ui); font-size: 13.5px; color: var(--ink-2); }
.table th, .table td { padding: 11px 12px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: middle; }
.table th { font-size: 11px; text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); font-weight: 500; background: var(--surface-2); white-space: nowrap; }
.table tbody tr:last-child td { border-bottom: 0; }
.table tbody tr:hover td { background: #FDF8F7; }
.table .num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.table-compact th, .table-compact td { padding: 8px 10px; font-size: 13px; }
.spec-table { font-family: var(--font-ui); font-size: 13.5px; }
.spec-table th { text-align: left; color: var(--muted); font-weight: 400; padding: 7px 0; width: 48%; border-bottom: 1px dashed var(--line); }
.spec-table td { padding: 7px 0; font-weight: 500; color: var(--ink); border-bottom: 1px dashed var(--line); text-align: right; font-variant-numeric: tabular-nums; }
.spec-table tr:last-child th, .spec-table tr:last-child td { border-bottom: 0; }

/* ---------- Header ---------- */
.site-header { position: sticky; top: 0; z-index: 60; background: rgba(255, 255, 255, 0.96); border-bottom: 1px solid var(--line); transition: background .3s, border-color .3s; }
.site-header .bar { height: var(--header-h); display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.brand { display: flex; align-items: center; gap: 14px; color: var(--ink); text-decoration: none !important; min-width: 0; }
.brand .logo { height: 46px; width: auto; }
.brand .brand-text { display: flex; flex-direction: column; line-height: 1.1; min-width: 0; }
.brand .brand-name { font-family: var(--font-display); font-weight: 600; font-size: 24px; letter-spacing: 0.01em; color: var(--ink); }
.brand .brand-sub { font-family: var(--font-body); font-style: italic; font-size: 13px; color: var(--rose); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nav { display: none; gap: 2px; }
.nav a { padding: 8px 12px; font-family: var(--font-body); font-size: 16px; font-weight: 400; color: var(--body); white-space: nowrap; text-decoration: none !important; border-bottom: 1px solid transparent; }
.nav a:hover, .nav a.active { color: var(--cocoa); border-bottom-color: var(--accent); }
.header-actions { display: flex; align-items: center; gap: 10px; }
.lang-switch { display: inline-flex; border: 1px solid var(--line-strong); padding: 2px; background: #fff; }
.lang-switch button { border: 0; background: transparent; padding: 5px 10px; font-family: var(--font-ui); font-size: 12.5px; font-weight: 500; color: var(--muted); }
.lang-switch button.active { background: var(--cocoa); color: #fff; }
.menu-toggle { display: inline-flex; }
@media (min-width: 1100px) { .nav { display: flex; } .menu-toggle { display: none; } }
.mobile-nav { display: none; border-top: 1px solid var(--line); background: var(--surface); padding: 10px var(--gutter) 16px; }
.mobile-nav.open { display: block; }
.mobile-nav a { display: block; padding: 12px 8px; font-size: 17px; color: var(--ink); border-bottom: 1px solid var(--line); }
.mobile-nav .row { padding-top: 14px; }
.hide-sm { display: none; }
@media (min-width: 720px) { .hide-sm { display: inline-flex; } }

/* Header over the video hero */
.site-header.is-top { background: linear-gradient(180deg, rgba(83, 54, 51, 0.55), rgba(83, 54, 51, 0)); border-bottom-color: transparent; }
.site-header.is-top .brand-name, .site-header.is-top .nav a, .site-header.is-top .btn-ghost { color: #fff; }
.site-header.is-top .brand-sub { color: #F2D9D3; }
.site-header.is-top .nav a:hover, .site-header.is-top .nav a.active { border-bottom-color: #fff; }
.site-header.is-top .lang-switch { background: rgba(255,255,255,.12); border-color: rgba(255,255,255,.4); }
.site-header.is-top .lang-switch button { color: rgba(255,255,255,.85); }
.site-header.is-top .lang-switch button.active { background: #fff; color: var(--cocoa); }
.site-header.is-top .btn-outline { border-color: rgba(255,255,255,.6); color: #fff; background: transparent; }
.site-header.is-top .btn-outline:hover { background: #fff; color: var(--cocoa); }

/* ---------- Footer (cocoa) ---------- */
.site-footer { background: var(--cocoa); color: #E9D8D3; padding: 72px 0 32px; margin-top: 0; }
.site-footer h4 { color: #fff; font-family: var(--font-display); font-size: 22px; font-weight: 500; margin-bottom: 14px; }
.site-footer a { color: #E9D8D3; }
.site-footer a:hover { color: #fff; }
.site-footer .foot-grid { display: grid; gap: 32px; grid-template-columns: 1fr; }
@media (min-width: 820px) { .site-footer .foot-grid { grid-template-columns: 1.4fr 1fr 1fr 1fr; } }
.site-footer .legal { border-top: 1px solid rgba(255,255,255,.14); margin-top: 48px; padding-top: 22px; font-family: var(--font-ui); font-size: 12.5px; color: #C9B2AC; display: flex; flex-wrap: wrap; gap: 10px; justify-content: space-between; }
.site-footer .logo-foot { height: 52px; width: auto; background: #fff; padding: 8px 12px; }
.site-footer ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 8px; font-size: 16px; }

/* ---------- Modal ---------- */
.modal-backdrop { position: fixed; inset: 0; z-index: 100; background: rgba(83, 54, 51, 0.55); display: flex; align-items: flex-end; justify-content: center; padding: 0; opacity: 0; pointer-events: none; transition: opacity .18s; }
.modal-backdrop.open { opacity: 1; pointer-events: auto; }
.modal { width: 100%; max-width: 760px; max-height: 92vh; overflow: auto; background: #fff; box-shadow: var(--shadow-lg); transform: translateY(24px); transition: transform .2s; }
.modal-backdrop.open .modal { transform: translateY(0); }
.modal.modal-wide { max-width: 1040px; }
.modal-head { position: sticky; top: 0; background: #fff; z-index: 2; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 18px 24px; border-bottom: 1px solid var(--line); }
.modal-head h3 { font-size: 26px; font-weight: 500; }
.modal-body { padding: 24px; }
.modal-foot { padding: 16px 24px; border-top: 1px solid var(--line); display: flex; gap: 10px; justify-content: flex-end; flex-wrap: wrap; background: var(--surface-2); }
@media (min-width: 720px) { .modal-backdrop { align-items: center; padding: 24px; } }

/* ---------- Toast ---------- */
.toast-host { position: fixed; left: 50%; bottom: 20px; transform: translateX(-50%); z-index: 200; display: flex; flex-direction: column; gap: 8px; align-items: center; pointer-events: none; width: calc(100% - 32px); max-width: 480px; }
.toast { background: var(--cocoa); color: #fff; padding: 12px 18px; font-family: var(--font-ui); font-size: 13.5px; box-shadow: var(--shadow-lg); display: flex; gap: 10px; align-items: center; animation: toast-in .2s ease-out; pointer-events: auto; }
.toast.success { background: var(--green-dark); }
.toast.error { background: var(--red-dark); }
@keyframes toast-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

/* ---------- Product packaging illustrations ---------- */
.pack-visual { display: flex; align-items: center; justify-content: center; height: 190px; background: var(--blush-grad); border-bottom: 1px solid var(--line); position: relative; overflow: hidden; }
.pack-visual::before { content: ""; position: absolute; width: 150px; height: 150px; border-radius: 50%; background: rgba(255,255,255,.55); }
.pack-visual svg { position: relative; height: 120px; width: auto; filter: drop-shadow(0 10px 14px rgba(83,54,51,.18)); }
.pack-visual .line-tag { position: absolute; top: 12px; left: 12px; }
.pack-visual .tags { position: absolute; top: 12px; right: 12px; display: flex; gap: 4px; }

/* ---------- Chatbot widget ---------- */
.chat-launcher { position: fixed; right: 18px; bottom: 18px; z-index: 90; display: flex; align-items: center; gap: 10px; padding: 13px 20px 13px 16px; background: var(--cocoa); color: #fff; border: 0; border-radius: 999px; font-family: var(--font-ui); font-weight: 500; font-size: 14px; box-shadow: 0 12px 32px rgba(83, 54, 51, 0.35); }
.chat-launcher:hover { background: #3F2826; }
.chat-launcher .pulse { width: 10px; height: 10px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 0 rgba(224,189,182,.7); animation: pulse 2s infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(224,189,182,.6); } 70% { box-shadow: 0 0 0 9px rgba(224,189,182,0); } 100% { box-shadow: 0 0 0 0 rgba(224,189,182,0); } }
.chat-panel { position: fixed; right: 0; bottom: 0; z-index: 95; width: 100%; height: 100%; background: #fff; display: flex; flex-direction: column; box-shadow: var(--shadow-lg); transform: translateY(16px); opacity: 0; pointer-events: none; transition: transform .2s, opacity .2s; }
.chat-panel.open { transform: none; opacity: 1; pointer-events: auto; }
@media (min-width: 560px) { .chat-panel { right: 18px; bottom: 18px; width: 390px; height: min(640px, calc(100vh - 36px)); overflow: hidden; border: 1px solid var(--line); } }
.chat-head { display: flex; align-items: center; gap: 12px; padding: 14px 16px; background: var(--cocoa); color: #fff; }
.chat-head .avatar { width: 40px; height: 40px; border-radius: 50%; background: var(--accent); color: var(--cocoa); display: grid; place-items: center; font-family: var(--font-display); font-weight: 700; font-size: 20px; }
.chat-head .title { font-family: var(--font-display); font-weight: 600; font-size: 18px; line-height: 1.2; }
.chat-head .status { font-family: var(--font-ui); font-size: 11.5px; color: #F2D9D3; display: flex; align-items: center; gap: 6px; }
.chat-head .close { margin-left: auto; background: transparent; border: 0; color: #fff; padding: 6px; }
.chat-head .close:hover { background: rgba(255,255,255,.12); }
.chat-body { flex: 1; overflow-y: auto; padding: 16px; display: flex; flex-direction: column; gap: 10px; background: var(--surface-2); }
.msg { max-width: 86%; padding: 10px 13px; font-family: var(--font-ui); font-size: 13.5px; line-height: 1.5; white-space: pre-line; color: var(--ink-2); }
.msg.bot { align-self: flex-start; background: #fff; border: 1px solid var(--line); }
.msg.user { align-self: flex-end; background: var(--cocoa); color: #fff; }
.msg strong { font-weight: 700; }
.msg .mini-table { margin-top: 6px; border-top: 1px solid var(--line); font-size: 12.5px; }
.msg .mini-table div { display: flex; justify-content: space-between; gap: 8px; padding: 4px 0; border-bottom: 1px solid var(--line); }
.msg .mini-table div span:last-child { font-weight: 500; white-space: nowrap; color: var(--ink); }
.typing { display: inline-flex; gap: 4px; padding: 10px 14px; }
.typing i { width: 6px; height: 6px; border-radius: 50%; background: var(--muted-2); animation: blink 1s infinite; }
.typing i:nth-child(2) { animation-delay: .15s; } .typing i:nth-child(3) { animation-delay: .3s; }
@keyframes blink { 0%, 80%, 100% { opacity: .3; } 40% { opacity: 1; } }
.quick-replies { display: flex; flex-wrap: wrap; gap: 6px; padding: 8px 12px; border-top: 1px solid var(--line); background: #fff; }
.quick-replies button { font-family: var(--font-ui); font-size: 12px; font-weight: 500; padding: 6px 11px; border-radius: 999px; border: 1px solid var(--line-strong); background: #fff; color: var(--ink-2); }
.quick-replies button:hover { border-color: var(--cocoa); color: var(--cocoa); }
.chat-input { display: flex; gap: 8px; padding: 10px 12px; border-top: 1px solid var(--line); background: #fff; }
.chat-input input { flex: 1; }
.chat-input button { padding: 8px 12px; }

/* ---------- Misc ---------- */
.kpi-list { display: flex; flex-wrap: wrap; gap: 8px; }
.kpi-list .badge { padding: 8px 14px; font-size: 12.5px; background: #fff; border: 1px solid var(--line); }
.kpi-list .badge svg { width: 15px; height: 15px; color: var(--accent-dark); }
.empty { padding: 32px; text-align: center; color: var(--muted); font-size: 15px; font-style: italic; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); overflow-x: auto; }
.tabs button { background: transparent; border: 0; padding: 10px 14px; font-family: var(--font-ui); font-weight: 500; font-size: 13.5px; color: var(--muted); border-bottom: 2px solid transparent; margin-bottom: -1px; white-space: nowrap; }
.tabs button.active { color: var(--ink); border-bottom-color: var(--accent-dark); }
.status-pill { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: 999px; font-family: var(--font-ui); font-size: 12px; font-weight: 500; }
.status-draft { background: var(--surface-2); color: var(--ink-2); }
.status-sent { background: var(--blue-soft); color: var(--blue); }
.status-accepted { background: var(--sage-soft); color: var(--green-dark); }
.status-expired { background: var(--accent-soft); color: var(--red-dark); }
.status-new { background: var(--caramel-soft); color: var(--gold-dark); }
.status-contacted { background: var(--sage-soft); color: var(--green-dark); }
.status-ok { background: var(--sage-soft); color: var(--green-dark); }
.status-manual { background: var(--caramel-soft); color: var(--gold-dark); }
.ic { width: 16px; height: 16px; flex: none; vertical-align: -3px; }
.toast svg { width: 18px; height: 18px; }
.chat-launcher svg { width: 20px; height: 20px; }
.status-pill svg, .badge svg { width: 14px; height: 14px; }
.cnt { flex: none; }

/* Overflow guards */
.grid > *, .hero .container > *, .logi-wrap > *, .pl-wrap > *, .contact-wrap > *, .haccp-layout > *, .brand-text { min-width: 0; }
@media (max-width: 560px) {
  .btn { white-space: normal; text-align: center; }
  .btn-lg { white-space: normal; }
  .brand .brand-sub { display: none; }
  .chat-panel { inset: 0; width: auto; height: auto; }
  .journal-head .row { width: 100%; }
}

/* ---------- Print: only .print-host is printed (offer / HACCP export) ---------- */
.print-host { display: none; }
@media print {
  body { background: #fff; }
  body.printing > *:not(.print-host) { display: none !important; }
  body.printing .print-host { display: block !important; }
  .chat-launcher, .chat-panel, .toast-host, .site-header, .site-footer { display: none !important; }
  @page { size: A4; margin: 14mm 12mm; }
}

/* Header density: logo carries the brand name on the public site; nav tightened */
.nav a { font-size: 15px; padding: 8px 9px; }
@media (min-width: 1100px) and (max-width: 1199px) { .nav { display: none; } .menu-toggle { display: inline-flex; } }
@media (max-width: 1499px) {
  body:not(.admin) .site-header .brand-text { display: none; }
  body:not(.admin) .header-actions .btn-outline span { display: none; }
  body:not(.admin) .header-actions .btn-outline { padding: 8px 10px; }
}

/* ---------- Navigation: absolute (not sticky), transparent, over the video / page band ---------- */
body:not(.admin) .site-header { position: absolute; top: 0; left: 0; right: 0; z-index: 60; background: transparent; border-bottom: 0; backdrop-filter: none; -webkit-backdrop-filter: none; }
body:not(.admin) .site-header .bar { height: var(--header-h); }
body:not(.admin) .site-header .brand-name, body:not(.admin) .site-header .nav a, body:not(.admin) .site-header .btn-ghost { color: #fff; }
body:not(.admin) .site-header .nav a:hover, body:not(.admin) .site-header .nav a.active, body:not(.admin) .site-header .nav .has-sub.active > a { border-bottom-color: #fff; color: #fff; }
body:not(.admin) .site-header .lang-switch { background: rgba(255,255,255,.12); border-color: rgba(255,255,255,.4); }
body:not(.admin) .site-header .lang-switch button { color: rgba(255,255,255,.85); }
body:not(.admin) .site-header .lang-switch button.active { background: #fff; color: var(--cocoa); }
body:not(.admin) .site-header .btn-outline { border-color: rgba(255,255,255,.6); color: #fff; background: transparent; }
body:not(.admin) .site-header .btn-outline:hover { background: #fff; color: var(--cocoa); }
body:not(.admin) .site-header .nav .has-sub .sub a { color: var(--body); border-bottom: 0; }
body:not(.admin) .site-header .nav .has-sub .sub a:hover, body:not(.admin) .site-header .nav .has-sub .sub a.active { color: var(--cocoa); }
body:not(.admin) .site-header .mobile-nav { background: rgba(83,54,51,.97); border-top: 1px solid rgba(255,255,255,.15); }
body:not(.admin) .site-header .mobile-nav a { color: #fff; border-bottom-color: rgba(255,255,255,.12); }
body:not(.admin) .site-header .mobile-nav .btn-outline { border-color: rgba(255,255,255,.6); color: #fff; }
.hero-scroll .hero-sticky { padding-top: 0; }
.page-band { padding-top: 130px; }
