/*
 * What follows is the result of much research on cross-browser styling.
 * Credit left inline and big thanks to Nicolas Gallagher, Jonathan Neal,
 * Kroc Camen, and the H5BP dev community and team.
 */

/* ==========================================================================
   Base styles: opinionated defaults
   ========================================================================== */

html {
    color: #222;
    font-size: 1em;
    line-height: 1.4;
}

/*
 * Remove text-shadow in selection highlight:
 * https://twitter.com/miketaylr/status/12228805301
 *
 * These selection rule sets have to be separate.
 * Customize the background color to match your design.
 */

::selection {
    background: #b3d4fc;
    text-shadow: none;
}

/*
 * A better looking default horizontal rule
 */

hr {
    display: block;
    height: 1px;
    border: 0;
    border-top: 1px solid #ccc;
    margin: 1em 0;
    padding: 0;
}

/*
 * Remove the gap between audio, canvas, iframes,
 * images, videos and the bottom of their containers:
 * https://github.com/h5bp/html5-boilerplate/issues/440
 */

audio,
canvas,
iframe,
img,
svg,
video {
    vertical-align: middle;
}

/*
 * Remove default fieldset styles.
 */

fieldset {
    border: 0;
    margin: 0;
    padding: 0;
}

/*
 * Allow only vertical resizing of textareas.
 */

textarea {
    resize: vertical;
}

/* ==========================================================================
   Browser Upgrade Prompt
   ========================================================================== */

.browserupgrade {
    margin: 0.2em 0;
    background: #ccc;
    color: #000;
    padding: 0.2em 0;
}

html, body {
	height:100%;
	margin:0; 
	padding:0;
}

body {
	font-size:62,5%;
	font-family: 'Lato', sans-serif;
	font-weight:100;
}

/* ==========================================================================
   Author's custom styles
   ========================================================================== */

.logo { position:absolute; left:1em; top:1em; background-image:url(img/logo.png); width:15em; height:2em; background-size:contain; background-repeat:no-repeat; z-index:10}
.logo.logo_rosa { background-image:url(img/logo_rosa.png); display:none; }
.logo.logo_red { background-image:url(img/logo_red.png); display:none; }
.logo.logo_blu { background-image:url(img/logo_blu.png); display:none; }
.logo.logo_green { background-image:url(img/logo_green.png); display:none; }
.sf { height:100%; width:100%; background-size:cover; background-position:center; position:absolute; display:none;}
.sf1 { background-image:url(img/1.jpeg);}
.sf2 { background-image:url(img/2.jpeg);}
.sf3 { background-image:url(img/3.jpeg);}
.sf4 { background-image:url(img/4.jpeg);}
.sf5 { background-image:url(img/1.jpeg);}
.sf6 { background-image:url(img/1.jpeg);}
.sf7 { background-image:url(img/1.jpeg);}
.sf8 { background-image:url(img/1.jpeg);}
.sf9 { background-image:url(img/1.jpeg);}
.sf10 { background-image:url(img/1.jpeg);}
.sf11 { background-image:url(img/1.jpeg);}
.sf12 { background-image:url(img/1.jpeg);}
.sf13 { background-image:url(img/1.jpeg);}
.sf14 { background-image:url(img/1.jpeg);}
.sf15 { background-image:url(img/1.jpeg);}
.sf16 { background-image:url(img/1.jpeg);}
.sf17 { background-image:url(img/1.jpeg);}
.sf18 { background-image:url(img/1.jpeg);}
.sf19 { background-image:url(img/1.jpeg);}
.sf20 { background-image:url(img/1.jpeg);}
.ico { position:absolute; top:1em; right:7em; z-index:10; border-radius:0%; border:2px solid rgba(255,255,255,0); display:inline-block; width:3em; height:3em; text-align:center; line-height:3em; -webkit-transition: all .3s ease; transition: all .3s ease;}
.ico.active {border:2px solid rgba(255,255,255,100); }
.ico_2 { right:5em;}
.ico_3 { right:1em;}
.ico a { font-size:2em; color:#003a5d; -webkit-transition: all 5s ease; transition: all 5s ease;}
.ico a.logo_rosa { color:#f06098}
.ico a.logo_red { color:#e82c2d}
.ico a.logo_blu { color:#1997d0}
.ico a.logo_green { color:#71b663;}
.pannello {
	height:100%; width:100%; position:absolute; z-index:2; color:#fff; box-sizing:border-box; padding:10em; display:none;
	background: -moz-radial-gradient(center, ellipse cover,  rgba(0,0,0,0.5) 0%, rgba(0,0,0,0.5) 20%, rgba(0,0,0,1) 80%, rgba(0,0,0,1) 100%);
	background: -webkit-radial-gradient(center, ellipse cover,  rgba(0,0,0,0.5) 0%,rgba(0,0,0,0.5) 20%,rgba(0,0,0,1) 80%,rgba(0,0,0,1) 100%);
	background: radial-gradient(ellipse at center,  rgba(0,0,0,0.5) 0%,rgba(0,0,0,0.5) 20%,rgba(0,0,0,1) 80%,rgba(0,0,0,1) 100%);
	filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#00000000', endColorstr='#000000',GradientType=1 );
}
.pannello p { font-size:1.5em; line-height:2; text-align:center;}
.pannello p strong { font-weight:400; font-size:1.7em; line-height:1.5}
.morph_close { cursor:pointer; text-align:center; display:block;}
.info { position:absolute; width:100%; z-index:2; color:#FFFFFF; height:100%; background: -moz-linear-gradient(45deg,  rgba(0,0,0,0.5) 0%, rgba(0,0,0,0) 30%, rgba(0,0,0,0) 100%); display:none;
background: -webkit-linear-gradient(45deg,  rgba(0,0,0,0.5) 0%,rgba(0,0,0,0) 30%,rgba(0,0,0,0) 100%);
background: linear-gradient(45deg,  rgba(0,0,0,0.5) 0%,rgba(0,0,0,0) 30%,rgba(0,0,0,0) 100%);
filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#4d000000', endColorstr='#00000000',GradientType=1 );
}
.morph-title { font-family: 'Playfair Display', serif; background-image:url(img/val_green.svg); background-size:contain; background-repeat:no-repeat; text-align:left; padding-left:5em; margin-left:2em; position:absolute; bottom:2em;}
.morph-title h1, .morph-title h2, .morph-title h3 { font-weight:400; margin:0; padding:0;}
.morph-title h1 { padding-top: 1.9em;}

.gallery { position:absolute;height:100%; width:100%; position:absolute; z-index:2; color:#fff; box-sizing:border-box; display:none;
	background: -moz-radial-gradient(center, ellipse cover,  rgba(0,0,0,0.5) 0%, rgba(0,0,0,0.5) 20%, rgba(0,0,0,1) 80%, rgba(0,0,0,1) 100%);
	background: -webkit-radial-gradient(center, ellipse cover,  rgba(0,0,0,0.5) 0%,rgba(0,0,0,0.5) 20%,rgba(0,0,0,1) 80%,rgba(0,0,0,1) 100%);
	background: radial-gradient(ellipse at center,  rgba(0,0,0,0.5) 0%,rgba(0,0,0,0.5) 20%,rgba(0,0,0,1) 80%,rgba(0,0,0,1) 100%);
	filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#00000000', endColorstr='#000000',GradientType=1 ); overflow:hidden; }
.gal { position:absolute; z-index:2; width:20%; text-align:center; vertical-align:middle; margin-top:20%; opacity:0; margin-left:40%; -webkit-transition: all .3s ease; transition: all .3s ease; cursor:pointer;}
.gal img { width:80%; height:auto; margin:auto}
.g1, .g6, .g11, .g16 { margin-left: 0%; opacity:100;}
.g2, .g7, .g12, .g17 { margin-left: 20%; opacity:100;}
.g3, .g8, .g13, .g18 { margin-left: 40%; opacity:100;}
.g4, .g9, .g14, .g19 { margin-left: 60%; opacity:100;}
.g5, .g10, .g15, .g20 { margin-left: 80%; opacity:100;}

.g1, .g2, .g3, .g4, .g5 { margin-top:5%; }
.g6, .g7, .g8, .g9, .g10 { margin-top:17%}
.g11, .g12, .g13, .g14, .g15 { margin-top:29%}
.g16, .g17, .g18, .g19, .g20 { margin-top:41%}

.gal:hover { transform:scale(1.1)}

.navi { position:absolute; top:50%; font-size:5em; cursor:pointer; z-index:1; color:#FFFFFF;-webkit-transition: all .3s ease; transition: all .3s ease;}
.navi_sx { left:0.5em}
.navi_dx { right:0.5em}
.navi_sx:hover { left:0.4em}
.navi_dx:hover { right:0.4em}
.credits { position:absolute; right:1em; bottom:1em; color:#FFFFFF; z-index:1; letter-spacing:2px }
.credits a {  color:#FFFFFF; }

/* ==========================================================================
   Helper classes
   ========================================================================== */

/*
 * Hide visually and from screen readers
 */

.hidden {
    display: none !important;
}

/*
 * Hide only visually, but have it available for screen readers:
 * https://snook.ca/archives/html_and_css/hiding-content-for-accessibility
 */

.visuallyhidden {
    border: 0;
    clip: rect(0 0 0 0);
    height: 1px;
    margin: -1px;
    overflow: hidden;
    padding: 0;
    position: absolute;
    width: 1px;
}

/*
 * Extends the .visuallyhidden class to allow the element
 * to be focusable when navigated to via the keyboard:
 * https://www.drupal.org/node/897638
 */

.visuallyhidden.focusable:active,
.visuallyhidden.focusable:focus {
    clip: auto;
    height: auto;
    margin: 0;
    overflow: visible;
    position: static;
    width: auto;
}

/*
 * Hide visually and from screen readers, but maintain layout
 */

.invisible {
    visibility: hidden;
}

/*
 * Clearfix: contain floats
 *
 * For modern browsers
 * 1. The space content is one way to avoid an Opera bug when the
 *    `contenteditable` attribute is included anywhere else in the document.
 *    Otherwise it causes space to appear at the top and bottom of elements
 *    that receive the `clearfix` class.
 * 2. The use of `table` rather than `block` is only necessary if using
 *    `:before` to contain the top-margins of child elements.
 */

.clearfix:before,
.clearfix:after {
    content: " "; /* 1 */
    display: table; /* 2 */
}

.clearfix:after {
    clear: both;
}

/* ==========================================================================
   EXAMPLE Media Queries for Responsive Design.
   These examples override the primary ('mobile first') styles.
   Modify as content requires.
   ========================================================================== */

@media only screen and (min-width: 35em) {
    /* Style adjustments for viewports that meet the condition */
}

@media print,
       (min-resolution: 1.25dppx),
       (min-resolution: 120dpi) {
    /* Style adjustments for high resolution devices */
}

/* ==========================================================================
   Print styles.
   Inlined to avoid the additional HTTP request:
   http://www.phpied.com/delay-loading-your-print-css/
   ========================================================================== */

@media print {
    *,
    *:before,
    *:after,
    *:first-letter,
    p:first-line,
    div:first-line,
    blockquote:first-line,
    li:first-line {
        background: transparent !important;
        color: #000 !important; /* Black prints faster:
                                   http://www.sanbeiji.com/archives/953 */
        box-shadow: none !important;
        text-shadow: none !important;
    }

    a,
    a:visited {
        text-decoration: underline;
    }

    a[href]:after {
        content: " (" attr(href) ")";
    }

    abbr[title]:after {
        content: " (" attr(title) ")";
    }

    /*
     * Don't show links that are fragment identifiers,
     * or use the `javascript:` pseudo protocol
     */

    a[href^="#"]:after,
    a[href^="javascript:"]:after {
        content: "";
    }

    pre {
        white-space: pre-wrap !important;
    }
    pre,
    blockquote {
        border: 1px solid #999;
        page-break-inside: avoid;
    }

    /*
     * Printing Tables:
     * http://css-discuss.incutio.com/wiki/Printing_Tables
     */

    thead {
        display: table-header-group;
    }

    tr,
    img {
        page-break-inside: avoid;
    }

    p,
    h2,
    h3 {
        orphans: 3;
        widows: 3;
    }

    h2,
    h3 {
        page-break-after: avoid;
    }
}