/* 
Theme Name: Asianajotoimisto J.S. Kettunen & Laari Oy
Theme URI: https://www.jskettunen.fi
Description: Asianajotoimisto J.S. Kettunen & Laari Oy
Version: 1.0
Author: Riku Jokinen
Author URI: https://www.rikujokinen.com/
*/
/* Reset */
html, body, div, h1, h2, h3, h4, h5, h6, ul, ol, dl, li, dt, dd, p, blockquote, pre, form, fieldset, table, th, td {
  margin: 0;
  padding: 0;
}

img {
  border: 0;
  display: block;
}

ol, ul, dl {
  list-style: none;
}

article, aside, canvas, details, figcaption, figure, footer, header, hgroup, menu, nav, section, summary, mark, time {
  display: block;
}

table {
  border-spacing: 0;
  border-collapse: collapse;
}

input, select, textarea {
  border-radius: 0;
  font-family: "Libre Franklin", sans-serif;
}

* {
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
}

*, *:before, *:after {
  box-sizing: border-box;
}

/* Global */
body, html {
  height: 100%;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-family: "Libre Franklin", sans-serif;
  color: #2a2219;
  font-weight: 400;
}

body {
  position: relative;
  display: flex;
  flex-direction: column;
}
body.no-scroll {
  height: 100vh;
  overflow: hidden;
}
body > main {
  flex-grow: 1;
}

h1, h2, h3 {
  font-family: "Libre Baskerville", sans-serif;
  font-weight: 700;
  margin-bottom: 0.5em;
  line-height: 1.2em;
}

h1 {
  font-size: clamp(2.25rem, 4.5vw + 0.5rem, 5rem);
  line-height: 1em;
  margin-bottom: 0.75em;
}

h2 {
  font-size: clamp(1.75rem, 3.5vw + 0.5rem, 3rem);
}

h3 {
  font-size: clamp(1.375rem, 2vw + 0.5rem, 2rem);
}

p,
ol,
ul {
  font-size: clamp(1rem, 1vw + 0.5rem, 1.125rem);
  line-height: 1.75em;
  margin-bottom: 1.5em;
}

ol,
ul {
  margin-left: 1.25rem;
}

ol li {
  list-style-type: decimal;
}

ul li {
  list-style-type: disc;
}

a {
  color: inherit;
}

b, strong {
  font-weight: 700;
}

.button,
button,
input[type=button],
input[type=submit] {
  display: inline-block;
  font-size: clamp(1rem, 1vw + 0.5rem, 1.25rem);
  font-weight: 700;
  color: #2a2219;
  background-color: #d6af76;
  padding: 0.75em 1.5em;
  text-decoration: none;
  outline: none;
  cursor: pointer;
  border: none;
  border-radius: 0.25em;
  margin: 1em 0;
  transition: background-color 0.2s ease-in-out;
}
.button:hover, .button:focus,
button:hover,
button:focus,
input[type=button]:hover,
input[type=button]:focus,
input[type=submit]:hover,
input[type=submit]:focus {
  background-color: #debf91;
}

/* Header */
header {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  padding-top: clamp(2rem, 5vw, 4rem);
  z-index: 100;
}
header::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: transparent;
  opacity: 0.9;
  transition: background-color 0.2s ease-in-out;
}
header.sticky {
  position: fixed;
  padding: 1rem 0;
  backdrop-filter: blur(5px);
}
body.admin-bar header.sticky {
  top: 32px;
}
header.sticky::before {
  background-color: #2a2219;
}
header.sticky .site-logo {
  height: 40px;
}
header .wrap {
  max-width: 1710px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
header .site-logo {
  position: relative;
  width: 260px;
  height: 50px;
  text-indent: -9999px;
  text-align: left;
  overflow: hidden;
  margin: 0 2rem 0 0;
  transition: height 0.2s ease-in-out;
}
header .site-logo a {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: url(assets/images/logo-header.svg) no-repeat;
  background-size: contain;
}

/* Menus */
#main-menu {
  position: relative;
}
#main-menu ul {
  display: flex;
  margin: 0;
}
#main-menu ul li {
  list-style-type: none;
  margin-right: 4em;
}
#main-menu ul li:last-child {
  margin-right: 0;
}
#main-menu ul li a {
  color: #fff;
  font-size: 1.125rem;
  font-weight: 700;
  text-decoration: none;
  transition-duration: 0.2s;
}
#main-menu ul li a:hover, #main-menu ul li a:focus {
  color: #d6af76;
}

/* Content */
.wrap {
  position: relative;
  max-width: 1420px;
  margin-left: auto;
  margin-right: auto;
}

.content-padding {
  padding: clamp(3rem, 10vw, 8rem) 0;
}

.section-header {
  text-align: center;
  margin-bottom: clamp(3rem, 10vw, 6rem);
  padding: 0 1rem;
}
.section-header h2 {
  max-width: 18ch;
  margin-left: auto;
  margin-right: auto;
}
.section-header p {
  font-size: clamp(1.125rem, 2vw + 0.5rem, 1.25rem);
  max-width: 50ch;
  margin-left: auto;
  margin-right: auto;
}

.section-columns {
  display: flex;
  flex-wrap: wrap;
  gap: 1em 8rem;
}
.section-columns .column {
  flex: 1 1 300px;
  overflow: hidden;
}

/* Text content */
.text-content {
  position: relative;
  overflow: hidden;
}
.text-content .wrap {
  max-width: 970px;
}
.text-content .bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}
.text-content .bg img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.text-content h1, .text-content h2, .text-content h3, .text-content h4 {
  color: #6a5b45;
}
.text-content a {
  text-decoration: underline;
  transition: color 0.2s ease-in-out;
}
.text-content :is(p, ul, ol) + :is(h1, h2, h3, h4) {
  margin-top: 1.5em;
}

/* Hero */
.hero {
  position: relative;
  overflow: hidden;
}
.hero .wrap {
  padding-top: clamp(80px, 9.5vw, 120px);
}
.hero .bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}
.hero .bg img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.hero .hero-text {
  padding: clamp(80px, 9.5vw, 200px) 0 clamp(0px, 9.5vw, 200px) 0;
  color: #fff;
}
.hero .hero-text h1 {
  max-width: 15ch;
}
.hero .hero-text p {
  font-size: clamp(1rem, 1vw + 0.5rem, 1.25rem);
  font-weight: 500;
  max-width: 50ch;
}

/* Staff items */
.staff-items {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(clamp(220px, 20vw, 280px), 1fr));
  gap: 3rem clamp(3rem, 10vw, 5rem);
}
.staff-items .staff-item {
  text-align: center;
}
.staff-items .staff-item .image {
  position: relative;
  width: 100%;
  height: 0;
  padding-bottom: 125%;
  margin: 0 auto clamp(1.5rem, 3vw, 2rem) auto;
  border: 1px solid #ada8a1;
  background-color: #faf9f8;
  box-shadow: 0 0 1.5rem rgba(0, 0, 0, .05);
}
.staff-items .staff-item .image img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
}
.staff-items .staff-item .contact strong {
  color: #6a5b45;
  font-size: clamp(1.125rem, 2vw + 0.5rem, 1.25rem);
}
.staff-items .staff-item .contact p {
  font-size: clamp(1rem, 1vw + 0.5rem, 1.125rem);
  margin-bottom: 0.75em;
  line-height: 1.5em;
}

/* Form content */
.form-content .section-header h1,
.form-content .section-header h2,
.form-content .section-header h3,
.form-content .section-header p {
  color: #fff;
}
.form-content a:hover,
.form-content a:focus {
  color: #d6af76;
}
.form-content .form-container {
  max-width: 620px;
  margin-left: auto;
  margin-right: auto;
}
.form-content nf-fields-wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}
.form-content nf-fields-wrap nf-field {
  flex: 1 1 200px;
}
.form-content nf-fields-wrap nf-field:nth-child(5), .form-content nf-fields-wrap nf-field:nth-child(6) {
  flex-basis: 100%;
}
.form-content nf-fields-wrap nf-field:nth-child(6) {
  text-align: center;
}

/* Forms */
input[type=text],
input[type=tel],
input[type=email],
input[type=number],
input[type=password],
textarea,
select {
  display: block;
  width: 100%;
  background-color: #fff;
  border: none;
  border-radius: 0.25em;
  font-size: 1rem;
  font-family: "Libre Franklin", sans-serif;
  font-weight: 400;
  padding: 1em 1.5em;
  outline: none;
}

textarea {
  height: 120px;
}

select {
  cursor: pointer;
}

::-webkit-input-placeholder {
  color: #887f75;
  font-style: italic;
}

::-moz-placeholder {
  color: #887f75;
  font-style: italic;
}

:-ms-input-placeholder {
  color: #887f75;
  font-style: italic;
}

:-moz-placeholder {
  color: #887f75;
  font-style: italic;
}

/* Footer */
footer {
  position: relative;
}
footer p {
  margin-bottom: 0;
}
footer .footer-content {
  padding: clamp(3rem, 6vw, 4rem) 0;
  background-color: #fff;
}
footer .footer-content .wrap {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
}
footer .footer-content .footer-logo {
  position: relative;
  width: 230px;
  height: 44px;
  margin-top: 0.5rem;
  text-indent: -9999px;
  text-align: left;
  overflow: hidden;
  background: url(assets/images/logo-footer.svg) no-repeat;
  background-size: contain;
  background-position: top left;
}
footer .footer-content .footer-contact-columns {
  display: flex;
  gap: 2rem clamp(3rem, 8vw, 6rem);
  text-align: center;
}
footer .footer-content .footer-logos {
  display: flex;
  justify-content: flex-end;
}
footer .footer-copyright {
  padding: 1rem 0;
  background-color: #faf9f8;
}
footer .footer-copyright .wrap {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
}
footer .footer-copyright p {
  font-size: 0.875rem;
}
footer .footer-copyright a {
  text-decoration: none;
}
footer .footer-copyright a:hover, footer .footer-copyright a:focus {
  color: #d6af76;
}

footer .footer-copyright .terms ul {
  display: flex;
  gap: 1.5rem;
  margin: 0;
}

footer .footer-copyright .terms ul li {
  list-style-type: none;
}

footer .footer-copyright .terms ul li a {
  font-size: 0.875rem;
}

/* Misc */
div.clear {
  clear: both;
  height: 0px;
}

.alignleft {
  float: left;
  margin: 0 2.5rem 2.5rem 0;
}

.alignright {
  float: right;
  margin: 0 0 2.5rem 2.5rem;
}

.aligncenter {
  margin: 2.5rem auto;
}

.video-container .inner {
  position: relative;
  width: 100%;
  height: 0;
  padding-bottom: 56.25%;
}
.video-container .inner iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

.mobile-helper {
  display: none;
}

/* Ninja forms */
.nf-before-form-content,
.nf-field-label,
.nf-after-field {
  display: none;
}

.nf-field-container {
  margin-bottom: 0 !important;
}

.nf-error .ninja-forms-field {
  border: none !important;
}

.nf-after-form-content .nf-error-msg {
  text-align: center;
  background-color: #a72222;
  color: #fff;
  padding: .5em 1em;
  margin: 2rem auto 0 auto;
  width: fit-content;
}

.nf-error .nf-field-element {
  position: relative;
}

.nf-error .nf-field-element::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 5px;
  height: 100%;
  background-color: #a72222;
  border-top-left-radius: .25em;
  border-bottom-left-radius: .25em;
}

.nf-response-msg {
  text-align: center;
}

.nf-response-msg h1,
.nf-response-msg h2,
.nf-response-msg h3,
.nf-response-msg p {
  color: #fff;
}

/* Media queries */
@media only screen and (max-width: 1900px) {
  header .wrap {
    margin-left: 5vw;
    margin-right: 5vw;
  }
}
@media only screen and (max-width: 1580px) {
  .wrap {
    margin-left: 5vw;
    margin-right: 5vw;
  }

  .text-content .wrap {
    margin-left: auto;
    margin-right: auto;
  }
}
@media only screen and (max-width: 1080px) {
  .text-content .wrap {
    margin-left: 5vw;
    margin-right: 5vw;
  }
}
@media only screen and (max-width: 992px) {
  .mobile-helper {
    display: block;
  }

  #main-menu {
    display: none;
  }

  footer .footer-content .wrap > * {
    flex-basis: 100%;
    text-align: center;
  }
  footer .footer-content .wrap .footer-logo {
    margin-bottom: 2rem;
    background-position: top center;
  }
  footer .footer-content .wrap .footer-contact-columns {
    justify-content: center;
    margin-bottom: 2rem;
  }
  footer .footer-content .wrap .footer-logos {
    justify-content: center;
  }
  footer .footer-copyright .wrap > * {
    flex-basis: 100%;
    text-align: center;
  }
  footer .footer-copyright .terms ul {
    display: block;
    text-align: center;
    margin-bottom: 1rem;
  }
}
@media only screen and (max-width: 600px) {
  #wpadminbar {
    transform: translateY(-100%);
  }

  footer .footer-content .wrap .footer-contact-columns {
    display: block;
    margin-bottom: 0;
  }

  footer .footer-content .wrap .footer-contact-columns .footer-contact-column {
    margin-bottom: 2rem;
  }
}