/*
Theme Name: Art Space CPH FSE
Theme URI: 
Author: computer_alex
Author URI: alexanderhjalmarsson.dk
Description: Custom Parent theme
Requires at least: 6.9
Tested up to: 6.9
Requires PHP: 7.0
Version: 1.1
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: computer_alex-starter-theme
Tags: one-column, custom-colors, custom-menu, custom-logo, editor-style, featured-images, full-site-editing, block-patterns, rtl-language-support, sticky-post, threaded-comments, translation-ready, wide-blocks, block-styles, style-variations, accessibility-ready, blog, portfolio, news

*/

/* Only behaviors without native block controls belong here. Shared values live in theme.json.
 * Loaded in the frontend and editor; low-specificity defaults allow block overrides. */

:where(.is-style-product-card) {
  border-color: var(--wp--preset--color--accent);
  background: var(--wp--preset--color--base-2);
}
:where(.is-style-product-card) .wp-block-post-title { min-height: 3.6em; }
:where(.wp-block-woocommerce-product-collection) .wp-block-query-pagination {
  gap: .75rem;
  flex-wrap: wrap;
}
:where(.wp-block-query-pagination-numbers) { display: flex; gap: .5rem; flex-wrap: wrap; }
:where(.wp-block-query-pagination) .page-numbers {
  display: inline-flex;
  min-width: 2.75rem;
  min-height: 2.75rem;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--wp--preset--color--accent);
  border-radius: 50%;
  text-decoration: none;
}
:where(.wp-block-query-pagination) .page-numbers.current {
  background: var(--wp--preset--color--contrast);
  color: var(--wp--preset--color--base-2);
}
/* The filter slider and toolbar have internal WooCommerce markup without layout controls. */
:where(.is-style-catalog-filters) .wp-block-accordion-heading__toggle {
  min-height: 44px;
  padding: .75rem;
  font-size: var(--wp--preset--font-size--medium);
  line-height: 1.5;
  text-transform: none;
}
:where(.is-style-catalog-filters) .wp-block-accordion-item {
  border-bottom: 1px solid var(--wp--preset--color--accent);
}
:where(.is-style-catalog-filters) .wc-block-product-filter-price-slider__content {
  max-width: 100%;
  grid-template-columns: minmax(0, auto) minmax(0, 1fr) minmax(0, auto);
}
:where(.is-style-catalog-filters) .wc-block-product-filter-price-slider input { max-width: 100%; }
:where(.lux-toolbar, .lux-sort-group) { gap: .75rem; flex-wrap: wrap; }
:where(.lux-toolbar) { padding-bottom: var(--wp--preset--spacing--10); }
:where(.lux-toolbar) .woocommerce-ordering { margin: 0; }
:where(.lux-toolbar) select { max-width: 100%; font: inherit; min-height: 44px; }
:where(.lux-sort-group) p { margin: 0; }
/* Product gallery and specification internals are rendered by WooCommerce. */
:where(.lux-product-gallery-shell) { min-width: 0; }
:where(.lux-product-attributes) table { width: 100%; border-collapse: collapse; }
:where(.lux-product-attributes) th,
:where(.lux-product-attributes) td {
  padding: .75rem;
  text-align: left;
  vertical-align: top;
  border-color: var(--wp--preset--color--accent);
  overflow-wrap: anywhere;
}
:where(.lux-product-attributes) th { width: 32%; font-weight: 500; }
:where(.lux-product-attributes) td p { margin: 0; }
/* Lists used by existing editorial patterns need flex layout unavailable in List controls. */
:where(.trust-list, .hero-stats) {
  display: flex;
  flex-wrap: wrap;
  gap: var(--wp--preset--spacing--10) var(--wp--preset--spacing--30);
  padding-left: 0;
  list-style: none;
}
/* Keep legacy account form controls consistent with native textInput styles. */
:where(.woocommerce-account .woocommerce) input.input-text { font: inherit; min-height: 44px; }
:where(.woocommerce-account .woocommerce) button.button {
  background: var(--wp--preset--color--contrast);
  color: var(--wp--preset--color--base-2);
  border-radius: 9999px;
  padding: .75rem 1.25rem;
  font: 500 var(--wp--preset--font-size--small)/1.5 var(--wp--preset--font-family--body);
}
/* Native Columns stack at 781px. A sidebar needs more room at tablet widths. */
@media (min-width: 782px) and (max-width: 1100px) {
  .wp-block-columns:has(> .is-style-catalog-filters) { flex-wrap: wrap !important; }
  .wp-block-columns > .is-style-catalog-filters,
  .wp-block-columns > .is-style-catalog-filters + .wp-block-column { flex-basis: 100% !important; }
}
@media (max-width: 600px) {
  .lux-sort-group { width: 100%; }
  .lux-sort-group .woocommerce-ordering { width: 100%; }
  .lux-toolbar select { width: 100%; }
  .is-style-product-card .wp-block-post-title { min-height: 0; }
}

/* WooCommerce keeps two product columns even when cards no longer fit on a phone. */
@media (max-width: 480px) {
  .wp-block-woocommerce-product-collection .wc-block-product-template {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* The legacy WooCommerce gallery has no native control for thumbnail overflow.
 * A horizontal strip keeps large image sets from pushing mobile product details away. */
.lux-product-gallery-shell .flex-control-thumbs {
  display: flex;
  gap: .75rem;
  overflow-x: auto;
  scroll-snap-type: x proximity;
  padding-bottom: .5rem;
}
.lux-product-gallery-shell .flex-control-thumbs > li {
  flex: 0 0 72px;
  scroll-snap-align: start;
}

/* Instagram supplies a fixed minimum width inline; native block controls cannot
 * override third-party iframe dimensions. This opt-in style keeps embeds inside columns. */
.wp-block-embed.is-style-artspace-instagram .instagram-media,
.wp-block-embed.is-style-artspace-instagram .instagram-media-registered {
  box-sizing: border-box;
  min-width: 0 !important;
  width: 100% !important;
  max-width: 100% !important;
  margin: 0 !important;
}
