/* CSS Variables for Theme System */
:root {
    /* Light Mode (Default) */
    --color-background: #FFFFFF;
    --color-text: #404040;
    --color-text-dark: #000000;
    --color-primary: #224477;
    --color-accent: #77BBEE;
    --color-accent-hover: #99CCEE;
    --color-border: #D3D3D3;
    --color-shadow: rgba(0, 0, 0, 0.05);
    --color-banner-bg: linear-gradient(135deg, #BBDDFF 0%, #99CCEE 100%);
    --color-footer-bg: #ACACAC;
    --color-header-bg: #FFFFFF;
    --color-card-bg: #FFFFFF;
    --color-input-bg: #FFFFFF;
    --color-button-bg: #224477;
    --color-button-text: #FFFFFF;
    --color-button-hover: #77BBEE;

    /* Smooth transitions for theme changes */
    transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}

/* Dark Mode Theme */
html[data-theme="dark"] {
    --color-background: #1a1a1a;
    --color-text: #e0e0e0;
    --color-text-dark: #ffffff;
    --color-primary: #77BBEE;
    --color-accent: #99CCEE;
    --color-accent-hover: #BBDDFF;
    --color-border: #404040;
    --color-shadow: rgba(255, 255, 255, 0.1);
    --color-banner-bg: linear-gradient(135deg, #2a2a2a 0%, #404040 100%);
    --color-footer-bg: #2a2a2a;
    --color-header-bg: #1a1a1a;
    --color-card-bg: #2a2a2a;
    --color-input-bg: #2a2a2a;
    --color-button-bg: #77BBEE;
    --color-button-text: #1a1a1a;
    --color-button-hover: #99CCEE;
}




/* Logo Filters for Theme Adaptation */
html[data-theme="dark"] .logo {
    filter: invert(100%) hue-rotate(180deg);
}

/* Hide logo on very thin screens to free up nav space */
@media (max-width: 480px) {
    .logo-container {
        display: none;
    }
}



/* Ensure standard images are not affected by theme filters */
img:not(.logo) {
    filter: none !important;
}

/* Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Open Sans', sans-serif;
    transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}

body {
    background: var(--color-background);
    color: var(--color-text);
    line-height: 1.6;
    font-size: 18px;
    display: flex;
    flex-direction: column;
    align-items: center;
    min-height: 100vh;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: var(--color-text);
}

strong {
    font-weight: 500;
}

/* Typography */
h1 {
    margin: 20px auto;
    font-size: 28px;
    color: var(--color-primary);
    text-align: center;
    width: 100%;
    max-width: 960px;
}

/* Header & Navigation */
header {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px 32px;
    background: var(--color-header-bg);
    box-shadow: 0 2px 5px var(--color-shadow);
    position: sticky;
    top: 0;
    z-index: 100;
    width: 100%;
}

.header-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    max-width: 1200px;
    position: relative;
}

.logo-container {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-shrink: 0;
}

.logo {
    width: 80px;
    height: 80px;
    cursor: pointer;
}

.logo-text {
    font-size: 38px;
    color: var(--color-primary);
    font-weight: 700;
    white-space: nowrap;
}

nav {
    position: relative;
    flex-shrink: 1;
    overflow-x: auto;
    overflow-y: hidden;
    width: 100%;
    padding: 0 40px;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    touch-action: pan-x;
}

nav::-webkit-scrollbar {
    display: none;
}

nav ul {
    list-style: none;
    display: inline-flex;
    gap: 20px;
    font-size: 20px;
    margin: 0 0 0 20px;
    white-space: nowrap;
    flex-shrink: 0;
    width: max-content;
    padding-right: 20px;
}

nav ul li {
    cursor: pointer;
    position: relative;
}

nav ul li:not(:last-child)::after {
    content: "|";
    color: var(--color-border);
    margin-left: 20px;
}

nav ul li a {
    color: var(--color-accent);
}

nav ul li a:hover {
    color: var(--color-primary);
}

nav ul li.active a {
    color: var(--color-text-dark);
}

.nav-controls {
    position: absolute;
    top: 0;
    right: 40px;
    height: 100%;
    display: flex;
    align-items: center;
    z-index: 11;
}

.nav-arrow {
    font-size: 24px;
    color: var(--color-primary);
    cursor: pointer;
    padding: 6px;
    user-select: none;
    z-index: 12;
}

.nav-controls::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 100px;
    height: 100%;
    background: linear-gradient(to left, var(--color-header-bg), transparent);
    pointer-events: none;
    z-index: 10;
}

.nav-controls::before {
    content: '';
    position: absolute;
    top: 0;
    left: 80px;
    width: calc(100vw - 40px);
    height: 100%;
    background: var(--color-header-bg);
    pointer-events: none;
    z-index: 10;
}

/* Main Content */
main {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    flex-grow: 1;
}

/* Banner Styles */
.banner {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 32px 40px;
    background: var(--color-banner-bg);
    border-radius: 8px;
    margin: 20px auto;
    box-shadow: 0 5px 15px var(--color-shadow);
    width: 100%;
    max-width: 960px;
}

.join-team-button {
    display: inline-block;
    background: var(--color-button-bg);
    color: var(--color-button-text);
    padding: 12px 24px;
    border-radius: 4px;
    font-size: 18px;
    font-weight: 600;
    text-decoration: none;
    transition: background-color 0.3s ease;
}

.join-team-button:hover {
    background: var(--color-button-hover);
    color: var(--color-button-text);
}

.banner p {
    font-size: 22px;
    max-width: 880px;
    color: var(--color-text);
    text-align: center;
    margin-bottom: 20px;
}

.banner p a {
    color: var(--color-primary);
    font-weight: 500;
}

.banner p a:hover {
    color: var(--color-text-dark);
}

.banner p a.bold {
    color: var(--color-text-dark);
    font-weight: 500;
}

.banner p:not(.bold) a {
    color: var(--color-primary);
}

.banner p.note {
    font-size: 18px;
    color: var(--color-text);
    font-style: italic;
}

.banner .small-italic {
    font-size: 18px;
    font-style: italic;
}

.banner .small-italic a {
    color: var(--color-primary);
}

.banner .small-italic a:hover {
    color: var(--color-text-dark);
}

/* Special banner styles for citas page */
.citas-page .banner {
    border: 12px solid transparent;
    background: linear-gradient(var(--color-background), var(--color-background)) padding-box, var(--color-banner-bg) border-box;
}

/* Gallery Styles */
.gallery {
    margin: 20px auto;
    overflow-x: auto;
    white-space: nowrap;
    width: 100%;
    max-width: 1536px;
}

.gallery-container {
    display: inline-flex;
    gap: 12px;
}

.gallery img {
    width: 300px;
    height: 300px;
    object-fit: cover;
    border-radius: 8px;
    cursor: pointer;
}

/* Contact Styles */
.contact {
    font-size: 20px;
    margin: 20px auto;
    width: 100%;
    max-width: 960px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.phone-numbers {
    display: flex;
    gap: 20px;
    align-items: center;
    margin-bottom: 12px;
    flex-wrap: nowrap;
}

.phone-numbers strong {
    font-weight: 500;
}

.phone-numbers span {
    display: inline-flex;
    gap: 5px;
    white-space: nowrap;
}

.phone-numbers a {
    color: var(--color-primary);
}

.social-links {
    display: flex;
    gap: 20px;
    align-items: center;
    margin-bottom: 12px;
}

.social-links a {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--color-text);
}

.social-links a:hover {
    color: var(--color-text-dark);
}

.social-links img {
    width: 24px;
    height: 24px;
    filter: grayscale(100%);
}

.social-links a:hover img.facebook,
.social-links a:hover img.instagram,
.social-links a:hover img.whatsapp {
    filter: none;
}

/* Contacto page specific styles */
.contacto-page .contact {
    font-size: 22px;
}

.contacto-page .phone-numbers {
    gap: 24px;
    margin-bottom: 14px;
}

.contacto-page .social-links {
    gap: 24px;
    margin-bottom: 14px;
}

.contacto-page .phone-numbers span {
    gap: 6px;
}

.contacto-page .social-links a {
    gap: 10px;
}

.contacto-page .social-links img {
    width: 28px;
    height: 28px;
}

/* Instagram Feed Styles */
.instagram-feed {
    margin: 20px auto;
    width: 100%;
    max-width: 960px;
}

.instagram-feed h2 {
    font-size: 24px;
    color: var(--color-primary);
    margin-bottom: 20px;
    text-align: center;
}

.feed-container {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    justify-content: center;
}

.feed-item {
    width: 300px;
    text-align: center;
}

.feed-item img {
    width: 100%;
    height: 300px;
    object-fit: cover;
    border-radius: 8px;
}

.feed-item h3 {
    font-size: 18px;
    color: var(--color-text);
    margin: 10px 0 5px;
}

.feed-item p {
    font-size: 16px;
    color: var(--color-text);
}

.view-more {
    display: block;
    text-align: center;
    background: var(--color-button-bg);
    color: var(--color-button-text);
    padding: 10px 20px;
    border-radius: 4px;
    margin: 20px auto;
    width: fit-content;
}

.view-more:hover {
    background: var(--color-button-hover);
}

/* Calendar Container */
.calendar-container {
    width: 100%;
    max-width: 880px;
    height: 600px;
    overflow: hidden;
    border-radius: 8px;
    background: var(--color-card-bg);
}

.calendar-container iframe {
    width: 100%;
    height: 100%;
    border: 0;
}

.calendar-button {
    text-align: center;
    margin: 20px 0;
}

/* Contact Intro */
.contact-intro {
    max-width: 960px;
    margin: 20px auto;
    padding: 20px 40px;
    background: rgba(187, 221, 255, 0.3);
    border-radius: 8px;
    text-align: center;
}

html[data-theme="dark"] .contact-intro {
    background: rgba(42, 42, 42, 0.5);
}

html[data-theme="sunset"] .contact-intro {
    background: rgba(240, 230, 210, 0.5);
}

.contact-intro p {
    font-size: 18px;
    color: var(--color-text);
    line-height: 1.6;
    margin: 0;
}

/* Contact Form Styles */
.contact-form {
    width: 100%;
    max-width: 600px;
    margin: 20px auto;
}

.contact-form label {
    display: block;
    font-size: 18px;
    margin-bottom: 5px;
    color: var(--color-text);
}

.contact-form input,
.contact-form textarea {
    width: 100%;
    padding: 10px;
    margin-bottom: 15px;
    border: 1px solid var(--color-border);
    border-radius: 4px;
    font-size: 16px;
    background: var(--color-input-bg);
    color: var(--color-text);
}

.contact-form textarea {
    resize: vertical;
    min-height: 100px;
}

.contact-form button {
    background: var(--color-button-bg);
    color: var(--color-button-text);
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    font-size: 18px;
    cursor: pointer;
}

.contact-form button:hover {
    background: var(--color-button-hover);
}

/* Citas Text Styles */
.citas-text {
    margin: 20px auto;
    width: 100%;
    max-width: 960px;
    font-size: 20px;
    color: var(--color-text-dark);
}

.citas-text h2 {
    font-size: 24px;
    color: var(--color-primary);
    margin-bottom: 16px;
    text-align: center;
}

.citas-text ul {
    list-style: none;
    margin-bottom: 16px;
}

.citas-text ul li {
    margin-bottom: 12px;
}

.citas-text p {
    margin-bottom: 12px;
}

.citas-text a {
    color: var(--color-primary);
}

.citas-text a:hover {
    color: var(--color-text-dark);
}

.citas-text .separator {
    border-top: 1px solid var(--color-border);
    margin: 20px 0;
}

.citas-text .emergency {
    text-align: center;
    font-weight: 500;
    font-size: 24px;
}

.citas-text .emergency a {
    color: var(--color-primary);
    display: block;
}

.citas-text .emergency a:hover {
    color: var(--color-text-dark);
}

.citas-text .emergency-followup {
    text-align: center;
}

.citas-text .duda {
    text-align: center;
}

/* Emergencias Text Styles */
.emergencias-text {
    margin: 20px auto;
    width: 100%;
    max-width: 960px;
    font-size: 20px;
    color: var(--color-text-dark);
}

.emergencias-text h2 {
    font-size: 26px;
    color: var(--color-primary);
    margin-bottom: 16px;
    text-align: center;
}

.emergencias-text h3 {
    font-size: 18px;
    color: #404040;
    font-weight: 700;
    margin-bottom: 12px;
}

.emergencias-text ul {
    margin-bottom: 16px;
    padding-left: 20px;
}

.emergencias-text ul li {
    margin-bottom: 16px;
    list-style-type: disc;
}

.emergencias-text p {
    margin-bottom: 12px;
}

.emergencias-text p.calm {
    color: #404040;
    text-align: center;
}

.emergencias-text p.contact {
    color: #404040;
    font-weight: normal;
}

.emergencias-text p.regla {
    font-size: 26px;
    color: #224477;
    font-weight: 700;
    text-align: center;
}

.emergencias-text p.regla-followup {
    font-size: 18px;
    color: #404040;
    text-align: center;
}

.emergencias-text p.definition {
    font-size: 18px;
    text-align: center;
    color: #404040;
}

.emergencias-text a {
    color: var(--color-primary);
}

.emergencias-text a:hover {
    color: var(--color-text-dark);
}

.emergencias-text .emergency-list li {
    font-weight: 700;
}

.emergencias-text .emergency-list li span {
    font-weight: normal;
}

.emergencias-text .separator,
.emergencias-text .calm-separator {
    border-top: 1px solid #D3D3D3;
    margin: 20px 0;
}

/* Emergencias Banner Styles */
.emergencias-page .banner p.phone {
    font-size: 48px;
    font-weight: 700;
    color: var(--color-text-dark) !important;
    margin-bottom: 18px;
}

.emergencias-page .banner p.phone a {
    color: var(--color-text-dark) !important;
}

.emergencias-page .banner p.address {
    font-size: 22px;
    font-weight: 700;
    color: #404040;
}

.emergencias-page .banner p.address a {
    color: #404040;
}

.emergencias-page .banner p.address a:hover {
    color: #224477;
}

/* FAQ Styles */
.faq {
    margin: 20px auto;
    width: 100%;
    max-width: 960px;
}

.faq h2 {
    font-size: 24px;
    color: var(--color-primary);
    margin: 20px 0 10px;
}

.faq h3 {
    font-size: 20px;
    color: var(--color-text);
    margin: 15px 0 5px;
}

.faq p {
    font-size: 18px;
    margin-bottom: 15px;
}

.faq ul {
    list-style: none;
    margin-bottom: 20px;
}

.faq li {
    margin-bottom: 10px;
}

.faq strong {
    font-weight: 500;
}

/* Map Container Styles */
.map-container {
    width: 100%;
    max-width: 880px;
    height: 600px;
    overflow: hidden;
    border-radius: 8px;
    background: #FFFFFF;
}

.map-container h2 {
    font-size: 24px;
    color: var(--color-primary);
    text-align: center;
    padding: 10px;
}

.map-container iframe {
    width: 100%;
    height: calc(100% - 46px);
    border: 0;
}

.mapa-page .banner:first-child {
    border-bottom: 1px solid #D3D3D3;
}

.horarios-info {
    padding: 20px;
    text-align: left;
    max-width: 880px;
}

.horarios-info h3 {
    font-size: 20px;
    color: var(--color-primary);
    margin-bottom: 12px;
}

.horarios-info p {
    font-size: 16px;
    color: var(--color-text);
    margin-bottom: 12px;
}

.horarios-info ul {
    list-style: none;
    padding: 0;
}

.horarios-info li {
    font-size: 16px;
    color: var(--color-text);
    margin-bottom: 8px;
    padding-left: 0;
}

.horarios-info a {
    color: var(--color-primary);
    font-weight: 600;
}

.horarios-info a:hover {
    color: var(--color-text-dark);
}

/* Productos Text Styles */
.productos-text {
    margin: 20px auto;
    width: 100%;
    max-width: 960px;
    font-size: 20px;
    color: #000000;
}

.productos-text h2 {
    font-size: 20px;
    color: var(--color-primary);
    margin-bottom: 16px;
    text-align: center;
    cursor: pointer;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.productos-text h2::before {
    content: '▼';
    font-size: 14px;
    color: #77BBEE;
    margin-right: 8px;
    transition: transform 0.3s ease;
    position: absolute;
    left: 0;
}

.productos-text h2.collapsed::before {
    transform: rotate(-90deg);
}

.productos-text h3 {
    font-size: 20px;
    color: #404040;
    font-weight: 700;
    margin-bottom: 12px;
}

.productos-text .collapse-content.collapsed h3 {
    visibility: hidden;
}

.productos-text a {
    color: var(--color-primary);
}

.productos-text a:hover {
    color: var(--color-text-dark);
}

.productos-text .separator {
    border-top: 1px solid #D3D3D3;
    margin: 20px 0;
}

.productos-text .collapse-content {
    max-height: 0;
    overflow-y: hidden;
    transition: max-height 0.5s ease-in-out, padding 0.5s ease-in-out;
    padding: 0 16px;
}

.productos-text .collapse-content:not(.collapsed) {
    overflow-y: auto;
    padding: 16px;
    scrollbar-width: thin;
    scrollbar-color: #77BBEE transparent;
}

.productos-text .collapse-content:not(.collapsed)::-webkit-scrollbar {
    width: 8px;
}

.productos-text .collapse-content:not(.collapsed)::-webkit-scrollbar-thumb {
    background: #77BBEE;
    border-radius: 4px;
}

.productos-text .collapse-content:not(.collapsed)::-webkit-scrollbar-track {
    background: transparent;
}

.productos-text .collapse-content .product-grid {
    visibility: visible;
}

.productos-text .collapse-content.collapsed .product-grid {
    visibility: hidden;
}

/* Filter Checkboxes */
.filter-checkboxes {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    justify-content: center;
    margin: 20px auto;
    max-width: 960px;
}

.filter-checkbox label {
    font-size: 18px;
    color: #224477;
    cursor: pointer;
}

.filter-checkbox label:hover {
    color: #000000;
}

.filter-checkbox input[type="checkbox"] {
    margin-right: 8px;
    accent-color: #77BBEE;
}

/* Product Grid */
.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    width: 100%;
}

.product-card {
    background: var(--color-card-bg);
    border: 1px solid var(--color-border);
    border-radius: 8px;
    padding: 16px;
    text-align: center;
    transition: opacity 0.3s ease, transform 0.3s ease, height 0.3s ease;
}

.product-card.hidden {
    opacity: 0;
    transform: translateY(10px);
    height: 0;
    margin: 0;
    padding: 0;
    overflow: hidden;
}

.product-card img {
    width: 100%;
    max-width: 300px;
    height: 300px;
    object-fit: cover;
    border-radius: 8px;
}

.product-card h4 {
    font-size: 18px;
    color: var(--color-text);
    margin: 12px 0;
}

.product-card .price {
    font-size: 16px;
    color: var(--color-text-dark);
}

.product-card table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 12px;
}

.product-card table td {
    padding: 8px;
    text-align: left;
    border-bottom: 1px solid var(--color-border);
}

.product-card table td.price {
    text-align: right;
}

/* Servicios Text Styles */
.servicios-text {
    margin: 20px auto;
    width: 100%;
    max-width: 960px;
    font-size: 20px;
    color: #000000;
}

.servicios-text h2 {
    font-size: 24px;
    color: var(--color-primary);
    margin-bottom: 16px;
    text-align: center;
    cursor: pointer;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.servicios-text h2::before {
    content: '▼';
    font-size: 16px;
    color: #77BBEE;
    margin-right: 8px;
    transition: transform 0.3s ease;
    position: absolute;
    left: 0;
}

.servicios-text h2.collapsed::before {
    transform: rotate(-90deg);
}

.servicios-text h3 {
    font-size: 20px;
    color: #404040;
    font-weight: 700;
    margin-bottom: 12px;
}

.servicios-text p {
    margin-bottom: 12px;
}

.servicios-text a {
    color: var(--color-primary);
}

.servicios-text a:hover {
    color: var(--color-text-dark);
}

.servicios-text .separator {
    border-top: 1px solid #D3D3D3;
    margin: 20px 0;
}

.servicios-text table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 16px;
}

.servicios-text table th,
.servicios-text table td {
    padding: 10px;
    text-align: left;
    border-bottom: 1px solid #D3D3D3;
}

.servicios-text table th {
    font-weight: 700;
    color: var(--color-primary);
}

.servicios-text table td {
    font-size: 18px;
}

.servicios-text table td.price {
    text-align: right;
}

.servicios-text .subcategory {
    font-weight: 700;
    margin: 12px 0 8px;
    color: #404040;
}

.servicios-text .collapse-content {
    max-height: 1000px;
    overflow: hidden;
    transition: max-height 0.5s ease-in-out;
}

.servicios-text .collapse-content.collapsed {
    max-height: 0;
}

/* 404 Page Styles */
.error-404-page body {
    background-color: #224477;
    color: #77BBEE;
    text-align: center;
    font-size: 1.5rem;
    line-height: 1.7;
    cursor: default;
    transition: color 0.3s ease;
}

.error-404-page body::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    box-shadow: inset 0 0 10rem rgba(0, 0, 0, 0.7);
    pointer-events: none;
}

.error-404-page .container {
    max-width: 820px;
    margin: 0 auto;
    padding: 28px;
    background-color: transparent;
    position: relative;
    z-index: 1;
}

.error-404-page .logo {
    max-width: 100px;
    margin: 0 auto 24px;
    display: block;
}

.error-404-page h1 {
    color: #FFFFFF;
    font-size: 2.6rem;
    margin-bottom: 32px;
    font-weight: 700;
}

.error-404-page p {
    margin: 18px 0;
    padding: 0 20px;
    color: #77BBEE;
    text-align: center;
}

.error-404-page a {
    color: #77BBEE;
    text-decoration: none;
    font-weight: 700;
    transition: color 0.5s ease;
}

.error-404-page a:hover {
    color: #FFFFFF;
}

.error-404-page .business-info {
    margin-top: 48px;
    color: #B0B0B0;
    font-size: 1.25rem;
    line-height: 1.5;
}

.error-404-page .business-info a {
    color: #77BBEE;
}

.error-404-page .business-info a:hover {
    color: #FFFFFF;
}

.error-404-page .return-link {
    display: inline-block;
    margin-top: 36px;
    font-size: 1.3rem;
    color: #224477;
    background-color: #FFFFFF;
    border: 1.5px solid #B0B0B0;
    padding: 10px 18px;
    border-radius: 4px;
    font-weight: 700;
    transition: all 0.3s ease;
}

.error-404-page .return-link:hover {
    background-color: #B0B0B0;
    color: #224477;
}

.error-404-page footer {
    margin-top: 44px;
    color: #B0B0B0;
    font-size: 1.15rem;
}

.error-404-page footer a {
    color: #77BBEE;
    margin: 0 8px;
}

.error-404-page footer a:hover {
    color: #FFFFFF;
}

/* Instruperro Page Styles - Updated to match site design */
.instruperro-page .container {
    max-width: 960px;
    margin: 20px auto;
    padding: 32px 40px;
    background: linear-gradient(135deg, #BBDDFF 0%, #99CCEE 100%);
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.instruperro-page h1 {
    font-size: 28px;
    color: #224477;
    text-align: center;
    margin-bottom: 20px;
}

.instruperro-page h2 {
    font-size: 22px;
    color: #224477;
    margin: 20px 0 12px;
}

.instruperro-page hr {
    border: none;
    height: 1px;
    background-color: #D3D3D3;
    margin: 20px 0;
}

.instruperro-page p {
    font-size: 18px;
    color: #404040;
    margin-bottom: 16px;
    line-height: 1.6;
}

.instruperro-page a {
    color: #224477;
    text-decoration: none;
    transition: color 0.3s ease;
}

.instruperro-page a:hover {
    color: #000000;
}

.instruperro-page .cita-button {
    display: inline-block;
    background: #224477;
    color: #FFFFFF;
    padding: 12px 24px;
    border-radius: 4px;
    font-size: 18px;
    font-weight: 600;
    text-decoration: none;
    transition: background-color 0.3s ease;
}

.instruperro-page .cita-button:hover {
    background: #77BBEE;
    color: #FFFFFF;
}

.instruperro-page button {
    background-color: #77BBEE;
    color: #224477;
    border: none;
    padding: 10px 20px;
    font-size: 16px;
    cursor: pointer;
    border-radius: 4px;
    transition: background-color 0.3s ease;
    margin-top: 20px;
    font-weight: 600;
}

.instruperro-page button:hover {
    background-color: #224477;
    color: #FFFFFF;
}

.instruperro-page strong {
    color: #224477;
    font-weight: 600;
}

/* Nutri Page Styles */
.nutri-page body {
    background-color: #224477;
    color: #77BBEE;
    text-align: center;
    font-size: 1.5rem;
    line-height: 1.7;
    cursor: default;
    transition: color 0.3s ease;
}

.nutri-page body::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    box-shadow: inset 0 0 10rem rgba(0, 0, 0, 0.7);
    pointer-events: none;
}

.nutri-page .container {
    max-width: 820px;
    margin: 0 auto;
    padding: 28px;
    background-color: transparent;
    position: relative;
    z-index: 1;
}

.nutri-page .logo {
    max-width: 140px;
    margin: 0 auto 24px;
    display: block;
}

.nutri-page h1 {
    color: #FFFFFF;
    font-size: 2.6rem;
    margin-bottom: 32px;
    font-weight: 700;
}

.nutri-page ul {
    list-style: none;
    padding: 0;
    margin: 0 auto;
    max-width: 500px;
}

.nutri-page li {
    margin: 18px 0;
    display: flex;
    justify-content: flex-start;
    align-items: center;
    gap: 12px;
    color: #77BBEE;
    text-align: left;
}

.nutri-page li::before {
    content: "•";
    font-size: 2rem;
    color: #B0B0B0;
}

.nutri-page a {
    color: #77BBEE;
    text-decoration: none;
    font-weight: 700;
    transition: color 0.5s ease;
}

.nutri-page a:hover {
    color: #FFFFFF;
}

.nutri-page .business-info {
    margin-top: 48px;
    color: #B0B0B0;
    font-size: 1.25rem;
    line-height: 1.5;
}

.nutri-page .business-info a {
    color: #77BBEE;
}

.nutri-page .business-info a:hover {
    color: #FFFFFF;
}

.nutri-page .return-link {
    display: inline-block;
    margin-top: 36px;
    font-size: 1.3rem;
    color: #224477;
    background-color: #FFFFFF;
    border: 1.5px solid #B0B0B0;
    padding: 10px 18px;
    border-radius: 4px;
    font-weight: 700;
    transition: all 0.3s ease;
}

.nutri-page .return-link:hover {
    background-color: #B0B0B0;
    color: #224477;
}

.nutri-page footer {
    margin-top: 44px;
    color: #B0B0B0;
    font-size: 1.15rem;
}

.nutri-page footer a {
    color: #77BBEE;
    margin: 0 8px;
}

.nutri-page footer a:hover {
    color: #FFFFFF;
}

/* Nutriaves and Nutriperros Page Styles */
.nutriaves-page,
.nutriperros-page {
    font-family: Arial, sans-serif;
    margin: 20px;
    background-color: #ffffff;
    transition: filter 0.5s ease-in-out;
}

.nutriaves-page h1,
.nutriperros-page h1 {
    text-align: center;
    font-size: 36px;
    color: #000000;
}

.nutriaves-page .product,
.nutriperros-page .product {
    border: 1px solid #ccc;
    padding: 10px;
    margin-bottom: 20px;
    display: inline-block;
    vertical-align: top;
    text-align: left;
    width: 300px;
    box-sizing: border-box;
}

.nutriaves-page h2,
.nutriperros-page h2 {
    font-size: 24px;
    color: #224477;
}

.nutriaves-page h3,
.nutriperros-page h3 {
    font-size: 20px;
    color: #224477;
}

.nutriaves-page p,
.nutriperros-page p {
    font-size: 16px;
    line-height: 1.5;
}

.nutriaves-page img,
.nutriperros-page img {
    display: block;
    margin: 10px auto;
    width: 100px;
}

.nutriaves-page .analysis,
.nutriperros-page .analysis {
    font-weight: bold;
}

.nutriaves-page .links,
.nutriperros-page .links {
    text-align: center;
    margin-top: 20px;
}

.nutriaves-page a,
.nutriperros-page a {
    margin: 0 10px;
    color: #224477;
    text-decoration: none;
}

.nutriaves-page a:hover,
.nutriperros-page a:hover {
    text-decoration: underline;
}

.nutriaves-page .product-container,
.nutriperros-page .product-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
}

/* Invert colors functionality */
html.invert-colors {
    filter: invert(100%);
}

/* Footer */
footer {
    background: var(--color-footer-bg);
    padding: 10px 40px;
    text-align: center;
    font-size: 18px;
    color: var(--color-text-dark);
    width: 100%;
    margin-top: auto;
}

footer p {
    display: inline;
}

footer .wikimedia-link {
    margin-left: 20px;
    color: var(--color-text);
    font-size: 14px;
}

footer .wikimedia-link:hover {
    color: var(--color-primary);
}

/* Wikimedia Page Styles */
.wikimedia-content {
    text-align: left;
    max-width: 880px;
}

.wikimedia-content h2 {
    font-size: 24px;
    color: #224477;
    margin-bottom: 16px;
    text-align: center;
}

.wikimedia-content h3 {
    font-size: 20px;
    color: #224477;
    margin: 20px 0 12px;
}

.wikimedia-content ul {
    margin: 12px 0 16px 20px;
}

.wikimedia-content li {
    margin-bottom: 8px;
    font-size: 18px;
    color: #404040;
}

.wikimedia-info,
.usage-info {
    background: rgba(255, 255, 255, 0.7);
    padding: 20px;
    border-radius: 6px;
    margin: 20px 0;
}

.redirect-info {
    background: rgba(119, 187, 238, 0.2);
    padding: 20px;
    border-radius: 6px;
    margin: 20px 0;
    text-align: center;
}

.redirect-info p {
    margin-bottom: 12px;
    font-size: 18px;
}

.direct-link {
    color: #224477;
    font-weight: 600;
    text-decoration: underline;
}

.direct-link:hover {
    color: #000000;
}

#countdown {
    font-weight: 700;
    color: #224477;
    font-size: 20px;
}

/* Theme toggle in footer */
#theme-toggle {
    cursor: pointer;
    color: var(--color-primary);
    transition: color 0.3s ease;
}

#theme-toggle:hover {
    color: var(--color-text-dark);
}

/* Mobile Landscape Warning */
.mobile-warning {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(34, 68, 119, 0.95);
    color: #FFFFFF;
    z-index: 9999;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    text-align: center;
    padding: 20px;
    font-size: 18px;
    line-height: 1.6;
}

.mobile-warning h2 {
    font-size: 24px;
    margin-bottom: 20px;
    color: #FFFFFF;
}

.mobile-warning p {
    margin-bottom: 15px;
    max-width: 300px;
}

.mobile-warning .rotate-icon {
    font-size: 48px;
    margin: 20px 0;
    animation: rotate 2s linear infinite;
}

@keyframes rotate {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(90deg);
    }
}

.mobile-warning button {
    background: #77BBEE;
    color: #224477;
    border: none;
    padding: 12px 24px;
    border-radius: 4px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    margin-top: 20px;
}

.mobile-warning button:hover {
    background: #FFFFFF;
}

/* Media Queries */
@media (max-width: 600px) {
    .error-404-page body {
        font-size: 1.35rem;
    }

    .error-404-page h1 {
        font-size: 2.1rem;
    }

    .error-404-page .logo {
        max-width: 80px;
    }

    .error-404-page .return-link {
        font-size: 1.15rem;
        padding: 8px 14px;
    }

    .error-404-page .business-info {
        font-size: 1.05rem;
    }

    .nutri-page li::before {
        font-size: 1rem;
    }

    .instruperro-page body {
        font-size: 0.9rem;
    }

    .instruperro-page h1 {
        font-size: 2rem;
    }

    .instruperro-page h2 {
        font-size: 1.5rem;
    }

    .instruperro-page button {
        width: 100%;
        box-sizing: border-box;
    }
}

@media (max-width: 768px) {
    .logo-text {
        font-size: 30px;
    }

    h1 {
        font-size: 24px;
        max-width: 90%;
    }

    nav {
        padding: 0 32px;
    }

    nav ul {
        gap: 12px;
        font-size: 18px;
        margin-left: 16px;
    }

    nav ul li:not(:last-child)::after {
        margin-left: 12px;
    }

    .banner {
        padding: 20px;
        max-width: 90%;
    }

    .banner p {
        max-width: 95%;
        font-size: 20px;
    }

    .banner p.note {
        font-size: 16px;
    }

    .nav-arrow {
        font-size: 20px;
    }

    .nav-controls {
        right: 32px;
    }

    .nav-controls::before {
        left: 32px;
        width: calc(100vw - 32px);
    }

    .phone-numbers,
    .social-links {
        flex-direction: column;
        gap: 10px;
    }

    .contacto-page .phone-numbers,
    .contacto-page .social-links {
        gap: 12px;
    }

    .contacto-page .social-links img {
        width: 24px;
        height: 24px;
    }

    .gallery img {
        width: 200px;
        height: 200px;
    }

    .contact {
        max-width: 90%;
    }

    .citas-text,
    .emergencias-text,
    .faq,
    .servicios-text,
    .productos-text,
    .filter-checkboxes {
        max-width: 90%;
    }

    .calendar-container,
    .map-container {
        max-width: 90%;
        height: 500px;
    }

    .contact-form {
        max-width: 90%;
    }

    .contact-form label {
        font-size: 16px;
    }

    .contact-form input,
    .contact-form textarea {
        font-size: 14px;
    }

    .contact-form button {
        font-size: 16px;
    }

    header {
        padding: 10px 20px;
    }

    .header-container {
        max-width: 100%;
    }

    .citas-text h2,
    .faq h2,
    .servicios-text h2 {
        font-size: 22px;
    }

    .citas-text .emergency {
        font-size: 22px;
    }

    .emergencias-text h2 {
        font-size: 24px;
    }

    .emergencias-text h3 {
        font-size: 16px;
    }

    .emergencias-text {
        font-size: 18px;
    }

    .emergencias-text p.regla {
        font-size: 24px;
    }

    .emergencias-text p.definition {
        font-size: 16px;
    }

    .emergencias-page .banner p.phone {
        font-size: 40px;
    }

    .emergencias-page .banner p.address {
        font-size: 20px;
    }

    .faq h3 {
        font-size: 18px;
    }

    .faq p {
        font-size: 16px;
    }

    .instagram-feed h2 {
        font-size: 22px;
    }

    .feed-item {
        width: 100%;
        max-width: 300px;
    }

    .feed-item img {
        height: 200px;
    }

    .feed-item h3 {
        font-size: 16px;
    }

    .feed-item p {
        font-size: 14px;
    }

    .productos-text h2 {
        font-size: 18px;
    }

    .productos-text h3 {
        font-size: 18px;
    }

    .productos-text {
        font-size: 18px;
    }

    .productos-text h2::before {
        font-size: 12px;
    }

    .product-grid {
        grid-template-columns: 1fr;
    }

    .filter-checkbox label {
        font-size: 16px;
    }

    .servicios-text h3 {
        font-size: 18px;
    }

    .servicios-text {
        font-size: 18px;
    }

    .servicios-text table td {
        font-size: 16px;
    }

    .servicios-text h2::before {
        font-size: 14px;
    }

    .nutriaves-page h1,
    .nutriperros-page h1 {
        font-size: 28px;
    }

    .nutriaves-page .product,
    .nutriperros-page .product {
        width: 100%;
    }

    .nutriaves-page .links a,
    .nutriperros-page .links a {
        display: block;
        margin-bottom: 10px;
    }
}

@media (min-width: 769px) {

    .nutriaves-page .product-container,
    .nutriperros-page .product-container {
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
        gap: 20px;
    }

    .nutriaves-page .product,
    .nutriperros-page .product {
        width: calc(50% - 10px);
    }
}

@media (min-width: 1024px) {

    .nutriaves-page .product,
    .nutriperros-page .product {
        width: calc(25% - 15px);
    }
}

@media (min-width: 1200px) and (max-width: 1600px) {
    .header-container {
        max-width: 1000px;
    }

    .banner,
    h1 {
        max-width: 800px;
    }

    .banner p {
        max-width: 720px;
    }

    .gallery {
        max-width: 1280px;
    }

    .contact,
    .citas-text,
    .emergencias-text,
    .faq,
    .servicios-text,
    .productos-text,
    .filter-checkboxes {
        max-width: 800px;
    }

    .calendar-container,
    .map-container {
        max-width: 720px;
    }
}

@media (min-width: 1600px) {
    .header-container {
        max-width: 1200px;
    }

    .gallery {
        max-width: 1536px;
    }
}