.directory-mode {
  margin: 0 0 54px;
  text-align: center;
}

.directory-mode > p {
  margin: 0 0 14px;
  color: var(--green-900);
  font-weight: 850;
}

.directory-mode > div {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 320px));
  justify-content: center;
  gap: 14px;
}

.directory-mode button {
  display: flex;
  min-height: 74px;
  padding: 14px 20px;
  align-items: center;
  justify-content: center;
  gap: 12px;
  color: var(--green-900);
  background: white;
  border: 2px solid var(--line);
  border-radius: 18px;
  box-shadow: var(--shadow-soft);
  font: inherit;
  font-weight: 850;
  cursor: pointer;
}

.directory-mode button span {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  color: white;
  background: var(--green-700);
  border-radius: 12px;
}

.directory-mode button[aria-selected="true"] {
  color: white;
  background: var(--green-800);
  border-color: var(--green-800);
}

.directory-mode button[aria-selected="true"] span {
  color: var(--green-900);
  background: var(--gold);
}

[data-directory-panel][hidden] {
  display: none;
}

.company-card .company-actions {
  grid-template-columns: 1fr 1fr;
}

.company-detail-placeholder {
  display: flex;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 1px;
  color: var(--green-700);
  background: #f1f5f2;
  border: 1px dashed #b8c8bd;
  border-radius: 12px;
  font-size: 0.78rem;
  font-weight: 800;
  line-height: 1.15;
}

.company-detail-placeholder small {
  color: var(--text-muted);
  font-size: 0.62rem;
  font-weight: 700;
}

.company-source-note {
  margin-top: 28px;
  padding: 18px 20px;
  background: #f6f8f6;
  border-radius: 14px;
}

.company-source-note strong {
  color: var(--green-900);
}

.company-source-note p {
  margin: 7px 0 0;
}

.company-source-note a {
  color: var(--green-800);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.directory-list,
.company-list {
  scroll-margin-top: 110px;
}

@media (max-width: 620px) {
  .directory-mode {
    margin-bottom: 40px;
  }

  .directory-mode > div {
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }

  .directory-mode button {
    min-height: 88px;
    padding: 11px 7px;
    flex-direction: column;
    gap: 7px;
    font-size: 0.76rem;
  }

  .directory-mode button span {
    width: 34px;
    height: 34px;
  }
}
