/* Cerrajero 24h Reus – clean professional UI */
@import url('https://fonts.googleapis.com/css2?family=DM+Sans:ital,opsz,wght@0,9..40,400;0,9..40,500;0,9..40,600;0,9..40,700&display=swap');

:root {
	--bg: #f8f9fb;
	--bg-white: #ffffff;
	--bg-tint: #f0f4f8;
	--text: #1a202c;
	--text-muted: #4a5568;
	--text-soft: #718096;
	--primary: #0d3b66;
	--primary-hover: #0a2d4d;
	--primary-light: rgba(13, 59, 102, 0.08);
	--border: #e2e8f0;
	--border-light: #edf2f7;
	--success: #0d9488;
	--success-hover: #0f766e;
	--radius: 10px;
	--radius-sm: 8px;
	--container: 1120px;
	--prose: 65ch;
	--shadow: 0 1px 3px rgba(0,0,0,.06);
	--shadow-md: 0 4px 12px rgba(0,0,0,.06);
	--shadow-lg: 0 12px 28px rgba(0,0,0,.08);
}

*, *::before, *::after { box-sizing: border-box; }
body {
	margin: 0;
	font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, sans-serif;
	font-size: 1rem;
	line-height: 1.6;
	color: var(--text);
	background: var(--bg);
	-webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ----- Top bar ----- */
.top-bar {
	background: var(--primary);
	color: #fff;
	padding: 0.5rem 0;
	font-size: 0.8125rem;
	font-weight: 500;
}
.top-bar-inner {
	max-width: var(--container);
	margin: 0 auto;
	padding: 0 1.5rem;
	display: flex;
	justify-content: space-between;
	align-items: center;
}
.top-bar a { color: rgba(255,255,255,0.92); }
.top-bar a:hover { color: #fff; text-decoration: none; }

/* ----- Header ----- */
.site-header {
	background: var(--bg-white);
	box-shadow: var(--shadow);
}
.header-inner {
	max-width: var(--container);
	margin: 0 auto;
	padding: 1rem 1.5rem;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1.5rem;
	flex-wrap: wrap;
}
.site-logo {
	display: inline-block;
	width: 264px;
	height: 50px;
	background: transparent url('/assets/servei-cerrajero-reus-logo.png') left center/contain no-repeat;
	text-indent: -9999px;
	overflow: hidden;
	white-space: nowrap;
}
.site-logo:hover { text-decoration: none; }
.logo {
	display: inline-block;
	width: 264px;
	height: 50px;
	background: transparent url('/assets/servei-cerrajero-reus-logo.png') left center/contain no-repeat;
	text-indent: -9999px;
	overflow: hidden;
	white-space: nowrap;
}
.logo:hover { text-decoration: none; }

.main-nav {
	display: flex;
	align-items: center;
	gap: 0.125rem;
}
.main-nav a {
	color: var(--text);
	padding: 0.5rem 0.875rem;
	font-weight: 500;
	font-size: 0.9375rem;
	border-radius: var(--radius-sm);
	transition: background .15s, color .15s;
}
.main-nav a:hover {
	background: var(--bg-tint);
	text-decoration: none;
	color: var(--primary);
}

.header-cta { display: flex; align-items: center; gap: 0.5rem; }
.btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 0.4rem;
	padding: 0.625rem 1.25rem;
	font-size: 0.9375rem;
	font-weight: 600;
	font-family: inherit;
	border-radius: var(--radius-sm);
	border: none;
	cursor: pointer;
	text-decoration: none;
	transition: background .2s, color .2s, transform .1s;
}
.btn:active { transform: scale(0.98); }
.btn-phone { background: var(--primary); color: #fff; }
.btn-phone:hover { background: var(--primary-hover); color: #fff; text-decoration: none; }
.btn-whatsapp { background: var(--success); color: #fff; }
.btn-whatsapp:hover { background: var(--success-hover); color: #fff; text-decoration: none; }
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-hover); color: #fff; text-decoration: none; }
.btn-outline { background: transparent; color: var(--primary); border: 2px solid var(--primary); }
.btn-outline:hover { background: var(--primary-light); color: var(--primary); text-decoration: none; }

/* ----- Hero (home) ----- */
.hero {
	background: linear-gradient(145deg, var(--primary) 0%, #0a2d4d 100%);
	color: #fff;
	padding: 3.5rem 1.5rem;
	text-align: center;
	position: relative;
}
.hero::after {
	content: none;
}
.hero-inner { max-width: 560px; margin: 0 auto; position: relative; z-index: 1; }
.hero h1 {
	margin: 0 0 0.75rem;
	font-size: 1.875rem;
	font-weight: 700;
	letter-spacing: -0.02em;
	line-height: 1.2;
}
.hero .hero-lead {
	margin: 0 0 1.75rem;
	font-size: 1.0625rem;
	opacity: 0.95;
	line-height: 1.5;
	color: rgba(255,255,255,0.95);
}
.hero .hero-cta {
	display: flex;
	flex-wrap: wrap;
	gap: 0.75rem;
	justify-content: center;
}
.hero .btn-phone { background: #fff; color: var(--primary); }
.hero .btn-phone:hover { background: #f0f4f8; color: var(--primary); }
.hero .btn-whatsapp { background: var(--success); color: #fff; }

@media (min-width: 640px) {
	.hero { padding: 4rem 1.5rem; }
	.hero h1 { font-size: 2.25rem; }
}

/* ----- Page header (inner pages) ----- */
.page-header {
	background: var(--bg-white);
	border-bottom: 1px solid var(--border);
	padding: 2rem 1.5rem;
}
.page-header-inner { max-width: var(--container); margin: 0 auto; }
.page-title {
	margin: 0;
	font-size: 1.75rem;
	font-weight: 700;
	color: var(--text);
	letter-spacing: -0.02em;
}
.page-header .breadcrumb { margin-top: 0.75rem; }

/* ----- Main content ----- */
.main-content {
	padding: 2.5rem 1.5rem 3.5rem;
	min-height: 40vh;
	background: var(--bg-white);
}
.content-inner {
	max-width: var(--container);
	margin: 0 auto;
	width: 100%;
}

/* Content blocks – sections with subtle bg for visual hierarchy */
.content-block {
	background: var(--bg-tint);
	border-radius: var(--radius);
	padding: 1.75rem 1.5rem;
	margin-bottom: 1.5rem;
	border: 1px solid var(--border-light);
}
.content-block:last-child { margin-bottom: 0; }
.content-block h2 {
	font-size: 1.25rem;
	font-weight: 700;
	color: var(--text);
	margin: 0 0 0.75rem;
	padding-bottom: 0.5rem;
	border-bottom: 2px solid var(--primary);
	display: inline-block;
}
.content-block p { margin: 0 0 0.75rem; color: var(--text-muted); font-size: 0.9375rem; line-height: 1.65; }
.content-block p:last-child { margin-bottom: 0; }
.content-block ul { margin: 0 0 0.75rem; padding-left: 1.25rem; }
.content-block li { margin: 0.25rem 0; }
.content-block a { color: var(--primary); font-weight: 600; }
.content-block a:hover { text-decoration: underline; }

/* Section heading (standalone) */
.section-heading {
	font-size: 1.375rem;
	font-weight: 700;
	color: var(--text);
	margin: 0 0 1.25rem;
	padding-bottom: 0.5rem;
	border-bottom: 3px solid var(--primary);
	display: inline-block;
}

/* Prose (general long text) */
.prose { max-width: var(--prose); }
.prose p { margin: 0 0 1rem; color: var(--text-muted); }
.prose p:last-child { margin-bottom: 0; }
.prose h2 { font-size: 1.25rem; margin: 1.5rem 0 0.75rem; font-weight: 600; color: var(--text); }
.prose ul { margin: 0 0 1rem; padding-left: 1.25rem; }

/* Home prose – when used inside content-block, no extra bg */
.home-prose { max-width: none; }
.home-prose p { margin: 0 0 0.75rem; color: var(--text-muted); font-size: 0.9375rem; line-height: 1.65; }
.home-prose p:last-child { margin-bottom: 0; }
.home-prose h2 {
	font-size: 1.25rem;
	font-weight: 700;
	color: var(--text);
	margin: 1.25rem 0 0.5rem;
	padding-bottom: 0.35rem;
	border-bottom: 2px solid var(--primary);
	display: inline-block;
}
.home-prose h2:first-of-type { margin-top: 0; }
.home-prose ul { margin: 0 0 0.75rem; padding-left: 1.25rem; }
.home-prose li { margin: 0.2rem 0; }
.home-prose a { color: var(--primary); font-weight: 600; }
.home-prose a:hover { text-decoration: underline; }

/* ----- Cards (services, zones, features) ----- */
.card-grid {
	display: grid;
	grid-template-columns: 1fr;
	gap: 1.25rem;
	margin: 0;
}
.card {
	background: var(--bg-white);
	border: 1px solid var(--border);
	border-radius: var(--radius);
	padding: 1.5rem 1.5rem;
	transition: box-shadow .2s, border-color .2s, transform .1s;
	box-shadow: var(--shadow);
}
.card:hover {
	box-shadow: var(--shadow-md);
	border-color: var(--primary);
	transform: translateY(-2px);
}
.card h2, .card h3 { margin: 0 0 0.5rem; font-size: 1.125rem; font-weight: 600; color: var(--text); }
.card h2 a, .card h3 a { color: var(--primary); }
.card h2 a:hover, .card h3 a:hover { text-decoration: none; color: var(--primary-hover); }
.card p { margin: 0; font-size: 0.9375rem; color: var(--text-muted); line-height: 1.55; }
.card .link {
	display: inline-flex;
	align-items: center;
	gap: 0.35rem;
	margin-top: 1rem;
	padding: 0.5rem 1rem;
	font-weight: 600;
	font-size: 0.875rem;
	background: var(--primary);
	color: #fff;
	border-radius: var(--radius-sm);
	transition: background .2s;
}
.card .link:hover { background: var(--primary-hover); color: #fff; text-decoration: none; }
.card .link::after { content: '→'; }

/* Zone cards – with optional icon area */
.zone-card {
	display: block;
	background: var(--bg-white);
	border: 1px solid var(--border);
	border-radius: var(--radius);
	padding: 1.5rem;
	text-decoration: none;
	color: inherit;
	transition: box-shadow .2s, border-color .2s, transform .1s;
	box-shadow: var(--shadow);
}
.zone-card:hover {
	text-decoration: none;
	box-shadow: var(--shadow-md);
	border-color: var(--primary);
	transform: translateY(-2px);
}
.zone-card .zone-card-title {
	font-size: 1.0625rem;
	font-weight: 600;
	color: var(--primary);
	margin: 0 0 0.25rem;
}
.zone-card .zone-card-desc {
	font-size: 0.875rem;
	color: var(--text-muted);
	margin: 0;
	line-height: 1.45;
}
.zone-card-grid {
	display: grid;
	grid-template-columns: 1fr;
	gap: 1rem;
	margin: 0;
}
@media (min-width: 480px) {
	.zone-card-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 768px) {
	.card-grid { grid-template-columns: repeat(2, 1fr); }
	.zone-card-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (min-width: 900px) {
	.card-grid { grid-template-columns: repeat(3, 1fr); }
}

/* Legacy zone list (simple links) – keep for backward compat, style as minimal list */
.zone-list { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 0.5rem; }
.zone-list li { margin: 0; }
.zone-list a { font-weight: 500; }

/* ----- Contact page ----- */
.contact-block {
	background: var(--bg-tint);
	border: 1px solid var(--border-light);
	border-radius: var(--radius);
	padding: 1.5rem 1.5rem;
	margin-bottom: 1rem;
}
.contact-block:last-of-type { margin-bottom: 0; }
.contact-block h2 { margin: 0 0 0.5rem; font-size: 1rem; font-weight: 600; color: var(--text-muted); text-transform: uppercase; letter-spacing: .04em; }
.contact-block p { margin: 0.25rem 0; font-size: 0.9375rem; color: var(--text); }
.contact-block a { font-weight: 500; }

/* ----- Conversion block ----- */
.conversion-box {
	margin-top: 1.5rem;
	padding: 1.25rem;
	border: 1px solid var(--border);
	border-radius: var(--radius);
	background: var(--bg-tint);
}
.conversion-box h2 {
	margin: 0 0 0.6rem;
	font-size: 1.1rem;
	color: var(--text);
}
.conversion-box p {
	margin: 0 0 0.75rem;
	font-size: 0.9375rem;
	color: var(--text-muted);
}
.trust-list {
	margin: 0 0 0.9rem;
	padding-left: 1.1rem;
	color: var(--text-muted);
}
.trust-list li { margin: 0.2rem 0; }
.cta-row {
	display: flex;
	flex-wrap: wrap;
	gap: 0.65rem;
}

/* ----- FAQ ----- */
.faq-list { border-top: 1px solid var(--border); }
.faq-list details {
	border-bottom: 1px solid var(--border);
	background: var(--bg-white);
}
.faq-list summary {
	cursor: pointer;
	padding: 1rem 0;
	font-weight: 600;
	list-style: none;
	font-size: 0.9375rem;
	color: var(--text);
}
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary::after { content: "+"; float: right; color: var(--text-soft); font-size: 1.25rem; }
.faq-list details[open] summary::after { content: "−"; }
.faq-list .answer { padding: 0 0 1rem; color: var(--text-muted); font-size: 0.9375rem; line-height: 1.6; }

/* ----- Breadcrumb ----- */
.breadcrumb { font-size: 0.8125rem; color: var(--text-soft); }
.breadcrumb a { color: var(--text-soft); }
.breadcrumb a:hover { color: var(--primary); }

/* ----- Footer ----- */
.site-footer {
	background: var(--text);
	color: rgba(255,255,255,0.88);
	padding: 2.5rem 1.5rem 1.5rem;
	margin-top: 0;
}
.footer-inner { max-width: var(--container); margin: 0 auto; }
.footer-grid {
	display: grid;
	grid-template-columns: 1fr;
	gap: 2rem;
	margin-bottom: 2rem;
}
.footer-col h3 {
	margin: 0 0 0.75rem;
	font-size: 0.8125rem;
	font-weight: 600;
	color: #fff;
	text-transform: uppercase;
	letter-spacing: 0.05em;
}
.footer-col ul { list-style: none; padding: 0; margin: 0; }
.footer-col li { margin: 0.35rem 0; }
.footer-col a { color: rgba(255,255,255,0.85); }
.footer-col a:hover { color: #fff; text-decoration: none; }
.footer-col p { margin: 0.35rem 0; font-size: 0.9375rem; color: rgba(255,255,255,0.85); }

.footer-bottom {
	padding-top: 1.5rem;
	border-top: 1px solid rgba(255,255,255,0.12);
	font-size: 0.8125rem;
	color: rgba(255,255,255,0.6);
}
.footer-bottom a { color: rgba(255,255,255,0.85); }

@media (min-width: 640px) {
	.footer-grid { grid-template-columns: repeat(3, 1fr); }
}

/* ----- Sticky CTA ----- */
.sticky-cta {
	position: fixed;
	bottom: 0;
	left: 0;
	right: 0;
	background: var(--primary);
	padding: 0.75rem 1rem;
	display: flex;
	gap: 0.75rem;
	justify-content: center;
	align-items: center;
	z-index: 1000;
	box-shadow: 0 -4px 20px rgba(0,0,0,.15);
}
.sticky-cta .btn { flex: 1; max-width: 180px; }
.sticky-cta .btn-phone { background: #fff; color: var(--primary); }
.sticky-cta .btn-phone:hover { background: #f0f4f8; color: var(--primary); }
.sticky-cta .btn-whatsapp { background: var(--success); color: #fff; }
.main-wrap { padding-bottom: 76px; }

/* ----- Cookie banner ----- */
.cookie-banner {
	position: fixed;
	bottom: 0;
	left: 0;
	right: 0;
	background: var(--primary);
	color: #fff;
	padding: 1rem 1.5rem;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 1rem;
	z-index: 1001;
	box-shadow: 0 -2px 16px rgba(0,0,0,.2);
}
.cookie-banner p { margin: 0; font-size: 0.9375rem; flex: 1; min-width: 200px; }
.cookie-banner a { color: rgba(255,255,255,0.95); text-decoration: underline; }
.cookie-banner .btn { background: #fff; color: var(--primary); }
body.cookies-accepted .cookie-banner { display: none; }

/* ----- Intro strip (for inner pages) ----- */
.intro-strip {
	background: var(--bg-tint);
	border-radius: var(--radius);
	padding: 1.25rem 1.5rem;
	margin-bottom: 1.5rem;
	border-left: 4px solid var(--primary);
}
.intro-strip p { margin: 0; font-size: 0.9375rem; color: var(--text-muted); line-height: 1.6; }

/* ----- Legacy / CA compatibility ----- */
.section { padding: 2rem 1.5rem; max-width: var(--container); margin: 0 auto; }
.section h2 { font-size: 1.25rem; margin: 0 0 1rem; font-weight: 600; }
.service-grid { display: grid; grid-template-columns: 1fr; gap: 1rem; }
@media (min-width: 640px) { .service-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 900px) { .service-grid { grid-template-columns: repeat(3, 1fr); } }
.service-card {
	background: var(--bg-white);
	border: 1px solid var(--border);
	border-radius: var(--radius);
	padding: 1.25rem;
}
.service-card h3 { margin: 0 0 0.5rem; font-size: 1rem; font-weight: 600; }
.service-card p { margin: 0; font-size: 0.9375rem; color: var(--text-muted); }
.zones-list { background: var(--bg-tint); border: 1px solid var(--border-light); border-radius: var(--radius); padding: 1.25rem; }
.zones-list ul { margin: 0; padding-left: 1.25rem; }
.faq details { border-bottom: 1px solid var(--border); }
.faq summary { cursor: pointer; padding: 0.75rem 0; font-weight: 600; list-style: none; }
.faq .answer, .faq div { padding: 0 0 1rem; color: var(--text-muted); font-size: 0.9375rem; }
