/* Footer Responsive Styles - v2.4 */

#footer {
    background: #2c3e50;
    color: #e8e8e8;
    padding: 40px 0 40px; /* make top and bottom equal (30px) */
    border: none;
}

.footer-widgets {
    margin-bottom: 0;
}

.footer-col {
    margin-bottom: 40px;
}

.footer-col h5 {
    color: #fff;
    margin-bottom: 20px;
    font-weight: 700;
    font-size: 16px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Footer text elements */
.footer-item {
    font-size: 14px;
    margin-bottom: 10px;
    color: #d0d0d0;
    line-height: 1.6;
}

.footer-item-bold {
    font-weight: 700;
    display: block;
    margin-bottom: 12px;
    color: #fff;
    font-size: 15px;
}

.footer-label {
    font-weight: 600;
    color: #fff;
}

/* Navigation footer */
.footer-col .nav-footer {
    list-style: none;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.footer-col .nav-footer a {
    color: #d0d0d0;
    text-decoration: none;
    font-size: 14px;
    transition: color 0.3s ease;
}

.footer-col .nav-footer a:hover {
    color: #5dade2;
}

.footer-policies {
    margin-bottom: 25px;
}

/* Social Media Icons */
.footer-social ul {
    list-style: none;
    padding: 0;
    display: flex;
    gap: 15px;
    width: 100%;
}

.footer-social ul li {
    display: flex;
    align-items: center;
    justify-content: center;
}

.footer-social ul li a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    color: #fff;
    transition: all 0.3s ease;
}

.footer-social ul li a:hover {
    background: #5dade2;
    color: #fff;
}

/* Footer Bottom */
.footer-bottom {
    border-top: 1px solid #34495e;
    margin-top: 40px;
    padding-top: 30px;
    padding-bottom: 20px;
    text-align: center;
}

.footer-copyright-text {
    color: #d0d0d0;
    font-size: 13px;
    margin-bottom: 12px;
    margin: 0;
    line-height: 1.6;
}

.footer-compliance-text {
    margin-bottom: 12px;
    font-size: 13px;
    color: #d0d0d0;
    line-height: 1.6;
}

.footer-visit-count {
    color: #f39c12;
    font-weight: 600;
    font-size: 14px;
    margin-top: 15px;
}

.footer-visit-count span {
    color: #fff;
    font-weight: 700;
}

.footer-bottom a {
    color: #5dade2;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-bottom a:hover {
    color: #2ecc71;
    text-decoration: underline;
}

/* Tablet: 768px - 991px */
@media (min-width: 768px) and (max-width: 991px) {
    #footer {
        padding: 25px 0; /* top and bottom equal (25px) */
    }

    .footer-col {
        margin-bottom: 30px;
    }

    .footer-col h5 {
        font-size: 15px;
        margin-bottom: 15px;
    }

    .footer-item {
        font-size: 13px;
        margin-bottom: 8px;
    }

    .footer-item-bold {
        font-size: 14px;
        margin-bottom: 10px;
    }

    .footer-col .nav-footer a {
        font-size: 13px;
    }
}

/* Mobile: < 768px */
@media (max-width: 767px) {
    #footer {
        padding: 20px 14px; /* mobile: top/bottom 20px, symmetric horizontal gutter */
        background: #1e2433;
    }

    /* control spacing via footer-widgets so footer-bottom gap is predictable */
    .footer-widgets {
        margin-bottom: 3px !important; /* target ~3px gap between widgets and footer-bottom */
        padding-bottom: 0 !important; /* override legacy theme padding */
        min-height: 0 !important; /* override legacy min-height */
        text-align: left;
    }

    /* remove per-column bottom margin to avoid double spacing */
    .footer-col {
        margin-bottom: 0;
        text-align: left;
        padding: 0;
        border-bottom: none;
        padding-left: 0; /* ensure left padding comes from container, not column */
    }

    .footer-col:last-child {
        border-bottom: none;
    }

    .footer-col h5 {
        font-size: 15px;
        margin-bottom: 12px;
        text-align: left;
        font-weight: 600;
    }

    .footer-item,
    .footer-item-bold,
    .footer-col .nav-footer a {
        font-size: 13px;
        text-align: left;
        margin-bottom: 6px;
        line-height: 1.5;
    }

    .footer-social ul {
        gap: 15px;
        justify-content: flex-start;
        margin-top: 8px !important; /* reduced spacing above icons */
        margin-bottom: 0 !important; /* force no bottom spacing so combined gap is controlled by .footer-widgets */
        padding-left: 0; /* align icons to left gutter */
    }

    /* Nudge icons down slightly on mobile to visually reduce gap to ~3px */
    .footer-social {
        margin-bottom: -8px !important;
    }

    .footer-social ul li a {
        width: 32px;
        height: 32px;
        background: rgba(255, 255, 255, 0.08);
        display: flex;
        align-items: center;
        justify-content: center;
        border-radius: 4px;
    }

    /* apply to social links generated inline */
    .social-link-inline {
        width: 32px !important;
        height: 32px !important;
        border-radius: 4px !important;
    }

    .footer-social ul li a:hover {
        background: rgba(255, 255, 255, 0.15);
    }

    .footer-bottom {
        margin-top: 20px;
        padding-top: 20px;
        padding-bottom: 15px;
        text-align: left;
        border-top: 1px solid rgba(255, 255, 255, 0.08);
        padding-left: 14px; /* align footer-bottom with gutter */
        padding-right: 14px;
    }

    /* Strong override: ensure footer-bottom top gap is approx 3px on mobile */
    #footer .footer-bottom {
        margin-top: 0 !important;
        padding-top: 3px !important;
    }

    .footer-copyright-text,
    .footer-compliance-text,
    .footer-visit-count {
        font-size: 12px;
        margin-bottom: 8px;
        text-align: left;
        line-height: 1.6;
    }
}

/* Extra Small: < 576px */
@media (max-width: 575px) {
    #footer {
        padding: 15px 10px; /* XS: top/bottom 15px, symmetric horizontal gutter */
        background: #1e2433;
    }

    .footer-widgets {
        margin-bottom: 3px !important; /* enforce ~3px gap on XS */
        padding-bottom: 0 !important; /* override legacy theme padding on XS */
        min-height: 0 !important;
    }

    .footer-col {
        margin-bottom: 0;
        text-align: left;
        padding: 0;
        border-bottom: none;
        padding-left: 0;
    }

    .footer-col:last-child {
        border-bottom: none;
    }

    .footer-col h5 {
        font-size: 14px;
        margin-bottom: 10px;
        text-align: left;
        font-weight: 600;
    }

    .footer-item,
    .footer-item-bold,
    .footer-col .nav-footer a {
        font-size: 12px;
        text-align: left;
        margin-bottom: 5px;
        line-height: 1.5;
    }

    .footer-social ul {
        gap: 12px;
        justify-content: flex-start;
        margin-top: 6px !important; /* reduced on XS */
        margin-bottom: 0 !important; /* remove bottom margin so overall gap is controlled by footer-widgets */
        padding-left: 0;
    }

    /* Nudge icons down slightly on XS to visually reduce gap to ~3px */
    .footer-social {
        margin-bottom: -6px !important;
    }

    .footer-social ul li a {
        width: 28px;
        height: 28px;
        background: rgba(255, 255, 255, 0.08);
        display: flex;
        align-items: center;
        justify-content: center;
        border-radius: 4px;
    }

    /* apply to social links generated inline */
    .social-link-inline {
        width: 28px !important;
        height: 28px !important;
        border-radius: 4px !important;
    }

    .footer-social ul li a:hover {
        background: rgba(255, 255, 255, 0.15);
    }

    .footer-bottom {
        margin-top: 15px;
        padding-top: 18px;
        padding-bottom: 10px;
        text-align: left;
        border-top: 1px solid rgba(255, 255, 255, 0.08);
        padding-left: 10px;
        padding-right: 10px;
    }

    /* Strong override: ensure footer-bottom top gap is approx 3px on XS */
    #footer .footer-bottom {
        margin-top: 0 !important;
        padding-top: 3px !important;
    }

    .footer-copyright-text,
    .footer-compliance-text,
    .footer-visit-count {
        font-size: 11px;
        margin-bottom: 6px;
        text-align: left;
        line-height: 1.5;
    }
}

/* Dark Mode */
.dark-mode #footer {
    background: #1a1f26;
    color: #e0e0e0;
}

/* Remove Bootstrap gutter from footer areas (force no left/right padding) */
/* This prevents calc(var(--bs-gutter-x) * .5) from creating uneven gutters */
#footer .container,
#footer .container-fluid,
#footer .footer-bottom .container {
    padding-left: 0 !important;
    padding-right: 0 !important;
}

#footer .row,
#footer .footer-bottom .row {
    margin-left: 0 !important;
    margin-right: 0 !important;
}

.footer-bottom,
.footer-bottom [class*="col-"],
.footer-bottom > div {
    padding-left: 0 !important;
    padding-right: 0 !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
}

.dark-mode .footer-col h5 {
    color: #fff;
}

.dark-mode .footer-item,
.dark-mode .footer-item-bold,
.dark-mode .footer-label {
    color: #d0d0d0;
}

.dark-mode .footer-col .nav-footer a {
    color: #a0a0a0;
}

.dark-mode .footer-col .nav-footer a:hover {
    color: #5dade2;
}

.dark-mode .footer-bottom {
    border-top-color: #2a2f36;
}

.dark-mode .footer-copyright-text,
.dark-mode .footer-compliance-text,
.dark-mode .footer-visit-count {
    color: #a0a0a0;
}

.dark-mode .footer-bottom a {
    color: #5dade2;
}

.dark-mode .footer-bottom a:hover {
    color: #69c0ff;
}

/* Center footer-bottom column contents (override left-align on mobile) */
#footer .footer-bottom .col-md-12 {
    text-align: center !important;
}

#footer .footer-bottom .col-md-12 .footer-copyright-text,
#footer .footer-bottom .col-md-12 .footer-compliance-text,
#footer .footer-bottom .col-md-12 .footer-visit-count {
    text-align: center !important;
    display: block !important;
    margin-left: auto !important;
    margin-right: auto !important;
}

#footer .footer-bottom .col-md-12 .footer-compliance-text a {
    display: inline-block !important;
    text-align: center !important;
}


