/**
Theme Name: DGR Infissi
Author: Goon Italia
Author URI: https://goonitalia.it
Description: DGR Infissi theme by Goon Italia
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: dgr-infissi
Template: astra
*/


/* --------------------------------------------------------------------------
   Occasioni - griglia prodotti del momento
   -------------------------------------------------------------------------- */

.dgr-occasioni {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
	gap: 32px;
}

.dgr-occasione {
	display: flex;
	flex-direction: column;
	background: #fff;
	border: 1px solid #e6e6e6;
	border-radius: 4px;
	overflow: hidden;
}

.dgr-occasione__foto {
	position: relative;
	aspect-ratio: 4 / 3;
	background: #f3f3f3;
}

.dgr-occasione__foto img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.dgr-occasione__badge {
	position: absolute;
	top: 12px;
	left: 12px;
	padding: 5px 10px;
	font-size: 12px;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	color: #fff;
	background: #bf1b25;
}

.dgr-occasione__badge--prenotato {
	background: #4a4a4a;
}

.dgr-occasione__testo {
	display: flex;
	flex: 1;
	flex-direction: column;
	padding: 20px;
}

.dgr-occasione__categoria {
	margin: 0 0 6px;
	font-size: 12px;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: #7a7a7a;
}

.dgr-occasione__titolo {
	margin: 0 0 10px;
	font-size: 20px;
	line-height: 1.25;
}

.dgr-occasione__descrizione {
	margin: 0 0 16px;
	font-size: 15px;
	line-height: 1.5;
	color: #4a4a4a;
}

.dgr-occasione__dati {
	margin: 0 0 16px;
	padding: 0;
	list-style: none;
	font-size: 14px;
}

.dgr-occasione__dati li {
	display: flex;
	gap: 8px;
	padding: 7px 0;
	border-top: 1px solid #efefef;
}

.dgr-occasione__dati li span {
	flex: 0 0 100px;
	color: #7a7a7a;
}

.dgr-occasione__prezzo {
	margin: auto 0 16px;
	font-size: 26px;
	font-weight: 700;
	line-height: 1.2;
	color: #bf1b25;
}

.dgr-occasione__cta {
	display: block;
	padding: 13px 20px;
	border-radius: 2px;
	background: #bf1b25;
	color: #fff;
	font-size: 15px;
	font-weight: 600;
	text-align: center;
	text-decoration: none;
}

.dgr-occasione__cta:hover,
.dgr-occasione__cta:focus {
	background: #991520;
	color: #fff;
}

.dgr-occasione--venduto {
	opacity: 0.7;
}

.dgr-occasione--venduto .dgr-occasione__prezzo {
	color: #4a4a4a;
	text-decoration: line-through;
}

.dgr-occasioni-vuoto {
	margin: 0;
	padding: 32px;
	background: #f7f7f7;
	color: #5a5a5a;
	text-align: center;
}

@media (max-width: 480px) {

	.dgr-occasioni {
		grid-template-columns: 1fr;
		gap: 24px;
	}
}

.dgr-occasioni-nota {
	margin: 24px 0 0;
	font-size: 13px;
	line-height: 1.5;
	color: #7a7a7a;
}


.dgr-occasione__codice {
	margin: 0 0 8px;
	font-size: 12px;
	letter-spacing: 0.04em;
	color: #9a9a9a;
}

/* --------------------------------------------------------------------------
   Modale richiesta informazioni
   -------------------------------------------------------------------------- */

#dgr-modale {
	display: none;
	position: fixed;
	inset: 0;
	z-index: 9999;
	padding: 24px 16px;
	overflow-y: auto;
	background: rgba(20, 20, 20, 0.72);
}

#dgr-modale.is-aperta {
	display: flex;
	align-items: flex-start;
	justify-content: center;
}

#dgr-modale > .e-con-inner {
	position: relative;
	width: 100%;
	max-width: 520px;
	margin: auto;
	padding: 32px 28px 28px;
	border-radius: 4px;
	background: #fff;
	box-shadow: 0 18px 50px rgba(0, 0, 0, 0.3);
}

.dgr-modale__chiudi {
	position: absolute;
	top: 8px;
	right: 10px;
	width: 40px;
	height: 40px;
	padding: 0;
	border: 0;
	background: none;
	color: #8a8a8a;
	font-size: 30px;
	line-height: 1;
	cursor: pointer;
}

.dgr-modale__chiudi:hover,
.dgr-modale__chiudi:focus {
	color: #bf1b25;
}

.dgr-modale__oggetto {
	margin: 0 0 20px;
	padding: 12px 14px;
	border-left: 3px solid #bf1b25;
	background: #f7f7f7;
	font-size: 15px;
	font-weight: 600;
	line-height: 1.35;
	color: #2a2a2a;
}

.dgr-modale__oggetto:empty {
	display: none;
}

body.dgr-modale-aperta {
	overflow: hidden;
}

#dgr-modale .elementor-button[type="submit"] {
	background-color: #bf1b25;
	color: #fff;
	font-weight: 600;
}

#dgr-modale .elementor-button[type="submit"]:hover,
#dgr-modale .elementor-button[type="submit"]:focus {
	background-color: #991520;
}

/* Dentro l'editor di Elementor la modale deve restare visibile e modificabile:
   qui non e' un overlay ma un normale blocco in fondo alla pagina. */

body.elementor-editor-active #dgr-modale {
	display: block;
	position: static;
	padding: 0;
	overflow: visible;
	background: none;
}

body.elementor-editor-active #dgr-modale > .e-con-inner {
	max-width: 560px;
	margin: 0 auto;
	border: 1px dashed #c9c9c9;
	box-shadow: none;
}
