/* PrintIQ studio – the product page is the configurator. shop.js builds this layout around the engine
   (assets/engine-<v>/css/app.css keeps the engine internals: map, line cards, range inputs). */

body.printiq-product .woocommerce-product-gallery,
body.printiq-product div.product > .summary,
body.printiq-product div.product > .woocommerce-badges { display: none !important; }
body.printiq-product .site-content { padding-top: 0; }

/* full-bleed without the scrollbar overshoot: shop.js sets --printiq-sb to the scrollbar width */
.printiq-studio { width: calc(100vw - var(--printiq-sb, 0px)); margin: 0 0 0 calc(50% - 50vw + var(--printiq-sb, 0px) / 2); background: #f2e7e1; }
.printiq-studio__head { display: none; } /* moved into the panel by shop.js; stays as fallback until then */
.printiq-studio .printiq-loading { padding: 80px 20px; text-align: center; color: #6d6d6d; }

/* ---- two columns: the studio is exactly one screen high (minus the theme header, measured by shop.js);
   the stage stays, the panel scrolls inside its own column, the price bar is always at its bottom ---- */
.printiq-studio { --printiq-stage-max: 1140px; --printiq-panel-w: 460px; }
/* four columns: beige filler · stage · panel · white filler – the composition is centred on wide screens while the
   beige runs to the left edge and the white to the right edge (no "box" in a band) */
.printiq-studio__grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, var(--printiq-stage-max)) var(--printiq-panel-w) minmax(0, 1fr); height: calc(100vh - var(--printiq-header, 0px)); min-height: 560px; }
.printiq-studio__fill--l { background: #f2e7e1; }
.printiq-studio__fill--r { background: #fff; }
.printiq-studio__stage { display: flex; flex-direction: column; align-items: center; justify-content: center; min-height: 0; padding: 40px 48px; }
.printiq-studio__panel { background: #fff; min-height: 0; display: flex; flex-direction: column; }
.printiq-studio__scroll { position: relative; flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; padding: 0 40px 24px; scroll-behavior: smooth; }
.printiq-studio__scroll::-webkit-scrollbar { width: 8px; }
.printiq-studio__scroll::-webkit-scrollbar-thumb { background: #e3dcd5; border-radius: 4px; }
.printiq-studio__head { padding-top: 32px; }

/* step navigation: sticky at the top of the scrolling panel */
.printiq-studio__nav { position: sticky; top: 0; z-index: 3; display: flex; gap: 0; margin: 0 -40px 8px; padding: 0 40px; background: #fff; border-bottom: 1px solid #ece6df; }
.printiq-studio__nav button { flex: 1; padding: 14px 0 12px; border: 0; border-bottom: 2px solid transparent; border-radius: 0; background: none; font-size: 12px; letter-spacing: .12em; text-transform: uppercase; color: #8c8c8c; cursor: pointer; }
.printiq-studio__nav button i { font-style: normal; margin-right: 6px; opacity: .6; }
.printiq-studio__nav button.is-active { color: #1a1a1a; border-bottom-color: #1a1a1a; }
.printiq-studio__nav button:hover { color: #1a1a1a; }

/* ---- the engine's preview column, restyled ---- */
.printiq-studio .hm-app { background: transparent; font-family: inherit; }
.printiq-studio .hm-app .layout { display: block; padding: 0; max-width: none; }
.printiq-studio .hm-app .topbar { display: none; }
.printiq-studio .hm-app .preview-col { position: static; width: 100%; max-width: 640px; }
.printiq-studio .hm-app .preview-wrap { background: transparent; padding: 0; border-radius: 0; min-height: 0; }
.printiq-studio .hm-app .preview { width: min(100%, calc((100vh - var(--printiq-header, 0px) - 150px) * var(--ar, 0.707))); }
.printiq-studio .hm-app .preview-wrap.mockup .preview { outline: 14px solid #141414; box-shadow: 0 30px 60px -20px rgba(0, 0, 0, .45), 0 10px 20px rgba(0, 0, 0, .12); }
.printiq-studio .hm-app .preview-foot { justify-content: center; gap: 18px; padding: 16px 0 0; font-size: 12px; letter-spacing: .04em; color: #8c8c8c; }
.printiq-studio .hm-app .preview-foot .chk { font-size: 12px; color: #8c8c8c; }
.printiq-studio .hm-app .shop-actions { display: none; } /* its pieces live in the panel and the sticky bar */

/* ---- panel head ---- */
.printiq-studio__crumb { font-size: 12px; color: #8c8c8c; margin: 0 0 14px; }
.printiq-studio__crumb a { color: #8c8c8c; }
.printiq-studio__crumb .woocommerce-breadcrumb, .printiq-studio__crumb .breadcrumb { font-size: 12px; margin: 0; }
.printiq-studio__panel h1 { margin: 0 0 8px; font-size: 30px; line-height: 1.15; }
.printiq-studio__lead { margin: 0 0 6px; color: #4a4a4a; font-size: 15px; line-height: 1.55; }
.printiq-studio__enter { margin: 0 0 30px; color: #8c8c8c; font-size: 13px; }

/* ---- steps ---- */
.printiq-step { padding: 26px 0 8px; border-top: 1px solid #ece6df; scroll-margin-top: 56px; }
.printiq-step:first-of-type { border-top: 0; }
.printiq-step__title { display: flex; align-items: baseline; gap: 12px; margin: 0 0 18px; font-size: 19px; }
.printiq-step__title i { font-style: normal; font-size: 12px; letter-spacing: .14em; color: #8c8c8c; }
.printiq-step__group { margin: 0 0 22px; }
.printiq-step__group:last-child { margin-bottom: 8px; }
.printiq-step__label { display: block; margin: 0 0 10px; font-size: 11px; letter-spacing: .14em; text-transform: uppercase; color: #6d6d6d; }

/* the engine's form controls inside the panel */
.printiq-studio .hm-app details { border: 0; border-radius: 0; background: transparent; }
.printiq-studio .hm-app summary { display: none; }
.printiq-studio .hm-app .body { padding: 0; border: 0; gap: 14px; }
.printiq-studio .hm-app label { font-size: 12px; letter-spacing: .06em; text-transform: uppercase; color: #6d6d6d; gap: 6px; }
.printiq-studio .hm-app label small { text-transform: none; letter-spacing: 0; font-size: 11px; }
.printiq-studio .hm-app label.chk { text-transform: none; letter-spacing: 0; font-size: 14px; color: #1a1a1a; }
.printiq-studio .hm-app input[type="text"], .printiq-studio .hm-app input[type="number"], .printiq-studio .hm-app input[type="date"], .printiq-studio .hm-app input[type="time"], .printiq-studio .hm-app select, .printiq-studio .hm-app textarea {
	min-height: 46px; padding: 10px 14px; border: 1px solid #e3dcd5; border-radius: 6px; background: #fff; font-size: 15px; letter-spacing: 0; text-transform: none; color: #1a1a1a;
}
.printiq-studio .hm-app input:focus, .printiq-studio .hm-app select:focus, .printiq-studio .hm-app textarea:focus { outline: none; border-color: #1a1a1a; box-shadow: 0 0 0 2px rgba(26, 26, 26, .08); }
.printiq-studio .hm-app button { border-radius: 6px; padding: 10px 14px; border-color: #e3dcd5; font-size: 13px; }
.printiq-studio .hm-app .row input { min-width: 0; }
.printiq-studio .hm-app .hint { font-size: 12px; color: #8c8c8c; line-height: 1.5; }
.printiq-studio .hm-app .line-card { border: 0; border-radius: 0; padding: 0; background: transparent; gap: 8px; }
.printiq-studio .hm-app .line-card .grid3 { display: none; }
.printiq-studio .hm-app .line-head strong { font-weight: 400; font-size: 12px; letter-spacing: .06em; text-transform: uppercase; color: #6d6d6d; }
.printiq-studio .hm-app .line-tools { display: none; }
.printiq-studio .hm-app #map { height: 300px; border-radius: 8px; }
.printiq-studio .hm-app #btnMapToggle, .printiq-studio .hm-app #btnGeocode { white-space: nowrap; }
.printiq-studio .hm-app label.file { border-radius: 6px; padding: 14px; justify-content: center; background: #faf7f4; font-size: 13px; letter-spacing: 0; text-transform: none; color: #1a1a1a; }

/* a group whose engine section is hidden for this module disappears with it */
.printiq-step__group:has(> details[hidden]), .printiq-step__group[hidden] { display: none; }

/* advanced controls: hidden until "Viac možností" */
.printiq-step .is-advanced { display: none !important; }
.printiq-step.is-open .is-advanced { display: flex !important; }
.printiq-step.is-open .is-advanced.grid2, .printiq-step.is-open .is-advanced.grid3, .printiq-step.is-open .is-advanced.colors { display: grid !important; }
.printiq-step.is-open .hm-app .line-card .grid3 { display: grid; }
.printiq-studio .hm-app .printiq-step__more { display: inline-block; margin: 4px 0 16px; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: #1a1a1a; border-bottom: 1px solid #1a1a1a; cursor: pointer; background: none; padding: 0; }
.printiq-studio .hm-app .printiq-step__more::after { content: ' +'; }
.printiq-step.is-open .printiq-step__more::after { content: ' –'; }

/* chips, swatches */
.printiq-chips-row { display: flex; flex-wrap: wrap; gap: 8px; }
.printiq-studio .hm-app .printiq-chip { padding: 9px 16px; border: 1px solid #e3dcd5; border-radius: 999px; background: #fff; font-size: 13px; color: #1a1a1a; cursor: pointer; line-height: 1.2; transition: border-color .15s, background .15s; }
.printiq-studio .hm-app .printiq-chip:hover { border-color: #1a1a1a; }
.printiq-studio .hm-app .printiq-chip.is-active { background: #1a1a1a; border-color: #1a1a1a; color: #fff; }
.printiq-studio .hm-app .printiq-chip small { display: block; font-size: 11px; opacity: .7; margin-top: 2px; }
.printiq-chip--format { min-width: 96px; text-align: center; padding: 10px 14px; border-radius: 8px; }
.printiq-swatches { display: flex; flex-wrap: wrap; gap: 10px; }
.printiq-studio .hm-app .printiq-swatch { position: relative; width: 40px; height: 40px; border-radius: 50%; border: 1px solid rgba(0, 0, 0, .12); cursor: pointer; padding: 0; background: linear-gradient(135deg, var(--a) 0 50%, var(--b) 50% 100%); box-shadow: inset 0 0 0 2px #fff; }
.printiq-studio .hm-app .printiq-swatch.is-active { box-shadow: inset 0 0 0 2px #fff, 0 0 0 2px #1a1a1a; }
.printiq-studio .hm-app .printiq-swatch[title]:hover::after { content: attr(title); position: absolute; left: 50%; top: 100%; transform: translateX(-50%); margin-top: 6px; padding: 4px 8px; background: #1a1a1a; color: #fff; font-size: 11px; white-space: nowrap; border-radius: 4px; z-index: 2; }
.printiq-fonts { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; }
.printiq-studio .hm-app .printiq-font { padding: 12px 14px; border: 1px solid #e3dcd5; border-radius: 6px; background: #fff; text-align: left; cursor: pointer; font-size: 13px; color: #1a1a1a; }
.printiq-studio .hm-app .printiq-font.is-active { border-color: #1a1a1a; box-shadow: inset 0 0 0 1px #1a1a1a; }
.printiq-studio .hm-app .printiq-font small { display: block; color: #8c8c8c; font-size: 11px; margin-top: 2px; }

/* quality cards (engine fieldset restyled) */
.printiq-studio .hm-app .printiq-quality { gap: 8px; }
.printiq-studio .hm-app .printiq-quality legend { display: none; }
.printiq-studio .hm-app .printiq-quality-option { padding: 12px 14px; border-radius: 8px; border-color: #e3dcd5; }
.printiq-studio .hm-app .printiq-quality-option.is-active { border-color: #1a1a1a; box-shadow: inset 0 0 0 1px #1a1a1a; }

/* "Začať odznova" (engine reset) as a quiet link at the end of step 3 */
.printiq-studio .hm-app .shop-reset { justify-content: flex-start; margin: 8px 0 0; }
.printiq-studio .hm-app .shop-reset button { padding: 0; border: 0; background: none; color: #8c8c8c; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; border-bottom: 1px solid #c9c2bb; border-radius: 0; }
.printiq-studio .hm-app .shop-reset button:hover { color: #1a1a1a; border-color: #1a1a1a; }

/* skeleton (server-side HTML until shop.js mounts the engine) – same grid, shimmering poster and lines */
@keyframes printiq-shimmer { 0% { background-position: -400px 0; } 100% { background-position: 400px 0; } }
.printiq-skel .printiq-studio__stage { justify-content: center; }
.printiq-skel__poster { width: min(100%, calc((100vh - var(--printiq-header, 0px) - 230px) * 0.707)); max-width: 640px; aspect-ratio: 0.707; background: #fff; outline: 14px solid #141414; box-shadow: 0 30px 60px -20px rgba(0, 0, 0, .45), 0 10px 20px rgba(0, 0, 0, .12); }
.printiq-skel__note { margin: 26px 0 0; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: #8c8c8c; }
.printiq-skel__bar { height: 2px; background: linear-gradient(90deg, #ece6df 0%, #1a1a1a 50%, #ece6df 100%); background-size: 800px 2px; animation: printiq-shimmer 1.4s linear infinite; }
.printiq-skel .printiq-studio__scroll { overflow: hidden; }
.printiq-skel .printiq-studio__head { padding-top: 32px; }
.printiq-skel__line, .printiq-skel__field { height: 12px; margin: 0 0 14px; border-radius: 6px; background: linear-gradient(90deg, #f3efea 0%, #e9e2db 50%, #f3efea 100%); background-size: 800px 100%; animation: printiq-shimmer 1.6s linear infinite; }
.printiq-skel__line:nth-child(odd) { width: 60%; }
.printiq-skel__field { height: 46px; margin: 6px 0 18px; }
@media (max-width: 860px) {
	.printiq-skel { display: block; }
	.printiq-skel .printiq-studio__panel { display: none; }
	.printiq-skel .printiq-studio__mhead { display: block; }
	.printiq-skel__poster { width: min(100%, calc((100vh - var(--printiq-header, 0px) - 300px) * 0.707)); outline-width: 10px; }
}

/* phone-only controls (bottom sheet) and the title above the art */
.printiq-studio__edit, .printiq-studio__close, .printiq-studio__mhead { display: none; }
@media (max-width: 860px) { .printiq-studio__edit, .printiq-studio__close { display: block; } }

/* sticky bar */
.printiq-studio__bar { position: relative; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 16px 40px; background: #fff; border-top: 1px solid #ece6df; box-shadow: 0 -12px 30px rgba(0, 0, 0, .05); }
.printiq-studio__price { display: flex; flex-direction: column; }
.printiq-studio__price strong { font-size: 24px; line-height: 1.1; }
.printiq-studio__price span { font-size: 12px; color: #8c8c8c; }
.printiq-studio__bar .printiq-add { margin: 0; width: auto; min-width: 220px; padding: 15px 28px; border-radius: 0; font-size: 13px; letter-spacing: .12em; text-transform: uppercase; font-weight: 400; }
.printiq-studio__bar .printiq-msg { position: absolute; left: 40px; right: 40px; bottom: 100%; margin: 0 0 8px; padding: 8px 12px; background: #fff; border: 1px solid #e3dcd5; font-size: 13px; }
.printiq-studio__note { margin: 0; font-size: 12px; color: #8c8c8c; }
.printiq-studio__hint { margin: 10px 0 0; font-size: 12px; color: #8c8c8c; line-height: 1.5; }

/* ---- wide screens: bigger composition, the panel grows with the screen ---- */
@media (min-width: 1700px) {
	.printiq-studio { --printiq-stage-max: 1400px; --printiq-panel-w: 560px; }
	.printiq-studio .hm-app .preview-col { max-width: 820px; }
	.printiq-studio__panel { zoom: 1.08; }
}
@media (min-width: 2300px) {
	.printiq-studio { --printiq-stage-max: 1750px; --printiq-panel-w: 640px; }
	.printiq-studio .hm-app .preview-col { max-width: 1040px; }
	.printiq-studio__stage { padding: 56px 64px; }
	.printiq-studio__panel { zoom: 1.2; }
}
@media (min-width: 3300px) {
	.printiq-studio { --printiq-stage-max: 2100px; --printiq-panel-w: 720px; }
	.printiq-studio .hm-app .preview-col { max-width: 1240px; }
	.printiq-studio__panel { zoom: 1.35; }
}

/* ---- responsive ---- */
@media (max-width: 1100px) {
	.printiq-studio__grid { grid-template-columns: minmax(0, 1fr) 400px; }
	.printiq-studio__scroll, .printiq-studio__bar { padding-left: 28px; padding-right: 28px; }
	.printiq-studio__stage { padding: 40px 28px; }
}
@media (max-width: 860px) {
	/* phone: the art fills the screen above a fixed bar; the panel is a bottom sheet (Upraviť) over ~half of the
	   screen, the art shrinks above it so every change is still visible */
	.printiq-studio { --printiq-bar: 76px; --printiq-sheet: 54vh; }
	.printiq-studio__grid { display: block; height: auto; min-height: 0; }
	.printiq-studio__fill--l, .printiq-studio__fill--r { display: none; }
	.printiq-studio__stage { display: flex; flex-direction: column; justify-content: center; align-items: center; min-height: 0; height: calc(100vh - var(--printiq-header, 0px) - var(--printiq-bar)); padding: 16px 20px 20px; transition: height .3s ease; }
	.printiq-studio .hm-app .preview-col { max-width: 100%; }
	.printiq-studio .hm-app .preview { width: min(100%, calc((100vh - var(--printiq-header, 0px) - var(--printiq-bar) - 150px) * var(--ar, 0.707))); transition: width .3s ease; }
	.printiq-studio .hm-app .preview-wrap.mockup .preview { outline-width: 10px; }
	.printiq-studio .hm-app .preview-foot .status { display: none; }
	.printiq-studio__mhead { display: block; width: 100%; margin: 0 0 12px; text-align: center; }
	.printiq-studio__mhead h1 { margin: 0 0 4px; font-size: 22px; line-height: 1.2; }
	.printiq-studio__mhead p { margin: 0; font-size: 13px; color: #6d6d6d; line-height: 1.5; }
	.printiq-studio__head { display: none !important; }

	.printiq-studio__panel { position: fixed; left: 0; right: 0; bottom: var(--printiq-bar); z-index: 49; height: var(--printiq-sheet); min-height: 0; border-radius: 18px 18px 0 0; box-shadow: 0 -16px 40px rgba(0, 0, 0, .14); transform: translateY(calc(100% + var(--printiq-bar))); transition: transform .32s cubic-bezier(.2, .7, .2, 1); }
	body.printiq-sheet-open .printiq-studio__panel { transform: translateY(0); }
	body.printiq-sheet-open .printiq-studio__stage { height: calc(100vh - var(--printiq-header, 0px) - var(--printiq-bar) - var(--printiq-sheet)); }
	body.printiq-sheet-open .printiq-studio .hm-app .preview { width: min(100%, calc((100vh - var(--printiq-header, 0px) - var(--printiq-bar) - var(--printiq-sheet) - 70px) * var(--ar, 0.707))); }
	body.printiq-sheet-open .printiq-studio .hm-app .preview-foot { display: none; }
	body.printiq-sheet-open .printiq-studio__mhead { display: none; }
	.printiq-studio__scroll { overflow-y: auto; padding: 0 20px 24px; }
	.printiq-studio__nav { margin: 0 -20px 8px; padding: 10px 56px 0 20px; }
	.printiq-studio__nav::before { content: ''; position: absolute; left: 50%; top: 6px; width: 40px; height: 4px; margin-left: -20px; border-radius: 2px; background: #e3dcd5; }
	.printiq-studio__close { position: absolute; right: 12px; top: 10px; width: 36px; height: 36px; border: 0; border-radius: 50%; background: #f2e7e1; color: #1a1a1a; font-size: 18px; line-height: 36px; text-align: center; cursor: pointer; }

	.printiq-studio__bar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 50; height: var(--printiq-bar); padding: 10px 16px; gap: 10px; }
	.printiq-studio__bar .printiq-add { min-width: 0; flex: 1; padding: 13px 14px; }
	.printiq-studio__edit { flex: 0 0 auto; padding: 13px 16px; border: 1px solid #1a1a1a; background: #fff; color: #1a1a1a; font-size: 12px; letter-spacing: .1em; text-transform: uppercase; cursor: pointer; }
	body.printiq-sheet-open .printiq-studio__edit { background: #1a1a1a; color: #fff; }
	.printiq-studio__bar .printiq-msg { left: 16px; right: 16px; }
	.printiq-studio__price strong { font-size: 19px; }
	.printiq-studio__price span { font-size: 11px; }
	body.printiq-product { padding-bottom: var(--printiq-bar, 76px); }
	.printiq-fonts { grid-template-columns: 1fr; }
}
