@IMPORT url("allfonts.css");
@IMPORT url("all.min.css");
@IMPORT url("common.css");

:root {
    --hue: 200;
}

html {
	font-family: opensans, Verdana, Arial, sans-serif;
	font-size: 14px;
}

html.screen-m {
	font-size: 13px;
}
html.screen-s {
	font-size: 12px;
}

body, p, table {
	font-size: 1rem;
}

h2 {
	font-size: 1.25rem;
}

body.main { /* per non includere i body degli iframe*/
    /*background-image: url("../images/prima_torre.jpg");*/
    background-repeat:  no-repeat;
    /* background-attachment: fixed; */
    background-position: top left;
	background-color: #dee7ef;
/*	background-size: 100% auto; 
	background-size: cover;
    font-size: 14px; */
    margin: 0;
    padding: 0;
    height:100%;    
}

.screen-s body.main { 
	background: #e2e2e2; 
}	


/* ---- background ----- */
#slide_bg  {
	position: fixed;
	left: 0;
	top: 0;
	width: 100%;
	height: 100vh;
	background-image: url('../images/rocca.jpg'); 
	background-size: cover;
	background-repeat: no-repeat;
	background-position: 0% 100%;
	z-index: -1;
}	



#slide_bg > figure {
	width: 100%;
	height: 100%;
	background-position: center left;
	background-size: cover;
	background-repeat: no-repeat;
	backface-visibility: hidden;
	animation: imageAnimation  220s linear infinite 0s;  
	color: transparent;
	position: absolute;
	left: 0;
	top: 0;
	z-index: -1;
	opacity: 0;
	margin: 0;
  }
  
  #slide_bg > figure,
  .screen-s  #slide_bg > figure {
	animation: none;
   display:none;
  }
  
  .screen-s  #slide_bg  {
	 background-position: 10% 100%;
  }

  #slide_bg > figure:nth-child(1) { 	  
	  background-image: url('../images/bg/sm1.jpg'); 
  }
  #slide_bg > figure:nth-child(2) {
	animation-delay: 20s;
	background-image: url('../images/bg/sm2.jpg');
  }  
  #slide_bg > figure:nth-child(3) {
	animation-delay: 40s;
	background-image: url('../images/bg/sm3.jpg');
  }
  #slide_bg > figure:nth-child(4) {
	animation-delay: 60s;
	background-image: url('../images/bg/sm4.jpg');
  }
  #slide_bg > figure:nth-child(5) {
	animation-delay: 80s;
	background-image: url('../images/bg/sm5.jpg');
  }  
  #slide_bg > figure:nth-child(6) {
	animation-delay: 100s;
	background-image: url('../images/bg/sm6.jpg');
  }  
  #slide_bg > figure:nth-child(7) {
	animation-delay: 120s;
	background-image: url('../images/bg/sm7.jpg');
  }  
  #slide_bg > figure:nth-child(8) {
	animation-delay: 140s;
	background-image: url('../images/bg/sm8.jpg');
  }  
  #slide_bg > figure:nth-child(9) {
	animation-delay: 160s;
	background-image: url('../images/bg/sm9.jpg');
  }  
  #slide_bg > figure:nth-child(10) {
	animation-delay: 180s;
	background-image: url('../images/bg/sm10.jpg');
  }  
  #slide_bg > figure:nth-child(11) {
	animation-delay: 200s;
	background-image: url('../images/bg/sm11.jpg');
  }  
  #slide_bg > figure:nth-child(12) {
	animation-delay: 220s;
	background-image: url('../images/bg/sm12.jpg');
  }  

  @keyframes imageAnimation {  
	0% {
		animation-timing-function: ease-in;
		opacity: 0;
	}
	8% {
		animation-timing-function: ease-out;
		opacity: 1;
	}
	17% {
		opacity: 1
	}
	25% {
		opacity: 0
	}
	100% {
		opacity: 0
	}
  }

/*=========================================
    header
  =========================================*/
  
.header , .header a{
   font-family: crimson, Times New Roman, Times, serif;
   color:#333;
}

.outer-header {
	display: flex;
	justify-content: space-around;
	align-items: center;
	background: #fff;
}  


.stemma-rsm {
	height: 5rem;
	margin: 0 1rem;
}
.stemma-box {
	flex-grow: 1;
	text-align: center;
	max-width: 6rem;
}


.mainHeader {
   position: relative;
   padding: .8em 0;
   flex-grow: 10;
}  
  
.mainHeader .rsm {    
	font-size: 1.8rem;
	font-weight: bold;
	text-transform: uppercase;
}
.screen-s .mainHeader .rsm {
	font-size: 1.7rem;
}	
.mainHeader .segr {
    margin: 0;
    font-size: 1.5rem;
    font-weight: normal;
    padding: 3px 0;
    width: 95%;
}
.screen-s .mainHeader .segr {
	font-size: 1.15rem;
}	

.title-band {
    padding: 0 0 0.5em;
    background-color: #fffe;
    background: radial-gradient( ellipse at 0 0, #fffe 0%, #fffe 47%, #fff0 70%), linear-gradient(180deg, #fff 50% , #fff0 67%);
    background-position: 0 0;
    position: relative;
    height: 4rem;
}

.subtitle-elez ,
.title-elez {
	font-weight: normal;
	position: absolute;
	font-size: 1.4rem; 
}

.title-elez {
	font-size: 1.7rem;
	font-weight: bold;
	left: 6rem;
	top: 0rem;
	padding-bottom: .1rem;
	border-bottom: 1px solid #aaa;
}	
.title-elez > .short {
	display: none;
}
.subtitle-elez {
	left: 10rem;
	top: 2.4rem;
}	

.screen-s .subtitle-elez {
	font-size: 1.2rem; 
	top: 2.7rem;
	left: 5.2rem;
}

.screen-s .title-elez {
	font-weight: bold;
	top: 0rem;
	left: 5.7rem;
}	
.screen-s .title-elez > .short {
	display: inline;
}
.screen-s .title-elez > .ext {
	display: none;
}
/* ==============================
	     icona menu hamburger 
   ============================= */
#labnav {
	position: absolute;
	left: 1.8rem;
	top: 0rem;
	z-index: 999;
	cursor: pointer;
	
	visibility: hidden; /* fabio: non serve il bottone del menù*/
}
.screen-s #labnav {
	left: .8rem !important;
}

#labnav b {
	width: 40px;
	height: 40px;
	display: block;
	position: relative;
	right: 0;
	top: 0;
	cursor: pointer;
	transition: background 500ms ease;
	border-radius: 50%;
	box-shadow: 2px 2px 3px 1px rgba(50,50,50,0.4);
}
#labnav b i {
	display: block;
	background: #666;
	width: 24px;
	height: 3.6px;
	position: absolute;
	left: 9px;
	top: 11px;
	border-radius: 1000px;
	transform-origin: 20px 4px;
	transition: transform 300ms cubic-bezier(0.09, 0.92, 0, 1.435), opacity 500ms ease;
}
#labnav b i:nth-child(2) {
	top: 18px;
}
#labnav b i:nth-child(3) {
	transform-origin: 26px 4px;
	top: 25px;
}
#labnav.clicked span {
	color: rgba(255, 255, 255, 0.25);
}
#labnav.clicked b {
	transition-delay: 100ms;
}
#labnav.clicked b i:nth-child(1) {
	transform: rotate(45deg) translate(6px, 11px);
}
#labnav.clicked b i:nth-child(2) {
	opacity: 0;
}
#labnav.clicked b i:nth-child(3) {
	transform: rotate(-45deg) translate(10px, -14px);
}
/* ===============================
		menu
   =============================== */
.menu {
	box-sizing: border-box;
	display: flex;
	flex-direction: column;
	margin: 1rem auto;
	width: 99%;
	z-index: 998;
	overflow: auto;
	background: hsl(200deg 80% 80% / 60%);
	box-shadow: 0 0 8px 3px #3336;
	transition: opacity 300ms  ease;
	max-width: 80rem;
	border-radius: 4px;
}
.screen-s .menu {
    background: none;
    box-shadow: none;
}

.screen-s .menu .item {
    margin: 1em 0px;
}
.menu.open_false  {
	display: none;
}

.menu.open_true  {
	opacity: 1;
	animation: openmenu 0.7s ease-out;  
	
}
.screen-s .menu.active {
    width: 100%;
    left: 0;
}

.menu .item,.menu .item a  {
	color: #eee;
}	

.menu .item {
	background: hsl(200deg 78% 30%);
	border: 1px solid #ccc;
	border-width: 1px;
	margin: 0.5rem;
	box-shadow: 1px 0px 8px 2px #6666;
	border-radius: 6px;
}
.item.risultati {
    background: hsl(200deg 71.74% 24.84%);
    margin-top: 2em;
}
.menu .item a {
	font-size: 1.25rem;
	font-weight: bold;
	text-transform: none;
	text-decoration: none;
	align-self: center;
	text-shadow: 0px 1px 2px #444;
}

.menu .icon  {
	font-size: 2.2rem;
	color: #fff;
	float:left;
}

.menu .voice .opener {
  cursor: pointer;
}

.menu .voice .opener i {
	transition: all 0.3s;
}

.menu .voice.open_true .opener i {
	transform: rotate(180deg);
}

.menu .content {
	padding:1em;
}

.screen-s .menu .content {
    padding: 1em 0.5em;
}

.menu .voice.open_false .content {
	display: none;
	opacity: 0;
}
.menu .voice.open_true .content {
	opacity: 1;
	animation-name: openvoice;
	animation-duration: 1s;  
}
.menu .linkgroup {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
}

.menu .affluenza .linkgroup {
    font-size: 1.3rem;
    font-weight: normal;
}


.menu .voice  .opener {
	color: #fff;
	margin: 0;
	font-weight: 100;
	font-size: 1.6rem;
	text-align: center;
	border-bottom: 1px solid #fff6;
	padding: .5rem 1rem;
	border-radius: 5px 5px 0 0;
}

.menu .voice.open_false  .opener {
	border-bottom: none;
}

.menu .voice.open_true  .opener {
    box-shadow: 0 5px 1em -12px #333, 2px 7px 1em -20px inset;
}

.menu .voice .generale {
    margin: 0 auto .5em;
    padding: 8px 1em;
    width: 22em;
    text-align: center;
    background: #0590bbaa;
    border-color: #fffc;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: .5em;
    font-weight: bold;
}

.menu .castello ,
.menu .generale {
    border: 1px solid #fff6;
    background: #3e82a4;
    border-radius: 3px;
}

.menu .castello {
    padding: 5px 5px;
    margin: 0 0.15em 0.5em;
    transition: background 1s ease;
    display: flex;
    align-content: center;
    align-items: center;
    flex-wrap: wrap;
    justify-content: flex-start;
    flex-direction: row;
    flex: 1 1 calc(30% - 0.5em);
}

.menu .affluenza .castello {
}

.screen-s .menu .affluenza .castello {
    flex-direction: column;
    text-align: center;
    min-height: 6.2em;
}


.menu .castello > a {
    display: flex;
    border: 1px solid #fff0;
    transition: all 0.3s ease 0.1s;
    height: 3.5em;
    padding: 0.3em;
    margin: 0.2em;
    flex-direction: row;
    justify-content: space-evenly;
    max-width: 26em;
    border-radius: 3px;
    align-items: center;
    align-content: center;
    font-weight: bold;
    flex-wrap: wrap;
    line-height: 1.1em;
}

.menu .castello .titolo {
    flex: 1 1;
    max-width: 54%;
}

.menu .voice a:hover {
    border: 1px solid #fff;
    background: #fffb;
    color: #023;
    text-shadow: 0 0 1px;
    box-shadow: 0 0 1em -2.1px #fffa;
}
.menu .castello .preferenze {
    border-left: 1px solid #fff2;
}
.menu .castello,
.menu .castello a {
	/* color: #fff; */
}

.menu .castello:hover {
	background: #FFF5;
	border-color: #FFF;
}
.menu .castello img {
	height: 4rem;
	padding: 0.3rem;
	/* flex-shrink: 0; */
}

.menu .castello .dsvoti {
    min-width: 6.5em;
    justify-self: flex-end;
}

.screen-s .menu .castello .dsvoti {
}


@keyframes openmenu {
	from { opacity: 0;}
	to   { opacity: 1;}
}
@keyframes openvoice {
	from {opacity: 0.1;}
	to {opacity: 1;}
}

.risultati .voti {
    border: 1px solid #fff0;
    border-width: 0 1px;
    min-height: 3em;
    width: 100%;
}

.risultati .linkgroup {
	flex-direction: column;
	flex-wrap: nowrap;
	font-weight: bold;
}

.risultati .castello span {
	padding: 0 .4rem;
	min-width: 8em;
	flex: 1 1;
}

.risultati .castello .preferenze i {
	padding: 0 .5em;
}


/*=========================================
    altro
  =========================================*/
#contdati {
	box-sizing: border-box;
	width: 100%;
	margin: auto;
	position: relative;
	max-width: 75em;
	/* box-shadow: 0 0 1.4em 0.8em #fffa; */
	border-radius: 5px;
	border: 2px solid #fffc;
	background: hsl(var(--hue) 50% 40% / 80%);
}
.screen-s #contdati {
    border-width: 2px 0;
    border-radius: 0;
}

#fdati {
   width: 100%;
   border: none;
   min-height: 70vh;
   overflow: visible;
}

#close_dati {
    position: absolute;
    top: 0px;
    left: 0px;
    width: 1em;
    padding: 0 1em;
    background: #FFFe;
    border-radius: 3px 0;
    color: #045;
    line-height: 1.4em;
    font-size: 1.4rem;
    cursor: pointer;
    box-shadow: 1px 1px 2px;
}

.screen-s #close_dati {
	left: -5px;
}

/*=========================================
    info bar
  =========================================*/
div#bottombar {
	z-index: 50;
	text-align: left;
	color: #111;
	background: #9cfa;
	margin: -0.2rem auto 0px;
	box-sizing: border-box;
	padding: 0 2% 0.4%;
	width: 100%;
	height: 3.55rem;
	display: flex;
	align-items: center;
	bottom: 0;
}


div#bottombar .segint {
	font-weight: normal;
	font-size: 1rem;
	flex-grow: 1;
}

div#bottombar .elab {
	font-size: .8rem;
	flex-grow: 0;
	padding: 0 .2rem;
}

div#bottombar .ciscoop {
	height: 3rem;
	flex-grow: 0;
	margin: 0rem;
}

div#bottombar span.ciscoop  img {
	width: 70px;
	position: relative;
	top: 5px;
}

/*
div#bboverlay {
	z-index:2; 
	background-color: #b1d3ff; 
	position:absolute;
    width: 710px;
    margin-left: 0px; 
} 
*/