/* BY HOME — страница товара. Палитра Quiet Luxury (согласована со спекой). */
/* Только вертикальные отступы: сокращённая запись обнуляла боковые поля .wrap —
   на телефоне текст прилипал к краю, на компьютере страница съезжала левее шапки. */
#prod { padding-top: 24px; padding-bottom: 64px; }
.tv-empty { padding: 80px 0; text-align: center; color: #6b6b65; font-size: 18px; }
.tv-empty a { color: #a07b3f; }

.tv-crumb { font-size: 13px; color: #6b6b65; margin: 8px 0 22px; }
.tv-crumb a { color: #6b6b65; text-decoration: none; }
.tv-crumb a:hover { color: #1a1a18; }
.tv-crumb span { color: #c8c4bc; margin: 0 4px; }

.tv-grid { display: grid; grid-template-columns: 1.3fr 0.7fr; gap: 44px; align-items: start; }
/* Закреплён блок покупки, а не галерея: шапка сайта тоже закреплена (≈132 px),
   и галерея с top:20px уезжала под неё. */
.tv-buy { position: sticky; top: 150px; }
.tv-main { width: 100%; aspect-ratio: 1/1; max-height: max(420px, calc(100vh - 190px)); object-fit: contain; background: #f5f3ef; border: 1px solid #e8e4dc; border-radius: 4px; }
.tv-thumbs { display: flex; gap: 10px; margin-top: 12px; flex-wrap: wrap; }
.tv-thumb { width: 96px; height: 96px; object-fit: contain; background: #f5f3ef; border: 1px solid #e8e4dc; border-radius: 3px; cursor: pointer; opacity: .6; transition: opacity .15s, border-color .15s; }
.tv-thumb:hover, .tv-thumb.on { opacity: 1; border-color: var(--brass); }

.tv-buy h1 { font-family: 'Cormorant Garamond', Georgia, serif; font-weight: 500; font-size: 32px; line-height: 1.15; color: #1a1a18; margin: 0 0 10px; }
.tv-ref { font-family: 'Space Mono', monospace; font-size: 12px; color: #a0a09a; letter-spacing: .04em; margin-bottom: 20px; }
.tv-price { font-size: 30px; font-weight: 700; color: #1a1a18; font-variant-numeric: tabular-nums; margin-bottom: 14px; }
.tv-avail { margin-bottom: 22px; font-size: 14px; }
.tv-in { color: #5a8a6b; font-weight: 600; }
.tv-order { color: #c9813e; font-weight: 500; }
.tv-showroom { color: var(--accent); font-weight: 600; }
.tv-add { display: block; width: 100%; padding: 16px; background: var(--accent); color: #fff; border: none; border-radius: 6px; font-family: 'Manrope', sans-serif; font-size: 15px; font-weight: 600; letter-spacing: .02em; cursor: pointer; transition: background .15s; }
.tv-add:hover { background: var(--accent-d); }

/* Избранное и сравнение под кнопкой покупки: вспомогательные действия, они
   не должны спорить с «В корзину» по заметности. */
.tv-lists { display: flex; gap: 8px; margin-top: 10px; }
.tv-list { flex: 1; padding: 11px 8px; background: #fff; color: #1b1b19; border: 1px solid #e9e8e3; border-radius: 4px;
  font-family: 'Manrope', sans-serif; font-size: 12px; font-weight: 600; cursor: pointer; transition: .15s; }
.tv-list:hover { border-color: var(--brass); }
.tv-list.on { border-color: var(--brass); background: #fbf7f0; color: #a07b3f; }
.tv-wishlink { display: inline-block; margin-top: 9px; font-size: 12px; font-weight: 600; color: #a07b3f; text-decoration: none; }
.tv-wishlink:hover { text-decoration: underline; }
.tv-wishlink[hidden] { display: none; }
.tv-add.added { background: #5a8a6b; }

.tv-tabs { margin-top: 56px; border-top: 1px solid #e8e4dc; }
.tv-tabbar { display: flex; gap: 4px; flex-wrap: wrap; margin-top: 22px; }
.tv-tabbar button { padding: 10px 18px; background: none; border: none; border-bottom: 2px solid transparent; font-family: 'Manrope', sans-serif; font-size: 14px; font-weight: 500; color: #6b6b65; cursor: pointer; }
.tv-tabbar button.on { color: #1a1a18; border-bottom-color: var(--brass); }
.tv-pane { display: none; padding: 24px 0; font-size: 15px; line-height: 1.7; color: #3a3a36; max-width: 760px; }
.tv-pane.on { display: block; }
.tv-pane img { max-width: 100%; height: auto; }
.tv-attrs { border-collapse: collapse; width: 100%; max-width: 560px; }
.tv-attrs td { padding: 9px 14px; border-bottom: 1px solid #f0ede7; font-size: 14px; vertical-align: top; }
.tv-attrs td:first-child { color: #6b6b65; width: 44%; }
.tv-attrs td:last-child { color: #1a1a18; }

/* Варианты цвета и размера (группа товаров): кружки с фото и кнопки. Выбранный
   обведён, нет такого сочетания или нет в наличии - бледный, но нажимается. */
.tv-var { margin: 0 0 20px; display: grid; gap: 14px; }
.tv-var-label { font-size: 13px; color: #6b6b65; margin-bottom: 8px; }
.tv-var-label b { color: #1a1a18; font-weight: 600; }
.tv-sw-list, .tv-sz-list { display: flex; flex-wrap: wrap; gap: 10px; }
.tv-sw { position: relative; width: 52px; height: 52px; border-radius: 50%; padding: 3px; box-sizing: border-box;
  background: #fff; border: 1px solid #e0dcd2; display: grid; place-items: center; overflow: hidden;
  text-decoration: none; transition: border-color .15s, box-shadow .15s, opacity .15s; }
.tv-sw img { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; display: block; background: #f5f3ef; }
.tv-sw span { font-size: 10px; line-height: 1.1; text-align: center; color: #3a3a36; padding: 2px; }
.tv-sw:hover { border-color: var(--brass); }
.tv-sw.on { border-color: #1a1a18; box-shadow: 0 0 0 2px #fff inset, 0 0 0 1px #1a1a18; }
.tv-sw.pale { opacity: .42; }
.tv-sw.pale:hover { opacity: .8; }
.tv-sz { min-width: 48px; padding: 10px 14px; box-sizing: border-box; border: 1px solid #e0dcd2; border-radius: 6px; background: #fff;
  color: #1a1a18; font-size: 13.5px; font-weight: 600; text-align: center; text-decoration: none; transition: border-color .15s, opacity .15s; }
.tv-sz:hover { border-color: var(--brass); }
.tv-sz.on { border-color: #1a1a18; box-shadow: 0 0 0 1px #1a1a18; }
.tv-sz.pale { opacity: .42; }
.tv-sz.pale:hover { opacity: .8; }
.tv-sw:focus-visible, .tv-sz:focus-visible { outline: 2px solid #1a1a18; outline-offset: 2px; }
@media (max-width: 600px) { .tv-sw { width: 46px; height: 46px; } .tv-var { margin-bottom: 16px; } }

/* варианты (цвета и пр.) */
.tv-catnote { margin-top: 14px; font-size: 12.5px; color: #a0a09a; }

/* с этим товаром покупают */
.tv-related { margin-top: 56px; border-top: 1px solid #e8e4dc; padding-top: 8px; }
.tv-related h2 { font-family: 'Cormorant Garamond', Georgia, serif; font-weight: 500; font-size: 26px; color: #1a1a18; margin: 24px 0 20px; }
.tv-rel-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.tv-rel { text-decoration: none; color: inherit; display: block; }
.tv-rel-ph { display: block; background: var(--stone); border-radius: 6px; overflow: hidden; }
.tv-rel img { width: 100%; aspect-ratio: 1/1; object-fit: contain; padding: 8%; mix-blend-mode: multiply; display: block; transition: transform .3s; }
.tv-rel:hover img { transform: scale(1.02); }
.tv-rel-name { font-size: 13px; color: #1a1a18; margin: 8px 0 2px; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.tv-rel-price { font-size: 14px; font-weight: 700; color: #1a1a18; font-variant-numeric: tabular-nums; }

/* Коллекция — ссылка на подборку (правки Светланы 11.08) */
.tv-col-link { color: #c46f1d; text-decoration: underline; text-underline-offset: 2px; }
.tv-col-link:hover { color: #a05a12; }
/* «вся коллекция →» справа в заголовке блока «Из этой же коллекции» */
.tv-related h2 { display: flex; align-items: baseline; justify-content: space-between; gap: 14px; flex-wrap: wrap; }
.tv-col-all { font-family: 'Manrope', system-ui, sans-serif; font-size: 13px; font-weight: 600; color: #c46f1d; text-decoration: none; }
.tv-col-all:hover { text-decoration: underline; }

@media (max-width: 880px) {
  .tv-grid { grid-template-columns: 1fr; gap: 24px; }
  .tv-buy { position: static; }
  .tv-buy h1 { font-size: 26px; }
  .tv-price { font-size: 26px; }
  .tv-rel-grid { grid-template-columns: repeat(2, 1fr); }
}

/* Цена со скидкой — как на прежнем сайте: зачёркнутая старая и процент */
.tv-price s { font-size: 16px; color: #8f8c84; font-weight: 500; margin-left: 6px; }
.tv-off { font-size: 14px; font-weight: 600; color: #a4481f; margin-left: 4px; }
/* Свойства вариантов — строками характеристик, не списком «нет в наличии» */
.tv-opts { margin: 4px 0 18px; display: grid; gap: 7px; }
.tv-opt { display: grid; grid-template-columns: 150px 1fr; gap: 12px; font-size: 13.5px; line-height: 1.45; }
.tv-opt span { color: #6f6d66; }
.tv-opt b { font-weight: 500; color: #1a1a18; }
@media (max-width: 520px) { .tv-opt { grid-template-columns: 1fr; gap: 1px; } }
.tv-trust { list-style: none; padding: 16px 0 0; margin: 18px 0 0; border-top: 1px solid #e7e3db;
  display: grid; grid-template-columns: 1fr 1fr; gap: 8px 18px; font-size: 13px; color: #6f6d66; }
.tv-trust li::before { content: "—"; margin-right: 6px; color: #b7b2a8; }
.tv-show { font-size: 13.5px; color: var(--accent); margin: -6px 0 16px; }

/* Подзаголовки старых описаний (были ЗАГЛАВНЫМИ) */
.tv-pane .tv-dh { font-family: 'Cormorant Garamond', Georgia, serif; font-size: 22px; font-weight: 600; color: #1a1a18; margin: 22px 0 6px; line-height: 1.25; }
.tv-pane p { margin: 0 0 10px; }
.tv-pane ul { margin: 0 0 12px 20px; }

/* Полоса покупки: появляется, когда основная кнопка ушла с экрана */
.tv-bar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 85; display: flex; align-items: center; gap: 12px;
  padding: 10px 16px calc(10px + env(safe-area-inset-bottom)); background: var(--bg, #fbfaf7);
  border-top: 1px solid var(--line, #e7e3db); box-shadow: 0 -8px 24px rgba(20,18,14,.08); }
.tv-bar[hidden] { display: none; }
.tv-bar-price { flex: 1; font-weight: 700; font-size: 18px; font-variant-numeric: tabular-nums; }
.tv-bar-price s { font-size: 13px; font-weight: 500; color: #8f8c84; margin-left: 4px; }
.tv-bar-add { height: 46px; padding: 0 26px; border: none; border-radius: 10px; background: var(--accent); color: #fff;
  font: inherit; font-weight: 600; font-size: 15px; cursor: pointer; }
/* на компьютере полоса по центру страницы, с названием товара */
.tv-bar-name { display: none; }
@media (min-width: 881px) {
  .tv-bar { padding-left: max(20px, calc((100vw - 1320px) / 2 + 20px)); padding-right: max(120px, calc((100vw - 1320px) / 2 + 20px)); }
  .tv-bar-name { display: block; flex: 1; font-family: 'Cormorant Garamond', Georgia, serif; font-size: 20px; font-weight: 600;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .tv-bar-price { flex: none; }
}
body.has-buybar .fab { bottom: calc(80px + env(safe-area-inset-bottom)); }

/* Телефон: вкладки одной строкой с прокруткой вбок, а не в две строки */
@media (max-width: 560px) {
  .tv-tabbar { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; margin-left: -20px; margin-right: -20px; padding: 0 20px; }
  .tv-tabbar::-webkit-scrollbar { display: none; }
  .tv-tabbar button { flex: 0 0 auto; padding: 10px 14px; }
}
.tv-trust a { color: inherit; text-decoration: underline; text-underline-offset: 3px; }

.tv-qty { font-size: 14px; color: #a4481f; margin-top: 4px; }
