/* ==========================================================================
   Brighenti F.lli – main.css
   ========================================================================== */

:root {
	--c-orange: #d77110;
	--c-orange-dark: #b85d0a;
	--c-cream: #faf5ed;
	--c-sand: #f4eee4;
	--c-card: #efe7da;
	--c-dark: #585857;
	--c-text: #585857;
	--c-muted: #7a7a78;
	--c-white: #fff;
	--c-placeholder: #d9d9d9;

	--f-head: "Bebas Neue", "Oswald", "Arial Narrow", sans-serif;
	--f-body: "Roboto", system-ui, -apple-system, "Segoe UI", sans-serif;

	--container: 1080px;
	--gutter: clamp(16px, 4vw, 32px);
	--section-y: clamp(56px, 7vw, 96px);
	--header-h: 84px;
	--radius: 0;
	--ease: cubic-bezier(.2, .7, .2, 1);
}

/* Reset essenziale ------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { transition: none !important; animation: none !important; } }
body {
	margin: 0;
	background: var(--c-cream);
	color: var(--c-text);
	font: 400 15px/1.6 var(--f-body);
	-webkit-font-smoothing: antialiased;
}
img, svg, video, iframe { display: block; max-width: 100%; }
img { height: auto; }
a { color: inherit; text-decoration: none; }
a:hover { color: var(--c-orange); }
p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }
h1, h2, h3, h4 { margin: 0; font-family: var(--f-head); font-weight: 400; line-height: 1.05; letter-spacing: .01em; }
button { font: inherit; cursor: pointer; }
:focus-visible { outline: 2px solid var(--c-orange); outline-offset: 3px; }
[id] { scroll-margin-top: calc(var(--header-h) - 10px); }

.screen-reader-text {
	position: absolute !important; width: 1px; height: 1px; overflow: hidden;
	clip: rect(1px, 1px, 1px, 1px); white-space: nowrap;
}
.skip-link {
	position: absolute; left: 12px; top: -60px; z-index: 1000;
	background: var(--c-orange); color: #fff; padding: 10px 16px;
}
.skip-link:focus { top: 12px; color: #fff; }

/* Layout ---------------------------------------------------------------- */
.container { width: 100%; max-width: calc(var(--container) + var(--gutter) * 2); margin-inline: auto; padding-inline: var(--gutter); }
.container--narrow { max-width: calc(760px + var(--gutter) * 2); }
.section { padding-block: var(--section-y); }
.section--light { background: var(--c-cream); }
.section--alt { background: var(--c-sand); }
.page-top { padding-top: calc(var(--header-h) + 64px); }

/* Tipografia di sezione -------------------------------------------------- */
.eyebrow {
	margin: 0 0 4px;
	font: 400 20px/1.1 var(--f-head);
	color: var(--c-orange);
	letter-spacing: .02em;
	text-transform: uppercase;
}
.section-title {
	font-size: clamp(30px, 3.4vw, 40px);
	color: var(--c-dark);
	text-transform: uppercase;
	margin-bottom: 20px;
}
.section-title--accent { color: var(--c-orange); }
.section-head { margin-bottom: 40px; }
.section-head--center { text-align: center; }

/* Bottoni ---------------------------------------------------------------- */
.btn {
	display: inline-flex; align-items: center; gap: 8px;
	padding: 10px 20px 8px;
	font: 400 18px/1 var(--f-head);
	letter-spacing: .03em;
	text-transform: uppercase;
	border: 2px solid var(--c-orange);
	border-radius: var(--radius);
	transition: background-color .2s var(--ease), color .2s var(--ease), border-color .2s var(--ease);
}
.btn .icon { width: 18px; height: 18px; margin-top: -2px; }
.btn--solid { background: var(--c-orange); color: #fff; }
.btn--solid:hover { background: var(--c-orange-dark); border-color: var(--c-orange-dark); color: #fff; }
.btn--outline { background: transparent; color: var(--c-orange); }
.btn--outline:hover { background: var(--c-orange); color: #fff; }

/* Righello decorativo --------------------------------------------------- */
.ruler {
	position: absolute; left: 0; right: 0; bottom: 0; height: 26px;
	pointer-events: none;
	background:
		repeating-linear-gradient(90deg, rgba(255,255,255,.55) 0 1px, transparent 1px 60px) left bottom / 100% 26px no-repeat,
		repeating-linear-gradient(90deg, rgba(255,255,255,.4) 0 1px, transparent 1px 30px) left bottom / 100% 18px no-repeat,
		repeating-linear-gradient(90deg, rgba(255,255,255,.28) 0 1px, transparent 1px 6px) left bottom / 100% 10px no-repeat;
}
.ruler--top { top: 0; bottom: auto; transform: scaleY(-1); }

/* ==========================================================================
   Header
   ========================================================================== */
.site-header {
	position: fixed; inset: 0 0 auto; z-index: 100;
	height: var(--header-h);
	display: flex; align-items: center;
	background: var(--c-dark);
	transition: background-color .3s var(--ease), box-shadow .3s var(--ease), height .3s var(--ease);
}
.admin-bar .site-header { top: 32px; }
@media (max-width: 782px) { .admin-bar .site-header { top: 46px; } }
.has-hero .site-header { background: transparent; }
.has-hero .site-header.is-scrolled,
.site-header.is-scrolled { background: rgba(68, 68, 67, .96); box-shadow: 0 6px 24px rgba(0,0,0,.15); --header-h: 68px; }

.site-header__inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; }

.logo { display: inline-flex; align-items: center; color: #fff; }
.logo:hover { color: #fff; }
.logo__img { width: auto; max-height: 34px; }
.logo__text {
	position: relative;
	font: 400 34px/1 var(--f-head);
	letter-spacing: .02em;
	padding-bottom: 5px;
}
.logo__text::after {
	content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 4px;
	background: var(--c-orange);
}

.primary-nav .menu { display: flex; gap: clamp(20px, 3.5vw, 52px); margin: 0; padding: 0; list-style: none; }
.primary-nav a {
	display: block; padding: 6px 0;
	font: 400 17px/1 var(--f-head); letter-spacing: .04em; text-transform: uppercase;
	color: #fff; position: relative;
}
.primary-nav a::after {
	content: ""; position: absolute; left: 0; right: 100%; bottom: 0; height: 2px;
	background: var(--c-orange); transition: right .25s var(--ease);
}
.primary-nav a:hover, .primary-nav .current-menu-item > a { color: #fff; }
.primary-nav a:hover::after, .primary-nav .current-menu-item > a::after { right: 0; }

.nav-toggle {
	display: none; position: relative; width: 44px; height: 44px; padding: 0;
	background: transparent; border: 0; color: #fff;
}
.nav-toggle__bar, .nav-toggle__bar::before, .nav-toggle__bar::after {
	position: absolute; left: 10px; width: 24px; height: 2px; background: currentColor;
	transition: transform .25s var(--ease), opacity .2s;
}
.nav-toggle__bar { top: 21px; }
.nav-toggle__bar::before, .nav-toggle__bar::after { content: ""; left: 0; }
.nav-toggle__bar::before { top: -7px; }
.nav-toggle__bar::after { top: 7px; }
.nav-open .nav-toggle__bar { background: transparent; }
.nav-open .nav-toggle__bar::before { transform: translateY(7px) rotate(45deg); background: #fff; }
.nav-open .nav-toggle__bar::after { transform: translateY(-7px) rotate(-45deg); background: #fff; }

@media (max-width: 860px) {
	.nav-toggle { display: block; z-index: 2; }
	.primary-nav {
		position: fixed; inset: 0; z-index: 1;
		display: flex; align-items: center; justify-content: center;
		background: rgba(58, 58, 57, .98);
		opacity: 0; visibility: hidden; transition: opacity .25s var(--ease), visibility .25s;
	}
	.nav-open .primary-nav { opacity: 1; visibility: visible; }
	.primary-nav .menu { flex-direction: column; align-items: center; gap: 22px; }
	.primary-nav a { font-size: 34px; }
	.nav-open { overflow: hidden; }
}

/* ==========================================================================
   Hero
   ========================================================================== */
.hero {
	position: relative; isolation: isolate;
	min-height: clamp(540px, 82vh, 760px);
	display: flex; align-items: center; justify-content: center;
	padding: calc(var(--header-h) + 40px) 0 90px;
	background: #3d3d3c;
	color: #fff; text-align: center; overflow: hidden;
}
.hero__bg { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; }
.hero::before { content: ""; position: absolute; inset: 0; z-index: -1; background: rgba(60, 60, 59, .68); }
.hero__kicker { margin: 0 0 6px; font: 400 clamp(22px, 2.6vw, 32px)/1 var(--f-head); letter-spacing: .04em; }
.hero__title {
	font-size: clamp(48px, 7.4vw, 92px);
	line-height: .98;
	text-transform: uppercase;
	margin-bottom: 32px;
}
.hero__title p { margin: 0; }
.hero__title strong, .hero__title b, .hero__title em, .hero__title i { color: var(--c-orange); font-weight: 400; font-style: normal; }
.hero .btn { font-size: 20px; padding: 12px 22px 10px; }

/* ==========================================================================
   Cosa facciamo
   ========================================================================== */
.services {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 16px;
}
.services__intro { grid-column: span 2; padding: 4px 32px 24px 0; }
.services__intro .section-title { margin-bottom: 14px; }
.services__text { font-size: 14px; margin-bottom: 24px; max-width: 46ch; }

.service-card {
	background: var(--c-sand);
	padding: 22px 22px 26px;
	transition: transform .3s var(--ease), box-shadow .3s var(--ease);
}
.service-card:hover { transform: translateY(-4px); box-shadow: 0 14px 30px rgba(88, 88, 87, .1); }
.service-card__icon { width: 60px; height: 60px; margin-bottom: 18px; }
.service-card__icon img { width: 100%; height: 100%; object-fit: contain; }
.service-card__title { font-size: 21px; color: var(--c-orange); text-transform: uppercase; margin-bottom: 10px; }
.service-card__text { font-size: 13.5px; line-height: 1.55; }

@media (max-width: 960px) {
	.services { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.services__intro { grid-column: 1 / -1; padding-right: 0; }
}
@media (max-width: 520px) {
	.services { grid-template-columns: 1fr; }
}

/* ==========================================================================
   Chi siamo
   ========================================================================== */
.about {
	display: grid;
	grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
	grid-template-areas: ". head" "media timeline";
	column-gap: 24px;
}
.about__head { grid-area: head; margin-bottom: 18px; }
.about__head .section-title { margin-bottom: 0; }
.about__media { grid-area: media; position: relative; min-height: 360px; }
.about__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.about__img--placeholder { background: var(--c-placeholder); }
.about__timeline { grid-area: timeline; display: grid; gap: 16px; align-content: start; }

.story-card { border: 2px solid var(--c-orange); padding: 22px 26px 24px; background: transparent; }
.story-card__year { font-size: 30px; color: var(--c-orange); margin-bottom: 10px; }
.story-card__text { font-size: 13.5px; line-height: 1.6; }

@media (max-width: 860px) {
	.about { grid-template-columns: 1fr; grid-template-areas: "head" "media" "timeline"; row-gap: 20px; }
	.about__media { min-height: 0; aspect-ratio: 4 / 3; }
}

/* ==========================================================================
   Oltre la tradizione + video
   ========================================================================== */
.tradition { background: var(--c-orange); color: #fff; padding-block: clamp(48px, 6vw, 72px); }
.tradition__title { font-size: clamp(30px, 3.4vw, 40px); text-transform: uppercase; margin-bottom: 16px; }
.tradition__inner p { font-size: 14px; max-width: 92ch; }

.video {
	position: relative; isolation: isolate;
	width: 100%; height: clamp(280px, 38vw, 560px);
	background: #c79a6a; overflow: hidden;
	display: flex; align-items: center; justify-content: center;
}
.video__poster { position: absolute; inset: 0; z-index: -1; width: 100%; height: 100%; object-fit: cover; }
.video__play {
	width: 72px; height: 72px; display: grid; place-items: center;
	background: rgba(250, 245, 237, .9); border: 0; color: var(--c-orange);
	transition: transform .25s var(--ease), background-color .25s;
}
.video__play .icon { width: 34px; height: 34px; stroke-width: 1.4; }
.video__play:hover { transform: scale(1.08); background: #fff; }
.video iframe, .video video { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; background: #000; }

/* ==========================================================================
   Social / Instagram
   ========================================================================== */
.carousel { position: relative; }
.carousel__track {
	display: grid; grid-auto-flow: column;
	grid-auto-columns: calc((100% - 2 * 24px) / 3);
	gap: 24px; margin: 0; padding: 0; list-style: none;
	overflow-x: auto; scroll-snap-type: x mandatory; scroll-behavior: smooth;
	scrollbar-width: none; overscroll-behavior-x: contain;
}
.carousel__track::-webkit-scrollbar { display: none; }
.carousel__slide { scroll-snap-align: start; }
@media (max-width: 860px) { .carousel__track { grid-auto-columns: calc((100% - 16px) / 2); gap: 16px; } }
@media (max-width: 560px) { .carousel__track { grid-auto-columns: 82%; } }

.ig-card { display: block; background: var(--c-sand); padding: 14px; }
.ig-card__media { position: relative; display: block; aspect-ratio: 1; overflow: hidden; background: var(--c-placeholder); }
.ig-card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s var(--ease); }
.ig-card:hover img { transform: scale(1.05); }
.ig-card__badge { position: absolute; top: 10px; right: 10px; color: #fff; filter: drop-shadow(0 1px 3px rgba(0,0,0,.5)); }
.ig-card__badge .icon { fill: currentColor; width: 20px; height: 20px; }

.carousel__dots { display: flex; justify-content: center; gap: 8px; margin-top: 28px; min-height: 14px; }
.carousel__dot {
	width: 22px; height: 14px; padding: 0; border: 0; background: transparent; position: relative;
}
.carousel__dot::before { content: ""; position: absolute; left: 0; right: 0; top: 6px; height: 3px; background: var(--c-muted); transition: background-color .2s; }
.carousel__dot[aria-selected="true"]::before { background: var(--c-orange); }
.carousel__dot:hover::before { background: var(--c-orange-dark); }

.admin-hint { padding: 14px 18px; border: 1px dashed var(--c-orange); background: #fff8ef; font-size: 14px; }
.admin-hint a { color: var(--c-orange); text-decoration: underline; }

/* ==========================================================================
   Contatti
   ========================================================================== */
.contacts { padding-bottom: clamp(48px, 6vw, 72px); }
.contacts__grid {
	display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 32px; align-items: start;
}
.contacts__intro .section-title { margin-bottom: 10px; }
.contacts__intro p { font-size: 13.5px; max-width: 40ch; }
.contacts__item { display: flex; gap: 18px; align-items: flex-start; padding-top: 34px; font-size: 13.5px; }
.contacts__item p { margin: 0; }
.contacts__mail { display: inline-block; border-bottom: 2px solid var(--c-orange); padding-bottom: 2px; margin-bottom: 4px; }
.icon-badge {
	flex: none; width: 44px; height: 44px; display: grid; place-items: center;
	background: var(--c-cream); color: var(--c-orange);
}
@media (max-width: 860px) {
	.contacts__grid { grid-template-columns: 1fr; gap: 0; }
	.contacts__item { padding-top: 24px; }
}

.map { height: clamp(260px, 30vw, 380px); background: #e6eadf; }
.map iframe { width: 100%; height: 100%; border: 0; filter: saturate(.85); }

/* Aiuto + form */
.help__grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 7vw, 96px); }
.help .section-title { margin-bottom: 12px; font-size: clamp(26px, 2.8vw, 34px); }
.help__col > p { font-size: 13.5px; max-width: 46ch; margin-bottom: 22px; }
@media (max-width: 860px) { .help__grid { grid-template-columns: 1fr; } }

.accordion { max-width: 420px; border: 2px solid var(--c-orange); }
.accordion__head {
	margin: 0; padding: 12px 16px 10px;
	background: var(--c-orange); color: #fff;
	font: 400 18px/1 var(--f-head); letter-spacing: .03em; text-transform: uppercase;
}
.accordion__item { border-top: 2px solid var(--c-orange); background: var(--c-cream); }
.accordion__item:first-of-type { border-top: 0; }
.accordion__item summary {
	display: flex; justify-content: space-between; align-items: center; gap: 12px;
	padding: 12px 16px; font-size: 13.5px; cursor: pointer; list-style: none;
}
.accordion__item summary::-webkit-details-marker { display: none; }
.accordion__item summary .icon { width: 20px; height: 20px; flex: none; transition: transform .25s var(--ease); }
.accordion__item[open] summary .icon { transform: rotate(180deg); color: var(--c-orange); }
.accordion__body { padding: 0 16px 16px; font-size: 13.5px; }
.accordion__body img { margin-top: 4px; }

.form { max-width: 420px; }
.form__row { margin-bottom: 18px; }
.form label { display: block; font-size: 13px; font-weight: 500; margin-bottom: 6px; }
.form input[type="text"], .form input[type="email"], .form select {
	width: 100%; height: 40px; padding: 8px 12px;
	font: inherit; font-size: 14px; color: var(--c-text);
	background: transparent; border: 1px solid var(--c-dark); border-radius: 0;
	transition: border-color .2s, box-shadow .2s;
}
.form input:focus, .form select:focus { outline: none; border-color: var(--c-orange); box-shadow: 0 0 0 1px var(--c-orange); }
.form__select { position: relative; }
.form__select select { appearance: none; background: var(--c-dark); color: #fff; border-color: var(--c-dark); padding-right: 40px; }
.form__select .icon { position: absolute; right: 10px; top: 50%; width: 20px; height: 20px; transform: translateY(-50%); color: #fff; pointer-events: none; }
.form__check { display: flex !important; gap: 10px; align-items: flex-start; font-weight: 400 !important; font-size: 12.5px !important; margin: 4px 0 20px; }
.form__check input { margin-top: 3px; accent-color: var(--c-orange); }
.form__check a { text-decoration: underline; }
.form__hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form .btn { padding: 9px 14px 7px; font-size: 17px; }

.form-message { max-width: 420px; padding: 12px 16px; font-size: 14px; border-left: 4px solid; }
.form-message--success { background: #eef6e9; border-color: #4f8a3a; }
.form-message--error { background: #fbeceb; border-color: #c0392b; }

/* ==========================================================================
   Footer
   ========================================================================== */
.site-footer {
	position: relative; background: var(--c-dark); color: #fff;
	padding: 72px 0 28px; font-size: 13px;
}
.site-footer a:hover { color: var(--c-orange); }
.site-footer__grid {
	display: grid; grid-template-columns: 1.5fr 1fr .6fr; gap: 32px; align-items: end;
}
.site-footer__grid { position: relative; }
.site-footer__grid::after {
	content: ""; position: absolute; left: calc(var(--gutter) + 48px); right: var(--gutter); bottom: 0; height: 6px;
	background: var(--c-orange); z-index: 0;
}
.site-footer__brand { align-self: end; }
.logo--footer .logo__img { max-height: 64px; }
.logo--footer .logo__text { font-size: clamp(44px, 6vw, 72px); padding-bottom: 0; }
.logo--footer .logo__text::after { display: none; }
.logo--footer { position: relative; z-index: 1; padding-bottom: 10px; }
.site-footer__col { align-self: start; padding-bottom: 34px; }
.site-footer__title { font-size: 17px; letter-spacing: .04em; text-transform: uppercase; margin: 0 0 14px; }
.site-footer__col .site-footer__title + * + .site-footer__title { margin-top: 18px; }
.site-footer__hours p { margin: 0; }
.contact-list { margin: 0; padding: 0; list-style: none; display: grid; gap: 14px; }
.contact-list--compact { gap: 10px; }
.contact-list li { display: flex; gap: 12px; align-items: flex-start; }
.contact-list .icon { flex: none; width: 20px; height: 20px; color: var(--c-orange); }
.contact-list__text p { margin: 0; }
.site-footer__legal { margin-top: 32px; text-align: center; font-size: 12px; color: rgba(255,255,255,.85); }
.legal-menu { display: flex; justify-content: center; gap: 6px; margin: 0; padding: 0; list-style: none; }
.legal-menu li + li::before { content: "-"; margin-right: 6px; }

@media (max-width: 860px) {
	.site-footer__grid { grid-template-columns: 1fr 1fr; }
	.site-footer__brand { grid-column: 1 / -1; order: 3; }
}
@media (max-width: 520px) {
	.site-footer__grid { grid-template-columns: 1fr; }
}

/* ==========================================================================
   Pagine interne / News
   ========================================================================== */
.post-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 24px; }
.post-card__link { display: block; height: 100%; background: var(--c-sand); padding: 14px 14px 22px; }
.post-card__media { display: block; aspect-ratio: 1; overflow: hidden; margin-bottom: 14px; }
.post-card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s var(--ease); }
.post-card__link:hover img { transform: scale(1.04); }
.post-card__date { font-size: 12px; color: var(--c-muted); }
.post-card__title { font-size: 24px; color: var(--c-orange); margin: 4px 0 8px; }
.post-card__excerpt { font-size: 13.5px; color: var(--c-text); }
.pagination { margin-top: 40px; }
.pagination .nav-links { display: flex; gap: 8px; flex-wrap: wrap; }
.pagination .page-numbers { padding: 6px 12px; border: 1px solid var(--c-orange); color: var(--c-orange); }
.pagination .page-numbers.current, .pagination a.page-numbers:hover { background: var(--c-orange); color: #fff; }

.entry-media { margin: 0 0 32px; }
.entry-content { font-size: 16px; line-height: 1.75; }
.entry-content h2, .entry-content h3 { color: var(--c-dark); margin: 1.6em 0 .5em; font-size: 28px; }
.entry-content a { color: var(--c-orange); text-decoration: underline; }
.entry-content img { margin-block: 1.5em; }
.entry-content ul, .entry-content ol { padding-left: 1.3em; }
.post-nav { display: flex; justify-content: space-between; gap: 24px; margin-top: 48px; padding-top: 24px; border-top: 1px solid var(--c-card); font-size: 14px; }
.post-nav a { color: var(--c-orange); }
.page-404 .btn { margin-top: 16px; }

/* Animazione d'ingresso (attivata da JS) ---------------------------------- */
.js .reveal { opacity: 0; transform: translateY(18px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.js .reveal.is-visible { opacity: 1; transform: none; }
