/* ---------------------------------= */
/* Modern Theme - Azulejos JP
/* ---------------------------------= */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Outfit:wght@300;400;600;800&display=swap');

:root {
    --primary: #1F2937;
    --primary-light: #374151;
    --accent: #0187D0; /* Corporate blue color */
    --accent-hover: #016ca8;
    --bg-light: #F9FAFB;
    --bg-white: #FFFFFF;
    --text-main: #374151;
    --text-muted: #6B7280;
    --font-heading: 'Outfit', sans-serif;
    --font-body: 'Inter', sans-serif;
}

/* Base resets for modern components */
.modern-layout {
    font-family: var(--font-body);
    color: var(--text-main);
    background-color: var(--bg-white);
    font-size: 16px; /* Corrige el 12px heredado del Bootstrap legacy en el contenido moderno */
    line-height: 1.6;
    margin: 0;
    padding: 0; /* Garantiza diseño a sangre completa (sin franjas laterales) en cualquier dispositivo */
    overflow-x: hidden; /* Red de seguridad contra desbordamientos horizontales */
}

/* Las imágenes nunca desbordan su contenedor (responsive) */
.modern-layout img {
    max-width: 100%;
    height: auto;
}

html {
    scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    .modern-layout *,
    .modern-layout *::before,
    .modern-layout *::after {
        animation-duration: 0.001ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.001ms !important;
    }
}

.modern-layout h1, .modern-layout h2, .modern-layout h3, .modern-layout h4, .modern-layout h5, .modern-layout h6 {
    font-family: var(--font-heading);
    font-weight: 600;
}

/* ---------------------------------= */
/* Header Redesign
/* ---------------------------------= */
.mh-header-wrapper {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
    padding: 10px 0;
    transition: all 0.3s ease;
}

.mh-header-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px;
}

.mh-logo img {
    height: 50px;
    width: auto;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.mh-logo:hover img {
    transform: scale(1.05);
}

.mh-nav {
    display: flex;
    align-items: center;
    gap: 24px;
    margin: 0;
    list-style: none;
}

.mh-nav-link {
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 14px;
    color: var(--primary);
    text-decoration: none;
    letter-spacing: 0.5px;
    position: relative;
    padding: 8px 0;
    transition: color 0.3s ease;
}

.mh-nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 0;
    background-color: var(--accent);
    transition: width 0.3s ease;
}

.mh-nav-link:hover, .mh-nav-link.active {
    color: var(--accent);
    text-decoration: none;
}

.mh-nav-link:hover::after, .mh-nav-link.active::after {
    width: 100%;
}

.mh-nav-btn {
    box-sizing: border-box;
    background-color: var(--accent) !important;
    color: white !important;
    padding: 10px 24px;
    border-radius: 50px;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 4px 14px rgba(1, 135, 208, 0.3);
}

.mh-nav-btn:hover {
    background-color: var(--accent-hover);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(1, 135, 208, 0.4);
    text-decoration: none;
}

.mh-nav-btn::after {
    display: none;
}

/* ---------------------------------= */
/* Hero Section
/* ---------------------------------= */
.mh-hero {
    position: relative;
    height: 80vh;
    min-height: 600px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.mh-hero-slides {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
}

.mh-hero-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    opacity: 0;
    transform: scale(1.05);
    transition: opacity 1.5s ease-in-out, transform 10s ease-out;
}

.mh-hero-slide.active {
    opacity: 1;
    transform: scale(1.0);
}

.mh-hero-dots {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 12px;
    z-index: 3;
}

.mh-hero-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.4);
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    padding: 0;
}

.mh-hero-dot:hover {
    background: rgba(255, 255, 255, 0.8);
}

.mh-hero-dot.active {
    background: var(--accent);
    transform: scale(1.25);
    box-shadow: 0 0 10px rgba(1, 135, 208, 0.5);
}

.mh-hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(31, 41, 55, 0.8) 0%, rgba(31, 41, 55, 0.4) 100%);
    z-index: 1;
}

.mh-hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    max-width: 800px;
    padding: 0 20px;
    color: white;
    animation: fadeInDown 1s ease-out forwards;
}

.mh-hero-content h1 {
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 20px;
    color: white;
    text-shadow: 0 4px 12px rgba(0,0,0,0.3);
}

.mh-hero-content p {
    font-size: 1.2rem;
    font-weight: 300;
    line-height: 1.6;
    margin-bottom: 30px;
    text-shadow: 0 2px 8px rgba(0,0,0,0.3);
}

@keyframes fadeInDown {
    from { opacity: 0; transform: translateY(-30px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ---------------------------------= */
/* Services Section
/* ---------------------------------= */
.mh-section {
    padding: 50px 20px;
    background-color: var(--bg-light);
}

.mh-section-title {
    text-align: center;
    margin-bottom: 60px;
}

.mh-section-title h2 {
    font-size: 2.5rem;
    color: var(--primary);
    margin-bottom: 15px;
}

.mh-section-title p {
    font-size: 1.1rem;
    color: var(--text-muted);
    max-width: 600px;
    margin: 0 auto;
}

.mh-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr));
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto;
}

.mh-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 10px 25px rgba(0,0,0,0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.mh-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 35px rgba(0,0,0,0.1);
}

.mh-card-img {
    height: 240px;
    background-size: cover;
    background-position: center;
}

.mh-card-content {
    padding: 30px;
}

.mh-card-content h3 {
    font-size: 1.5rem;
    margin-bottom: 15px;
    color: var(--primary);
}

.mh-card-content p {
    color: var(--text-muted);
    margin-bottom: 20px;
    line-height: 1.6;
}

.mh-link-arrow {
    display: inline-flex;
    align-items: center;
    color: var(--accent);
    font-weight: 600;
    text-decoration: none;
    transition: color 0.3s ease;
}

.mh-link-arrow i {
    margin-left: 8px;
    transition: transform 0.3s ease;
}

.mh-link-arrow:hover {
    color: var(--accent-hover);
    text-decoration: none;
}

.mh-link-arrow:hover i {
    transform: translateX(5px);
}

/* ---------------------------------= */
/* Info Section (Why Choose Us)
/* ---------------------------------= */
.mh-info-blocks {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px;
}

.mh-info-item {
    text-align: center;
    padding: 30px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.03);
}

.mh-info-icon {
    width: 60px;
    height: 60px;
    background-color: rgba(1, 135, 208, 0.1);
    color: var(--accent);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    margin: 0 auto 20px;
}

.mh-info-item h4 {
    margin-bottom: 10px;
    font-size: 1.2rem;
}

/* ---------------------------------= */
/* Modern Footer
/* ---------------------------------= */
.mh-footer {
    background-color: var(--primary);
    color: white;
    padding: 60px 20px 20px;
}

.mh-footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto 40px;
}

.mh-footer-col h4 {
    color: white;
    font-size: 1.2rem;
    margin-bottom: 25px;
    position: relative;
    padding-bottom: 10px;
}

.mh-footer-col h4::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 40px;
    height: 2px;
    background-color: var(--accent);
}

.mh-footer-col p {
    color: #9CA3AF;
    line-height: 1.6;
    margin-bottom: 15px;
}

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

.mh-footer-links li {
    margin-bottom: 12px;
}

.mh-footer-links a {
    color: #9CA3AF;
    text-decoration: none;
    transition: color 0.3s ease;
    display: inline-flex;
    align-items: center;
}

.mh-footer-links a i {
    margin-right: 10px;
    color: var(--accent);
}

.mh-footer-links a:hover {
    color: white;
    text-decoration: none;
}

.mh-social {
    display: flex;
    gap: 15px;
    margin-top: 20px;
}

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

.mh-social a:hover {
    background-color: var(--accent);
    transform: translateY(-3px);
}

.mh-footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 20px;
    text-align: center;
    color: #9CA3AF;
    font-size: 0.9rem;
    max-width: 1200px;
    margin: 0 auto;
}

.mh-footer-bottom a {
    color: white;
    text-decoration: none;
}

.mh-mobile-toggle, .mh-mobile-close {
    display: none;
    font-size: 28px;
    color: var(--primary);
    cursor: pointer;
    line-height: 1;
    background: none;
    border: none;
    padding: 6px;
    margin: 0;
    font-family: inherit;
}

/* Responsiveness */
@media (max-width: 991px) {
    .mh-header-container {
        padding: 15px 20px;
    }
    
    .mh-mobile-toggle {
        display: flex;
        align-items: center;
        justify-content: center;
    }
    
    .mh-nav-wrapper {
        position: fixed;
        top: 0;
        right: -100%;
        width: 100%;
        max-width: 320px;
        height: 100vh;
        background-color: var(--bg-white);
        z-index: 10000;
        box-shadow: -10px 0 30px rgba(0,0,0,0.15);
        transition: right 0.4s cubic-bezier(0.16, 1, 0.3, 1);
        padding: 80px 30px 30px;
        overflow-y: auto;
    }
    
    .mh-nav-wrapper.mh-nav-active {
        right: 0;
    }
    
    .mh-mobile-close {
        display: block;
        position: absolute;
        top: 25px;
        right: 25px;
        font-size: 32px;
        color: var(--text-muted);
        transition: color 0.2s ease;
    }
    
    .mh-mobile-close:hover {
        color: var(--primary);
    }
    
    .mh-nav {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }
    
    .mh-nav-link {
        font-size: 1.2rem;
        display: block;
        width: 100%;
        padding: 10px 0;
    }
    
    .mh-nav-btn {
        display: inline-block;
        margin-top: 20px;
        width: 100%;
        text-align: center;
    }
    
    .mh-dropdown-menu {
        position: static;
        box-shadow: none;
        opacity: 1;
        visibility: visible;
        transform: none;
        padding: 10px 0 10px 15px;
        border-left: 2px solid var(--accent);
        margin-top: 10px;
        display: none;
    }
    
    .mh-dropdown:hover .mh-dropdown-menu,
    .mh-dropdown:focus-within .mh-dropdown-menu,
    .mh-dropdown.active .mh-dropdown-menu {
        display: block;
    }
}

@media (max-width: 768px) {
    .mh-hero { height: 70vh; min-height: 460px; }
    .mh-hero-content h1 { font-size: 2.2rem; }
    .mh-hero-content p { font-size: 1.05rem; }
    .mh-info-blocks { grid-template-columns: 1fr; }
    .mh-section { padding: 56px 18px; }
    .mh-section-title { margin-bottom: 40px; }
    .mh-section-title h2 { font-size: 2rem; }
}

@media (max-width: 480px) {
    .mh-hero-content h1 { font-size: 1.8rem; }
    .mh-card-content { padding: 24px; }
}


/* ================================== */
/* LEGACY OVERRIDES PARA SEC_DIN */
/* ================================== */
.contenidos {
    max-width: 1200px;
    margin: 40px auto;
    padding: 20px;
}

.span3 .media, .span4 .media {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    margin-bottom: 20px;
    padding-bottom: 15px;
}

.span3 .media:hover, .span4 .media:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
}

.media-image, .noticia-image, .promo-image {
    min-height: 220px;
    border-radius: 12px 12px 0 0;
    width: 100%;
}

.noticiabox {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    margin-bottom: 20px;
}

.noticiabox:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
}

.noticiabox .picture {
    height: 100%;
}

.noticiabox .noticia-image {
    height: 100%;
    min-height: 180px;
    border-radius: 12px 0 0 12px;
}

.item-description {
    padding: 20px;
}

.item-description h5 a {
    font-family: var(--font-heading);
    font-weight: 600;
    color: var(--primary);
    text-decoration: none;
    font-size: 1.1rem;
}

.item-description h5 a:hover {
    color: var(--accent);
}

.media-heading {
    padding: 15px 10px 0;
    text-align: center;
}

.media-heading a {
    font-family: var(--font-heading);
    font-weight: 600;
    color: var(--primary);
    text-decoration: none;
    font-size: 1.1rem;
}

.media-heading a:hover {
    color: var(--accent);
}

.breadcrumb {
    background: transparent !important;
    padding: 0 !important;
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 600;
    border-bottom: 2px solid var(--accent);
    display: inline-block;
    margin-bottom: 30px;
}

.image-overlay-link, .image-overlay-zoom {
    border-radius: inherit;
}



/* ================================== */
/* CONTACT PAGE MODERN STYLES */
/* ================================== */
.mh-contact-wrapper {
    max-width: 1200px;
    margin: 40px auto;
    padding: 0 20px;
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 40px;
}
@media (max-width: 768px) {
    .mh-contact-wrapper {
        grid-template-columns: 1fr;
    }
}
.mh-contact-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
    padding: 40px;
}
.mh-contact-title {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    color: var(--primary);
    margin-bottom: 25px;
    font-weight: 700;
}
.mh-form-group {
    margin-bottom: 20px;
}
.mh-form-group label {
    display: block;
    margin-bottom: 8px;
    color: var(--text-muted);
    font-weight: 500;
    font-size: 0.95rem;
}
.mh-form-group input[type='text'],
.mh-form-group input[type='email'],
.mh-form-group textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #E5E7EB;
    border-radius: 8px;
    font-family: var(--font-body);
    font-size: 1rem;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
    box-sizing: border-box;
    background-color: #F9FAFB;
}
.mh-form-group input:focus,
.mh-form-group textarea:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(1, 135, 208, 0.2);
    background-color: white;
}

/* ================================== */
/* Dropdown Menus */
/* ================================== */
.mh-dropdown { position: relative; }
.mh-dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    background: white;
    min-width: 220px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    border-radius: 8px;
    padding: 10px 0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s ease;
    z-index: 1000;
}
.mh-dropdown:hover .mh-dropdown-menu,
.mh-dropdown:focus-within .mh-dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}
.mh-dropdown-menu li { list-style: none; margin: 0; padding: 0; }
.mh-dropdown-menu li a {
    display: block;
    padding: 10px 20px;
    color: var(--text-main);
    text-decoration: none;
    font-weight: 500;
    transition: background 0.2s, color 0.2s;
    font-family: var(--font-body);
}
.mh-dropdown-menu li a:hover {
    background: var(--bg-light);
    color: var(--primary);
}

/* ================================== */
/* Cookie Banner Moderno              */
/* ================================== */
.mh-cookie-tab {
    position: fixed;
    bottom: 0;
    left: 20px;
    background-color: #000000;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 12px 12px 0 0;
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    box-shadow: 0 -4px 10px rgba(0,0,0,0.1);
    z-index: 9998;
    transition: transform 0.3s ease, background-color 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    letter-spacing: 0.5px;
}

.mh-cookie-tab:hover {
    background-color: #222222;
    transform: translateY(-2px);
}

.mh-cookie-banner {
    position: fixed;
    bottom: 20px;
    left: 20px;
    width: 480px;
    max-width: calc(100% - 40px);
    background-color: var(--bg-white);
    border-radius: 20px;
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.12), 0 10px 25px rgba(0, 0, 0, 0.08);
    z-index: 9999;
    font-family: var(--font-body);
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.4s ease, transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.mh-cookie-banner.mh-hidden {
    opacity: 0;
    transform: translateY(120%);
    pointer-events: none;
}

.mh-cookie-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 30px 30px 15px;
}

.mh-cookie-title {
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 1.4rem;
    color: var(--primary);
    margin: 0;
    line-height: 1.2;
}

.mh-cookie-close {
    background: none;
    border: none;
    font-size: 26px;
    color: var(--text-muted);
    cursor: pointer;
    padding: 0;
    line-height: 1;
    margin-top: -4px;
    transition: color 0.2s ease;
}

.mh-cookie-close:hover {
    color: var(--primary);
}

.mh-cookie-body {
    padding: 0 30px 30px;
}

.mh-cookie-text {
    font-size: 0.95rem;
    color: var(--text-muted);
    line-height: 1.6;
    margin-bottom: 25px;
}

.mh-cookie-options {
    background-color: var(--bg-light);
    border-radius: 8px;
    padding: 16px;
    margin-bottom: 20px;
}

.mh-cookie-option {
    margin-bottom: 12px;
}

.mh-cookie-option:last-child {
    margin-bottom: 0;
}

.mh-toggle-label {
    display: flex;
    align-items: center;
    cursor: pointer;
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--primary);
}

.mh-toggle-input {
    display: none;
}

.mh-toggle-switch {
    position: relative;
    width: 40px;
    height: 22px;
    background-color: #D1D5DB;
    border-radius: 22px;
    margin-right: 12px;
    transition: background-color 0.3s ease;
}

.mh-toggle-switch::after {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    width: 18px;
    height: 18px;
    background-color: white;
    border-radius: 50%;
    transition: transform 0.3s cubic-bezier(0.4, 0.0, 0.2, 1);
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.mh-toggle-input:checked + .mh-toggle-switch {
    background-color: var(--primary);
}

.mh-toggle-input:checked + .mh-toggle-switch::after {
    transform: translateX(18px);
}

.mh-toggle-input:disabled + .mh-toggle-switch {
    opacity: 0.6;
    cursor: not-allowed;
}

.mh-cookie-actions {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
    margin-top: 10px;
    margin-bottom: 24px;
}

.mh-cookie-actions-main {
    display: flex;
    flex-direction: row;
    width: 100%;
    gap: 12px;
}

.mh-cookie-actions-main button {
    flex: 1;
}

.mh-btn-secondary#btn-configurar {
    width: 100%;
}

.mh-btn-primary, .mh-btn-secondary {
    font-family: var(--font-heading);
    font-size: 0.85rem;
    font-weight: 600;
    padding: 12px 18px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    letter-spacing: 0.5px;
}

.mh-btn-primary {
    background-color: #000000;
    color: #FFFFFF;
    border: 1px solid #000000;
}

.mh-btn-primary:hover {
    background-color: #222222;
    transform: translateY(-1px);
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
}

.mh-btn-secondary {
    background-color: transparent;
    color: var(--primary);
    border: 1px solid #D1D5DB;
}

.mh-btn-secondary:hover {
    background-color: var(--bg-light);
    border-color: #9CA3AF;
}

.mh-cookie-links {
    text-align: center;
    font-size: 0.8rem;
    color: var(--text-muted);
}

.mh-cookie-links a {
    color: var(--text-muted);
    text-decoration: none;
    transition: color 0.2s ease;
}

.mh-cookie-links a:hover {
    color: var(--primary);
    text-decoration: underline;
}

@media (max-width: 500px) {
    .mh-cookie-banner {
        width: 100%;
        max-width: 100%;
        left: 0;
        bottom: 0;
        border-radius: 20px 20px 0 0;
        box-shadow: 0 -10px 40px rgba(0,0,0,0.1);
    }

}


/* ================================== */
/* ACCESIBILIDAD (a11y)               */
/* ================================== */

/* Enlace de salto al contenido (visible solo al recibir foco con teclado) */
.mh-skip-link {
    position: absolute;
    left: 12px;
    top: -60px;
    z-index: 100000;
    background: var(--accent);
    color: #fff;
    padding: 12px 20px;
    border-radius: 0 0 8px 8px;
    font-family: var(--font-heading);
    font-weight: 600;
    text-decoration: none;
    transition: top 0.2s ease;
}

.mh-skip-link:focus {
    top: 0;
    color: #fff;
    text-decoration: none;
    outline: 3px solid var(--primary);
    outline-offset: 2px;
}

/* El destino del salto no debe mostrar contorno al recibir foco programático */
#wrapper:focus,
#wrapper:focus-visible,
#contenido-principal:focus,
#contenido-principal:focus-visible {
    outline: none;
}

/* Foco visible y coherente para navegación por teclado */
.modern-layout a:focus-visible,
.modern-layout button:focus-visible,
.modern-layout input:focus-visible,
.modern-layout textarea:focus-visible,
.modern-layout select:focus-visible,
.modern-layout [tabindex]:focus-visible {
    outline: 3px solid var(--accent);
    outline-offset: 2px;
    border-radius: 3px;
}

/* Sobre fondos oscuros (header sticky, footer, hero, banners) el foco azul
   puede tener poco contraste: usamos blanco con halo oscuro */
.mh-header-wrapper a:focus-visible,
.mh-header-wrapper button:focus-visible,
.mh-footer a:focus-visible,
.mh-hero-content a:focus-visible {
    outline: 3px solid #fff;
    outline-offset: 3px;
    box-shadow: 0 0 0 6px rgba(0, 0, 0, 0.45);
}

/* Asegura que la cabecera fija no tape el destino del salto al contenido */
#contenido-principal { scroll-margin-top: 100px; }


/* ================================== */
/* ARMONÍA TÍTULOS LEGACY (sec_din)   */
/* ================================== */
.modern-layout .contenidos .titulo {
    font-family: var(--font-heading);
    color: var(--primary);
    line-height: 1.25;
}

/* Migas de pan: que el contador de productos respire en móvil */
@media (max-width: 575px) {
    .breadcrumb {
        font-size: 1.2rem;
    }
}


/* ================================== */
/* AJUSTES (jun 2026)                 */
/* ================================== */

/* Hero en móvil: evita que el texto/botón se corten.
   El hero deja de tener altura fija y crece con el contenido. */
@media (max-width: 768px) {
    .mh-hero { height: auto; min-height: 80vh; }
    .mh-hero-content { padding: 80px 22px 100px; }
    .mh-hero-content h1 { font-size: 2rem; }
    .mh-hero-content p { font-size: 1rem; }
    .mh-hero-dots { bottom: 16px; }
}

@media (max-width: 400px) {
    .mh-hero-content h1 { font-size: 1.7rem; }
}


