/*
Theme Name:   BLOND:ISH
Theme URI:    https://blondish.world
Author:       BLOND:ISH
Author URI:   https://blondish.world
Description:  WordPress Full Site Editing (FSE) block theme for blondish.world
Version:      2.0.0
Requires at least: 6.4
Requires PHP: 8.0
License:      Private
Text Domain:  blondish
*/

/*
 * A24-inspired design: monochrome, editorial minimalism.
 * Photography dominates; typography and layout recede.
 *
 * Most visual styling lives in theme.json.
 * This file handles: pseudo-elements, animations, hover effects,
 * navigation drawer, third-party embed overrides, focus styles.
 */

/* ==========================================================================
   CUSTOM PROPERTIES
   ========================================================================== */

:root {
	--transition-fast: 0.15s cubic-bezier(0.25, 0.1, 0.25, 1);
	--transition-medium: 0.25s cubic-bezier(0.25, 0.1, 0.25, 1);
	--nav-drawer-width: 500px;
}

/* ==========================================================================
   BASE RESETS
   ========================================================================== */

*,
*::before,
*::after {
	box-sizing: border-box;
}

html {
	scroll-behavior: smooth;
}

body {
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
}

img,
video {
	max-width: 100%;
	height: auto;
	display: block;
}

/* ==========================================================================
   ACCESSIBILITY — SKIP TO CONTENT
   ========================================================================== */

.skip-to-content {
	position: absolute;
	top: -100%;
	left: 1rem;
	z-index: 9999;
	padding: 0.5rem 1rem;
	background: var(--wp--preset--color--black);
	color: var(--wp--preset--color--white);
	font-family: var(--wp--preset--font-family--heading);
	font-weight: 500;
	text-transform: uppercase;
	letter-spacing: 0.05em;
	font-size: var(--wp--preset--font-size--xs);
	text-decoration: none;
	transition: top var(--transition-fast);
}

.skip-to-content:focus {
	top: 1rem;
	outline: 2px solid var(--wp--preset--color--black);
	outline-offset: 2px;
}

/* ==========================================================================
   FOCUS STYLES — WCAG 2.1 AA
   ========================================================================== */

:focus-visible {
	outline: 2px solid var(--wp--preset--color--black);
	outline-offset: 3px;
}

:focus:not(:focus-visible) {
	outline: none;
}

/* On dark backgrounds, invert focus ring */
.has-black-background-color :focus-visible,
.wp-block-cover :focus-visible {
	outline-color: var(--wp--preset--color--white);
}

/* ==========================================================================
   LINKS — A24-style underline on hover
   ========================================================================== */

.wp-block-paragraph a,
.wp-block-list a,
.entry-content a:not(.wp-block-button__link) {
	text-decoration: none;
	border-bottom: 1px solid transparent;
	transition: border-color var(--transition-fast);
}

.wp-block-paragraph a:hover,
.wp-block-list a:hover,
.entry-content a:not(.wp-block-button__link):hover {
	border-bottom-color: currentColor;
}

/* ==========================================================================
   BUTTONS — outline style, A24 aesthetic
   ========================================================================== */

.wp-block-button__link {
	transition: background-color var(--transition-fast),
	            color var(--transition-fast);
}

/* Outline (default) variant */
.wp-block-button:not(.is-style-fill) .wp-block-button__link {
	background: transparent;
	border: 1px solid var(--wp--preset--color--black);
	color: var(--wp--preset--color--black);
}

.wp-block-button:not(.is-style-fill) .wp-block-button__link:hover {
	background: var(--wp--preset--color--black);
	color: var(--wp--preset--color--white);
}

/* On dark backgrounds */
.has-black-background-color .wp-block-button:not(.is-style-fill) .wp-block-button__link,
.wp-block-cover .wp-block-button:not(.is-style-fill) .wp-block-button__link {
	border-color: var(--wp--preset--color--white);
	color: var(--wp--preset--color--white);
}

.has-black-background-color .wp-block-button:not(.is-style-fill) .wp-block-button__link:hover,
.wp-block-cover .wp-block-button:not(.is-style-fill) .wp-block-button__link:hover {
	background: var(--wp--preset--color--white);
	color: var(--wp--preset--color--black);
}

/* Touch targets — WCAG 2.5.5 */
.wp-block-button__link,
.wp-block-navigation__responsive-container-open,
.wp-block-navigation__responsive-container-close {
	min-height: 44px;
	min-width: 44px;
}

/* ==========================================================================
   FULL-WIDTH SECTIONS
   ========================================================================== */

.wp-block-cover.alignfull,
.wp-block-group.alignfull {
	max-width: 100% !important;
	width: 100vw !important;
	margin-left: calc(50% - 50vw) !important;
	margin-right: calc(50% - 50vw) !important;
}

/* ==========================================================================
   COVER BLOCK
   ========================================================================== */

.wp-block-cover {
	min-height: 85vh;
}

.wp-block-cover.is-homepage-hero {
	min-height: 95vh;
}

.wp-block-cover__inner-container {
	width: 100%;
	max-width: var(--wp--style--global--wide-size, 1400px);
	margin-left: auto;
	margin-right: auto;
	padding-left: 1.5rem;
	padding-right: 1.5rem;
}

/* ==========================================================================
   EYEBROW LABELS — A24 pattern: small caps label above headings
   ========================================================================== */

.eyebrow,
.wp-block-group.is-style-eyebrow > p:first-child {
	font-family: var(--wp--preset--font-family--heading);
	font-size: var(--wp--preset--font-size--xs);
	font-weight: 500;
	text-transform: uppercase;
	letter-spacing: 0.05em;
	color: var(--wp--preset--color--mid-grey);
	margin-bottom: 0.75rem;
}

/* ==========================================================================
   HEADER / NAVIGATION — clean, transparent, A24-style
   ========================================================================== */

.site-header {
	z-index: 100;
	transition: background-color var(--transition-medium),
	            box-shadow var(--transition-medium);
}

/* Scrolled state — add subtle shadow */
.site-header.is-scrolled {
	box-shadow: 0 1px 0 rgba(0, 0, 0, 0.08);
}

/* Navigation overlay (mobile menu / drawer) */
.wp-block-navigation__responsive-container.is-menu-open {
	background-color: var(--wp--preset--color--black);
}

/* Nav links in drawer */
.wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation-item__content {
	font-size: clamp(2rem, 5vw, 4.625rem);
	font-weight: 400;
	letter-spacing: -0.03em;
	text-transform: uppercase;
	color: var(--wp--preset--color--white);
	padding: 0.25em 0;
	display: inline-block;
	border-bottom: 1px solid transparent;
	transition: border-color var(--transition-fast);
}

.wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation-item__content:hover {
	border-bottom-color: var(--wp--preset--color--white);
}

/* Hamburger icon */
.wp-block-navigation__responsive-container-open svg {
	fill: var(--wp--preset--color--black);
	width: 24px;
	height: 24px;
}

.wp-block-navigation__responsive-container-close svg {
	fill: var(--wp--preset--color--white);
}

/* Desktop nav link hover */
.wp-block-navigation-item__content {
	border-bottom: 1px solid transparent;
	transition: border-color var(--transition-fast);
	padding-bottom: 2px;
}

.wp-block-navigation-item__content:hover {
	border-bottom-color: currentColor;
}

/* ==========================================================================
   IMAGES — lazy loading fade-in
   ========================================================================== */

img[loading="lazy"] {
	opacity: 0;
	transition: opacity 0.3s ease;
}

img[loading="lazy"].loaded,
img.wp-post-image {
	opacity: 1;
}

/* ==========================================================================
   POST / QUERY LOOP — A24-style film card grid
   ========================================================================== */

.wp-block-post-featured-image {
	overflow: hidden;
}

.wp-block-post-featured-image img {
	transition: transform 0.3s ease;
}

.wp-block-post:hover .wp-block-post-featured-image img {
	transform: scale(1.02);
}

/* Card title — clean hover underline */
.wp-block-post .wp-block-post-title a {
	border-bottom: 1px solid transparent;
	transition: border-color var(--transition-fast);
}

.wp-block-post .wp-block-post-title a:hover {
	border-bottom-color: currentColor;
}

/* Post meta / date — A24 eyebrow style */
.wp-block-post-date,
.wp-block-post-terms {
	font-size: var(--wp--preset--font-size--xs);
	text-transform: uppercase;
	letter-spacing: 0.05em;
	color: var(--wp--preset--color--mid-grey);
}

/* ==========================================================================
   SECTIONS — generous vertical rhythm like A24
   ========================================================================== */

.homepage-section {
	padding-top: var(--wp--preset--spacing--2xl);
	padding-bottom: var(--wp--preset--spacing--2xl);
}

.homepage-section + .homepage-section {
	border-top: 1px solid var(--wp--preset--color--light-grey);
}

/* ==========================================================================
   DARK SECTIONS — invert colors for contrast blocks
   ========================================================================== */

.has-black-background-color {
	color: var(--wp--preset--color--white);
}

.has-black-background-color h1,
.has-black-background-color h2,
.has-black-background-color h3,
.has-black-background-color h4,
.has-black-background-color a {
	color: var(--wp--preset--color--white);
}

.has-black-background-color .eyebrow,
.has-black-background-color .wp-block-group.is-style-eyebrow > p:first-child {
	color: var(--wp--preset--color--mid-grey);
}

/* ==========================================================================
   LITE-YOUTUBE-EMBED
   ========================================================================== */

lite-youtube {
	max-width: 100%;
	border-radius: 0;
}

/* ==========================================================================
   SEATED EMBED — placeholder
   ========================================================================== */

#seated-placeholder:empty::after {
	content: 'Loading tour dates\2026';
	display: block;
	text-align: center;
	padding: 2rem;
	color: var(--wp--preset--color--mid-grey);
	font-family: var(--wp--preset--font-family--heading);
	font-size: var(--wp--preset--font-size--xs);
	letter-spacing: 0.05em;
	text-transform: uppercase;
}

/* ==========================================================================
   SHOPIFY PLACEHOLDER
   ========================================================================== */

#shopify-placeholder:empty::after {
	content: 'Loading store\2026';
	display: block;
	text-align: center;
	padding: 2rem;
	color: var(--wp--preset--color--mid-grey);
	font-family: var(--wp--preset--font-family--heading);
	font-size: var(--wp--preset--font-size--xs);
	letter-spacing: 0.05em;
	text-transform: uppercase;
}

/* ==========================================================================
   EVENT LINKS
   ========================================================================== */

.events-hero__list-item {
	transition: background-color var(--transition-fast);
}

.events-hero__list-venue,
.events-hero__venue a {
	transition: color var(--transition-fast);
}

/* ==========================================================================
   MUSIC RELEASES GRID — square cover images
   ========================================================================== */

.music-releases-grid,
.music-archive-grid {
	gap: var(--wp--preset--spacing--sm) !important;
}

/* Square image cards */
.music-release-card .wp-block-post-featured-image {
	overflow: hidden;
}

.music-release-card .wp-block-post-featured-image img {
	aspect-ratio: 1 / 1;
	object-fit: cover;
	width: 100%;
	height: auto;
	transition: transform 0.3s ease, filter 0.3s ease;
}

.music-release-card:hover .wp-block-post-featured-image img {
	transform: scale(1.03);
	filter: brightness(0.92);
}

/* Homepage grid: 4 columns → 2 on tablet → 2 on mobile */
.music-releases-grid {
	grid-template-columns: repeat(4, 1fr) !important;
}

@media (max-width: 1024px) {
	.music-releases-grid {
		grid-template-columns: repeat(2, 1fr) !important;
	}
}

@media (max-width: 480px) {
	.music-releases-grid {
		grid-template-columns: repeat(2, 1fr) !important;
		gap: var(--wp--preset--spacing--xs) !important;
	}
}

/* Archive grid: 3 columns → 2 on tablet → 1 on mobile */
.music-archive-grid {
	grid-template-columns: repeat(3, 1fr) !important;
}

@media (max-width: 1024px) {
	.music-archive-grid {
		grid-template-columns: repeat(2, 1fr) !important;
	}
}

@media (max-width: 600px) {
	.music-archive-grid {
		grid-template-columns: 1fr !important;
	}
}

/* ==========================================================================
   PRINT STYLES
   ========================================================================== */

@media print {
	.wp-block-navigation,
	.wp-block-cover__overlay,
	#seated-placeholder,
	#shopify-placeholder,
	.events-hero,
	lite-youtube {
		display: none !important;
	}

	body {
		background: #fff !important;
		color: #000 !important;
	}
}
