/* ====================================
   AL HOMES FOOTER
   v3.0 - Added legal links + static icon badge
   Fixed: newsletter arrow, single-row alignment
   Container: 1200px max-width
   ==================================== */

/* CSS Variables */
:root {
    --footer-bg: #EFEDEB;
    --footer-dark-text: #2A2A2A;
    --footer-light-text: #666666;
    --footer-primary: #5A4F42;
    --footer-border: #CCC8C0;
    --footer-icon: #483F35;
    --footer-white: #FFFFFF;
    --footer-placeholder: #969696;
}

/* ====================================
   FOOTER BASE
   ==================================== */

.site-footer {
    width: 100%;
    background: var(--footer-bg);
    padding: 80px 96px;
    box-sizing: border-box;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 56px;
}

/* ====================================
   FOOTER MAIN - Two Column Layout
   ==================================== */

.footer-main {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    width: 100%;
}

/* ====================================
   FOOTER LEFT COLUMN
   ==================================== */

.footer-left {
    flex: 0 0 384px;
    max-width: 384px;
    display: flex;
    flex-direction: column;
    gap: 28px;
}

/* Logo */
.footer-logo {
    width: 192px;
    height: 40px;
    position: relative;
    overflow: hidden;
}

.footer-logo a {
    display: block;
    height: 100%;
}

.footer-logo img {
    height: 40px;
    width: auto;
    object-fit: contain;
}

/* Office Locations Section */
.footer-offices {
    display: flex;
    flex-direction: column;
    gap: 28px;
}

.office-item {
    width: 384px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.office-name {
    font-family: 'Afacad Flux', sans-serif;
    font-size: 18px;
    font-weight: 400;
    color: var(--footer-dark-text);
    text-transform: capitalize;
}

.office-details {
    font-family: 'Afacad Flux', sans-serif;
    font-size: 18px;
    font-weight: 300;
    color: var(--footer-light-text);
    text-transform: capitalize;
    line-height: 1.5;
}

/* Newsletter Section */
.footer-newsletter {
    width: 384px;
    display: flex;
    flex-direction: column;
    gap: 28px;
    margin-top: 28px;
}

.newsletter-text {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.footer-newsletter h4 {
    font-family: 'Afacad Flux', sans-serif;
    font-size: 20px;
    font-weight: 400;
    color: var(--footer-dark-text);
    margin: 0;
}

.footer-newsletter p {
    font-family: 'Afacad Flux', sans-serif;
    font-size: 18px;
    font-weight: 300;
    color: var(--footer-light-text);
    line-height: 1.5;
    margin: 0;
}

/* Newsletter Form */
.alhomes-newsletter-form {
    width: 100%;
    max-width: 384px;
    height: 48px;
    display: flex;
    align-items: center;
    background: var(--footer-white);
    border: 1px solid var(--footer-border);
    border-radius: 50px;
    padding: 12px 20px;
    gap: 10px;
    box-sizing: border-box;
    overflow: hidden;
}

.alhomes-newsletter-form input[type="email"] {
    flex: 1;
    border: none;
    outline: none;
    background: transparent;
    font-family: 'Afacad Flux', sans-serif;
    font-size: 18px;
    font-weight: 300;
    color: var(--footer-dark-text);
    min-width: 0;
    width: 100%;
    padding: 0;
    margin: 0;
    -webkit-appearance: none;
    appearance: none;
    box-shadow: none;
    border-radius: 0;
}

.alhomes-newsletter-form input[type="email"]::placeholder {
    color: var(--footer-placeholder);
}

/* Kill ALL focus/hover highlights on input */
.alhomes-newsletter-form input[type="email"]:focus,
.alhomes-newsletter-form input[type="email"]:hover,
.alhomes-newsletter-form input[type="email"]:active {
    border: none !important;
    outline: none !important;
    box-shadow: none !important;
    background: transparent !important;
    -webkit-box-shadow: none !important;
}

/* Chrome autofill bg override */
.alhomes-newsletter-form input[type="email"]:-webkit-autofill,
.alhomes-newsletter-form input[type="email"]:-webkit-autofill:hover,
.alhomes-newsletter-form input[type="email"]:-webkit-autofill:focus {
    -webkit-box-shadow: 0 0 0px 1000px var(--footer-white) inset !important;
    -webkit-text-fill-color: var(--footer-dark-text) !important;
    transition: background-color 5000s ease-in-out 0s;
}

/* Form pill hover - subtle outline only */
.alhomes-newsletter-form:focus-within {
    border-color: var(--footer-primary);
}

/* ====================================
   NEWSLETTER SUBMIT BUTTON - Perfect Circle
   IMPORTANT: Scoped ONLY to .alhomes-newsletter-form
   so it does NOT affect .footer-badge-icon or anything else
   ==================================== */
.alhomes-newsletter-form button.alhomes-newsletter-btn {
    display: flex !important;
    width: 28px !important;
    height: 28px !important;
    min-width: 28px !important;
    min-height: 28px !important;
    max-width: 28px !important;
    max-height: 28px !important;
    padding: 0 !important;
    background: var(--footer-primary) !important;
    background-color: var(--footer-primary) !important;
    border: none !important;
    border-radius: 32px !important;
    justify-content: center !important;
    align-items: center !important;
    cursor: pointer !important;
    flex-shrink: 0 !important;
    box-sizing: border-box !important;
    transition: background 0.3s ease, transform 0.3s ease !important;
    position: relative !important;
    overflow: hidden !important;
    color: #FFF !important;
}

.alhomes-newsletter-form button.alhomes-newsletter-btn:hover {
    background: #483F35 !important;
    background-color: #483F35 !important;
    transform: scale(1.05);
}

.alhomes-newsletter-form .alhomes-arrow-icon {
    width: 12px !important;
    height: 12px !important;
    flex-shrink: 0;
}

/* ====================================
   FOOTER RIGHT COLUMN - Navigation
   ==================================== */

.footer-right {
    flex: 0 0 600px;
    max-width: 600px;
    display: flex;
    flex-direction: column;
    gap: 56px;
}

/* ====================================
   FOOTER NAV ROWS - ALIGNMENT FIX v2.2
   ==================================== */

.footer-nav-row {
    display: flex;
    justify-content: flex-start;
    align-items: flex-start;
    width: 100%;
}

.footer-nav-row:first-child {
    gap: 56px;
}

.footer-nav-row:last-child {
    width: 100%;
    gap: 56px;
}

.footer-nav-row > .footer-nav-group:first-child {
    flex: 0 0 120px;
    min-width: 120px;
}

.footer-nav-services {
    flex: 1;
}

/* ====================================
   Navigation Groups
   ==================================== */

.footer-nav-group {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.nav-label {
    font-family: 'Afacad Flux', sans-serif;
    font-size: 16px;
    font-weight: 400;
    color: var(--footer-light-text);
    text-transform: capitalize;
}

.footer-nav-group ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.footer-nav-group a {
    font-family: 'Afacad Flux', sans-serif;
    font-size: 16px;
    font-weight: 400;
    color: var(--footer-dark-text);
    text-decoration: none;
    text-transform: capitalize;
    transition: color 0.2s ease;
}

.footer-nav-group a:hover {
    color: var(--footer-primary);
}

/* Services columns layout */
.services-columns {
    display: flex;
    gap: 56px;
}

.services-columns ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* ====================================
   FOOTER BOTTOM
   ==================================== */

.footer-bottom {
    display: flex;
    flex-direction: column;
    gap: 28px;
}

/* Social Icons */
.footer-social {
    display: flex;
    align-items: center;
    gap: 14px;
}

.footer-social a {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--footer-icon);
    transition: color 0.3s ease, transform 0.3s ease;
    position: relative;
    overflow: hidden;
}

.footer-social a:hover {
    color: var(--footer-primary);
    transform: translateY(-2px);
}

.footer-social svg {
    width: 20px;
    height: 20px;
}

/* ====================================
   LEGAL SECTION
   ==================================== */

.footer-legal {
    display: flex;
    flex-direction: column;
    gap: 28px;
}

.footer-divider {
    width: 100%;
    height: 1px;
    background: var(--footer-border);
}

/* ====================================
   LEGAL CONTENT ROW
   Single horizontal line:
   [©2025 AL Homes]  [Site Map | Legal... | Privacy... | Terms... | Access...]  [icon]
   ==================================== */

.footer-legal-content {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
}

.footer-copyright {
    font-family: 'Afacad Flux', sans-serif;
    font-size: 16px;
    font-weight: 300;
    color: var(--footer-light-text);
    text-align: left;
    flex-shrink: 0;
    white-space: nowrap;
}

/* ====================================
   v3.0 NEW: Legal Links (Center)
   Same color as existing Privacy Policy link
   ==================================== */

.footer-legal-links {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 8px;
    flex: 1;
}

.footer-legal-links a {
    font-family: 'Afacad Flux', sans-serif;
    font-size: 14px;
    font-weight: 300;
    color: var(--footer-light-text);
    text-decoration: none;
    transition: color 0.2s ease;
    white-space: nowrap;
}

.footer-legal-links a:hover {
    color: var(--footer-dark-text);
    text-decoration: underline;
}

.legal-separator {
    font-family: 'Afacad Flux', sans-serif;
    font-size: 14px;
    font-weight: 300;
    color: var(--footer-border);
    user-select: none;
}

/* ====================================
   v3.0 NEW: Icon Badge (Right)
   Plain static image - NO background,
   NO border, NO link, NOT hoverable
   ==================================== */

.footer-badge-icon {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.footer-badge-icon img {
    width: 48px;
    height: 48px;
    object-fit: contain;
    display: block;
}

/* ====================================
   LEGACY: .footer-privacy (backward compat)
   ==================================== */

.footer-privacy {
    font-family: 'Afacad Flux', sans-serif;
    font-size: 16px;
    font-weight: 300;
    color: var(--footer-light-text);
    text-decoration: none;
    text-align: right;
    transition: color 0.2s ease;
}

.footer-privacy:hover {
    color: var(--footer-dark-text);
    text-decoration: underline;
}

/* ====================================
   RESPONSIVE - Large Tablets / Small Desktops
   ==================================== */
@media (max-width: 1300px) {
    .site-footer {
        padding: 80px 60px;
    }
    
    .footer-main {
        gap: 40px;
    }
    
    .footer-left {
        flex: 0 0 350px;
        max-width: 350px;
    }
    
    .footer-newsletter {
        width: 100%;
    }
    
    .office-item {
        width: 100%;
    }
    
    .alhomes-newsletter-form {
        max-width: 350px;
    }
    
    .footer-right {
        flex: 1;
        max-width: 520px;
    }
    
    .footer-nav-services {
        width: auto;
        flex: 1;
    }
    
    .footer-nav-row {
        gap: 40px;
    }
    
    .footer-nav-row:first-child {
        gap: 40px;
    }
    
    .footer-nav-row:last-child {
        gap: 40px;
    }
    
    /* Legal links smaller text */
    .footer-legal-links a {
        font-size: 13px;
    }
    
    .legal-separator {
        font-size: 13px;
    }
}

/* ====================================
   RESPONSIVE - Tablets
   ==================================== */
@media (max-width: 1024px) {
    .site-footer {
        padding: 60px 40px;
    }
    
    .footer-main {
        flex-direction: column;
        gap: 50px;
    }
    
    .footer-left {
        flex: none;
        max-width: 100%;
        width: 100%;
    }
    
    .footer-newsletter {
        width: 100%;
        max-width: 100%;
    }
    
    .alhomes-newsletter-form {
        max-width: 420px;
    }
    
    .office-item {
        width: 100%;
    }
    
    .footer-right {
        flex: none;
        max-width: 100%;
        width: 100%;
        gap: 40px;
    }
    
    .footer-nav-row {
        gap: 40px;
    }
    
    .footer-nav-row:first-child {
        gap: 40px;
    }
    
    .footer-nav-row:last-child {
        width: auto;
        gap: 40px;
    }
    
    /* Legal row: copyright + icon on top line, links below */
    .footer-legal-content {
        flex-wrap: wrap;
    }
    
    .footer-legal-links {
        flex-basis: 100%;
        justify-content: flex-start;
        order: 3;
    }
    
    .footer-copyright {
        order: 1;
    }
    
    .footer-badge-icon {
        order: 2;
        margin-left: auto;
    }
}

/* ====================================
   RESPONSIVE - Mobile Landscape
   ==================================== */
@media (max-width: 768px) {
    .site-footer {
        padding: 50px 20px;
    }
    
    .footer-container {
        gap: 40px;
    }
    
    .footer-left {
        gap: 24px;
    }
    
    .footer-offices {
        gap: 20px;
    }
    
    .office-name {
        font-size: 16px;
    }
    
    .office-details {
        font-size: 16px;
    }
    
    .footer-newsletter {
        width: 100%;
        max-width: 100%;
    }
    
    .footer-newsletter h4 {
        font-size: 18px;
    }
    
    .footer-newsletter p {
        font-size: 16px;
    }
    
    .alhomes-newsletter-form {
        width: 100%;
        max-width: 100%;
        height: 48px;
        padding: 10px 16px;
    }
    
    .alhomes-newsletter-form input[type="email"] {
        font-size: 16px;
    }
    
    .footer-right {
        gap: 30px;
    }
    
    .footer-nav-row {
        flex-wrap: wrap;
        gap: 30px;
    }
    
    .footer-nav-row:first-child {
        flex-direction: row;
        gap: 40px;
    }
    
    .footer-nav-row:last-child {
        flex-direction: row;
        gap: 40px;
    }
    
    .footer-nav-row > .footer-nav-group:first-child {
        flex: 0 0 auto;
        min-width: auto;
    }
    
    .services-columns {
        flex-direction: column;
        gap: 10px;
    }
    
    .footer-nav-services {
        width: auto;
    }
    
    .footer-bottom {
        gap: 20px;
    }
    
    /* Legal: full column stack */
    .footer-legal-content {
        flex-direction: column;
        align-items: flex-start;
        gap: 14px;
    }
    
    .footer-copyright {
        order: unset;
        font-size: 14px;
    }
    
    .footer-legal-links {
        order: unset;
        flex-basis: auto;
        justify-content: flex-start;
        gap: 5px;
    }
    
    .footer-legal-links a {
        font-size: 12px;
    }
    
    .legal-separator {
        font-size: 12px;
    }
    
    .footer-badge-icon {
        order: unset;
        margin-left: 0;
    }
    
    .footer-badge-icon img {
        width: 40px;
        height: 40px;
    }
}

/* ====================================
   RESPONSIVE - Mobile Portrait
   ==================================== */
@media (max-width: 575px) {
    .site-footer {
        padding: 40px 20px;
    }
    
    .footer-logo {
        width: 150px;
        height: 32px;
    }
    
    .footer-logo img {
        height: 32px;
    }
    
    .alhomes-newsletter-form {
        width: 100%;
        max-width: 100%;
        height: 46px;
        padding: 10px 14px;
        gap: 8px;
    }
    
    .alhomes-newsletter-form input[type="email"] {
        font-size: 15px;
    }
    
    .footer-nav-row:first-child {
        flex-direction: column;
        gap: 25px;
    }
    
    .footer-nav-row:last-child {
        flex-direction: row;
        flex-wrap: wrap;
        gap: 30px;
    }
    
    .footer-nav-group {
        width: auto;
    }
    
    .footer-nav-services {
        width: 100%;
    }
    
    .services-columns {
        flex-direction: row;
        gap: 40px;
    }
    
    .footer-legal-content {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .footer-copyright,
    .footer-privacy {
        text-align: left;
    }
    
    .footer-legal-links {
        gap: 4px 6px;
    }
    
    .footer-legal-links a {
        font-size: 11px;
    }
    
    .legal-separator {
        font-size: 11px;
    }
    
    .footer-badge-icon img {
        width: 36px;
        height: 36px;
    }
}

/* ====================================
   RESPONSIVE - Small Mobile (375px)
   ==================================== */
@media (max-width: 375px) {
    .site-footer {
        padding: 30px 16px;
    }
    
    .footer-container {
        gap: 30px;
    }
    
    .alhomes-newsletter-form {
        height: 44px;
        padding: 8px 12px;
        gap: 8px;
    }
    
    .alhomes-newsletter-form input[type="email"] {
        font-size: 14px;
    }
    
    .footer-nav-row:first-child {
        gap: 20px;
    }
    
    .footer-nav-row:last-child {
        gap: 24px;
    }
    
    .services-columns {
        gap: 30px;
    }
    
    .nav-label {
        font-size: 14px;
    }
    
    .footer-nav-group a {
        font-size: 14px;
    }
    
    .footer-copyright,
    .footer-privacy {
        font-size: 14px;
    }
    
    .footer-legal-links a {
        font-size: 10px;
    }
    
    .legal-separator {
        font-size: 10px;
    }
    
    .footer-badge-icon img {
        width: 32px;
        height: 32px;
    }
}