/* =============================================
   FOOTER SITEWIDE — fmsw-* namespace
   Farray Motor — versión 1.0
   Usado en: home, landing-ocasion, landing-financiacion, landing-cita-taller
============================================= */

:root {
    --fmsw-red:   #B81F18;
    --fmsw-dark:  #0f1923;
    --fmsw-grey:  #f8f9fa;
    --fmsw-blue:  #1f4f72;
    --fmsw-moto:  #0f6b57;
    --fmsw-font:  'Inter', 'Helvetica Neue', Arial, sans-serif;
}

/* ── ENVIOS + TEAM SECTION ── */
.fmsw-envios-section {
    background: transparent;
    padding: 0;
}

.fmsw-envios-inner {
    max-width: none;
    margin: 0;
}

.fmsw-envios-img {
    width: 100%;
    display: block;
    border-radius: 0;
    box-shadow: none;
}

.fmsw-envios-mobile {
    display: none;
}

.fmsw-envios-mobile-img {
    width: 100%;
    height: auto;
    display: block;
}

.fmsw-team-section {
    padding: 32px 5% 90px;
    background: linear-gradient(180deg, #f8f9fa 0%, #ffffff 100%);
}

.fmsw-team-section .fmsw-section-header {
    max-width: 980px;
    margin: 0 auto 42px;
    text-align: center;
}

.fmsw-team-label {
    display: inline-block;
    margin-bottom: 16px;
    padding: 8px 16px;
    border-radius: 999px;
    background: rgba(184, 31, 24, 0.08);
    color: var(--fmsw-red);
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.fmsw-team-title {
    font-size: 2.4rem;
    line-height: 1.15;
    letter-spacing: -0.03em;
    color: var(--fmsw-dark);
    margin: 0 0 16px;
}

.fmsw-team-subtitle {
    max-width: 860px;
    margin: 0 auto;
    font-size: 1.05rem;
    line-height: 1.75;
    color: #5f6c77;
}

.fmsw-team-grid {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 28px;
}

.fmsw-team-card {
    position: relative;
    display: grid;
    grid-template-columns: 180px 1fr;
    gap: 24px;
    padding: 26px;
    border-radius: 24px;
    background: #ffffff;
    border: 1px solid rgba(15, 25, 35, 0.08);
    box-shadow: 0 18px 45px rgba(15, 25, 35, 0.08);
    overflow: hidden;
}

.fmsw-team-card::before {
    content: '';
    position: absolute;
    inset: 0 auto 0 0;
    width: 6px;
    background: var(--fmsw-red);
}

.fmsw-team-card--coches::before {
    background: linear-gradient(180deg, var(--fmsw-red) 0%, #da4b44 100%);
}

.fmsw-team-card--motos::before {
    background: linear-gradient(180deg, var(--fmsw-moto) 0%, #19a37c 100%);
}

.fmsw-team-card-top {
    grid-column: 1 / -1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.fmsw-team-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 34px;
    padding: 8px 14px;
    border-radius: 999px;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.fmsw-team-card--coches .fmsw-team-badge {
    background: rgba(184, 31, 24, 0.1);
    color: var(--fmsw-red);
}

.fmsw-team-card--motos .fmsw-team-badge {
    background: rgba(15, 107, 87, 0.1);
    color: var(--fmsw-moto);
}

.fmsw-team-stars {
    color: #f4b400;
    letter-spacing: 0.2em;
    font-size: 0.95rem;
    white-space: nowrap;
}

.fmsw-team-media {
    position: relative;
    grid-column: 1;
    grid-row: 2;
    border-radius: 18px;
    overflow: hidden;
    background: #eef2f6;
    min-height: 210px;
}

.fmsw-team-media img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
    object-position: center top;
}

.fmsw-team-body {
    grid-column: 2;
    grid-row: 2 / span 2;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.fmsw-team-person {
    grid-column: 1;
    grid-row: 3;
    text-align: center;
    padding: 6px 6px 0;
}

.fmsw-team-name {
    margin: 0 0 4px;
    color: var(--fmsw-dark);
    font-size: 1.35rem;
    font-weight: 800;
    letter-spacing: -0.02em;
}

.fmsw-team-role {
    margin-bottom: 16px;
    color: #7a8792;
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.fmsw-team-quote {
    position: relative;
    margin-top: 2px;
    margin-bottom: 14px;
    padding: 18px 18px 16px;
    border-radius: 18px;
    background: #f4f7fa;
    border: 1px solid rgba(15, 25, 35, 0.08);
}

.fmsw-team-quote::before {
    content: '';
    position: absolute;
    left: 22px;
    bottom: -10px;
    width: 18px;
    height: 18px;
    background: #f4f7fa;
    border-right: 1px solid rgba(15, 25, 35, 0.08);
    border-bottom: 1px solid rgba(15, 25, 35, 0.08);
    transform: rotate(45deg);
}

.fmsw-team-client {
    margin-top: 0;
    padding-left: 8px;
    color: var(--fmsw-dark);
    font-size: 0.9rem;
    font-weight: 700;
}

.fmsw-team-text {
    margin: 0;
    color: #42515d;
    font-size: 0.98rem;
    line-height: 1.75;
}

.fmsw-team-summary {
    max-width: 1080px;
    margin: 34px auto 0;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
}

.fmsw-team-summary-item {
    padding: 18px 20px;
    border-radius: 18px;
    background: #fff;
    border: 1px solid rgba(15, 25, 35, 0.07);
    text-align: center;
    box-shadow: 0 10px 30px rgba(15, 25, 35, 0.05);
}

.fmsw-team-summary-item strong {
    display: block;
    margin-bottom: 6px;
    color: var(--fmsw-dark);
    font-size: 1.25rem;
}

.fmsw-team-summary-item span {
    color: #6a7883;
    font-size: 0.92rem;
}

/* ── WHY SECTION ── */
.fmsw-why-section {
    padding: 120px 5%;
    background: linear-gradient(180deg, #f8f9fa 0%, #ffffff 100%);
    position: relative;
}

.fmsw-why-container {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: center;
}

.fmsw-why-content {
    padding-right: 40px;
}

.fmsw-why-label {
    display: inline-block;
    background: var(--fmsw-red);
    color: #EFF2F7;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 20px;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.fmsw-why-title {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--fmsw-dark);
    margin-bottom: 24px;
    letter-spacing: -0.03em;
    line-height: 1.15;
}

.fmsw-why-desc {
    font-size: 1.1rem;
    color: #6c757d;
    line-height: 1.7;
    margin-bottom: 36px;
}

.fmsw-why-features {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.fmsw-why-feature {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--fmsw-dark);
    font-weight: 500;
}

.fmsw-why-feature svg {
    width: 24px;
    height: 24px;
    color: var(--fmsw-red);
    flex-shrink: 0;
}

.fmsw-why-image {
    position: relative;
}

.fmsw-why-image-main {
    width: 100%;
    border-radius: 20px;
    box-shadow: 0 30px 80px rgba(0,0,0,0.15);
}

.fmsw-why-image-accent {
    position: absolute;
    bottom: -30px;
    right: -30px;
    width: 200px;
    height: 200px;
    background: var(--fmsw-red);
    border-radius: 20px;
    z-index: -1;
}

/* ── SERVICE SECTION ── */
.fmsw-service-section {
    padding: 100px 5%;
    background: var(--fmsw-dark);
    position: relative;
}

.fmsw-service-section .fmsw-section-header {
    text-align: center;
    margin-bottom: 60px;
}

.fmsw-service-title-main {
    color: white;
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 16px;
    letter-spacing: -0.03em;
}

.fmsw-service-subtitle {
    color: rgba(255,255,255,0.6);
    font-size: 1.15rem;
    max-width: 500px;
    margin: 0 auto;
}

.fmsw-service-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto;
}

.fmsw-service-card {
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 20px;
    padding: 40px;
    text-align: center;
    transition: all 0.4s ease;
}

.fmsw-service-card:hover {
    background: rgba(255,255,255,0.08);
    transform: translateY(-5px);
}

.fmsw-service-icon {
    width: 70px;
    height: 70px;
    margin: 0 auto 24px;
    background: var(--fmsw-red);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.fmsw-service-icon svg {
    width: 32px;
    height: 32px;
    color: #EFF2F7;
}

.fmsw-service-card-title {
    color: white;
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 12px;
    letter-spacing: -0.02em;
}

.fmsw-service-card-desc {
    color: rgba(255,255,255,0.6);
    font-size: 0.95rem;
    line-height: 1.6;
}

/* ── CONTACT SECTION ── */
.fmsw-contact-section {
    background: #f8f9fa;
    overflow: hidden;
}

.fmsw-contact-inner {
    display: grid;
    grid-template-columns: 1fr 1fr;
    min-height: 520px;
}

.fmsw-contact-left {
    padding: 80px 5% 80px 5%;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.fmsw-section-header--left {
    text-align: left;
    margin-bottom: 40px;
}

.fmsw-section-header--left .fmsw-contact-subtitle {
    margin: 0;
    max-width: 100%;
}

.fmsw-contact-title-main {
    color: var(--fmsw-dark);
    font-size: 2.2rem;
    font-weight: 800;
    margin-bottom: 12px;
    letter-spacing: -0.03em;
}

.fmsw-contact-subtitle {
    color: #4c5b66;
    font-size: 1.05rem;
    max-width: 500px;
    margin: 0 auto;
}

.fmsw-contact-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin-bottom: 32px;
}

.fmsw-contact-card {
    background: white;
    border-radius: 12px;
    padding: 24px 16px;
    text-align: center;
    border: 1px solid rgba(0,0,0,0.06);
    transition: all 0.3s ease;
}

.fmsw-contact-card:hover {
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
}

.fmsw-contact-icon {
    width: 48px;
    height: 48px;
    margin: 0 auto 14px;
    background: linear-gradient(135deg, var(--fmsw-red) 0%, #8b1510 100%);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.fmsw-contact-icon svg {
    width: 22px;
    height: 22px;
    color: white;
}

.fmsw-contact-card-title {
    font-size: 1rem;
    font-weight: 700;
    color: var(--fmsw-dark);
    margin-bottom: 8px;
}

.fmsw-contact-info {
    color: #6c757d;
    font-size: 0.88rem;
    line-height: 1.6;
}

.fmsw-contact-info a {
    color: var(--fmsw-red);
    text-decoration: none;
    font-weight: 500;
}

.fmsw-contact-info a:hover {
    text-decoration: underline;
}

.fmsw-contact-cta {
    grid-column: 2;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: var(--fmsw-red);
    color: white;
    text-decoration: none;
    font-weight: 700;
    font-size: 0.88rem;
    letter-spacing: 0.07em;
    text-transform: uppercase;
    padding: 14px 24px;
    border-radius: 8px;
    transition: background 0.3s ease, transform 0.2s ease;
    align-self: start;
    margin-top: 4px;
}

.fmsw-contact-cta svg {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
}

.fmsw-contact-cta:hover {
    background: #8b1510;
    transform: translateY(-2px);
    color: white;
    text-decoration: none;
}

.fmsw-contact-map {
    position: relative;
    min-height: 520px;
    border-radius: 24px;
    overflow: hidden;
    background: linear-gradient(180deg, #edf3f7 0%, #dfe8ef 100%);
}

.fmsw-contact-map iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
    display: block;
}

.fmsw-contact-map-placeholder {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    gap: 14px;
    padding: 36px;
    background:
        radial-gradient(circle at top right, rgba(31, 79, 114, 0.14), transparent 34%),
        linear-gradient(135deg, rgba(255,255,255,0.94), rgba(236,243,248,0.96));
}

.fmsw-contact-map-kicker {
    display: inline-flex;
    align-items: center;
    padding: 8px 14px;
    border-radius: 999px;
    background: rgba(31, 79, 114, 0.08);
    color: var(--fmsw-blue);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.fmsw-contact-map-title {
    margin: 0;
    color: var(--fmsw-dark);
    font-size: 2rem;
    line-height: 1.1;
}

.fmsw-contact-map-text {
    max-width: 520px;
    margin: 0;
    color: #4b5a67;
    font-size: 1rem;
    line-height: 1.7;
}

.fmsw-contact-map-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.fmsw-contact-map-load,
.fmsw-contact-map-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    padding: 0 18px;
    border-radius: 999px;
    font-weight: 700;
    text-decoration: none;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.fmsw-contact-map-load {
    border: 0;
    cursor: pointer;
    background: var(--fmsw-blue);
    color: #fff;
    box-shadow: 0 14px 28px rgba(31, 79, 114, 0.22);
}

.fmsw-contact-map-link {
    background: rgba(255,255,255,0.88);
    color: var(--fmsw-dark);
    border: 1px solid rgba(15, 25, 35, 0.08);
}

.fmsw-contact-map-load:hover,
.fmsw-contact-map-link:hover {
    transform: translateY(-2px);
}

/* ── FOOTER ── */
.fmsw-footer {
    background: var(--fmsw-dark);
    padding: 80px 5% 40px;
    color: rgba(255,255,255,0.7);
    font-family: var(--fmsw-font);
}

.fmsw-footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 60px;
    max-width: 1400px;
    margin: 0 auto 60px;
}

.fmsw-footer-brand {
    padding-right: 40px;
}

.fmsw-footer-logo {
    font-size: 1.8rem;
    font-weight: 800;
    color: white;
    margin-bottom: 20px;
    letter-spacing: -0.02em;
}

.fmsw-footer-tagline {
    font-size: 1rem;
    line-height: 1.7;
    margin-bottom: 24px;
}

.fmsw-footer-social {
    display: flex;
    gap: 12px;
}

.fmsw-footer-social a {
    width: 44px;
    height: 44px;
    background: rgba(255,255,255,0.1);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    transition: all 0.3s ease;
}

.fmsw-footer-social a:hover {
    background: var(--fmsw-red);
    transform: translateY(-3px);
}

.fmsw-footer-social svg {
    width: 20px;
    height: 20px;
}

.fmsw-footer-col-title {
    color: white;
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 24px;
    letter-spacing: -0.02em;
}

.fmsw-footer-links {
    list-style: none;
    padding: 0;
    margin: 0;
}

.fmsw-footer-links li {
    margin-bottom: 14px;
}

.fmsw-footer-links a {
    color: rgba(255,255,255,0.6);
    text-decoration: none;
    font-size: 0.95rem;
    transition: color 0.3s ease;
}

.fmsw-footer-links a:hover {
    color: white;
}

.fmsw-footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1400px;
    margin: 0 auto;
    font-size: 0.9rem;
}

.fmsw-footer-legal {
    display: flex;
    gap: 24px;
}

.fmsw-footer-legal a {
    color: rgba(255,255,255,0.5);
    text-decoration: none;
    transition: color 0.3s ease;
}

.fmsw-footer-legal a:hover {
    color: white;
}

/* ── RESPONSIVE ── */
@media (max-width: 992px) {
    .fmsw-team-grid {
        grid-template-columns: 1fr;
    }
    .fmsw-team-summary {
        grid-template-columns: 1fr;
    }
    .fmsw-why-container {
        grid-template-columns: 1fr;
        gap: 50px;
    }
    .fmsw-why-content {
        padding-right: 0;
    }
    .fmsw-service-grid {
        grid-template-columns: 1fr;
    }
    .fmsw-contact-inner {
        grid-template-columns: 1fr;
    }
    .fmsw-contact-map {
        min-height: 380px;
    }
    .fmsw-contact-map iframe {
        position: static;
        width: 100%;
        height: 380px;
    }
    .fmsw-footer-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 768px) {
    .fmsw-envios-img {
        display: none;
    }

    .fmsw-envios-mobile {
        display: flex;
        flex-direction: column;
        width: 100%;
        background: radial-gradient(circle at 50% 42%, #f3fafc 0%, #e8f4f7 42%, #dcecef 100%);
        gap: 0;
        margin: 0;
        padding: 0;
        line-height: 0;
        overflow: hidden;
    }

    .fmsw-envios-mobile-img {
        margin: 0;
        padding: 0;
        border: 0;
        flex: 0 0 auto;
    }

    .fmsw-envios-mobile-img ~ .fmsw-envios-mobile-img {
        margin-top: -260px;
    }

    .fmsw-team-section {
        padding: 24px 5% 44px;
    }
    .fmsw-team-title {
        font-size: 1.9rem;
    }
    .fmsw-team-card {
        grid-template-columns: 1fr;
        padding: 20px;
    }
    .fmsw-team-media,
    .fmsw-team-person,
    .fmsw-team-body {
        grid-column: auto;
        grid-row: auto;
    }
    .fmsw-team-media {
        min-height: 180px;
        max-height: 220px;
    }
    .fmsw-team-media img {
        object-fit: contain;
        object-position: center top;
    }
    .fmsw-team-card-top {
        flex-direction: column;
        align-items: flex-start;
    }
    .fmsw-team-summary {
        margin: 20px auto 0;
        gap: 12px;
    }
    .fmsw-team-summary-item {
        padding: 14px 16px;
        border-radius: 14px;
    }
    .fmsw-team-summary-item strong {
        font-size: 1.05rem;
        margin-bottom: 4px;
    }
    .fmsw-team-summary-item span {
        font-size: 0.84rem;
        line-height: 1.45;
    }
    .fmsw-why-section { padding: 60px 5%; }
    .fmsw-why-title { font-size: 2rem; }
    .fmsw-service-title-main { font-size: 2rem; }
    .fmsw-contact-title-main { font-size: 1.8rem; }
    .fmsw-contact-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    .fmsw-contact-left {
        padding: 60px 5%;
    }
    .fmsw-footer-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    .fmsw-footer-bottom {
        flex-direction: column;
        gap: 16px;
        text-align: center;
    }
}

@media (max-width: 370px) {
    .fmsw-envios-mobile-img ~ .fmsw-envios-mobile-img {
        margin-top: -214px;
    }
}

@media (max-width: 330px) {
    .fmsw-envios-mobile-img ~ .fmsw-envios-mobile-img {
        margin-top: -172px;
    }
}

/* ── MOBILE: Contact CTA/hours layout for ≤480px ── */
@media (max-width: 480px) {
    /* Contact grid: full-width stacked cards */
    .fmsw-contact-grid {
        grid-template-columns: 1fr;
        gap: 14px;
    }
    .fmsw-contact-card {
        padding: 20px 14px;
    }
    /* CTA button spans full width, clear of grid-column:2 */
    .fmsw-contact-cta {
        grid-column: auto;
        width: 100%;
        justify-content: center;
        padding: 16px 20px;
        font-size: 0.92rem;
        margin-top: 6px;
    }
    /* Hours info: tighten line-height for readability */
    .fmsw-contact-info {
        font-size: 0.84rem;
        line-height: 1.55;
        word-break: break-word;
        overflow-wrap: anywhere;
    }
    /* Contact section tighter padding */
    .fmsw-contact-section { padding: 40px 5%; }
    .fmsw-contact-left { padding: 40px 5%; }
    .fmsw-contact-map { min-height: 280px; }
    .fmsw-contact-map iframe { height: 280px; }
    .fmsw-contact-title-main { font-size: 1.5rem; }
    .fmsw-contact-inner {
        grid-template-columns: 1fr;
        min-height: auto;
    }
    .fmsw-contact-card-title {
        font-size: 0.95rem;
    }
    /* Footer tighter padding */
    .fmsw-footer { padding: 40px 5% 24px; }
    .fmsw-footer-brand { padding-right: 0; }
    .fmsw-footer-logo { font-size: 1.5rem; }
}

@media (max-width: 480px) {
    .fmsw-team-subtitle {
        font-size: 0.98rem;
    }
    .fmsw-team-media {
        min-height: 160px;
        max-height: 190px;
    }
    .fmsw-team-card {
        padding: 18px;
        gap: 16px;
    }
    .fmsw-team-name {
        font-size: 1.18rem;
    }
    .fmsw-team-text {
        font-size: 0.93rem;
        line-height: 1.65;
    }
    .fmsw-why-features {
        grid-template-columns: 1fr;
    }
    .fmsw-service-section { padding: 60px 5%; }
    .fmsw-contact-section { padding: 60px 5%; }
    .fmsw-footer { padding: 60px 5% 30px; }
}
