/* styles/footer.css - Footer-Specific Styles */

.footer {
  padding: 4rem 2rem 0;
  background: var(--bg-light);
}

.container {
  max-width: 1400px;
  margin: 0 auto;
}

.row {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
}

.col-md-6 {
  flex: 1 1 100%;
}

.col-lg-4 {
  flex: 1 1 calc(33.333% - 2rem);
}

.col-sm-6 {
  flex: 1 1 calc(50% - 2rem);
}

.col-lg-2 {
  flex: 1 1 calc(16.667% - 2rem);
}

.col-12 {
  flex: 1 1 100%;
}

/* Widget 1 (Logo, Description, Social Links) */
.widget1 .logo a {
  font-family: "Montserrat", sans-serif;
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--black);
  text-transform: uppercase;
  letter-spacing: 1px;
  transition: color 0.3s ease;
}

.widget1 .logo a:hover {
  color: var(--secondary); /* Vibrant green on hover */
  text-shadow: 0 0 12px rgba(72, 161, 50, 0.18);
}

.widget1 p {
  font-family: "Inter", sans-serif;
  font-size: 1rem;
  color: var(--gray);
  margin-top: 1.5rem;
}

.socialLinks {
  margin-top: 1.5rem;
}

.socialLinks ul {
  display: flex;
  gap: 1rem;
  list-style: none;
  padding: 0;
  margin: 0;
  justify-content: center;
}

.socialLinks ul li {
  display: inline-block;
}

.socialLinks ul li a {
  display: block;
  width: 40px;
  height: 40px;
  text-align: center;
  line-height: 40px;
  border-radius: 50%;
  background: var(--gray-light);
  transition: all 0.3s ease;
  color: var(--text-light);
}

.footer .socialLinks ul li a:hover,
.footer .socialLinks ul li a:focus-visible {
  transform: translateY(-3px);
  box-shadow:
    0 0 0 1px rgba(72, 161, 50, 0.14),
    0 8px 18px rgba(10, 18, 38, 0.12),
    0 0 16px rgba(72, 161, 50, 0.12) !important;
  outline: none;
}

/* Social media brand colors */
.socialLinks ul li a .fa-youtube { 
  color: #ff0000;
  font-size: 1.2rem;
}
.socialLinks ul li a .fa-x-twitter { 
  color: #000000;
  font-size: 1.2rem;
}
.socialLinks ul li a .fa-facebook-f { 
  color: #1877f2;
  font-size: 1.2rem;
}
.socialLinks ul li a .fa-instagram { 
  background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  text-fill-color: transparent;
  font-size: 1.2rem;
}

/* Dark theme adjustments */
[data-theme="dark"] .socialLinks ul li a {
  background: var(--gray-dark);
  color: var(--text-dark);
}

[data-theme="dark"] .footer .socialLinks ul li a:hover,
[data-theme="dark"] .footer .socialLinks ul li a:focus-visible {
  box-shadow:
    0 0 0 1px rgba(138, 228, 107, 0.14),
    0 8px 18px rgba(0, 0, 0, 0.24),
    0 0 16px rgba(138, 228, 107, 0.14) !important;
}

/* Widget 2 (Latest Blogs) */
.widget2 h5,
.widget3 h5,
.widget4 h5 {
  font-family: "Playfair Display", serif;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--black);
  margin-bottom: 1.5rem;
}

.widget3,
.widget4 {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  width: fit-content;
  max-width: 100%;
  margin-inline: auto;
}

.widget3 h5,
.widget4 h5 {
  position: relative;
  margin-bottom: 1.25rem;
  padding-bottom: 0.55rem;
}

.widget3 h5::after,
.widget4 h5::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 2.75rem;
  height: 2px;
  border-radius: 999px;
  background: linear-gradient(90deg, rgba(72, 161, 50, 0.9), rgba(72, 161, 50, 0.18));
}

.widget2 .media {
  margin-bottom: 1.5rem;
}

.widget2 .media p {
  font-family: "Inter", sans-serif;
  font-size: 1rem;
  font-weight: 600;
  color: var(--gray-dark);
  transition: color 0.3s ease;
}

.widget2 .media a:hover p {
  color: var(--secondary);
}

.widget2 .media span {
  font-size: 0.8rem;
  color: var(--secondary);
  text-transform: uppercase;
  display: block;
  margin-top: 0.5rem;
}

.widget2 {
  position: relative;
}

.footer-blog-stack {
  position: relative;
  --footer-card-height: 7rem;
  --footer-enter-top-y: -6.75rem;
  --footer-top-y: 0.5rem;
  --footer-middle-y: 4.95rem;
  --footer-bottom-y: 10.1rem;
  --footer-enter-bottom-y: 15.35rem;
  --footer-exit-bottom-y: 17rem;
  --footer-exit-top-y: -5.4rem;
  min-height: calc(var(--footer-bottom-y) + var(--footer-card-height));
  padding: 0.45rem 0 0.15rem;
  overflow: hidden;
}

.footer-blog-card {
  position: absolute;
  inset: 0 auto auto 0;
  width: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.45rem;
  min-height: var(--footer-card-height);
  padding: 1rem 1.15rem;
  border-radius: 1.1rem;
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(72, 161, 50, 0.12);
  box-shadow:
    0 10px 26px rgba(10, 18, 38, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.75);
  text-decoration: none;
  transform-origin: center;
  transition:
    transform 1.05s cubic-bezier(0.22, 1, 0.36, 1),
    opacity 1.05s cubic-bezier(0.22, 1, 0.36, 1),
    box-shadow 0.5s ease,
    border-color 0.5s ease,
    filter 0.5s ease;
  will-change: transform, opacity;
}

.footer-blog-card time {
  font-family: "Inter", sans-serif;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--gray);
  opacity: 0.88;
  text-transform: uppercase;
}

.footer-blog-card-title {
  font-family: "Inter", sans-serif;
  font-size: 1.1rem;
  line-height: 1.45;
  font-weight: 700;
  color: var(--gray-dark);
  transition: color 0.3s ease, text-shadow 0.3s ease;
}

.footer-blog-card.position-top,
.footer-blog-card.position-bottom {
  z-index: 1;
  cursor: pointer;
  filter: saturate(0.92);
}

.footer-blog-card.position-incoming-top {
  transform: translateY(var(--footer-enter-top-y)) scale(0.9);
  opacity: 0;
  z-index: 0;
  pointer-events: none;
}

.footer-blog-card.position-top {
  transform: translateY(var(--footer-top-y)) scale(0.9);
  opacity: 0.2;
}

.footer-blog-card.position-middle {
  z-index: 3;
  cursor: pointer;
  transform: translateY(var(--footer-middle-y)) scale(1);
  opacity: 1;
  filter: none;
  box-shadow:
    0 18px 34px rgba(10, 18, 38, 0.12),
    0 0 18px rgba(72, 161, 50, 0.08);
}

.footer-blog-card.position-bottom {
  transform: translateY(var(--footer-bottom-y)) scale(0.9);
  opacity: 0.18;
}

.footer-blog-card.position-outgoing-bottom {
  transform: translateY(var(--footer-exit-bottom-y)) scale(0.86);
  opacity: 0;
  z-index: 0;
  pointer-events: none;
}

.footer-blog-card.position-outgoing-top {
  transform: translateY(var(--footer-exit-top-y)) scale(0.86);
  opacity: 0;
  z-index: 0;
  pointer-events: none;
}

.footer-blog-card.position-incoming-bottom {
  transform: translateY(var(--footer-enter-bottom-y)) scale(0.9);
  opacity: 0;
  z-index: 0;
  pointer-events: none;
}

.footer-blog-card.position-middle .footer-blog-card-title,
.footer-blog-card.is-active .footer-blog-card-title {
  color: var(--secondary);
  text-shadow: 0 0 14px rgba(72, 161, 50, 0.16);
}

.footer-blog-card:hover,
.footer-blog-card:focus-visible {
  border-color: rgba(72, 161, 50, 0.28);
  box-shadow:
    0 18px 34px rgba(10, 18, 38, 0.14),
    0 0 18px rgba(72, 161, 50, 0.12);
  outline: none;
}

.footer-blog-card:hover .footer-blog-card-title,
.footer-blog-card:focus-visible .footer-blog-card-title {
  color: var(--secondary);
  text-shadow: 0 0 14px rgba(72, 161, 50, 0.2);
}

/* Widgets 3 & 4 (Quick Links, Other Links) */
.widget3 ul,
.widget4 ul {
  list-style: none;
  margin: 0;
  padding: 0;
  width: 100%;
}

.widget3 ul li,
.widget4 ul li {
  margin: 0;
}

.footer-platform-stack {
  --footer-platform-row-height: 1.56rem;
  --footer-platform-row-gap: 1rem;
  --footer-platform-enter-top-y: -2.7rem;
  --footer-platform-row1-y: 0;
  --footer-platform-row2-y: calc(var(--footer-platform-row-height) + var(--footer-platform-row-gap));
  --footer-platform-row3-y: calc((var(--footer-platform-row-height) + var(--footer-platform-row-gap)) * 2);
  --footer-platform-row4-y: calc((var(--footer-platform-row-height) + var(--footer-platform-row-gap)) * 3);
  --footer-platform-row5-y: calc((var(--footer-platform-row-height) + var(--footer-platform-row-gap)) * 4);
  --footer-platform-exit-bottom-y: calc((var(--footer-platform-row-height) + var(--footer-platform-row-gap)) * 5 + 0.55rem);
  position: relative;
  width: 100%;
  max-width: 12.25rem;
  min-width: 0;
  min-height: calc(
    (var(--footer-platform-row-height) * 5) +
    (var(--footer-platform-row-gap) * 4)
  );
  overflow: hidden;
}

.footer-platform-card {
  position: absolute;
  inset: 0 auto auto 0;
  width: 100%;
  font-family: "Inter", sans-serif;
  font-size: 1rem;
  color: var(--gray);
  display: flex;
  align-items: center;
  justify-content: flex-start;
  height: var(--footer-platform-row-height);
  padding: 0;
  margin-bottom: 0;
  border-radius: 0.85rem;
  line-height: 1.35;
  text-decoration: none;
  letter-spacing: 0;
  transition:
    color 0.3s ease,
    text-shadow 0.3s ease,
    letter-spacing 0.28s ease,
    transform 1.18s cubic-bezier(0.22, 1, 0.36, 1),
    opacity 1.05s cubic-bezier(0.22, 1, 0.36, 1),
    filter 0.28s ease;
  will-change: transform, opacity;
}

.footer-platform-card.position-incoming-top {
  transform: translateY(var(--footer-platform-enter-top-y));
  opacity: 0;
  z-index: 0;
  pointer-events: none;
}

.footer-platform-card.position-row1 {
  transform: translateY(var(--footer-platform-row1-y));
  opacity: 1;
  z-index: 5;
}

.footer-platform-card.position-row2 {
  transform: translateY(var(--footer-platform-row2-y));
  opacity: 1;
  z-index: 4;
}

.footer-platform-card.position-row3 {
  transform: translateY(var(--footer-platform-row3-y));
  opacity: 1;
  z-index: 3;
}

.footer-platform-card.position-row4 {
  transform: translateY(var(--footer-platform-row4-y));
  opacity: 1;
  z-index: 2;
}

.footer-platform-card.position-row5 {
  transform: translateY(var(--footer-platform-row5-y));
  opacity: 1;
  z-index: 1;
}

.footer-platform-card.position-outgoing-bottom {
  transform: translateY(var(--footer-platform-exit-bottom-y));
  opacity: 0;
  z-index: 0;
  pointer-events: none;
}

.footer-platform-card:hover,
.footer-platform-card:focus-visible {
  color: var(--secondary);
  text-shadow: 0 0 12px rgba(72, 161, 50, 0.18);
  filter: saturate(1.05);
  letter-spacing: 0.01em;
  transform-origin: left center;
  outline: none;
}

.widget3 ul li a,
.widget4 ul li a {
  font-family: "Inter", sans-serif;
  font-size: 1rem;
  color: var(--gray);
  display: block;
  margin-bottom: 0.9rem;
  transition: color 0.3s ease, transform 0.3s ease;
}

.widget3 ul li a:hover,
.widget4 ul li a:hover {
  color: var(--secondary);
  text-shadow: 0 0 12px rgba(72, 161, 50, 0.18);
  transform: translateX(4px);
}

.widget1 .logo a:hover,
.widget3 ul li a:hover,
.widget4 ul li a:hover {
  filter: saturate(1.05);
}

/* Copyright Area */
.copyRightArea {
  margin-top: 3rem;
  border-top: 1px solid rgba(0, 0, 0, 0.1);
  padding: 1.5rem 0;
}

.copyRightArea p {
  font-family: "Inter", sans-serif;
  font-size: 0.9rem;
  color: var(--gray-dark);
  text-align: center;
}

/* Dark Mode Adjustments */
[data-theme="dark"] .footer {
  background: var(--bg-dark);
}

[data-theme="dark"] .widget1 .logo a,
[data-theme="dark"] .widget2 h5,
[data-theme="dark"] .widget3 h5,
[data-theme="dark"] .widget4 h5 {
  color: var(--white);
}

[data-theme="dark"] .widget3 h5::after,
[data-theme="dark"] .widget4 h5::after {
  background: linear-gradient(90deg, rgba(138, 228, 107, 0.92), rgba(138, 228, 107, 0.18));
}

[data-theme="dark"] .widget1 .logo a:hover {
  color: var(--secondary-light); /* Lighter green for dark mode hover */
  text-shadow: 0 0 12px rgba(138, 228, 107, 0.22);
}

[data-theme="dark"] .widget1 p,
[data-theme="dark"] .widget3 ul li a,
[data-theme="dark"] .widget4 ul li a {
  color: var(--gray);
}

[data-theme="dark"] .footer-platform-card {
  color: var(--gray);
}

[data-theme="dark"] .footer-platform-card:hover,
[data-theme="dark"] .footer-platform-card:focus-visible {
  color: var(--secondary-light);
  text-shadow: 0 0 12px rgba(138, 228, 107, 0.2);
}

[data-theme="dark"] .widget2 .media p {
  color: var(--gray);
}

[data-theme="dark"] .widget2 .media a:hover p {
  color: var(--secondary-light);
}

[data-theme="dark"] .footer-blog-card {
  background: rgba(32, 39, 56, 0.92);
  border-color: rgba(138, 228, 107, 0.14);
  box-shadow:
    0 14px 30px rgba(0, 0, 0, 0.28),
    inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

[data-theme="dark"] .footer-blog-card time {
  color: var(--gray);
}

[data-theme="dark"] .footer-blog-card-title {
  color: var(--text-dark);
}

[data-theme="dark"] .footer-blog-card.position-middle,
[data-theme="dark"] .footer-blog-card.is-active {
  box-shadow:
    0 18px 34px rgba(0, 0, 0, 0.32),
    0 0 18px rgba(138, 228, 107, 0.1);
}

[data-theme="dark"] .footer-blog-card.position-middle .footer-blog-card-title,
[data-theme="dark"] .footer-blog-card.is-active .footer-blog-card-title,
[data-theme="dark"] .footer-blog-card:hover .footer-blog-card-title,
[data-theme="dark"] .footer-blog-card:focus-visible .footer-blog-card-title {
  color: var(--secondary-light);
  text-shadow: 0 0 14px rgba(138, 228, 107, 0.22);
}

[data-theme="dark"] .footer-blog-card:hover,
[data-theme="dark"] .footer-blog-card:focus-visible {
  border-color: rgba(138, 228, 107, 0.28);
  box-shadow:
    0 18px 34px rgba(0, 0, 0, 0.35),
    0 0 18px rgba(138, 228, 107, 0.14);
}

[data-theme="dark"] .copyRightArea {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

[data-theme="dark"] .copyRightArea p {
  color: var(--gray);
}

/* Responsive Adjustments */
@media (max-width: 1024px) {
  .footer {
      padding: 3rem 1.5rem 0;
  }

  .col-lg-4,
  .col-lg-2 {
      flex: 1 1 calc(50% - 1.5rem);
  }
}

@media (max-width: 600px) {
  .footer {
      padding: 2rem 1rem 0;
  }

  .container,
  .row,
  .widget1,
  .widget2,
  .widget3,
  .widget4,
  .media,
  .media-body,
  .content {
      width: 100%;
      max-width: 100%;
      min-width: 0;
  }

  .col-md-6,
  .col-lg-4,
  .col-sm-6,
  .col-lg-2 {
      flex: 0 0 100%;
      max-width: 100%;
      min-width: 0;
  }

  .widget2 h5,
  .widget3 h5,
  .widget4 h5 {
      font-size: 1.3rem;
  }

  .widget3,
  .widget4 {
      width: 100%;
      max-width: 18rem;
  }

  .widget1 .logo a,
  .footer-blog-card-title,
  .widget2 .media p,
  .widget3 ul li a,
  .widget4 ul li a,
  .copyRightArea p {
      overflow-wrap: anywhere;
  }

  .footer-blog-stack {
      --footer-card-height: 6.55rem;
      --footer-enter-top-y: -6.2rem;
      --footer-top-y: 0.45rem;
      --footer-middle-y: 4.55rem;
      --footer-bottom-y: 9.15rem;
      --footer-enter-bottom-y: 14rem;
      --footer-exit-bottom-y: 15.4rem;
      --footer-exit-top-y: -4.8rem;
  }

  .footer-blog-card {
      padding: 0.95rem 1rem;
  }

  .footer-platform-stack {
      --footer-platform-row-height: 1.5rem;
      --footer-platform-row-gap: 0.92rem;
      max-width: 100%;
  }
}
