/*
 * lfabra-checkout.css
 * Кастомний дизайн чекауту для OpenCart 3
 * Підключається у cart.twig / checkout.twig через {{ 'catalog/view/theme/default/stylesheet/lfabra-checkout.css'|theme }}
 * Всі класи з префіксом .lf- щоб не конфліктувати з Bootstrap OC
 */

/* ═══════════════════════════════════════════════
   1. ТОКЕНИ
   ═══════════════════════════════════════════════ */
:root {
  --lf-bg:            #f5f5f5;
  --lf-surface:       #ffffff;
  --lf-border:        #e8e8e8;
  --lf-border-input:  #d4d4d4;

  --lf-text:          #1a1a1a;
  --lf-text-sec:      #6b6b6b;
  --lf-text-muted:    #9b9b9b;

  --lf-accent:        #f5a623;
  --lf-accent-h:      #e0941a;
  --lf-accent-light:  #fff4e0;
  --lf-accent-shadow: rgba(245,166,35,0.35);

  --lf-error:         #e53935;
  --lf-success:       #43a047;
  --lf-notice-bg:     #fdebd0;
  --lf-notice-text:   #a0522d;

  --lf-font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif;

  --lf-radius-sm:   6px;
  --lf-radius-md:   10px;
  --lf-radius-lg:   14px;
  --lf-radius-pill: 999px;

  --lf-shadow-card:  0 2px 12px rgba(0,0,0,0.07);
  --lf-shadow-focus: 0 0 0 3px rgba(245,166,35,0.22);

  --lf-t-fast: 150ms ease;
  --lf-t-base: 220ms ease;

  --lf-max-w: 960px;
}

/* ═══════════════════════════════════════════════
   2. БАЗОВІ ПЕРЕВИЗНАЧЕННЯ OC
   ═══════════════════════════════════════════════ */
#checkout-cart,
#checkout-checkout {
  background: var(--lf-bg);
  font-family: var(--lf-font);
  color: var(--lf-text);
  min-height: 60vh;
  padding-bottom: 60px;
}

/* Прибираємо Bootstrap breadcrumb у межах наших сторінок */
#checkout-cart .breadcrumb,
#checkout-checkout .breadcrumb {
  display: none !important;
}

/* Прибираємо стандартний контейнер */
#checkout-cart > .container,
#checkout-checkout > .container {
  max-width: var(--lf-max-w) !important;
  padding: 0 16px !important;
}

/* ═══════════════════════════════════════════════
   3. ОБГОРТКА
   ═══════════════════════════════════════════════ */
.lf-page-bg { background: var(--lf-bg); }

.lf-wrapper {
  max-width: var(--lf-max-w);
  margin: 0 auto;
  padding: 0 16px 60px;
}

/* ═══════════════════════════════════════════════
   4. BREADCRUMB
   ═══════════════════════════════════════════════ */
.lf-breadcrumb {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  padding: 20px 0 16px;
  font-size: 13px;
  color: var(--lf-text-sec);
}
.lf-breadcrumb__link { color: var(--lf-text-sec); transition: color var(--lf-t-fast); }
.lf-breadcrumb__link:hover { color: var(--lf-accent); text-decoration: none; }
.lf-breadcrumb__sep { color: var(--lf-text-muted); }
.lf-breadcrumb__current { color: var(--lf-text); font-weight: 500; }

/* ═══════════════════════════════════════════════
   5. АЛЕРТИ
   ═══════════════════════════════════════════════ */
.lf-alert {
  padding: 12px 16px;
  border-radius: var(--lf-radius-sm);
  font-size: 14px;
  margin-bottom: 16px;
}
.lf-alert--info    { background: #e8f4fd; color: #1565c0; border: 1px solid #b3d4fb; }
.lf-alert--success { background: #e8f5e9; color: #2e7d32; border: 1px solid #a5d6a7; }
.lf-alert--danger  { background: #fdecea; color: #b71c1c; border: 1px solid #ef9a9a; }

/* ═══════════════════════════════════════════════
   6. КАРТКИ ТОВАРІВ У КОШИКУ
   ═══════════════════════════════════════════════ */
.lf-cart-items {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 20px;
}

.lf-cart-item {
  background: var(--lf-surface);
  border-radius: var(--lf-radius-lg);
  box-shadow: var(--lf-shadow-card);
  padding: 20px 24px;
  display: grid;
  grid-template-columns: 72px 1fr auto auto auto auto auto;
  align-items: center;
  gap: 20px;
}

/* Image */
.lf-cart-item__image { width: 72px; height: 56px; flex-shrink: 0; }
.lf-cart-item__image a { display: block; width: 100%; height: 100%; }
.lf-cart-item__image img { width: 100%; height: 100%; object-fit: contain; border-radius: 4px; }

/* Info */
.lf-cart-item__info { min-width: 0; }
.lf-cart-item__name {
  display: block;
  font-size: 15px;
  font-weight: 500;
  color: var(--lf-text);
  line-height: 1.3;
  margin-bottom: 2px;
  text-decoration: none;
  transition: color var(--lf-t-fast);
}
.lf-cart-item__name:hover { color: var(--lf-accent); }
.lf-cart-item__no-stock { color: var(--lf-error); }
.lf-cart-item__model { font-size: 13px; color: var(--lf-text-muted); margin-top: 2px; margin-bottom: 0; }
.lf-cart-item__option { font-size: 13px; color: var(--lf-text-sec); }
.lf-cart-item__option span { color: var(--lf-text); }
.lf-cart-item__reward { font-size: 12px; color: var(--lf-accent); margin-top: 2px; }

/* Qty controls */
.lf-cart-item__qty {
  display: flex;
  align-items: center;
  border: 1.5px solid var(--lf-border-input);
  border-radius: var(--lf-radius-sm);
  overflow: hidden;
  flex-shrink: 0;
}
.lf-qty-btn {
  width: 32px; height: 34px;
  display: flex; align-items: center; justify-content: center;
  background: transparent;
  border: none;
  font-size: 16px;
  color: var(--lf-text-sec);
  cursor: pointer;
  transition: background var(--lf-t-fast), color var(--lf-t-fast);
  user-select: none;
  padding: 0;
  line-height: 1;
}
.lf-qty-btn:hover { background: var(--lf-bg); color: var(--lf-text); }
.lf-qty-value {
  width: 36px; height: 34px;
  text-align: center;
  border: none;
  border-left: 1.5px solid var(--lf-border-input);
  border-right: 1.5px solid var(--lf-border-input);
  font-size: 15px;
  font-weight: 600;
  color: var(--lf-text);
  background: transparent;
  box-shadow: none;
  outline: none;
  padding: 0;
}
.lf-qty-value:focus { outline: none; box-shadow: none; border-color: var(--lf-accent); }

/* Price */
.lf-cart-item__price-unit {
  font-size: 13px;
  color: var(--lf-text-sec);
  white-space: nowrap;
  flex-shrink: 0;
}
.lf-cart-item__price-total {
  font-size: 18px;
  font-weight: 700;
  color: var(--lf-text);
  white-space: nowrap;
  flex-shrink: 0;
  min-width: 50px;
  text-align: right;
}

/* Remove */
.lf-cart-item__remove {
  width: 28px; height: 28px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 50%;
  font-size: 20px;
  line-height: 1;
  color: var(--lf-text-muted);
  background: transparent;
  border: none;
  cursor: pointer;
  flex-shrink: 0;
  padding: 0;
  transition: color var(--lf-t-fast), background var(--lf-t-fast);
}
.lf-cart-item__remove:hover { color: var(--lf-error); background: #fef2f2; }

/* ═══════════════════════════════════════════════
   7. ПІДСУМОК КОШИКУ + КНОПКИ
   ═══════════════════════════════════════════════ */
.lf-cart-footer {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  flex-wrap: wrap;
  gap: 16px;
  padding: 8px 0 0;
}

.lf-cart-totals {
  background: var(--lf-surface);
  border-radius: var(--lf-radius-lg);
  box-shadow: var(--lf-shadow-card);
  padding: 20px 24px;
  min-width: 280px;
}

.lf-cart-total-line {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 6px 0;
  border-bottom: 1px solid var(--lf-border);
}
.lf-cart-total-line:last-child { border-bottom: none; }
.lf-cart-total-line--grand { padding-top: 10px; margin-top: 4px; }
.lf-cart-total-line--grand .lf-cart-total-line__label { font-weight: 700; font-size: 16px; }
.lf-cart-total-line--grand .lf-cart-total-line__value { font-weight: 700; font-size: 18px; color: var(--lf-accent); }
.lf-cart-total-line__label { font-size: 14px; color: var(--lf-text-sec); }
.lf-cart-total-line__value { font-size: 14px; font-weight: 500; color: var(--lf-text); }

.lf-cart-actions { display: flex; gap: 12px; align-items: center; }

/* ═══════════════════════════════════════════════
   8. КНОПКИ
   ═══════════════════════════════════════════════ */
.lf-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 44px;
  padding: 0 24px;
  border-radius: var(--lf-radius-pill);
  font-family: var(--lf-font);
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  border: none;
  text-decoration: none;
  transition: background var(--lf-t-base), box-shadow var(--lf-t-base), transform 80ms ease;
  white-space: nowrap;
}
.lf-btn--primary {
  background: var(--lf-accent);
  color: #fff;
  box-shadow: 0 4px 14px var(--lf-accent-shadow);
}
.lf-btn--primary:hover { background: var(--lf-accent-h); box-shadow: 0 6px 20px var(--lf-accent-shadow); color: #fff; text-decoration: none; }
.lf-btn--primary:active { transform: translateY(1px); }
.lf-btn--ghost {
  background: var(--lf-surface);
  color: var(--lf-text-sec);
  border: 1.5px solid var(--lf-border-input);
  box-shadow: var(--lf-shadow-card);
}
.lf-btn--ghost:hover { color: var(--lf-text); border-color: var(--lf-accent); text-decoration: none; }
.lf-btn--wide { width: 100%; height: 48px; font-size: 15px; }

/* OC button-register overrides */
input#button-register.lf-btn { font-family: var(--lf-font); }

/* ═══════════════════════════════════════════════
   9. ФОРМА РЕЄСТРАЦІЇ  (register.twig)
   ═══════════════════════════════════════════════ */
.lf-register-wrap {
  background: var(--lf-surface);
  border-radius: var(--lf-radius-lg);
  box-shadow: var(--lf-shadow-card);
  padding: 32px;
}

/* Customer type */
.lf-customer-type {
  display: flex;
  gap: 32px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}
.lf-radio-label {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  font-size: 15px;
  color: var(--lf-text-sec);
  user-select: none;
}
.lf-radio-label input[type="radio"] { position: absolute; opacity: 0; width: 0; height: 0; }
.lf-radio-custom {
  width: 18px; height: 18px;
  border-radius: 50%;
  border: 2px solid var(--lf-border-input);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  transition: border-color var(--lf-t-fast);
  position: relative;
}
.lf-radio-custom::after {
  content: '';
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--lf-accent);
  opacity: 0;
  transform: scale(0.5);
  transition: opacity var(--lf-t-fast), transform var(--lf-t-fast);
}
.lf-radio-label input:checked ~ .lf-radio-custom { border-color: var(--lf-accent); }
.lf-radio-label input:checked ~ .lf-radio-custom::after { opacity: 1; transform: scale(1); }
.lf-radio-label--active,
.lf-radio-label:has(input:checked) { color: var(--lf-text); font-weight: 500; }

/* 2-col form grid */
.lf-form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}
.lf-form-col { display: flex; flex-direction: column; gap: 0; }
.lf-form-col fieldset { border: none; padding: 0; margin: 0; }

/* Form rows */
.lf-form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 0;
}

.lf-form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 16px;
}
.lf-form-group:last-child { margin-bottom: 0; }

/* Labels */
.lf-form-label {
  font-size: 13px;
  font-weight: 500;
  color: var(--lf-text-sec);
  display: block;
}

/* Inputs */
.lf-form-input {
  width: 100%;
  height: 44px;
  padding: 0 16px;
  border: 1.5px solid var(--lf-border-input);
  border-radius: var(--lf-radius-sm);
  font-family: var(--lf-font);
  font-size: 15px;
  color: var(--lf-text);
  background: var(--lf-surface);
  box-shadow: none;
  transition: border-color var(--lf-t-fast), box-shadow var(--lf-t-fast);
  appearance: none;
}
.lf-form-input::placeholder { color: var(--lf-text-muted); }
.lf-form-input:focus { border-color: var(--lf-accent); box-shadow: var(--lf-shadow-focus); outline: none; }
.lf-form-textarea { height: auto; padding: 12px 16px; resize: vertical; }

/* Selects */
.lf-select-wrapper { position: relative; }
.lf-select-wrapper::after {
  content: '';
  pointer-events: none;
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  width: 0; height: 0;
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-top: 6px solid var(--lf-text-muted);
}
.lf-form-select {
  width: 100%;
  height: 44px;
  padding: 0 36px 0 16px;
  border: 1.5px solid var(--lf-border-input);
  border-radius: var(--lf-radius-sm);
  font-family: var(--lf-font);
  font-size: 15px;
  color: var(--lf-text-muted);
  background: var(--lf-surface);
  appearance: none;
  -webkit-appearance: none;
  cursor: pointer;
  box-shadow: none;
  transition: border-color var(--lf-t-fast), box-shadow var(--lf-t-fast);
}
.lf-form-select:focus { border-color: var(--lf-accent); box-shadow: var(--lf-shadow-focus); outline: none; color: var(--lf-text); }
.lf-form-select option { color: var(--lf-text); }

/* Error state */
.lf-form-group.has-error .lf-form-input,
.lf-form-group.has-error .lf-form-select { border-color: var(--lf-error); }
.lf-form-group .text-danger { font-size: 12px; color: var(--lf-error); margin-top: -4px; }

/* Fieldset password */
.lf-fieldset-password { margin-top: 20px; padding-top: 20px; border-top: 1.5px solid var(--lf-border); }

/* Extras (newsletter, shipping) */
.lf-form-extras {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1.5px solid var(--lf-border);
}

/* Checkbox */
.lf-checkbox-label {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  cursor: pointer;
  font-size: 14px;
  color: var(--lf-text-sec);
  user-select: none;
}
.lf-checkbox-label input[type="checkbox"] { position: absolute; opacity: 0; width: 0; height: 0; }
.lf-checkbox-custom {
  width: 17px; height: 17px;
  border: 1.5px solid var(--lf-border-input);
  border-radius: 4px;
  flex-shrink: 0;
  margin-top: 1px;
  display: flex; align-items: center; justify-content: center;
  transition: background var(--lf-t-fast), border-color var(--lf-t-fast);
  position: relative;
}
.lf-checkbox-custom::after {
  content: '';
  width: 5px; height: 9px;
  border: 2px solid #fff;
  border-top: none; border-left: none;
  transform: rotate(45deg) translateY(-1px);
  opacity: 0;
  transition: opacity var(--lf-t-fast);
}
.lf-checkbox-label input:checked ~ .lf-checkbox-custom { background: var(--lf-accent); border-color: var(--lf-accent); }
.lf-checkbox-label input:checked ~ .lf-checkbox-custom::after { opacity: 1; }

/* Agreement */
.lf-form-submit-row {
  margin-top: 24px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.lf-agreement-label {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  cursor: pointer;
  font-size: 13px;
  color: var(--lf-text-sec);
  user-select: none;
}
.lf-agreement-checkbox { position: absolute; opacity: 0; width: 0; height: 0; }
.lf-agreement-custom {
  width: 16px; height: 16px;
  border: 1.5px solid var(--lf-border-input);
  border-radius: 3px;
  flex-shrink: 0;
  margin-top: 1px;
  display: flex; align-items: center; justify-content: center;
  transition: background var(--lf-t-fast), border-color var(--lf-t-fast);
}
.lf-agreement-custom::after {
  content: '';
  width: 4px; height: 8px;
  border: 2px solid #fff;
  border-top: none; border-left: none;
  transform: rotate(45deg) translateY(-1px);
  opacity: 0;
  transition: opacity var(--lf-t-fast);
}
.lf-agreement-checkbox:checked ~ .lf-agreement-custom { background: var(--lf-accent); border-color: var(--lf-accent); }
.lf-agreement-checkbox:checked ~ .lf-agreement-custom::after { opacity: 1; }
.lf-agreement-text { line-height: 1.5; }
.lf-agreement-text a { color: var(--lf-accent); text-decoration: underline; }

/* ═══════════════════════════════════════════════
   10. CHECKOUT ACCORDION  (checkout.twig panels)
   ═══════════════════════════════════════════════ */
#checkout-checkout .panel-default {
  border: none;
  background: var(--lf-surface);
  border-radius: var(--lf-radius-lg) !important;
  box-shadow: var(--lf-shadow-card);
  margin-bottom: 12px !important;
}
#checkout-checkout .panel-heading {
  background: transparent !important;
  border: none !important;
  padding: 20px 24px !important;
  border-radius: var(--lf-radius-lg) !important;
}
#checkout-checkout .panel-title {
  font-family: var(--lf-font);
  font-size: 15px;
  font-weight: 600;
  color: var(--lf-text);
}
#checkout-checkout .panel-title a {
  color: var(--lf-text);
  text-decoration: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
#checkout-checkout .panel-title a:hover { color: var(--lf-accent); }
#checkout-checkout .panel-title .fa { color: var(--lf-accent); }
#checkout-checkout .panel-body { padding: 0 24px 24px !important; }
#checkout-checkout .panel-collapse .panel-body { border-top: 1.5px solid var(--lf-border); padding-top: 20px !important; }

/* ═══════════════════════════════════════════════
   11. ORDER SUMMARY SIDEBAR
   ═══════════════════════════════════════════════ */
.lf-order-summary {
  background: var(--lf-surface);
  border-radius: var(--lf-radius-lg);
  box-shadow: var(--lf-shadow-card);
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  position: sticky;
  top: 16px;
}
.lf-order-summary__notice {
  background: var(--lf-notice-bg);
  color: var(--lf-notice-text);
  border-radius: var(--lf-radius-sm);
  padding: 8px 14px;
  font-size: 12px;
  font-weight: 500;
  text-align: center;
  line-height: 1.5;
}
.lf-order-summary__lines {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding-bottom: 12px;
  border-bottom: 1.5px solid var(--lf-border);
}
.lf-order-summary__line {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}
.lf-order-summary__label { font-size: 13px; color: var(--lf-text-sec); }
.lf-order-summary__value { font-size: 13px; font-weight: 500; color: var(--lf-text); }
.lf-order-summary__total {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
}
.lf-order-summary__total-label { font-size: 15px; font-weight: 700; }
.lf-order-summary__total-value { font-size: 20px; font-weight: 700; color: var(--lf-accent); }
.lf-order-summary__meta { font-size: 12px; color: var(--lf-text-sec); line-height: 1.6; }

/* ═══════════════════════════════════════════════
   12. СЕКЦІЇ (confirm/method)
   ═══════════════════════════════════════════════ */
.lf-section-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--lf-text);
  margin: 24px 0 8px;
}
.lf-section-sub {
  font-size: 14px;
  color: var(--lf-text-sec);
  margin-bottom: 16px;
}

/* ═══════════════════════════════════════════════
   13. МОБІЛЬНА АДАПТАЦІЯ
   ═══════════════════════════════════════════════ */
@media (max-width: 768px) {

  .lf-cart-item {
    grid-template-columns: 60px 1fr auto;
    grid-template-rows: auto auto auto;
    gap: 10px 12px;
    padding: 16px;
  }
  .lf-cart-item__image { grid-row: 1 / 3; width: 60px; height: 48px; }
  .lf-cart-item__info  { grid-column: 2; grid-row: 1; }
  .lf-cart-item__remove { grid-column: 3; grid-row: 1; }
  .lf-cart-item__qty   { grid-column: 1 / 3; grid-row: 3; }
  .lf-cart-item__price-unit  { grid-column: 2; grid-row: 3; display: flex; align-items: center; }
  .lf-cart-item__price-total { grid-column: 3; grid-row: 3; display: flex; align-items: center; justify-content: flex-end; }

  .lf-cart-footer { flex-direction: column; align-items: stretch; }
  .lf-cart-totals { min-width: 0; }
  .lf-cart-actions { flex-direction: column-reverse; }
  .lf-btn { width: 100%; justify-content: center; }

  .lf-form-grid { grid-template-columns: 1fr; }
  .lf-form-row  { grid-template-columns: 1fr; }
  .lf-register-wrap { padding: 20px 16px; }
  .lf-customer-type { gap: 16px; }

  .lf-order-summary { position: static; }
}

@media (max-width: 480px) {
  .lf-cart-item { grid-template-columns: 52px 1fr auto; padding: 12px; gap: 8px 10px; }
  .lf-cart-item__image { width: 52px; height: 42px; }
  .lf-cart-item__name  { font-size: 14px; }
  .lf-cart-item__price-total { font-size: 15px; }
  .lf-cart-totals { padding: 16px; }
  .lf-register-wrap { padding: 16px 12px; }
  .lf-form-input, .lf-form-select { height: 42px; font-size: 14px; }
}

/* ═══════════════════════════════════════════════
   14. REDUCED MOTION
   ═══════════════════════════════════════════════ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: 0ms !important; }
}

/* ═══════════════════════════════════════════════
   15. CHECKOUT STEPS  (checkout.twig)
   ═══════════════════════════════════════════════ */
.lf-checkout-layout {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.lf-steps { display: flex; flex-direction: column; gap: 10px; }

.lf-step {
  background: var(--lf-surface);
  border-radius: var(--lf-radius-lg);
  box-shadow: var(--lf-shadow-card);
  overflow: hidden;
  transition: box-shadow var(--lf-t-base);
}
.lf-step--open { box-shadow: 0 4px 20px rgba(0,0,0,0.10); }

.lf-step__head {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 18px 24px;
  cursor: pointer;
  user-select: none;
  transition: background var(--lf-t-fast);
}
.lf-step__head:hover { background: #fafafa; }
.lf-step--open .lf-step__head { background: #fafafa; border-bottom: 1.5px solid var(--lf-border); }

.lf-step__num {
  width: 28px; height: 28px;
  border-radius: 50%;
  background: var(--lf-accent-light);
  color: var(--lf-accent);
  font-size: 13px;
  font-weight: 700;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  transition: background var(--lf-t-fast), color var(--lf-t-fast);
}
.lf-step--open .lf-step__num { background: var(--lf-accent); color: #fff; }

.lf-step__title {
  flex: 1;
  font-size: 15px;
  font-weight: 600;
  color: var(--lf-text);
}

.lf-step__chevron {
  color: var(--lf-text-muted);
  font-size: 18px;
  line-height: 1;
  transform: rotate(0deg);
  transition: transform var(--lf-t-fast), color var(--lf-t-fast);
}
.lf-step--open .lf-step__chevron { transform: rotate(90deg); color: var(--lf-accent); }

.lf-step__body { overflow: hidden; }
.lf-step__body .panel-body { padding: 24px !important; }

/* ═══════════════════════════════════════════════
   16. LOGIN STEP  (login.twig)
   ═══════════════════════════════════════════════ */
.lf-login-grid {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 0;
  align-items: start;
}

.lf-login-col { padding: 4px 0; }

.lf-login-divider {
  width: 1px;
  background: var(--lf-border);
  margin: 0 32px;
  align-self: stretch;
  min-height: 160px;
}

.lf-login__title {
  font-size: 17px;
  font-weight: 700;
  color: var(--lf-text);
  margin-bottom: 6px;
}
.lf-login__sub {
  font-size: 14px;
  color: var(--lf-text-sec);
  margin-bottom: 16px;
  line-height: 1.5;
}
.lf-login__hint {
  font-size: 13px;
  color: var(--lf-text-sec);
  margin: 12px 0 20px;
  line-height: 1.5;
}
.lf-login__forgotten {
  display: block;
  font-size: 13px;
  color: var(--lf-accent);
  margin-top: 6px;
  transition: color var(--lf-t-fast);
}
.lf-login__forgotten:hover { color: var(--lf-accent-h); text-decoration: underline; }

/* ═══════════════════════════════════════════════
   17. DELIVERY / PAYMENT METHOD  (method twigs)
   ═══════════════════════════════════════════════ */
.lf-method__desc {
  font-size: 14px;
  color: var(--lf-text-sec);
  margin-bottom: 14px;
}
.lf-method-group-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--lf-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin: 16px 0 8px;
}
.lf-method-list { display: flex; flex-direction: column; gap: 8px; }

.lf-method-option {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  border: 1.5px solid var(--lf-border-input);
  border-radius: var(--lf-radius-md);
  cursor: pointer;
  transition: border-color var(--lf-t-fast), background var(--lf-t-fast);
  user-select: none;
}
.lf-method-option:hover { border-color: var(--lf-accent); background: var(--lf-accent-light); }
.lf-method-option input[type="radio"] { position: absolute; opacity: 0; width: 0; height: 0; }
.lf-method-option:has(input:checked) { border-color: var(--lf-accent); background: var(--lf-accent-light); }

.lf-method-option__radio {
  width: 18px; height: 18px;
  border-radius: 50%;
  border: 2px solid var(--lf-border-input);
  flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  transition: border-color var(--lf-t-fast);
  position: relative;
}
.lf-method-option__radio::after {
  content: '';
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--lf-accent);
  opacity: 0;
  transform: scale(0.5);
  transition: opacity var(--lf-t-fast), transform var(--lf-t-fast);
}
.lf-method-option:has(input:checked) .lf-method-option__radio { border-color: var(--lf-accent); }
.lf-method-option:has(input:checked) .lf-method-option__radio::after { opacity: 1; transform: scale(1); }

.lf-method-option__label { font-size: 15px; font-weight: 500; color: var(--lf-text); }
.lf-method-option__terms { font-size: 13px; color: var(--lf-text-muted); font-weight: 400; }

.lf-form-group--mt { margin-top: 20px; }
.lf-form-submit-row--mt { margin-top: 8px; }

/* ═══════════════════════════════════════════════
   18. CONFIRM TABLE  (confirm.twig)
   ═══════════════════════════════════════════════ */
.lf-confirm-table-wrap {
  overflow-x: auto;
  margin-bottom: 20px;
  border-radius: var(--lf-radius-md);
  border: 1.5px solid var(--lf-border);
}
.lf-confirm-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}
.lf-confirm-table thead tr {
  background: #fafafa;
  border-bottom: 1.5px solid var(--lf-border);
}
.lf-confirm-table th {
  padding: 12px 16px;
  font-size: 12px;
  font-weight: 600;
  color: var(--lf-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  text-align: left;
}
.lf-confirm-table td {
  padding: 14px 16px;
  color: var(--lf-text);
  border-bottom: 1px solid var(--lf-border);
  vertical-align: top;
}
.lf-confirm-table tbody tr:last-child td { border-bottom: none; }
.lf-confirm-table tfoot td { border-top: 1.5px solid var(--lf-border); border-bottom: none; padding: 12px 16px; }
.lf-confirm-table__right { text-align: right !important; }
.lf-confirm-table__link { color: var(--lf-text); font-weight: 500; text-decoration: none; }
.lf-confirm-table__link:hover { color: var(--lf-accent); }
.lf-confirm-table__option { color: var(--lf-text-sec); }
.lf-confirm-table__recurring { color: var(--lf-accent); font-size: 12px; }
.lf-confirm-table__grand td { background: #fafafa; }
.lf-confirm-table__grand strong { font-size: 16px; color: var(--lf-text); }
.lf-confirm-table__grand .lf-confirm-table__right:last-child { font-size: 18px; font-weight: 700; color: var(--lf-accent); }

/* ═══════════════════════════════════════════════
   19. МОБІЛЬНА — ДОДАТКОВІ ПРАВИЛА
   ═══════════════════════════════════════════════ */
@media (max-width: 768px) {
  .lf-login-grid { grid-template-columns: 1fr; }
  .lf-login-divider { width: 100%; height: 1px; min-height: 0; margin: 24px 0; }
  .lf-step__head { padding: 16px; }
  .lf-step__body .panel-body { padding: 16px !important; }
  .lf-confirm-table th, .lf-confirm-table td { padding: 10px 12px; }
}

/* ═══════════════════════════════════════════════
   20. CHECKOUT BOTTOM LAYOUT (макет з макету)
   ═══════════════════════════════════════════════ */
.lf-checkout-bottom {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 24px;
  align-items: start;
  margin-top: 16px;
}

/* Ліва частина — форма */
.lf-checkout-form-section {
  background: var(--lf-surface);
  border-radius: var(--lf-radius-lg);
  box-shadow: var(--lf-shadow-card);
  padding: 32px;
}

.lf-form-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
}
.lf-form-title {
  font-size: 20px;
  font-weight: 700;
  color: var(--lf-text);
}
.lf-form-login-hint {
  font-size: 13px;
  color: var(--lf-text-sec);
}
.lf-form-login-link {
  color: var(--lf-accent);
  font-weight: 600;
  text-decoration: none;
}
.lf-form-login-link:hover { color: var(--lf-accent-h); text-decoration: underline; }

/* Панелі AJAX — без зайвих відступів */
.lf-ajax-panel .panel-body { padding: 0 !important; }

/* Права частина — сайдбар */
.lf-order-summary {
  position: sticky;
  top: 16px;
}

/* Мін. сума */
.lf-order-summary__min-notice {
  background: var(--lf-notice-bg);
  color: var(--lf-notice-text);
  border-radius: var(--lf-radius-sm);
  padding: 8px 14px;
  font-size: 12px;
  font-weight: 500;
  text-align: center;
  margin-bottom: 0;
}

/* Порожній кошик */
.lf-empty-cart {
  padding: 20px;
  text-align: center;
  color: var(--lf-text-muted);
  font-size: 14px;
}

/* Помилки полів форми */
.lf-form-input--error { border-color: var(--lf-error) !important; }
.lf-form-error {
  font-size: 12px;
  color: var(--lf-error);
  margin-top: -8px;
  margin-bottom: 4px;
}

/* ── Мобільна для checkout-bottom ── */
@media (max-width: 768px) {
  .lf-checkout-bottom {
    grid-template-columns: 1fr;
  }
  .lf-order-summary {
    position: static;
    order: -1;
  }
  .lf-checkout-form-section {
    padding: 20px 16px;
  }
  .lf-form-header { flex-direction: column; gap: 4px; }
}
