/* Ministries Page Styles - Inherits from main.css */

/* Removed local :root and animations now use main.css variables and animations */

/* Hero Section */
.hero {
  background: linear-gradient(
      135deg,
      rgba(var(--color-primary-rgb), 0.77) 0%,
      rgba(var(--color-primary-rgb), 0.85) 30%,
      rgba(var(--color-primary-rgb), 1) 80%
    ), url("../images/image5.jpg") center / cover no-repeat;
  padding: 80px 60px;
  position: relative;
  overflow: hidden;
}

.hero-container {
  max-width: 1400px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
  position: relative;
  z-index: 2;
}

.hero-content {
  color: var(--color-white);
  animation: slideInLeft 0.8s ease-out;
}

/* Updated badge to use CSS variables */
.hero-badge {
  display: inline-block;
  background: rgba(152, 109, 167, 0.562);
  backdrop-filter: blur(10px);
  padding: 8px 18px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 500;
  margin-bottom: 24px;
  animation: fadeInUp 0.6s ease-out;
  transition: all 0.3s ease;
}

.hero-badge:hover {
  background: rgba(152, 109, 167, 0.8);
  transform: translateY(-2px);
}

.hero-title {
  font-size: 48px;
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 24px;
  animation: fadeInUp 0.8s ease-out 0.2s both;
}

.hero-description {
  font-size: 16px;
  line-height: 1.6;
  opacity: 0.95;
  margin-bottom: 36px;
  animation: fadeInUp 1s ease-out 0.4s both;
}

.hero-button {
  background: transparent;
  color: var(--color-white);
  border: 2px solid var(--color-white);
  padding: 14px 36px;
  border-radius: 8px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  transition: all 0.3s ease;
  animation: fadeInUp 1.2s ease-out 0.6s both;
}

.hero-button:hover {
  background: var(--color-white);
  color: var(--color-primary);
  transform: translateY(-3px);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
}

.hero-button .arrow {
  transition: transform 0.3s ease;
}

.hero-button:hover .arrow {
  transform: translateX(4px);
}

/* Hero Image Section with Layers */
.hero-image-section {
  position: relative;
  max-width: 500px;
  margin-left: auto;
  animation: slideInRight 0.8s ease-out;
}

/* Updated yellow accent to use CSS variable */
.yellow-accent {
  position: absolute;
  left: -10px;
  top: 10px;
  width: 100%;
  height: 330px;
  border-radius: 30px;
  background: var(--color-yellow);
  z-index: 1;
  transition: transform 0.4s ease;
}

.hero-image-section:hover .yellow-accent {
  transform: translate(8px, -8px);
}

.hero-image-container {
  position: relative;
  width: 100%;
  height: 350px;
  border-radius: 30px;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  z-index: 2;
  transition: transform 0.4s ease;
}

.hero-image-section:hover .hero-image-container {
  transform: scale(1.02);
}

.hero-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.stats-card {
  position: absolute;
  bottom: -30px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--color-white);
  padding: 20px 40px;
  border-radius: 20px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
  display: flex;
  gap: 50px;
  z-index: 3;
  animation: fadeInUp 1.4s ease-out 0.8s both;
  transition: all 0.3s ease;
}

.stats-card:hover {
  transform: translateX(-50%) translateY(-5px);
  box-shadow: 0 15px 50px rgba(0, 0, 0, 0.2);
}

.stat-item {
  text-align: center;
  transition: transform 0.3s ease;
}

.stats-card:hover .stat-item {
  transform: translateY(-3px);
}

/* Updated stat number color to use CSS variable */
.stat-number {
  font-size: 32px;
  font-weight: 700;
  color: var(--color-primary);
  line-height: 1;
  margin-bottom: 4px;
}

.stat-label {
  font-size: 12px;
  color: var(--color-text-light);
  font-weight: 500;
  line-height: 1.3;
}

/* Tabs Section */
.tabs-section {
  background: var(--color-gray-light);
  padding: 60px;
}

.tabs-container {
  max-width: 1400px;
  margin: 0 auto;
}

.tabs {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-bottom: 40px;
  flex-wrap: wrap;
}

.tab {
  padding: 14px 40px;
  border-radius: 30px;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s ease;
  border: 2px solid;
  animation: fadeInUp 0.6s ease-out both;
}

/* Updated tab colors to use CSS variables */
.tab.ministries:hover:not(.active) {
  transform: translateY(-2px);
  background: var(--color-primary-light);
  color: var(--color-white);
  box-shadow: 0 6px 20px rgba(var(--color-primary-rgb), 0.25);
}

.tab.dockets:hover:not(.active) {
  transform: translateY(-2px);
  background: var(--color-yellow);
  color: var(--color-text);
  box-shadow: 0 6px 20px rgba(var(--color-yellow-rgb), 0.3);
}

.tab.active.ministries {
  background: var(--color-primary);
  color: var(--color-white);
  border-color: var(--color-primary);
  box-shadow: 0 6px 20px rgba(var(--color-primary-rgb), 0.3);
  animation: glow 2s ease-in-out infinite;
}

.tab.inactive.ministries {
  background: var(--color-white);
  color: var(--color-primary);
  border-color: var(--color-primary);
}

.tab.active.dockets {
  background: var(--color-yellow);
  color: var(--color-text);
  border-color: var(--color-yellow);
  box-shadow: 0 6px 20px rgba(var(--color-yellow-rgb), 0.3);
  animation: glow 2s ease-in-out infinite;
}

.tab.inactive.dockets {
  background: var(--color-white);
  color: var(--color-text);
  border-color: var(--color-yellow);
}

/* Filter Section */
.filter-section {
  max-width: 900px;
  margin: 0 auto 60px;
  background: var(--color-white);
  padding: 40px;
  border-radius: 30px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  animation: fadeInUp 0.6s ease-out;
  transition: all 0.3s ease;
}

.filter-section:hover {
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

.filter-container {
  display: flex;
  align-items: center;
  gap: 30px;
  flex-wrap: wrap;
}

.filter-label {
  font-size: 16px;
  font-weight: 600;
  color: var(--color-text);
  white-space: nowrap;
}

.filter-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 0;
}

/* Updated filter button colors to use CSS variables */
.filter-btn {
  padding: 12px 32px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  border: 2px solid var(--color-border);
  background: var(--color-white);
  color: var(--color-text-light);
  transition: all 0.3s ease;
  border-right: none;
  position: relative;
  overflow: hidden;
}

.filter-btn::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: var(--color-primary);
  z-index: -1;
  transition: left 0.3s ease;
}

.filter-btn:first-child {
  border-radius: 25px 0 0 25px;
}

.filter-btn:last-child {
  border-radius: 0 25px 25px 0;
  border-right: 2px solid var(--color-border);
}

.filter-btn.active {
  background: var(--color-primary);
  color: var(--color-white);
  border-color: var(--color-primary);
  box-shadow: 0 4px 15px rgba(var(--color-primary-rgb), 0.3);
}

.filter-btn.active + .filter-btn {
  border-left-color: var(--color-primary);
}

.filter-btn:hover:not(.active) {
  background: var(--color-gray-light);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* Cards Grid */
.cards-grid {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
  padding: 0 60px 60px;
}

/* Regular Ministry Card */
.ministry-card {
  background: var(--color-white);
  border-radius: 20px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
  overflow: hidden;
  transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  cursor: pointer;
  animation: fadeInUp 0.6s ease-out both;
  position: relative;
}

.ministry-card:nth-child(1) {
  animation-delay: 0.1s;
}

.ministry-card:nth-child(2) {
  animation-delay: 0.2s;
}

.ministry-card:nth-child(3) {
  animation-delay: 0.3s;
}

.ministry-card:nth-child(4) {
  animation-delay: 0.4s;
}

.ministry-card:nth-child(5) {
  animation-delay: 0.5s;
}

.ministry-card:nth-child(6) {
  animation-delay: 0.6s;
}

.ministry-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 15px 40px rgba(var(--color-primary-rgb), 0.25);
}

.ministry-card:hover .card-image {
  transform: scale(1.08);
}

.card-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.card-content {
  padding: 20px;
}

/* Updated card tag to use CSS variable */
.card-tag {
  display: inline-block;
  background: var(--color-primary);
  color: var(--color-white);
  padding: 4px 12px;
  border-radius: 12px;
  font-size: 11px;
  font-weight: 600;
  margin-bottom: 12px;
  transition: all 0.3s ease;
  animation: fadeInUp 0.6s ease-out;
}

.ministry-card:hover .card-tag {
  transform: translateX(3px);
  box-shadow: 0 4px 10px rgba(var(--color-primary-rgb), 0.2);
}

.card-title {
  font-size: 22px;
  font-weight: 700;
  color: var(--color-text);
  line-height: 1.3;
  margin-bottom: 10px;
  transition: color 0.3s ease;
}

.ministry-card:hover .card-title {
  color: var(--color-primary);
}

.card-description {
  font-size: 13px;
  color: var(--color-text-light);
  line-height: 1.5;
  margin-bottom: 18px;
}

.card-divider {
  width: 100%;
  height: 1px;
  background: var(--color-border);
  margin-bottom: 18px;
  transition: all 0.3s ease;
}

.ministry-card:hover .card-divider {
  background: var(--color-primary);
  box-shadow: 0 1px 5px rgba(var(--color-primary-rgb), 0.2);
}

.card-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--color-primary);
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.3s ease;
  position: relative;
}

.card-link::after {
  content: "";
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--color-primary);
  transition: width 0.3s ease;
}

.card-link:hover::after {
  width: 100%;
}

.card-link:hover {
  gap: 12px;
}

/* Docket Card with Three Layers */
.docket-card {
  position: relative;
  cursor: pointer;
  transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  animation: fadeInUp 0.6s ease-out both;
}

.docket-card:nth-child(1) {
  animation-delay: 0.1s;
}

.docket-card:nth-child(2) {
  animation-delay: 0.2s;
}

.docket-card:nth-child(3) {
  animation-delay: 0.3s;
}

.docket-card:nth-child(4) {
  animation-delay: 0.4s;
}

.docket-card:nth-child(5) {
  animation-delay: 0.5s;
}

.docket-card:nth-child(6) {
  animation-delay: 0.6s;
}

.docket-card:hover {
  transform: translateY(-8px);
}

/* Updated docket layers to use CSS variables */
.docket-layer-yellow {
  position: absolute;
  top: -10px;
  right: -10px;
  width: 100%;
  height: 100%;
  background: var(--color-yellow);
  border-radius: 20px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
  transform: rotate(3deg);
  z-index: 1;
  transition: all 0.4s ease;
}

.docket-card:hover .docket-layer-yellow {
  transform: rotate(2deg) translateY(-5px);
  box-shadow: 0 8px 30px rgba(var(--color-yellow-rgb), 0.25);
}

.docket-layer-purple {
  position: absolute;
  top: -6px;
  right: -6px;
  width: 100%;
  height: 100%;
  background: var(--color-primary);
  border-radius: 20px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
  transform: rotate(1.5deg);
  z-index: 2;
  transition: all 0.4s ease;
}

.docket-card:hover .docket-layer-purple {
  transform: rotate(0.5deg) translateY(-8px);
  box-shadow: 0 10px 35px rgba(var(--color-primary-rgb), 0.3);
}

.docket-layer-white {
  position: relative;
  background: var(--color-white);
  border-radius: 20px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
  overflow: hidden;
  z-index: 3;
  transition: all 0.4s ease;
}

.docket-card:hover .docket-layer-white {
  transform: translateY(-10px);
  box-shadow: 0 15px 45px rgba(0, 0, 0, 0.15);
}

.docket-card .card-tag {
  background: var(--color-yellow);
  color: var(--color-primary);
}

/* Responsive Design */
@media (max-width: 1024px) {
  .hero {
    padding: 60px 30px;
  }

  .hero-container {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .hero-title {
    font-size: 40px;
  }

  .hero-image-section {
    margin: 0 auto;
    max-width: 400px;
  }

  .stats-card {
    flex-direction: column;
    gap: 30px;
    padding: 20px 30px;
  }

  .cards-grid {
    grid-template-columns: repeat(2, 1fr);
    padding: 0 30px 60px;
    gap: 24px;
  }

  .tabs-section {
    padding: 40px 30px;
  }

  .filter-section {
    padding: 30px;
    margin: 0 auto 40px;
  }

  .filter-container {
    flex-direction: column;
    align-items: stretch;
    gap: 20px;
  }

  .filter-buttons {
    width: 100%;
  }

  .filter-btn {
    flex: 1;
    padding: 12px 16px;
    font-size: 14px;
  }
}

@media (max-width: 768px) {
  .hero {
    padding: 50px 20px;
  }

  .hero-container {
    gap: 30px;
  }

  .hero-title {
    font-size: 28px;
  }

  .hero-description {
    font-size: 14px;
  }

  .hero-button {
    padding: 12px 28px;
    font-size: 14px;
  }

  .yellow-accent {
    height: 250px;
  }

  .hero-image-container {
    height: 280px;
  }

  .stats-card {
    width: 90%;
    padding: 16px 24px;
    font-size: 14px;
    bottom: -20px;
  }

  .stat-number {
    font-size: 24px;
  }

  .stat-label {
    font-size: 10px;
  }

  .tabs {
    gap: 12px;
    margin-bottom: 30px;
  }

  .tab {
    padding: 12px 24px;
    font-size: 14px;
  }

  .tabs-section {
    padding: 30px 20px;
  }

  .filter-section {
    padding: 20px;
    margin: 0 20px 30px;
    border-radius: 20px;
  }

  .filter-label {
    font-size: 14px;
  }

  .filter-buttons {
    width: 100%;
    overflow-x: auto;
  }

  .filter-btn {
    padding: 10px 16px;
    font-size: 12px;
    white-space: nowrap;
    flex-shrink: 0;
  }

  .cards-grid {
    grid-template-columns: 1fr;
    padding: 0 20px 40px;
    gap: 20px;
  }

  .card-image {
    height: 180px;
  }

  .card-content {
    padding: 16px;
  }

  .card-title {
    font-size: 18px;
  }

  .card-description {
    font-size: 12px;
  }
}

@media (max-width: 480px) {
  .hero {
    padding: 40px 16px;
  }

  .hero-title {
    font-size: 24px;
    line-height: 1.1;
  }

  .hero-description {
    font-size: 13px;
    margin-bottom: 24px;
  }

  .hero-button {
    padding: 10px 20px;
    font-size: 13px;
  }

  .hero-image-section {
    max-width: 100%;
  }

  .yellow-accent {
    height: 200px;
  }

  .hero-image-container {
    height: 220px;
  }

  .stats-card {
    gap: 20px;
    padding: 12px 16px;
    bottom: -16px;
  }

  .stat-number {
    font-size: 20px;
  }

  .stat-label {
    font-size: 9px;
  }

  .tabs {
    gap: 8px;
    margin-bottom: 20px;
  }

  .tab {
    padding: 10px 16px;
    font-size: 12px;
  }

  .filter-section {
    padding: 16px;
    margin: 0 16px 20px;
  }

  .filter-container {
    gap: 12px;
  }

  .filter-label {
    font-size: 12px;
  }

  .filter-buttons {
    width: 100%;
  }

  .filter-btn {
    padding: 8px 12px;
    font-size: 11px;
  }

  .cards-grid {
    padding: 0 16px 30px;
  }
}

.hidden {
  display: none;
}
