:root {
  --main-color-one: #142e4b;
  --main-color-two: #1f456e;
  --main-color-two-darkened: #1f3e60;
  --off-black: #333;
  --h1-mbl: .67em;
  --h2-mbl: .83em;
  --h3-mbl: 1em;
  --h4-mbl: 1.33em;
  --h5-mbl: 1.67em;
  --h6-mbl: 2.33em;
}

.nav-toggle, #lang-menu {
  z-index: 2;
}

h1 {
  margin: var(--h1-mbl) 0;
}

h2 {
  margin: var(--h2-mbl) 0;
}

h3 {
  margin: var(--h3-mbl) 0;
}

h4 {
  margin: var(--h4-mbl) 0;
}

h5 {
  margin: var(--h5-mbl) 0;
}

h6 {
  margin: var(--h6-mbl) 0;
}

@font-face {
  font-family: Cantarell;
  src: url(/static/fonts/Cantarell-Regular.ttf);
}

@font-face {
  font-family: Cantarell;
  src: url(/static/fonts/Cantarell-Bold.ttf);
  font-weight: bold;
}

@font-face {
  font-family: Cantarell;
  src: url(/static/fonts/Cantarell-italic.ttf);
  font-style: italic;
}

@font-face {
  font-family: PT-Mono;
  src: url(/static/fonts/PT_Mono/PTMono-Regular.ttf);
}

@font-face {
  font-family: Open-Sans;
  src: url(/static/fonts/Open_Sans/OpenSans-VariableFont_wdth,wght.ttf);
}

@font-face {
  font-family: Open-Sans;
  src: url(/static/fonts/Open_Sans/OpenSans-VariableFont_wdth,wght.ttf);
}

@font-face {
  font-family: Open-Sans;
  src: url(/static/fonts/Open_Sans/OpenSans-Italic-VariableFont_wdth,wght.ttf);
  font-style: italic;
}

html {
  scroll-behavior: smooth;
  background: var(--main-color-one);
}

html, body {
    padding: 0;
    margin: 0;
    font-type: Cantarell;
    font-style: normal;
}

#hero {
    height: 100vh;
    background: var(--main-color-two);
    display: flex;
    color: white;
}

#hero .logo {
    justify-self: stretch;
    align-self: stretch;
    display: flex;
    align-items: center;
    flex-grow: 1;
}

#hero .logo div:first-child {
  background: var(--main-color-one);
  width: 100%;
  height: 100%;
  display: flex;
}

#hero .logo svg {
    stroke: white;
    stroke-width: .28px;
    width: calc(100vw / 5);
    height: min-content;
    aspect-ratio: 1 / 1;
    margin: auto;
    overflow: visible;
}

#hero .logo .curve {
  height: 100%;
  aspect-ratio: 1 / 9;
  background: var(--main-color-one);
  clip-path: url(#hero-path);
  position: relative;
  left: -1px;
}

/*
#hero .logo .curve::before {
  content: "";
  display: block;
  width: 50vw;
  height: 100%;
  background: var(--main-color-one);
  position: absolute;
  left: -50vw;
}
*/

#hero > .content {
  align-self: center;
  font-family: PT-Mono;
  flex-grow: 1;
  width: min-content;
  max-height: calc(100% - 6rem);
  overflow-y: auto;
}

#hero > .content h1:after {
  content: "_";
  animation: cursor .5s infinite alternate linear;
}

@keyframes cursor {
  from { opacity: 0 }
  to { opacity: 1 }
}

#hero > .content h1 {
  font-weight: bold;
}

#hero > .content {
  font-size: 2rem;
  display: block;
}

#hero .s {
  margin-right: 5em;
}

#hero .s p {
  font-size: 1.1rem;
  line-height: 140%;
}

#hero a {
  color: inherit;
}

header {
  font-family: PT-Mono;
}

header .bar {
  background: var(--main-color-two);
  border-radius: .5rem;
  margin-top: .5rem;
}

header nav {
  position: fixed;
  z-index: 2;
  top: 0;
  right: 33%;
  transform: translateX(50%);
}

.menu-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  gap: 2.3rem;
  font-size: 1.7rem;
  color: white;
  padding: 1rem 1.1rem;
  white-space: nowrap;
}

.menu-list li {
  display: inline-block;
  position: relative;
}

:is(.link-list, footer) a {
  color: inherit;
  text-decoration: none;
}

:is(.link-list, footer) .t {
  position: relative;
}

:is(.link-list, footer) .t:after {
  --line-thickness: .08em;
  content: "";
  position: absolute;
  background: white;
  left: 0;
  right: 0;
  bottom: calc(var(--line-thickness) / 2);
  height: 0px;
  transition: .1s;
}

:is(
  .link-list :is(
    :is(a:hover, a[aria-current="page"]) .t,
    :is(a:hover, a[aria-current="page"]).t
  ),
  footer :is(a:hover, a.t[aria-current="page"])
):after {
  height: var(--line-thickness);
  bottom: 0px;
}

.menu-list li > ul {
  position: absolute;
  display: none;
  flex-direction: column;
  gap: 0;
  padding: .5rem 0;
  background: var(--main-color-two);
  z-index: 1;
  border-radius: 0 0 .5rem .5rem;
  left: -1.1rem;
}

.menu-list li > ul li {
  padding: .5rem 1rem;
}

.menu-list li:hover > ul {
  display: flex;
}

#lang-menu {
  position: fixed;
  left: .5rem;
}

#lang-menu li:first-child::after {
  content: "/";
  margin-left: 2.3rem;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  border: none;
  outline: none;
  margin: 0;
  position: fixed;
  height: 2.5rem;
  justify-content: space-between;
  background: none;
  padding: 1rem;
  box-sizing: content-box;
  right: 0;
  cursor: pointer;
}

.nav-toggle div {
  width: 3rem;
  height: .5rem;
  background: white;
  border-radius: 3px;
  transition: transform .2s, opacity .1s;
  outline: 2px solid var(--main-color-one);
}

.nav-toggle[aria-expanded="true"] div:nth-child(2) {
  opacity: 0;
}

.nav-toggle[aria-expanded="true"] div:nth-child(1) {
  transform: translateY(calc(1.25rem - 50%)) rotateZ(45deg);
}

.nav-toggle[aria-expanded="true"] div:nth-child(3) {
  transform: translateY(calc(-1.25rem + 50%)) rotateZ(-45deg);
}

.contact-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.contact-list i {
  margin-right: 1rem;
}

.contact-list li {
  margin-block: 1.5rem;
}

@media (max-width: 1310px) {
  #hero {
    flex-direction: column;
    height: initial;
  }

  #hero .logo {
    flex-direction: column;
    flex-grow: initial;
    /*
     * this is because of the +2px thing on .curve
     */
    overflow-x: clip;
  }

  #hero .logo svg {
    width: calc(100vw / 2.2);
    margin: 6rem auto 2rem !important;
  }

  #hero .curve {
    clip-path: url(#hero-path-s) !important;
    aspect-ratio: 9 / 1 !important;
    /*
     * the +2px is because without it does not take up the entire screen on
     * Safari as of testing
     */
    width: calc(100% + 2px) !important;
    height: initial !important;
    top: -1px;
  }

  #hero > .content {
    width: initial;
    width: 100%;
    font-size: 1.4rem !important;
    padding-inline: 1rem;
    box-sizing: border-box;
    overflow-y: initial !important;
  }

  #hero > .content.centered {
    text-align: center !important;
  }

  .nav-toggle {
    display: flex;
  }

  header {
    right: 0;
    margin: 0 .5rem 0 0;
    transform: initial;
    min-width: 50vw;
    top: 4.5rem;
    max-height: calc(100vh - 5.5rem);
    overflow-y: scroll;
  }

  nav {
    --top-margin: calc(3.875rem + 1lh);
    margin-top:  var(--top-margin) !important;
    transform: initial !important;
    right: .5rem !important;
    max-width: calc(100vw - 1rem);
    max-height: calc(100vh - var(--top-margin));
    overflow-y: auto;
    scrollbar-gutter: stable;
  }

  nav > ul {
    flex-direction: column;
  }

  nav > ul[data-visible="false"] {
    display: none;
  }

  nav ul li > ul {
    position: relative !important;
    background: var(--main-color-two-darkened) !important;
    width: calc(100% + 2.2rem);
  }

  nav .menu-list {
    white-space: initial !important;
  }

  #hero .s {
    margin-right: initial;
    margin-inline: 4rem;
  }

  .quote-form {
    max-width: initial !important;
    margin-bottom: 1rem !important;
    width: 100%;
    margin-inline: auto; !important
  }

  #hero .logo svg {
    margin: 5rem auto;
    display: block;
  }

  #hero:has(+ footer) {
    min-height: calc(100vh - 6rem);
  }

  footer {
    height: 6rem !important;
    margin-top: 0 !important;
    flex-wrap: wrap;
  }

  footer dl {
    width: 100%;
  }

  footer a.t {
    margin: initial !important;
  }

  .footer-bg {
    height: 6rem !important;
  }
}

body > main {
  border-block: 4rem solid white;
  overflow-x: auto;
}

body > main article {
  display: inline-block;
  max-width: 100vw;
  padding-inline: max(calc(50vw - 45rem), 2rem);
  font-family: Open-Sans;
  box-sizing: border-box;
  font-size: 1.1em;
  line-height: 150%;
  color: var(--off-black);
  background: white;
}

body > main article h1 {
  scroll-margin-top: calc(4rem + var(--h1-mbl));
}

.quote-form {
  display: grid;
  max-width: 55%;
  font-size: 1.2rem;
  gap: 1rem;
  margin: 0 2px 5px 2px;
}

.quote-form label:has(+ *:required)::after {
  content: "*";
  margin-left: .3rem;
}

.quote-form input:not([type="submit"]), .quote-form textarea {
  border: none;
  font-size: 1em;
  padding: .3rem;
  border-radius: 4px;
  background: rgba(255, 255, 255, .7);
  border: 1px solid var(--off-black);
}

.quote-form input:not([type="submit"]):focus, .quote-form textarea:focus{
  outline: 2px solid white;
}

.quote-form > div {
  display: grid;
  gap: .4rem;
}

.quote-form textarea {
  resize: vertical;
}

.quote-form input[type="submit"] {
  background: none;
  border: .35rem solid rgba(255, 255, 255, .7);
  color: rgba(255, 255, 255, .7);
  border-radius: 12px;
  font-size: 1em;
  justify-self: center;
  padding: .8rem 1.4rem;
  cursor: pointer;
  font-weight: bold;
  transition: background .4s, border .4s, transform .12s;
}

.quote-form input[type="submit"]:hover {
  background: rgba(255, 255, 255, .7);
  border-color: rgba(0,0,0,0);
  color: black;
  mix-blend-mode: screen;
}

.quote-form input[type="submit"]:active {
  transform: translateY(3px);
}

footer {
  position: sticky;
  color: white;
  height: 3rem;
  padding-inline: 1rem;
  display: flex;
  align-items: center;
  font-family: Open-Sans;
  font-size: 1.2rem;
}

footer dl {
  display: flex;
  gap: .5rem;
  margin: 0;
}

footer dl dt:after {
  content: ":";
}

footer dl dd {
  margin: 0;
}

footer dl dd:not(:last-child):after {
  content: "-";
  margin-left: .5rem;
}

footer a.t {
  margin-left: auto;
}

#hero + footer {
  margin-top: -3rem;
}
