.policy-layout-grid {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 3rem;
  align-items: flex-start;
}

.policy-nav-wrapper {
  position: sticky;
  top: 120px;
}

.policy-nav-title {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 0.5rem 1rem;
  margin-bottom: 0.5rem;
}

.policy-nav .list-group-item {
  display: flex;
  align-items: center;
  background-color: transparent;
  border: none;
  padding: 0.75rem 1rem;
  color: var(--text-body);
  font-weight: 500;
  font-size: 0.9rem;
  border-radius: 8px;
  margin-bottom: 0.25rem;
  transition: all 0.2s ease-in-out;
  text-decoration: none;
}

.policy-nav .list-group-item .nav-icon {
  width: 28px;
  font-size: 0.9em;
  color: var(--text-muted);
  transition: color 0.2s ease-in-out;
}

.policy-nav .list-group-item:hover {
  background-color: var(--bg-surface);
  color: var(--text-heading);
  transform: translateX(5px);
}

.policy-nav .list-group-item:hover .nav-icon {
  color: var(--primary);
}

.policy-nav .list-group-item.active {
  background-color: var(--primary-light-theme);
  color: var(--primary);
  font-weight: 700;
  transform: translateX(0);
}

.dark-theme .policy-nav .list-group-item.active {
  background-color: rgba(var(--primary-rgb), 0.1);
}

.policy-nav .list-group-item.active .nav-icon {
  color: var(--primary);
}

.policy-progress-container {
  display: none;
}
@media (min-width: 992px) {
  .policy-progress-container {
    display: block;
    margin-top: 1.5rem;
    padding: 0 1rem;
  }
}
.progress-bar-bg {
  height: 6px;
  background-color: var(--border-color);
  border-radius: 6px;
  overflow: hidden;
}
.progress-bar-fill {
  height: 100%;
  width: 0%;
  background-color: var(--primary);
  border-radius: 6px;
  transition: width 0.1s linear;
}

.legal-section {
  font-family: var(--font-body);
  line-height: 1.8;
  text-align: justify;
  color: var(--text-body);
}

@media (max-width: 991.98px) {
  .policy-layout-grid {
    grid-template-columns: 1fr;
  }

  .policy-nav-wrapper {
    display: none;
  }

  .legal-section {
    background-color: var(--bg-surface);
    padding: 1.5rem;
    border-radius: 16px;
    border: 1px solid var(--border-color);
    margin-bottom: 100px;
  }

  .legal-section h1 {
    font-size: 1.8rem;
  }

  .legal-section h2 {
    font-size: 1.5rem;
  }
}

.mobile-topic-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  background-color: var(--bg-surface);
  border-top: 1px solid var(--border-color);
  padding: 0.75rem 1rem;
  z-index: 1020;
  box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.1);
  display: flex;
  justify-content: space-between;
  align-items: center;
  transform: translateY(100%);
  transition: transform 0.3s ease-in-out;
}
.dark-theme .mobile-topic-nav {
  box-shadow: 0 -4px 25px rgba(0, 0, 0, 0.3);
}

.mobile-topic-nav.visible {
  transform: translateY(0%);
}

.topic-nav-btn {
  background: none;
  border: none;
  color: var(--primary);
  font-size: 1.5rem;
  padding: 0.5rem;
}

.topic-nav-btn:disabled {
  color: var(--text-muted);
  opacity: 0.5;
}

.current-topic-display {
  text-align: center;
  flex-grow: 1;
  padding: 0 1rem;
}

.current-topic-title {
  display: block;
  font-weight: 600;
  color: var(--text-heading);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.current-topic-progress {
  font-size: 0.8rem;
  color: var(--text-muted);
}

@media (max-width: 767px) {
  .table-responsive {
    border: none;
  }

  .table thead {
    display: none;
  }

  .table,
  .table tbody,
  .table tr,
  .table td {
    display: block;
    width: 100%;
  }

  .table tr {
    margin-bottom: 1rem;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    overflow: hidden;
  }

  .table td {
    text-align: right;
    padding-left: 50%;
    position: relative;
    border: none;
    border-bottom: 1px solid var(--border-color);
  }

  .table tr:last-child td:last-child {
    border-bottom: none;
  }

  .table td::before {
    content: attr(data-label);
    position: absolute;
    left: 1rem;
    width: calc(50% - 2rem);
    text-align: left;
    font-weight: 600;
    color: var(--text-heading);
  }

  .table td:nth-of-type(1)::before {
    content: "Categoria:";
  }
  .table td:nth-of-type(2)::before {
    content: "Exemplos:";
  }
  .table td:nth-of-type(3)::before {
    content: "Finalidade:";
  }
}

