/* Fríðheimr — WooCommerce styles
   Overrides default WC to match the site's brand.
   Light, premium, calm — no "marketplace" look. */

/* ── Reset WooCommerce defaults ─────────────────────────────────────────── */

.woocommerce .woocommerce-notices-wrapper { display: none; }
.woocommerce form .form-row input.input-text,
.woocommerce form .form-row textarea { font-family: var(--font-main); }

/* ── Shop page layout ────────────────────────────────────────────────────── */

.woocommerce-page .ast-container,
.woocommerce .ast-container { max-width: 1200px; }

/* Breadcrumb */
.woocommerce .woocommerce-breadcrumb {
  font-size: 12px;
  color: #9ca3af;
  margin-bottom: 24px;
  padding: 0;
  background: none;
}
.woocommerce .woocommerce-breadcrumb a {
  color: #9ca3af;
  text-decoration: none;
}
.woocommerce .woocommerce-breadcrumb a:hover { color: #9333ea; }

/* Shop header — hide Astra page title (we have our own shop-intro block) */
.woocommerce-page.post-type-archive-product h1.entry-title,
.woocommerce-page.post-type-archive-product .page-title,
.woocommerce-products-header { display: none; }

/* Result count + ordering row */
.woocommerce-result-count {
  font-size: 13px;
  color: #9ca3af;
  margin: 0 0 24px;
}
.woocommerce-ordering {
  margin: 0 0 24px;
}
.woocommerce-ordering select {
  font-family: var(--font-main);
  font-size: 13px;
  border: 1px solid #ede9fe;
  border-radius: 8px;
  padding: 6px 12px;
  color: #374151;
  background: #fff;
  cursor: pointer;
}
.woocommerce-ordering select:focus { outline: none; border-color: #9333ea; }

/* Category filter tabs (if shown) */
.widget_product_categories .product-categories li a {
  color: #374151;
  font-size: 14px;
  text-decoration: none;
}
.widget_product_categories .product-categories li a:hover { color: #9333ea; }

/* ── Product grid ────────────────────────────────────────────────────────── */

.woocommerce ul.products {
  display: grid !important;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin: 0 !important;
  padding: 0 !important;
  list-style: none !important;
}

@media (max-width: 900px) {
  .woocommerce ul.products { grid-template-columns: repeat(2, 1fr); gap: 16px; }
}
@media (max-width: 520px) {
  .woocommerce ul.products { grid-template-columns: 1fr; gap: 16px; }
}

/* ── Product card ────────────────────────────────────────────────────────── */

.woocommerce ul.products li.product {
  background: #fff;
  border: 1px solid #ede9fe;
  border-radius: 16px;
  overflow: hidden;
  padding: 0 !important;
  margin: 0 !important;
  display: flex !important;
  flex-direction: column;
  transition: transform 220ms ease, box-shadow 220ms ease, border-color 220ms ease;
  position: relative;
  width: auto !important;
  float: none !important;
}

@media (hover: hover) {
  .woocommerce ul.products li.product:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 32px rgba(147, 51, 234, 0.1);
    border-color: rgba(147, 51, 234, 0.3);
  }
}

/* Product image */
.woocommerce ul.products li.product .woocommerce-LoopProduct-link {
  display: block;
  text-decoration: none !important;
}

.woocommerce ul.products li.product .attachment-woocommerce_thumbnail,
.woocommerce ul.products li.product img {
  width: 100% !important;
  height: 220px !important;
  object-fit: cover !important;
  display: block;
  border-radius: 0 !important;
  margin: 0 !important;
}

/* Category badge */
.woocommerce ul.products li.product .woocommerce-loop-category__title {
  font-size: 13px;
  color: var(--color-brand, #9333ea);
  font-weight: 600;
}

/* Card body (text area) */
.woocommerce ul.products li.product .woocommerce-loop-product__title {
  font-size: 16px !important;
  font-weight: 700 !important;
  color: #1a0f3c !important;
  line-height: 1.35;
  margin: 0 !important;
  padding: 0 !important;
  text-decoration: none !important;
}

.woocommerce ul.products li.product .fridheimr-card-body {
  padding: 16px 20px;
  display: flex;
  flex-direction: column;
  flex: 1;
  gap: 8px;
}

/* Price */
.woocommerce ul.products li.product .price {
  font-size: 18px !important;
  font-weight: 700 !important;
  color: var(--color-brand, #9333ea) !important;
  margin: 0 !important;
  display: block;
}
.woocommerce ul.products li.product .price del {
  color: #9ca3af !important;
  font-size: 14px !important;
  font-weight: 400 !important;
}
.woocommerce ul.products li.product .price ins {
  text-decoration: none !important;
}

/* Short description */
.woocommerce ul.products li.product .woocommerce-product-details__short-description {
  font-size: 13px;
  color: #6b7280;
  line-height: 1.55;
  margin: 0;
}

/* Card footer (CTA area) */
.woocommerce ul.products li.product .button {
  display: block !important;
  width: 100% !important;
  text-align: center !important;
  margin: auto 0 0 !important;
  padding: 10px 20px !important;
  font-size: 13px !important;
  font-weight: 700 !important;
  border-radius: 50px !important;
  border: none !important;
  cursor: pointer !important;
  text-decoration: none !important;
  transition: background 200ms ease, transform 200ms ease !important;
}

/* CTA button: primary (yellow) for external/service products */
.woocommerce ul.products li.product .product_type_external {
  background: var(--color-cta, #f5d97a) !important;
  color: #1a0f3c !important;
}
.woocommerce ul.products li.product .product_type_external:hover {
  background: var(--color-cta-hover, #f0cf60) !important;
  transform: translateY(-1px);
}

/* CTA button: outline for add-to-cart (physical) */
.woocommerce ul.products li.product .add_to_cart_button {
  background: transparent !important;
  color: var(--color-brand, #9333ea) !important;
  border: 2px solid var(--color-brand, #9333ea) !important;
}
.woocommerce ul.products li.product .add_to_cart_button:hover {
  background: var(--color-brand, #9333ea) !important;
  color: #fff !important;
}

/* Loading state */
.woocommerce ul.products li.product .add_to_cart_button.loading::after {
  border-top-color: #9333ea;
}
.woocommerce ul.products li.product .add_to_cart_button.added {
  border-color: #22c55e !important;
  color: #22c55e !important;
}

/* Placeholder image when no product image */
.woocommerce ul.products li.product .woocommerce-placeholder {
  width: 100% !important;
  height: 220px !important;
  background: linear-gradient(135deg, #f9f7ff 0%, #f0ecff 100%) !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
}

/* Sale badge */
.woocommerce ul.products li.product .onsale {
  background: #9333ea;
  border-radius: 8px;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 10px;
  top: 12px;
  left: 12px;
}

/* ── Card title / price spacing ─────────────────────────────────────────── */

/* WooCommerce puts title and price inside the link or after it.
   We inject a padding wrapper via PHP or rely on Astra's templates. */
.woocommerce ul.products li.product > a,
.woocommerce ul.products li.product .woocommerce-loop-product__link {
  display: block;
  text-decoration: none !important;
}

/* Title + price block below image */
.woocommerce ul.products li.product .woocommerce-loop-product__title,
.woocommerce ul.products li.product .price {
  padding-left: 20px !important;
  padding-right: 20px !important;
}
.woocommerce ul.products li.product .woocommerce-loop-product__title {
  padding-top: 16px !important;
  padding-bottom: 6px !important;
}
.woocommerce ul.products li.product .price {
  padding-bottom: 12px !important;
}
.woocommerce ul.products li.product .button {
  margin: 0 20px 20px !important;
  width: calc(100% - 40px) !important;
}

/* ── Shop page header ────────────────────────────────────────────────────── */

.woocommerce-shop-header,
.archive.woocommerce .woocommerce-products-header {
  padding: 48px 0 36px;
  text-align: center;
}

/* Category archive header */
.woocommerce .woocommerce-products-header {
  text-align: left;
}

/* ── Product category tiles (if displayed) ───────────────────────────────── */

.woocommerce ul.products li.product-category {
  text-align: center;
}
.woocommerce ul.products li.product-category img {
  border-radius: 12px !important;
  margin-bottom: 12px !important;
}
.woocommerce ul.products li.product-category h2.woocommerce-loop-category__title {
  font-size: 16px;
  font-weight: 700;
  color: #1a0f3c;
}
.woocommerce ul.products li.product-category .count {
  font-size: 12px;
  color: #9ca3af;
  margin-left: 4px;
}

/* ── Single product page ─────────────────────────────────────────────────── */

.single-product .woocommerce-product-gallery {
  border-radius: 18px;
  overflow: hidden;
  border: 1px solid #ede9fe;
}

.single-product .woocommerce-product-gallery__image img {
  border-radius: 0 !important;
}

.single-product .product_title {
  font-size: 28px !important;
  font-weight: 800 !important;
  color: #1a0f3c !important;
  line-height: 1.25;
}

.single-product .woocommerce-product-details__short-description {
  font-size: 16px;
  color: #4b5563;
  line-height: 1.7;
  margin: 16px 0 24px;
}

.single-product .price {
  font-size: 26px !important;
  font-weight: 800 !important;
  color: var(--color-brand, #9333ea) !important;
  margin: 0 0 20px !important;
  display: block;
}

/* Single product buttons */
.single-product .single_add_to_cart_button {
  font-family: var(--font-main) !important;
  font-size: 15px !important;
  font-weight: 700 !important;
  padding: 13px 32px !important;
  border-radius: 50px !important;
  border: none !important;
  cursor: pointer !important;
  background: var(--color-cta, #f5d97a) !important;
  color: #1a0f3c !important;
  transition: background 200ms ease, transform 200ms ease !important;
  text-decoration: none !important;
}

.single-product .single_add_to_cart_button:hover {
  background: var(--color-cta-hover, #f0cf60) !important;
  transform: translateY(-2px);
}

/* External product button on single page */
.single-product .product_type_external.single_add_to_cart_button {
  background: var(--color-cta, #f5d97a) !important;
  color: #1a0f3c !important;
}

/* Service CTA block */
.fridheimr-service-cta {
  margin-top: 20px;
}
.fridheimr-service-cta .btn-cta {
  font-size: 15px;
  padding: 13px 32px;
}

/* Product meta */
.woocommerce .product_meta {
  font-size: 13px;
  color: #9ca3af;
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid #ede9fe;
}
.woocommerce .product_meta .sku_wrapper,
.woocommerce .product_meta .posted_in,
.woocommerce .product_meta .tagged_as {
  display: block;
  margin-bottom: 4px;
}
.woocommerce .product_meta a { color: #9333ea; text-decoration: none; }

/* Product tabs */
.woocommerce .woocommerce-tabs .tabs li a {
  font-family: var(--font-main);
  font-size: 14px;
  font-weight: 600;
  color: #374151;
  text-decoration: none;
}
.woocommerce .woocommerce-tabs .tabs li.active a { color: #9333ea; }
.woocommerce .woocommerce-tabs .panel {
  font-size: 15px;
  line-height: 1.8;
  color: #374151;
}
.woocommerce .woocommerce-tabs .panel h2,
.woocommerce .woocommerce-tabs .panel h3 {
  font-size: 18px;
  font-weight: 700;
  color: #1a0f3c;
  margin: 20px 0 10px;
}
.woocommerce .woocommerce-tabs .panel ul {
  margin: 10px 0 10px 20px;
}
.woocommerce .woocommerce-tabs .panel ul li { margin-bottom: 6px; }
.woocommerce .woocommerce-tabs .panel em { color: #9ca3af; }

/* ── Related products ────────────────────────────────────────────────────── */

.woocommerce .related.products h2,
.woocommerce .upsells.products h2 {
  font-size: 22px;
  font-weight: 700;
  color: #1a0f3c;
  margin-bottom: 24px;
}
.woocommerce .related.products ul.products,
.woocommerce .upsells.products ul.products {
  grid-template-columns: repeat(3, 1fr) !important;
}
@media (max-width: 768px) {
  .woocommerce .related.products ul.products,
  .woocommerce .upsells.products ul.products {
    grid-template-columns: repeat(2, 1fr) !important;
  }
}

/* ── Cart & checkout (basic) ─────────────────────────────────────────────── */

.woocommerce table.shop_table {
  border: 1px solid #ede9fe;
  border-radius: 12px;
  overflow: hidden;
}
.woocommerce table.shop_table th {
  font-weight: 700;
  color: #1a0f3c;
  background: #f9f7ff;
  padding: 12px 16px;
  border-bottom: 1px solid #ede9fe;
  font-size: 13px;
}
.woocommerce table.shop_table td {
  padding: 12px 16px;
  vertical-align: middle;
  border-color: #ede9fe;
}
.woocommerce table.shop_table .product-name a {
  color: #1a0f3c;
  font-weight: 600;
  text-decoration: none;
}
.woocommerce table.shop_table .product-name a:hover { color: #9333ea; }

/* Cart total */
.woocommerce .cart_totals h2 {
  font-size: 20px;
  font-weight: 700;
  color: #1a0f3c;
  margin-bottom: 16px;
}
.woocommerce .cart_totals table.shop_table { margin-bottom: 24px; }

/* Cart & checkout buttons */
.woocommerce a.button,
.woocommerce button.button,
.woocommerce input.button {
  font-family: var(--font-main);
  font-weight: 600;
  border-radius: 50px;
  border: none;
  cursor: pointer;
  transition: background 200ms ease;
  font-size: 14px;
}
.woocommerce a.button.alt,
.woocommerce button.button.alt,
.woocommerce #payment #place_order {
  background: var(--color-cta, #f5d97a) !important;
  color: #1a0f3c !important;
  padding: 12px 28px !important;
  font-weight: 700 !important;
}
.woocommerce a.button.alt:hover,
.woocommerce button.button.alt:hover {
  background: var(--color-cta-hover, #f0cf60) !important;
}

/* ── Notices ─────────────────────────────────────────────────────────────── */

.woocommerce-message,
.woocommerce-error,
.woocommerce-info {
  border-radius: 12px;
  border: none;
  font-size: 14px;
  padding: 14px 20px;
  margin-bottom: 24px;
}
.woocommerce-message {
  background: #f0fdf4;
  color: #166534;
  border-left: 4px solid #22c55e;
}
.woocommerce-error { background: #fef2f2; color: #991b1b; border-left: 4px solid #ef4444; }
.woocommerce-info  { background: #f0ecff; color: #4b5563; border-left: 4px solid #9333ea; }

/* ── Filtering / widgets ─────────────────────────────────────────────────── */

.woocommerce-widget-layered-nav-dropdown__submit {
  background: var(--color-brand, #9333ea);
  color: #fff;
  border: none;
  border-radius: 8px;
  padding: 8px 16px;
  font-size: 13px;
  cursor: pointer;
}

/* ── Shop intro block (custom) ───────────────────────────────────────────── */

.shop-intro {
  background: #f9f7ff;
  padding: 56px 20px 48px;
  text-align: center;
  margin-bottom: 0;
}
.shop-intro__label {
  font-size: 11px;
  color: #9ca3af;
  letter-spacing: 2px;
  text-transform: uppercase;
  display: block;
  margin-bottom: 8px;
}
.shop-intro__title {
  font-size: 32px;
  font-weight: 800;
  color: #1a0f3c;
  margin: 0 0 12px;
}
.shop-intro__desc {
  font-size: 16px;
  color: #4b5563;
  max-width: 560px;
  margin: 0 auto 32px;
  line-height: 1.65;
}

/* Shop category tabs */
.shop-cats {
  display: flex;
  gap: 10px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 40px;
  padding: 0 20px;
}
.shop-cat-tab {
  padding: 8px 20px;
  border: 1px solid #ede9fe;
  border-radius: 24px;
  font-size: 14px;
  font-weight: 600;
  color: #374151;
  text-decoration: none;
  background: #fff;
  transition: all 200ms ease;
}
.shop-cat-tab:hover,
.shop-cat-tab.active {
  background: #9333ea;
  border-color: #9333ea;
  color: #fff;
}

/* ── Pre-launch: Заказать button ────────────────────────────────────────── */

.button.btn-order {
  display: inline-block;
  background: transparent;
  color: #9333ea;
  border: 2px solid #9333ea;
  border-radius: 6px;
  padding: 13px 32px;
  font-family: var(--font-main);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
}
.button.btn-order:hover {
  background: #9333ea;
  color: #fff;
}

/* Single product pre-launch CTA block */
.sp-prelaunch-cta {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 24px;
}
.sp-prelaunch-cta .sp-cta-primary {
  flex: 1 1 auto;
  text-align: center;
}
.sp-prelaunch-cta .sp-cta-secondary {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: transparent;
  color: #6b7280;
  border: 2px solid #e5e7eb;
  border-radius: 6px;
  padding: 13px 20px;
  font-family: var(--font-main);
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  white-space: nowrap;
  transition: border-color 0.2s, color 0.2s;
}
.sp-prelaunch-cta .sp-cta-secondary:hover {
  border-color: #9333ea;
  color: #9333ea;
}
.sp-prelaunch-cta .sp-cta-secondary svg {
  flex-shrink: 0;
}

/* Loop btn-order в каталоге */
.woocommerce ul.products li.product .btn-order {
  width: 100%;
  text-align: center;
  margin-top: 8px;
}

/* ── Скрыть корзину Astra (предзапуск) ─────────────────────────────────── */

.ast-header-cart-wrap,
.ast-header-cart,
.astra-menu-cart,
.ast-woo-header-cart-info,
.ast-masthead-custom-menu-items .ast-header-woo-cart,
.ast-header-woo-cart,
.ast-cart-menu-wrap,
.header-main-layout-1 .ast-header-woo-cart,
.ast-primary-header-bar .ast-header-woo-cart {
  display: none !important;
}

/* ── CTA пояснение на карточке товара ───────────────────────────────────── */

.sp-cta-note {
  font-size: 13px;
  color: #6b7280;
  line-height: 1.5;
  margin-top: 12px;
  margin-bottom: 0;
}

/* ── Предзапусковая страница /cart/ и /checkout/ ────────────────────────── */

.fh-prelaunch-page {
  min-height: 60vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 60px 20px;
}
.fh-prelaunch-page__inner {
  max-width: 520px;
  text-align: center;
}
.fh-prelaunch-page__icon {
  margin-bottom: 24px;
  opacity: 0.7;
}
.fh-prelaunch-page__title {
  font-size: 26px;
  font-weight: 800;
  color: #1a0f3c;
  margin-bottom: 16px;
}
.fh-prelaunch-page__text {
  font-size: 16px;
  color: #4b5563;
  line-height: 1.7;
  margin-bottom: 32px;
}
.fh-prelaunch-page__actions {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}
.fh-prelaunch-page__btn {
  width: auto;
  padding: 14px 40px;
  font-size: 16px;
}
.fh-prelaunch-page__link {
  font-size: 14px;
  color: #9333ea;
  text-decoration: none;
}
.fh-prelaunch-page__link:hover { text-decoration: underline; }

/* ── Уведомление о выбранном предмете на странице контакта ──────────────── */

.fh-contact-product-notice {
  background: #f5f3ff;
  border: 1.5px solid #ede9fe;
  border-radius: 10px;
  padding: 14px 20px;
  margin-bottom: 28px;
}
.fh-contact-product-notice__inner {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.fh-contact-product-notice__label {
  font-size: 14px;
  color: #6b7280;
  white-space: nowrap;
}
.fh-contact-product-notice__name {
  font-size: 15px;
  font-weight: 600;
  color: #9333ea;
  text-decoration: none;
}
.fh-contact-product-notice__name:hover { text-decoration: underline; }

/* Скрыть поле "Ссылка на предмет" (b010) визуально, но оставить в DOM */
[name*="b010"],
[name*="b010"] + label,
[id*="b010"] {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
}
/* Скрыть весь блок SureForms вокруг b010 */
[data-block-id="b010"],
.srfm-input-wrap:has([name*="b010"]) {
  display: none !important;
}

/* Поле "Интересующий предмет" (b009) — читаемое, но readonly */
[name*="b009"][readonly] {
  background: #f9f7ff;
  border-color: #d8b4fe !important;
  color: #374151;
  cursor: default;
}

/* ── Mobile responsive ───────────────────────────────────────────────────── */

@media (max-width: 768px) {
  .woocommerce ul.products li.product .attachment-woocommerce_thumbnail,
  .woocommerce ul.products li.product img {
    height: 180px !important;
  }

  .single-product .product_title { font-size: 22px !important; }
  .single-product .price { font-size: 22px !important; }
}

/* Fridheimr custom shop archive */

.fh-shop-template {
  --fh-shop-ink: #21133f;
  --fh-shop-muted: #716782;
  --fh-shop-purple: #8d3ee6;
  --fh-shop-purple-deep: #5621b0;
  --fh-shop-purple-soft: #f5efff;
  --fh-shop-lilac: #fbf7ff;
  --fh-shop-line: rgba(139, 62, 228, 0.15);
  --fh-shop-gold: #f2c943;
  background:
    radial-gradient(circle at 18% 8%, rgba(139, 62, 228, 0.06), transparent 24%),
    radial-gradient(circle at 84% 18%, rgba(242, 201, 67, 0.09), transparent 20%),
    #fff;
  color: var(--fh-shop-ink);
  font-family: var(--font-main, "Inter", sans-serif);
  margin-top: 0 !important;
  max-width: 100vw;
  overflow-x: hidden;
}

.woocommerce-shop .site-content .ast-container,
.tax-product_cat .site-content .ast-container {
  box-sizing: border-box;
  width: 100%;
  max-width: 100vw;
  padding-left: 0;
  padding-right: 0;
  overflow-x: hidden;
}

.fh-shop-shell {
  box-sizing: border-box;
  width: min(calc(100% - 40px), 1240px);
  max-width: calc(100vw - 40px);
  margin: 0 auto;
  padding: 18px 0 42px;
}

.fh-shop-breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 18px;
  color: #a39aac;
  font-size: 13px;
}

.fh-shop-breadcrumb a {
  color: inherit;
  text-decoration: none;
}

.fh-shop-breadcrumb a:hover {
  color: var(--fh-shop-purple);
}

.fh-shop-hero {
  position: relative;
  overflow: hidden;
  min-height: 210px;
  padding: 34px 42px 32px;
  border: 1px solid rgba(139, 62, 228, 0.12);
  border-radius: 8px;
  text-align: center;
  background:
    radial-gradient(circle at 19% 28%, rgba(255, 255, 255, 0.82), transparent 25%),
    radial-gradient(circle at 80% 36%, rgba(255, 255, 255, 0.76), transparent 24%),
    linear-gradient(104deg, rgba(251, 247, 255, 0.98), rgba(245, 237, 255, 0.74), rgba(251, 247, 255, 0.96));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9), 0 16px 44px rgba(83, 46, 126, 0.08);
}

.fh-shop-hero::before,
.fh-shop-hero::after {
  content: "";
  position: absolute;
  top: 50%;
  width: 224px;
  height: 224px;
  transform: translateY(-50%);
  background: var(--fh-shop-purple);
  -webkit-mask: url("https://runesmagic.com/wp-content/themes/fridheimr-child/assets/img/runes-circle.svg") center / contain no-repeat;
  mask: url("https://runesmagic.com/wp-content/themes/fridheimr-child/assets/img/runes-circle.svg") center / contain no-repeat;
  opacity: 0.055;
  pointer-events: none;
}

.fh-shop-hero::before {
  left: 24px;
}

.fh-shop-hero::after {
  right: 24px;
}

.fh-shop-hero__ornament {
  position: absolute;
  left: 50%;
  z-index: 0;
  width: min(620px, 58%);
  height: 80px;
  background: var(--fh-shop-purple);
  opacity: 0.045;
  pointer-events: none;
  -webkit-mask: url("https://runesmagic.com/wp-content/themes/fridheimr-child/assets/img/shop-ornament-line.svg") center / contain no-repeat;
  mask: url("https://runesmagic.com/wp-content/themes/fridheimr-child/assets/img/shop-ornament-line.svg") center / contain no-repeat;
}

.fh-shop-hero__ornament--top {
  top: 14px;
  transform: translateX(-50%);
}

.fh-shop-hero__ornament--bottom {
  bottom: 2px;
  transform: translateX(-50%) scaleY(-1);
  opacity: 0.035;
}

.fh-shop-hero__label,
.fh-shop-hero h1,
.fh-shop-hero p,
.fh-shop-hero__line,
.fh-shop-hero__meta {
  position: relative;
  z-index: 1;
}

.fh-shop-hero__label {
  display: block;
  margin-bottom: 8px;
  color: #c19218;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.3em;
  text-transform: uppercase;
}

.fh-shop-hero h1 {
  margin: 0;
  color: var(--fh-shop-ink);
  font-family: var(--font-serif, "Cardo", Georgia, serif);
  font-size: clamp(38px, 4.2vw, 56px);
  font-weight: 500;
  line-height: 1.04;
  letter-spacing: 0;
}

.fh-shop-hero p {
  max-width: 620px;
  margin: 14px auto 0;
  color: var(--fh-shop-muted);
  font-size: 16px;
  line-height: 1.58;
}

.fh-shop-hero__line {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: min(430px, 70%);
  margin: 20px auto 14px;
  color: var(--fh-shop-gold);
}

.fh-shop-hero__line::before,
.fh-shop-hero__line::after {
  content: "";
  height: 1px;
  flex: 1;
  background: linear-gradient(90deg, transparent, rgba(242, 201, 67, 0.45));
}

.fh-shop-hero__line::after {
  transform: scaleX(-1);
}

.fh-shop-hero__line span {
  display: inline-block;
  color: var(--fh-shop-gold);
  font-size: 24px;
  line-height: 1;
  transform: rotate(180deg);
}

.fh-shop-hero__meta {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px 24px;
  color: #3c3255;
  font-size: 14px;
  font-weight: 600;
}

.fh-shop-hero__meta span + span::before {
  content: "•";
  margin-right: 24px;
  color: var(--fh-shop-purple);
}

.fh-shop-tabs {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 12px;
  margin: 22px 0 18px;
}

.fh-shop-tab {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 38px;
  padding: 0 23px;
  border: 1px solid var(--fh-shop-line);
  border-radius: 999px;
  color: #312641;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 8px 18px rgba(71, 40, 114, 0.045);
  font-size: 14px;
  font-weight: 700;
  text-decoration: none !important;
  transition: transform 180ms ease, color 180ms ease, background 180ms ease, border-color 180ms ease;
}

.fh-shop-tab:hover,
.fh-shop-tab.is-active {
  color: #fff;
  border-color: var(--fh-shop-purple-deep);
  background: linear-gradient(180deg, var(--fh-shop-purple), var(--fh-shop-purple-deep));
  transform: translateY(-1px);
}

.fh-shop-category-select {
  display: none;
  margin: 18px 0;
}

.fh-shop-category-select select {
  width: 100%;
  min-height: 48px;
  box-sizing: border-box;
  padding: 0 48px 0 18px;
  border: 1px solid var(--fh-shop-line);
  border-radius: 999px;
  color: var(--fh-shop-purple);
  background-color: rgba(255, 255, 255, 0.88);
  background-image:
    linear-gradient(45deg, transparent 50%, var(--fh-shop-purple) 50%),
    linear-gradient(135deg, var(--fh-shop-purple) 50%, transparent 50%);
  background-position:
    calc(100% - 25px) 50%,
    calc(100% - 19px) 50%;
  background-repeat: no-repeat;
  background-size: 6px 6px, 6px 6px;
  box-shadow: 0 10px 24px rgba(71, 40, 114, 0.06);
  font-family: inherit;
  font-size: 16px;
  font-weight: 800;
  appearance: none;
}

.fh-shop-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin: 0 0 16px;
}

.fh-shop-toolbar__left {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  color: var(--fh-shop-muted);
  font-size: 14px;
}

.fh-shop-quick-filter {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 14px;
  border-radius: 999px;
  color: var(--fh-shop-purple);
  background: var(--fh-shop-lilac);
  font-size: 12px;
  font-weight: 750;
}

.fh-shop-quick-filter::before {
  content: "⌁";
  font-size: 15px;
}

.fh-shop-sort {
  display: flex;
  align-items: center;
  gap: 12px;
}

.fh-shop-sort select,
.fh-shop-filter-button {
  min-height: 38px;
  border: 1px solid rgba(139, 62, 228, 0.12);
  border-radius: 999px;
  box-sizing: border-box;
  max-width: 100%;
  color: var(--fh-shop-purple);
  background-color: var(--fh-shop-lilac);
  box-shadow: none;
  font-family: inherit;
  font-size: 12px;
  font-weight: 750;
}

.fh-shop-sort select {
  min-width: 232px;
  padding: 0 38px 0 16px;
  appearance: none;
  -webkit-appearance: none;
  background-image:
    linear-gradient(45deg, transparent 50%, var(--fh-shop-purple) 50%),
    linear-gradient(135deg, var(--fh-shop-purple) 50%, transparent 50%);
  background-position:
    calc(100% - 18px) 52%,
    calc(100% - 13px) 52%;
  background-repeat: no-repeat;
  background-size: 5px 5px, 5px 5px;
}

.fh-shop-filter-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 18px;
  cursor: pointer;
  list-style: none;
  user-select: none;
}

.fh-shop-filter-button::before {
  content: "⌄";
  display: inline-block;
  margin-right: 8px;
  transform: rotate(90deg);
  color: var(--fh-shop-purple);
}

.fh-shop-filter {
  position: relative;
}

.fh-shop-filter-button::-webkit-details-marker {
  display: none;
}

.fh-shop-filter-button::marker {
  content: "";
}

.fh-shop-filter-button::before {
  content: none;
  display: none;
}

.fh-shop-filter-panel {
  position: absolute;
  z-index: 20;
  top: calc(100% + 10px);
  right: 0;
  width: 238px;
  padding: 12px;
  border: 1px solid var(--fh-shop-line);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 18px 36px rgba(71, 40, 114, 0.14);
}

.fh-shop-filter-panel__title {
  display: block;
  margin: 0 0 8px;
  color: var(--fh-shop-muted);
  font-size: 12px;
  font-weight: 750;
}

.fh-shop-filter-option {
  display: flex;
  align-items: center;
  min-height: 34px;
  padding: 0 11px;
  border-radius: 999px;
  color: var(--fh-shop-muted) !important;
  font-size: 12px;
  font-weight: 750;
  text-decoration: none !important;
}

.fh-shop-filter-option:hover {
  color: var(--fh-shop-purple) !important;
  background: var(--fh-shop-lilac);
}

.fh-shop-filter-option.is-active {
  color: #fff !important;
  background: linear-gradient(135deg, var(--fh-shop-purple-deep), var(--fh-shop-purple));
}

.fh-shop-catalog {
  display: block;
}

.fh-shop-products {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.fh-shop-card {
  position: relative;
  overflow: hidden;
  min-width: 0;
  padding: 0 !important;
  margin: 0 !important;
  border: 1px solid var(--fh-shop-line);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 12px 26px rgba(71, 40, 114, 0.06);
  transition: transform 220ms ease, box-shadow 220ms ease, border-color 220ms ease;
}

.fh-shop-card:hover {
  transform: translateY(-4px);
  border-color: rgba(139, 62, 228, 0.3);
  box-shadow: 0 18px 36px rgba(71, 40, 114, 0.12);
}

.fh-shop-card__media {
  position: relative;
  display: block;
  overflow: hidden;
  aspect-ratio: 1.58 / 1;
  background: var(--fh-shop-purple-soft);
  text-decoration: none !important;
}

.fh-shop-card__media img {
  display: block;
  width: 100% !important;
  height: 100% !important;
  margin: 0 !important;
  object-fit: cover;
  transform: scale(1.01);
  transition: transform 380ms ease;
}

.fh-shop-card:hover .fh-shop-card__media img {
  transform: scale(1.055);
}

.fh-shop-card__heart {
  position: absolute;
  top: 9px;
  right: 10px;
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 999px;
  color: #fff;
  background: rgba(25, 12, 42, 0.2);
  font-size: 22px;
  line-height: 1;
  backdrop-filter: blur(6px);
}

.fh-shop-card__body {
  padding: 10px 10px 11px;
}

.fh-shop-card__cat {
  display: inline-block;
  margin-bottom: 5px;
  color: #8b7a9a;
  font-size: 12px;
  font-weight: 650;
  text-decoration: none !important;
}

.fh-shop-card__cat:hover {
  color: var(--fh-shop-purple);
}

.fh-shop-card h2 {
  min-height: 42px;
  margin: 0 0 8px;
  font-family: var(--font-serif, "Cardo", Georgia, serif);
  font-size: 18px;
  font-weight: 700;
  line-height: 1.18;
}

.fh-shop-card h2 a {
  color: var(--fh-shop-ink);
  text-decoration: none !important;
}

.fh-shop-card h2 a:hover {
  color: var(--fh-shop-purple);
}

.fh-shop-card__price {
  min-height: 25px;
  color: var(--fh-shop-purple) !important;
  font-size: 16px;
  font-weight: 850;
}

.fh-shop-card__price .amount,
.fh-shop-card__price bdi,
.fh-shop-card__price .woocommerce-Price-currencySymbol {
  color: inherit !important;
}

.fh-shop-card__bottom {
  display: flex;
  justify-content: flex-end;
  min-height: 22px;
  margin-top: -2px;
}

.fh-shop-card__bottom span {
  display: inline-flex;
  align-items: center;
  min-height: 20px;
  padding: 0 8px;
  border: 1px solid rgba(242, 201, 67, 0.28);
  border-radius: 6px;
  color: #b58d11;
  background: #fffaf0;
  font-size: 10px;
  font-weight: 750;
}

.fh-shop-card__button {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 32px;
  margin-top: 4px;
  border-radius: 7px;
  color: #fff !important;
  background: linear-gradient(180deg, var(--fh-shop-purple), var(--fh-shop-purple-deep));
  box-shadow: 0 10px 18px rgba(86, 33, 176, 0.18);
  font-size: 13px;
  font-weight: 850;
  text-decoration: none !important;
  transition: transform 180ms ease, box-shadow 180ms ease;
}

.fh-shop-card__button:hover {
  transform: translateY(-1px);
  box-shadow: 0 13px 22px rgba(86, 33, 176, 0.25);
}

.fh-shop-side-note {
  position: sticky;
  top: 110px;
  min-height: 420px;
  padding: 28px 17px;
  border: 1px solid var(--fh-shop-line);
  border-radius: 8px;
  text-align: center;
  background:
    radial-gradient(circle at 50% 12%, rgba(139, 62, 228, 0.07), transparent 24%),
    linear-gradient(180deg, rgba(251, 247, 255, 0) 0%, rgba(251, 247, 255, 0.8) 100%),
    linear-gradient(180deg, #fff, #fbf8ff);
  box-shadow: 0 14px 30px rgba(71, 40, 114, 0.07);
}

.fh-shop-side-note__sigil {
  width: 56px;
  height: 56px;
  margin: 8px auto 24px;
  background: var(--fh-shop-purple);
  -webkit-mask: url("https://runesmagic.com/wp-content/themes/fridheimr-child/assets/img/runes-circle.svg") center / contain no-repeat;
  mask: url("https://runesmagic.com/wp-content/themes/fridheimr-child/assets/img/runes-circle.svg") center / contain no-repeat;
  opacity: 0.16;
}

.fh-shop-side-note h2 {
  margin: 0 0 62px;
  color: var(--fh-shop-ink);
  font-family: var(--font-serif, "Cardo", Georgia, serif);
  font-size: 18px;
  line-height: 1.25;
}

.fh-shop-side-note h2::after {
  content: "";
  display: block;
  width: 82px;
  height: 1px;
  margin: 24px auto 0;
  background: linear-gradient(90deg, transparent, rgba(139, 62, 228, 0.18), transparent);
}

.fh-shop-side-note p {
  margin: 0 0 20px;
  color: var(--fh-shop-muted);
  font-size: 13px;
  line-height: 1.5;
}

.fh-shop-side-note p::before {
  content: "☏";
  display: block;
  margin-bottom: 14px;
  color: var(--fh-shop-purple);
  font-size: 42px;
  line-height: 1;
}

.fh-shop-side-note a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  padding: 0 14px;
  border-radius: 999px;
  color: #21133f !important;
  background: linear-gradient(180deg, #ffe887, var(--fh-shop-gold));
  box-shadow: 0 10px 18px rgba(193, 146, 24, 0.16);
  font-size: 12px;
  font-weight: 850;
  text-decoration: none !important;
}

.fh-shop-empty {
  grid-column: 1 / -1;
  padding: 44px;
  border: 1px solid var(--fh-shop-line);
  border-radius: 8px;
  text-align: center;
  background: #fff;
}

.fh-shop-empty h2 {
  margin: 0 0 10px;
  font-size: 24px;
}

.fh-shop-empty p {
  margin: 0 auto 18px;
  max-width: 520px;
  color: var(--fh-shop-muted);
}

.fh-shop-empty a {
  color: var(--fh-shop-purple);
  font-weight: 800;
}

.fh-shop-trust {
  position: relative;
  overflow: hidden;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0;
  margin-top: 18px;
  border: 1px solid var(--fh-shop-line);
  border-radius: 8px;
  background:
    linear-gradient(90deg, rgba(251, 247, 255, 0.94), #fff 42%, rgba(251, 247, 255, 0.94));
  box-shadow: 0 12px 28px rgba(71, 40, 114, 0.05);
}

.fh-shop-trust::before,
.fh-shop-trust::after {
  content: "";
  position: absolute;
  top: 50%;
  width: 230px;
  height: 70px;
  background: var(--fh-shop-purple);
  opacity: 0.035;
  pointer-events: none;
  -webkit-mask: url("https://runesmagic.com/wp-content/themes/fridheimr-child/assets/img/shop-ornament-line.svg") center / contain no-repeat;
  mask: url("https://runesmagic.com/wp-content/themes/fridheimr-child/assets/img/shop-ornament-line.svg") center / contain no-repeat;
}

.fh-shop-trust::before {
  left: 16px;
  transform: translateY(-50%);
}

.fh-shop-trust::after {
  right: 16px;
  transform: translateY(-50%) scaleX(-1);
}

.fh-shop-trust div {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 56px minmax(0, 1fr);
  gap: 12px 18px;
  align-items: center;
  padding: 22px 28px;
  border-right: 1px solid rgba(139, 62, 228, 0.1);
}

.fh-shop-trust div:last-child {
  border-right: 0;
}

.fh-shop-trust span {
  grid-row: span 2;
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border-radius: 999px;
  color: var(--fh-shop-purple);
  background: var(--fh-shop-purple-soft);
  font-size: 27px;
}

.fh-shop-trust h2 {
  margin: 0;
  color: var(--fh-shop-ink);
  font-size: 16px;
  font-weight: 850;
}

.fh-shop-trust p {
  margin: -6px 0 0;
  color: var(--fh-shop-muted);
  font-size: 13px;
  line-height: 1.45;
}

@media (max-width: 1120px) {
  .fh-shop-catalog {
    grid-template-columns: 1fr;
  }

  .fh-shop-side-note {
    position: relative;
    top: auto;
    display: grid;
    grid-template-columns: 74px 1fr auto;
    gap: 18px;
    align-items: center;
    min-height: 0;
    text-align: left;
  }

  .fh-shop-side-note__sigil {
    margin: 0;
  }

  .fh-shop-side-note h2,
  .fh-shop-side-note p {
    margin: 0;
  }

  .fh-shop-side-note h2::after,
  .fh-shop-side-note p::before {
    display: none;
  }
}

@media (max-width: 980px) {
  .fh-shop-products {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .fh-shop-trust {
    grid-template-columns: 1fr;
  }

  .fh-shop-trust div {
    border-right: 0;
    border-bottom: 1px solid rgba(139, 62, 228, 0.1);
  }

  .fh-shop-trust div:last-child {
    border-bottom: 0;
  }
}

@media (max-width: 760px) {
  .fh-shop-shell {
    width: min(calc(100% - 28px), 640px);
    max-width: calc(100vw - 28px);
    margin-left: auto;
    margin-right: auto;
    padding-top: 14px;
  }

  .fh-shop-hero {
    padding: 30px 22px;
  }

  .fh-shop-hero::before,
  .fh-shop-hero::after {
    width: 270px;
    height: 270px;
    opacity: 0.055;
  }

  .fh-shop-hero::before {
    left: 50%;
    top: 52%;
    transform: translate(-50%, -50%);
  }

  .fh-shop-hero::after {
    display: none;
  }

  .fh-shop-tabs {
    display: none;
  }

  .fh-shop-category-select {
    display: block;
  }

  .fh-shop-toolbar,
  .fh-shop-sort {
    align-items: stretch;
    flex-direction: column;
  }

  .fh-shop-sort select,
  .fh-shop-filter-button {
    width: 100%;
  }

  .fh-shop-filter {
    width: 100%;
  }

  .fh-shop-filter-panel {
    position: static;
    width: 100%;
    margin-top: 8px;
    box-sizing: border-box;
  }

  .fh-shop-products {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .fh-shop-side-note {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .fh-shop-side-note__sigil {
    margin: 0 auto;
  }
}

@media (max-width: 520px) {
  .fh-shop-template {
    width: 100%;
    max-width: 100vw;
    overflow-x: hidden;
  }

  .fh-shop-shell {
    width: calc(100% - 28px);
    max-width: calc(100vw - 28px);
  }

  .fh-shop-hero h1 {
    font-size: 34px;
  }

  .fh-shop-hero__meta span + span::before {
    display: none;
  }

  .fh-shop-category-select {
    margin: 16px 0 18px;
  }

  .fh-shop-products {
    grid-template-columns: 1fr;
    gap: 14px;
    width: 100%;
    max-width: 100%;
  }

  .fh-shop-card {
    width: 100%;
    max-width: 100%;
  }

  .fh-shop-card__media {
    aspect-ratio: 1.48 / 1;
  }

  .fh-shop-card__body {
    padding: 12px 14px 14px;
  }

  .fh-shop-card h2 {
    min-height: 0;
    font-size: 22px;
  }

  .fh-shop-card__price {
    font-size: 19px;
  }

  .fh-shop-card__button {
    width: 100%;
    min-height: 38px;
    margin-top: 10px;
  }

  .fh-shop-trust div {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .fh-shop-trust span {
    grid-row: auto;
    margin: 0 auto;
  }
}
