/* Page Header */
.page-header {
  padding-top: 10rem;
  padding-bottom: 4rem;
  background-color: var(--midnight-blue);
  color: white;
  text-align: center;
}

.header-content {
    max-width: 800px;
    margin: 0 auto;
}

.page-title {
  font-size: 3rem;
  font-weight: 800;
  margin-bottom: 1rem;
}

.page-desc {
  font-size: 1.2rem;
  opacity: 0.8;
  max-width: 600px;
  margin: 0 auto;
}

/* Shoelace-style Tab Group */
.sl-tab-group {
  display: flex;
  flex-direction: column;
}

.sl-tab-nav {
  display: flex;
  position: relative;
  border-bottom: 1px solid var(--border);
  margin-bottom: 2rem;
  gap: 2rem;
}

.sl-tab {
  background: none;
  border: none;
  font-family: inherit;
  font-size: 1rem;
  font-weight: 500;
  color: var(--text-gray);
  padding: 1rem 0;
  cursor: pointer;
  transition: color 0.3s;
  position: relative;
}

.sl-tab:hover {
  color: var(--royal-blue);
}

.sl-tab.active {
  color: var(--royal-blue);
  font-weight: 600;
}

/* Active Indicator (Underline) */
.sl-tab-active-indicator {
  position: absolute;
  bottom: -1px;
  height: 2px;
  background-color: var(--royal-blue);
  transition:
    left 0.3s cubic-bezier(0.25, 1, 0.5, 1),
    width 0.3s cubic-bezier(0.25, 1, 0.5, 1),
    transform 0.3s;
  pointer-events: none;
}

.sl-tab-panels {
  position: relative;
}

.sl-tab-panel {
  display: none;
  animation: fadeIn 0.4s ease;
}

.sl-tab-panel.active {
  display: block;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Toolkit Bar (Search & Filter) */
.toolkit-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
  flex-wrap: wrap;
  gap: 1rem;
}

.search-form {
  flex: 1;
  max-width: 400px;
}

.input-group {
  position: relative;
  display: flex;
  align-items: center;
}

.search-icon {
  position: absolute;
  left: 1rem;
  color: var(--text-gray);
  width: 20px;
  height: 20px;
}

.search-input {
  width: 100%;
  padding: 0.75rem 1rem 0.75rem 3rem;
  border: 1px solid var(--border);
  border-radius: 50px;
  font-family: inherit;
  font-size: 0.95rem;
  outline: none;
  transition:
    border-color 0.3s,
    box-shadow 0.3s;
}

.search-input:focus {
  border-color: var(--royal-blue);
  box-shadow: 0 0 0 3px rgba(30, 58, 138, 0.1);
}

.filter-dropdown {
  position: relative;
}

.btn-filter {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  background: white;
  border: 1px solid var(--border);
  border-radius: 50px;
  cursor: pointer;
  font-family: inherit;
  font-weight: 500;
  color: var(--text-gray);
  transition: all 0.3s;
}

.btn-filter:hover {
  background: var(--bg-light);
  border-color: var(--midnight-blue);
}

.filter-menu {
  position: absolute;
  top: 110%;
  right: 0;
  background: white;
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  width: 200px;
  padding: 0.5rem 0;
  z-index: 10;
  display: none;
}

.filter-menu.show {
  display: block;
}

.filter-menu li {
  padding: 0.5rem 1rem;
  cursor: pointer;
  transition: background 0.2s;
  color: var(--text-gray);
}

.filter-menu li:hover {
  background: var(--light-blue);
  color: var(--royal-blue);
}

.filter-menu li.active {
  font-weight: 600;
  color: var(--royal-blue);
}

/* News Grid */
.news-display-grid {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.news-card-full {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 2rem;
  background: white;
  border-radius: 16px;
  padding: 1.5rem;
  border: 1px solid var(--border);
  transition:
    transform 0.3s,
    box-shadow 0.3s;
}

.news-card-full:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.05);
  border-color: transparent;
}

.news-thumb {
  position: relative;
  height: 180px;
  border-radius: 12px;
  overflow: hidden;
}

.news-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s;
}

.news-card-full:hover .news-thumb img {
  transform: scale(1.05);
}

.category-tag {
  position: absolute;
  top: 1rem;
  left: 1rem;
  background: rgba(255, 255, 255, 0.9);
  padding: 0.25rem 0.75rem;
  border-radius: 50px;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--royal-blue);
  backdrop-filter: blur(4px);
}

.news-body {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.news-body h3 {
  font-size: 1.5rem;
  margin-bottom: 0.5rem;
  color: var(--midnight-blue);
}

.news-body p {
  color: var(--text-gray);
  margin-bottom: 1.5rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.meta {
  display: flex;
  gap: 1rem;
  margin-bottom: 0.5rem;
}

.meta .date {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.85rem;
  color: var(--text-gray);
}

.read-more-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 600;
  color: var(--royal-blue);
  margin-top: auto;
}

/* Pagination */
.pagination-container {
  display: flex;
  justify-content: center;
  align-items: center;
  margin-top: 4rem;
  gap: 1rem;
}

.page-numbers {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.page-btn,
.page-num {
  width: 40px;
  height: 40px;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: white;
  cursor: pointer;
  transition: all 0.2s;
  font-family: inherit;
  font-weight: 500;
  color: var(--text-gray);
}

.page-btn:hover:not(.disabled),
.page-num:hover {
  border-color: var(--royal-blue);
  color: var(--royal-blue);
}

.page-num.active {
  background: var(--royal-blue);
  color: white;
  border-color: var(--royal-blue);
}

.page-btn.disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.dots {
  color: var(--text-gray);
}

/* Regulations Layout */
.regulation-container {
  max-width: 900px;
  margin: 0 auto;
}

.section-intro {
  margin-bottom: 2rem;
  color: var(--text-gray);
}

.accordion-item {
  margin-bottom: 1rem;
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  background: white;
}

.accordion-header {
  width: 100%;
  display: flex;
  justify-content: space-between;
  font-family: "Plus Jakarta Sans", sans-serif;
  align-items: center;
  padding: 1.25rem 1.5rem;
  background: white;
  border: none;
  cursor: pointer;
  transition: background 0.3s;
}

.accordion-header:hover {
  background: var(--bg-light);
}

.accordion-header.active {
  background: var(--light-blue);
}

.header-left {
  display: flex;
  align-items: center;
  gap: 1rem;
  font-weight: 600;
  font-size: 1.1rem;
  color: var(--midnight-blue);
}

.icon-box {
  width: 40px;
  height: 40px;
  background: white;
  border-radius: 8px;
  display: flex;
  justify-content: center;
  align-items: center;
  color: var(--royal-blue);
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.accordion-header.active .icon-box {
  background: var(--royal-blue);
  color: white;
}

.acc-chevron {
  transition: transform 0.3s;
  color: var(--text-gray);
}

.accordion-header.active .acc-chevron {
  transform: rotate(180deg);
  color: var(--royal-blue);
}

.accordion-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease-out;
  border-top: 1px solid var(--border);
  /* Hide border when closed to prevent double border thickness or visual artifacts */
  border-top-width: 0; 
}

.accordion-header.active + .accordion-content {
  border-top-width: 1px;
}

.download-list {
  list-style: none;
}

.download-list li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid var(--bg-light);
  transition: background 0.2s;
}

.download-list li:hover {
  background: var(--bg-light);
}

.download-list li:last-child {
  border-bottom: none;
}

.doc-info {
  display: flex;
  flex-direction: column;
}

.doc-info strong {
  color: var(--midnight-blue);
  margin-bottom: 0.2rem;
}

.doc-info span {
  font-size: 0.9rem;
  color: var(--text-gray);
}

.btn-download {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  border-radius: 6px;
  background: var(--light-blue);
  color: var(--royal-blue);
  font-weight: 600;
  font-size: 0.9rem;
  transition: all 0.2s;
}

.btn-download:hover {
  background: var(--royal-blue);
  color: white;
}

/* Mobile Responsive */
@media (max-width: 768px) {
  .sl-tab-nav {
    gap: 1rem;
    overflow-x: auto;
    white-space: nowrap;
  }
  
  .news-card-full {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .news-thumb {
    height: 200px;
  }

  .download-list li {
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
  }
  
  .btn-download {
    width: 100%;
    justify-content: center;
  }
}
