/*
Theme Name: Liberty Church
Theme URI: https://www.libertychurch.com.au/
Author: Liberty Church
Author URI: https://www.libertychurch.com.au/
Description: A warm, welcoming full-site-editing (block) theme for Liberty Church, Tamworth — home of Liberty Church, Kalayaan Church, Liberty Food Care and Liberty Christian Primary School. Built with WordPress block patterns and theme.json.
Requires at least: 6.5
Tested up to: 7.0
Requires PHP: 7.0
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: liberty-church
Tags: full-site-editing, block-patterns, church, nonprofit, community, one-column, custom-colors, custom-menu, editor-style, featured-images, threaded-comments, translation-ready
*/

/* This is a block theme. Styling is handled in theme.json.
   Minimal supplemental CSS lives here for fine details that theme.json cannot express. */

.wp-block-button.is-style-pill .wp-block-button__link {
	border-radius: 999px;
}

/* Smooth anchor scrolling for in-page service-time / location links */
html {
	scroll-behavior: smooth;
}

/* Subtle lift on ministry / card group hover */
.lib-card {
	transition: transform .25s ease, box-shadow .25s ease;
}
.lib-card:hover {
	transform: translateY(-4px);
}

/* Constrain cover hero text nicely on small screens */
@media (max-width: 600px) {
	.lib-hero h1 {
		font-size: clamp(2rem, 9vw, 3rem) !important;
	}
}

/* ---------------------------------------------------------------------------
   Links & navigation interactions
   --------------------------------------------------------------------------- */

a {
	transition: color .18s ease;
}

/* Header navigation links */
.lib-site-header .wp-block-navigation .wp-block-navigation-item__content {
	position: relative;
	padding-bottom: 4px;
}

/* Animated underline indicator (hover + current page + current ancestor) */
.lib-site-header .wp-block-navigation-item > .wp-block-navigation-item__content::after {
	content: "";
	position: absolute;
	left: 0;
	right: 0;
	bottom: -2px;
	height: 2px;
	border-radius: 2px;
	background: var(--wp--preset--color--secondary);
	transform: scaleX(0);
	transform-origin: left center;
	transition: transform .22s ease;
}
.lib-site-header .wp-block-navigation-item:hover > .wp-block-navigation-item__content::after,
.lib-site-header .wp-block-navigation-item:focus-within > .wp-block-navigation-item__content::after,
.lib-site-header .wp-block-navigation-item.current-menu-item > .wp-block-navigation-item__content::after,
.lib-site-header .wp-block-navigation-item.current_page_item > .wp-block-navigation-item__content::after,
.lib-site-header .wp-block-navigation-item.current-menu-ancestor > .wp-block-navigation-item__content::after,
.lib-site-header .wp-block-navigation-item.current_page_ancestor > .wp-block-navigation-item__content::after,
.lib-site-header .wp-block-navigation-item__content[aria-current="page"]::after {
	transform: scaleX(1);
}

/* Colour for hover + active nav items */
.lib-site-header .wp-block-navigation-item:hover > .wp-block-navigation-item__content,
.lib-site-header .wp-block-navigation-item.current-menu-item > .wp-block-navigation-item__content,
.lib-site-header .wp-block-navigation-item.current_page_item > .wp-block-navigation-item__content,
.lib-site-header .wp-block-navigation-item.current-menu-ancestor > .wp-block-navigation-item__content,
.lib-site-header .wp-block-navigation-item.current_page_ancestor > .wp-block-navigation-item__content,
.lib-site-header .wp-block-navigation-item__content[aria-current="page"] {
	color: var(--wp--preset--color--secondary) !important;
}

/* Submenu (dropdown) tidy */
.lib-site-header .wp-block-navigation-submenu .wp-block-navigation-item__content::after {
	display: none;
}

/* Footer links: warm hover */
footer a {
	transition: color .18s ease;
}
footer a:hover,
footer a:focus {
	color: var(--wp--preset--color--accent) !important;
}

/* Always-visible footer link lists (no bullets, two columns of links) */
.lib-footer-links {
	list-style: none;
	margin: 0;
	padding: 0;
	line-height: 2.1;
}
.lib-footer-links li {
	margin: 0;
}
.lib-footer-links a {
	color: #cbd3dd;
	text-decoration: none;
	font-size: 0.95rem;
}

/* Button hover lift */
.wp-block-button__link {
	transition: background-color .2s ease, transform .15s ease, box-shadow .2s ease;
}
.wp-block-button__link:hover {
	transform: translateY(-2px);
	box-shadow: 0 8px 18px rgba(21, 42, 69, .18);
}

/* ---------------------------------------------------------------------------
   Accessibility & touch targets (design-review)
   ------------------------------------------------------------------------- */

/* Visible keyboard focus ring — we never overrode the default, so make ours
   explicit and on-brand rather than relying on the UA outline. */
.lib-site-header a:focus-visible,
.lib-site-header button:focus-visible,
.wp-block-button__link:focus-visible {
	outline: 2px solid var(--wp--preset--color--secondary);
	outline-offset: 3px;
	border-radius: 2px;
}

/* Dropdown toggle arrow rendered at 9x9px — too small to tap. Grow its hit
   area without moving the arrow noticeably. */
.lib-site-header .wp-block-navigation__submenu-icon {
	padding: 0.35em;
}

/* In the mobile overlay menu, give every nav link a full 44px tap target. */
.lib-site-header .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation-item__content {
	min-height: 44px;
	display: flex;
	align-items: center;
}

/* Top-bar phone/email were 16px-tall bare links. Pad them into real tap
   targets (the top bar still stays compact). */
.lib-site-header .has-primary-dark-background-color a {
	display: inline-block;
	padding: 4px 2px;
}

/* Respect users who ask the OS to reduce motion. */
@media (prefers-reduced-motion: reduce) {
	.lib-site-header .wp-block-navigation-item__content::after,
	.wp-block-button__link,
	footer a {
		transition: none !important;
	}
	.wp-block-button__link:hover {
		transform: none;
	}
}
