/*
Theme Name: Advisement Directory Theme
Theme URI: https://advisement.com/
Author: OpenAI Codex
Description: Companion theme for the Advisement attorney directory. Keeps an editorial blog feel while shifting the homepage and footer to a clean blue directory layout.
Version: 0.2.10
Requires at least: 6.0
Tested up to: 6.8
Requires PHP: 7.4
Text Domain: advisement-directory-theme
*/

:root {
	--adt-blue-900: #103d73;
	--adt-blue-800: #174d91;
	--adt-blue-700: #2865b7;
	--adt-blue-100: #eaf3ff;
	--adt-ink-900: #182431;
	--adt-ink-700: #485467;
	--adt-ink-500: #6b7280;
	--adt-border: #e5e7eb;
	--adt-surface: #ffffff;
	--adt-surface-alt: #f8fbff;
	--adt-shadow: 0 16px 40px rgba(16, 61, 115, 0.08);
	--adt-radius-lg: 28px;
	--adt-radius-md: 18px;
	--adt-content-width: 1200px;
}

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

html {
	scroll-behavior: smooth;
}

body {
	background: #ffffff;
	color: var(--adt-ink-900);
	font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
	font-size: 16px;
	line-height: 1.7;
	margin: 0;
}

a {
	color: var(--adt-blue-700);
	text-decoration: none;
}

a:hover,
a:focus-visible {
	text-decoration: underline;
}

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

.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;
	white-space: nowrap;
	width: 1px;
}

.adt-site-shell {
	min-height: 100vh;
}

.adt-wrap {
	margin: 0 auto;
	max-width: var(--adt-content-width);
	padding: 0 20px;
}

.adt-site-header {
	background: #ffffff;
	border-bottom: 1px solid var(--adt-border);
	position: sticky;
	top: 0;
	z-index: 40;
}

.adt-site-header__inner {
	align-items: center;
	display: flex;
	gap: 28px;
	justify-content: space-between;
	min-height: 76px;
}

.adt-branding {
	align-items: center;
	display: flex;
	flex: 0 0 auto;
	gap: 12px;
}

.adt-branding .custom-logo-link {
	display: inline-flex;
	flex-shrink: 0;
	max-width: 220px;
}

.adt-branding .custom-logo {
	height: auto;
	max-height: 48px;
	width: auto;
}

.adt-branding__title {
	color: var(--adt-blue-900);
	font-size: 1.85rem;
	font-weight: 800;
	letter-spacing: -0.02em;
	margin: 0;
}

.adt-branding__title a {
	color: inherit;
	text-decoration: none;
}

.adt-branding__tag {
	color: var(--adt-ink-500);
	font-size: 0.92rem;
	margin: 0;
}

.adt-mobile-menu-checkbox,
.adt-mobile-menu-button {
	display: none;
}

.adt-header-nav {
	display: flex;
	flex: 1 1 auto;
	justify-content: center;
	position: relative;
}

.adt-mega-menu {
	align-items: center;
	display: flex;
	flex-wrap: nowrap;
	gap: 4px;
	list-style: none;
	margin: 0;
	padding: 0;
}

.adt-mega-menu__entry {
	position: static;
}

.adt-mega-menu__item {
	position: static;
}

.adt-mega-menu__item summary {
	list-style: none;
}

.adt-mega-menu__item summary::-webkit-details-marker {
	display: none;
}

.adt-mega-menu__toggle {
	align-items: center;
	border-bottom: 2px solid transparent;
	color: var(--adt-ink-900);
	cursor: pointer;
	display: inline-flex;
	gap: 8px;
	font-weight: 700;
	padding: 26px 14px 24px;
	transition: color 180ms ease, border-color 180ms ease;
}

.adt-mega-menu__toggle:hover,
.adt-mega-menu__toggle:focus-visible,
.adt-mega-menu__item[open] .adt-mega-menu__toggle,
.adt-mega-menu__item.is-current .adt-mega-menu__toggle {
	border-bottom-color: #ef6e2e;
	color: var(--adt-blue-700);
	text-decoration: none;
}

.adt-mega-menu__caret {
	border-bottom: 2px solid currentColor;
	border-right: 2px solid currentColor;
	display: inline-block;
	height: 8px;
	margin-top: -3px;
	transform: rotate(45deg);
	width: 8px;
}

.adt-mega-menu__item[open] .adt-mega-menu__caret {
	margin-top: 3px;
	transform: rotate(-135deg);
}

.adt-mega-panel {
	background: #ffffff;
	border: 1px solid var(--adt-border);
	box-shadow: 0 24px 44px rgba(24, 36, 49, 0.12);
	left: 50%;
	margin-top: 1px;
	padding: 18px 24px 22px;
	position: absolute;
	top: 100%;
	transform: translateX(-50%);
	width: min(1060px, calc(100vw - 40px));
	z-index: 45;
}

.adt-mega-panel__grid {
	display: grid;
	gap: 20px 26px;
	grid-template-columns: minmax(0, 1fr);
}

.adt-mega-panel__grid--location {
	grid-template-columns: 300px minmax(0, 1fr);
}

.adt-mega-panel__grid--topics {
	grid-template-columns: minmax(0, 1.2fr) minmax(260px, 0.8fr);
}

.adt-mega-panel__section {
	min-width: 0;
}

.adt-mega-panel__section--cities {
	border-right: 1px solid var(--adt-border);
	padding-right: 16px;
}

.adt-mega-panel__section h2 {
	color: var(--adt-ink-900);
	font-size: 0.95rem;
	margin: 0 0 14px;
}

.adt-mega-links {
	display: grid;
	gap: 10px;
	list-style: none;
	margin: 0;
	padding: 0;
}

.adt-mega-panel__section--cities .adt-mega-links {
	column-gap: 18px;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	row-gap: 10px;
}

.adt-mega-links li {
	break-inside: avoid;
}

.adt-mega-links a {
	color: #2072c9;
	font-size: 0.96rem;
	font-weight: 500;
	line-height: 1.3;
	text-decoration: none;
}

.adt-mega-links a:hover,
.adt-mega-links a:focus-visible {
	text-decoration: underline;
}

.adt-mega-links--columns {
	column-gap: 26px;
	columns: 5 120px;
	display: block;
}

.adt-mega-links--columns li {
	margin: 0 0 10px;
}

.adt-header-actions {
	align-items: center;
	display: inline-flex;
	flex: 0 0 auto;
	gap: 14px;
}

.adt-header-search {
	align-items: center;
	color: var(--adt-ink-900);
	display: inline-flex;
	height: 40px;
	justify-content: center;
	width: 40px;
}

.adt-header-search:hover,
.adt-header-search:focus-visible {
	text-decoration: none;
}

.adt-header-search svg {
	height: 22px;
	width: 22px;
}

.adt-header-link {
	color: var(--adt-blue-700);
	font-weight: 700;
	white-space: nowrap;
}

.adt-header-signin {
	align-items: center;
	background: #ef6e2e;
	border-radius: 10px;
	color: #ffffff;
	display: inline-flex;
	font-weight: 800;
	justify-content: center;
	min-height: 44px;
	padding: 10px 18px;
	white-space: nowrap;
}

.adt-header-signin:hover,
.adt-header-signin:focus-visible {
	background: #de6122;
	color: #ffffff;
	text-decoration: none;
}

.adt-button,
.wp-block-button__link {
	background: var(--adt-blue-900);
	border: 1px solid var(--adt-blue-900);
	border-radius: 999px;
	color: #ffffff;
	display: inline-flex;
	font-weight: 800;
	justify-content: center;
	padding: 13px 20px;
	text-decoration: none;
}

.adt-button:hover,
.adt-button:focus-visible,
.wp-block-button__link:hover,
.wp-block-button__link:focus-visible {
	background: var(--adt-blue-800);
	border-color: var(--adt-blue-800);
	text-decoration: none;
}

.adt-button--ghost {
	background: #ffffff;
	border-color: var(--adt-border);
	color: var(--adt-ink-900);
}

.adt-button--ghost:hover,
.adt-button--ghost:focus-visible {
	background: var(--adt-surface-alt);
	border-color: var(--adt-blue-700);
}

.adt-page-section {
	padding: 38px 0;
}

.adt-page-section--directory-app {
	padding: 0;
}

.adt-directory-hero {
	background:
		linear-gradient(180deg, #ffffff 0%, #f5faff 100%);
	padding: 42px 0 26px;
}

.adt-directory-hero__grid {
	display: grid;
	gap: 26px;
	grid-template-columns: minmax(0, 1.2fr) minmax(320px, 0.8fr);
}

.adt-kicker {
	color: var(--adt-blue-700);
	font-size: 0.82rem;
	font-weight: 800;
	letter-spacing: 0.16em;
	margin: 0 0 12px;
	text-transform: uppercase;
}

.adt-hero-title {
	color: var(--adt-blue-900);
	font-size: clamp(2.5rem, 6vw, 4.4rem);
	letter-spacing: -0.04em;
	line-height: 0.98;
	margin: 0;
}

.adt-hero-copy {
	color: var(--adt-ink-700);
	font-size: 1.1rem;
	margin: 16px 0 0;
	max-width: 60ch;
}

.adt-hero-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 12px;
	margin-top: 22px;
}

.adt-search-panel,
.adt-card,
.adt-state-grid a,
.adt-city-grid a,
.adt-post-card,
.adt-footer-panel {
	background: var(--adt-surface);
	border: 1px solid var(--adt-border);
	border-radius: var(--adt-radius-lg);
	box-shadow: var(--adt-shadow);
}

.adt-search-panel {
	padding: 22px;
}

.adt-search-panel h2,
.adt-section-title {
	color: var(--adt-blue-900);
	font-size: clamp(1.5rem, 3vw, 2.2rem);
	letter-spacing: -0.03em;
	margin: 0 0 14px;
}

.adt-directory-form {
	display: grid;
	gap: 12px;
}

.adt-directory-form input,
.adt-directory-form select {
	border: 1px solid var(--adt-border);
	border-radius: 16px;
	font: inherit;
	min-height: 50px;
	padding: 0 16px;
}

.adt-directory-form__row {
	display: grid;
	gap: 12px;
	grid-template-columns: repeat(2, minmax(0, 1fr));
}

.adt-stats-strip {
	display: grid;
	gap: 16px;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	margin-top: 28px;
}

.adt-card {
	padding: 22px;
}

.adt-card__label {
	color: var(--adt-ink-500);
	font-size: 0.92rem;
	margin: 0;
}

.adt-card__value {
	color: var(--adt-blue-900);
	font-size: clamp(1.8rem, 4vw, 2.7rem);
	font-weight: 800;
	letter-spacing: -0.03em;
	margin: 10px 0 0;
}

.adt-state-grid,
.adt-city-grid,
.adt-post-grid {
	display: grid;
	gap: 16px;
}

.adt-state-grid {
	grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
}

.adt-city-grid {
	grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.adt-state-grid a,
.adt-city-grid a {
	color: var(--adt-ink-900);
	display: grid;
	gap: 4px;
	padding: 18px 20px;
	text-decoration: none;
}

.adt-state-grid strong,
.adt-city-grid strong {
	color: var(--adt-blue-900);
	font-size: 1rem;
}

.adt-state-grid span,
.adt-city-grid span {
	color: var(--adt-ink-500);
	font-size: 0.95rem;
}

.adt-editorial-band {
	background: #ffffff;
}

.adt-post-grid {
	grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.adt-post-card {
	overflow: hidden;
}

.adt-post-card__content {
	padding: 20px;
}

.adt-post-card__meta {
	color: var(--adt-blue-700);
	font-size: 0.9rem;
	font-weight: 800;
	margin: 0 0 10px;
	text-transform: uppercase;
}

.adt-post-card h3 {
	font-size: 1.2rem;
	line-height: 1.25;
	margin: 0 0 10px;
}

.adt-post-card p {
	color: var(--adt-ink-700);
	margin: 0;
}

.adt-content-grid {
	display: grid;
	gap: 28px;
	grid-template-columns: minmax(0, 1fr) 320px;
}

.adt-main-card,
.adt-sidebar-card {
	background: var(--adt-surface);
	border: 1px solid var(--adt-border);
	border-radius: var(--adt-radius-lg);
	padding: 28px;
}

.adt-post-list article + article {
	border-top: 1px solid var(--adt-border);
	margin-top: 22px;
	padding-top: 22px;
}

.adt-post-entry__meta {
	color: var(--adt-blue-700);
	font-size: 0.9rem;
	font-weight: 800;
	margin: 0 0 10px;
	text-transform: uppercase;
}

.adt-post-entry__title {
	font-size: clamp(1.4rem, 3vw, 2rem);
	line-height: 1.15;
	margin: 0 0 12px;
}

.adt-post-entry__thumb {
	border-radius: var(--adt-radius-md);
	margin-bottom: 16px;
	overflow: hidden;
}

.adt-sidebar-card h2 {
	font-size: 1.25rem;
	margin: 0 0 12px;
}

.adt-link-list {
	display: grid;
	gap: 10px;
	list-style: none;
	margin: 0;
	padding: 0;
}

.adt-sidebar-related {
	border-top: 1px solid var(--adt-border);
	display: grid;
	gap: 16px;
	margin-top: 28px;
	padding-top: 24px;
}

.adt-sidebar-related h3 {
	color: var(--adt-blue-900);
	font-size: 1.15rem;
	margin: 0;
}

.adt-sidebar-related__list {
	display: grid;
	gap: 16px;
}

.adt-sidebar-related__item {
	display: grid;
	gap: 12px;
	grid-template-columns: 88px minmax(0, 1fr);
}

.adt-sidebar-related__thumb {
	border-radius: 16px;
	display: block;
	overflow: hidden;
}

.adt-sidebar-related__thumb img {
	aspect-ratio: 1 / 1;
	object-fit: cover;
	width: 100%;
}

.adt-sidebar-related__content {
	min-width: 0;
}

.adt-sidebar-related__content .adt-post-entry__meta {
	font-size: 0.78rem;
	margin-bottom: 6px;
}

.adt-sidebar-related__content h4 {
	font-size: 1rem;
	line-height: 1.3;
	margin: 0;
}

.adt-sidebar-related__content h4 a {
	color: var(--adt-ink-900);
	text-decoration: none;
}

.adt-related-posts {
	border-top: 1px solid var(--adt-border);
	margin-top: 32px;
	padding-top: 28px;
}

.adt-related-posts h2 {
	color: var(--adt-blue-900);
	font-size: 1.45rem;
	margin: 0 0 18px;
}

.adt-related-posts__grid {
	display: grid;
	gap: 18px;
	grid-template-columns: repeat(3, minmax(0, 1fr));
}

.adt-related-post {
	background: var(--adt-surface-alt);
	border: 1px solid var(--adt-border);
	border-radius: 22px;
	overflow: hidden;
}

.adt-related-post__thumb {
	display: block;
}

.adt-related-post__thumb img {
	aspect-ratio: 16 / 10;
	object-fit: cover;
	width: 100%;
}

.adt-related-post__content {
	padding: 18px;
}

.adt-related-post__content h3 {
	font-size: 1.05rem;
	line-height: 1.3;
	margin: 0 0 10px;
}

.adt-related-post__content h3 a {
	color: var(--adt-blue-900);
	text-decoration: none;
}

.adt-related-post__content p:last-child {
	color: var(--adt-ink-700);
	margin: 0;
}

.adt-directory-band {
	background: linear-gradient(180deg, #f8fbff 0%, #ffffff 100%);
}

.adt-site-footer {
	background: #eef3fb;
	color: var(--adt-ink-900);
	margin-top: 48px;
	padding: 52px 0 28px;
}

.adt-footer-grid {
	display: grid;
	gap: 28px;
	grid-template-columns: minmax(280px, 1.35fr) 1fr 1fr 1.15fr;
}

.adt-footer-panel {
	background: transparent;
	border: 0;
	border-radius: 0;
	box-shadow: none;
	padding: 0;
}

.adt-footer-panel--brand {
	display: grid;
	gap: 22px;
}

.adt-footer-branding {
	align-items: center;
	display: flex;
	gap: 16px;
}

.adt-footer-branding .custom-logo-link {
	display: inline-flex;
	flex-shrink: 0;
	max-width: 210px;
}

.adt-footer-branding .custom-logo {
	height: auto;
	max-height: 58px;
	width: auto;
}

.adt-footer-branding h2 {
	color: var(--adt-blue-700);
	font-size: 1.8rem;
	font-weight: 800;
	letter-spacing: -0.03em;
	margin: 0;
}

.adt-footer-branding__tag {
	color: var(--adt-ink-500);
	font-size: 0.95rem;
	margin: 4px 0 0;
}

.adt-footer-panel__lead {
	color: var(--adt-ink-900);
	font-size: 1.05rem;
	line-height: 1.7;
	margin: 0;
	max-width: 28rem;
}

.adt-footer-actions {
	display: grid;
	gap: 14px;
	justify-items: start;
	width: 100%;
}

.adt-footer-account-links {
	display: flex;
	flex-wrap: wrap;
	gap: 10px 18px;
}

.adt-footer-account-links a {
	color: var(--adt-blue-700);
	font-size: 0.98rem;
	font-weight: 700;
	text-decoration: none;
}

.adt-footer-account-links a:hover,
.adt-footer-account-links a:focus-visible {
	text-decoration: underline;
}

.adt-footer-cta,
.adt-footer-cta:visited {
	align-items: center;
	background: linear-gradient(180deg, #5683e8 0%, #4776de 100%);
	border: 1px solid rgba(71, 118, 222, 0.9);
	border-radius: 999px;
	box-shadow: 0 12px 28px rgba(71, 118, 222, 0.18);
	color: #ffffff !important;
	display: inline-flex;
	font-size: 1rem;
	font-weight: 800;
	justify-content: center;
	letter-spacing: 0.01em;
	line-height: 1;
	min-height: 50px;
	padding: 14px 28px;
	text-align: center;
	width: min(100%, 280px);
}

.adt-footer-cta:hover,
.adt-footer-cta:focus-visible {
	background: linear-gradient(180deg, #4e7be0 0%, #3c67d1 100%);
	border-color: rgba(60, 103, 209, 0.96);
	box-shadow: 0 16px 30px rgba(60, 103, 209, 0.24);
	color: #ffffff !important;
	text-decoration: none;
	transform: translateY(-1px);
}

.adt-footer-panel h2,
.adt-footer-panel h3 {
	color: var(--adt-ink-900);
	font-size: 1.05rem;
	margin: 0 0 12px;
}

.adt-footer-panel p,
.adt-footer-panel li,
.adt-footer-panel a {
	color: var(--adt-ink-700);
}

.adt-footer-panel ul {
	display: grid;
	gap: 10px;
	list-style: none;
	margin: 0;
	padding: 0;
}

.adt-footer-panel li a {
	text-decoration: none;
}

.adt-footer-bottom {
	border-top: 1px solid rgba(24, 36, 49, 0.08);
	color: var(--adt-ink-500);
	display: flex;
	flex-wrap: wrap;
	gap: 10px 20px;
	justify-content: space-between;
	margin-top: 24px;
	padding-top: 18px;
}

.adt-footer-bottom__meta {
	display: flex;
	flex-wrap: wrap;
	gap: 10px 18px;
}

.adt-footer-bottom__meta a,
.adt-footer-bottom__meta span {
	color: inherit;
	text-decoration: none;
}

.entry-content > *:first-child,
.adt-main-card > *:first-child {
	margin-top: 0;
}

.entry-content > *:last-child,
.adt-main-card > *:last-child {
	margin-bottom: 0;
}

@media (max-width: 1024px) {
	.adt-directory-hero__grid,
	.adt-content-grid,
	.adt-footer-grid {
		grid-template-columns: 1fr;
	}

	.adt-stats-strip,
	.adt-related-posts__grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.adt-site-header__inner {
		flex-wrap: wrap;
		padding-bottom: 14px;
		padding-top: 14px;
	}

	.adt-header-nav {
		flex-basis: 100%;
		justify-content: flex-start;
		order: 3;
	}

	.adt-mega-menu {
		flex-wrap: wrap;
	}

	.adt-mega-panel {
		width: min(960px, calc(100vw - 40px));
	}
}

@media (max-width: 720px) {
	.adt-site-header__inner {
		align-items: center;
		flex-direction: row;
		flex-wrap: wrap;
		gap: 10px;
		padding: 14px 0;
	}

	.adt-branding {
		flex: 1 1 auto;
		min-width: 0;
	}

	.adt-branding__title {
		font-size: 1.55rem;
	}

	.adt-header-actions {
		align-items: center;
		flex: 0 0 auto;
		gap: 8px;
		margin-left: auto;
		width: auto;
	}

	.adt-mobile-menu-button {
		align-items: center;
		border: 1px solid var(--adt-border);
		border-radius: 10px;
		cursor: pointer;
		display: inline-flex;
		height: 40px;
		justify-content: center;
		width: 40px;
	}

	.adt-mobile-menu-icon {
		display: grid;
		gap: 4px;
		width: 18px;
	}

	.adt-mobile-menu-icon span {
		background: var(--adt-ink-900);
		border-radius: 999px;
		display: block;
		height: 2px;
		transition: transform 180ms ease, opacity 180ms ease;
		width: 100%;
	}

	.adt-mobile-menu-checkbox:checked ~ .adt-header-actions .adt-mobile-menu-button {
		background: var(--adt-surface-alt);
		border-color: #c9d8ea;
	}

	.adt-mobile-menu-checkbox:checked ~ .adt-header-actions .adt-mobile-menu-icon span:nth-child(1) {
		transform: translateY(6px) rotate(45deg);
	}

	.adt-mobile-menu-checkbox:checked ~ .adt-header-actions .adt-mobile-menu-icon span:nth-child(2) {
		opacity: 0;
	}

	.adt-mobile-menu-checkbox:checked ~ .adt-header-actions .adt-mobile-menu-icon span:nth-child(3) {
		transform: translateY(-6px) rotate(-45deg);
	}

	.adt-header-nav {
		display: none;
		order: 3;
		width: 100%;
	}

	.adt-mobile-menu-checkbox:checked ~ .adt-header-nav {
		display: block;
	}

	.adt-mega-menu {
		flex-direction: column;
		gap: 0;
		width: 100%;
	}

	.adt-mega-menu__entry,
	.adt-mega-menu__item,
	.adt-mega-menu__toggle {
		width: 100%;
	}

	.adt-mega-menu__toggle {
		justify-content: space-between;
		padding: 16px 0;
	}

	.adt-mega-panel {
		border-left: 0;
		border-radius: 0;
		border-right: 0;
		box-shadow: none;
		left: auto;
		margin-top: 0;
		padding: 16px 0 8px;
		position: static;
		top: auto;
		transform: none;
		width: 100%;
	}

	.adt-mega-panel__grid,
	.adt-mega-panel__grid--location,
	.adt-mega-panel__grid--topics {
		grid-template-columns: 1fr;
	}

	.adt-mega-panel__section--cities {
		border-right: 0;
		padding-right: 0;
	}

	.adt-mega-links--columns {
		columns: 2 140px;
	}

	.adt-header-actions {
		align-items: center;
		flex-wrap: nowrap;
	}

	.adt-header-link,
	.adt-header-signin {
		justify-content: center;
	}

	.adt-directory-form__row,
	.adt-stats-strip,
	.adt-related-posts__grid {
		grid-template-columns: 1fr;
	}

	.adt-hero-title {
		font-size: 2.4rem;
	}

	.adt-main-card,
	.adt-sidebar-card,
	.adt-card,
	.adt-search-panel,
	.adt-footer-panel {
		border-radius: 22px;
		padding: 20px;
	}

	.adt-footer-panel {
		padding: 0;
	}

	.adt-footer-cta {
		width: min(100%, 340px);
	}
}
