/**
 * Fungsi Jabatan: structured legal authorities and department functions.
 */

.jkptg-department-functions {
  max-width: 1200px;
  margin: 36px auto 96px;
  color: var(--jkptg-text-primary, #00122a);
  font-family: var(--jkptg-font-family-body, Inter, sans-serif);
}

.jkptg-department-functions__section h2 {
  margin: 0 0 20px;
  font-size: var(--jkptg-font-size-xl, 20px);
  font-weight: 700;
  line-height: 24px;
}

.jkptg-department-functions__intro {
  margin: 0 0 20px;
  font-size: var(--jkptg-font-size-md, 16px);
  line-height: 22px;
}

.jkptg-department-functions__authorities,
.jkptg-department-functions__functions {
  margin: 0;
  padding: 0;
  list-style: none;
}

.jkptg-department-functions__authorities {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px 24px;
}

.jkptg-department-functions__authority {
  min-width: 0;
}

.jkptg-department-functions__authority--wide {
  grid-column: 1 / -1;
}

.jkptg-department-functions__authority-inner {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  gap: 10px;
  min-height: 102px;
  height: 100%;
  padding: 20px 15px;
  border: 1px solid var(--jkptg-border-neutral-on-light-05, #d3d7dc);
  border-radius: 8px;
  background: #f7f9fa;
  color: inherit;
  text-decoration: none;
}

.jkptg-department-functions__authority--wide .jkptg-department-functions__authority-inner {
  min-height: 54px;
  padding: 15px;
}

.jkptg-department-functions__authority a:hover,
.jkptg-department-functions__authority a:focus-visible {
  border-color: var(--jkptg-color-teal-600, #008f86);
  background: var(--jkptg-color-teal-100, #e6fffc);
  text-decoration: none;
}

.jkptg-department-functions__authority a:focus-visible {
  outline: 2px solid var(--jkptg-color-teal-600, #008f86);
  outline-offset: 2px;
}

.jkptg-department-functions__badge {
  display: inline-block;
  padding: 0;
  background: transparent;
  color: var(--jkptg-text-brand, #008f86);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  line-height: 24px;
}

.jkptg-department-functions__authority h3 {
  margin: 0;
  font-size: var(--jkptg-font-size-md, 16px);
  font-weight: 500;
  line-height: 24px;
}

.jkptg-department-functions__authority--wide h3 {
  font-size: var(--jkptg-font-size-lg, 18px);
  font-weight: 700;
}

.jkptg-department-functions__section--functions {
  margin-top: 54px;
}

.jkptg-department-functions__functions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  column-gap: 24px;
}

.jkptg-department-functions__function {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  min-height: 92px;
  padding: 20px 15px;
  border-top: 1px solid var(--jkptg-border-neutral-on-light-05, #d3d7dc);
  font-size: var(--jkptg-font-size-md, 16px);
  line-height: 24px;
}

.jkptg-department-functions__function img {
  flex: 0 0 auto;
  width: auto;
  height: auto;
  max-width: 54px;
  max-height: 54px;
  object-fit: contain;
}

@media (max-width: 991.98px) {
  .jkptg-department-functions__authorities,
  .jkptg-department-functions__functions {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 599.98px) {
  .jkptg-department-functions {
    margin: 28px auto 64px;
  }

  .jkptg-department-functions__authorities,
  .jkptg-department-functions__functions {
    grid-template-columns: minmax(0, 1fr);
  }

  .jkptg-department-functions__authorities {
    gap: 12px;
  }

  .jkptg-department-functions__authority-inner {
    min-height: 92px;
  }

  .jkptg-department-functions__section--functions {
    margin-top: 40px;
  }

  .jkptg-department-functions__function {
    min-height: 80px;
  }
}
