/*
Theme Name: Venere
Theme URI: https://www.ferramentavenere.com
Description: Tema a blocchi su misura per Ferramenta Venere, Torino. Usa solo blocchi standard di WordPress.
Version: 1.3.3
Requires at least: 6.6
Tested up to: 7.1
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: venere
*/

/* ---------- Base ---------- */
html { scroll-behavior: smooth; }
body { -webkit-font-smoothing: antialiased; }
:where(.wp-site-blocks) > * { margin-block-start: 0; }
img { height: auto; }
.wp-block-post-content > .alignfull,
.wp-block-post-content > .wp-block-pattern > .alignfull,
.wp-block-post-content > * + .alignfull { margin-block-start: 0; }
.wp-block-post-content > .alignfull + * { margin-block-start: 0; }
main > .wp-block-post-content { margin-block-start: 0; }

/* ---------- Testata ---------- */
.venere-header {
	position: sticky;
	top: 0;
	z-index: 50;
	box-shadow: 0 1px 0 rgba(43, 27, 33, 0.08);
}
body.admin-bar .venere-header { top: 32px; }
@media (max-width: 782px) { body.admin-bar .venere-header { top: 0; } }

.venere-topbar a { color: inherit; text-decoration: none; }
.venere-topbar a:hover { color: var(--wp--preset--color--accent); }
@media (max-width: 720px) { .venere-topbar .venere-hide-mobile { display: none; } }

.venere-brand { text-decoration: none; }
.venere-brand a { text-decoration: none; color: inherit; }
.venere-brand .wp-block-image { margin: 0; }
.venere-brand .wp-block-image img { border-radius: 0; }
.venere-brand-name { line-height: 1 !important; }
.venere-brand-tag { line-height: 1.1 !important; letter-spacing: 0.18em; text-transform: uppercase; }

.venere-header .wp-block-navigation a:hover { color: var(--wp--preset--color--primary); }
.venere-header .wp-block-navigation .current-menu-item > a,
.venere-header .wp-block-navigation a[aria-current="page"] {
	color: var(--wp--preset--color--primary);
	text-decoration: underline;
	text-decoration-color: var(--wp--preset--color--accent);
	text-decoration-thickness: 3px;
	text-underline-offset: 8px;
}
@media (max-width: 600px) { .venere-header .venere-header-cta { display: none; } }

/* ---------- Elementi ricorrenti ---------- */
.venere-eyebrow {
	text-transform: uppercase;
	letter-spacing: 0.16em;
	font-weight: 700;
	font-size: 0.8rem !important;
}
.venere-lead { max-width: 640px; margin-left: 0 !important; margin-right: auto !important; }
.has-text-align-center.venere-lead { margin-left: auto !important; }
.venere-page-hero > .venere-lead { margin-left: calc((100% - min(100%, 1200px)) / 2) !important; }

.is-style-outline .wp-block-button__link,
.wp-block-button.is-style-outline > .wp-block-button__link {
	background: transparent;
	border-color: currentColor;
}
.venere-on-dark .is-style-outline > .wp-block-button__link { color: #fff; }
.venere-on-dark .is-style-outline > .wp-block-button__link:hover {
	background: #fff;
	color: var(--wp--preset--color--primary-dark);
	border-color: #fff;
}
.venere-btn-dark .wp-block-button__link {
	background: var(--wp--preset--color--primary-dark);
	border-color: var(--wp--preset--color--primary-dark);
	color: #fff;
}
.venere-btn-dark .wp-block-button__link:hover {
	background: var(--wp--preset--color--primary);
	border-color: var(--wp--preset--color--primary);
}

/* ---------- Hero ---------- */
.venere-hero { overflow: hidden; }
.venere-hero h1 { color: #fff; max-width: 14ch; }
.venere-hero .venere-accent-word { color: var(--wp--preset--color--accent); font-style: italic; }

/* ---------- Striscia punti di forza ---------- */
.venere-trust .wp-block-column { position: relative; }
.venere-trust-num {
	font-family: var(--wp--preset--font-family--heading);
	color: var(--wp--preset--color--primary);
	font-weight: 700;
	line-height: 1 !important;
}

/* ---------- Schede servizi ---------- */
.venere-card {
	padding: 0;
	border-radius: var(--wp--custom--radius--medium);
	overflow: hidden;
	transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.venere-cards .venere-card { height: 100%; }
.venere-card:hover { transform: translateY(-4px); box-shadow: var(--wp--preset--shadow--lift); }
.venere-card .wp-block-image { margin: 0; }
.venere-card .wp-block-image img {
	border-radius: 0;
	width: 100%;
	aspect-ratio: 4 / 3;
	object-fit: cover;
	display: block;
}
.venere-card-body > * + * { margin-block-start: 0.6rem; }
.venere-card a.venere-more,
.venere-more a {
	font-weight: 700;
	text-decoration: none;
	color: var(--wp--preset--color--primary);
}
.venere-more a:hover { text-decoration: underline; }
.venere-cards > .wp-block-column { display: flex; }
.venere-cards > .wp-block-column > .venere-card { flex: 1; }

/* ---------- Immagini ---------- */
.venere-photo img {
	width: 100%;
	object-fit: cover;
	aspect-ratio: 4 / 3;
	box-shadow: var(--wp--preset--shadow--card);
}
.venere-photo-tall img { aspect-ratio: 4 / 5; }
.venere-gallery .wp-block-image img { aspect-ratio: 1 / 1; object-fit: cover; width: 100%; }

/* ---------- Valori numerati ---------- */
.venere-value-num {
	font-family: var(--wp--preset--font-family--heading);
	font-style: italic;
	color: var(--wp--preset--color--accent);
	font-size: 2.6rem !important;
	line-height: 1 !important;
	font-weight: 700;
}
.venere-value { border-top: 3px solid var(--wp--preset--color--accent); }

/* ---------- Banda preventivo ---------- */
.venere-cta-band { border-radius: var(--wp--custom--radius--large); }

/* ---------- Team ---------- */
.venere-avatar {
	width: 96px;
	height: 96px;
	padding: 0 !important;
	box-sizing: border-box;
	border-radius: 50% !important;
	display: flex !important;
	align-items: center;
	justify-content: center;
	margin-left: auto !important;
	margin-right: auto !important;
	font-family: var(--wp--preset--font-family--heading);
	font-size: 2.4rem !important;
	font-weight: 700;
	line-height: 1 !important;
}

/* ---------- Contatti ---------- */
.venere-contact-card a { text-decoration: none; font-weight: 700; }
.venere-contact-card a:hover { text-decoration: underline; }
.venere-form-wrap .wpforms-container { margin: 0 !important; }
.venere-form-wrap .wpforms-submit {
	background: var(--wp--preset--color--accent) !important;
	color: var(--wp--preset--color--contrast) !important;
	border: 0 !important;
	border-radius: 999px !important;
	font-weight: 700 !important;
	padding: 0.8rem 1.8rem !important;
	height: auto !important;
}
.venere-form-wrap .wpforms-submit:hover { background: var(--wp--preset--color--primary) !important; color: #fff !important; }
.venere-form-wrap input:not([type=checkbox]):not([type=radio]),
.venere-form-wrap select,
.venere-form-wrap textarea { border-radius: 8px !important; }

/* ---------- Modulo contatti integrato ---------- */
.venere-cf { scroll-margin-top: 140px; }
.venere-cf-form { display: grid; gap: 1rem; margin-top: 1.25rem; }
.venere-cf-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
@media (max-width: 640px) { .venere-cf-row { grid-template-columns: 1fr; } }
.venere-cf-field { margin: 0 !important; display: flex; flex-direction: column; gap: 0.35rem; }
.venere-cf-field label { font-weight: 600; font-size: 0.95rem; }
.venere-cf-field input,
.venere-cf-field select,
.venere-cf-field textarea {
	width: 100%;
	box-sizing: border-box;
	font: inherit;
	color: var(--wp--preset--color--contrast);
	background: var(--wp--preset--color--cream);
	border: 1.5px solid var(--wp--preset--color--sand);
	border-radius: 10px;
	padding: 0.75rem 0.9rem;
	transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
}
.venere-cf-field textarea { resize: vertical; min-height: 140px; }
.venere-cf-field input:focus,
.venere-cf-field select:focus,
.venere-cf-field textarea:focus {
	outline: none;
	background: #fff;
	border-color: var(--wp--preset--color--primary);
	box-shadow: 0 0 0 3px rgba(114, 24, 56, 0.15);
}
.venere-cf-check { margin: 0 !important; display: flex; gap: 0.6rem; align-items: flex-start; font-size: 0.92rem; color: var(--wp--preset--color--muted); }
.venere-cf-check input { margin-top: 0.25rem; width: 1.1rem; height: 1.1rem; accent-color: var(--wp--preset--color--primary); flex: none; }
.venere-cf-actions { margin: 0.25rem 0 0 !important; display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; }
.venere-cf-actions button { cursor: pointer; }
.venere-cf-note { font-size: 0.85rem; color: var(--wp--preset--color--muted); }
.venere-cf-hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }
.venere-cf-msg { border-radius: 10px; padding: 1rem 1.2rem; margin-top: 1rem; }
.venere-cf-msg ul { margin: 0.4rem 0 0; padding-left: 1.2rem; }
.venere-cf-msg.is-success { background: #e8f5ec; border: 1.5px solid #9fd3b0; color: #1d5c34; }
.venere-cf-msg.is-error { background: #fdecef; border: 1.5px solid #f1a7b7; color: #7a1730; }

/* ---------- Media e testo ---------- */
.venere-media-text .wp-block-media-text__media img {
	border-radius: var(--wp--custom--radius--medium);
	box-shadow: var(--wp--preset--shadow--card);
	aspect-ratio: 4 / 3;
	object-fit: cover;
}
.venere-media-text { scroll-margin-top: 140px; }
.venere-checklist { list-style: none; padding-left: 0 !important; }
.venere-checklist li { position: relative; padding-left: 1.8rem; margin-bottom: 0.4rem; }
.venere-checklist li::before {
	content: "";
	position: absolute;
	left: 0;
	top: 0.45em;
	width: 1.05rem;
	height: 1.05rem;
	border-radius: 50%;
	background: var(--wp--preset--color--accent) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M4 8.5l2.5 2.5L12 5.5' fill='none' stroke='%234A0E24' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 75% no-repeat;
}

/* ---------- Piè di pagina ---------- */
.venere-footer a { color: #fff; text-decoration: none; }
.venere-footer a:hover { color: var(--wp--preset--color--accent); text-decoration: underline; }
.venere-footer .venere-footer-links { list-style: none; padding-left: 0 !important; }
.venere-footer .venere-footer-links li { margin-bottom: 0.35rem; }
.venere-footer .wp-block-image img { border-radius: 0; }

/* ---------- Pagine standard ---------- */
.venere-page-hero h1 { color: #fff; }

/* ---------- Orari e valutazione ---------- */
.venere-hours table { border-collapse: collapse; width: 100%; }
.venere-hours td { border: 0; border-bottom: 1px solid var(--wp--preset--color--sand); padding: 0.55rem 0; }
.venere-hours td:last-child { text-align: right; font-weight: 600; }
.venere-hours tr:last-child td { border-bottom: 0; }
.venere-hours.is-compact td { padding: 0.35rem 0; font-size: 0.95rem; }
.venere-hours { margin-top: 0.5rem !important; }
.venere-rating { margin-top: 1rem !important; }
.venere-rating .venere-stars { color: var(--wp--preset--color--accent); letter-spacing: 0.08em; }
@media (max-width: 1100px) { .venere-topbar .venere-topbar-hours { display: none; } }

/* ---------- Recensioni Google ---------- */
.venere-reviews {
	background: var(--wp--preset--color--cream);
	padding: var(--wp--preset--spacing--70) clamp(1rem, 4vw, 2.5rem);
	margin-top: var(--wp--preset--spacing--70) !important;
}
.venere-reviews-inner { max-width: 1200px; margin: 0 auto; }
.venere-reviews-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 1.5rem; margin-bottom: var(--wp--preset--spacing--50); }
.venere-reviews-head h2 { margin: 0.4rem 0 0; }
.venere-reviews-score { display: flex; align-items: center; gap: 0.9rem; }
.venere-reviews-num { font-family: var(--wp--preset--font-family--heading); font-size: 3.4rem; font-weight: 700; line-height: 1; color: var(--wp--preset--color--primary); }
.venere-reviews-meta { display: flex; flex-direction: column; gap: 0.3rem; color: var(--wp--preset--color--muted); font-size: 0.95rem; }
.venere-stars-bar { position: relative; display: inline-block; font-size: 1rem; line-height: 1; letter-spacing: 0.1em; vertical-align: -1px; }
.venere-stars-bar::before { content: "★★★★★"; color: #e4d9cc; }
.venere-stars-fill { position: absolute; inset: 0 auto 0 0; overflow: hidden; white-space: nowrap; }
.venere-stars-fill::before { content: "★★★★★"; color: var(--wp--preset--color--accent); }
.venere-stars-bar.is-large { font-size: 1.35rem; }
.venere-reviews-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: var(--wp--preset--spacing--40); }
.venere-review { background: #fff; border-radius: var(--wp--custom--radius--medium); box-shadow: var(--wp--preset--shadow--card); padding: 1.4rem 1.4rem 1.1rem; display: flex; flex-direction: column; gap: 0.8rem; }
.venere-review-author { display: flex; align-items: center; gap: 0.75rem; }
.venere-review-author img, .venere-review-initial { width: 40px; height: 40px; border-radius: 50%; flex: none; object-fit: cover; }
.venere-review-initial { display: inline-flex; align-items: center; justify-content: center; background: var(--wp--preset--color--primary); color: var(--wp--preset--color--accent); font-weight: 700; }
.venere-review-author > span { display: flex; flex-direction: column; gap: 0.15rem; }
.venere-review-name { font-weight: 700; color: var(--wp--preset--color--contrast); text-decoration: none; }
a.venere-review-name:hover { text-decoration: underline; }
.venere-review-when { font-size: 0.85rem; color: var(--wp--preset--color--muted); }
.venere-review-text { margin: 0; display: -webkit-box; -webkit-line-clamp: 7; -webkit-box-orient: vertical; overflow: hidden; }
.venere-review-foot { margin-top: auto; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.3rem 0.8rem; font-size: 0.85rem; color: var(--wp--preset--color--muted); }
.venere-review-foot a { font-weight: 700; text-decoration: none; margin-left: auto; white-space: nowrap; }
.venere-reviews-actions { display: flex; flex-wrap: wrap; gap: 0.8rem; margin-top: var(--wp--preset--spacing--50); }
.venere-reviews-actions .wp-element-button { text-decoration: none; display: inline-block; }
.venere-btn-ghost { background: transparent !important; color: var(--wp--preset--color--primary) !important; border-color: var(--wp--preset--color--primary) !important; }
.venere-btn-ghost:hover { background: var(--wp--preset--color--primary) !important; color: #fff !important; }
.venere-reviews-note { font-size: 0.82rem; color: var(--wp--preset--color--muted); margin-top: 1.2rem; }
.venere-gmaps { font-family: Roboto, Arial, sans-serif; font-size: 13px; font-weight: 500; color: #5f6368; }

/* ---------- WhatsApp e social ---------- */
.venere-wa {
	position: fixed;
	right: 18px;
	bottom: 18px;
	z-index: 60;
	display: inline-flex;
	align-items: center;
	gap: 0.55rem;
	background: #25d366;
	color: #fff;
	border-radius: 999px;
	padding: 0.75rem 1.1rem 0.75rem 0.85rem;
	font-weight: 700;
	font-size: 0.98rem;
	text-decoration: none;
	box-shadow: 0 10px 28px rgba(0, 0, 0, 0.22);
	transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.venere-wa:hover, .venere-wa:focus-visible { color: #fff; transform: translateY(-2px); box-shadow: 0 14px 34px rgba(0, 0, 0, 0.28); }
.venere-wa svg { width: 28px; height: 28px; fill: currentColor; flex: none; }
@media (max-width: 600px) {
	.venere-wa { padding: 0.85rem; right: 14px; bottom: 14px; }
	.venere-wa .venere-wa-label { display: none; }
}
.venere-btn-wa .wp-block-button__link { background: #25d366; border-color: #25d366; color: #0b3d1f; }
.venere-btn-wa .wp-block-button__link:hover { background: #1ebe5a; border-color: #1ebe5a; color: #fff; }
.venere-social { margin-bottom: 0.5rem !important; }
.venere-footer .venere-social a:hover { color: #fff; text-decoration: none; }
.venere-footer .venere-social .wp-social-link { transition: transform 0.2s ease; }
.venere-footer .venere-social .wp-social-link:hover { transform: translateY(-2px); }

/* ---------- Mobile ---------- */
@media (max-width: 781px) {
	.venere-hero { min-height: 560px !important; }
	.venere-stack-reverse { flex-direction: column-reverse; }
	.venere-gallery .wp-block-image img { aspect-ratio: 16 / 10; }
	.venere-media-text.has-media-on-the-right .wp-block-media-text__media { grid-row: 1 !important; }
	.venere-media-text.has-media-on-the-right .wp-block-media-text__content { grid-row: 2 !important; }
}

@media (prefers-reduced-motion: reduce) {
	.venere-wa, .venere-wa:hover { transition: none; transform: none; }
	html { scroll-behavior: auto; }
	.venere-card { transition: none; }
	.venere-card:hover { transform: none; }
}
.venere-review-text.is-empty { color: var(--wp--preset--color--muted); font-style: italic; }
