/*
Theme Name: Downtown Child
Theme URI: https://eye-fish.com/
Description: Child theme for Downtown. Adds a basket icon with a live item count to the header top bar, and carries the site's custom CSS (migrated from Customizer Additional CSS, which is per-theme).
Author: Eye-Fish
Author URI: https://eye-fish.com/
Template: downtown
Version: 1.0.18
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: downtown-child
*/

/* ============================================================
   Migrated verbatim from Customizer > Additional CSS (theme:
   "downtown") on 2026-09-30, so these rules keep applying under
   the child theme. Do not remove without checking the shop's
   product-card layout and the Tail Blazer video sizing.
   ============================================================ */

/* Make each product card a positioning context */
.woocommerce ul.products li.product {
  position: relative;
}

/* --- Base reset so theme doesn't force full width blocks --- */
.woocommerce ul.products li.product .button,
.woocommerce ul.products li.product button {
  float: none !important;
  width: auto !important;
  box-sizing: border-box !important;
  margin: 0 !important;
}

/* --- Main button sizing (Add to Cart / Compare / Quick View) --- */
.woocommerce ul.products li.product .button.product_type_simple.add_to_cart_button,
.woocommerce ul.products li.product button.woosc-btn,
.woocommerce ul.products li.product button.woosq-btn {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  height: 38px !important;
  line-height: 38px !important;
  padding: 0 16px !important;
  font-size: 14px !important;
  font-weight: 600 !important;
  border-radius: 6px !important;
  white-space: nowrap !important;
}

/* -----------------------------------------------------
   1) HEART BUTTON: float it ABOVE Add to cart (centered)
   ----------------------------------------------------- */

/* Make wishlist container take full row but not push layout weird */
.woocommerce ul.products li.product .yith-wcwl-add-to-wishlist {
  position: absolute !important;
  left: 50% !important;
  transform: translateX(-50%) !important;
  top: calc(100% - 88px) !important; /* adjusts vertical position above Add to cart */
  z-index: 5 !important;
  margin: 0 !important;
  padding: 0 !important;
}

/* Heart button look */
.woocommerce ul.products li.product .yith-wcwl-add-to-wishlist a.add_to_wishlist {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  height: 34px !important;
  width: 34px !important;
  padding: 0 !important;
  border-radius: 6px !important;
}

/* Hide wishlist text label, keep icon only */
.woocommerce ul.products li.product .yith-wcwl-add-to-wishlist a.add_to_wishlist span {
  display: none !important;
}

/* SVG sizing */
.woocommerce ul.products li.product .yith-wcwl-add-to-wishlist svg {
  width: 18px !important;
  height: 18px !important;
  display: block !important;
}

/* -----------------------------------------------------
   2) BUTTON ROWS:
      - Add to cart alone on a centered row
      - Compare + Quick View in a row below
   ----------------------------------------------------- */

/* Add some spacing so absolutely-positioned heart doesn't overlap */
.woocommerce ul.products li.product .price {
  margin-bottom: 44px !important; /* space reserved for heart + add-to-cart area */
}

/* Center Add to cart on its own row */
.woocommerce ul.products li.product .button.product_type_simple.add_to_cart_button {
  display: flex !important;
  width: fit-content !important;
  margin: 0 auto 8px auto !important; /* centered + gap before Compare row */
}

/* Compare + Quick View as a centered row */
.woocommerce ul.products li.product button.woosc-btn,
.woocommerce ul.products li.product button.woosq-btn {
  margin: 0 2px 0 0 !important;
}

/* Wrap Compare + Quick View into a pseudo-row by making them inline and centering */
.woocommerce ul.products li.product button.woosc-btn {
  margin-left: auto !important;
}
.woocommerce ul.products li.product button.woosq-btn {
  margin-right: auto !important;
}

/* -----------------------------------------------------
   3) Hide duplicate buttons you have in markup
   ----------------------------------------------------- */
.woocommerce ul.products li.product button.woosw-btn,
.woocommerce ul.products li.product a.yith-wcqv-button {
  display: none !important;
}

/* Prevent weird uppercase transforms */
.woocommerce ul.products li.product .button,
.woocommerce ul.products li.product button {
  text-transform: none !important;
}
.woocommerce ul.products li.product .button.product_type_simple.add_to_cart_button {
    display: flex !important;
    width: 149px !important;
    top: -2px;
    left: 26px;
    margin: 0 !important;
    text-transform: uppercase !important;
}
.woocommerce ul.products li.product .button.product_type_simple.add_to_cart_button.ajax_add_to_cart:before {
    display: none !important;
}
.woocommerce ul.products li.product .yith-wcwl-add-to-wishlist {
    width: 35px;
    position: absolute !important;
    right: 10px;
    left: unset !important;
    transform: translateX(-50%) !important;
    top: calc(100% - 81px) !important;
    z-index: 5 !important;
    margin: 0 !important;
    padding: 0 !important;
}
.woocommerce ul.products li.product .yith-wcwl-add-to-wishlist {
    width: 39px;
    height: 38px;
    position: absolute !important;
    right: 10px;
    left: unset !important;
    transform: translateX(-50%) !important;
    top: calc(100% - 78px) !important;
    z-index: 5 !important;
    margin: 0 !important;
    padding: 0 !important;
    border-radius: 7px;
}
.woocommerce ul.products li.product .yith-wcwl-add-to-wishlist a.add_to_wishlist
 {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    height: 38px !important;
    width: 39px !important;
    padding: 0 !important;
    border-radius: 6px !important;
}
@media (max-width: 768px) {
  .woocommerce ul.products li.product button.woosc-btn {
    margin-left: -39px !important;
    width: 106px !important;
}
  .woocommerce ul.products li.product .yith-wcwl-add-to-wishlist {
    width: 39px;
    height: 38px;
    position: absolute !important;
    right: -7px;
    left: unset !important;
    transform: translateX(-50%
-50%
) !important;
    top: calc(100% - 78px) !important;
}
}
/* Tail Blazer (14708): balance video size with gallery image */
.postid-14708 .wp-video{width:100%!important;max-width:290px!important;margin:0 auto!important}
.postid-14708 .wp-video .mejs-container,.postid-14708 .wp-video .mejs-inner,.postid-14708 .wp-video .mejs-mediaelement,.postid-14708 .wp-video video{width:100%!important;max-width:100%!important;height:auto!important}
.postid-14708 .wp-video .mejs-layers .mejs-layer{width:100%!important;height:100%!important}
@media (max-width: 768px){
.woocommerce ul.products li.product .yith-wcwl-add-to-wishlist{width:39px;height:38px;position:absolute!important;right:-7px;left:unset!important;transform:translateX(-50% -50%)!important;top:calc(100% - 78px)!important;z-index:5!important;margin:0!important;margin-top:0!important;padding:0!important;border-radius:7px;

    z-index: 5 !important;
    margin: 0 !important;
    margin-top: 0px !important;
    padding: 0 !important;
    border-radius: 7px;
}
  .woocommerce ul.products li.product button.woosq-btn {
    margin-right: 42px !important;
    margin-top: 2px !important;
    width: 106px !important;
}
  .woocommerce ul.products li.product .button.product_type_simple.add_to_cart_button {
    display: flex !important;
    width: 149px !important;
    top: -2px;
    left: 14px;
    margin: 0 !important;
    text-transform: uppercase !important;
}
}

/* ============================================================
   Downtown Child additions
   ============================================================ */

/* Basket icon in the header top bar, next to the login links. */
.topbar-cart{display:inline-block;vertical-align:middle;margin-left:12px}
.topbar-cart-link{display:inline-flex;align-items:center;gap:6px;color:inherit;text-decoration:none}
.topbar-cart-link svg{display:block}
.topbar-cart-link:hover{opacity:.75}
.topbar-cart-count{display:inline-flex;align-items:center;justify-content:center;min-width:20px;height:20px;padding:0 6px;border-radius:10px;background:#DE6425;color:#fff;font-size:12px;font-weight:700;line-height:20px}

/* Mobile slide-in menu: solid white panel. The theme's transparent
   navigation background setting washes out the parent's white panel,
   leaving bare text floating over the page content. */
@media only screen and (max-width: 979px){
.navigation.active .mobile-menu{background:#ffffff!important}
}

/* v1.0.6: spacing for the always-visible "Continue shopping" button on the cart page */
.downtown-child-continue-shopping{margin:0 0 1.5em;}

/* v1.0.8: wishlist hearts — solid white when unpicked (no dark outline), black when picked.
   Shop cards: button stays orange in every state (never black, never white). */
.woocommerce ul.products li.product .yith-wcwl-add-to-wishlist a,
.woocommerce ul.products li.product .yith-wcwl-add-to-wishlist a:hover,
.woocommerce ul.products li.product .yith-wcwl-add-to-wishlist a:focus,
.woocommerce ul.products li.product .yith-wcwl-add-to-wishlist a:active {
  background-color: #f78c24 !important;
  border-color: #f78c24 !important;
}
.woocommerce ul.products li.product .yith-wcwl-add-to-wishlist a.add_to_wishlist svg.yith-wcwl-icon-svg {
  color: #ffffff !important;
  fill: #ffffff !important;
  stroke: #ffffff !important;
}
.woocommerce ul.products li.product .yith-wcwl-add-to-wishlist.exists a {
  font-size: 0 !important;
}
.woocommerce ul.products li.product .yith-wcwl-add-to-wishlist.exists .feedback {
  display: none !important;
}
.woocommerce ul.products li.product .yith-wcwl-add-to-wishlist.exists svg.yith-wcwl-icon-svg {
  color: #000000 !important;
  fill: #000000 !important;
  stroke: #000000 !important;
}
/* Single product page: unpicked heart white with no black outline (YITH defaults it to black);
   picked state already turns black via YITH, pinned here explicitly. */
.single-product .yith-wcwl-add-to-wishlist {
  --add-to-wishlist-icon-color: #ffffff;
}
.single-product .yith-wcwl-add-to-wishlist.exists {
  --added-to-wishlist-icon-color: #000000;
}
.single-product .yith-wcwl-add-to-wishlist.exists svg.yith-wcwl-icon-svg {
  fill: #000000 !important;
}

/* v1.0.9: (1) single-product unpicked heart — set color directly; the --add-to-wishlist-icon-color
   variable didn't take (YITH pins it closer to the element). (2) loop picked state — YITH renders
   the "Browse Wishlist" anchor with no SVG heart, so draw a black heart with CSS. */
.single-product .yith-wcwl-add-to-wishlist:not(.exists) svg.yith-wcwl-icon-svg {
  color: #ffffff !important;
}
.woocommerce ul.products li.product .yith-wcwl-add-to-wishlist.exists a {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  height: 38px !important;
  width: 39px !important;
  padding: 0 !important;
  border-radius: 6px !important;
}
.woocommerce ul.products li.product .yith-wcwl-add-to-wishlist.exists svg {
  display: none !important;
}
.woocommerce ul.products li.product .yith-wcwl-add-to-wishlist.exists a::after {
  content: "\2665\FE0E";
  color: #000000;
  font-size: 18px;
  line-height: 1;
}

/* v1.0.10: guarantee a SIMPLE SOLID white heart with no outline — paint the svg AND its path
   directly, so no outline-only rendering survives in any YITH markup variant. Unpicked only
   (a.add_to_wishlist); picked states use different markup and stay black. */
.yith-wcwl-add-to-wishlist a.add_to_wishlist svg.yith-wcwl-icon-svg,
.yith-wcwl-add-to-wishlist a.add_to_wishlist svg.yith-wcwl-icon-svg path {
  color: #ffffff !important;
  fill: #ffffff !important;
  stroke: #ffffff !important;
}
/* v1.0.11: SINGLE heart, not double. The parent theme paints its own FontAwesome
   ::before heart directly on top of YITH's SVG heart — on shop cards (white #fff,
   overlapping the white SVG = "double white") and on the single product page
   (dark #333 / orange on hover, plus a "\f112" icon in picked states). Hide the
   theme's duplicate everywhere so only YITH's one heart shows: solid white
   unpicked, black when picked. */
.woocommerce ul.products li.product .yith-wcwl-add-to-wishlist .add_to_wishlist::before,
.woocommerce-page ul.products li.product .yith-wcwl-add-to-wishlist .add_to_wishlist::before,
.woocommerce ul.products li.product .yith-wcwl-wishlistexistsbrowse.show a::before,
.woocommerce-page ul.products li.product .yith-wcwl-wishlistexistsbrowse.show a::before,
.woocommerce ul.products li.product .yith-wcwl-wishlistaddedbrowse.show a::before,
.woocommerce-page ul.products li.product .yith-wcwl-wishlistaddedbrowse.show a::before,
.single-product .yith-wcwl-add-to-wishlist .add_to_wishlist::before,
.single-product .yith-wcwl-add-to-wishlist .add_to_wishlist:hover::before,
.single-product .yith-wcwl-add-to-wishlist .add_to_wishlist:focus::before,
.single-product .yith-wcwl-wishlistexistsbrowse.show a::before,
.single-product .yith-wcwl-wishlistaddedbrowse.show a::before {
  display: none !important;
}

/* v1.0.12: FishUSA-style "Available Colors" card grid for grouped harness
   pages. Desktop 4 columns, collapsing to 1 column on phones. Eye-Fish
   orange (#f78c24) add-to-cart to match the shop's buttons. */
.eye-fish-colors-heading {
  margin: 1.5em 0 0.25em;
}
.eye-fish-colors-hint {
  margin: 0 0 1.25em;
  color: #555;
}
.eye-fish-color-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-bottom: 1.5em;
}
.eye-fish-color-card {
  border: 1px solid #e3e3e3;
  border-radius: 8px;
  background: #fff;
  padding: 16px 14px;
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.eye-fish-color-card.is-sold-out {
  opacity: 0.65;
}
.eye-fish-color-photo img {
  width: 100%;
  height: auto;
  aspect-ratio: 1 / 1;
  object-fit: contain;
  border-radius: 4px;
}
.eye-fish-color-name {
  font-size: 15px;
  line-height: 1.35;
  margin: 0;
  color: #222;
}
.eye-fish-color-price {
  font-weight: 700;
  font-size: 16px;
  color: #222;
}
.eye-fish-color-stock {
  font-size: 13px;
}
.eye-fish-color-qty {
  margin-top: auto;
  display: flex;
  justify-content: center;
}
.eye-fish-color-qty .quantity {
  margin: 0;
}
.eye-fish-color-qty input.qty {
  width: 4em;
  text-align: center;
}
button.eye-fish-grouped-submit {
  background: #f78c24 !important;
  border-color: #f78c24 !important;
  color: #fff !important;
  font-size: 17px;
  padding: 14px 34px;
}
button.eye-fish-grouped-submit:hover {
  background: #e07a1a !important;
  border-color: #e07a1a !important;
  color: #fff !important;
}
@media (max-width: 1024px) {
  .eye-fish-color-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}
@media (max-width: 768px) {
  .eye-fish-color-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
  }
}
@media (max-width: 560px) {
  .eye-fish-color-grid {
    grid-template-columns: 1fr;
  }
}

/* v1.0.13: grouped harness parents — full-width layout. The pages lead with
   a video + blade write-up, then the "Available Colors" grid, so the summary
   spans the whole page instead of sitting in the theme's right-hand column.
   (The left gallery is removed in functions.php; the display:none below is
   a backstop in case the theme renders its gallery with its own hook.) */
body.eye-fish-grouped-fullwidth .woocommerce-product-gallery,
body.eye-fish-grouped-fullwidth div.product div.images {
  display: none !important;
}
body.eye-fish-grouped-fullwidth div.product div.summary {
  width: 100% !important;
  float: none !important;
  clear: both;
}
/* Video block at the top of grouped parents (short description). */
.eye-fish-grouped-intro .eye-fish-grouped-video {
  margin: 0 0 18px;
}
.eye-fish-grouped-intro .eye-fish-grouped-video video,
.eye-fish-grouped-intro .wp-video {
  width: 100% !important;
  max-width: 860px;
}

/* v1.0.15: layout rules for the restored WooCommerce wrappers (see
   functions.php). The parent theme's CSS targets .theme-container /
   #primary / #secondary, but its templates never emit them; these rules
   ensure the re-inserted wrappers lay out correctly on desktop and
   collapse cleanly on smaller screens. The sidebar widgets themselves
   are untouched — filtering works as before. */
/* v1.0.16: use max-width + flexbox for robustness. If the theme already
   outputs an outer .theme-container (e.g. via header-shop.php), ours
   fills it (100%) instead of nesting a second fixed 1200px block;
   if standalone, ours centers at 1200px. Flexbox replaces floats for
   the sidebar/grid split. */
.theme-container {
  width: 100% !important;
  max-width: 1200px !important;
  margin-left: auto !important;
  margin-right: auto !important;
}
.theme-container::after {
  content: "";
  display: table;
  clear: both;
}
/* v1.0.18: Shop archives use the theme's NATIVE structure:
   <div class="main-content"><div id="primary">...<div id="secondary">.
   (v1.0.15-1.0.17 PHP restructuring created duplicate IDs; now disabled.)
   Center .main-content and ensure the sidebar floats work. */
body.shop-left-sidebar .main-content,
body.post-type-archive-product .main-content,
body.tax-product_cat .main-content {
  width: 100% !important;
  max-width: 1200px !important;
  margin-left: auto !important;
  margin-right: auto !important;
}
body.shop-left-sidebar .main-content::after,
body.post-type-archive-product .main-content::after,
body.tax-product_cat .main-content::after {
  content: "";
  display: table;
  clear: both;
}
body.shop-left-sidebar #primary,
body.post-type-archive-product #primary,
body.tax-product_cat #primary {
  float: left !important;
  width: 920px !important;
  max-width: calc(100% - 270px) !important;
}
body.shop-left-sidebar #secondary,
body.post-type-archive-product #secondary,
body.tax-product_cat #secondary {
  float: right !important;
  width: 250px !important;
  max-width: 250px !important;
}
@media (max-width: 979px) {
  body.shop-left-sidebar #primary,
  body.shop-left-sidebar #secondary,
  body.post-type-archive-product #primary,
  body.post-type-archive-product #secondary,
  body.tax-product_cat #primary,
  body.tax-product_cat #secondary {
    float: none !important;
    width: 100% !important;
    max-width: 100% !important;
  }
}
/* Legacy v1.0.16-1.0.17 shop-layout rules kept for safety (no longer generated). */
.theme-container.shop-layout::after {
  content: "";
  display: table;
  clear: both;
}
#primary.content-area {
  float: left !important;
}
#secondary.widget-area {
  float: right !important;
}
@media (max-width: 979px) {
  .theme-container {
    width: auto !important;
    max-width: none !important;
    margin-left: 15px !important;
    margin-right: 15px !important;
  }
  .theme-container.shop-layout {
    display: block !important;
  }
  #primary.content-area,
  #secondary.widget-area {
    width: 100% !important;
    max-width: 100% !important;
    float: none !important;
  }
}
