/* Base Styles */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    font-size: 100%;
    overflow-x: hidden;
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
    background-color: var(--color-background);
}

body {
    font-family: var(--font-family-body);
    line-height: 1.6;
    color: var(--color-text);
    background-color: var(--color-background); /* Color base sólido */
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    position: relative;
    overflow-x: hidden;
    width: 100%;
    min-height: 100%;
    margin: 0;
    padding: 0;
}

/* Fondo animado optimizado en capa separada */
body::before {
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background: linear-gradient(300deg, #EAE0D5, #E4DACE, #EAE0D5, #F0E8DE, #EAE0D5);
    background-size: 400% 400%;
    animation: softTornasol 20s ease infinite;
    pointer-events: none;
    will-change: background-position; /* Sugerencia al navegador para optimizar */
}

@keyframes softTornasol {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* Prevent horizontal overflow on main containers */
.container, .section-padding, main, section {
    max-width: 100vw;
    overflow-x: hidden;
    overflow-y: visible;
}

/* Prevent images and media from causing horizontal overflow */
img, video, iframe, embed, object {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Utility Classes */
.container {
    max-width: 90%; /* Use percentage instead of fixed pixels */
    margin: 0 auto;
    padding: 0 5%; /* Convert to percentage */
}

.section-padding {
    padding: 5% 0; /* Reduced from 8% to 5% */
    position: relative;
}

.section-title {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: var(--spacing-md);
    background: linear-gradient(135deg, var(--color-primary), var(--color-accent));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.section-subtitle {
    font-size: 1.15rem;
    text-align: center;
    max-width: 80%; /* Convert to percentage */
    margin: 0 auto 5%; /* Convert spacing to percentage */
    color: var(--color-neutral-600);
}

a {
    color: var(--color-primary);
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

ul {
    list-style: none;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-family-heading);
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: var(--spacing-sm);
    color: var(--color-text);
}

p {
    margin-bottom: var(--spacing-sm);
}

.bg-light {
    background-color: var(--color-neutral-100);
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}


