/* * * * * * * * * * * * * *
	Color palette
	
	#124170 : dark blue
	#26667F : dark teal
	#67C090 : green
	#DDF4E7 : light green
	
* * * * * * * * * * * * * */

/* ====== Color Palette ====== */
:root {
  --color-dark-blue: #124170;
  --color-dark-teal: #26667F;
  --color-green: #67C090;
  --color-light-green: #DDF4E7;
  --color-white: #F8F8F8;
  --safe-bottom: env(safe-area-inset-bottom, 0px);
}

/* Global HTML/body fixes and cross-browser text rendering */
html, body {
	overflow-x: hidden;
	-webkit-text-size-adjust: 100%;
	-ms-text-size-adjust: 100%;
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
}

/* Prevent the iOS tap highlight and improve touch handling */
a, button { -webkit-tap-highlight-color: rgba(0,0,0,0); touch-action: manipulation; }

/* Box sizing and flex children safe defaults to avoid overflow in Safari/Firefox */
* {
	box-sizing: border-box;
}

/* Prevent flex children overflow issues in Safari/Firefox */
.flex-child,
.d-flex > *,
.row > * {
	min-width: 0;
	min-height: 0;
}

/* Project specific flex-safe defaults */
.navbar .container,
.logo,
.navbar-brand,
#intro .full-height,
.item .text-holder,
.sticky-container,
.sticky-visuals,
.sticky-text {
	min-width: 0;
	min-height: 0;
}

/* iOS momentum scrolling for any overflow containers */
.scrollable,
.sidebar .inner,
.scrollable-y,
#sidebar .inner {
	-webkit-overflow-scrolling: touch;
}

/* Image defaults and object-fit safety */
img {
	max-width: 100%;
	height: auto;
	display: block;
}

.image.object img {
	width: 100%;
	height: auto;
	object-fit: cover;
}

/* * * * * * * * * * * * * *

	General rules

 * * * * * * * * * * * * * */
 
.bg-1{
	background: #123170;
	color: var(--color-light-green);
}
 
a{
	--bs-link-color-rgb: var(--color-light-green);
}

/* Button & form control resets to improve cross-browser consistency */
button, input[type="button"], input[type="submit"], .btn {
	-webkit-appearance: none;
	-moz-appearance: none;
	appearance: none;
	border-radius: 6px;
}

button::-moz-focus-inner, input::-moz-focus-inner {
	border: 0;
	padding: 0;
}

button:focus, .btn:focus, a:focus {
	outline: 3px solid rgba(102, 192, 144, 0.35);
	outline-offset: 2px;
}

.btn-primary{
	--bs-btn-bg: var(--color-dark-teal);
	--bs-btn-border-color: var(--color-dark-blue);
}

.btn-secondary{
	--bs-btn-bg: rgba(0, 0, 0, 0);
	color: var(--color-dark-teal);
}
 
h1, h2, h3{
	/*font-family: 'Reckless Neue';*/
	font-family: 'Quicksand';
}

p{
	font-size: 18px;
	font-family: 'Quicksand';
}

.heading{
	padding: 3rem 1rem;
	letter-spacing: 2px;
	font-size: 40px;
}

.heading h1{
	font-size: 3rem;
}

.cta{
	position: relative;
	height: 60vh;
	padding: 3rem 0;
}

@media(max-width: 576px){
	.cta{
		height: 85vh;
	}
}

.cta .btn{
	background-color: var(--color-dark-blue);
	color: var(--color-light-green);
	margin: 2rem 2rem 2rem 2rem;
	padding: 1rem 2rem 1rem 2rem;
}

.bottom-alert {
    position: fixed;
	bottom: calc(20px + var(--safe-bottom));         /* distanza dal fondo, account for safe-area */
    left: 50%;
    transform: translateX(-50%);
    z-index: 1055;        /* sopra altri elementi */
    max-width: 50%;
    border-radius: 0.75rem;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.5);
}
.alert-info{
	--bs-alert-color: var(--color-light-green);
    --bs-alert-bg: var(--color-dark-blue);
    --bs-alert-border-color: #0b2845;
    --bs-alert-link-color: var(--bs-info-text-emphasis);
	font-size: 20px;
	border-width: 2px;
}

@media (max-width: 576px){
	.bottom-alert{
		width: 95%;
		max-width: 576px;
	}
}

/* * * * * * *
	Social
 * * * * * * */
/* Contenitore fisso */

.social-fixed {
  position: fixed;
	bottom: calc(10% + var(--safe-bottom));
  right: 1rem;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  z-index: 1000;
}

/* Stile base icone */
.social-fixed .social-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  color: white;
  font-size: 1.4rem;
  text-decoration: none;
  transition: all 0.3s ease;
}

/* Colori dei social */
.social-icon.facebook { 
	background-color: #1877f2; 
}
.social-icon.twitter { 
	background-color: #000000; 
}
.social-icon.instagram {
	background: radial-gradient(circle at 30% 107%, #fdf497 0%, #fd5949 45%, #d6249f 60%, #285AEB 90%);
}
.social-icon.whatsapp {
	background-color: #25D366; 
}

/* Hover elegante */
.social-icon:hover {
  transform: scale(1.1);
  filter: brightness(1.2);
  box-shadow: 0 4px 10px rgba(0,0,0,0.3);
}

.social-icon:active {
	transform: scale(1.05);
	filter: brightness(1.15);
}

.social-icon, .card-has-bg {
	will-change: transform, filter;
}


/* * * * * * *
	navbar
 * * * * * * */ 

.navbar{
	background: var(--color-dark-teal);
	font-family: Quicksand;
	font-weight: 400;
	color: var(--color-green);
}
/* bisogna capire quali solo le variabili di bootstrap per ridefenire quelle, senza fare doppioni */

.navbar-nav {
  --bs-navbar-link-color: var(--color-green);
  --bs-navbar-color: var(--color-light-green);
  --bs-nav-link-font-size: 1.3rem;
  --bs-navbar-hover-color: #007bff;
  --bs-navbar-brand-color: #222;
  --bs-navbar-brand-hover-color: #007bff;
  --bs-navbar-active-color: var(--color-green);
}

.logo h1{
	padding-left: 0.8rem;
	margin: 0;
	color: #E3E3E3;
	font-size: 2rem;
	white-space: nowrap;
	min-width: 0;
}

.navbar-brand{
	min-width: 0;
	flex-shrink: 1;
}

.navbar-brand img{
	display: block;
	max-height: 60px;
	object-fit: contain;
}

@media (max-width: 420px){
	.logo h1{
		font-size: 24px;
	}
	
	.navbar-brand img{
		max-height: 50px;
	}
}

@media (max-width: 385px){
	.logo h1{
		font-size: 22px;
	}
	
	.navbar-brand img{
		max-height: 45px;
	}
}

@media (max-width: 350px){
	.logo h1{
		font-size: 20px;
	}
	
	.navbar-brand img{
		max-height: 40px;
	}
}

/* * * * * * * * * * * * * *

	Landing
	
 * * * * * * * * * * * * * */
 
#intro{
	position: relative;
	/*background: var(--color-light-green);
	background: linear-gradient(0deg, rgba(221, 244, 231, 1) 0%, rgba(235, 235, 235, 1) 100%);*/
	background: url('../img/pics/patient10-min.jpg') top/cover fixed no-repeat;
}

#intro::before{
	content:"";
	position: absolute;
	inset: 0;
	/*background: #DDF4E7DF;*/
	background: linear-gradient(90deg, rgba(221, 244, 231, 0) 0%, rgba(221, 244, 231, 0.75) 66%, rgba(221, 244, 231, 0.9) 100%);
	z-index: 0;
}

@media (max-width: 576px){
	#intro{
		background: url('../img/pics/rx2-min.jpg') center/cover fixed no-repeat;
	}
	
	#intro::before{
		content:"";
		position: absolute;
		inset: 0;
		background: rgba(221, 244, 231, 0.6);
		z-index: 0;
	}
	
	
}
/* to be checked */
@supports (-webkit-touch-callout: none) {
	/* Touch WebKit (iOS) does not reliably support fixed backgrounds; force scroll to avoid issues */
	#intro,
	.promo,
	.scanner,
	#services,
	#reach-us,
	#about-us {
		background-attachment: scroll !important;
		background-position: center center;
		-webkit-backface-visibility: hidden;
		backface-visibility: hidden;
	}
}



#intro .full-height{
	position: relative;
	height: 100svh;
	min-height: 100vh;
	padding-top: 8rem;
	z-index: 1;
}

#intro .big-title{
	font-family: 'Reckless Neue'; /* spostato */
    font-weight: normal;
    font-style: normal;
	padding-bottom: 4rem;
}

#intro .big-title > h1{
		font-size: 2.8rem;
}

@media (max-width: 576px){
	#intro .intro-desc{
		margin-top: 10rem;
	}
	
	#intro .big-title > h1{
		font-size: 1.6rem;
	}
}

#intro .description{
	padding-top: 0.5rem;
	font-family: 'Gloock';
	z-index: 2;
	
}

#intro .description{
	font-size: 20px;
	letter-spacing: 2px;
	/*max-width: 55%;*/
}

#intro .description h2{
	font-size: 2.5rem;
}

#intro .buttons{
	font-family: 'Quicksand';
}
	
/* TO DELETE
#intro .front-img{
	position: absolute;
	bottom: -20vh; 
	right: 0;      
	padding-right: var(--bs-gutter-x, 1.5rem);
	z-index: -1;   
}
	*/

@media (max-width: 576px){
	#intro .front-img{
		bottom: unset;
		top: 14rem;
	}
	
	#intro .description h2{
		font-size: 2rem;
	}
}

#intro .buttons .btn-primary{
	background-color: var(--color-dark-teal);
	color: var(--color-light-green);
	margin: 3rem 4rem 2rem 0rem;
	padding: 1rem 2rem 1rem 2rem;
}

#intro .buttons .btn-secondary{
	background-color: var(--color-white);
	color: var(--color-dark-blue);
	margin: 3rem 4rem 2rem 0rem;
	padding: 1rem 2rem 1rem 2rem;
}


@media (max-width: 576px){
	#intro .buttons .btn{
		margin: 2rem 1rem 2rem 0rem;
	}
}	

#intro .front-img img{
  max-width: 1000px;
  height: auto;
  display: block;
}

@media (max-width: 576px){
	#intro .front-img img{
	  width: 100%;
	  height: auto;
	  display: block;
	}
}
	
/* * * * * * * * * * * * * 
	About Us
 * * * * * * * * * * * * */
	
#about-us{
	background: var(--color-light-green);
	background: linear-gradient(180deg, rgba(221, 244, 231, 1) 0%, rgba(235, 235, 235, 1) 100%);
	min-height: 100vh;
}

#about-us .container{
	padding: 4rem 0;
}
/*
#about-us .heading{
	padding: 2rem 0;
	letter-spacing: 2px;
	font-size: 40px;
}
*/
#about-us .buttons .btn-primary{
	background-color: var(--color-dark-teal);
	color: var(--color-light-green);
	margin: 3rem 4rem 2rem 0rem;
	padding: 1rem 2rem 1rem 2rem;
}

#about-us .buttons .btn-secondary{
	background-color: var(--color-white);
	color: var(--color-dark-blue);
	margin: 3rem 4rem 2rem 0rem;
	padding: 1rem 2rem 1rem 2rem;
}

#about-us .description{
	padding-left: 3rem;
}

@media (max-width: 576px){
	#about-us .description{
		padding: 1rem;
	}
	
	#about-us .buttons .btn{ 
		margin: 0rem 0.8rem 2rem 0rem;
	}
}
#about-us hr{
	display: block;
	width: 80%;
    height: 1px;
    border: 0;
    border-top: 1px solid var(--color-green);
    margin: 1em 10%;
    padding: 0;
}

#about-us p{
	font-size: 19px;
	padding-bottom: 1.5rem;
}

#about-us .about-pic img{
	--b: 11px;  /* border thickness*/
	--s: 100px; /* size of the corner*/
	--g: 14px; /* the gap*/
	--c: var(--color-dark-teal); 

	padding: calc(var(--b) + var(--g));
	background-image: conic-gradient(from  90deg at top    var(--b) left  var(--b), #0000 25%, var(--c) 0), conic-gradient(from -90deg at bottom var(--b) right var(--b), #0000 25%, var(--c) 0);
	background-position: var(--_p, 0%) var(--_p, 0%), calc(100% - var(--_p, 0%)) calc(100% - var(--_p, 0%));
	background-size: var(--s) var(--s);
	background-repeat: no-repeat;
	transition:	background-position .3s var(--_i,.3s), background-size .3s calc(.3s - var(--_i, .3s));
}

#about-us .about-pic img:hover {
  background-size: calc(100% - var(--g)) calc(100% - var(--g));
  --_p: calc(var(--g) / 2);
  --_i: 0s;
}

#about-us .propic{
	width: 18rem;
	border-radius: 50%;
	padding: 2rem;
}

/* * * * * * * * 
	Promo
 * * * * * * * */
 


.promo{
	position: relative;
	background: url('../img/pics/empty2-min.jpg')  center/cover fixed no-repeat;
	color: var(--color-light-green);
}

.cta-content{
	height: 15rem;
	padding: 2rem 2rem;
	position: relative;
	z-index: 1;
}

.cta-content::before{
	content:"";
	position: absolute;
	inset: 0;
	/*background: #DDF4E7A1;*/
	z-index: -1;
	
	background: rgba(38, 102, 127, 0.4);
	border-radius: 16px;
	box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
	backdrop-filter: blur(2.5px);
	-webkit-backdrop-filter: blur(3px);
	border: 1px solid rgba(38, 102, 127, 0.2);
}

/* Fallback for browsers that don't support backdrop-filter (e.g. some Firefox builds) */
@supports not ((-webkit-backdrop-filter: blur(2px)) or (backdrop-filter: blur(2px))) {
  .cta-content::before,
  #services .card-has-bg:before,
  .promo .cta-content::before,
  #services .card-has-bg:before {
    background-color: rgba(38,102,127,0.6);
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }
}

@media (max-width: 576px){
	.cta-content button{
		margin: 0!important;
		width: 100%;
	}
}

/* * * * * * * * * * * * *
	
	Services
	
 * * * * * * * * * * * * */
 
#services{
	padding: 5rem 0;
	background: var(--color-light-green);
}

#services h1{
	text-align: left;
}

.fade-out-bottom{
	-webkit-mask-image: linear-gradient(to bottom, black 60%, transparent 100%);
    mask-image: linear-gradient(to bottom, black 0%, transparent 100%);
}

.fade-out-bottom::after {
    content: '';
    position: absolute;
    inset: 0; /* Cover the entire container */
    pointer-events: none; /* Allow interaction with the content underneath */
    
    /* Apply a blur to the content behind this pseudo-element */
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);

    /* Mask this pseudo-element so the blur effect fades in from top to bottom */
    -webkit-mask-image: linear-gradient(to bottom, transparent 50%, black 80%);
    mask-image: linear-gradient(to bottom, transparent 50%, black 80%);
}

#services .card {
  border: none;
  overflow: hidden;
  border-radius: 20px;
  width: 25rem;
  height: 28rem;
  margin: 1rem;
  box-shadow: 0 0 12px 0 rgba(0, 0, 0, 0.2);
  transition: all 500ms cubic-bezier(0.19, 1, 0.22, 1);
}

@media (max-width: 768px) {
	#services .card{
		min-height: 350px;
	}
}

@media (max-width: 420px) {
	#services .card{
		min-height: 300px;
	}
}

#services .card-has-bg {
    transition: all 500ms cubic-bezier(0.19, 1, 0.22, 1);
    background-size: cover;
    background-repeat: no-repeat;
    background-position: center center;
}
	
#services .card-has-bg:before {
	content: "";
	position: absolute;
	inset: 0;
	backdrop-filter: blur(6px);
	-webkit-backdrop-filter: blur(6px);

	/* maschera graduale: trasparente sopra, visibile sotto */
	mask-image: linear-gradient(to top, rgba(0,0,0,1) 20%, rgba(0,0,0,0) 60%);
	-webkit-mask-image: linear-gradient(to top, rgba(0,0,0,1) 35%, rgba(0,0,0,0) 65%);
	background: linear-gradient(to top, rgba(255,255,255,0.95), transparent);
	/*
     content: "";
      position: absolute;
      top: 0;
      right: 0;
      bottom: 0;
      left: 0;
      background: inherit;
      -webkit-filter: grayscale(1);
      -moz-filter: grayscale(100%);
      -ms-filter: grayscale(100%);
      -o-filter: grayscale(100%);
      filter: grayscale(100%);
	*/
}

#services .card-has-bg:hover {
    transform: scale(0.98);
    box-shadow: 0 0 5px -2px rgba(0, 0, 0, 0.3);
    background-size: 130%;
    transition: all 500ms cubic-bezier(0.19, 1, 0.22, 1);
}

#services .card.card-has-bg:hover .card-img-overlay {
        transition: all 800ms cubic-bezier(0.19, 1, 0.22, 1);
        /*background: rgb(255, 186, 33);
        background: linear-gradient(
          0deg,
          rgba(255, 186, 33, 0.5) 0%,
          rgba(255, 186, 33, 1) 100%
        );*/
 }
	
	
.card-icon{
	/*position: absolute;
	top: 0;
	left: 0;
	padding: 1rem 0;*/
	z-index: 2;
}

.card-icon img{
	width: 200px;
}

.card-img-overlay{
		padding: 1rem 0;
}


.scanner{
	position: relative;
	background: url('../img/pics/scanner1-min.jpg') center/cover no-repeat fixed;
	min-height: 60vh;
	color: var(--color-light-green);
}

.scanner::before{
	content:"";
	position: absolute;
	inset: 0;
	background: #26667F5C;
	z-index: 0;
}


/* * * * * * * * * * * 

	Reach-us
	
 * * * * * * * * * * */
 
#reach-us{
	padding: 8rem 0;
	display: flex;
	align-items: center;
	background: var(--color-green);
}

#reach-us .card{
	--bs-border-radius: 1.5rem;
	width: 30rem;
	height: 28rem;
	padding: 1rem 0;
}

#reach-us .card-header{
	background-color: unset;
	border-bottom: unset;
	padding: 1rem 1rem;
}

#reach-us hr{
	width: 80%;
	margin: auto;
}

#reach-us .map iframe{
	width:100%;
	height: 14rem;
}

#reach-us .btn{
	padding: 1rem 2rem;
}

@media (max-width: 330px){
	#reach-us .card-body p{
		font-size: 16px;
	}
}

/* * * * * * * * * * * 

	Staff
	
 * * * * * * * * * * */
 
#staff .staff-pic{
	width: 25rem;
}

#staff .staff-pic img{
	width: 100%;
	height: auto;
}

#staff h3{
	margin-bottom: 3rem;
}

#staff .staff-text{
	padding-top:5rem;
}

#staff .staff-text .role{
	font-family: 'Reckless Neue';
    font-size: 1.3rem;
    color: #424242;
    text-transform: uppercase;
}

@media (max-width: 768px) {
	
	#staff .staff-wrapper{
		margin: 2rem 0 3rem 0;
	}
	
	#staff .staff-pic img{
		width: 70%;
		margin-left: 12.5%;
	}
		
	#staff .staff-text{
		padding-top: 2rem;
	}
	
	#staff .staff-text h1{
		font-size: 33px;
	}
}

/* * * * * * * * * * * 

	People
	
 * * * * * * * * * * */
 
#people{
	background: var(--color-light-green);
	padding: 3rem 0;
}


.sticky-wrapper {
  position: relative;
  height: 600vh; /* totale altezza per lo scroll */ 
}

.sticky-container {
	position: sticky;
	top: 0;
	height: 100svh;
	min-height: 100vh;
  display: flex;
  justify-content: space-around;
  align-items: center;
}

.sticky-text, .sticky-visuals {
  position: relative;
  width: 40%;
  height: 60vh;
}

.sticky-visuals img{
	width: 80%
}

.text-block, .visual {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 0.5s;
}


.text-block.active, .visual.active {
  opacity: 1;
}

.text-block h1{
	width:100%;
	font-size: 2rem;
}

.text-block .role{
	font-family: 'Reckless Neue';
	font-size: 1.4rem;
	color: #424242;
	text-transform: uppercase;
}

.text-block p {
	margin: 5rem 0;
	font-size: 1.6rem;
}

.visual {
  border-radius: 10px;
}
 
/* Contenitore principale per ogni sezione */
.item {
	position: relative;
	/* Use flex layout so sticky positioning works reliably across browsers */
	display: flex;
	align-items: stretch;
	flex-wrap: nowrap;
}

/* Spaziatura verticale dinamica, serve per poter scrollare gli item uno sull'altro */
/* sembra che crea uno spazio virtuale sopra il quale gli oggetti sticky possono muoversi */
.item::after {
  content: "";
  display: block;
  height: 100vh;
  margin-bottom: -100vh; /*prima era 100vh*/
}

/* Ultimo elemento: nessun effetto extra */
.item:last-of-type::after {
  display: none;
}

.item:last-of-type {
  margin-bottom: 0;
  /* background-image:
    linear-gradient(to bottom, rgba(0,0,0,0.05), transparent 50px),
    linear-gradient(to top, rgba(0,0,0,0.05), transparent 50px); */
}

/* Immagine a sinistra, sticky */
.item .image-holder {
	position: sticky;
	top: 4rem; /*prima era 0*/
	overflow: hidden;
	width: 50%;
	height: 80vh; /*prima era 100vh*/
	flex: 0 0 50%;
	align-self: start;
}

/* Immagine centrata orizzontalmente */
.item .image-holder img {
  position: relative;
  height: 100%;
  width: auto;
  left: 50%;
  transform: translateX(-50%);
}

/* Testo sulla destra, centrato verticalmente */
.item .text-holder {
	display: flex;
	flex-direction: column;
	justify-content: center;
	width: 50%;
	min-height: 120vh;
	padding: 2em;
	box-sizing: border-box;
	flex: 1 1 50%;
}

.item h1 {
  margin-top: 0;
  font-size: 2rem;
}

.item p {
  font-size: 1rem;
}


/* --- MOBILE VERSION --- */
@media (max-width: 768px) {
	.text-block h1{
		font-size: 2rem;
	}
	
	.text-block .role{
		font-size: 1.1rem;
	}
	
	.text-block p {
		margin: 1rem 0;
		font-size: 1rem;
	}
	
	.sticky-container{
		display: flex;
		flex-direction: column;
	}
	
	.sticky-visuals {
		position: absolute;
	}
	
	.sticky-text{
		position: absolute;
		top: 20rem;
		width: 80%;
	}
}

/* * * * * * * * * * * 

	Footer
	
 * * * * * * * * * * */
 
footer{
	background: var(--color-dark-blue);
	padding: 3rem 0;
	min-height: 65vh;
}

footer .copyright {
	text-align: center;
	padding: 0 0 2rem 0;
	margin: 0;
	font-size: 16px;
	color: var(--color-white);
	border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

@media(max-width: 576px){
	footer h2{
		font-size: 36px;
	}
}

footer, footer p{
	color: var(--color-white);
	font-size: 20px;
}

footer .logo{
	width: 100%;
}

footer .logo img{
	display: block;
	width: 100%;
	max-height: 200px;
	object-fit: contain;
}

footer iframe{
	width: 100%;
	aspect-ratio: 16 / 9;
	height: auto;
	border-radius: 5%;
}

footer .media{
	display: flex;
	flex-direction: row;
}

footer .media .social-icon{
	display: flex;
	align-items: center;
	justify-content: center;
	width: 40px;
	height: 40px;
	border-radius: 50%;
	color: var(--color-white);
	font-size: 1.2rem;
	text-decoration: none;
	transition: all 0.3s ease;
}

footer .info{
	font-family: 'Quicksand';
}

footer .info h3{
	padding-bottom: 1rem;
}

footer .btn{
	width: 100%;
    background-color:var(--color-dark-teal);
	color: var(--color-light-green);
    margin: 2.5rem 0;
    padding: 1rem 2rem 1rem 2rem;
}