/* RESET & BASE STYLES */
a,abbr,acronym,address,applet,article,aside,audio,b,big,blockquote,body,canvas,caption,center,cite,code,dd,del,details,dfn,div,dl,dt,em,embed,fieldset,figcaption,figure,footer,form,h1,h2,h3,h4,h5,h6,header,hgroup,html,i,iframe,img,ins,kbd,label,legend,li,mark,menu,nav,object,ol,output,p,pre,q,ruby,s,samp,section,small,span,strike,strong,sub,summary,sup,table,tbody,td,tfoot,th,thead,time,tr,tt,u,ul,var,video{margin:0;padding:0;border:0;font-size:100%;font:inherit;vertical-align:baseline}article,aside,details,figcaption,figure,footer,header,hgroup,menu,nav,section{display:block}body,html{line-height:1.15;-ms-text-size-adjust:100%;-webkit-text-size-adjust:100%;font-size:16px}img{max-width:100%}ol,ul{list-style:none}blockquote:after,blockquote:before,q:after,q:before{content:"";content:none}table{border-collapse:collapse;border-spacing:0}a,article,body,code,dd,div,dl,dt,fieldset,footer,form,h1,h2,h3,h4,h5,h6,header,html,input[type=email],input[type=number],input[type=password],input[type=tel],input[type=text],input[type=url],legend,li,main,nav,ol,p,pre,section,table,td,textarea,th,tr,ul{box-sizing:border-box}em,i{font-style:italic}b{font-weight:700}img{border-style:none}svg:not(:root){overflow:hidden}input{-webkit-appearance:none;-moz-appearance:none}[type=reset],[type=submit],button,html [type=button]{-webkit-appearance:button}[type=button]::-moz-focus-inner,[type=reset]::-moz-focus-inner,[type=submit]::-moz-focus-inner,button::-moz-focus-inner{border-style:none;padding:0}[type=button]:-moz-focusring,[type=reset]:-moz-focusring,[type=submit]:-moz-focusring,button:-moz-focusring{outline:1px dotted ButtonText}textarea{overflow:auto}summary{display:list-item}canvas{display:inline-block}[hidden],template{display:none}legend{box-sizing:border-box;color:inherit;display:table;max-width:100%;padding:0;white-space:normal}progress{vertical-align:baseline}audio,progress,video{display:inline-block}audio:not([controls]){display:none;height:0}

/* APP STYLES */
body{
    background-color:#fcfffc;
    color:#1e1e1e;
    font-family:asc,-apple-system,BlinkMacSystemFont,sans-serif;
    line-height:1.35;
    text-rendering:optimizeLegibility;
    font-variant-ligatures:common-ligatures;
    font-feature-settings:"kern","liga";
    font-kerning:normal;
    width:100%;
    font-size:1rem;
    color:#000
}
body a:hover{opacity:0.6}

/* DYNAMIC ISLAND OPTIMIZATION */
section{
    height:100svh;
    width:100%;
    position:relative;
    overflow:hidden;
    display:-ms-flexbox;
    display:flex;
    -ms-flex-pack:center;
    justify-content:center;
    -ms-flex-align:center;
    align-items:center
}
section img{
    display:block;
    height:calc(100% - 1.75rem * 5);
    width:calc(100% - 1.75rem * 5);
    -o-object-fit:contain;
    object-fit:contain
}

/* RESPONSIVE IMAGES */
@media only screen and (max-width:500px){
    section img{width:calc(100% - 1rem * 5);height:calc(100% - 1rem * 5)}
}
@media only screen and (max-width:800px){
    section img{height:calc(100% - 1.75rem * 2);width:calc(100% - 1.75rem * 2)}
}
@media only screen and (min-width:1400px){
    section img{height:calc(100% - 1.75rem * 6);width:calc(100% - 1.75rem * 6)}
}
section img.cover{height:100%;width:100%;-o-object-fit:cover;object-fit:cover}
section img.logo{max-height:12rem}

/* LEGEND STYLES */
section legend{
    position:fixed;
    bottom: 2rem;
    left:1.75rem;
    opacity:0;
    transition:opacity .7s ease;
    z-index:1;
    color:#000000
}

@media only screen and (max-width:800px){nav h1 {max-width:60%}}

section.show legend{opacity:1}

/* NAVIGATION */
nav{
    position:fixed;
    top:10px;
    left:0;
    padding:1.75rem;
    padding-top:env(safe-area-inset-top);
    display:-ms-flexbox;
    display:flex;
    -ms-flex-pack:justify;
    justify-content:space-between;
    -ms-flex-align:center;
    align-items:center;
    width:100%;
    z-index:1
}

@media only screen and (max-width:500px){
    nav{padding:1.75rem;padding-top:env(safe-area-inset-top)}
}

nav a{color:#000;text-decoration:none;transition:opacity .3s ease}

/* INFO PAGE STYLES */
body.info{background:#d26566;color:#fcfffc;min-height:100vh;-ms-flex-pack:justify;justify-content:space-between;-ms-flex-direction:column;flex-direction:column}
body.info,body.info main{display:-ms-flexbox;display:flex}
body.info main{height:100%;-ms-flex-direction:row-reverse;flex-direction:row-reverse;-ms-flex-align:start;align-items:flex-start}
body.info main nav{position:relative;-ms-flex-pack:end;justify-content:flex-end}
body.info main nav a{color:#fcfffc}
body.info main .wrapper{width:calc(100% - 1.75rem);max-width:27.2rem;padding-top:1.75rem;-ms-flex-negative:0;flex-shrink:0;padding-left:1.75rem}

@media only screen and (max-width:500px){
    body.info main .wrapper{padding-left:1rem;padding-top:1rem;width:calc(100% - 1rem)}
}

body.info main .wrapper h1{padding-bottom:1.75rem}

@media only screen and (max-width:500px){
    body.info main .wrapper h1{padding-bottom:1rem}
}

body.info main .wrapper ul{padding-bottom:1.75rem}

@media only screen and (max-width:500px){
    body.info main .wrapper ul{padding-bottom:1rem}
}

body.info main .wrapper p{padding-bottom:1.75rem}

@media only screen and (max-width:500px){
    body.info main .wrapper p{padding-bottom:1rem}
}

body.info main .wrapper h3{display:inline-block}
body.info main .wrapper a{color:#fcfffc;text-decoration:none}

@media only screen and (max-width:650px){
    body.info main{-ms-flex-direction:column;flex-direction:column}
    body.info main nav{-ms-flex-pack:start;justify-content:flex-start}
}

body.info .press a{text-decoration:none;color:#fcfffc}
body.info footer{display:-ms-flexbox;display:flex;-ms-flex-pack:justify;justify-content:space-between;padding:0 1.75rem;padding-bottom:1.75rem;padding-bottom:env(safe-area-inset-bottom)}

@media only screen and (max-width:500px){
    body.info footer{padding-bottom:1rem;padding:0 1rem;padding-bottom:env(safe-area-inset-bottom)}
}

body.info footer a{text-decoration:none;color:#fcfffc}

@media only screen and (max-width:600px){
    body.info footer{-ms-flex-pack:start;-ms-flex-direction:column;flex-direction:column;justify-content:flex-start}
}

body.info footer .credit{color:#d9adac;text-decoration:none;font-size:80%;border-bottom:.1em solid transparent}

@media only screen and (max-width:600px){
    body.info footer .credit{padding:1.75rem 0}
    @media only screen and (max-width:500px){
        body.info footer .credit{padding:1rem 0}
    }
}

/* OVERVIEW GRID */
#overview {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr)); /* Mobile: 2 columns */
    gap: 2rem;
    padding: calc(1.75rem + env(safe-area-inset-top)) 1.75rem calc(1.75rem + env(safe-area-inset-bottom));
    width: min(100%, 1600px);
    margin: 1.75rem auto 0;
    box-sizing: border-box;
}

@media (min-width: 600px) {
    #overview {
        grid-template-columns: repeat(3, minmax(0, 1fr)); /* Tablet: 3 columns */
        gap: 2.5rem;
    }
}

@media (min-width: 1000px) {
    #overview {
        grid-template-columns: repeat(4, minmax(0, 1fr)); /* Desktop: 4 columns */
        gap: 3rem;
    }
}

@media (min-width: 1500px) {
    #overview {
        grid-template-columns: repeat(5, minmax(0, 1fr)); /* Large: 5 columns */
        gap: 3rem;
    }
}

.overview-item img {
    width: 100%;
    height: auto;
    display: block;
}



.overview-item legend {
    margin-top: 10px;
    font-family: asc,sans-serif;
    font-size: 0.7rem;
    color: #000;
    text-align: left;
    padding: 0;
    background: none;
    box-shadow: none;
    position: static;
    opacity: 1;
    transform: none;
    width: auto;
    max-width: none;
}

/* Info page compatibility */
body.info .overview-item legend {
    color: #fcfffc;
}

#overview {margin-top:1.75rem;}


/* COPYRIGHT MODAL */
#copyright-modal {
    border: none;
    padding: 3rem;
    max-width: 600px;
    width: 90%;
    font-family: inherit;
    color: #000;
}

#copyright-modal::backdrop {
    background: rgba(0,0,0, 0.7);
}

.modal-content {
    display: flex;
    flex-direction: column;
    gap: 1.75rem;
}

.modal-content p {
    font-size: 16px;
    margin: 0;
}

#close-modal {
    background: #fff;
    font-family: asc,sans-serif;
    font-size: 16px;
    color: #000;
    border: 0.02rem solid #000;
    padding: 0.75rem 1.5rem;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1rem;
    align-self: flex-start;
}

#close-modal:hover {
    opacity: 0.5;
}

/* LEGEND FLASH ANIMATION */
@keyframes flash-yellow {
    0% {
        background-color: #fff;
    }
    100% {
        background-color: transparent;
    }
}

section.show legend {
    opacity: 1;
    animation: flash-yellow 1.5s ease-out forwards;
}
