/* Footer Styles */
.footer {
  background: linear-gradient(135deg, #2549FF 0%, #000000 100%);
  backdrop-filter: blur(10px);
  color: #FFFFFF;
  padding: 2.5rem 2rem 1rem;
  margin-top: 4rem;
  border-top: 3px solid #2549FF;
}

.footer-container {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
  margin-bottom: 1.5rem;
  direction: rtl;
}

.footer-section h3 {
  color: #FFFFFF;
  margin-bottom: 0.8rem;
  font-size: 1.2rem;
  letter-spacing: 1px;
  text-transform: uppercase;
  direction: ltr;
}

.footer-section ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  direction: ltr;
  gap: 0.6rem;
}

.footer-section a {
  color: rgba(255, 255, 255, 0.9);
  text-decoration: none;
  transition: all 0.3s ease;
  position: relative;
}

.footer-section a:hover {
  color: #FFFFFF;
  padding-left: 0.5rem;
  text-decoration: underline;
}

.footer-section p {
  color: rgba(255, 255, 255, 0.85);
  direction: ltr;
  line-height: 1.5;
  margin-bottom: 0.4rem;
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.2);
  max-width: 1200px;
  margin: 0 auto;
  flex-wrap: wrap;
  gap: 0.8rem;
}

.footer-bottom p {
  color: rgba(255, 255, 255, 0.8);
  font-size: 0.9rem;
}

.footer-links {
  display: flex;
  gap: 1.5rem;
}

.footer-links a {
  color: rgba(255, 255, 255, 0.8);
  text-decoration: none;
  font-size: 0.9rem;
  transition: color 0.3s ease;
}

.footer-links a:hover {
  color: #FFFFFF;
}

/* Social Section Inline Styling */
.footer-section:nth-child(3) {
  grid-column: span 1;
}

.footer-section:nth-child(3) ul {
  display: flex;
  flex-direction: row;
  gap: 1rem;
  flex-wrap: wrap;
}

@media screen and (max-width: 1024px) {
  .footer {
    padding: 2rem 1.5rem 0.8rem;
  }

  .footer-container {
    grid-template-columns: repeat(3, 1fr);
    gap: 1.2rem;
    margin-bottom: 1.2rem;
  }

  .footer-section h3 {
    font-size: 1rem;
    margin-bottom: 0.7rem;
  }

  .footer-section ul {
    gap: 0.5rem;
  }

  /* Keep social links in a row on larger devices */
  .footer-section:nth-child(3) ul {
    flex-direction: row;
    gap: 1rem;
  }
}

@media screen and (max-width: 768px) {
  .footer {
    padding: 1.2rem 1rem 0.6rem;
    margin-top: 2.5rem;
  }

  .footer-container {
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-bottom: 1rem;
    direction: ltr;
  }

  /* Company section */
  .footer-section:nth-child(1) {
    grid-column: 1;
    grid-row: 1;
  }

  /* Quick Links section */
  .footer-section:nth-child(2) {
    grid-column: 1;
    grid-row: 2;
  }

  /* Social section positioned on right */
  .footer-section:nth-child(3) {
    grid-column: 2;
    grid-row: 1 / 3;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
  }

  .footer-section:nth-child(3) h3 {
    color: #FFFFFF;
    font-size: 0.9rem;
    margin-bottom: 0.6rem;
  }

  .footer-section:nth-child(3) ul {
    flex-direction: column;
    gap: 0.4rem;
  }

  .footer-section:nth-child(3) a {
    font-size: 0.85rem;
  }

  /* Corporate Office section spans full width */
  .footer-section:nth-child(4) {
    grid-column: 1 / -1;
  }

  .footer-section h3 {
    font-size: 0.9rem;
    margin-bottom: 0.6rem;
    letter-spacing: 0.5px;
  }

  .footer-section ul {
    gap: 0.4rem;
  }

  .footer-section a {
    font-size: 0.85rem;
  }

  .footer-section p {
    font-size: 0.85rem;
  }

  .footer-bottom {
    flex-direction: column;
    text-align: center;
    padding-top: 0.8rem;
    gap: 0.5rem;
  }

  .footer-bottom p {
    font-size: 0.75rem;
  }

  .footer-links {
    flex-direction: row;
    gap: 0.2rem;
    width: auto;
    justify-content: center;
  }

  .footer-links a {
    font-size: 0.75rem;
  }

  .footer-links a:not(:last-child)::after {
    content: '  ·  ';
    margin-left: 0.2rem;
  }
}

/* Ultra-Small Devices (320px - 360px) */
@media screen and (max-width: 360px) {
  .footer {
    padding: 1rem 0.6rem 0.5rem;
    margin-top: 1.5rem;
  }

  .footer-container {
    grid-template-columns: 1fr 1fr;
    gap: 0.7rem;
    margin-bottom: 0.7rem;
    direction: ltr;
  }

  /* Company section */
  .footer-section:nth-child(1) {
    grid-column: 1;
    grid-row: 1;
  }

  /* Quick Links section */
  .footer-section:nth-child(2) {
    grid-column: 1;
    grid-row: 2;
  }

  /* Social section positioned on right */
  .footer-section:nth-child(3) {
    grid-column: 2;
    grid-row: 1 / 3;
  }

  .footer-section:nth-child(3) h3 {
    color: #FFFFFF;
    font-size: 0.7rem;
    margin-bottom: 0.4rem;
  }

  .footer-section:nth-child(3) ul {
    flex-direction: column;
    gap: 0.25rem;
  }

  /* Corporate Office section spans full width */
  .footer-section:nth-child(4) {
    grid-column: 1 / -1;
  }

  .footer-section h3 {
    font-size: 0.75rem;
    margin-bottom: 0.4rem;
    letter-spacing: 0.3px;
    text-transform: uppercase;
  }

  .footer-section ul {
    gap: 0.25rem;
  }

  .footer-section a {
    font-size: 0.7rem;
  }

  .footer-section p {
    font-size: 0.7rem;
    line-height: 1.2;
    margin-bottom: 0.25rem;
  }

  .footer-bottom {
    padding-top: 0.6rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    gap: 0.3rem;
    flex-direction: column;
    align-items: flex-start;
  }

  .footer-bottom p {
    font-size: 0.65rem;
    margin: 0;
  }

  .footer-links {
    gap: 0.15rem;
    width: auto;
    flex-wrap: wrap;
    justify-content: center;
  }

  .footer-links a {
    font-size: 0.65rem;
  }

  .footer-links a:not(:last-child)::after {
    content: '  ·  ';
    margin-left: 0.15rem;
  }
}

/* Small Devices (361px - 375px) */
@media screen and (max-width: 375px) and (min-width: 361px) {
  .footer {
    padding: 1.1rem 0.7rem 0.6rem;
    margin-top: 1.6rem;
  }

  .footer-container {
    grid-template-columns: 1fr 1fr;
    gap: 0.8rem;
    margin-bottom: 0.8rem;
    direction: ltr;
  }

  /* Company section */
  .footer-section:nth-child(1) {
    grid-column: 1;
    grid-row: 1;
  }

  /* Quick Links section */
  .footer-section:nth-child(2) {
    grid-column: 1;
    grid-row: 2;
  }

  /* Social section positioned on right */
  .footer-section:nth-child(3) {
    grid-column: 2;
    grid-row: 1 / 3;
  }

  .footer-section:nth-child(3) h3 {
    color: #FFFFFF;
    font-size: 0.75rem;
    margin-bottom: 0.4rem;
  }

  .footer-section:nth-child(3) ul {
    flex-direction: column;
    gap: 0.3rem;
  }

  /* Corporate Office section spans full width */
  .footer-section:nth-child(4) {
    grid-column: 1 / -1;
  }

  .footer-section h3 {
    font-size: 0.8rem;
    margin-bottom: 0.45rem;
    letter-spacing: 0.3px;
  }

  .footer-section ul {
    gap: 0.3rem;
  }

  .footer-section a {
    font-size: 0.75rem;
  }

  .footer-section p {
    font-size: 0.75rem;
    line-height: 1.25;
    margin-bottom: 0.3rem;
  }

  .footer-bottom {
    padding-top: 0.7rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    gap: 0.4rem;
  }

  .footer-bottom p {
    font-size: 0.68rem;
  }

  .footer-links {
    gap: 0.2rem;
    flex-direction: row;
    justify-content: center;
  }

  .footer-links a {
    font-size: 0.68rem;
  }

  .footer-links a:not(:last-child)::after {
    content: '  ·  ';
    margin-left: 0.2rem;
  }
}

@media screen and (max-width: 480px) {
  .footer {
    padding: 1.2rem 0.8rem 0.6rem;
    margin-top: 2rem;
  }

  .footer-container {
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-bottom: 0.9rem;
    direction: ltr;
  }

  /* Company section */
  .footer-section:nth-child(1) {
    grid-column: 1;
    grid-row: 1;
  }

  /* Quick Links section */
  .footer-section:nth-child(2) {
    grid-column: 1;
    grid-row: 2;
  }

  /* Social section positioned on right */
  .footer-section:nth-child(3) {
    grid-column: 2;
    grid-row: 1 / 3;
  }

  .footer-section:nth-child(3) h3 {
    color: #FFFFFF;
    font-size: 0.85rem;
    margin-bottom: 0.5rem;
  }

  .footer-section:nth-child(3) ul {
    flex-direction: column;
    gap: 0.35rem;
  }

  /* Corporate Office section spans full width */
  .footer-section:nth-child(4) {
    grid-column: 1 / -1;
  }

  .footer-section h3 {
    font-size: 0.85rem;
    margin-bottom: 0.5rem;
    letter-spacing: 0.4px;
  }

  .footer-section ul {
    gap: 0.35rem;
  }

  .footer-section a {
    font-size: 0.8rem;
  }

  .footer-section p {
    font-size: 0.8rem;
    line-height: 1.3;
  }

  .footer-bottom {
    padding-top: 0.8rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    gap: 0.5rem;
  }

  .footer-bottom p {
    font-size: 0.7rem;
  }

  .footer-links {
    gap: 0.25rem;
    flex-direction: row;
    justify-content: center;
  }

  .footer-links a {
    font-size: 0.7rem;
  }

  .footer-links a:not(:last-child)::after {
    content: '  ·  ';
    margin-left: 0.25rem;
  }
}
