/* === VARIABLES === */
:root {
    --primary: #8e2038;
    --primary-dark: #72182c;
    --secondary: #000;
    --light: #f8f9fa;
    --dark: #212529;
    --gray: #6c757d;
    --light-gray: #e9ecef;

    --scroll-track: #f1f1f1;
    --scroll-thumb: #8e2038;
    --scroll-thumb-hover: #8e2038;
}

/* === RESET === */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html, body {
    width: 100%;
    min-height: 100vh;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: var(--dark);
}

/* Scrollbars */
html {
    overflow-y: scroll;
    scrollbar-width: auto;
    scrollbar-color: var(--scroll-thumb) var(--scroll-track);
}

::-webkit-scrollbar {
    width: 14px;
    height: 14px;
}

::-webkit-scrollbar-track {
    background: var(--scroll-track);
    border-radius: 8px;
}

::-webkit-scrollbar-thumb {
    background-color: var(--scroll-thumb);
    border-radius: 8px;
    border: 3px solid var(--scroll-track);
}

::-webkit-scrollbar-thumb:hover {
    background-color: var(--scroll-thumb-hover);
}

/* === BODY STRUCTURE === */
body {
    display: flex;
    flex-direction: column;
}

/* === NAVBAR === */
.navbar-custom {
    background-color: white;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    padding: 10px 20px;
    position: fixed;
    top: 0;
    z-index: 1030;
    width: 100%;
}

.nav-link {
    color: #333;
    font-size: 1rem;
    text-decoration: none;
    margin-right: 15px;
    position: relative;
    transition: color 0.3s ease;
}

.nav-link::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -5px;
    width: 0%;
    height: 2px;
    background-color: var(--primary);
    transition: width 0.3s ease;
}

.nav-link:hover {
    color: var(--primary);
}

.nav-link:hover::after {
    width: 100%;
}

.nav-link[data-section-title] {
    font-weight: 600;
    letter-spacing: .3px;
}

.nav-link[data-section-title]:hover {
    color: var(--primary-dark);
}

.nav-item svg {
    vertical-align: middle;
    transition: transform 0.2s ease;
}

.nav-item svg:hover {
    transform: scale(1.2);
}

/* === MAIN CONTAINER === */
main.container-fluid {
    width: 100%;
    flex: 1;
    overflow: hidden;
}

/* === SEARCH OVERLAY === */
.search-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, .75);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1080;
}

.search-box {
    background: #fff;
    padding: 24px 28px;
    border-radius: 12px;
    display: flex;
    gap: 12px;
    width: min(92%, 480px);
    box-shadow: 0 12px 32px rgba(0, 0, 0, .25);
}

.search-box input {
    flex: 1;
    border: 1px solid #ccc;
    border-radius: 6px;
    padding: 10px 14px;
    font-size: 1rem;
    outline: none;
}

.search-box button {
    background: var(--primary);
    color: #fff;
    border: none;
    border-radius: 6px;
    width: 44px;
    height: 44px;
    font-size: 1.25rem;
    cursor: pointer;
    transition: 0.25s;
}

.search-box button:hover {
    background: var(--primary-dark);
}

/* Resaltar resultados */
.search-highlight {
    background-color: #fff8e1;
    padding: 2px 4px;
    border-radius: 3px;
    animation: highlightFade 2s ease;
}

@keyframes highlightFade {
    from {
        background-color: #ffeb3b;
    }
    to {
        background-color: #fff8e1;
    }
}

/* === BOTÓN "SUBIR" === */
.btn-top {
    position: fixed;
    right: 24px;
    bottom: 32px;
    width: 48px;
    height: 48px;
    border: none;
    border-radius: 50%;
    background: var(--primary);
    color: #fff;
    font-size: 1.4rem;
    text-align: center;
    cursor: pointer;
    box-shadow: 0 6px 16px rgba(0, 0, 0, .25);
    transition: transform .25s ease, background-color .25s;
    display: none;
    z-index: 1050;
}

.btn-top:hover {
    transform: translateY(-4px);
    background: var(--primary-dark);
}

/* === IMÁGENES === */
img {
    max-width: 100%;
    height: auto;
}

/* === FOOTER === */
footer.bg-dark {
    background-color: var(--secondary) !important;
    color: var(--light);
    padding: 2.5rem 0;
}

footer .text-primary {
    color: var(--primary) !important;
    font-weight: 600;
    letter-spacing: 0.5px;
}

footer h5 {
    font-size: 1.1rem;
    margin-bottom: 1.25rem;
    position: relative;
}

footer h5::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    width: 50px;
    height: 2px;
    background-color: var(--primary);
}

footer h6 {
    font-size: 0.95rem;
    font-weight: 500;
}

footer p {
    margin-bottom: 0.25rem;
    font-size: 0.9rem;
    color: var(--light-gray);
}

footer .btn-outline-light {
    border-color: var(--light-gray);
    color: white;
    padding: 0.5rem 1.25rem;
    transition: all 0.3s ease;
    font-weight: 500;
}

footer .btn-outline-light:hover {
    background-color: var(--primary);
    border-color: var(--primary);
    transform: translateY(-3px);
    box-shadow: 0 4px 10px rgba(142, 32, 56, 0.3);
}
