﻿/* ----------------------- *\
            HEADER
\* ----------------------- */
header,
footer {
  /* --bg_layout: var(--color_layout);
    --text_layout: var(--color_white); */
  --bg_layout: var(--color_white);
  --text_layout: var(--color_layout);
}

header {
  width: 100%;
  background-color: var(--bg_layout);
  /* border-bottom: 1px solid var(--text_layout); */
  box-shadow: 0px 4px 6px -4px rgba(0, 0, 0, 0.4);
  position: fixed;
  left: 0;
  top: 0;
  padding: 1rem;
  z-index: 99999;
  overflow: hidden;
}
.header {
  width: 100%;
  max-width: var(--max_width);
  margin-left: auto;
  margin-right: auto;
}
.header > .logo {
  float: left;
  font-size: 20px;
  height: var(--logo);
}

.header > .logo img {
  height: 100%;
  width: var(--logo);
  vertical-align: middle;
}
.header > .logo p {
  display: inline-block;
  vertical-align: middle;
  color: var(--color_info);
  font-weight: 700;
  font-size: 12px;
}
.header > .logo span {
  display: block;
  margin-bottom: 0;
  color: #054a91;
  text-transform: uppercase;
  font-size: 1rem;
}

.header > .menu_icon {
  position: absolute;
  right: 10px;
  top: 50%;
  z-index: 9;
  width: 34px;
  height: 34px;
  transform: translateY(-50%);
}

.header > .menu_icon.is_closed > .open_icon {
  display: block;
}
.header > .menu_icon.is_closed > .close_icon {
  display: none;
}
.header > .menu_icon.is_opened > .open_icon {
  display: none;
}
.header > .menu_icon.is_opened > .close_icon {
  display: block;
}

.header > .menu_icon > svg {
  stroke: var(--text_layout) !important;
  fill: var(--text_layout) !important;
}

.header > .nav-menu {
  transform: translate(100%);
  transition: all 0.3s ease-in-out;
  position: fixed;
  top: 115px;
  right: 0;
  background-color: #fefefe;
  width: 100%;
  height: calc(100vh - 70px);
  overflow: auto;
}

.header > .nav-menu.show {
  transform: translate(0);
  transition: all 0.3s ease-in-out;
}

.header > .nav-menu > ul > li {
  display: inline-block;
  width: 100%;
  text-align: center;
  padding: 1rem 0;
  border-bottom: 1px solid rgba(5, 74, 145, 0.1);
  position: relative;
}
.header > .nav-menu > ul > li.has-submenu {
  position: relative;
}
.header > .nav-menu > ul > li.has-submenu > input {
  position: absolute;
  opacity: 0;
  visibility: hidden;
}

.header > .nav-menu > ul > li.has-submenu > label:after {
  content: ">";
  display: inline-block;
  color: inherit;
  font-size: 100%;
  margin-left: 0.5rem;
  transform: rotate(90deg);
  vertical-align: middle;
}

.section-dropdown {
  padding: 0.75rem 3rem;
  background-color: var(--bg_layout);
  top: 47px;
  right: 0;
  min-width: 100%;
  width: auto;
  max-height: 40vh;
  border-radius: 4px;
  display: block;

  z-index: 2;
  opacity: 0;
  pointer-events: none;
  transform: translateX(100%);
  transition: all 300ms linear;

  overflow-y: auto;
  margin-bottom: 2rem;

  box-shadow: 0 0 2px 2px rgba(0, 0, 0, 0.2);
}
.section-dropdown > li {
  padding-top: 0.25rem;
  padding-bottom: 0.25rem;
}
.section-dropdown > li:hover {
  background-color: rgba(0, 0, 0, 0.2);
  margin-left: -3rem;
  margin-right: -3rem;
}
.section-dropdown > li > a {
  color: var(--text_layout);
  display: inline-block;
  width: max-content;
  font-size: 15px;
}

.dropdown:checked ~ .section-dropdown {
  opacity: 1;
  pointer-events: auto;
  transform: translateX(0);
  transition: all 300ms linear;
}
.section-dropdown:before {
  position: absolute;
  top: -20px;
  left: 0;
  width: 100%;
  height: 20px;
  content: "";
  display: block;
  z-index: 1;
}

.section-dropdown:after {
  position: absolute;
  top: -7px;
  right: 30px;

  width: 0;
  height: 0;
  border-left: 8px solid transparent;
  border-right: 8px solid transparent;
  border-bottom: 8px solid var(--bg_layout);
  content: "";
  display: block;
  z-index: 2;
  transition: all 200ms linear;
}

.header > .nav-menu > ul > li > a,
.header > .nav-menu > ul > li > label {
  color: var(--color_layout);
  cursor: pointer;
  font-size: 15px;
  font-weight: 600;
}

@media (min-width: 576px) {
  .header > .nav-menu {
    width: 50%;
    box-shadow: 0 0 8px 4px #4444441a;
  }
}

@media (min-width: 768px) {
  header {
    overflow: visible;
  }
  .header {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    row-gap: 1rem;
  }
  .header > .menu_icon {
    display: none;
  }
  .header > .nav-menu {
    transform: none;
    position: relative;
    top: 0px;
    float: right;
    width: auto;
    /* max-width: 962px; */
    margin-left: auto;
    height: auto;
    background-color: transparent;
    box-shadow: none;
    overflow: visible;
  }
  .header > .nav-menu > ul {
    margin-top: 0;
    display: flex;
    justify-content: space-between;
  }
  .header > .nav-menu > ul > li {
    width: auto;
    padding: 0;
    border-bottom: none;
    margin-left: 16px;
    display: flex;
    align-items: center;
    padding: 4px 2px;
    transition: all 0.3s ease-in-out;
    position: relative;
  }
  .header > .nav-menu > ul > li.active:after {
    content: "";
    display: block;
    width: 8px;
    height: 8px;
    background-color: var(--color_secondary);
    border-radius: 50%;
    position: absolute;
    bottom: -4px;
    left: 50%;
    transform: translateX(-50%);
  }
  .header > .nav-menu > ul > li.active > a,
  .header > .nav-menu > ul > li:hover > a {
    color: var(--color_secondary);
    transition: all 0.3s ease-in-out;
  }
  .header > .nav-menu > ul > li > a,
  .header > .nav-menu > ul > li > label {
    color: var(--text_layout);
    display: inline-block;

    height: auto;
    line-height: 20px;
  }
  .section-dropdown {
    position: absolute;
  }
}

/* ----------------------- *\
            BODY
\* ----------------------- */
.page_content {
  margin-bottom: 76px;
}

/* ----------------------- *\
        CONTAINER
\* ----------------------- */
.container {
  width: 100%;
  padding: 0.5rem;
  max-width: var(--max_width);
  margin-left: auto;
  margin-right: auto;
}
.main {
  width: 100%;
}
.sidebar {
  width: 100%;
  display: block;
}
@media (min-width: 768px) {
  .main {
    width: calc(100% - var(--sidebar));
    padding: 10px;
    padding-top: 0;
  }
  .sidebar {
    display: block;
    width: var(--sidebar);
  }
  .container {
    display: flex;
    flex-direction: row-reverse;
  }
}
@media (min-width: 1280px) {
  .container {
    padding: 0;
  }
}

.banner-section {
  width: 100%;
  max-width: 728px;
  height: auto;
  margin: 20px auto;
  /* background-color: #4444441a; */
}

.white-wrapper {
  background-color: var(--color_white);
  /* box-shadow: 0 0 2px 2px rgba(0, 0, 0, .1); */
  padding: 32px;
}
/* ----------------------- *\
            MODAL
\* ----------------------- */
.modal {
  --delay: 0.5s;
  --modal_width: 600px;

  position: fixed;
  z-index: 99999;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.8);

  display: flex;
  align-items: center;
  justify-content: center;

  animation: fadeIn var(--delay) both;
}
.modal[aria-hidden="true"] {
  animation: fadeOut var(--delay) both;
}
.modal-wrapper {
  overflow: auto;
  background: var(--color_white);
  width: var(--modal_width);
  max-width: calc(100vw - 20px);
  max-height: calc(100vh - 100px);
  padding: 20px;

  animation: slideFromTop var(--delay) both;
}
.modal[aria-hidden="true"] .modal-wrapper {
  animation: slideToBottom var(--delay) both;
}
#iframe-modal .modal-wrapper {
  height: 100%;
}
.js-modal-close {
  display: flex;
  justify-content: center;
  align-items: center;
  position: sticky;
  right: 0;
  top: 0;
  border: 2px solid var(--color_danger);
  color: var(--color_danger);
  background-color: var(--color_white);
  border-radius: 50%;
  width: 30px;
  height: 30px;
  font-size: 2rem;
  line-height: 2rem;
  font-weight: 700;
  margin-left: auto;

  cursor: pointer;
}

@media (min-width: 992px) {
  .modal {
    --modal_width: 60%;
  }
  .modal-wrapper {
    max-width: var(--max_width);
  }
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}
@keyframes fadeOut {
  from {
    opacity: 1;
  }
  to {
    opacity: 0;
  }
}
@keyframes slideFromTop {
  from {
    transform: translateY(-100px);
  }
  to {
    transform: translateY(0px);
  }
}
@keyframes slideToBottom {
  from {
    transform: translateY(0px);
  }
  to {
    transform: translateY(50px);
  }
}

/* ----------------------- *\
            ARTICLE
\* ----------------------- */
.article-container {
  width: 100%;
}

.article-container h1 {
  text-align: center;
  margin: 2rem auto;
  font-size: 2rem;
  color: var(--color_danger);
}
.article-container h2 {
  margin-top: 1rem;
  font-size: 1.25rem;
}
.article-container h3 {
  margin-top: 0.5rem;
}
.article-container p {
  text-align: justify;
}
.article-container ul {
  margin-left: 2rem;
}
.article-container ul li:before {
  content: "\2192";
  display: inline-block;
  margin-right: 0.75rem;
  font-size: inherit;
  vertical-align: middle;
  font-weight: bold;
}
.article-container a {
  color: var(--color_secondary);
}
.article-container a:hover {
  text-decoration: underline;
}

.article-container img {
  max-width: 100%;
  margin: 1rem auto;
}
.cat-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-top: 1rem;
}

.cat-block {
  flex: 1 1 calc(33.333% - 16px);
  min-width: 220px;
  border: 1px solid #cccccc;
  border-radius: 6px;
  padding: 0.8rem 1rem;
  background: white;
  box-shadow: rgba(0, 0, 0, 0.06) 0px 0px 0px 1px;
}

.cat-block__title {
  font-size: 1rem;
  font-weight: bold;
  color: #1a3a5c;
  margin-bottom: 8px;
  padding-bottom: 6px;
  border-bottom: 1px solid #e0e0e0;
}

.cat-block__sub {
  font-size: 0.9rem;
  color: var(--text-dark-secondary);
  font-weight: 500;
  margin: 6px 0 2px;
}

.cat-block__item {
  font-size: 0.85rem;
  color: #7a7a7a;
  margin: 2px 0 2px 14px;
}

.cat-block__item::before {
  content: "– ";
}
/* ----------------------- *\
            FOOTER
\* ----------------------- */

footer {
  width: 100%;
  background-color: var(--bg_layout);
  border-top: 1px solid var(--text_layout);
  padding: 1rem;
}

.footer {
  width: 100%;
  max-width: var(--max_width);
  margin-left: auto;
  margin-right: auto;

  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: flex-end;
}

.footer a {
  color: var(--text_layout);
  font-size: 15px;
  font-weight: 600;
}
.footer a:hover {
  text-decoration: underline;
  color: var(--color_secondary);
}
@media (min-width: 640px) {
  footer {
    position: fixed;
    bottom: 0;

    z-index: 999;
  }
}
