/**
 * Theme Name: Blocksy Child
 * Description: Blocksy Child theme
 * Author: Creative Themes
 * Template: blocksy
 * Text Domain: blocksy
 */

:root {
    --container-width: 1300px;
    --logo-height: 2.3rem;
    --header-height: 4.5rem;
	--space-xs: 0.25rem;
    --space-xs: 0.5rem;
    --space-s: 0.75rem;
    --space-base: 1rem;
    --space-m: clamp(1.13rem, calc(1.00rem + 0.56vw), 1.50rem);
    --space-l: clamp(1.50rem, calc(1.33rem + 0.74vw), 2.00rem);
    --space-xl: clamp(2.25rem, calc(2.00rem + 1.11vw), 3.00rem);
    --space-2xl: clamp(3.00rem, calc(2.67rem + 1.48vw), 4.00rem);
    --space-3xl: clamp(3.75rem, calc(3.33rem + 1.85vw), 5.00rem);
    --space-section: clamp(4rem, 2.4681rem + 6.8085vw, 8rem);
   
    --transition: all 0.3s ease-in-out;
	
	--font-base: 1rem;
    --font-s: 0.75rem;
    --font-xs: 0.5rem;
    --font-h6: clamp(0.4375rem, 0.4136rem + 0.1064vw, 0.5rem);
    --font-h5: clamp(0.6875rem, 0.6636rem + 0.1064vw, 0.75rem);
    --font-h4: clamp(1.125rem, 1.0771rem + 0.2128vw, 1.25rem);
    --font-h3: clamp(1.25rem, 1.1543rem + 0.4255vw, 1.5rem);
    --font-h2: clamp(1.5rem, 1.3564rem + 0.6383vw, 1.875rem);
    --font-h1: clamp(2rem, 1.8085rem + 0.8511vw, 2.5rem);
    --font-hero: clamp(2rem, 1.234rem + 3.4043vw, 4rem);
}

/**************************************************
 * Basics
 * ***********************************************/
img{
	display:block;
	width:100%;
	height:auto;
}
/**************************************************
 * Animate
 * ***********************************************/
@media (prefers-reduced-motion: no-preference) {
  .animate {
    opacity: 0;
    transform: translateY(50px);
    transition: opacity 1s ease, transform 0.6s ease;
    will-change: opacity, transform;
  }

  .animate.is-visible {
    opacity: 1;
    transform: translateY(0);
  }

  /* Disable animation in the editor preview */
  .editor-styles-wrapper .animate {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
}

/**************************************************
 * Spacing for blocks placed straight into a page or post
 *
 * Blocksy's content spacing is None, so built layouts space themselves.
 * Anything dropped directly into the content - core or GB text, headings,
 * buttons, images, shapes, containers - gets the same rhythm as the
 * .smart-spacing global class (same tokens). Sections are left alone:
 * a <section>, anything with the .section class, or a full-width block
 * neither gets nor causes a gap, so a built page manages its own space.
 * .entry-content = front end, .is-root-container = block editor.
 * ***********************************************/
:is(.entry-content, .is-root-container) > :where(:not(section, .section, .alignfull, style, script)) + :not(section, .section, .alignfull, style, script) {
	margin-top: var(--space-base);
}

:is(.entry-content, .is-root-container) > :where(:not(section, .section, .alignfull, style, script)) + :not(section, .section, .alignfull, style, script):is(h1, h2, h3) {
	margin-top: var(--space-xl);
}

/**************************************************
 * Blocksy content spacing inside Woo and comments
 *
 * Global content spacing is None, which also zeroes the gaps in markup
 * Woo prints itself (form rows are <p>, so checkout, My account and the
 * login form lose their spacing). Turn Blocksy's own spacing back on there.
 * div.woocommerce = the shortcode wrapper - not body.woocommerce, which
 * would bring the gaps back across whole GB-built shop pages.
 * 1.5em = Blocksy's "Comfortable".
 * ***********************************************/
:is(div.woocommerce, .comments-area) {
	--theme-content-spacing: 1.5em;
	--has-theme-content-spacing: 1;
}
