/* Basic CSS3 structure */

/* Chossen palette colour */
:root {
    --colorA: #1b1b1c;
    --colorB: #d0c091;
    --colorC: #aca490;
    --colorD: #170409;
    --colorE: #5c4f38;
}

/* Chossen fonts */
/* @font-face {
    font-family: Savoye;
    src: url('../fonts/savoye.ttf') format('truetype');
    font-style: normal;
    font-weight: normal;
} */

@font-face {
    font-family: Savoye;
    src: url('../fonts/savoye.otf') format('truetype');
    font-style: italic;
    font-weight: 500;
}


/* Cleaning default browser styles */
* {
    margin: 0px;
    padding: 0px;
    /* border: 1px black solid; */
}

/* Main container styles */
noscript {
    position: fixed;
    color: #534340;
    background-color: #C5D8A4;
    border-radius: 10px;
    border-color: #534340;
    text-align: center;
}

noscript p {
    color: red;
}

body {
    background-color: white;
    /* background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='1000' height='1000' viewBox='0 0 800 800'%3E%3Cg fill='none' stroke='%23C74B50' stroke-width='1'%3E%3Cpath d='M769 229L1037 260.9M927 880L731 737 520 660 309 538 40 599 295 764 126.5 879.5 40 599-197 493 102 382-31 229 126.5 79.5-69-63'/%3E%3Cpath d='M-31 229L237 261 390 382 603 493 308.5 537.5 101.5 381.5M370 905L295 764'/%3E%3Cpath d='M520 660L578 842 731 737 840 599 603 493 520 660 295 764 309 538 390 382 539 269 769 229 577.5 41.5 370 105 295 -36 126.5 79.5 237 261 102 382 40 599 -69 737 127 880'/%3E%3Cpath d='M520-140L578.5 42.5 731-63M603 493L539 269 237 261 370 105M902 382L539 269M390 382L102 382'/%3E%3Cpath d='M-222 42L126.5 79.5 370 105 539 269 577.5 41.5 927 80 769 229 902 382 603 493 731 737M295-36L577.5 41.5M578 842L295 764M40-201L127 80M102 382L-261 269'/%3E%3C/g%3E%3Cg fill='%23D49B54'%3E%3Ccircle cx='769' cy='229' r='7'/%3E%3Ccircle cx='539' cy='269' r='7'/%3E%3Ccircle cx='603' cy='493' r='7'/%3E%3Ccircle cx='731' cy='737' r='7'/%3E%3Ccircle cx='520' cy='660' r='7'/%3E%3Ccircle cx='309' cy='538' r='7'/%3E%3Ccircle cx='295' cy='764' r='7'/%3E%3Ccircle cx='40' cy='599' r='7'/%3E%3Ccircle cx='102' cy='382' r='7'/%3E%3Ccircle cx='127' cy='80' r='7'/%3E%3Ccircle cx='370' cy='105' r='7'/%3E%3Ccircle cx='578' cy='42' r='7'/%3E%3Ccircle cx='237' cy='261' r='7'/%3E%3Ccircle cx='390' cy='382' r='7'/%3E%3C/g%3E%3C/svg%3E"); */
}

header {
    background-color: var(--colorD);
    width: 100%;
    padding-top: 2em;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
}

header a {
    margin-right: 1em;
    display: inline;
    color: var(--colorA);
    font-size: 60px;
    text-decoration: none;
    vertical-align: middle;
    float: left;
}

header a:visited {
    color: var(--colorA);
}

.hidden{
    position: relative;
    visibility: hidden;
    display: none;
}

nav {
    position: absolute;
    top: 40vh;
    width: calc(100% - 2rem);
    font-size: x-large;
    margin-left: 1rem;
    margin-right: 1rem;
}

nav ul {
    list-style-type: none;
    margin: 0;
    padding: 0;
    overflow: hidden;
    /* background-color: var(--colorD); */
    position: sticky;
    top: 0;
    /* text-shadow: 5px 5px black; */
}
  
nav ul li {
    float: left;
    /* border-right: 1px solid var(--colorA); */
}

nav ul li:last-child {
    border-right: none;
}
  
nav ul li a {
    display: block;
    color: var(--colorA);
    text-align: center;
    padding: 14px 16px;
    text-decoration: none;
    font-family: Savoye;
}

nav ul li ul {
    list-style-type: none;
    margin: 0;
    padding: 0;
    overflow: hidden;
    background-color: var(--colorD);
    position: sticky;
    top: 0;
}

nav ul li a:visited {
    color: var(--colorA);
}

nav ul li a:hover:not(.active) {
    color: var(--colorD);
    background-color: var(--colorC);
/*     border-top-left-radius: 5px;
    border-top-right-radius: 5px; */
    border-bottom-left-radius: 5px;
    border-bottom-right-radius: 5px;
    text-shadow: 0px 0px black;
}

.active {
    color: var(--colorD) !important;
    background-color: var(--colorC);
/*     border-top-left-radius: 5px;
    border-top-right-radius: 5px; */
    border-bottom-left-radius: 5px;
    border-bottom-right-radius: 5px;
    text-shadow: 0px 0px black;
}

nav ul li input {
    margin-top: 1em;
    margin-left: 1em;
    border-radius: 5px;
}

nav .icon {
    display: none;
}
  
@media screen and (max-width: 600px) {
    nav li:not(.active) {
        display: none;
    }
    nav li.icon {
        float: right;
        display: block;
    }
}
  
@media screen and (max-width: 600px) {
    nav.responsive .icon {
      position: absolute;
      right: 0;
      top: 0;
    }
    nav.responsive li {
      float: none;
      display: block;
      text-align: center;
    }
}



/* -------------------------------------------
        Estilos CSS del botón del menú
----------------------------------------------*/

/* Ocultamos el input y le damos estilos al label */

input#menuButton { 
    visibility:hidden;
    position: absolute;
    top: -9999px;
}

.toggle-button {
    display:block;
    width:50px;
    height:50px;
    /* border:1px solid var(--colorA); */
    position:relative;
    cursor: pointer;
    box-sizing: border-box;
}

/* Usamos los :before y :after del label para dibujar las tres rayitas */

.toggle-button:before, .toggle-button:after {
    position:absolute;
    display:block;
    content:" ";
    width: calc(100% / 2);               
    box-sizing: border-box;
    left: calc(100% / 4);
    transition: all 0.2s ease-out;
}

.toggle-button:before {
    top: calc(100% / 4);
    height:calc(100% / 4);
    border-top:1px solid var(--colorA);
    border-bottom:1px solid var(--colorA);
    background-color: transparent;
}

.toggle-button:after {
    height:1px;
    background-color:var(--colorA);
    bottom:calc(100% / 4);
}

/* Hacemos clic y el input queda como :checked, así que los centramos y giramos 45º en distinto sentido */

input#menuButton:checked + .toggle-button:before, input#menuButton:checked + .toggle-button:after {
    top:calc(100% / 2);
    height:1px;
    border-bottom:0;
}

input#menuButton:checked + .toggle-button:before {
    transform: rotate(45deg); 
}

input#menuButton:checked + .toggle-button:after {
    transform: rotate(-45deg);
}

/* Posicionamos y mostramos cuando procede los <span> que nos ayudarán con los tooltips */

.abrir, .cerrar { 
    position:absolute;
    top:0;
    right:0;
    bottom:0;
    left:0;
    text-indent: -9999px;
}

.abrir {
    display:block;
}

.cerrar {
    display:none;
}

input#menuButton:checked + .toggle-button .abrir {
    display:none;
}

input#menuButton:checked + .toggle-button .cerrar {
    display:block;
}      
        
/* Fin de los estilos del boton de menu*/


/* Timeline Container */
.timeline {
    /* background: var(--colorD); */
    margin: 20px auto;
    padding: 20px;
    position: absolute;
    left: 50%;
    margin-left: -200px;
    font-family: Savoye;
    text-shadow: 1px 1px black;
  }
  
  /* Card container */
.timeline .card {
    position: relative;
    max-width: 400px;
  }
  
  /* setting padding based on even or odd */
.timeline .card:nth-child(odd) {
    padding: 30px 0 30px 30px;
  }
.timeline .card:nth-child(even) {
    padding: 30px 30px 30px 0;
  }
  /* Global ::before */
.timeline .card::before {
    content: "";
    position: absolute;
    width: 50%;
    border: solid var(--colorB);
  }
  
  /* Setting the border of top, bottom, left */
.timeline .card:nth-child(odd)::before {
    left: 0px;
    top: -4.5px;
    bottom: -4.5px;
    border-width: 5px 0 5px 5px;
    border-radius: 50px 0 0 50px;
  }
  
  /* Setting the border of top, bottom, right */
.timeline .card:nth-child(even)::before {
    right: 0;
    top: 0;
    bottom: 0;
    border-width: 5px 5px 5px 0;
    border-radius: 0 50px 50px 0;
  }
  
  /* Removing the border if it is the first card */
.timeline .card:first-child::before {
    border-top: 0;
    border-top-left-radius: 0;
  }
  
  /* Removing the border if it is the last card  and it's odd */
.timeline .card:last-child:nth-child(odd)::before {
    border-bottom: 0;
    border-bottom-left-radius: 0;
}

/* Removing the border if it is the last card  and it's even */
.card:last-child:nth-child(even)::before {
    border-bottom: 0;
    border-bottom-right-radius: 0;
}

/* Information about the timeline */
.timeline .info {
    display: flex;
    flex-direction: column;
    background: #333;
    color: gray;
    border-radius: 10px;
    padding: 10px;
}

/* Title of the card */
.timeline .title {
    color: var(--colorA);
    font-family: Savoye;
    position: relative;
}

/* Timeline dot  */
.timeline .title::before {
    content: "";
    position: absolute;
    width: 10px;
    height: 10px;
    background: white;
    border-radius: 999px;
    border: 3px solid var(--colorB);
}

/* text right if the card is even  */
.card:nth-child(even) > .info > .title {
    text-align: right;
}

/* setting dot to the left if the card is odd */
.card:nth-child(odd) > .info > .title::before {
    left: -45px;
}

/* setting dot to the right if the card is odd */
.card:nth-child(even) > .info > .title::before {
    right: -45px;   
} 

/* End Timeline */
main {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    width: 100%;
    height: 100%;
    gap: 2rem;
}

section {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    margin: 1rem;
    color: var(--colorA);
    font-family: Savoye;
    /* text-shadow: 5px 5px black; */
    width: inherit;
}

section .title {
    color: var(--colorA);
    font-family: Savoye;
    width: 100%;
    display: flex;
    flex-direction: row;
    text-align: right;
}

h1 {
    color: white;
    font-family: Savoye;
    position: absolute;
    top: 30vh;
    font-size: xxx-large;
}

section h2 {
    display: inherit;
    width: 100%;
    padding: 1rem;
    margin: 1rem auto;
}

article {
    display: flex;
    padding: 1em;
    flex-direction: column;
    gap: 1rem;
}

article .photo {
    border-radius: 50% !important;
    box-shadow: 5px 5px black;
    max-height: 250px;
}

.odd-section {
    margin: 0rem 0rem 0rem 0rem;
    background-color: black;
    transform: rotate(-8deg) skewX(-8deg);
    width: 101%;
    height: 40vh;
    top: -20vh;
    position: absolute;
}
.even-section {
    background-color: white;
    transform: rotate(-8deg);
    top: 20vh;
    position: absolute;
}
.even-body-section {
    background-color: white;
    /* height: 40vh; */
    top: 45vh;
    position: absolute;
}
.foot-section {
    background-color: black;
    transform: rotate(8deg);
    height: 30vh;
    top: 100vh;
    position: absolute;
}