/*
Theme Name: Kancelaria Adwokacka - Weronika Chomicz
Theme URI: https://kancelariawch.pl
Author: WCH 
Description: Minimalistyczny motyw dla Kancelarii Adwokackiej Weroniki Chomicz
Version: 1.0.0
Requires at least: 6.4
Requires PHP: 8.1
License: GPL-2.0-or-later
Text Domain: wch
*/

/* ---------- Fonty (lokalne, latin-ext) ---------- */
@font-face { font-family: "Cormorant Garamond"; font-style: normal; font-weight: 500; font-display: swap; src: url("assets/fonts/cormorant-garamond-500.woff2") format("woff2"); }
@font-face { font-family: "Cormorant Garamond"; font-style: normal; font-weight: 600; font-display: swap; src: url("assets/fonts/cormorant-garamond-600.woff2") format("woff2"); }
@font-face { font-family: "Jost"; font-style: normal; font-weight: 400; font-display: swap; src: url("assets/fonts/jost-400.woff2") format("woff2"); }
@font-face { font-family: "Jost"; font-style: normal; font-weight: 500; font-display: swap; src: url("assets/fonts/jost-500.woff2") format("woff2"); }

/* ---------- Tokeny ---------- */
:root {
	--wch-white: #ffffff;
	--wch-sand: #f5f0e7;
	--wch-line: #e4dccd;
	--wch-gold: #a8834f;
	--wch-gold-dark: #7f6139;
	--wch-graphite: #2e2f31;
	--wch-muted: #66625c;
	--wch-ink: #1a1a1a;

	--wch-serif: "Cormorant Garamond", Georgia, "Times New Roman", serif;
	--wch-sans: "Jost", "Segoe UI", system-ui, sans-serif;

	--wch-width: 72rem;
	--wch-text: 40rem;
	--wch-gap: clamp(1.25rem, 4vw, 2.5rem);
	--wch-section: clamp(4rem, 10vw, 7.5rem);
}

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

html { scroll-behavior: smooth; scroll-padding-top: 6rem; -webkit-text-size-adjust: 100%; }

body {
	margin: 0;
	background: var(--wch-white);
	color: var(--wch-graphite);
	font: 400 1.0625rem/1.7 var(--wch-sans);
	-webkit-font-smoothing: antialiased;
}

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

h1, h2, h3, h4 {
	margin: 0 0 .6em;
	color: var(--wch-ink);
	font-family: var(--wch-serif);
	font-weight: 500;
	line-height: 1.15;
}
h1 { font-size: clamp(2.5rem, 6vw, 4.25rem); }
h2 { font-size: clamp(2rem, 4vw, 2.75rem); }
h3 { font-size: 1.6rem; }

p { margin: 0 0 1.1em; }

a { color: var(--wch-gold-dark); text-underline-offset: .2em; text-decoration-thickness: 1px; }
a:hover { color: var(--wch-ink); }

:focus-visible { outline: 2px solid var(--wch-gold); outline-offset: 3px; }

.wch-container { width: min(100% - 2 * var(--wch-gap), var(--wch-width)); margin-inline: auto; }

.wch-sr-only {
	position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
	overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.wch-skip-link { position: absolute; left: 1rem; top: -4rem; z-index: 100; padding: .6rem 1rem; background: var(--wch-ink); color: var(--wch-white); }
.wch-skip-link:focus { top: 1rem; color: var(--wch-white); }

/* ---------- Przyciski ---------- */
.wch-button {
	display: inline-block;
	padding: .8rem 1.6rem;
	border: 1px solid var(--wch-ink);
	background: var(--wch-ink);
	color: var(--wch-white);
	font: 500 .95rem/1.2 var(--wch-sans);
	letter-spacing: .02em;
	text-decoration: none;
	transition: background-color .2s, color .2s, border-color .2s;
}
.wch-button:hover { background: var(--wch-gold-dark); border-color: var(--wch-gold-dark); color: var(--wch-white); }
.wch-button-ghost { background: transparent; color: var(--wch-ink); }
.wch-button-ghost:hover { background: transparent; border-color: var(--wch-gold); color: var(--wch-gold-dark); }

/* ---------- Nagłówek ---------- */
.wch-header {
	position: sticky; top: 0; z-index: 50;
	background: rgba(255, 255, 255, .96);
	border-bottom: 1px solid var(--wch-line);
}
.wch-header-inner { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; min-height: 5rem; }

.wch-brand { display: flex; flex-direction: column; color: var(--wch-ink); text-decoration: none; line-height: 1.1; }
.wch-brand-name { font: 600 1.5rem/1.1 var(--wch-serif); }
.wch-brand-sub { color: var(--wch-muted); font-size: .85rem; letter-spacing: .03em; }
.wch-brand .custom-logo { padding:0.5em; max-height: 3.5rem; width: auto; }

.wch-nav ul { display: flex; gap: 2rem; margin: 0; padding: 0; list-style: none; }
.wch-nav a { color: var(--wch-graphite); font-size: .95rem; text-decoration: none; }
.wch-nav a:hover,
.wch-nav .current-menu-item > a { color: var(--wch-gold-dark); }

.wch-header-phone { white-space: nowrap; }

.wch-nav-toggle {
	display: none;
	padding: .5rem;
	border: 0;
	background: none;
	color: var(--wch-ink);
	cursor: pointer;
}
.wch-nav-toggle span { display: block; width: 1.5rem; height: 1px; margin: .35rem 0; background: currentColor; transition: transform .2s, opacity .2s; }
.wch-nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(.4rem) rotate(45deg); }
.wch-nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.wch-nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-.4rem) rotate(-45deg); }

@media (max-width: 56rem) {
	.wch-nav-toggle { display: block; }
	.wch-header-phone { display: none; }
	.wch-nav {
		display: none;
		position: absolute; top: 100%; left: 0; right: 0;
		padding: 1rem var(--wch-gap) 2rem;
		background: var(--wch-white);
		border-bottom: 1px solid var(--wch-line);
	}
	.wch-nav.is-open { display: block; }
	.wch-nav ul { flex-direction: column; gap: 0; }
	.wch-nav a { display: block; padding: .8rem 0; border-bottom: 1px solid var(--wch-line); font-size: 1.05rem; }
	.wch-nav-phone { display: block; margin-top: 1.5rem; text-align: center; }
}
@media (min-width: 56.01rem) {
	.wch-nav-phone { display: none; }
}

/* ---------- Sekcje ---------- */
.wch-section { padding-block: var(--wch-section); }
.wch-section-sand { background: var(--wch-sand); }
.wch-section-head { max-width: var(--wch-text); margin-bottom: 3rem; }
.wch-section-head p { color: var(--wch-muted); }

/* ---------- Hero ---------- */
.wch-hero {
	position: relative;
	isolation: isolate;
	overflow: hidden;
	display: grid;
	align-content: center;
	min-height: 78vh;
	min-height: 78svh;
	padding-top: clamp(8rem, 24vw, 20rem);
	padding-bottom:1em;
}
.wch-backdrop {
	position: absolute;
	inset: 0;
	z-index: -1;
	pointer-events: none;
}
.wch-backdrop img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: 0% 2%;
	opacity: .16;
	-webkit-mask-image: linear-gradient(to bottom, #000 0%, #000 55%, transparent 100%);
	mask-image: linear-gradient(to bottom, #000 0%, #000 55%, transparent 100%);
}
.wch-hero-inner {
	max-width: 46rem;
	padding-left: clamp(1.25rem, 4vw, 3rem);
	border-left: 1px solid var(--wch-gold);
}
.wch-hero-kicker { margin-bottom: 1.25rem; color: var(--wch-gold-dark); font: 500 1.35rem/1.3 var(--wch-serif); }
.wch-hero-title { margin-bottom: 1.5rem; letter-spacing: -.01em; }
.wch-hero-lead { max-width: 34rem; margin-bottom: 2.5rem; color: var(--wch-muted); font-size: 1.15rem; }
.wch-hero-actions { display: flex; flex-wrap: wrap; gap: 1rem; }

@media (prefers-reduced-motion: no-preference) {
	.wch-hero-inner { animation: wchReveal .9s ease-out both; }
	@keyframes wchReveal {
		from { opacity: 0; clip-path: inset(0 0 100% 0); }
		to { opacity: 1; clip-path: inset(0 0 0 0); }
	}
}

/* ---------- O mnie ---------- */
.wch-about { display: grid; gap: var(--wch-gap); align-items: start; }
.wch-about-media img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; }
@media (min-width: 56rem) {
	.wch-about.has-media { grid-template-columns: 5fr 7fr; gap: 5rem; }
}

/* ---------- Specjalizacje (indeks) ---------- */
.wch-areas { margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--wch-line); }
.wch-area { border-bottom: 1px solid var(--wch-line); }
.wch-area summary {
	display: grid;
	grid-template-columns: 1fr auto;
	gap: .25rem 2rem;
	padding: 1.75rem 0;
	cursor: pointer;
	list-style: none;
}
.wch-area summary::-webkit-details-marker { display: none; }
.wch-area-title { margin: 0; font-size: clamp(1.6rem, 3vw, 2rem); transition: color .2s; }
.wch-area-intro { grid-column: 1; margin: 0; max-width: 44rem; color: var(--wch-muted); }
.wch-area-icon {
	grid-column: 2; grid-row: 1 / span 2; align-self: center;
	position: relative; width: 1.25rem; height: 1.25rem;
}
.wch-area-icon::before,
.wch-area-icon::after {
	content: ""; position: absolute; top: 50%; left: 0; width: 100%; height: 1px;
	background: var(--wch-gold); transition: transform .25s;
}
.wch-area-icon::after { transform: rotate(90deg); }
.wch-area[open] .wch-area-icon::after { transform: rotate(0); }
.wch-area summary:hover .wch-area-title { color: var(--wch-gold-dark); }

.wch-area-body { max-width: 44rem; padding: 0 0 2rem; }
.wch-area-body ul { margin: 0 0 1.25rem; padding: 0; list-style: none; }
.wch-area-body li { position: relative; padding: .3rem 0 .3rem 1.5rem; }
.wch-area-body li::before { content: ""; position: absolute; left: 0; top: 1.05em; width: .6rem; height: 1px; background: var(--wch-gold); }
.wch-area-body p:last-child { margin-bottom: 0; color: var(--wch-muted); }

/* ---------- Specjalizacje: lista skrócona ---------- */
.wch-areas-compact { display: grid; }
@media (min-width: 42rem) { .wch-areas-compact { grid-template-columns: 1fr 1fr; column-gap: 3rem; } }
.wch-areas-compact li { border-bottom: 1px solid var(--wch-line); }
.wch-areas-compact a {
	display: block;
	padding: 1.1rem 0;
	color: var(--wch-ink);
	font: 500 1.35rem/1.3 var(--wch-serif);
	text-decoration: none;
	transition: color .2s;
}
.wch-areas-compact a:hover { color: var(--wch-gold-dark); }
.wch-areas-more { margin-top: 2.5rem; }

.wch-section-tight { padding-top: 0; }
.wch-areas-intro { padding-bottom: 3rem; }

.wch-cta { max-width: var(--wch-text); }
.wch-cta p:last-child { margin-bottom: 0; }

.wch-area:target > summary .wch-area-title { color: var(--wch-gold-dark); }

/* ---------- Kontakt ---------- */
.wch-contact { display: grid; gap: 3rem; }
@media (min-width: 56rem) { .wch-contact { grid-template-columns: 1fr 1fr; gap: 5rem; } }

.wch-contact-list { margin: 0; }
.wch-contact-list dt { margin-top: 1.5rem; color: var(--wch-muted); font-size: .9rem; }
.wch-contact-list dt:first-child { margin-top: 0; }
.wch-contact-list dd { margin: .15rem 0 0; color: var(--wch-ink); font: 500 1.5rem/1.3 var(--wch-serif); }
.wch-contact-list dd a { color: inherit; text-decoration: none; }
.wch-contact-list dd a:hover { color: var(--wch-gold-dark); }

.wch-directions { white-space: pre-line; }
.wch-directions h3 { white-space: normal; }

/* ---------- Social ---------- */
.wch-social { display: flex; gap: .75rem; margin: 0; padding: 0; list-style: none; }
.wch-social a {
	display: grid; place-items: center; width: 2.5rem; height: 2.5rem;
	border: 1px solid currentColor; border-radius: 50%;
	color: inherit; transition: color .2s;
}
.wch-social a:hover { color: var(--wch-gold); }
.wch-social svg { width: 1.1rem; height: 1.1rem; }

/* ---------- Stopka ---------- */
.wch-footer { padding-block: 4rem 2rem; background: var(--wch-ink); color: #cfcac2; font-size: .95rem; }
.wch-footer a { color: #cfcac2; }
.wch-footer a:hover { color: var(--wch-gold); }
.wch-footer-grid { display: grid; gap: 2.5rem; }
@media (min-width: 48rem) { .wch-footer-grid { grid-template-columns: 2fr 1fr 1fr; } }
.wch-footer .wch-brand-name { color: var(--wch-white); }
.wch-footer-title { margin-bottom: .75rem; color: var(--wch-white); font: 500 1.25rem/1.2 var(--wch-serif); }
.wch-footer p { margin-bottom: .4rem; }
.wch-footer-menu { margin: 0; padding: 0; list-style: none; }
.wch-footer-menu li { margin-bottom: .4rem; }
.wch-footer-bottom {
	display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1rem;
	margin-top: 3rem; padding-top: 1.5rem;
	border-top: 1px solid #3a3a3a; font-size: .85rem; color: #8f8a83;
}

/* ---------- Treść wpisów i stron ---------- */
.wch-page-header { padding-block: clamp(3.5rem, 8vw, 6rem) 2rem; }
.wch-page-header h1 { max-width: var(--wch-text); }

.wch-entry { max-width: var(--wch-text); padding-bottom: var(--wch-section); }
.wch-entry > * + h2, .wch-entry > * + h3 { margin-top: 2.5rem; }
.wch-entry h2 { display:inline-block; padding-bottom:0.2em; border-bottom:2px solid var(--wch-gold)}
.wch-entry ul, .wch-entry ol { padding-left: 1.25rem; }
.wch-entry li { margin-bottom: .4rem; }
.wch-entry blockquote { margin: 2rem 0; padding-left: 1.5rem; border-left: 1px solid var(--wch-gold); font: 500 1.5rem/1.4 var(--wch-serif); color: var(--wch-ink); }
.wch-entry img { margin-block: 2rem; }
.wch-entry .alignwide, .wch-entry .alignfull { max-width: none; }

.wch-post-list { max-width: var(--wch-text); padding-bottom: var(--wch-section); }
.wch-post { padding-block: 2rem; border-bottom: 1px solid var(--wch-line); }
.wch-post h2 { font-size: 1.9rem; }
.wch-post h2 a { color: var(--wch-ink); text-decoration: none; }
.wch-post h2 a:hover { color: var(--wch-gold-dark); }
.wch-post-meta { margin-bottom: .75rem; color: var(--wch-muted); font-size: .9rem; }

.wch-pagination { margin-top: 3rem; }
.wch-pagination .nav-links { display: flex; flex-wrap: wrap; gap: .5rem; }
.wch-pagination .page-numbers { padding: .4rem .8rem; border: 1px solid var(--wch-line); text-decoration: none; }
.wch-pagination .current { border-color: var(--wch-ink); color: var(--wch-ink); }

@media (prefers-reduced-motion: reduce) {
	html { scroll-behavior: auto; }
	*, *::before, *::after { transition: none !important; animation: none !important; }
}

@media print {
	.wch-backdrop, .wch-header, .wch-footer { display: none; }
}
