/* =============================================================
   Marina Barsoum — Shared site chrome (header, nav, language
   selector, music player, buttons, footer, base animations).
   Loaded by every page. Page-specific layout (hero, sections,
   forms, galleries) stays in each page's own <style> block.
   ============================================================= */

/* ===== RESET Y VARIABLES ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #9c27b0;
    --secondary-color: #ff4081;
    --dark-color: #212121;
    --light-color: #f5f5f5;
    --white: #ffffff;
    --gold: #d4af37;
    --granada-red: #c62828;
    --andalucia-green: #2e7d32;
    --font-main: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    --shadow-sm: 0 2px 10px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 5px 15px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 25px rgba(0, 0, 0, 0.15);
    --transition: all 0.3s ease;
}

body {
    font-family: var(--font-main);
    background-color: var(--light-color);
    color: var(--dark-color);
    line-height: 1.6;
    overflow-x: hidden;
}

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

a:hover {
    color: var(--secondary-color);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    width: 100%;
}

/* ===== HEADER Y NAVEGACIÓN ===== */
header {
    background-color: var(--white);
    box-shadow: var(--shadow-sm);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 0;
    position: relative;
    flex-wrap: wrap;
}

.logo {
    font-size: 24px;
    font-weight: 700;
    color: var(--primary-color);
    z-index: 1002;
}

.logo span {
    color: var(--secondary-color);
}

/* Hamburguesa Menu */
.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 4px;
    padding: 5px;
    z-index: 1001;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background: var(--primary-color);
    transition: 0.3s;
    border-radius: 2px;
}

.hamburger.active span:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
}

/* Navigation */
nav ul {
    display: flex;
    list-style: none;
    gap: 30px;
}

nav ul li a {
    font-weight: 600;
    position: relative;
    padding: 5px 0;
}

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

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

/* Language selector */
.language-selector {
    position: relative;
    margin-left: 20px;
    z-index: 1001;
}

.language-btn {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 16px;
    display: flex;
    align-items: center;
    color: var(--primary-color);
    padding: 8px 12px;
    border-radius: 20px;
    transition: var(--transition);
}

.language-btn:hover {
    background: rgba(156, 39, 176, 0.1);
}

.language-btn i {
    margin-right: 5px;
}

.language-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    background: var(--white);
    box-shadow: var(--shadow-md);
    border-radius: 8px;
    width: 160px;
    display: none;
    z-index: 1001;
    margin-top: 5px;
    border: 1px solid #e0e0e0;
}

.language-dropdown.show {
    display: block;
}

.language-option {
    padding: 12px 15px;
    display: flex;
    align-items: center;
    cursor: pointer;
    transition: var(--transition);
    border-bottom: 1px solid #f5f5f5;
}

.language-option:last-child {
    border-bottom: none;
}

.language-option:hover {
    background: #f8f9fa;
}

.language-option img {
    width: 20px;
    height: 15px;
    margin-right: 10px;
    object-fit: cover;
    border-radius: 2px;
}

/* ===== MUSIC CONTROLS - posición dinámica con JS ===== */
.music-controls {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    padding: 12px 0;
    position: fixed;
    left: 0;
    right: 0;
    z-index: 999;
    box-shadow: var(--shadow-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
}

.music-player {
    display: flex;
    align-items: center;
    gap: 15px;
    background: rgba(255, 255, 255, 0.1);
    padding: 0 20px;
    border-radius: 25px;
    backdrop-filter: blur(10px);
}

.music-icon {
    font-size: 20px;
    cursor: pointer;
    transition: var(--transition);
}

.music-icon:hover {
    transform: scale(1.1);
    color: var(--secondary-color);
}

.music-status {
    font-size: 14px;
    font-weight: 500;
    min-width: 120px;
}

.control-buttons {
    display: flex;
    gap: 10px;
}

.control-btn {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    font-size: 14px;
}

.control-btn:hover:not(:disabled) {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.05);
}

.control-btn.active {
    background: var(--secondary-color);
    animation: pulse 2s infinite;
}

.control-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

/* ===== BUTTONS ===== */
.btn {
    display: inline-block;
    background: var(--primary-color);
    color: var(--white);
    padding: 12px 30px;
    border-radius: 30px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: var(--transition);
    animation: fadeIn 1.5s ease;
    border: none;
    cursor: pointer;
}

.btn:hover {
    background: var(--secondary-color);
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}

/* ===== FOOTER ===== */
footer {
    background: var(--dark-color);
    color: var(--white);
    padding: 50px 0 20px;
    clear: both;
}

.footer-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-bottom: 30px;
}

.footer-col h3 {
    color: var(--secondary-color);
    margin-bottom: 20px;
    font-size: 1.3rem;
}

.footer-col p {
    margin-bottom: 15px;
    color: #ccc;
}

.footer-col ul {
    list-style: none;
}

.footer-col ul li {
    margin-bottom: 10px;
}

.footer-col ul li a {
    color: #ccc;
    transition: var(--transition);
}

.footer-col ul li a:hover {
    color: var(--secondary-color);
    padding-left: 5px;
}

.social-links {
    display: flex;
    margin-top: 20px;
    gap: 10px;
}

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

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

.copyright {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.logo-4uware {
    text-align: center;
    margin-top: 20px;
}

.logo-4uware img {
    width: 100px;
    height: auto;
    vertical-align: middle;
}

.logo-4uware p {
    font-size: 12px;
    color: #ccc;
    margin-top: 5px;
}

.logo-4uware a {
    color: var(--white);
}

/* ===== ANIMACIONES ===== */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

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

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ===== RESPONSIVE: shared chrome only ===== */
@media (max-width: 768px) {
    .header-container {
        flex-wrap: wrap;
    }

    .hamburger {
        display: flex;
        order: 2;
    }

    nav {
        order: 3;
        width: 100%;
        display: none;
        margin-top: 20px;
    }

    nav.active {
        display: block;
    }

    nav ul {
        flex-direction: column;
        background: var(--white);
        padding: 20px;
        border-radius: 10px;
        box-shadow: var(--shadow-md);
        gap: 15px;
    }

    nav ul li {
        margin: 0;
        text-align: center;
    }

    .language-selector {
        order: 1;
        margin-left: 0;
    }

    .music-controls {
        flex-direction: column;
        gap: 10px;
        padding: 10px 0;
    }

    .music-player {
        width: 90%;
        justify-content: center;
        flex-wrap: wrap;
    }

    .music-status {
        min-width: auto;
    }

    .footer-container {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .social-links {
        justify-content: center;
    }

    .logo-4uware img {
        margin: 0 auto;
    }
}

@media (max-width: 480px) {
    .btn {
        padding: 10px 25px;
        font-size: 14px;
    }

    .music-player {
        padding: 0 10px;
    }

    .control-buttons {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 360px) {
    .logo {
        font-size: 20px;
    }

    .language-btn span {
        display: none;
    }

    .language-btn i {
        margin-right: 0;
    }
}

@media (max-width: 768px) and (orientation: portrait) {
    button,
    .control-btn,
    .language-btn,
    .hamburger {
        min-height: 44px;
        min-width: 44px;
    }

    body {
        font-size: 16px;
        -webkit-text-size-adjust: 100%;
    }
}

@media (max-width: 320px) {
    .logo {
        font-size: 18px;
    }
}
