/* Loyalty — личный кабинет, промокоды, бонусы */
.ly-account, .ly-order-block, .ly-success, .ly-subscribe { --ly-border: #e5e5e5; --ly-muted: #777; --ly-accent: #000; --ly-ok: #1f7a3a; --ly-err: #b3261e; }
.ly-account { display: grid; gap: 20px; margin: 10px 0 40px; }
.ly-login { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: start; }
.ly-card { border: 1px solid var(--ly-border); padding: 24px; background: #fff; border-radius: 4px; }
.ly-card h2 { margin: 0 0 16px; font-size: 22px; }
.ly-card h3 { margin: 0 0 12px; font-size: 18px; }
.ly-muted { color: var(--ly-muted); }
.ly-small { font-size: 13px; line-height: 1.5; }
.ly-nowrap { white-space: nowrap; }
.ly-right { text-align: right; }
.ly-dim { opacity: .55; }
.ly-plus { color: var(--ly-ok); }
.ly-minus { color: var(--ly-err); }
.ly-link { color: inherit; text-decoration: underline; cursor: pointer; }
.ly-form .form-group { margin-bottom: 14px; }
.ly-form input[type=text], .ly-form input[type=email], .ly-form input[type=tel] { width: 100%; max-width: 420px; height: 46px; padding: 0 14px; border: 1px solid #ccc; font-size: 16px; box-sizing: border-box; }
.ly-form label { display: block; font-size: 13px; color: var(--ly-muted); margin-bottom: 4px; }
.ly-form .ly-check { display: flex; }
.ly-benefits ul { margin: 0 0 12px; padding-left: 20px; }
.ly-benefits li { margin-bottom: 6px; }
.ly-msg { margin-top: 12px; padding: 10px 14px; font-size: 14px; border-left: 3px solid var(--ly-ok); background: #f3f8f4; }
.ly-msg-error { border-left-color: var(--ly-err); background: #fbf1f0; }
.ly-account-head { display: flex; justify-content: space-between; align-items: center; gap: 16px; }
.ly-hello { font-size: 22px; font-weight: 600; }
.ly-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.ly-label { font-size: 13px; text-transform: uppercase; letter-spacing: .06em; color: var(--ly-muted); margin-bottom: 8px; }
.ly-big { font-size: 40px; font-weight: 700; line-height: 1.1; margin-bottom: 8px; }
.ly-big span { font-size: 16px; font-weight: 400; color: var(--ly-muted); }
.ly-code { display: inline-block; font-size: 28px; font-weight: 700; letter-spacing: .12em; padding: 8px 16px; border: 2px dashed var(--ly-accent); cursor: pointer; margin-bottom: 10px; user-select: all; }
.ly-code-sm { display: inline-block; font-weight: 700; letter-spacing: .08em; padding: 2px 8px; border: 1px dashed var(--ly-accent); }
.ly-share { display: flex; gap: 8px; margin: 12px 0; }
.ly-share input { flex: 1; min-width: 0; height: 42px; padding: 0 10px; border: 1px solid #ccc; font-size: 14px; }
.ly-share .button, .ly-promo-form .button { white-space: nowrap; margin: 0; }
.ly-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.ly-table td { padding: 8px 6px; border-bottom: 1px solid #f0f0f0; vertical-align: top; }
.ly-orders { display: grid; gap: 8px; }
.ly-order { border: 1px solid var(--ly-border); }
.ly-order summary { display: grid; grid-template-columns: 1fr auto auto auto; gap: 16px; align-items: center; padding: 12px 16px; cursor: pointer; list-style: none; }
.ly-order summary::-webkit-details-marker { display: none; }
.ly-order[open] summary { border-bottom: 1px solid var(--ly-border); }
.ly-order .ly-table { margin: 0; }
.ly-order-num { font-weight: 600; }
.ly-order-sum { font-weight: 600; white-space: nowrap; }
.ly-status { font-size: 13px; padding: 3px 10px; border-radius: 12px; color: var(--ly-status, #666); border: 1px solid currentColor; white-space: nowrap; }
.ly-row { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.ly-row input { max-width: none !important; }
.ly-check { display: flex; gap: 10px; align-items: flex-start; margin: 10px 0 16px; cursor: pointer; }
.ly-check input { margin-top: 3px; flex: none; width: 16px; height: 16px; }

/* Шапка */
.ly-header-link { display: inline-flex; align-items: center; justify-content: center; flex: none; color: inherit; text-decoration: none; margin: 0 18px; line-height: 0; }
.header-bottom-inner .header-search-button { flex-shrink: 0; } /* иконка кабинета рядом — лупа не должна сжиматься */
.ly-header-link:hover { opacity: .7; }
.ly-header-link svg { width: 20px !important; height: 20px !important; }

/* Форма заказа */
.ly-order-block { margin: 24px 0; }
.ly-block { margin-bottom: 22px; }
.ly-block h2 { margin-bottom: 12px; }
.ly-promo-form { display: flex; gap: 8px; max-width: 480px; }
.ly-promo-form input { flex: 1; min-width: 0; height: 46px; padding: 0 14px; border: 1px solid #ccc; font-size: 16px; text-transform: uppercase; }
.ly-promo-applied { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.ly-gift-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.ly-gift-item { display: flex; flex-direction: column; gap: 6px; padding: 10px; border: 1px solid var(--ly-border); cursor: pointer; font-size: 13px; }
.ly-gift-item.ly-selected { border-color: var(--ly-accent); box-shadow: 0 0 0 1px var(--ly-accent); }
.ly-gift-item input { display: none; }
.ly-gift-item img { width: 100%; height: 100px; object-fit: contain; }
.ly-summary { border-top: 1px solid var(--ly-border); padding-top: 12px; max-width: 480px; }
.ly-summary-row { display: flex; justify-content: space-between; padding: 4px 0; font-size: 15px; }
.ly-summary-row.ly-discount { color: var(--ly-ok); }
.ly-summary-row.ly-total { font-size: 20px; border-top: 1px solid var(--ly-border); margin-top: 6px; padding-top: 10px; }
.ly-login-hint { margin-bottom: 18px; }

/* После заказа */
.ly-success { display: grid; gap: 16px; margin: 20px 0; }

/* Подписка в подвале */
.ly-subscribe { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); gap: 20px; align-items: start; padding: 24px 0; border-top: 1px solid rgba(127, 127, 127, .25); margin-top: 24px; }
.ly-subscribe-text b { display: block; font-size: 18px; margin-bottom: 6px; }
.ly-subscribe-text span { opacity: .75; font-size: 14px; }
.ly-subscribe-form { display: flex; flex-wrap: wrap; gap: 8px; }
.ly-subscribe-form input[type=email] { flex: 1; min-width: 200px; height: 44px; padding: 0 12px; border: 1px solid #ccc; font-size: 15px; color: #000; background: #fff; }
.ly-subscribe-form .button { margin: 0; }
.ly-subscribe-form .ly-check { width: 100%; margin: 4px 0 0; opacity: .8; }
.ly-subscribe-form .ly-check a { color: inherit; }
.ly-subscribe-form .ly-msg { width: 100%; color: #222; }

/* Уведомление */
.ly-toast { position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 20px); background: #111; color: #fff; padding: 12px 20px; font-size: 14px; max-width: calc(100% - 32px); z-index: 100000; opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s; border-radius: 4px; }
.ly-toast.ly-show { opacity: 1; transform: translate(-50%, 0); }
.ly-toast-error { background: var(--ly-err, #b3261e); }
.ly-busy { opacity: .6; pointer-events: none; }

/* Заголовки блоков — не наследуем крупные h2 темы */
.ly-account .ly-card h2, .ly-order-block .ly-block h2, .ly-success h2 { font-size: 22px !important; line-height: 1.3 !important; margin: 0 0 14px !important; }

/* Иконка кабинета в мобильной панели — как кнопка поиска (панель свёрстана абсолютно) */
.mobile-top-panel .ly-header-link { position: absolute; right: 105px; top: 10px; width: 35px; height: 35px; margin: 0; justify-content: center; background: #fff; border-radius: 5px; box-shadow: 0 0 7px rgba(0, 0, 0, .2); color: #c08c7e; }
.mobile-top-panel .ly-header-link svg { width: 20px !important; height: 20px !important; }

@media (max-width: 800px) {
    .ly-account .ly-card h2, .ly-order-block .ly-block h2, .ly-success h2 { font-size: 20px !important; }
    .ly-subscribe-form input[type=email], .ly-subscribe-form .button { width: 100%; min-width: 0; flex: 1 1 100%; }
    .ly-promo-form { flex-direction: column; max-width: none; }
    .ly-promo-form .button { width: 100%; }
    .ly-summary { max-width: none; }
    .ly-code { font-size: 22px; }
    .ly-login, .ly-grid, .ly-row, .ly-subscribe { grid-template-columns: minmax(0, 1fr); }
    .ly-order summary { grid-template-columns: 1fr auto; }
    .ly-order-date { display: none; }
    .ly-share { flex-direction: column; }
    .ly-card { padding: 16px; }
    .ly-big { font-size: 32px; }
}
