/* Styles for menu and footer (extracted) */
@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;600&family=Lato:wght@400;700&display=swap');

:root {
    --color-accent: #a1b27a;
    --color-bg: #fdfaf5;
    --color-text: #5c4033;
    --color-white: #fefefe;
    /* This line is unchanged but included for context */
    --color-border: #e6e2dc;
    --color-contrast: #6a4f3d;
    --color-inactive: #999999;
    --color-title: #5c4033;
    --color-gris: #f4f4f4;
    --color-texto: #2c3e50;
    --color-azul: #3b82f6;
    --color-verde: var(--color-favor, #2e8b57);
    --color-naranja: #f39c12;
}

/* Typography: unified across the site */
body {
    font-family: 'Lato', sans-serif;
    background: var(--color-bg, #fdfaf5);
    color: var(--color-title);
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    text-align: left;
}

h1,
h2,
h3,
h4 {
    font-family: 'Montserrat', sans-serif;
    color: var(--color-title);
}

/* Header logo sizing */
header img {
    width: 100px;
    height: auto;
    margin-left: 1em;
}

/* Header layout and appearance (moved from inline) */
header {
    background: var(--color-bg, #fdfaf5);
    border-bottom: 2px solid var(--color-border, #e6e2dc);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    padding: 1.5em 1em;
    display: flex;
    justify-content: space-between;
    align-items: center;
}


header h1 {
    margin: 0;
    font-size: 1.6em;
    color: var(--color-title);
}

header p {
    margin: 0.4em 0 0;
    color: #6a4f3d;
    font-size: 0.95em;
}

/* Shared header utilities used across pages */
.header-text {
    flex-grow: 1;
    padding-right: 1em;
}

.header-text h1 {
    margin: 0;
    font-size: clamp(1.4em, 4vw, 2em);
    text-transform: uppercase;
}

.header-text p {
    margin-top: 0.5em;
    font-size: clamp(0.9em, 2.5vw, 1em);
    font-style: italic;
}

.logo {
    max-width: 140px;
    height: auto;
    object-fit: contain;
}

.container {
    flex: 1;
    max-width: 900px;
    margin: auto;
    padding: 1em;
}

/* Ensure main content expands to push footer to bottom on pages without .container */
main {
    flex: 1;
}

/* Overlay fijo debajo del row */
.overlay {
    position: fixed;
    left: 0;
    width: 100%;
    background: rgba(0, 0, 0, 0.3);
    display: none;
    z-index: 900;
}

.overlay.active {
    display: block;
}

/* Row con hamburguesa */
.menu-row {
    background: var(--color-accent);
    padding: 0.3em 0.8em;
    display: flex;
    justify-content: flex-start;
}

.hamburger {
    width: 32px;
    height: 32px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    color: var(--color-white);
    font-size: 1.6em;
}

.hamburger span {
    height: 3px;
    width: 22px;
    background: var(--color-white);
    margin: 3px 0;
    border-radius: 2px;
}

.hamburger.close span {
    display: none;
}

.hamburger.close::before {
    content: "×";
    color: var(--color-white);
    font-size: 1.6em;
}

/* Menú horizontal */
nav {
    background: var(--color-accent);
}

nav ul {
    list-style: none;
    margin: 0;
    padding: 0.5em 1em;
    display: flex;
    gap: 1em;
}

nav ul li a {
    color: var(--color-white);
    text-decoration: none;
    font-weight: bold;
    padding: 0.4em 0.8em;
    border-radius: 4px;
    transition: background 0.3s, color 0.3s, transform 0.3s;
    position: relative;
}

nav ul li a:hover {
    background: var(--color-contrast);
    transform: translateX(4px);
}

nav ul li a::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: -2px;
    width: 0%;
    height: 2px;
    background: var(--color-white);
    transition: width 0.3s ease;
}

nav ul li a:hover::after {
    width: 100%;
}

/* Menú lateral fijo con scroll interno */
.mobile-menu {
    position: fixed;
    left: -100%;
    width: 220px;
    background: var(--color-accent);
    color: var(--color-white);
    transition: left 0.3s ease;
    z-index: 1000;
    box-shadow: 4px 0 12px rgba(0, 0, 0, 0.2);
    overflow-y: auto;
}

.mobile-menu.active {
    left: 0;
}

.mobile-menu ul {
    list-style: none;
    padding: 0.5em;
    margin: 0.5em;
}

.mobile-menu ul li {
    border-bottom: 1px solid var(--color-contrast);
}

.mobile-menu ul li a {
    display: block;
    padding: 0.9em;
    text-decoration: none;
    color: var(--color-white);
    font-weight: bold;
    transition: background 0.3s, transform 0.3s;
    position: relative;
}

.mobile-menu ul li a:hover {
    background: var(--color-contrast);
    transform: translateX(4px);
}

.mobile-menu ul li a::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: -2px;
    width: 0%;
    height: 2px;
    background: var(--color-white);
    transition: width 0.3s ease;
}

.mobile-menu ul li a:hover::after {
    width: 100%;
}

/* Footer */
footer {
    background: var(--color-accent);
    color: var(--color-white);
    text-align: center;
    padding: 1.2em 0;
    margin-top: auto;
}

footer p {
    color: var(--color-white);
    margin: 0;
}

.footer-links {
    margin-top: 1em;
    display: flex;
    justify-content: center;
    gap: 1.5em;
}

.footer-links a {
    color: var(--color-white);
    text-decoration: none;
}

@media(max-width:768px) {
    nav ul {
        display: none;
    }

    .hamburger {
        display: flex;
    }

    .footer-links {
        display: none;
    }
}

@media(min-width:769px) {
    .menu-row {
        display: none;
    }
}