/* =============================================
   MOBILE FOOTER
   ============================================= */

/* Hide mobile footer on desktop */
.footer-mobile {
  display: none;
}

@media (max-width: 768px) {

  /* Override footer-section fixed height/overflow for mobile */
  .footer-section {
    height: auto;
    overflow: visible;
    background: #070807;
  }

  .footer-section::before {
    display: none;
  }

  /* Hide all desktop footer elements */
  .footer-stage,
  .footer-bg-colors,
  .footer-top-bg,
  .footer-main-divider {
    display: none;
  }

  .footer-mobile {
    display: block;
    background: #070807;
    font-family: "Manrope", sans-serif;
  }

  /* --- Reference-style compact footer --- */
  .fm-body {
    --fm-bg: #070807;
    --fm-line: rgba(255, 255, 255, 0.13);
    --fm-muted: rgba(255, 255, 255, 0.52);
    --fm-lime: var(--lime);
    background:
      radial-gradient(circle at 82% 8%, rgba(255, 255, 255, 0.045), transparent 30%),
      linear-gradient(180deg, #0a0b0a 0%, var(--fm-bg) 44%, #040504 100%);
    color: #ffffff;
    padding: 26px clamp(22px, 6vw, 40px) 34px;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: hidden;
  }

  .fm-body::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    background-image:
      linear-gradient(rgba(255, 255, 255, 0.045) 1px, transparent 1px),
      linear-gradient(90deg, rgba(255, 255, 255, 0.035) 1px, transparent 1px);
    background-size: 28px 28px;
    background-position: 0 0;
    -webkit-mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.42) 0%, #000000 46%, #000000 100%);
    mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.42) 0%, #000000 46%, #000000 100%);
    opacity: 0.42;
  }

  .fm-body > * {
    position: relative;
    z-index: 1;
  }
  .fm-logo {
    display: block;
    width: clamp(126px, 36vw, 168px);
    margin: 2px 0 30px;
    text-decoration: none;
    -webkit-tap-highlight-color: transparent;
  }

  .fm-logo img {
    display: block;
    width: 100%;
    height: auto;
  }

  .fm-contact-list {
    display: flex;
    flex-direction: column;
    gap: 0;
    margin: 0 0 18px;
  }

  .fm-contact-item {
    display: grid;
    min-height: 84px;
    grid-template-columns: 52px minmax(0, 1fr);
    align-items: center;
    gap: 12px;
    padding: 14px 0;
    color: inherit;
    text-decoration: none;
    transition: transform 140ms var(--ease-out), opacity 160ms var(--ease-out);
    -webkit-tap-highlight-color: transparent;
  }

  .fm-contact-item:not(:last-child) {
    border-bottom: 1px solid var(--fm-line);
  }

  .fm-contact-item:active {
    transform: translateX(2px);
    opacity: 0.82;
  }

  .fm-contact-mark {
    width: 34px;
    height: 34px;
    justify-self: start;
    color: var(--fm-lime);
    fill: none;
    stroke: currentColor;
    stroke-width: 2.15;
    stroke-linecap: round;
    stroke-linejoin: round;
  }

  .fm-contact-item .footer-contact-text {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: 5px;
  }

  .fm-contact-item .contact-link {
    color: #ffffff;
    font-size: 15px;
    font-weight: 800;
    line-height: 1.15;
    letter-spacing: -0.24px;
    text-decoration: none;
  }

  .fm-contact-item .contact-desc {
    color: var(--fm-muted);
    font-size: 13px;
    font-weight: 500;
    line-height: 1.25;
    margin: 0;
  }

  .fm-divider {
    height: 1px;
    background: var(--fm-line);
  }

  .fm-accordion {
    border-bottom: 1px solid var(--fm-line);
  }

  .fm-acc-trigger {
    width: 100%;
    min-height: 62px;
    padding: 0;
    border: 0;
    background: transparent;
    color: rgba(255, 255, 255, 0.86);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    font-family: "Manrope", sans-serif;
    font-size: 13px;
    font-weight: 900;
    letter-spacing: -0.08px;
    text-align: left;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
  }

  .fm-acc-plus {
    width: 14px;
    height: 14px;
    position: relative;
    flex: 0 0 auto;
    color: rgba(255, 255, 255, 0.84);
  }

  .fm-acc-plus::before,
  .fm-acc-plus::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 14px;
    height: 1.5px;
    border-radius: 999px;
    background: currentColor;
    transform: translate(-50%, -50%);
    transition: transform 180ms var(--ease-out), opacity 180ms var(--ease-out);
  }

  .fm-acc-plus::after {
    transform: translate(-50%, -50%) rotate(90deg);
  }

  .fm-accordion.is-open .fm-acc-plus::after {
    opacity: 0;
    transform: translate(-50%, -50%) rotate(0deg);
  }

  .fm-acc-body[hidden] {
    display: none;
  }

  .fm-acc-body {
    padding: 0 0 18px;
  }

  .fm-links-list {
    list-style: none;
    margin: -3px 0 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
  }

  .fm-link {
    color: rgba(255, 255, 255, 0.82);
    display: flex;
    width: 100%;
    min-height: 28px;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    font-size: 13px;
    font-weight: 650;
    letter-spacing: -0.12px;
    text-decoration: none;
    transition: color 160ms var(--ease-out), transform 140ms var(--ease-out);
  }

  .fm-link::after {
    content: "";
    width: 13px;
    height: 13px;
    flex-shrink: 0;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cline x1='7' y1='17' x2='17' y2='7'/%3E%3Cpolyline points='7 7 17 7 17 17'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-size: contain;
    opacity: 0.5;
    transition: opacity 160ms var(--ease-out), transform 160ms var(--ease-out);
  }

  .fm-link:active {
    color: #ffffff;
    transform: translateX(2px);
  }

  .fm-link:active::after {
    opacity: 0.9;
  }

  .fm-social-row {
    min-height: 84px;
    border-bottom: 1px solid var(--fm-line);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
  }

  .fm-social-title {
    color: rgba(255, 255, 255, 0.55);
    font-size: 13px;
    font-weight: 750;
    letter-spacing: -0.12px;
    margin: 0;
  }

  .fm-social {
    display: flex;
    gap: 12px;
    flex: 0 0 auto;
  }

  .fm-social .social-btn {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #121311;
    border: 1px solid rgba(255, 255, 255, 0.24);
    color: rgba(255, 255, 255, 0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    transition:
      transform 140ms var(--ease-out),
      border-color 180ms var(--ease-out),
      color 180ms var(--ease-out),
      background-color 180ms var(--ease-out);
    -webkit-tap-highlight-color: transparent;
  }

  .fm-social .social-btn:active {
    transform: scale(0.94);
    border-color: rgb(var(--lime-rgb) / 0.74);
    background: rgb(var(--lime-rgb) / 0.08);
    color: var(--fm-lime);
  }

  .fm-social .social-icon {
    width: 15px;
    height: 15px;
  }

  .fm-bottom {
    padding-top: 25px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }

  .fm-bottom p {
    color: rgba(255, 255, 255, 0.38);
    font-size: 10px;
    font-weight: 600;
    line-height: 1.35;
    letter-spacing: -0.12px;
    margin: 0;
  }
}

@media (min-width: 520px) and (max-width: 768px) {
  .fm-body {
    padding-left: clamp(36px, 9vw, 72px);
    padding-right: clamp(36px, 9vw, 72px);
  }
}