/* Уроборос — тема видавництва на основі Forma. Кольори, шрифти й радіуси — токени
   магазину (--store-*); тут — ритм Forma і власна розмітка (fm-*, ob-*). */

:root {
  --fm-gutter: clamp(1rem, 3vw, 2rem);
  --fm-section: clamp(3rem, 7vw, 6rem);
  --fm-line: rgb(var(--store-primary-rgb) / .12);
  --fm-ease: cubic-bezier(.2, .7, .2, 1);
  --sf-menu-gap: 1.75rem;
  --sf-menu-link-color: var(--store-ink);
  --sf-menu-link-hover-color: var(--store-primary);
  --sf-cart-count-bg: var(--store-accent);
  --sf-cart-count-color: var(--store-on-accent);
  --store-footer-background: var(--store-ink);
  --sf-footer-title-color: var(--store-on-dark);
  --sf-footer-link-color: rgb(255 255 255 / .72);
  --sf-footer-link-hover-color: var(--store-on-dark);
}

body { -webkit-font-smoothing: antialiased; }

/* Building blocks */
.fm-container { box-sizing: border-box; width: 100%; max-width: var(--store-container); margin-inline: auto; padding-inline: var(--fm-gutter); }
.fm-h1 { margin: 0; font-family: var(--store-font-display); font-size: clamp(2rem, 4vw, 3rem); font-weight: 600; line-height: 1.1; letter-spacing: -.02em; color: var(--store-ink); }
.fm-h2 { margin: 0 0 var(--store-space-4); font-family: var(--store-font-display); font-size: var(--store-text-2xl); font-weight: 600; color: var(--store-ink); }
.fm-h3 { margin: 0; font-family: var(--store-font-display); font-size: var(--store-text-xl); font-weight: 600; color: var(--store-ink); }
.fm-eyebrow { margin: 0 0 var(--store-space-2); color: var(--store-accent); font-size: var(--store-text-xs); font-weight: 700; letter-spacing: .14em; text-transform: uppercase; }
.fm-lead { margin: var(--store-space-3) 0 0; max-width: 42rem; color: var(--store-muted); font-size: var(--store-text-lg); line-height: 1.6; }
.fm-muted { margin: var(--store-space-2) 0 0; color: var(--store-muted); }
.fm-link { color: var(--store-primary); font-weight: 600; text-align: center; text-decoration: underline; text-underline-offset: 4px; }
.fm-panel { box-sizing: border-box; padding: clamp(1.25rem, 3vw, 2rem); border: 1px solid var(--fm-line); border-radius: var(--store-radius-lg); background: var(--store-surface); }
.fm-button { display: inline-flex; align-items: center; justify-content: center; min-height: 3rem; padding: 0 var(--store-space-6); border: 2px solid var(--store-primary); border-radius: var(--store-radius-md); background: var(--store-primary); color: var(--store-on-accent); font-weight: 700; text-decoration: none; transition: background .2s var(--fm-ease), color .2s var(--fm-ease); }
.fm-button:hover { background: var(--store-primary-strong); border-color: var(--store-primary-strong); }
.fm-button--ghost { background: transparent; color: var(--store-primary); }
.fm-button--ghost:hover { background: var(--store-primary-soft); color: var(--store-primary-strong); }
.fm-empty { display: grid; gap: var(--store-space-4); justify-items: center; padding: var(--store-space-12) var(--store-space-4); text-align: center; color: var(--store-muted); }
.fm-breadcrumbs { display: flex; flex-wrap: wrap; gap: var(--store-space-2); margin-bottom: var(--store-space-8); color: var(--store-muted); font-size: var(--store-text-sm); }
.fm-breadcrumbs a { color: inherit; text-decoration: none; }
.fm-breadcrumbs a:hover { color: var(--store-primary); }
.fm-page-head { display: grid; gap: var(--store-space-2); margin-bottom: var(--store-space-10); }
.fm-page-head--top { padding-top: var(--fm-section); }
.fm-page-head--center { justify-items: center; text-align: center; }
.fm-badge { display: inline-flex; padding: .2rem .55rem; border-radius: var(--store-radius-full); background: var(--store-surface); color: var(--store-ink); font-size: var(--store-text-xs); font-weight: 700; box-shadow: 0 1px 2px rgb(0 0 0 / .08); }
.fm-badge--sale { background: var(--store-accent); color: var(--store-on-accent); }
.fm-badge--muted { color: var(--store-muted); }

/* Header */
.fm-announcement { padding: .55rem var(--fm-gutter); background: var(--store-primary); color: var(--store-on-accent); font-size: var(--store-text-sm); font-weight: 600; text-align: center; }
.fm-announcement a { color: inherit; text-decoration: none; }
.fm-header { border-bottom: 1px solid var(--fm-line); background: var(--store-paper); }
.fm-header__row { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: var(--store-space-6); min-height: 4.5rem; }
.fm-header__start { display: flex; align-items: center; gap: var(--store-space-4); }
.fm-header__middle { display: flex; justify-content: center; }
.fm-header__end { display: flex; align-items: center; justify-content: flex-end; gap: var(--store-space-2); }
.fm-header--left .fm-header__middle { justify-content: center; }
@media (max-width: 1023px) {
  .fm-header__row { grid-template-columns: auto 1fr auto; gap: var(--store-space-3); }
  .fm-header--left .fm-header__middle { display: none; }
  .fm-header--center .fm-header__start [data-component="header.menu"] { display: none; }
}

/* Footer */
.fm-footer { padding-top: var(--fm-section); background: var(--store-ink); color: var(--store-on-dark); }
.fm-footer__grid { display: grid; gap: var(--store-space-10); grid-template-columns: 1fr; padding-bottom: var(--store-space-12); }
@media (min-width: 768px) { .fm-footer__grid { grid-template-columns: 2fr 1fr 1fr 1fr; } }
.fm-footer__brand { display: grid; gap: var(--store-space-5); align-content: start; }
.fm-footer__about { margin: 0; max-width: 26rem; color: rgb(255 255 255 / .72); line-height: 1.6; }
.fm-footer__title { margin: 0 0 var(--store-space-4); color: var(--store-on-dark); font-size: var(--store-text-sm); font-weight: 700; letter-spacing: .1em; text-transform: uppercase; }
.fm-footer__bottom { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--store-space-4); padding-block: var(--store-space-6); border-top: 1px solid rgb(255 255 255 / .12); color: rgb(255 255 255 / .6); font-size: var(--store-text-sm); }

/* Product card */
.fm-card { display: flex; flex-direction: column; gap: var(--store-space-3); height: 100%; }
.fm-card--framed { padding: var(--store-space-3); border: 1px solid var(--fm-line); border-radius: var(--store-radius-lg); background: var(--store-surface); }
.fm-card__media { position: relative; display: block; overflow: hidden; aspect-ratio: 4 / 5; border-radius: var(--store-radius-md); background: var(--store-primary-soft); }
.fm-card__image, .fm-card__placeholder { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: opacity .4s var(--fm-ease), transform .6s var(--fm-ease); }
.fm-card__image--second { opacity: 0; }
.fm-card:hover .fm-card__image--second { opacity: 1; }
.fm-card:hover .fm-card__image:only-of-type { transform: scale(1.03); }
.fm-card__badges { position: absolute; top: var(--store-space-3); left: var(--store-space-3); display: flex; flex-wrap: wrap; gap: var(--store-space-1); }
.fm-card__body { display: flex; flex: 1; flex-direction: column; gap: var(--store-space-2); }
.fm-card__title { color: var(--store-ink); font-weight: 600; line-height: 1.35; text-decoration: none; }
.fm-card__title:hover { color: var(--store-primary); }
.fm-card__price { display: flex; gap: var(--store-space-2); align-items: baseline; margin: 0 0 auto; font-weight: 700; }
.fm-card__price s { color: var(--store-muted); font-weight: 400; }
.fm-card__body > :last-child { align-self: stretch; }

/* Product page */
.fm-product { display: grid; gap: clamp(2rem, 5vw, 4rem); align-items: start; }
@media (min-width: 1024px) {
  .fm-product { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); }
  .fm-product--gallery-right .fm-product__media { order: 2; }
  .fm-product__summary { position: sticky; top: 6rem; }
}
.fm-product__summary { display: grid; gap: var(--store-space-4); }
.fm-product__buy { display: flex; align-items: flex-start; gap: var(--store-space-3); }
.fm-product__buy > :first-child { flex: 1; }
.fm-product__buy [data-part="buy"] { margin-top: 0; max-width: none; }
.fm-product__promise { margin: 0; padding: var(--store-space-3) var(--store-space-4); border-radius: var(--store-radius-md); background: var(--store-primary-soft); color: var(--store-primary-strong); font-size: var(--store-text-sm); font-weight: 600; }
.fm-details { border-top: 1px solid var(--fm-line); }
.fm-details:last-of-type { border-bottom: 1px solid var(--fm-line); }
.fm-details > summary { display: flex; justify-content: space-between; padding: var(--store-space-4) 0; cursor: pointer; font-weight: 700; list-style: none; }
.fm-details > summary::-webkit-details-marker { display: none; }
.fm-details > summary::after { content: "+"; font-size: var(--store-text-xl); line-height: 1; transition: transform .2s; }
.fm-details[open] > summary::after { transform: rotate(45deg); }
.fm-details > :not(summary) { padding-bottom: var(--store-space-5); }
.fm-product__details { display: grid; gap: var(--store-space-10); margin-top: var(--fm-section); }
.fm-product__folds { display: grid; }
@media (min-width: 1024px) { .fm-product__details { grid-template-columns: 1fr 1fr; } }
.fm-product__reviews { margin-top: var(--fm-section); }

/* Catalog */
.fm-collection-head { display: grid; gap: var(--store-space-2); margin-bottom: var(--store-space-8); }
.fm-collection-head--center { justify-items: center; text-align: center; }

/* Mini cart and cart */
.fm-mini { display: flex; flex: 1; flex-direction: column; min-height: 0; gap: var(--store-space-4); }
.fm-mini__head { display: flex; align-items: center; justify-content: space-between; }
.fm-mini__lines { flex: 1; min-height: 0; overflow-y: auto; }
.fm-mini__foot { display: grid; gap: var(--store-space-3); padding-top: var(--store-space-4); border-top: 1px solid var(--fm-line); }
.fm-cart { display: grid; gap: var(--store-space-8); align-items: start; margin-top: var(--store-space-8); }
@media (min-width: 1024px) { .fm-cart { grid-template-columns: minmax(0, 1fr) 22rem; } .fm-cart__aside { position: sticky; top: 6rem; } }
.fm-cart__aside { display: grid; gap: var(--store-space-4); }
.fm-cart__upsell { margin-top: var(--fm-section); }

/* Checkout */
.fm-checkout { display: grid; gap: var(--store-space-8); align-items: start; }
@media (min-width: 1024px) { .fm-checkout { grid-template-columns: minmax(0, 1fr) 24rem; } .fm-checkout__head { grid-column: 1 / -1; } .fm-checkout__summary { position: sticky; top: 2rem; } }
.fm-checkout__steps { display: grid; gap: var(--store-space-6); }
.fm-checkout__summary { box-sizing: border-box; display: grid; gap: var(--store-space-4); padding: var(--store-space-6); border-radius: var(--store-radius-lg); background: var(--store-ink); color: var(--store-on-dark); }
.fm-checkout__summary .fm-h3 { color: var(--store-on-dark); }
.fm-checkout__trust { margin: 0; color: rgb(255 255 255 / .7); font-size: var(--store-text-sm); text-align: center; }

/* Thank-you page */
.fm-thanks { display: grid; gap: var(--store-space-4); max-width: 40rem; margin: 0 auto; text-align: center; justify-items: center; }
.fm-thanks__lines { width: 100%; margin: 0; padding: 0; list-style: none; text-align: left; }
.fm-thanks__lines li, .fm-thanks__total { display: flex; justify-content: space-between; gap: var(--store-space-4); width: 100%; padding: var(--store-space-3) 0; border-bottom: 1px solid var(--fm-line); }
.fm-thanks__total { margin: 0; border: 0; font-size: var(--store-text-lg); }

/* Blog and article */
.fm-article { box-sizing: border-box; margin: 0 auto; max-width: 64rem; padding: var(--fm-section) var(--fm-gutter); }
.fm-entry { box-sizing: border-box; margin: 0 auto; max-width: var(--store-container); padding: var(--fm-section) var(--fm-gutter); }
.fm-article--narrow .fm-article__head, .fm-article--narrow .fm-article__body { max-width: 44rem; margin-inline: auto; }
.fm-article__head { display: grid; gap: var(--store-space-3); margin-bottom: var(--store-space-8); }
.fm-article__cover { display: block; width: 100%; max-height: 32rem; margin-bottom: var(--store-space-10); border-radius: var(--store-radius-lg); object-fit: cover; }
.fm-article__body { font-size: var(--store-text-lg); line-height: 1.75; }

/* Account and sign-in */
.fm-account { display: grid; gap: var(--store-space-8); align-items: start; }
@media (min-width: 1024px) { .fm-account { grid-template-columns: 14rem minmax(0, 1fr); } }
.fm-account__menu { display: grid; gap: var(--store-space-3); }
.fm-account__menu nav { display: grid; gap: var(--store-space-1); }
.fm-account__menu nav a { padding: var(--store-space-2) var(--store-space-3); border-radius: var(--store-radius-md); color: var(--store-ink); font-weight: 600; text-decoration: none; }
.fm-account__menu nav a:hover { background: var(--store-primary-soft); }
.fm-account__menu nav a.is-active { background: var(--store-primary); color: var(--store-on-accent); }
.fm-account__main { display: grid; gap: var(--store-space-4); }
.fm-auth { display: grid; gap: var(--store-space-4); justify-items: center; }
.fm-auth__card { display: grid; gap: var(--store-space-2); width: 100%; max-width: 28rem; }
.fm-auth__note { max-width: 28rem; margin: 0; color: var(--store-muted); font-size: var(--store-text-sm); text-align: center; }

/* 404 */
.fm-404 { display: grid; gap: var(--store-space-4); justify-items: center; padding-block: var(--fm-section); text-align: center; }
.fm-404__code { margin: 0; color: var(--store-primary-soft); font-family: var(--store-font-display); font-size: clamp(5rem, 16vw, 10rem); font-weight: 800; line-height: 1; }
.fm-404__actions { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--store-space-3); margin-top: var(--store-space-4); }

/* Reviews switched off leave no empty block. */
.fm-product__reviews:not(:has(*)) { display: none; }

/* Уроборос: секції головної (ob-*), як на ouroborosbooks.com.ua */
.ob-wrap { box-sizing: border-box; width: 100%; max-width: var(--store-container); margin-inline: auto; padding-inline: var(--fm-gutter); }
.ob-section { padding-block: clamp(3rem, 6vw, 6rem); }
.ob-section--surface { background: var(--store-surface); }
.ob-head { display: flex; align-items: flex-end; justify-content: space-between; gap: var(--store-space-6); margin-bottom: clamp(1.5rem, 3vw, 2.5rem); }
.ob-eyebrow { margin: 0 0 var(--store-space-2); color: var(--store-accent); font-size: var(--store-text-xs); font-weight: 800; letter-spacing: .2em; text-transform: uppercase; }
.ob-h2 { margin: 0; font-family: var(--store-font-display); font-size: clamp(1.875rem, 3.5vw, 2.25rem); font-weight: 600; letter-spacing: -.02em; color: var(--store-primary-strong); }
.ob-more { flex: none; color: var(--store-primary-strong); font-weight: 700; text-decoration: underline; text-decoration-color: var(--store-accent); text-decoration-thickness: 2px; text-underline-offset: 6px; }
.ob-more:hover { color: var(--store-primary); }
.ob-empty { color: var(--store-muted); }

.ob-hero { position: relative; display: grid; min-height: clamp(26rem, 70vh, 44rem); overflow: hidden; background: var(--store-primary-strong); color: var(--store-on-dark); }
.ob-hero__image { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.ob-hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgb(0 0 0 / .05), rgb(0 0 0 / .55)); }
.ob-hero__body { position: relative; z-index: 1; align-self: end; padding-block: clamp(2.5rem, 6vw, 5rem); }
.ob-hero__title { max-width: 18ch; margin: 0 0 var(--store-space-6); font-family: var(--store-font-display); font-size: clamp(2.25rem, 6vw, 4.25rem); font-weight: 600; line-height: 1.05; letter-spacing: -.03em; }
.ob-hero__button { border-color: var(--store-accent); background: var(--store-accent); }
.ob-hero__button:hover { border-color: var(--store-accent); background: var(--store-accent); filter: brightness(.92); }

.ob-genres__grid { display: grid; gap: .75rem; grid-template-columns: 1fr; }
@media (min-width: 640px) { .ob-genres__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1024px) { .ob-genres__grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.ob-genre { display: flex; align-items: flex-end; justify-content: space-between; min-height: 7rem; box-sizing: border-box; padding: 1.25rem; border: 1px solid var(--fm-line); border-radius: var(--store-radius-lg); background: var(--store-surface); color: var(--store-primary-strong); text-decoration: none; transition: transform .2s var(--fm-ease), border-color .2s var(--fm-ease), box-shadow .2s var(--fm-ease); }
.ob-genre:hover { transform: translateY(-4px); border-color: var(--store-accent); box-shadow: 0 18px 40px -24px rgb(var(--store-primary-rgb) / .45); }
.ob-genre__name { display: flex; align-items: center; gap: .75rem; font-family: var(--store-font-display); font-size: var(--store-text-xl); font-weight: 600; }
.ob-genre__icon { width: 1.75rem; height: 1.75rem; object-fit: contain; }
.ob-genre__arrow { display: grid; place-items: center; width: 2.25rem; height: 2.25rem; flex: none; border-radius: 999px; background: var(--store-primary-soft); color: var(--store-primary); }

.ob-blog__grid { display: grid; gap: 1.5rem; grid-template-columns: 1fr; }
@media (min-width: 768px) { .ob-blog__grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.ob-post { overflow: hidden; border-radius: var(--store-radius-lg); background: var(--store-surface); box-shadow: 0 1px 0 var(--fm-line); }
.ob-post__media { display: block; aspect-ratio: 16 / 9; background: var(--store-primary-soft); }
.ob-post__media img, .ob-post__placeholder { display: block; width: 100%; height: 100%; object-fit: cover; }
.ob-post__body { padding: 1.5rem 2rem 2rem; }
.ob-post__date { margin: 0 0 .75rem; color: var(--store-accent); font-size: var(--store-text-sm); font-weight: 600; }
.ob-post__title { margin: 0; font-family: var(--store-font-display); font-size: var(--store-text-2xl); font-weight: 600; line-height: 1.25; }
.ob-post__title a { color: var(--store-primary-strong); text-decoration: none; }
.ob-post__title a:hover { color: var(--store-primary); }

/* Автори й авторки під назвою книги */
.ob-byline { margin: var(--store-space-1) 0 var(--store-space-3); color: var(--store-muted); font-size: var(--store-text-sm); }
.fm-product__summary .ob-byline { font-size: var(--store-text-base); }
.ob-byline__role { color: var(--store-muted); }
.ob-byline__name { color: var(--store-primary); font-weight: 600; text-decoration: none; }
.ob-byline__name:hover { text-decoration: underline; text-underline-offset: 3px; }

@media (max-width: 640px) {
  .ob-head { align-items: flex-start; flex-direction: column; gap: var(--store-space-3); }
}
@media (prefers-reduced-motion: reduce) {
  .ob-genre { transition: none; }
  .ob-genre:hover { transform: none; }
}

/* Сторінка автора й авторки */
.ob-author { box-sizing: border-box; width: 100%; max-width: var(--store-container); margin-inline: auto; padding: clamp(2rem, 5vw, 4rem) var(--fm-gutter) var(--fm-section); }
.ob-author__head { display: grid; gap: clamp(1.5rem, 4vw, 3rem); grid-template-columns: minmax(0, 18rem) minmax(0, 1fr); align-items: start; margin-top: var(--store-space-8); }
.ob-author__photo { display: block; width: 100%; aspect-ratio: 3 / 4; object-fit: cover; border-radius: var(--store-radius-sm); }
.ob-author__name { margin: 0 0 var(--store-space-6); font-family: var(--store-font-display); font-size: clamp(2.25rem, 5vw, 3.75rem); font-weight: 600; line-height: 1.05; letter-spacing: -.02em; color: var(--store-primary-strong); }
.ob-author__bio { max-width: 52rem; color: var(--store-muted); font-size: var(--store-text-lg); line-height: 1.75; }
.ob-author__books { margin-top: clamp(3rem, 6vw, 5rem); }
.ob-author__books .ob-h2 { margin-bottom: clamp(1.5rem, 3vw, 2.5rem); }
@media (max-width: 720px) {
  .ob-author__head { grid-template-columns: 1fr; }
  .ob-author__photo { max-width: 16rem; }
}

/* Картка товару (як на старому сайті): папір, тонка рамка, обкладинка 18:28 */
.ob-card { display: flex; flex-direction: column; min-width: 0; height: 100%; box-sizing: border-box; padding: .75rem; background: var(--store-paper); }
.ob-card__media { position: relative; display: block; overflow: hidden; aspect-ratio: 18 / 28; border-radius: var(--store-radius-sm); background: var(--store-paper); }
.ob-card__image { display: block; width: 100%; height: 100%; object-fit: contain; mix-blend-mode: multiply; transition: opacity .5s var(--fm-ease), transform .5s var(--fm-ease); }
.ob-card__image--second { position: absolute; inset: 0; object-fit: cover; opacity: 0; }
.ob-card:hover .ob-card__image { transform: scale(1.025); }
.ob-card:hover .ob-card__image:has(+ .ob-card__image--second) { opacity: 0; }
.ob-card:hover .ob-card__image--second { opacity: 1; }
.ob-card__placeholder { display: block; width: 100%; height: 100%; background: var(--store-primary-soft); }
.ob-card__badges { position: absolute; top: .75rem; left: .75rem; right: .75rem; display: flex; flex-wrap: wrap; gap: .375rem; }
.ob-badge { max-width: 100%; overflow: hidden; padding: .25rem .625rem; border-radius: 999px; background: var(--store-accent); color: var(--store-on-accent); font-size: .62rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; text-overflow: ellipsis; white-space: nowrap; }
.ob-badge--forest, .ob-badge--petrol { background: var(--store-primary); color: #fff; }
.ob-badge--crimson, .ob-badge--berry { background: #b4232c; color: #fff; }
.ob-badge--plum { background: #6b3a76; color: #fff; }
.ob-badge--paper { background: var(--store-surface); color: var(--store-ink); }
.ob-card__title { display: -webkit-box; margin-top: .75rem; overflow: hidden; -webkit-box-orient: vertical; -webkit-line-clamp: 2; color: var(--store-primary-strong); font-family: var(--store-font-display); font-size: clamp(.875rem, 1.4vw, 1.125rem); font-weight: 600; line-height: 1.3; text-decoration: none; transition: color .2s var(--fm-ease); }
.ob-card:hover .ob-card__title { color: var(--store-accent); }
.ob-card .ob-byline { margin: .25rem 0 0; font-size: var(--store-text-xs); }
.ob-card__foot { display: flex; align-items: flex-end; justify-content: space-between; gap: .5rem; margin-top: auto; padding-top: .75rem; }
.ob-card__offer { min-width: 0; font-size: .6875rem; font-weight: 700; color: var(--store-primary); }
.ob-card__price { margin: .375rem 0 0; color: var(--store-primary-strong); font-family: var(--store-font-display); font-size: clamp(1rem, 1.4vw, 1.125rem); font-weight: 800; }
.ob-card__price s { margin-right: .5rem; color: var(--store-muted); font-weight: 600; }
/* Знімки на сторінці товару теж без білого прямокутника */
[data-component="product.gallery"] img { mix-blend-mode: multiply; }
@media (prefers-reduced-motion: reduce) { .ob-card__image { transition: none; } .ob-card:hover .ob-card__image { transform: none; } }

/* Сторінки: контакти й текстові сторінки */
.ob-page-title { margin: 0 0 clamp(2rem, 4vw, 3rem); font-family: var(--store-font-display); font-size: clamp(2.25rem, 5vw, 3rem); font-weight: 600; letter-spacing: -.02em; color: var(--store-primary-strong); }
.ob-contacts { padding-block: clamp(3rem, 6vw, 6rem); }
.ob-contacts__grid { display: grid; gap: clamp(2.5rem, 5vw, 4rem); grid-template-columns: repeat(auto-fit, minmax(min(100%, 22rem), 1fr)); align-items: start; }
.ob-contacts__main { display: grid; gap: 3rem; }
.ob-contacts__h2 { margin: 0 0 1.5rem; font-family: var(--store-font-display); font-size: clamp(1.5rem, 3vw, 1.875rem); font-weight: 600; color: var(--store-primary-strong); }
.ob-channels { display: grid; gap: 1.25rem; margin: 0; padding: 0; list-style: none; }
.ob-channel { display: inline-flex; align-items: center; gap: .875rem; max-width: 100%; color: var(--store-primary-strong); font-size: clamp(1rem, 4.4vw, var(--store-text-lg)); font-weight: 600; text-decoration: none; overflow-wrap: anywhere; }
.ob-channel:hover { color: var(--store-primary); }
.ob-channel__icon { display: inline-block; width: 2.75rem; height: 2.75rem; flex: none; border-radius: 999px; background: var(--store-primary-soft); }
.ob-channel__icon::after { content: ""; display: block; width: 100%; height: 100%; background: var(--store-primary); -webkit-mask: var(--ob-icon) center / 1.25rem no-repeat; mask: var(--ob-icon) center / 1.25rem no-repeat; }
.ob-channel__icon--phone { --ob-icon: url("ob-phone.svg"); }
.ob-channel__icon--email { --ob-icon: url("ob-email.svg"); }
.ob-contacts__form { border-radius: 999px; }
.ob-social { display: flex; flex-wrap: wrap; gap: .75rem; margin: 0; padding: 0; list-style: none; }
.ob-social__link { display: grid; place-items: center; width: 2.75rem; height: 2.75rem; border-radius: 999px; background: var(--store-primary-strong); }
.ob-social__link img { filter: invert(1); }
.ob-contacts__card { box-sizing: border-box; padding: clamp(1.5rem, 3vw, 2rem); border: 1px solid var(--fm-line); border-radius: var(--store-radius-lg); background: var(--store-surface); }
.ob-contacts__card-title { margin: .5rem 0 1.75rem; font-family: var(--store-font-display); font-size: clamp(1.5rem, 3vw, 1.875rem); font-weight: 600; color: var(--store-primary-strong); }

/* Сітки товарів як на старому сайті: 2 / 3 / 4 колонки на головній, 2 / 3 / 3 у каталозі; проміжки між картками */
.store-product-grid { gap: 2.5rem 1rem; }
@media (min-width: 1024px) { .store-product-grid { column-gap: 1.75rem; } }
[data-sf-catalog] .store-product-grid { column-gap: 1rem; }
@media (min-width: 1024px) { [data-sf-catalog] .store-product-grid { column-gap: 1.5rem; } }

/* Заголовки секцій ядра (Популярне, Новинки) в стилі видавництва */
.sf-products__eyebrow { color: var(--store-accent); font-weight: 800; letter-spacing: .2em; }
.sf-products__title { color: var(--store-primary-strong); }
.sf-products__link { color: var(--store-primary-strong); text-decoration-color: var(--store-accent); text-decoration-thickness: 2px; text-underline-offset: 6px; }

/* Кнопки купівлі як на старому сайті: мідна, при наведенні — майже чорна */
[data-component="commerce.add-to-cart"] [data-part="button"] { background: #cd883f; border-color: #cd883f; color: #fff; }
[data-component="commerce.add-to-cart"] [data-part="button"]:hover { background: #202020; border-color: #202020; color: #fff; }
/* Лічильник кількості — нейтральний, без акценту */
[data-component="commerce.add-to-cart"] [data-part="stepper"] { border: 1px solid var(--fm-line); border-radius: var(--store-radius-md); background: var(--store-surface); }
[data-component="commerce.add-to-cart"] [data-part="stepper"] button { background: transparent; color: var(--store-ink); }
[data-component="commerce.add-to-cart"] [data-part="stepper"] button:hover { background: var(--store-primary-soft); color: var(--store-ink); }
.ob-card [data-component="commerce.add-to-cart"] [data-part="button"] { width: 3.5625rem; height: 3.5625rem; border-radius: var(--store-radius-sm); }
@media (max-width: 767px) { .ob-card [data-component="commerce.add-to-cart"] [data-part="button"] { width: 2.5rem; height: 2.5rem; } }

/* Категорія: заголовок над фільтрами, SEO-опис під товарами */
.ob-collection-head { padding-top: clamp(1.5rem, 4vw, 3rem); }
.ob-collection-head .ob-page-title { margin-bottom: .5rem; }
.ob-collection-count { margin: 0 0 var(--store-space-6); color: var(--store-muted); }
.ob-collection-seo { max-width: 56rem; margin-top: clamp(2.5rem, 5vw, 4rem); color: var(--store-muted); line-height: 1.75; }
.ob-collection-seo :is(h2, h3) { color: var(--store-primary-strong); font-family: var(--store-font-display); }

/* Сторінка книги як на старому сайті */
.ob-breadcrumbs { display: flex; flex-wrap: wrap; gap: .5rem; padding-top: clamp(1.5rem, 4vw, 3rem); margin-bottom: clamp(1.5rem, 3vw, 2.5rem); color: var(--store-muted); font-size: var(--store-text-sm); }
.ob-breadcrumbs a { color: inherit; text-decoration: none; }
.ob-breadcrumbs a:hover, .ob-breadcrumbs [aria-current] { color: var(--store-primary-strong); }
.ob-product { display: grid; gap: clamp(2rem, 4vw, 4rem); grid-template-columns: minmax(0, 1fr); }
@media (min-width: 1024px) { .ob-product { grid-template-columns: minmax(0, 37fr) minmax(0, 48fr); } }
.ob-product__gallery { display: grid; gap: 1rem; grid-template-columns: repeat(2, minmax(0, 1fr)); align-content: start; }
.ob-product__shot { margin: 0; background: var(--store-paper); }
.ob-product__shot img { display: block; width: 100%; height: auto; mix-blend-mode: multiply; }
.ob-product__title { margin: .75rem 0 .5rem; font-family: var(--store-font-display); font-size: clamp(2rem, 4vw, 3rem); font-weight: 600; line-height: 1.08; letter-spacing: -.02em; color: var(--store-primary-strong); }
.ob-product__summary .ob-byline { margin-bottom: 1.5rem; }
.ob-product__description { color: var(--store-muted); font-size: var(--store-text-base); line-height: 1.75; }
.ob-product__description p { margin: 0 0 1rem; }
.ob-chips { display: flex; flex-wrap: wrap; gap: .5rem; margin: 1.5rem 0 0; padding: 0; list-style: none; }
.ob-chip { display: inline-block; padding: .3rem .7rem; border: 1px solid var(--fm-line); border-radius: 999px; background: var(--store-surface); color: var(--store-primary-strong); font-size: .75rem; font-weight: 700; text-transform: uppercase; text-decoration: none; }
a.ob-chip:hover { border-color: var(--store-accent); }
.ob-product__offer { display: grid; gap: 1rem; justify-items: start; margin-top: 2rem; }
.ob-product__offer [data-component="product.price"] { font-family: var(--store-font-display); font-size: 2rem; font-weight: 700; color: var(--store-primary-strong); }
.ob-product__buy { display: flex; flex-wrap: wrap; align-items: center; gap: .75rem; width: 100%; max-width: 28rem; }
.ob-product__buy [data-component="commerce.add-to-cart"] { flex: 1; }
.ob-product__details { margin-top: clamp(3rem, 6vw, 5rem); max-width: 56rem; }
.ob-product__reviews { margin-top: 3rem; }

/* Тон і контраст як на старому сайті: теплий сірий текст, насиченіший; надзаголовки темнішим помаранчевим */
body { font-weight: 500; }
.ob-eyebrow, .fm-eyebrow, .sf-products__eyebrow, .ob-post__date { color: #bd6817; }
.ob-product__description, .ob-author__bio, .ob-collection-seo, .fm-lead { color: var(--store-muted); font-weight: 500; }
/* Кнопки на зеленому — білий текст (на мідному акценті теж) */
.fm-button { color: #fff; }
.fm-button--ghost { color: var(--store-primary); }
.ob-hero__button, .ob-hero__button:hover { border-color: #cd883f; background: #cd883f; color: #fff; filter: none; }
.ob-hero__button:hover { border-color: #202020; background: #202020; }
/* Галерея книги з радіусами */
.ob-product__shot { overflow: hidden; border-radius: var(--store-radius); }
/* Характеристики під кнопкою, у колонці праворуч */
.ob-product__summary .ob-product__details { margin-top: 2.5rem; max-width: none; }
/* «Наші автори» на сторінці «Про нас» */
.ob-authors__title { margin-bottom: 2rem; }
.ob-authors__grid { display: grid; gap: 1.5rem; grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (min-width: 1024px) { .ob-authors__grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.ob-person { position: relative; overflow: hidden; border: 1px solid var(--fm-line); border-radius: var(--store-radius-lg); background: var(--store-surface); box-shadow: 0 1px 2px rgb(0 0 0 / .05); transition: border-color .2s var(--fm-ease), box-shadow .2s var(--fm-ease); }
.ob-person:hover { border-color: rgb(var(--store-primary-rgb) / .3); box-shadow: 0 6px 16px -8px rgb(0 0 0 / .2); }
.ob-person__link { position: absolute; inset: 0; z-index: 1; }
.ob-person__photo { display: block; width: 100%; aspect-ratio: 4 / 5; object-fit: cover; }
.ob-person__photo--empty { background: var(--store-primary-soft); }
.ob-person__name { margin: 0; padding: 1.25rem; font-family: var(--store-font-display); font-size: var(--store-text-xl); font-weight: 600; color: var(--store-primary-strong); text-decoration: underline; text-decoration-color: var(--store-accent); text-underline-offset: 4px; }
.ob-person:hover .ob-person__name { color: #92400e; }
/* Сторінка автора: книги великими картками */
.ob-author__books .sf-products__inner { padding-inline: 0; }
.ob-author__books .sf-products { padding-block: 0; }

/* Сторінки з крихтами зверху: без подвійного відступу */
.ob-contacts { padding-top: 1rem; }
