@charset "utf-8";

/* ============================
	FONT
   ============================ */

@font-face {
	font-display: swap;
	font-family: 'DunbarTall';
	font-style: normal;
	font-weight: 400;
	src: url('../fonts/DUNBARTALLBOOK.TTF') format('truetype');
}

@font-face {
	font-display: swap;
	font-family: 'DunbarTall';
	font-style: normal;
	font-weight: 700;
	src: url('../fonts/DUNBARTALLBOLD.TTF') format('truetype');
}

/* ============================
	DESIGN TOKENS
   ============================ */

:root {
	/* Fonts */
	--font-primary: 'DunbarTall', sans-serif;

	/* Primary Colors */
	--color-white: #FFFFFF;
	--color-black: #000000;

	/* Secondary Colors – Group 1 */
	--color-purple: #8B44AC;
	--color-red:    #C41230;
	--color-blue:   #1A4FA3;
	--color-pink:   #E91E8C;

	/* Secondary Colors – Group 2 */
	--color-orange: #f7941d;
	--color-green:  #39B54A;
	--color-cyan:   #29ABE2;
	--color-yellow: #FFD700;

	/* UI Aliases */
	--color-text:         #333333;
	--color-text-dark:    #000000;
	--color-text-muted:   #666666;
	--color-bg-light:     #F3F3F3;
	--color-bg-white:     #FFFFFF;
	--color-accent:       var(--color-red);
	--color-button:       var(--color-red);
	--color-button-dark:  #ad1613;
	--color-modal-bg:     #4D7BBC;
}

.text-orange {
	color: var(--color-orange)!important;
}
.text-blue {
	color: var(--color-blue)!important;
}
.text-green {
	color: var(--color-green)!important;
}
.text-purple {
	color: var(--color-orange)!important;
}
.text-red {
	color: var(--color-red) !important;
}

.bg_blu {
	background-color: var(--color-blue);
color: var(--color-bg-white);
border-radius: 50px;
}
/* ============================
	GENERALI 
   ============================ */

body {
	font-family: var(--font-primary);
	font-weight: 400;
	font-style: normal;
	font-size: 14px;
	color: var(--color-text);
	background-color: var(--color-orange);
}
.row {
	margin-left:0px;
	margin-right:0px;
}

h1, h2 {
	font-family: var(--font-primary);
	color: var(--color-text-dark);
}

a {
	text-decoration: none;
}

.text-red {
	color: var(--color-red);
}
.bg_orange {
	background-color: var(--color-orange);
}
.bg-page {
	background-image: url('../img/page.jpg');
	background-position: top center;
	background-size: cover;
	background-repeat: no-repeat;
	background-attachment: scroll;
}
.bg-quaderno {
	background-image: url('../img/quadreno.jpg');
	background-position: top center;
	background-size: contain;
	background-repeat: repeat-y;
	background-attachment: scroll;
	position: relative;
}
.bg-quaderno:before {
	position: absolute;
	top:0px;
	right:0px;
	content: url('../img/flip.png');
	z-index: 3000;
	pointer-events: none;
}

@media screen and (max-width: 760px) {
.bg-quaderno:before {
		position: absolute;
		top: 0px;
		right: 0px;
		content: url('../img/flip_small.png');
		z-index: 3000;
	}
}

/* ============================
	MENU
   ============================ */

.skip-to-main-content-link {
	position: absolute;
	left: -9999px;
	z-index: 999;
	padding: 1em;
	background-color: var(--color-black);
	color: var(--color-white);
	opacity: 0;
}
.skip-to-main-content-link:focus {
	left: 50%;
	transform: translateX(-50%);
	opacity: 1;
}

#menu {
	background-color: var(--color-bg-white);
}

#menu .navbar-brand img {
	max-width: 180px;
}

#menu .navbar-toggler {
	border: none;
	padding: 0;
	margin: 10px 0;
	font-size: 1.8rem;
	color: var(--color-text-dark);
	line-height: 1;
}
#menu .navbar-toggler:focus {
	box-shadow: none;
	outline: none;
}

/* hamburger visible by default, X hidden */
#menu .navbar-toggler .toggler-open  { display: inline; }
#menu .navbar-toggler .toggler-close { display: none; }

/* swap icons when Bootstrap sets aria-expanded="true" */
#menu .navbar-toggler[aria-expanded="true"] .toggler-open  { display: none; }
#menu .navbar-toggler[aria-expanded="true"] .toggler-close { display: inline; }

#menu .nav-link {
	font-family: var(--font-primary);
	color: var(--color-text-muted);
	font-weight: 700;
	font-size: 16px;
	padding: 5px 10px;
	text-decoration: none;
}
#menu .nav-link:hover,
#menu .nav-link.active {
	color: var(--color-text-dark);
}

@media (max-width: 991px) {
	#menu .nav-link {
		text-align: right;
	}
}

.modal-body {
	background-color: var(--color-bg-white);
}

/* ============================
	CAROUSEL
   ============================ */

/*
 * Both controls are pulled out of their default left/right edges
 * and repositioned side-by-side at the bottom-centre, just above
 * the indicators.
 *
 * Desktop (44px buttons, 8px gap): total row = 96px
 *   prev  left = 50% - 48px   next  left = 50% + 4px
 *
 * Mobile  (36px buttons, 6px gap): total row = 78px
 *   prev  left = 50% - 39px   next  left = 50% + 3px
 */

#carouselExampleIndicators .carousel-control-prev,
#carouselExampleIndicators .carousel-control-next {
	top: auto;
	bottom: 2.75rem;
	right: auto;
	width: 44px;
	height: 44px;
	border-radius: 50%;
	background-color: var(--color-black);
	opacity: 1;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: opacity .2s ease;
}
#carouselExampleIndicators .carousel-control-prev:hover,
#carouselExampleIndicators .carousel-control-next:hover {
	opacity: .8;
}
#carouselExampleIndicators .carousel-control-prev {
	left: calc(50% - 48px);
}
#carouselExampleIndicators .carousel-control-next {
	left: calc(50% + 4px);
}

#carouselExampleIndicators .carousel-control-prev .bi,
#carouselExampleIndicators .carousel-control-next .bi {
	font-size: 1.4rem;
	color: var(--color-white);
	line-height: 1;
}

#carouselExampleIndicators .carousel-indicators {
	bottom: 0.5rem;
	margin-bottom: 0;
}

@media (max-width: 575px) {
	/* On mobile the buttons move down to sit level with the indicators,
	   one on each side, instead of stacked centrally where they cover
	   the text baked into the slide image. */
	#carouselExampleIndicators .carousel-control-prev,
	#carouselExampleIndicators .carousel-control-next {
		width: 32px;
		height: 32px;
		bottom: 0.25rem;
		left: auto;
		right: auto;
	}
	#carouselExampleIndicators .carousel-control-prev {
		left: 0.5rem;
	}
	#carouselExampleIndicators .carousel-control-next {
		right: 0.5rem;
	}
	#carouselExampleIndicators .carousel-control-prev .bi,
	#carouselExampleIndicators .carousel-control-next .bi {
		font-size: 1rem;
	}
}

/* ============================
	MECCANICA
   ============================ */

/* ── Intro (left column) ── */
.meccanica-intro {
	display: flex;
	flex-direction: column;
	justify-content: center;
	padding: 2rem 2rem 2rem 2.5rem;
}

.meccanica-title {
	font-family: var(--font-primary);
	font-weight: 700;
	font-size: 3rem;
	color: var(--color-black);
	line-height: 1.1;
	border-bottom: 4px solid var(--color-orange);
	padding-bottom: 1rem;
	margin-bottom: 1rem;
}
.meccanica-title__qty {
	color: var(--color-orange);
	font-size: 5rem;
}

.meccanica-subtitle {
	font-family: var(--font-primary);
	font-size: 1.15rem;
	color: var(--color-black);
	margin-bottom: 1rem;
}
.meccanica-subtitle strong {
	color: var(--color-orange);
	font-size: 2.5rem;
	font-weight: 700;
}

.meccanica-dates {
	font-family: var(--font-primary);
	font-size: 0.9rem;
	color: var(--color-text-muted);
	border-left: 3px solid var(--color-orange);
	padding-left: 0.75rem;
	margin-bottom: 0;
}
.meccanica-dates .bi {
	margin-right: 0.35rem;
}

/* ── Steps (right column) ── */
.meccanica-steps-wrapper {
	padding: 2rem 2.5rem 1.5rem 2rem;
}

.meccanica-steps {
	position: relative;
}

.meccanica-step {
	display: flex;
	align-items: flex-start;
	gap: 1rem;
	position: relative;
	padding-bottom: 1.5rem;
}
/* vertical connector between steps */
.meccanica-step:not(:last-child)::after {
	content: '';
	position: absolute;
	left: 21px;
	top: 44px;
	bottom: 0;
	width: 2px;
	background: linear-gradient(to bottom, var(--color-orange), transparent);
}

.step-number {
	flex-shrink: 0;
	width: 44px;
	height: 44px;
	border-radius: 50%;
	background-color: var(--color-orange);
	color: var(--color-white);
	font-family: var(--font-primary);
	font-weight: 700;
	font-size: 1.4rem;
	display: flex;
	align-items: center;
	justify-content: center;
	box-shadow: 2px 3px 8px rgba(0, 0, 0, .2);
	position: relative;
	z-index: 1;
}

.step-content {
	padding-top: 0.3rem;
}

.step-title {
	font-family: var(--font-primary);
	font-weight: 700;
	font-size: 2rem;
	color: var(--color-black);
	text-decoration: underline;
	text-decoration-color: var(--color-orange);
	text-underline-offset: 4px;
	text-decoration-thickness: 2px;
	margin-bottom: 0.2rem;
}

.step-content p {
	font-family: var(--font-primary);
	font-size: 1.5rem;
	color: var(--color-text);
	margin-bottom: 0;
}

/* ── Cashback tiers ── */
.meccanica-tiers {
	margin-top: 0.5rem;
}

.tier-card {
	border: 2px solid var(--color-black);
	border-radius: 12px;
	padding: 0.85rem 0.4rem;
	text-align: center;
	background-color: rgba(255, 255, 255, .85);
	transition: transform .2s ease, box-shadow .2s ease;
}
.tier-card:hover {
	transform: translateY(-4px);
	box-shadow: 0 6px 16px rgba(0, 0, 0, .15);
}

.tier-card--mid {
	border-color: var(--color-orange);
	background-color: rgba(247, 148, 29, .1);
}

.tier-card--top {
	border-color: var(--color-orange);
	background-color: var(--color-orange);
}

.tier-qty {
	font-family: var(--font-primary);
	font-size: 0.78rem;
	font-weight: 700;
	color: var(--color-black);
	text-transform: uppercase;
	letter-spacing: 0.04em;
	margin-bottom: 0.15rem;
}
.tier-card--top .tier-qty { color: var(--color-white); }

.tier-perc {
	font-family: var(--font-primary);
	font-weight: 700;
	font-size: 2rem;
	color: var(--color-orange);
	line-height: 1.1;
}
.tier-card--mid .tier-perc { font-size: 2.3rem; }
.tier-card--top .tier-perc { color: var(--color-text); font-size: 2.7rem; }

.tier-max {
	font-family: var(--font-primary);
	font-size: 0.7rem;
	color: var(--color-text-muted);
}
.tier-card--top .tier-max { color: var(--color-text); }

/* ── Legal & note ── */
.meccanica-legal {
	font-family: var(--font-primary);
	font-size: 0.7rem;
	color: var(--color-text-muted);
	margin-top: 1rem;
	line-height: 1.5;
	border-top: 1px dashed var(--color-text-muted);
	padding-top: 0.75rem;
	margin-bottom: 0.5rem;
}
.meccanica-legal a {
	color: var(--color-text-muted);
	text-decoration: underline;
}

.meccanica-note {
	font-family: var(--font-primary);
	font-size: 0.7rem;
	color: var(--color-text);
	border-left: 3px solid var(--color-red);
	padding-left: 0.75rem;
	margin-bottom: 0;
}
.meccanica-note a {
	color: var(--color-text);
	text-decoration: underline;
}

/* ── Mobile ── */
@media (max-width: 991px) {
	.meccanica-intro {
		padding: 1.5rem 1.5rem 1rem;
		text-align: center;
		border-bottom: 3px solid var(--color-orange);
	}
	.meccanica-title {
		font-size: 1.8rem;
		border-bottom: none;
		padding-bottom: 0.5rem;
	}
	.meccanica-title__qty { font-size: 2.4rem; }
	.meccanica-subtitle { font-size: 1rem; }
	.meccanica-subtitle strong { font-size: 1.4rem; }
	.meccanica-dates {
		border-left: none;
		border-top: 2px solid var(--color-orange);
		padding-left: 0;
		padding-top: 0.5rem;
		display: inline-block;
	}
	.meccanica-steps-wrapper {
		padding: 1.5rem 1.5rem 1rem;
	}
	.tier-perc       { font-size: 1.6rem; }
	.tier-card--mid .tier-perc { font-size: 1.9rem; }
	.tier-card--top .tier-perc { font-size: 2.2rem; }
}

/* ============================
	FORM
   ============================ */

   .sfondo {
   	background-color: rgba(255,255,255,.8);
   	border-radius: 20px;
   	box-shadow: 0px 6px 8px rgba(0, 0, 0, .4);
   }
#errore {
	font-family: var(--font-primary);
	color: var(--color-red);
	font-weight: 700;
	text-align: center;
	font-size: 24px;
}

/* Reset per i <fieldset>/<legend> usati per raggruppare semanticamente i
   campi del form senza alterare l'aspetto visivo dei precedenti <div>/<label> */
.fieldset-plain {
	border: 0;
	margin: 0;
	padding: 0;
	min-width: 0;
}
.legend-plain {
	display: inline;
	float: none;
	width: auto;
	font-size: inherit;
	font-weight: inherit;
	line-height: inherit;
	margin-bottom: 0;
}
   .form-control, .form-select {
   	border-radius: 5px;
   	border: 1px solid var(--color-blue);
   	font-family: var(--font-primary);
   	color: var(--color-text-dark);
   }

   .carica_scontrino {
	border: 3px dashed var(--color-blue);
	border-radius: 10px;
	background-color: rgba(247, 148, 29, .1);
   }
   input[type="file"].form-control-lg {
	background-color: var(--color-white);
	height: auto;
	padding: 0.6rem 0.75rem;
	cursor: pointer;
   }

   .carica_scontrino__icon {
	background-color: var(--color-orange);
	border-color: var(--color-orange);
	color: var(--color-white);
	font-size: 1.4rem;
	cursor: pointer;
	transition: background-color .2s ease, border-color .2s ease;
   }
   .carica_scontrino__icon:hover {
	background-color: var(--color-button-dark);
	border-color: var(--color-button-dark);
   }

   .form-group {
   	margin-bottom: 15px;
   }

label[for=reg], label[for=tratt_dati]  {
	display: block;
}

   label a {
   	color: inherit;
   	text-decoration: underline;
   }

   small.small {
   	font-size: 10px;
   	line-height: 9px;
   }

   
.button {
	font-family: var(--font-primary);
	background-color: var(--color-orange);
	color: var(--color-text);
	border-radius: 65px;
	border: 0px solid transparent;
	font-weight: 700;
	font-size: 2.2rem;
	padding: .25rem 2rem;
	width: max-content;
	-webkit-box-shadow: 2px 4px 8px 1px rgba(0,0,0,.3);
	box-shadow: 2px 4px 8px 1px rgba(0, 0, 0, .3);
	text-decoration: none;
}


.button:hover {
	color: var(--color-white);
	background: var(--color-black);
}

@media screen and (max-width: 768pc) {
	.button {
		font-size: 1.5rem;;
	}
}

.img-small {
	max-width: 80px;
}


/* ============================
	FOOTER
   ============================ */
   footer {
   	font-family: var(--font-primary);
   	font-size: 0.8rem;
   	background-color: var(--color-bg-light);
   }

   footer p {
   	font-family: var(--font-primary);
   	color: var(--color-text);
   	font-weight: 400;
   	font-style: normal;
   	font-size: 0.8rem;
   	text-align: center;
   }

   footer p a {
   	font-family: var(--font-primary);
   	color: var(--color-text);
   	text-decoration: underline;
   	font-weight: 700;
   }


/* =========================
	COOKIE BAR
	======================= */

	.cc-window {
		font-size: .85rem !important;
		line-height: 1.2em !important;
	}

	@media (max-width:767px) {
		.cc-window {
			font-size: .75rem !important;
			line-height: 1.1em !important;
		}
	}

/* =========================
	 OCR LOADING
	======================= */

#ocr_loading, #ocr_loading > .modal-dialog, #ocr_loading > .modal-dialog > .modal-content, #ocr_loading > .modal-dialog > .modal-content > .modal-body {
	background-color: transparent !important;
} 


