@import url('https://fonts.googleapis.com/css2?family=Merriweather&family=Raleway&family=Roboto:wght@400;900&display=swap');

/* Custom properties */
:root {
    --clr-neutral-100: hsl(48, 100%, 93%);
    --clr-neutral-900: hsla(0, 0%, 10%, 0.98);

    --clr-primary-100: hsl(48, 100%, 93%);
    --clr-primary-200: hsla(26, 100%, 50%, 0.98);
    --clr-primary-300: hsla(26, 100%, 35%, 0.98);
    --clr-primary-700: hsla(26, 100%, 25%, 0.98);
    --clr-primary-800: hsla(26, 100%, 10%, 0.98);
    --clr-primary-900: hsla(0, 0%, 10%, 0.98);

    --clr-headline-100: hsl(39, 100%, 72%);
    --clr-headline-300: hsl(39, 100%, 65%);
    --clr-headline-900: hsl(39, 100%, 50%);

    --main-clr-font: hsl(48, 100%, 93%);

    --clr-menu: var(--clr-headline-900);

	--clr-input-valid: lime;
	--clr-input-focus: yellow;
	--clr-input-invalid: red;

    --ff-primary: "Raleway", Georgia, "Times New Roman", Times, serif; /*'Roboto', sans-serif;*/
    --ff-accent: "Roboto", Helvetica, sans-serif;
    --ff-header: var(var(--ff-accent));

    /* Other values*/
    --gap: 2rem;
}

html {
    scroll-behavior: smooth;
    scroll-padding: 5rem;

    height: 100svh;
}

/* Typografi */
body {
    font-family: var(--ff-primary);
    font-size: 1.5rem;
    line-height: 1.3;

    min-height: 100%;
    display: grid;
    grid: auto / 1em 1fr 1em;

    line-height: 1.5;
    min-height: 100vh;

    overflow-x: hidden;
}

a,
body {
    color: var(--main-clr-font);
}

h1,
h2,
h3,
h4 {
    color: var(--clr-headline-900);
    font-family: var(--ff-header);
    font-weight: 900;
    line-height: 1;
}

h2,
h3,
h4,
p {
    margin-bottom: 0.9em;
}

/* Layout */

h1 {
    text-transform: uppercase;
    font-family: var(--ff-accent);
    font-size: clamp(2rem, 4vw + 0.5rem, 5rem);
    font-weight: bold;
    line-height: 1.5rem;
    margin: 0 0 1em 0;
}

h2 {
    font-size: clamp(1.9rem, 3vw + 0.5rem, 3.5rem);
    line-height: 0.9;
}
h3 {
    font-size: clamp(1.5rem, 2.2vw + 0.5rem, 2rem);
    line-height: 0.9;
}

.text-center {
    text-align: center;
}

.flex {
    display: flex;
    gap: var(--gap, 1rem);
}

.grid{
    display: grid;
    gap: var(--gap, 1rem);
}

.main-body {
    background-color: var(--clr-primary-700);
    grid-column: 1 / -1;
}

header {
	background-color: var(--clr-primary-100);

    grid-column: 1 / -1;
}

header nav{
    position: absolute;
    top: .7rem;
    right: 0;
    font-family: var(--ff-accent);
    font-size: 1rem;
}
  
article,
section {
    grid-column: 1 / -1;
    padding-block: 5rem;
}

article > p,
section > p {
    padding-block: 0.75rem;
}

@media (hover: hover) {
    /* Targets only devices that can hover */

    a {
        cursor: pointer;
    }

    nav a::after{
        content: "";
        display: block;
        width: 100%;
        height: 5px;
        background-color: var(--clr-menu);
        bottom: -.5em;
        left: 0;
        right: 0;
        transform: scale(0, 1);
        transition: transform ease-in-out 300ms;
    }

    /*nav.footer-menu a:hover::after, */
    nav a:hover::after{
        transform: scale(1, 1);
    }

    nav a:active{
        color: var(--clr-menu);
    }
    

    .footer-menu a::after{
        transform-origin: left;
        height: 2px;
    }

}

.current-active-page{
    color: var(--clr-menu);
}

.light-color-section {
    background-color: var(--clr-primary-100);
    color: var(--clr-primary-900);
}
.light-color-section a{
    color: var(--clr-headline-900);
}

.dark-color-section {
    background-color: var(--clr-primary-700);
    color: var(--clr-primary-100);
}
.diff-color-section {
    background-color: rgb(56, 86, 4);
    color: var(--clr-primary-100);
}

/* Navigation */
.backdrop-blur {
    background-color: hsla(0, 0%, 50%, .9);
}
  
/* if backdrop support: very transparent and blurred */
@supports ((-webkit-backdrop-filter: none) or (backdrop-filter: none)) {
    .primary-nav {
        background-color: hsla(0, 0%, 50%, 0.5);
        -webkit-backdrop-filter: blur(3rem);
        backdrop-filter: blur(.3rem);
    }
}

.primary-nav a > span {
    margin-inline-end: 0.75em;
}

.form-wrapper button{
    --button-clr: var(--clr-headline-900);
    background-color: var(--button-clr);
	cursor: pointer;
	border: 0;
	border-radius: 5rem;
	padding: 0.5rem 1.5rem;
}

div.citat-wrapper{
    display: grid;
    justify-items: center;
    padding-block: 2rem;
}
p.citat, p.citat-source{
    width: 75%;
    font-size: smaller;
    font-style: italic;
}
div.citat-wrapper > p > a.citat-link{
    text-decoration: underline;
}

footer {
    background-color: var(--clr-neutral-900);
    background-image: url(../img/Topo-map.jpg);
    padding: 2em;
    margin: 0;

    grid-column: 1 / -1;
}

.footer-top > * {
    width: 185px;
}
.footer-top,
.section-content-wrapper {
    width: min(100% - 4rem, 1000px);
    margin-inline: auto;
    padding-block: 1.5rem;
}

.footer-top {
    color: var(--clr-main-900);
    font-size: 0.9rem;
    justify-content:space-between;
    margin-top: 1rem;
    margin-bottom: 1rem;
    align-items: top;
}

.footer-bottom {
    text-align: right;
    padding-top: 25px;
    color: var(--clr-main-300);
    font-size: 0.7rem;
}

/* SoMe start */
ul.some-info{
    display: grid;
    grid-template-columns: auto auto auto;
    justify-content: space-between;
  }

div.some-info > li > a {
    margin-right: 1.1rem;
}
/* SoMe end */

/* Footer menu start*/
.footer-menu a::after{
    width: 63%;
}

.fa-footer-menu{
    padding-right: .7rem;
}
/* Footer menu stop*/

/* Hamburger button start*/
button.mobile-nav-toggle{
    --button-clr: var(--clr-neutral-900);
    background-color: transparent;
}

button.hamburger{
    fill: var(--button-clr);
}

button .hamburger-line{
  transition: 
    rotate 300ms ease-in,
    y 300ms ease-in 300ms,
    opacity 0ms 300ms;
  transform-origin: center;
}
button[aria-expanded="true"] .hamburger-line{
  transition: 
    y 300ms ease-in,
    rotate 300ms ease-in 300ms,
    opacity 0ms 300ms;
  transform-origin: center;
  }

.mobile-nav-toggle[aria-expanded="true"] :is(.hamburger-top-bar, .hamburger-bottom-bar){
  fill: var(--clr-headline-900);
  y: 45px;
}

.mobile-nav-toggle[aria-expanded="true"] .hamburger-top-bar{
  rotate: 45deg;
}
.mobile-nav-toggle[aria-expanded="true"] .hamburger-bottom-bar{
  rotate: -45deg;
}

.mobile-nav-toggle[aria-expanded="true"] .hamburger-middle-bar{
  opacity: 0;
}

.mobile-nav-toggle {
  display: none;
}

/* Hamburger button end*/

/* Extra small devices (phones, 600px and down) */
@media (min-width: 30em) {
    .primary-nav {
        padding-block: 1.1rem;
        padding-inline: clamp(2rem, 3.5vw, 6rem);
        --gap: 2.5rem;
    }
}
@media (max-width: 30em) {
    .container-intro h1{
        font-size: clamp(1.8rem, 9vw + 0.5rem, 4rem);
        padding: 12px 5px;
        width: max-content;
    }

    h2 {
        font-size: clamp(1.7rem, 3vw + 0.5rem, 3.5rem);
        line-height: 0.9;
    }
    
    .section-content-wrapper {
        flex-direction: column;
    }

    .footer-bottom {
        text-align: center;
    }
    .footer-top > * {
        align-self: center;
    }

    .primary-nav {
        --gap: 2em;
        flex-direction: column;

        position: fixed;
        z-index: 1000;
        inset: 0 0 0 35%;

        padding: min(20vh, 8rem) 3rem;

        transform: translateX(100%);
        transition: transform 450ms ease-out;
    }

    .primary-nav[data-visible="true"] {
        transform: translateX(0%);
    }

    .mobile-nav-toggle {
        display: block;
        position: fixed;
        z-index: 9999;
        background-size: contain;
        background-repeat: no-repeat;

        cursor: pointer;
        width: 2.5rem;
        border: 0;
        aspect-ratio: 1;
        top: 1.2rem;
        right: 1.2rem;
    }

    .mobile-nav-toggle[aria-expanded="true"] {
        background-size: contain;
    }

    .footer-top {
        flex-direction: column-reverse;
    }

    div.some-wrapper {
        order: 4;
    }
    .name-info {
        order: 3;
    }
    .contact-info {
        order: 2;
    }
    footer > nav{
        order: 1;
    }

    div.some-info > li > a {
        margin-right: 1.1rem;
    }
}

@media (min-width: 30em) and (max-width: 55em) {

    #header-link-text1, #header-link-text4{
        display: none;
    }

    .primary-nav a > span[aria-hidden]{
        display: none;
    }
    .primary-nav li:first-of-type a > span[aria-hidden], 
    .primary-nav li:last-of-type a > span[aria-hidden]{
        display: block;
    }

    div.some-info > li > a {
        margin-right: 1rem;
    }
}

/* Small devices (portrait tablets and large phones, 600px and up) */
@media only screen and (min-width: 600px) {}

/* Medium devices (landscape tablets, 768px and up) */
@media only screen and (min-width: 768px) {
    h1 {
        line-height: 0.9;
        margin: 0;
    }
    h2 {
        line-height: 0.9;
        margin: 0;
    }
}

/* Medium devices (landscape tablets, 768px and up) */
@media only screen and (min-width: 768px) {}

/* Large devices (laptops/desktops, 992px and up) */
@media only screen and (min-width: 992px) {}

/* Extra large devices (large laptops and desktops, 1200px and up) */
@media only screen and (min-width: 1200px) {}

