/**
 * Footer UI — Student Point Sikar 2026
 *
 * Ported 1:1 from index.html (css/footer.css). MUST enqueue AFTER style.css
 * so `.footer` / `.footer-bottom` win specificity ties against the legacy
 * footer rules. Design tokens are scoped to the footer containers (no global
 * :root pollution). New markup uses design class names only — legacy
 * selectors (.foot_info, .social_img, .footer h4, .footer ul li a, .footer p)
 * no longer match because the markup avoids ul / h4 / bare p where needed.
 */

.footer,
.footer-bottom,
.back-to-top {
  --primary: #1565c0;
  --primary-dark: #0d47a1;
  --accent: #f9d67b;
  --white: #ffffff;
  --transition: all .3s ease;
  --shadow-md: 0 8px 32px rgba(21, 101, 192, .14);
  --font-head: "Sora", "Plus Jakarta Sans", sans-serif;
}

/* =================== FOOTER =================== */
.footer {
  background: #0a1628;
  background-image:
    url("data:image/svg+xml,%3Csvg width='100' height='100' viewBox='0 0 100 100' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100' height='100' fill='%230a1628'/%3E%3Crect width='100' height='100' fill='%23ffffff' opacity='0.02' filter='url(%23noise)'/%3E%3Cpath d='M0,50 Q25,40 50,50 T100,50' stroke='rgba(21,101,192,0.05)' fill='none' stroke-width='1'/%3E%3Cpath d='M0,30 Q20,25 40,30 T80,30 T100,30' stroke='rgba(249,214,123,0.03)' fill='none' stroke-width='0.5'/%3E%3Cpath d='M0,70 Q25,65 50,70 T100,70' stroke='rgba(21,101,192,0.04)' fill='none' stroke-width='1'/%3E%3Ccircle cx='20' cy='20' r='1' fill='rgba(249,214,123,0.1)'/%3E%3Ccircle cx='80' cy='80' r='1.5' fill='rgba(21,101,192,0.08)'/%3E%3Ccircle cx='60' cy='40' r='0.8' fill='rgba(249,214,123,0.06)'/%3E%3C/svg%3E"),
    linear-gradient(135deg, #0a1628 0%, #0d1f35 100%);
  background-size: 100px 100px, 100% 100%;
  background-position: 0 0, 0 0;
  color: rgba(255, 255, 255, .75);
  position: relative;
}

.footer::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    repeating-linear-gradient(90deg,
      transparent,
      transparent 2px,
      rgba(21, 101, 192, 0.02) 2px,
      rgba(21, 101, 192, 0.02) 4px),
    repeating-linear-gradient(0deg,
      transparent,
      transparent 1px,
      rgba(249, 214, 123, 0.01) 1px,
      rgba(249, 214, 123, 0.01) 2px);
  pointer-events: none;
  z-index: 0;
}

.footer-top {
  padding: 70px 0 50px;
  position: relative;
  z-index: 1;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1.2fr 1.2fr 1.8fr;
  gap: 48px;
}

.footer-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}

/* `.footer-logo img` (0,2,0) outranks legacy `.footer img` (0,1,1) */
.footer-logo img {
  height: 50px;
  width: 50px;
  max-width: 50px;
  border-radius: 50%;
  object-fit: cover;
}

.footer-logo-text strong {
  display: block;
  font-family: var(--font-head);
  font-size: 16px;
  font-weight: 800;
  color: var(--white);
}

.footer-logo-text span {
  font-size: 11px;
  color: rgba(255, 255, 255, .5);
}

/* `.footer .footer-desc` (0,2,0) outranks legacy `.footer p` (0,1,1) */
.footer .footer-desc {
  font-size: 14px;
  line-height: 1.7;
  margin-bottom: 20px;
  color: rgba(255, 255, 255, .6);
}

.footer-social {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.footer-social a {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, .2);
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255, 255, 255, .6);
  font-size: 14px;
  transition: var(--transition);
}

.footer-social a:hover {
  background: var(--accent);
  color: var(--primary);
  border-color: var(--accent);
}

.footer-heading {
  font-family: var(--font-head);
  font-size: 15px;
  font-weight: 700;
  color: var(--white);
  margin-bottom: 20px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, .08);
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-links-spaced {
  margin-bottom: 24px;
}

.footer-links a {
  font-size: 14px;
  color: rgba(255, 255, 255, .6);
  display: flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  transition: var(--transition);
}

.footer-links a::before {
  content: '\203A'; /* › */
  color: var(--accent);
  font-size: 16px;
}

.footer-links a:hover {
  color: var(--accent);
  padding-left: 4px;
}

.footer-contact-item {
  display: flex;
  gap: 12px;
  margin-bottom: 16px;
  align-items: flex-start;
}

.footer-contact-item .icon {
  width: 36px;
  height: 36px;
  background: rgba(249, 214, 123, .12);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  font-size: 14px;
  flex-shrink: 0;
  margin-top: 2px;
}

.footer-contact-item .text span {
  display: block;
  font-size: 11px;
  color: rgba(255, 255, 255, .4);
  text-transform: uppercase;
  letter-spacing: .08em;
  margin-bottom: 2px;
}

.footer-contact-item .text a {
  display: block;
  font-size: 14px;
  color: rgba(255, 255, 255, .75);
  text-decoration: none;
  transition: var(--transition);
}

.footer-contact-item .text a:hover {
  color: var(--accent);
}

.footer-contact-item .text p {
  font-size: 14px;
  color: rgba(255, 255, 255, .75);
}

/* active-users widget (kept from legacy footer) */
.footer .webi-active-users {
  margin-top: 12px;
  font-size: 13px;
  letter-spacing: .5px;
  font-weight: 500;
  color: rgba(255, 255, 255, .55);
}

.footer-bottom {
  background: rgba(0, 0, 0, .3);
  padding: 18px 0;
  font-size: 13px;
  color: rgba(255, 255, 255, .4);
  position: relative;
  z-index: 1;
}

.footer-bottom .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
}

.footer-bottom-links {
  display: flex;
  gap: 20px;
}

.footer-bottom-links a {
  color: rgba(255, 255, 255, .4);
  text-decoration: none;
  transition: var(--transition);
}

.footer-bottom-links a:hover {
  color: var(--accent);
}

/* =================== BACK TO TOP =================== */
.back-to-top {
  position: fixed;
  bottom: 28px;
  right: 28px;
  z-index: 999;
  width: 44px;
  height: 44px;
  background: var(--primary);
  color: var(--white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  text-decoration: none;
  box-shadow: var(--shadow-md);
  opacity: 0;
  transform: translateY(20px);
  transition: var(--transition);
  pointer-events: none;
}

.back-to-top.visible {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.back-to-top:hover {
  background: var(--primary-dark);
  transform: translateY(-2px);
}

/* =================== FOOTER RESPONSIVE =================== */
@media (max-width: 1024px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 36px;
  }
}

@media (max-width: 768px) {
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 28px;
  }
}

@media (max-width: 640px) {
  .footer-bottom .container {
    align-items: stretch;
  }
}
