/* Huddle theme – component CSS. Tokens come from theme.json (var(--wp--preset--*)). */

/* Accessibility ------------------------------------------------------- */
.screen-reader-text {
	border: 0; clip: rect(1px, 1px, 1px, 1px); clip-path: inset(50%);
	height: 1px; margin: -1px; overflow: hidden; padding: 0; position: absolute !important;
	width: 1px; word-wrap: normal !important;
}
.skip-link.screen-reader-text:focus {
	background: var(--wp--preset--color--white); border-radius: 6px; box-shadow: 0 0 0 3px var(--wp--preset--color--teal);
	clip: auto !important; clip-path: none; color: var(--wp--preset--color--jagua); display: block;
	font-weight: 700; height: auto; left: 1rem; padding: 0.75rem 1.25rem; top: 1rem; width: auto; z-index: 100000;
}
:where(a, button, input, select, textarea, summary, [tabindex]):focus-visible {
	outline: 3px solid var(--wp--preset--color--saffron); outline-offset: 2px;
}
@media (prefers-reduced-motion: reduce) {
	*, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; scroll-behavior: auto !important; transition-duration: 0.01ms !important; }
}
html { scroll-behavior: smooth; }

/* Header ---------------------------------------------------------------- */
/* Sticky goes on the template-part wrapper (a direct child of .wp-site-blocks): the <header> inside it
   is exactly the wrapper's height, so sticky on the inner element would have no room to stick.
   The :has() selector also covers templates customised in the Site Editor without our class. */
.huddle-header { border-bottom: 1px solid color-mix(in srgb, var(--wp--preset--color--teal) 18%, transparent); }
.huddle-header-part,
.wp-site-blocks > .wp-block-template-part:has(> .huddle-header) { position: sticky; top: 0; z-index: 50; }
.admin-bar .huddle-header-part,
.admin-bar .wp-site-blocks > .wp-block-template-part:has(> .huddle-header) { top: var(--wp-admin--admin-bar--height, 32px); }
@media (max-width: 600px) {
	.admin-bar .huddle-header-part,
	.admin-bar .wp-site-blocks > .wp-block-template-part:has(> .huddle-header) { top: 0; }
}
.huddle-brand .wp-block-site-title a { text-decoration: none; font-family: var(--wp--preset--font-family--heading); font-weight: 800; }
.huddle-header .wp-block-navigation { font-weight: 700; font-size: 0.975rem; }
.huddle-header .wp-block-navigation a { text-decoration: none; }
.huddle-header .wp-block-navigation a:hover { color: var(--wp--preset--color--henna); }
.huddle-header .wp-block-navigation__submenu-container { border-radius: 10px; padding: 0.4rem 0; box-shadow: 0 10px 30px rgba(24, 34, 47, 0.15); }
.huddle-header .wp-block-navigation__submenu-container a { padding: 0.45rem 1rem !important; }
@media (max-width: 780px) {
	.huddle-brand__tag { display: none; }
	.huddle-header__cta .wp-block-button__link { padding: 0.55rem 1rem; font-size: 0.875rem; }
}
@media (max-width: 420px) { .huddle-brand { display: none; } }
/* Core only switches to the overlay menu below 600px; the full menu plus CTA doesn't fit until ~1000px,
   so use the menu button up to 999px (mirrors core's own rules, scoped to the header). */
@media (min-width: 600px) and (max-width: 999px) {
	.huddle-header .wp-block-navigation__responsive-container-open:not(.always-shown) { display: flex; }
	.huddle-header .wp-block-navigation__responsive-container:not(.hidden-by-default):not(.is-menu-open) { display: none; }
	.huddle-header .wp-block-navigation__responsive-container.is-menu-open { display: flex; }
}
/* Inside the open overlay, submenus are plain indented lists (no dropdown card). */
.huddle-header .is-menu-open .wp-block-navigation__submenu-container { background: transparent !important; box-shadow: none; border: 0; }

/* Block styles ------------------------------------------------------------ */
.is-style-huddle-card {
	background: var(--wp--preset--color--white); border-radius: 18px; overflow: hidden;
	box-shadow: 0 1px 2px rgba(24, 34, 47, 0.06), 0 8px 24px rgba(24, 34, 47, 0.06);
	padding: var(--wp--preset--spacing--30);
}
.is-style-huddle-card > .wp-block-post-featured-image:first-child { margin: calc(-1 * var(--wp--preset--spacing--30)) calc(-1 * var(--wp--preset--spacing--30)) 0.75rem; }
.is-style-huddle-card .wp-block-post-title a { text-decoration: none; }
.is-style-huddle-underline { position: relative; padding-bottom: 0.35em; }
.is-style-huddle-underline::after {
	content: ""; position: absolute; left: 0; bottom: 0; width: 4.5rem; height: 6px; border-radius: 6px;
	background: var(--wp--preset--gradient--logo);
}
.has-text-align-center.is-style-huddle-underline::after { left: 50%; transform: translateX(-50%); }
.wp-block-button.is-style-huddle-teal .wp-block-button__link { background: var(--wp--preset--color--teal-deep); color: #fff; }
.wp-block-button.is-style-huddle-teal .wp-block-button__link:hover { background: var(--wp--preset--color--jagua); }
.wp-block-button.is-style-huddle-ghost .wp-block-button__link { background: transparent; color: #fff; box-shadow: inset 0 0 0 2px currentColor; }
.wp-block-button.is-style-huddle-ghost .wp-block-button__link:hover { background: rgba(255, 255, 255, 0.12); }

/* Sections ---------------------------------------------------------------- */
.huddle-hero { position: relative; overflow: hidden; isolation: isolate; }
/* hh27cover florals (decorative, CSS-only so no alt text), anchored bottom-right behind the logo.
   No mirrored top-left copy: the henna eyebrow text sits there and would drop below AA 4.5:1. */
.huddle-hero::before {
	content: ""; position: absolute; z-index: -1; pointer-events: none;
	background: url("../img/hh27-florals.webp") right bottom / contain no-repeat;
}
.huddle-hero::before { right: 0; bottom: 0; width: min(46rem, 52vw); aspect-ratio: 900 / 1008; max-height: 100%; background-position: right bottom; opacity: 0.85; }
.huddle-hero .wp-block-image img { filter: drop-shadow(0 18px 30px rgba(2, 103, 102, 0.25)); }
.huddle-eyebrow { letter-spacing: 0.08em; text-transform: uppercase; font-weight: 800; }
.huddle-section-motif { position: relative; }
.huddle-section-motif::before {
	content: ""; display: block; width: 3rem; height: 3rem; margin: 0 auto 0.5rem;
	background: url("../img/motif.svg") center / contain no-repeat;
}
.huddle-stats p strong { display: block; font-family: var(--wp--preset--font-family--heading); font-size: var(--wp--preset--font-size--xx-large); line-height: 1; color: var(--wp--preset--color--teal-deep); }

@media (max-width: 781px) {
	.huddle-hero .wp-block-image img { width: 180px !important; }
	.huddle-hero::before { width: 78vw; opacity: 0.5; }
}

/* FAQ / details accordions in content ------------------------------------- */
.wp-block-details { border-bottom: 1px solid var(--wp--preset--color--sand); padding: 0.9rem 0; }
.wp-block-details summary { cursor: pointer; font-weight: 700; list-style: none; padding-right: 2rem; position: relative; }
.wp-block-details summary::-webkit-details-marker { display: none; }
.wp-block-details summary::after { content: "+"; position: absolute; right: 0.25rem; top: -0.1rem; font-size: 1.5rem; line-height: 1; color: var(--wp--preset--color--henna); }
.wp-block-details[open] summary::after { content: "–"; }

/* Link in bio -------------------------------------------------------------- */
.huddle-links .wp-block-button { width: 100%; }
.huddle-links .wp-block-button__link { width: 100%; padding-top: 0.95rem; padding-bottom: 0.95rem; }

/* Footer ------------------------------------------------------------------- */
.huddle-footer a { text-decoration: none; }
.huddle-footer a:hover { text-decoration: underline; }
.huddle-footer__links { list-style: none; padding-left: 0; }
.huddle-footer__links li { margin-bottom: 0.35rem; }
.huddle-footer .huddle-event-meta { color: var(--wp--preset--color--mint-pale); }

/* Images ------------------------------------------------------------------- */
.wp-block-image.is-style-rounded img, .huddle-rounded img { border-radius: 18px; }
img { height: auto; }

/* Logo lettering (Candlepin; only active when the licensed font file is on the server) */
.huddle-hero h1,
h1.wp-block-post-title,
.wp-block-site-title,
.is-style-huddle-display,
.huddle-countdown__num {
	font-family: var(--huddle-display, var(--wp--preset--font-family--heading));
	font-synthesis: none;
}
.huddle-hero h1, h1.wp-block-post-title, .is-style-huddle-display { letter-spacing: 0.02em; }
