/* Andia of IYD: punk layer on top of theme.json */

:root {
	--iyd-pink: var(--wp--preset--color--pink, #ff2e93);
	--iyd-green: var(--wp--preset--color--green, #39ff14);
	--iyd-base: var(--wp--preset--color--base, #101010);
	--iyd-surface: var(--wp--preset--color--surface, #1b1b1d);
	--iyd-contrast: var(--wp--preset--color--contrast, #f2f2ee);
}

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

/* Scanlines: a quiet CRT texture over everything. */
body::after {
	content: "";
	position: fixed;
	inset: 0;
	pointer-events: none;
	z-index: 9999;
	background: repeating-linear-gradient(0deg, rgba(128, 128, 128, 0.05) 0 1px, transparent 1px 4px);
}
.editor-styles-wrapper::after { display: none; }

/* Keyboard focus you can actually see. */
:where(a, button, input, select, textarea, summary):focus-visible,
.wp-block-button__link:focus-visible {
	outline: 3px solid var(--iyd-green);
	outline-offset: 3px;
}

/* ---------- Type helpers ---------- */
.has-glitch-font-family { text-transform: none; letter-spacing: 0; font-weight: 400; }

.wp-block-heading.is-style-glitch,
.iyd-glitch {
	text-shadow: -3px 0 var(--iyd-pink), 3px 0 var(--iyd-green);
}
.wp-block-heading.is-style-stamp {
	display: inline-block;
	border: 4px solid currentColor;
	padding: 0.15em 0.4em;
	transform: rotate(-2deg);
	text-transform: uppercase;
}
p.is-style-mono-label {
	font-family: var(--wp--preset--font-family--mono);
	font-size: var(--wp--preset--font-size--small);
	letter-spacing: 0.01em;
}

/* One orchestrated moment: the hero title glitches in short bursts. */
@keyframes iyd-burst {
	0%, 88%, 100% { transform: none; text-shadow: -3px 0 var(--iyd-pink), 3px 0 var(--iyd-green); }
	90% { transform: translate(-5px, 0) skewX(-5deg); text-shadow: 7px 0 var(--iyd-pink), -7px 0 var(--iyd-green); }
	92% { transform: translate(6px, -2px) skewX(4deg); text-shadow: -9px 0 var(--iyd-pink), 9px 0 var(--iyd-green); }
	94% { transform: translate(-2px, 1px); text-shadow: 4px 0 var(--iyd-pink), -4px 0 var(--iyd-green); }
}
.iyd-hero-title {
	text-shadow: -3px 0 var(--iyd-pink), 3px 0 var(--iyd-green);
	animation: iyd-burst 7s steps(1, end) infinite;
	overflow-wrap: anywhere;
}
@media (prefers-reduced-motion: reduce) { .iyd-hero-title { animation: none; } }

/* ---------- Group styles ---------- */
.wp-block-group.is-style-sticker {
	transform: rotate(-2deg);
	box-shadow: 6px 6px 0 var(--iyd-green);
	border: 3px solid var(--iyd-base);
	width: fit-content;
	max-width: 100%;
}
.wp-block-group.is-style-sticker:not([class*="has-background"]) { background: var(--iyd-pink); color: var(--iyd-base); }

.wp-block-group.is-style-panel {
	background: var(--iyd-surface);
	border: 3px solid var(--iyd-contrast);
	box-shadow: 8px 8px 0 var(--iyd-pink);
}

.wp-block-group.is-style-torn-top {
	clip-path: polygon(0 10px, 4% 0, 9% 11px, 14% 2px, 20% 12px, 27% 3px, 33% 10px, 40% 0, 47% 12px, 54% 3px, 61% 10px, 68% 2px, 75% 12px, 82% 0, 89% 10px, 95% 3px, 100% 9px, 100% 100%, 0 100%);
	padding-top: calc(var(--wp--preset--spacing--60) + 12px);
}
.wp-block-group.is-style-torn-bottom {
	clip-path: polygon(0 0, 100% 0, 100% calc(100% - 9px), 95% calc(100% - 2px), 89% 100%, 82% calc(100% - 10px), 75% calc(100% - 1px), 68% 100%, 61% calc(100% - 9px), 54% calc(100% - 1px), 47% 100%, 40% calc(100% - 10px), 33% calc(100% - 2px), 27% 100%, 20% calc(100% - 9px), 14% calc(100% - 1px), 9% 100%, 4% calc(100% - 10px), 0 calc(100% - 3px));
	padding-bottom: calc(var(--wp--preset--spacing--60) + 12px);
}
.wp-block-group.iyd-torn-both {
	clip-path: polygon(0 10px, 4% 0, 9% 11px, 14% 2px, 20% 12px, 27% 3px, 33% 10px, 40% 0, 47% 12px, 54% 3px, 61% 10px, 68% 2px, 75% 12px, 82% 0, 89% 10px, 95% 3px, 100% 9px, 100% calc(100% - 9px), 95% calc(100% - 2px), 89% 100%, 82% calc(100% - 10px), 75% calc(100% - 1px), 68% 100%, 61% calc(100% - 9px), 54% calc(100% - 1px), 47% 100%, 40% calc(100% - 10px), 33% calc(100% - 2px), 27% 100%, 20% calc(100% - 9px), 14% calc(100% - 1px), 9% 100%, 4% calc(100% - 10px), 0 calc(100% - 3px));
}
.wp-block-group.is-style-halftone,
.iyd-halftone {
	background-image: radial-gradient(var(--iyd-surface) 1.6px, transparent 1.8px);
	background-size: 14px 14px;
}

/* ---------- Images ---------- */
.wp-block-image.is-style-holo-frame img {
	border: 8px solid transparent;
	border-image: var(--wp--preset--gradient--hologram) 1;
	background: var(--iyd-base);
}
.wp-block-image.is-style-glitch-frame img {
	box-shadow: -8px 8px 0 var(--iyd-pink), 8px -8px 0 var(--iyd-green);
}
.wp-block-image.is-style-taped { position: relative; transform: rotate(1.5deg); }
.wp-block-image.is-style-taped::before {
	content: "";
	position: absolute;
	top: -14px;
	left: 50%;
	width: 110px;
	height: 30px;
	margin-left: -55px;
	background: rgba(255, 46, 147, 0.78);
	transform: rotate(-3deg);
	z-index: 2;
}

/* ---------- Buttons ---------- */
.wp-block-button__link {
	transition: transform 0.08s ease, box-shadow 0.08s ease, background-color 0.12s ease;
}
.wp-block-button__link:hover,
.wp-block-button__link:focus-visible {
	transform: translate(3px, 3px);
	box-shadow: 3px 3px 0 var(--iyd-green);
}
.wp-block-button.is-style-outline-punk .wp-block-button__link {
	background: transparent;
	color: var(--iyd-contrast);
	border: 3px solid var(--iyd-contrast);
	box-shadow: 6px 6px 0 var(--iyd-pink);
}
.wp-block-button.is-style-outline-punk .wp-block-button__link:hover,
.wp-block-button.is-style-outline-punk .wp-block-button__link:focus-visible {
	background: var(--iyd-contrast);
	color: var(--iyd-base);
}
@media (prefers-reduced-motion: reduce) { .wp-block-button__link { transition: none; } }

/* ---------- Separator ---------- */
.wp-block-separator.is-style-hologram-bar {
	height: 10px;
	border: 0;
	width: 100%;
	max-width: none;
	background: var(--wp--preset--gradient--hologram);
	opacity: 1;
}

/* ---------- Ticker ---------- */
.iyd-ticker {
	overflow: hidden;
	border-top: 3px solid var(--iyd-base);
	border-bottom: 3px solid var(--iyd-base);
	white-space: nowrap;
}
.iyd-ticker .iyd-ticker__track {
	display: inline-block;
	margin: 0;
	padding: 0.45rem 0;
	font-family: var(--wp--preset--font-family--mono);
	font-weight: 700;
	font-size: var(--wp--preset--font-size--small);
	animation: iyd-marquee 38s linear infinite;
}
.iyd-ticker:hover .iyd-ticker__track { animation-play-state: paused; }
@keyframes iyd-marquee { from { transform: translateX(0); } to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) {
	.iyd-ticker { overflow-x: auto; }
	.iyd-ticker .iyd-ticker__track { animation: none; }
}

/* ---------- Layout helpers used by patterns ---------- */
.iyd-card {
	background: var(--iyd-surface);
	border: 3px solid var(--iyd-contrast);
	height: 100%;
}
.iyd-card h3 { margin-top: 0; }
.iyd-tilt-l { transform: rotate(-1.2deg); }
.iyd-tilt-r { transform: rotate(1.2deg); }
@media (max-width: 781px) { .iyd-tilt-l, .iyd-tilt-r { transform: none; } }
.iyd-timeline { border-left: 4px solid var(--iyd-pink); padding-left: var(--wp--preset--spacing--40); }
.iyd-timeline > .wp-block-group { position: relative; }
.iyd-timeline > .wp-block-group::before {
	content: "";
	position: absolute;
	left: calc(-1 * var(--wp--preset--spacing--40) - 12px);
	top: 0.5rem;
	width: 16px;
	height: 16px;
	background: var(--iyd-green);
	border: 3px solid var(--iyd-base);
}
.iyd-social .wp-social-link { transition: none; }

/* ---------- Header / footer ---------- */
.iyd-header { border-bottom: 3px solid var(--iyd-pink); }
.iyd-footer { border-top: 10px solid transparent; border-image: var(--wp--preset--gradient--hologram) 1; }

/* ---------- Forms ---------- */
input[type="text"], input[type="email"], input[type="search"], input[type="tel"],
input[type="url"], input[type="password"], input[type="number"], textarea, select,
.wp-block-search__input {
	background: var(--iyd-surface);
	color: var(--iyd-contrast);
	border: 3px solid var(--iyd-contrast);
	border-radius: 0;
	padding: 0.65rem 0.8rem;
	font: inherit;
}

/* ---------- Posts ---------- */
.wp-block-post-template.is-layout-grid > li { border: 3px solid var(--iyd-contrast); background: var(--iyd-surface); padding: var(--wp--preset--spacing--40); }
.wp-block-post-date, .wp-block-post-terms { font-family: var(--wp--preset--font-family--mono); font-size: var(--wp--preset--font-size--small); }

/* ---------- WooCommerce ---------- */
.woocommerce a.button, .woocommerce button.button, .woocommerce input.button,
.woocommerce #respond input#submit, .woocommerce a.button.alt, .woocommerce button.button.alt,
.wc-block-components-button:not(.is-link), .wc-block-grid__product-add-to-cart .wp-block-button__link {
	background: var(--iyd-pink);
	color: var(--iyd-base);
	border: 3px solid var(--iyd-base);
	border-radius: 0;
	box-shadow: 6px 6px 0 var(--iyd-green);
	font-weight: 700;
	padding: 0.8rem 1.5rem;
}
.woocommerce a.button:hover, .woocommerce button.button:hover, .woocommerce a.button.alt:hover,
.woocommerce button.button.alt:hover, .wc-block-components-button:not(.is-link):hover {
	background: var(--iyd-green);
	color: var(--iyd-base);
	transform: translate(3px, 3px);
	box-shadow: 3px 3px 0 var(--iyd-pink);
}
.woocommerce ul.products li.product, .wc-block-grid__product, .wc-block-product {
	background: var(--iyd-surface);
	border: 3px solid var(--iyd-contrast);
	padding: 1rem;
}
.woocommerce ul.products li.product .woocommerce-loop-product__title,
.wc-block-grid__product-title { font-weight: 700; color: var(--iyd-contrast); }
.woocommerce .price, .woocommerce div.product p.price, .woocommerce ul.products li.product .price,
.wc-block-grid__product-price, .wc-block-components-product-price {
	font-family: var(--wp--preset--font-family--mono);
	font-weight: 700;
	color: var(--iyd-green);
}
.woocommerce .price del, .wc-block-components-product-price del { color: var(--wp--preset--color--muted); }
.woocommerce span.onsale, .wc-block-components-product-sale-badge {
	background: var(--iyd-green);
	color: var(--iyd-base);
	border: 3px solid var(--iyd-base);
	border-radius: 0;
	transform: rotate(-6deg);
	font-weight: 700;
	min-height: 0;
	min-width: 0;
	line-height: 1.2;
	padding: 0.3rem 0.7rem;
}
.woocommerce-message, .woocommerce-info, .woocommerce-error, .wc-block-components-notice-banner {
	background: var(--iyd-surface);
	color: var(--iyd-contrast);
	border: 3px solid var(--iyd-pink);
	border-radius: 0;
}
.woocommerce table.shop_table, .woocommerce table.shop_table td, .woocommerce table.shop_table th {
	border-color: var(--iyd-contrast);
	border-radius: 0;
}
.woocommerce-breadcrumb, .woocommerce-result-count { font-family: var(--wp--preset--font-family--mono); font-size: var(--wp--preset--font-size--small); }
.wc-block-mini-cart__badge { background: var(--iyd-green); color: var(--iyd-base); border-radius: 0; }
.wc-block-components-text-input input, .wc-block-components-combobox .components-combobox-control__input,
.wc-blocks-components-select__select { background: var(--iyd-surface); color: var(--iyd-contrast); border-radius: 0; }
.woocommerce div.product .woocommerce-tabs ul.tabs li { background: var(--iyd-surface); border-radius: 0; border-color: var(--iyd-contrast); }
.woocommerce div.product .woocommerce-tabs ul.tabs li.active { background: var(--iyd-pink); }
.woocommerce div.product .woocommerce-tabs ul.tabs li.active a { color: var(--iyd-base); }
