/*
Theme Name: Acurba
Theme URI: https://acurba.com
Author: Asociación Cultural y Recreativa Bailo
Description: Tema a medida para ACURBA, la Asociación Cultural y Recreativa de Bailo. Paleta de teja, pino y trigo, tipografía Sorts Mill Goudy y Montserrat, y bloques listos para anunciar actividades, fiestas y noticias del pueblo.
Requires at least: 6.6
Tested up to: 7.1
Requires PHP: 8.1
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: acurba
Tags: block-theme, custom-colors, custom-menu, full-site-editing, one-column, two-columns, translation-ready
*/

/*
 * Nearly all of the design lives in theme.json, so it is editable from
 * Apariencia -> Editor without touching code. This file only holds what
 * theme.json cannot express: the wordmark, the brush-stroke divider taken
 * from the logo, and a few hover states.
 */

/* ---------------------------------------------------------------- wordmark */

/*
 * The logo file sets "ACURBA" in Goudy Old Style with ".com" in light
 * Montserrat, on its own dark green tile. Rebuilding it in CSS from Sorts Mill
 * Goudy (the free Goudy revival) means it stays crisp at any size, works on
 * any background, and the ".com" is appended here rather than being part of
 * the site title, so the browser tab and search results just read "Acurba".
 */
.wp-block-site-title a::after {
	content: ".com";
	font-family: Montserrat, sans-serif;
	font-weight: 300;
	letter-spacing: -0.03em;
	font-size: 0.62em;
	text-transform: lowercase;
	opacity: 0.75;
}

.wp-block-site-title a {
	text-decoration: none;
	color: currentColor;
}

.wp-block-site-title a:hover,
.wp-block-site-title a:focus {
	color: var(--wp--preset--color--primary);
	text-decoration: none;
}

/* On the dark bands the wordmark and tagline invert. */
.has-secondary-background-color .wp-block-site-title a,
.acurba-dark .wp-block-site-title a {
	color: var(--wp--preset--color--base);
}

.acurba-dark .wp-block-site-tagline {
	color: rgb(251 248 242 / 72%) !important;
}

/* -------------------------------------------------------- brush divider */

/*
 * The swoosh under the logo, reused as a section divider. It is a mask rather
 * than an <img> so it takes its colour from the surrounding text colour.
 */
.acurba-swoosh {
	display: block;
	width: min(18rem, 60%);
	aspect-ratio: 34 / 1;
	background-color: currentColor;
	-webkit-mask: url("assets/images/swoosh.svg") no-repeat center / contain;
	mask: url("assets/images/swoosh.svg") no-repeat center / contain;
	opacity: 0.9;
}

.acurba-swoosh--center {
	margin-inline: auto;
}

.acurba-swoosh--accent {
	color: var(--wp--preset--color--accent);
}

/* ------------------------------------------------------------- eyebrow */

/* Small label above a heading: "Próxima actividad", "Noticias", etc. */
.acurba-eyebrow {
	font-family: Montserrat, sans-serif;
	font-size: 0.75rem;
	font-weight: 600;
	letter-spacing: 0.18em;
	text-transform: uppercase;
	color: var(--wp--preset--color--primary);
	margin-bottom: 0.5rem;
}

.acurba-dark .acurba-eyebrow,
.has-secondary-background-color .acurba-eyebrow {
	color: var(--wp--preset--color--accent);
}

/* --------------------------------------------------------------- cards */

/* Activity and post cards: a quiet lift on hover, no bouncing. */
.acurba-card {
	transition: transform 0.25s ease, box-shadow 0.25s ease;
	height: 100%;
}

@media (hover: hover) {
	.acurba-card:hover {
		transform: translateY(-3px);
		box-shadow: var(--wp--preset--shadow--lift);
	}
}

.acurba-card .wp-block-post-title a,
.acurba-card h3 a {
	text-decoration: none;
}

.acurba-card .wp-block-post-title a:hover,
.acurba-card h3 a:hover {
	text-decoration: underline;
}

/* Date badge on the "next activity" panel. */
.acurba-date {
	font-family: var(--wp--preset--font-family--goudy);
	line-height: 1;
	text-align: center;
}

.acurba-date strong {
	display: block;
	font-size: 3rem;
	font-weight: 400;
}

.acurba-date span {
	display: block;
	font-family: Montserrat, sans-serif;
	font-size: 0.75rem;
	font-weight: 600;
	letter-spacing: 0.16em;
	text-transform: uppercase;
}

/* ---------------------------------------------------------- navigation */

/* Underline that grows from the left, so the nav does not shift on hover. */
.wp-block-navigation .wp-block-navigation-item__content {
	position: relative;
	text-decoration: none;
	padding-block: 0.25rem;
}

.wp-block-navigation:not(.has-background) .wp-block-navigation-item__content::after {
	content: "";
	position: absolute;
	left: 0;
	bottom: 0;
	width: 0;
	height: 2px;
	background-color: var(--wp--preset--color--accent);
	transition: width 0.2s ease;
}

.wp-block-navigation:not(.has-background) .wp-block-navigation-item__content:hover::after,
.wp-block-navigation:not(.has-background) .wp-block-navigation-item__content:focus::after,
.wp-block-navigation:not(.has-background) .current-menu-item > .wp-block-navigation-item__content::after {
	width: 100%;
}

/* The mobile overlay is dark, so its links must be light. */
.wp-block-navigation__responsive-container.is-menu-open {
	background-color: var(--wp--preset--color--secondary) !important;
	color: var(--wp--preset--color--base) !important;
}

.wp-block-navigation__responsive-container.is-menu-open a {
	color: var(--wp--preset--color--base) !important;
	font-size: 1.125rem;
}

/* ------------------------------------------------------------- content */

/* Post meta line under a title. */
.acurba-meta {
	font-size: 0.8125rem;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	color: var(--wp--preset--color--muted);
}

/* First paragraph of an article, set slightly larger. */
.acurba-lead {
	font-size: 1.1875rem;
	line-height: 1.65;
	color: var(--wp--preset--color--contrast);
}

.wp-block-post-content figure,
.wp-block-post-content img {
	border-radius: 2px;
}

/* Footer link lists carry no bullets. */
.acurba-footer-list {
	list-style: none;
}

.acurba-footer-list li + li {
	margin-top: 0.4rem;
}

/* Footer links: quiet until hovered. */
.acurba-dark a:where(:not(.wp-element-button)) {
	color: rgb(251 248 242 / 85%);
	text-decoration: none;
}

.acurba-dark a:where(:not(.wp-element-button)):hover,
.acurba-dark a:where(:not(.wp-element-button)):focus {
	color: var(--wp--preset--color--accent);
	text-decoration: underline;
}

.acurba-dark .wp-block-navigation a:hover {
	color: var(--wp--preset--color--accent) !important;
}

/* ------------------------------------------------------ accessibility */

/* Visible focus ring everywhere, on both light and dark bands. */
:where(a, button, input, select, textarea, summary):focus-visible {
	outline: 2px solid var(--wp--preset--color--accent);
	outline-offset: 2px;
}

.skip-link {
	position: absolute;
	left: -9999px;
	z-index: 999;
}

.skip-link:focus {
	left: 1rem;
	top: 1rem;
	background: var(--wp--preset--color--secondary);
	color: var(--wp--preset--color--base);
	padding: 0.75rem 1rem;
	border-radius: 2px;
}

@media (prefers-reduced-motion: reduce) {
	* {
		transition-duration: 0.01ms !important;
		animation-duration: 0.01ms !important;
	}
}

/* ---------------------------------------------------------------- print */

@media print {
	.wp-block-template-part,
	.wp-block-navigation {
		display: none !important;
	}

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