/* Well Done B2B — modern design system (design-system.md alapján) */
:root {
  --brand-blue: #0693E3;
  --brand-blue-link: #3498DB;
  --brand-blue-accent: #1E73BE;
  --brand-blue-dark: #0057A3;
  --brand-blue-strong: #0366D6;

  --bg-white: #FFFFFF;
  --bg-sky: #EDF8FF;
  --bg-sky-2: #F4FBFF;
  --base: #F0F0F0;
  --base-2: #F6F9FC;
  --surface-muted: #F9F9F9;

  --text-body: #7C8A97;
  --text-strong: #1F2A33;
  --text-black: #000000;

  --cat-orange: #FF8A00;
  --cat-pink: #E91E8C;
  --cat-purple: #7A2A8C;
  --cat-yellow: #FCB900;
  --cat-green: #008000;

  --ok: #1f9d57;
  --warn: #E07B00;
  --err: #D7263D;

  --border: #E6ECF1;
  --border-soft: #EEF2F6;

  --font-base: "Open Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --radius: 14px;
  --radius-sm: 10px;
  --radius-pill: 999px;
  --shadow-xs: 0 1px 2px rgba(16,42,67,.06);
  --shadow-sm: 0 1px 3px rgba(16,42,67,.07), 0 1px 2px rgba(16,42,67,.04);
  --shadow-md: 0 8px 24px rgba(16,42,67,.10);
  --shadow-lg: 0 18px 50px rgba(16,42,67,.16);
  --ring: 0 0 0 3px rgba(6,147,227,.16);
  --transition: .16s ease;
  --topbar-h: 62px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: var(--font-base);
  font-size: 15px;
  line-height: 1.55;
  color: var(--text-strong);
  background: var(--base-2);
  -webkit-font-smoothing: antialiased;
}
a { color: var(--brand-blue-link); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--brand-blue-strong); text-decoration: none; }

h1, h2 { color: var(--brand-blue); font-weight: 300; letter-spacing: 2.5px; text-transform: uppercase; margin: 0 0 14px; }
h2 { font-size: 28px; }
h3 { color: var(--text-strong); font-weight: 600; }
code { background: var(--base-2); padding: 1px 6px; border-radius: 6px; font-size: 13px; }

/* ===== Admin felső sáv (régi .topbar — _AdminLayout) ===== */
.topbar {
  background: linear-gradient(180deg, var(--bg-sky-2), var(--bg-sky));
  border-bottom: 1px solid #dceefb; padding: 12px 24px;
  display: flex; align-items: center; gap: 20px;
}
.topbar .brand { font-size: 22px; font-weight: 700; color: var(--brand-blue); letter-spacing: 0; text-transform: none; }
.topbar .brand .check { color: var(--err); }
.topbar nav { display: flex; gap: 6px; flex-wrap: wrap; }
.topbar nav a { color: var(--text-strong); font-size: 13.5px; padding: 6px 10px; border-radius: 8px; }
.topbar nav a:hover { background: rgba(255,255,255,.6); }
.topbar .spacer { flex: 1; }
.topbar .user { font-size: 13px; color: var(--text-body); }

.lang-switch { display: inline-flex; gap: 3px; font-size: 12px; background: rgba(255,255,255,.6); padding: 3px; border-radius: var(--radius-pill); }
.lang-switch a { padding: 3px 9px; border-radius: var(--radius-pill); color: var(--text-body); font-weight: 600; }
.lang-switch a.is-on { background: var(--brand-blue-link); color: #fff; }

/* ===== App shell: teljes szélességű felső sáv + bal menüsáv ===== */
.app { display: grid; grid-template-columns: 256px 1fr; }
.sidebar { background: #fff; border-right: 1px solid var(--border); display: flex; flex-direction: column; position: sticky; top: var(--topbar-h); height: calc(100vh - var(--topbar-h)); }
.side-nav { flex: 1; overflow-y: auto; padding: 10px 14px; }
.side-group { font-size: 10.5px; letter-spacing: 1.4px; text-transform: uppercase; color: var(--text-body); padding: 16px 10px 6px; font-weight: 700; }
.side-nav a {
  display: flex; align-items: center; gap: 12px; width: 100%; padding: 10px 12px; margin-bottom: 3px; border-radius: var(--radius-sm);
  color: var(--text-strong); font-size: 14px; text-decoration: none; background: none; border: 0; cursor: pointer;
  font-family: inherit; text-align: left; transition: background var(--transition), color var(--transition); position: relative;
}
.side-nav a:hover { background: var(--bg-sky); color: var(--brand-blue-dark); }
/* Fix kategória- és akció-almenük a vevői navigációban (2026-07-21) */
.side-nav a.side-sub { padding: 4px 14px 4px 40px; font-size: 12.5px; }
.side-nav a.is-active { background: var(--bg-sky); color: var(--brand-blue-dark); font-weight: 700; box-shadow: inset 3px 0 0 var(--brand-blue); }
.side-nav a.is-active .ic { color: var(--brand-blue); }
.side-nav .ic { width: 26px; height: 26px; display: grid; place-items: center; border-radius: 8px; background: var(--bg-sky); color: var(--brand-blue-link); font-size: 13px; flex: none; }
.side-nav a.is-active .ic { background: #fff; }
.side-badge { margin-left: auto; background: linear-gradient(180deg, var(--brand-blue-link), var(--brand-blue-strong)); color: #fff; border-radius: var(--radius-pill); font-size: 11px; padding: 2px 9px; font-weight: 700; }
.sidebar-user { display: flex; align-items: center; gap: 11px; padding: 14px 18px; border-top: 1px solid var(--border-soft); }
.avatar { width: 40px; height: 40px; border-radius: var(--radius-pill); background: linear-gradient(180deg, var(--brand-blue), var(--brand-blue-dark)); color: #fff; display: grid; place-items: center; font-weight: 700; font-size: 14px; flex: none; }
.sidebar-user-meta { min-width: 0; }
.sidebar-user-meta .name { font-size: 13px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sidebar-user-meta .company { font-size: 12px; color: var(--text-body); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.main { display: flex; flex-direction: column; min-width: 0; }

/* Teljes szélességű felső sáv */
.app-topbar {
  position: sticky; top: 0; z-index: 30; height: var(--topbar-h);
  display: flex; align-items: center; gap: 16px; padding: 0 22px;
  background: linear-gradient(180deg, var(--bg-sky-2), var(--bg-sky));
  border-bottom: 1px solid #dceefb; box-shadow: 0 2px 10px rgba(6,147,227,.05);
}
.app-topbar .spacer { flex: 1; }
.topbar-brand { display: flex; align-items: center; gap: 10px; flex: none; text-decoration: none; padding-right: 14px; }
.topbar-brand img { height: 34px; width: auto; }
.topbar-brand-sub { font-size: 10px; letter-spacing: 1.6px; text-transform: uppercase; color: var(--text-body); font-weight: 600; }
.hamburger { display: inline-flex; align-items: center; justify-content: center; width: 34px; height: 34px; background: none; border: 0; font-size: 20px; cursor: pointer; color: var(--brand-blue-dark); border-radius: 8px; transition: background var(--transition); }
.hamburger:hover { background: rgba(255,255,255,.6); }
.app-title { font-size: 14px; font-weight: 700; color: var(--brand-blue-dark); text-transform: uppercase; letter-spacing: 2px; }
.topbar-search { position: relative; flex: 0 1 400px; margin: 0; }
.topbar-search form { margin: 0; }
.topbar-search input {
  width: 100%; padding: 9px 14px 9px 38px; border-radius: var(--radius-pill); border: 1px solid #cfe4f5; background: #fff
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%237C8A97' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cline x1='21' y1='21' x2='16.65' y2='16.65'/%3E%3C/svg%3E") 13px center no-repeat;
}

/* Autocomplete legördülő */
.search-results { position: absolute; top: calc(100% + 8px); left: 0; right: 0; background: #fff; border: 1px solid var(--border); border-radius: var(--radius-sm); box-shadow: var(--shadow-md); max-height: 460px; overflow-y: auto; display: none; z-index: 60; overflow: hidden; }
.search-results.show { display: block; }
.sr-item { display: flex; align-items: center; gap: 12px; padding: 9px 13px; border-bottom: 1px solid var(--border-soft); color: var(--text-strong); }
.sr-item:last-child { border-bottom: 0; }
.sr-item:hover { background: var(--bg-sky); }
.sr-thumb { width: 40px; height: 40px; border-radius: var(--radius-sm); flex: none; display: grid; place-items: center; color: #fff; font-weight: 800; font-size: 16px; box-shadow: var(--shadow-xs); }
.sr-info { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.sr-name { font-size: 13px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sr-meta { font-size: 11px; color: var(--text-body); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sr-price { font-size: 13.5px; font-weight: 800; color: var(--brand-blue-dark); white-space: nowrap; }
.sr-empty { padding: 14px; color: var(--text-body); font-size: 13px; }

.contact-card { text-align: right; line-height: 1.25; }
.contact-label { font-size: 9.5px; letter-spacing: 1.2px; text-transform: uppercase; color: var(--text-body); font-weight: 700; }
.contact-name { font-size: 13px; font-weight: 700; }
.contact-meta { font-size: 11px; color: var(--text-body); }

/* Kijelentkezés a fejléc jobb felső sarkában (vevői + admin layout) */
.topbar-logout { margin: 0; flex: none; }
.topbar-logout button {
  display: inline-flex; align-items: center; gap: 7px; padding: 7px 14px;
  border: 1px solid #cfe4f5; border-radius: 8px;
  background: rgba(255,255,255,.6); color: var(--text-body);
  font-size: 12.5px; font-weight: 600; cursor: pointer; white-space: nowrap;
  transition: background var(--transition);
}
.topbar-logout button:hover { background: #fff; color: var(--brand-blue-dark); }

.content { padding: 28px; flex: 1; width: 100%; min-width: 0; }
.content-footer { margin-top: 44px; padding-top: 18px; border-top: 1px solid var(--border-soft); color: var(--text-body); font-size: 12px; }
.sidebar-backdrop { display: none; }

/* Összecsukott bal menüsáv (asztali nézet, hamburger) */
@media (min-width: 901px) {
  .app.collapsed { grid-template-columns: 1fr; }
  .app.collapsed > .sidebar { display: none; }
}

@media (max-width: 900px) {
  .app { grid-template-columns: 1fr; }
  .sidebar { position: fixed; left: 0; top: var(--topbar-h); width: 256px; height: calc(100vh - var(--topbar-h)); transform: translateX(-100%); transition: transform .2s; z-index: 20; box-shadow: var(--shadow-lg); }
  .sidebar.open { transform: translateX(0); }
  .hamburger { display: block; }
  .sidebar-backdrop.show { display: block; position: fixed; left: 0; right: 0; bottom: 0; top: var(--topbar-h); background: rgba(16,42,67,.34); z-index: 15; }
  .contact-card, .app-title { display: none; }
  .topbar-search { flex: 1; }
  .content { padding: 18px; }
}

/* Layout containers (admin) — teljes szélesség */
.container { width: 100%; margin: 0; padding: 28px; }

/* Footer (admin) */
.footer { background: var(--brand-blue-dark); color: #fff; padding: 22px 24px; font-size: 13px; margin-top: 44px; }
.footer a { color: #cfe6ff; }

/* Cards */
.card { background: var(--bg-white); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow-sm); padding: 22px; margin-bottom: 18px; }
.card-title { font-size: 12px; text-transform: uppercase; letter-spacing: 1.4px; color: var(--text-body); margin: 0 0 16px; font-weight: 700; padding-bottom: 10px; border-bottom: 1px solid var(--border-soft); position: relative; }
.card-title::after { content: ""; position: absolute; left: 0; bottom: -1px; width: 38px; height: 2px; background: var(--brand-blue); border-radius: 2px; }

/* Tudásbázis: morzsasor + mappa-kártyák */
.kb-breadcrumb { margin-bottom: 14px; font-size: 13.5px; color: var(--text-body); }
.kb-breadcrumb .sep { margin: 0 6px; color: var(--border); }
.kb-folders { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 18px; }
.kb-folder { display: flex; align-items: center; gap: 10px; background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 14px 18px; min-width: 180px; color: var(--text-strong); box-shadow: var(--shadow-xs); transition: box-shadow var(--transition), transform var(--transition); }
.kb-folder:hover { box-shadow: var(--shadow-md); transform: translateY(-1px); color: var(--brand-blue-dark); }
.kb-folder .ic { font-size: 22px; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 0; border-radius: var(--radius-sm);
  padding: 10px 20px; font-size: 13.5px; font-weight: 700; cursor: pointer; letter-spacing: .4px;
  background: linear-gradient(180deg, var(--brand-blue-link), var(--brand-blue-strong)); color: #fff;
  text-transform: uppercase; box-shadow: var(--shadow-xs); transition: transform var(--transition), box-shadow var(--transition), background var(--transition);
}
.btn:hover { color: #fff; transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn:active { transform: translateY(0); }
.btn:disabled { opacity: .55; cursor: not-allowed; transform: none; box-shadow: none; }
.btn-secondary { background: #fff; color: var(--text-strong); border: 1px solid var(--border); box-shadow: none; }
.btn-secondary:hover { background: var(--bg-sky); color: var(--brand-blue-dark); }
.btn-danger { background: #fff; color: #b42318; border: 1px solid #f1b4ae; box-shadow: none; }
.btn-danger:hover { background: #b42318; color: #fff; border-color: #b42318; }

/* Vissza-gomb — finom pill link a részletező oldalak tetején (azonos az admin felülettel). */
.btn-back {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 7px 15px 7px 12px;
  font-size: 13px; font-weight: 600; letter-spacing: .2px;
  color: var(--text-body); background: #fff;
  border: 1px solid var(--border); border-radius: var(--radius-pill);
  box-shadow: var(--shadow-xs);
  transition: color var(--transition), border-color var(--transition), background var(--transition), box-shadow var(--transition);
}
.btn-back:hover {
  color: var(--brand-blue-dark); background: var(--bg-sky);
  border-color: var(--brand-blue-link); box-shadow: var(--shadow-sm);
}
.btn-back .btn-back-ic { font-size: 16px; line-height: 1; transition: transform var(--transition); }
.btn-back:hover .btn-back-ic { transform: translateX(-2px); }
/* A vissza-link köré tekert <p> ne adjon dupla margót. */
p:has(> .btn-back) { margin: 0 0 14px; }
.btn-block { display: flex; width: 100%; }

/* Forms */
.form-group { margin-bottom: 16px; }
label { display: block; font-size: 13px; font-weight: 600; margin-bottom: 6px; color: var(--text-strong); }
input[type=text], input[type=email], input[type=password], input[type=number], input[type=date], input[type=search], select, textarea {
  width: 100%; padding: 10px 13px; border: 1px solid var(--border); border-radius: var(--radius-sm); font-family: inherit; font-size: 14px; background: #fff;
  transition: border-color var(--transition), box-shadow var(--transition);
}
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--brand-blue); box-shadow: var(--ring); }
.field-validation-error, .text-danger { color: var(--err); font-size: 12px; }
.validation-summary-errors { color: var(--err); font-size: 13px; margin-bottom: 12px; }
.checkbox-row { display: flex; align-items: center; gap: 9px; }
.checkbox-row input { width: auto; }
.checkbox-row label { margin: 0; }

/* Tables */
table.grid { width: 100%; border-collapse: collapse; background: #fff; }
table.grid th, table.grid td { padding: 11px 14px; text-align: left; font-size: 13.5px; border-bottom: 1px solid var(--border-soft); }
table.grid th { background: var(--bg-sky-2); font-weight: 700; color: var(--text-body); text-transform: uppercase; font-size: 11px; letter-spacing: .6px; }
table.grid tbody tr { transition: background var(--transition); }
table.grid tbody tr:hover { background: #fbfdff; }
table.grid tbody tr:last-child td { border-bottom: 0; }

/* Auth */
.auth-wrap { min-height: 100vh; display: grid; place-items: center; padding: 24px;
  background: radial-gradient(1200px 500px at 50% -10%, #d9f0ff, transparent), linear-gradient(180deg, var(--bg-sky), #fff); }
.auth-card { width: 400px; max-width: 92vw; background: #fff; border-radius: 20px; box-shadow: var(--shadow-lg); padding: 36px 34px; }
.auth-logo { text-align: center; margin-bottom: 10px; }
.auth-logo img { height: 78px; width: auto; }
.auth-card .slogan { text-align: center; color: var(--text-body); font-size: 13px; margin-bottom: 24px; }

/* Badges */
.badge { display: inline-flex; align-items: center; gap: 6px; padding: 3px 11px; border-radius: var(--radius-pill); font-size: 12px; font-weight: 700; }
.badge::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; opacity: .85; }
.badge-ok { background: #e4f6ec; color: var(--ok); }
.badge-low { background: #fff1df; color: var(--warn); }
.badge-out { background: #fde8ec; color: var(--err); }

/* Catalog */
.catalog-head { display: flex; align-items: baseline; gap: 16px; flex-wrap: wrap; margin-bottom: 18px; }
.filters { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-bottom: 18px; background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 14px 16px; box-shadow: var(--shadow-sm); }
.filters input, .filters select { width: auto; }
.filters-search { flex: 1 1 260px; min-width: 200px; }
.filters select { min-width: 158px; }
.filters-actions { margin-left: auto; display: flex; gap: 10px; }
.filters-checkbox { display: flex; align-items: center; gap: 6px; font-size: 14px; white-space: nowrap; }
.filters-checkbox input { width: auto; }
.prod-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(248px, 1fr)); gap: 18px; }
.prod-card { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow-sm); display: flex; flex-direction: column; overflow: hidden; transition: transform var(--transition), box-shadow var(--transition); }
.prod-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
/* Akciós termék kiemelése — ügyfélkérés (2026-07-21): piros keret */
.prod-card-promo { border: 2px solid #D32F2F; }

/* Sticky rendelési szalag a termékadatlapon */
.buy-sticky { position: fixed; top: 0; left: 0; right: 0; z-index: 60; background: #fff; border-bottom: 1px solid var(--border); box-shadow: var(--shadow-md); padding: 8px 16px; }
.buy-sticky-inner { display: flex; align-items: center; gap: 12px; max-width: 1100px; margin: 0 auto; }
.buy-sticky-name { font-weight: 700; color: var(--text-strong); flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.buy-sticky-price { font-weight: 700; white-space: nowrap; }
.buy-sticky input { width: 80px; }
.prod-thumb { position: relative; display: grid; place-items: center; height: 132px; text-decoration: none;
  background: linear-gradient(135deg, color-mix(in srgb, var(--accent) 16%, #fff), color-mix(in srgb, var(--accent) 6%, #fff)); }
.prod-thumb-mark { font-size: 42px; font-weight: 800; color: color-mix(in srgb, var(--accent) 78%, #444); opacity: .55; }
.prod-thumb-img { max-height: 116px; max-width: 88%; width: auto; height: auto; object-fit: contain; }
.prod-thumb .promo-badge { position: absolute; top: 10px; right: 10px; }
.prod-thumb .novelty-badge { position: absolute; top: 10px; left: 10px; }
.novelty-badge { color: #fff; background: #0693E3; padding: 3px 9px; border-radius: var(--radius-pill); font-size: 12px; font-weight: 800; box-shadow: var(--shadow-xs); }
.prod-card-body { padding: 15px 16px 16px; display: flex; flex-direction: column; gap: 7px; flex: 1; }
.prod-card .prod-name { font-weight: 700; color: var(--text-strong); font-size: 15px; line-height: 1.3; }
.prod-card .prod-sku, .prod-card .prod-brand { font-size: 12px; }
.prod-card-mid { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin: 2px 0; }
.promo-badge { color: #fff; background: #D32F2F; padding: 3px 9px; border-radius: var(--radius-pill); font-size: 12px; font-weight: 800; box-shadow: var(--shadow-xs); }
.prod-card-price { margin-top: auto; padding-top: 4px; }
.price-net { font-size: 20px; font-weight: 800; color: var(--brand-blue-dark); }
.price-old { text-decoration: line-through; color: var(--text-body); margin-right: 6px; font-size: 14px; }
.price-unit { font-size: 12px; }
.price-gross, .price-pack { font-size: 12px; }
/* Autocomplete keresési javaslatok (2026-07-21) */
.filters-search-wrap { position: relative; flex: 1; min-width: 220px; }
.filters-search-wrap .filters-search { width: 100%; }
.search-suggest { position: absolute; top: calc(100% + 4px); left: 0; right: 0; background: #fff; border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow-md); z-index: 50; max-height: 380px; overflow: auto; }
.search-suggest-item { display: flex; gap: 8px; align-items: center; padding: 9px 12px; cursor: pointer; color: inherit; }
.search-suggest-item:hover { background: var(--bg-sky); }
.search-suggest-item .suggest-name { flex: 1; min-width: 0; }

/* Két sorban: Részletek külön, alatta mennyiség + Kosárba — a nowrap gomb keskeny kártyán túlcsordult. */
.prod-card-foot { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; align-items: center; }
.prod-card-foot .btn-secondary { flex: 1 1 100%; }
.prod-card-foot .card-qty { width: 64px; flex: 0 0 auto; }
.prod-card-foot .card-add { flex: 1 1 auto; min-width: 0; white-space: nowrap; padding-left: 14px; padding-right: 14px; }

/* Product detail */
.detail-grid { display: grid; grid-template-columns: 2fr 1fr; gap: 18px; align-items: start; }
.detail-meta { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 12px; }
.chip { background: var(--bg-sky); border: 1px solid #d9ecf9; border-radius: var(--radius-pill); padding: 5px 13px; font-size: 12px; color: var(--brand-blue-dark); font-weight: 600; }
.detail-desc { margin-top: 14px; }
.detail-buy { position: sticky; top: calc(var(--topbar-h) + 16px); }
.buy-form { margin-top: 14px; }
@media (max-width: 800px) { .detail-grid { grid-template-columns: 1fr; } }

/* Termékoldal — galéria + rendezett elrendezés */
.product-detail { display: grid; grid-template-columns: minmax(300px, 400px) 1fr; gap: 24px; align-items: start; }
.product-gallery { position: sticky; top: calc(var(--topbar-h) + 16px); }
.gallery-main { position: relative; aspect-ratio: 1 / 1; border-radius: var(--radius); border: 1px solid var(--border); display: grid; place-items: center; overflow: hidden; box-shadow: var(--shadow-sm);
  background: linear-gradient(135deg, color-mix(in srgb, var(--accent) 18%, #fff), color-mix(in srgb, var(--accent) 6%, #fff)); }
.gallery-main-mark { font-size: 120px; font-weight: 800; color: color-mix(in srgb, var(--accent) 70%, #3a3a3a); opacity: .5; }
.gallery-main-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; padding: 8%; box-sizing: border-box; }
.gallery-promo { position: absolute; top: 14px; right: 14px; }
.gallery-thumbs { display: flex; gap: 10px; margin-top: 12px; }
.gallery-thumb { position: relative; width: 66px; height: 66px; border-radius: 10px; border: 2px solid var(--border); cursor: pointer; display: grid; place-items: center; padding: 0; overflow: hidden;
  background: linear-gradient(135deg, color-mix(in srgb, var(--accent) 16%, #fff), color-mix(in srgb, var(--accent) 5%, #fff)); transition: border-color var(--transition); }
.gallery-thumb span { font-size: 24px; font-weight: 800; color: color-mix(in srgb, var(--accent) 70%, #3a3a3a); opacity: .5; }
.gallery-thumb-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; padding: 12%; box-sizing: border-box; }
.gallery-thumb:hover { border-color: #bcd6ea; }
.gallery-thumb.is-active { border-color: var(--brand-blue); }
.gallery-note { font-size: 11px; margin-top: 10px; }

.product-main { min-width: 0; }
.detail-status { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin: 16px 0; }
.detail-price { margin: 16px 0; padding: 14px 0; border-top: 1px solid var(--border-soft); border-bottom: 1px solid var(--border-soft); }
.detail-price-row { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.detail-price .price-net { font-size: 28px; }
.buy-row { display: flex; gap: 12px; align-items: flex-end; flex-wrap: wrap; }
.detail-desc { line-height: 1.6; }

/* --- Videók / Dokumentumok tabok --- */
.media-tabs { padding-top: 6px; }
.tab-bar { display: flex; gap: 4px; border-bottom: 1px solid var(--border); margin: -4px 0 18px; }
.tab-btn { appearance: none; background: none; border: 0; cursor: pointer; font: inherit; font-weight: 600;
  color: var(--text-body); padding: 11px 16px 13px; display: inline-flex; align-items: center; gap: 8px;
  border-bottom: 2px solid transparent; margin-bottom: -1px; transition: color var(--transition), border-color var(--transition); }
.tab-btn:hover { color: var(--text-strong); }
.tab-btn.is-active { color: var(--brand-blue); border-bottom-color: var(--brand-blue); }
.tab-btn .tab-ic { font-size: 13px; opacity: .8; }
.tab-count { font-size: 11px; font-weight: 700; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px;
  display: inline-flex; align-items: center; justify-content: center; background: var(--border-soft); color: var(--text-body); }
.tab-btn.is-active .tab-count { background: color-mix(in srgb, var(--brand-blue) 16%, #fff); color: var(--brand-blue); }
.tab-panel { display: none; animation: tab-fade .18s ease; }
.tab-panel.is-active { display: block; }
@keyframes tab-fade { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }

.video-item + .video-item { margin-top: 18px; }
.video-title { font-size: 13px; font-weight: 600; color: var(--text-body); margin-bottom: 8px; }
.video-frame { position: relative; width: 100%; padding-top: 56.25%; border-radius: 12px; overflow: hidden; box-shadow: var(--shadow-sm); }
.video-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

/* --- Korszerű dokumentum-csempék --- */
.doc-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 12px; }
.doc-tile { display: flex; align-items: center; gap: 13px; padding: 13px 14px; text-decoration: none;
  border: 1px solid var(--border); border-radius: 14px; background: #fff;
  transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition); }
.doc-tile:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); border-color: color-mix(in srgb, var(--brand-blue) 35%, var(--border)); }
.doc-ico { flex: 0 0 auto; width: 44px; height: 44px; border-radius: 11px; display: grid; place-items: center;
  font-size: 11px; font-weight: 800; letter-spacing: .3px; color: #fff; }
.doc-ico--pdf { background: linear-gradient(135deg, #e53935, #c62828); }
.doc-ico--img { background: linear-gradient(135deg, #1aa85a, #0c7a3e); }
.doc-ico--doc { background: linear-gradient(135deg, #1e88e5, #1565c0); }
.doc-ico--xls { background: linear-gradient(135deg, #2e9e5b, #1b7a40); }
.doc-ico--zip { background: linear-gradient(135deg, #8e7cc3, #6a4fa0); }
.doc-ico--file { background: linear-gradient(135deg, #90a4ae, #607d8b); }
.doc-tile-body { min-width: 0; display: flex; flex-direction: column; gap: 2px; flex: 1; }
.doc-tile-name { font-weight: 600; color: var(--text-strong); font-size: 14px; line-height: 1.3;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.doc-tile-meta { font-size: 11.5px; color: var(--text-body); text-transform: uppercase; letter-spacing: .4px; }
.doc-dl { flex: 0 0 auto; width: 30px; height: 30px; border-radius: 8px; display: grid; place-items: center;
  color: var(--text-body); background: var(--border-soft); font-size: 15px; transition: background var(--transition), color var(--transition); }
.doc-tile:hover .doc-dl { background: var(--brand-blue); color: #fff; }
.doc-empty { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 28px 0; text-align: center; }
.doc-empty-ic { font-size: 34px; opacity: .35; }

@media (max-width: 820px) {
  .product-detail { grid-template-columns: 1fr; }
  .product-gallery { position: static; }
  .gallery-main { aspect-ratio: 16 / 10; }
  .gallery-main-mark { font-size: 84px; }
}

/* KPI (admin dashboard) */
.kpi-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 16px; }
.kpi { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 18px 20px; box-shadow: var(--shadow-sm); }
.kpi .label { font-size: 11px; text-transform: uppercase; letter-spacing: 1px; color: var(--text-body); font-weight: 700; }
.kpi .value { font-size: 30px; font-weight: 800; color: var(--brand-blue-dark); margin-top: 6px; }

/* Order meta (admin order detail) */
.order-meta { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px 24px; margin: 0; }
.order-meta > div { display: flex; flex-direction: column; gap: 3px; }
.order-meta dt { font-size: 11px; text-transform: uppercase; letter-spacing: 1px; color: var(--text-body); font-weight: 700; }
.order-meta dd { margin: 0; font-size: 15px; color: var(--brand-blue-dark); font-weight: 600; }

/* Pager */
.pager { display: flex; gap: 6px; margin-top: 18px; }
.pager a { padding: 7px 12px; border: 1px solid var(--border); border-radius: var(--radius-sm); background: #fff; }
.pager a.is-on { background: var(--brand-blue-link); color: #fff; border-color: var(--brand-blue-link); }

/* Cart */
.cart-group-foot { display: flex; gap: 18px; align-items: center; justify-content: space-between; flex-wrap: wrap; margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--border-soft); }
.moq-progress { height: 8px; width: 220px; max-width: 100%; margin-bottom: 8px; background: var(--base); border-radius: var(--radius-pill); overflow: hidden; }
.moq-progress-fill { height: 100%; border-radius: var(--radius-pill); transition: width .35s ease; }
.moq-progress-fill.is-met { background: var(--ok); }
.moq-progress-fill.is-low { background: var(--warn); }
.cart-total { display: flex; gap: 18px; align-items: center; justify-content: space-between; flex-wrap: wrap; }
.cart-foot-actions { display: flex; gap: 10px; align-items: center; }

/* --- Pénztár: lépcsős elrendezés + rögzített összesítő --- */
.checkout { display: grid; grid-template-columns: 1fr 340px; gap: 20px; align-items: start; }
.checkout-main { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.checkout-summary { position: sticky; top: calc(var(--topbar-h) + 16px); }
@media (max-width: 860px) { .checkout { grid-template-columns: 1fr; } .checkout-summary { position: static; } }

.step-card { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow-xs); padding: 18px 20px; }
.step-head { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 15px; color: var(--text-strong); margin-bottom: 14px; }
.step-num { display: inline-flex; align-items: center; justify-content: center; width: 24px; height: 24px; border-radius: 50%; background: var(--brand-blue-link); color: #fff; font-size: 13px; font-weight: 700; }
.step-sub { font-weight: 400; font-size: 13px; color: var(--text-body); }

/* Átvétel-mód opciók */
.ship-opt { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border: 1px solid var(--border); border-radius: var(--radius-sm); margin-bottom: 10px; cursor: pointer; transition: border-color var(--transition), background var(--transition); }
.ship-opt:hover { border-color: var(--brand-blue-link); background: var(--bg-sky); }
.ship-opt:has(input:checked) { border-color: var(--brand-blue-link); background: var(--bg-sky); box-shadow: inset 0 0 0 1px var(--brand-blue-link); }
.ship-opt input { margin: 0; }
.ship-opt-body { display: flex; flex-direction: column; gap: 2px; flex: 1; }
.ship-opt-title { font-weight: 600; color: var(--text-strong); }
.ship-opt-sub { font-size: 12.5px; color: var(--text-body); }
.ship-opt-price { font-weight: 700; color: var(--brand-blue-dark); white-space: nowrap; }
.ship-address { margin-top: 6px; }
.ship-address label { display: block; font-size: 13px; margin-bottom: 4px; }
.ship-address select { width: 100%; }

/* Összesítő lista */
.sum-list { margin: 0 0 12px; display: flex; flex-direction: column; gap: 8px; }
.sum-list > div { display: flex; justify-content: space-between; gap: 12px; font-size: 14px; }
.sum-list dt { color: var(--text-body); margin: 0; }
.sum-list dd { margin: 0; font-weight: 600; color: var(--text-strong); }
.sum-total { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding-top: 12px; margin-bottom: 14px; border-top: 1px solid var(--border-soft); font-weight: 800; }
.sum-total > span:last-child { font-size: 22px; color: var(--text-strong); }
.sum-hint { font-size: 12.5px; margin: 10px 0 0; text-align: center; }

.muted { color: var(--text-body); }
.alert { padding: 12px 16px; border-radius: var(--radius-sm); margin-bottom: 16px; font-size: 14px; border: 1px solid transparent; }
.alert-info { background: var(--bg-sky); color: var(--brand-blue-dark); border-color: #d4ecfb; }
.alert-warn { background: #fff5e8; color: #8a5300; border-color: #ffe2bd; }

/* Megszemélyesítés-sáv (admin/értékesítő „belépés vevőként") */
.impersonation-bar { display: flex; gap: 16px; align-items: center; justify-content: space-between; flex-wrap: wrap;
  background: #8a2b00; color: #fff; padding: 10px 18px; font-size: 14px; box-shadow: var(--shadow-sm); }
.impersonation-text { line-height: 1.4; }
.impersonation-stop { border: 1px solid rgba(255,255,255,.7); background: rgba(255,255,255,.12); color: #fff;
  font-weight: 700; padding: 7px 14px; border-radius: var(--radius-sm); cursor: pointer; white-space: nowrap; }
.impersonation-stop:hover { background: #fff; color: #8a2b00; }

/* Toast notifications */
.toast-container { position: fixed; top: 16px; right: 16px; z-index: 1000;
  display: flex; flex-direction: column; gap: 10px; max-width: min(380px, calc(100vw - 32px)); }
.toast { display: flex; align-items: flex-start; gap: 10px; padding: 12px 14px; border-radius: var(--radius-sm);
  background: #fff; border: 1px solid var(--border); border-left: 4px solid var(--text-body);
  box-shadow: var(--shadow-md, 0 6px 24px rgba(31,42,51,.14)); font-size: 14px; color: var(--text-strong);
  animation: toast-in .22s ease-out; }
.toast.toast-hide { animation: toast-out .2s ease-in forwards; }
.toast-icon { flex: 0 0 auto; width: 18px; height: 18px; margin-top: 1px; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center; color: #fff; font-size: 12px; font-weight: 800; line-height: 1; }
.toast-icon::before { content: "ⓘ"; }
.toast-msg { flex: 1 1 auto; line-height: 1.4; }
.toast-close { flex: 0 0 auto; background: none; border: 0; cursor: pointer; font-size: 20px; line-height: 1;
  color: var(--text-body); padding: 0 2px; margin-left: 2px; }
.toast-close:hover { color: var(--text-strong); }

.toast-success { border-left-color: var(--ok); }
.toast-success .toast-icon { background: var(--ok); }
.toast-success .toast-icon::before { content: "✓"; }
.toast-error { border-left-color: var(--err); }
.toast-error .toast-icon { background: var(--err); }
.toast-error .toast-icon::before { content: "!"; }
.toast-warning { border-left-color: var(--warn); }
.toast-warning .toast-icon { background: var(--warn); }
.toast-warning .toast-icon::before { content: "!"; }
.toast-info { border-left-color: var(--brand-blue-link); }
.toast-info .toast-icon { background: var(--brand-blue-link); }

@keyframes toast-in { from { opacity: 0; transform: translateX(16px); } to { opacity: 1; transform: none; } }
@keyframes toast-out { from { opacity: 1; transform: none; } to { opacity: 0; transform: translateX(16px); } }

@media (max-width: 640px) {
  .toast-container { top: auto; bottom: 16px; left: 16px; right: 16px; max-width: none; }
}

/* ---- Átvételihely-választó popup (termékoldal kosárba-tétel) ---- */
.dest-modal-overlay { position: fixed; inset: 0; background: rgba(31, 42, 51, .45); display: flex; align-items: center; justify-content: center; z-index: 1100; }
.dest-modal-overlay[hidden] { display: none; }
.dest-modal { background: #fff; border-radius: 10px; padding: 20px; width: min(480px, calc(100vw - 32px)); box-shadow: 0 10px 40px rgba(0, 0, 0, .25); }
.dest-modal-title { color: var(--text-strong); font-weight: 600; font-size: 17px; margin-bottom: 12px; }
.dest-modal-options { display: flex; flex-direction: column; gap: 6px; max-height: 50vh; overflow-y: auto; }
.dest-option { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border: 1px solid var(--border); border-radius: 8px; cursor: pointer; color: var(--text-strong); }
.dest-option:hover { border-color: var(--brand-blue-link); background: var(--border-soft); }
.dest-option input { accent-color: var(--brand-blue-link); }
.dest-modal-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 16px; }

/* ---- Kosár gomb a felső sávban (nyelvváltó és kapcsolattartó között) ---- */
.topbar-cart { position: relative; display: inline-flex; align-items: center; justify-content: center; width: 38px; height: 38px; font-size: 19px; border-radius: 8px; text-decoration: none; flex: none; transition: background var(--transition); }
.topbar-cart:hover { background: rgba(255, 255, 255, .6); }
.topbar-cart.is-active { background: rgba(255, 255, 255, .75); }
.topbar-cart-badge { position: absolute; top: -3px; right: -5px; background: linear-gradient(180deg, var(--brand-blue-link), var(--brand-blue-strong)); color: #fff; border-radius: var(--radius-pill); font-size: 10px; font-weight: 700; padding: 1px 5px; min-width: 16px; text-align: center; line-height: 14px; }

/* ---- Űrlap-rács a vevői oldalon (az admin.css form-grid mintájával egyező) ---- */
.form-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 0 26px; align-items: start; }
.form-grid .col-full { grid-column: 1 / -1; }
.form-actions { grid-column: 1 / -1; display: flex; gap: 10px; margin-top: 8px; }

/* ---- Szabályzat-elfogadó felugró (első belépéskori kapu) ---- */
.policy-modal { width: min(560px, calc(100vw - 32px)); }
.policy-option { cursor: default; }
.policy-option a { flex: 1; font-weight: 600; }
.policy-option input[type="checkbox"] { width: 18px; height: 18px; accent-color: var(--brand-blue-link); cursor: pointer; flex: none; }
.policy-option input[type="checkbox"]:disabled { cursor: default; }

/* ===== Szerkesztett tartalom (tartalmi oldalak, hírek/blog, akciós oldalak) ===== */
.content-body img { max-width: 100%; height: auto; border-radius: 8px; }
.post-banner { display: block; width: 100%; max-height: 320px; object-fit: cover; border-radius: 10px; margin-bottom: 14px; }
.post-list-banner { display: block; width: 100%; max-height: 180px; object-fit: cover; border-radius: 8px; margin-bottom: 10px; }
