@font-face {
  font-family: 'Source Sans 3';
  src: url('source-sans-3_5.2.9_latin-400-normal.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Source Sans 3';
  src: url('source-sans-3_5.2.9_latin-700-normal.woff2') format('woff2');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Source Sans 3', sans-serif;
  color: #171717;
  background: #fff;
  -webkit-text-size-adjust: 100%;
}

body.menu-open {
  overflow: hidden;
}

/* Header bar */
#header-wrapper {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: #fff;
  border-bottom: 1px solid #e5e5e5;
}

.header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  padding: 0 12px 0 16px;
}

.header-logo {
  display: flex;
  align-items: center;
}

.header-logo img {
  height: 28px;
  width: auto;
}

/* Hamburger / close toggle */
.menu-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  padding: 8px;
  border: none;
  background: none;
  border-radius: 8px;
  cursor: pointer;
  color: #171717;
}

.menu-toggle:active {
  background: #f5f5f5;
}

.menu-toggle .icon-close {
  display: none;
}

.menu-toggle[aria-expanded="true"] .icon-menu {
  display: none;
}

.menu-toggle[aria-expanded="true"] .icon-close {
  display: block;
}

/* Mobile menu panel */
.mobile-menu {
  position: fixed;
  top: 64px;
  left: 0;
  right: 0;
  background: #fff;
  overflow: hidden;
  z-index: 999;
  display: flex;
  flex-direction: column;
  max-height: 0;
  transition: max-height 0.3s ease;
}

.mobile-menu.is-open {
  max-height: calc(100vh - 64px);
  overflow-y: auto;
}

/* Nav section */
.menu-nav {
  border-bottom: 1px solid #e5e5e5;
  padding: 16px 0;
}

/* Menu items */
.menu-item-row {
  display: flex;
  align-items: stretch;
  min-height: 48px;
}

.menu-item-link {
  flex: 0 0 auto;
  white-space: nowrap;
  display: flex;
  align-items: center;
  padding: 12px 0 12px 16px;
  font-family: 'Source Sans 3', sans-serif;
  font-size: 16px;
  font-weight: 700;
  line-height: 24px;
  color: #404040;
  text-decoration: none;
}

.menu-item-link:active {
  color: #171717;
}

.menu-item-toggle {
  flex: 1 1 auto;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  padding: 12px 16px;
  border: none;
  background: none;
  cursor: pointer;
  color: #404040;
  border-radius: 8px;
}

.menu-item-toggle:active {
  background: #f5f5f5;
}

.menu-item-toggle .chevron {
  flex-shrink: 0;
  transition: transform 0.2s ease;
}

.menu-item.open .menu-item-toggle .chevron {
  transform: rotate(180deg);
}

.menu-item.cta {
  display: block;
  padding: 12px 18px;
  font-size: 16px;
  font-weight: 700;
  line-height: 24px;
  color: #16818d;
  text-decoration: none;
}

/* Submenus */
.submenu {
  max-height: 0;
  overflow: hidden;
  padding: 0 16px;
  transition: max-height 0.25s ease, padding 0.25s ease;
}

.menu-item.open .submenu {
  max-height: 500px;
  padding: 0 16px 8px;
}

.submenu::before {
  content: '';
  display: block;
  height: 5px;
  background: #e2530c;
  border-radius: 2px 2px 0 0;
}

.submenu a {
  display: block;
  padding: 12px 16px;
  font-size: 16px;
  font-weight: 700;
  line-height: 24px;
  color: #404040;
  text-decoration: none;
  background: #fff;
  border-left: 1px solid #e5e5e5;
  border-right: 1px solid #e5e5e5;
}

.submenu a:last-child {
  border-bottom: 1px solid #e5e5e5;
  border-radius: 0 0 4px 4px;
}

.submenu a:active {
  background: #f5f5f5;
}

/* Login section */
.menu-login {
  padding: 24px 16px;
  flex: 1;
}

.menu-login form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.input-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.input-label {
  font-size: 14px;
  font-weight: 400;
  line-height: 20px;
  color: #404040;
}

.input-field input {
  width: 100%;
  height: 44px;
  padding: 10px 14px;
  border: 1px solid #d4d4d4;
  border-radius: 8px;
  font-family: 'Source Sans 3', sans-serif;
  font-size: 16px;
  line-height: 24px;
  color: #171717;
  background: #fff;
  box-shadow: 0 1px 1px rgba(0, 0, 0, 0.05);
}

.input-field input:focus {
  outline: none;
  border-color: #16818d;
  box-shadow: 0 0 0 2px rgba(22, 129, 141, 0.15);
}

.login-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.remember {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 400;
  line-height: 20px;
  color: #404040;
  cursor: pointer;
}

.remember input[type="checkbox"] {
  width: 16px;
  height: 16px;
  border: 1px solid #d4d4d4;
  border-radius: 4px;
  cursor: pointer;
}

.forgot-link {
  font-size: 14px;
  font-weight: 500;
  line-height: 20px;
  color: #16818d;
  text-decoration: none;
}

.login-btn {
  width: 100%;
  height: 44px;
  border: none;
  border-radius: 9999px;
  background: #16818d;
  color: #fff;
  font-family: 'Source Sans 3', sans-serif;
  font-size: 14px;
  font-weight: 700;
  line-height: 20px;
  cursor: pointer;
}

.login-btn:active {
  background: #126d77;
}

/* Logged in state */
.logged-in {
  display: flex;
  flex-direction: column;
  gap: 12px;
  font-size: 16px;
}

.logged-in a {
  color: #16818d;
  font-weight: 700;
  text-decoration: none;
}

/* Page content container */
#container {
  width: 100%;
  min-height: 100vh;
  background: #fff;
}

#content {
  width: 100%;
  position: relative;
}

/* Adform parade */
.adform-parade {
  max-width: 100%;
  margin: 0 auto 25px;
  text-align: center;
  overflow: hidden;
  width: 100%;
}

/* Page navigation (kuvanavi) */
.kuvanavi {
  text-align: center;
  padding: 5px 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.kuvanavi table {
  margin: auto;
  border-spacing: 12px 0;
}

.kuvanavi img {
  display: none;
}

td.navi_o {
  text-align: center;
}

a.sivulle {
  font-size: 20px;
  font-weight: 700;
  text-decoration: none;
  color: #000;
}

a.navi_o,
a.navi_a {
  color: #000;
  font-weight: 400;
  text-decoration: none;
}

a.navi_o {
  font-size: 20px;
}

a.navi_a,
a.navi_use {
  font-size: 18px;
}

a.navi_selected {
  font-size: 20px;
  font-weight: 700;
  color: #000;
  text-decoration: none;
}

a.navi_use {
  font-weight: 700;
  color: #000;
  text-decoration: none;
}

td.navi_selected {
  padding: 0;
}

td.navi_text_kuvat,
td.navi_text_ncom {
  height: 24px;
  vertical-align: middle;
}

td.navi_text_kuvat {
  text-align: right;
}

.kuvanavi div {
  font-size: 18px;
  padding: 0;
}

/* Footer */
.footer {
  margin-top: 50px;
  background: #1a1b1d;
  color: #666;
  font-size: 13px;
  padding: 20px;
  text-align: center;
}

.footer div {
  text-align: center;
  color: gray;
  font-size: 16px;
  font-weight: bold;
  margin-bottom: 20px;
}

.footer table {
  margin: 0 auto;
}

.footer td {
  padding: 0 30px;
  line-height: 150%;
  vertical-align: top;
}

.footer a {
  font-size: 12pt;
  color: #666;
  text-decoration: none;
}
