/*
    Los Tacos con Salsa - Design System
    Color Palette:
    - Elegant Black: #0a0a0a
    - Sparkling Gold: #d4af37
    - White Accent: #ffffff
    - Glass Background: rgba(255, 255, 255, 0.05)
*/

:root {
    --black: #0a0a0a;
    --gold: #d4af37;
    --gold-glow: rgba(212, 175, 55, 0.4);
    --white: #ffffff;
    --glass: rgba(255, 255, 255, 0.05);
    --glass-border: rgba(212, 175, 55, 0.3);
    
    /* Puerto Rico Accent Colors - Subtle Use */
    --pr-red: #ED1727;
    --pr-blue: #0050EF;
    
    --font-heading: 'Playfair Display', serif;
    --font-body: 'Montserrat', sans-serif;
    --transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

.site-wrapper {
    overflow-x: hidden;
    width: 100%;
    position: relative;
}

html {
    scroll-behavior: smooth;
    width: 100%;
}

body {
    width: 100%;
    position: relative;
    background-color: var(--black);
    background-image: linear-gradient(rgba(10, 10, 10, 0.9), rgba(10, 10, 10, 0.9)), url('https://www.transparenttextures.com/patterns/dark-wood.png');
    background-repeat: repeat;
    background-attachment: fixed; /* Keep it elegant on desktop */
    color: var(--white);
    font-family: var(--font-body);
    line-height: 1.6;
}

@media (max-width: 768px) {
    body {
        background-attachment: scroll; /* Mobile fixes for fixed backgrounds */
    }
}

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

/* Typography */
h1, h2, h3 {
    font-family: var(--font-heading);
    color: var(--gold);
    text-transform: capitalize;
}

.section-title {
    font-size: 3rem;
    text-align: center;
    margin-bottom: 50px;
    position: relative;
    padding-bottom: 15px;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background: var(--gold);
}

/* Header & Nav */
header {
    padding: 20px 0;
    position: absolute;
    width: 100%;
    z-index: 100;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo h1 {
    font-size: 2rem;
    background: linear-gradient(to right, #d4af37, #f7e089, #d4af37);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 0 5px var(--gold-glow));
}

.nav-logo {
    height: 60px;
    width: auto;
    filter: drop-shadow(0 0 8px var(--gold-glow));
    transition: var(--transition);
}

.nav-logo:hover {
    transform: scale(1.05);
}

.menu-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 6px;
    z-index: 1001;
}

.menu-toggle .bar {
    width: 30px;
    height: 3px;
    background-color: var(--gold);
    border-radius: 3px;
    transition: var(--transition);
}

/* Hamburger Animation */
.menu-toggle.active .bar:nth-child(2) {
    opacity: 0;
}

.menu-toggle.active .bar:nth-child(1) {
    transform: translateY(9px) rotate(45deg);
}

.menu-toggle.active .bar:nth-child(3) {
    transform: translateY(-9px) rotate(-45deg);
}

.nav-links {
    list-style: none;
    display: flex;
    gap: 30px;
}

.nav-links a {
    color: var(--white);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
    letter-spacing: 1px;
    transition: var(--transition);
}

.nav-links a:hover {
    color: var(--gold);
}

.mobile-only {
    display: none !important;
}

/* Hero Section */
.hero {
    height: 100vh;
    min-height: 100vh;
    min-height: 100dvh;
    background-image: linear-gradient(rgba(0,0,0,0.7), rgba(0,0,0,0.7)), url('./assets/hero_bg.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    overflow: hidden;
}

.hero-main-logo {
    max-width: 400px;
    height: auto;
    margin-bottom: 20px;
    filter: drop-shadow(0 0 15px var(--gold-glow));
    transition: var(--transition);
}

@media (max-width: 768px) {
    .hero-main-logo {
        max-width: 220px;
    }
}

@media (max-width: 768px) {
    .hero {
        background-attachment: scroll; /* Critical for mobile background alignment */
        min-height: 80vh; /* Adjust for better visibility on small screens */
    }
}

.hero-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    max-width: 100%;
    padding: 0 20px;
    animation: fadeIn 1.2s ease-out;
    padding-top: 80px; /* Standard header offset */
    position: relative;
    z-index: 5;
}

@media (min-width: 769px) {
    .hero-content {
        padding-top: 0;
    }
}

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

.hero-title {
    font-size: 5rem;
    margin-bottom: 10px;
    filter: drop-shadow(0 4px 10px rgba(0,0,0,0.8));
}

.hero-slogan {
    font-size: 1.8rem;
    font-style: italic;
    color: var(--gold);
    margin-bottom: 40px;
    font-weight: 300;
    text-shadow: 0 4px 15px rgba(0,0,0,0.9); /* Strong shadow for readability */
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 15px 40px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    letter-spacing: 1px;
    transition: var(--transition);
    cursor: pointer;
}

.btn-gold {
    background: var(--gold);
    color: var(--black);
    box-shadow: 0 4px 15px var(--gold-glow);
}

.btn-gold:hover {
    background: #f7e089;
    transform: translateY(-3px);
    box-shadow: 0 8px 25px var(--gold-glow);
}

.btn-outline {
    border: 2px solid var(--gold);
    color: var(--gold);
    margin-right: 15px;
}

.btn-outline:hover {
    background: var(--gold);
    color: var(--black);
}

/* Culture Section */
.culture-section {
    padding: 80px 0;
}

.culture-flex {
    display: flex;
    align-items: center;
    gap: 50px;
    padding: 60px;
}

.culture-img {
    flex: 1;
}

.culture-img img {
    width: 100%;
    border-radius: 15px;
    filter: grayscale(100%) brightness(0.8) sepia(50%) hue-rotate(-50deg) saturate(200%);
    box-shadow: 0 15px 35px rgba(0,0,0,0.5);
    border: 1px solid var(--glass-border);
}

.culture-text {
    flex: 1.2;
}

.section-title.left {
    text-align: left;
    margin-bottom: 30px;
}

.section-title.left::after {
    left: 0;
    transform: none;
}

.culture-text h3 {
    font-size: 1.5rem;
    color: var(--gold);
    margin-bottom: 20px;
}

.culture-text p {
    font-size: 1.1rem;
    margin-bottom: 20px;
    color: #eee;
}

.quote {
    font-family: var(--font-heading);
    font-style: italic;
    color: var(--gold);
    font-size: 1.4rem;
}

/* Menu Section */
.menu-section {
    padding: 100px 0;
    background: radial-gradient(circle at top right, #1a1a1a 0%, #0a0a0a 100%);
}

.menu-category {
    margin-bottom: 80px;
}

.category-header {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 40px;
}

.category-header h2 {
    font-size: 2rem;
    white-space: nowrap;
    position: relative;
    padding-bottom: 0;
}

/* Glassmorphism Category Badge */
.category-header::after {
    content: '';
    flex: 1;
    height: 1px;
    background: linear-gradient(to right, var(--gold), transparent);
}

.menu-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

/* Glassmorphism Cards */
.glass {
    background: var(--glass);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
}

.menu-card {
    overflow: hidden;
    transition: var(--transition);
    display: flex;
    flex-direction: column;
}

.menu-card:hover {
    transform: translateY(-10px);
    border-color: var(--gold);
    box-shadow: 0 10px 30px rgba(212, 175, 55, 0.2);
}

.card-img-wrapper {
    height: 200px;
    overflow: hidden;
}

@media (max-width: 480px) {
    .card-img-wrapper {
        height: 160px;
    }
}

.card-img-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.menu-card:hover img {
    transform: scale(1.1);
}

.card-content {
    padding: 25px;
    text-align: center;
}

.card-content h3 {
    font-size: 1.5rem;
    margin-bottom: 5px;
}

.card-tag {
    display: inline-block;
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 4px 12px;
    border-radius: 20px;
    margin-bottom: 15px;
    font-weight: 700;
}

.tag-star {
    background: var(--gold);
    color: var(--black);
}

.tag-favorite {
    background: var(--pr-blue);
    color: white;
}

.card-content p {
    font-size: 0.95rem;
    color: #ccc;
    margin-bottom: 20px;
    min-height: 2.8em;
}

.price {
    display: block;
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--gold);
    position: relative;
}

.price::before {
    content: '';
    position: absolute;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 30px;
    height: 1px;
    background: var(--glass-border);
}

.card-icon {
    position: absolute;
    top: 15px;
    right: 15px;
    font-size: 1.2rem;
    z-index: 10;
}

.icon-star { color: var(--gold); }
.icon-fav { color: orange; animation: pulse 2s infinite; }

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

/* Picor Section */
.picor-section {
    padding: 60px 0;
    text-align: center;
}

.picor-container {
    max-width: 800px;
    margin: 0 auto;
    padding: 40px;
}

.picor-meter {
    height: 12px;
    background: linear-gradient(to right, #4CAF50, #FFC107, #F44336);
    border-radius: 10px;
    margin-bottom: 40px;
    position: relative;
}

.picor-points {
    display: flex;
    justify-content: space-between;
    position: absolute;
    top: -30px;
    width: 100%;
}

.picor-points span {
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
}

.picor-details {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

.picor-item {
    padding: 20px;
}

.picor-item h4 {
    color: var(--gold);
    margin-bottom: 10px;
}

.picor-item p {
    font-size: 0.9rem;
    color: #ccc;
}

/* Flyers Section */
.menu-flyers {
    margin-top: 100px;
    padding-bottom: 50px;
}

.flyer-flex {
    display: flex;
    gap: 30px;
    padding: 40px;
    justify-content: center;
    flex-wrap: wrap;
}

.flyer-img {
    max-width: 45%;
    height: auto;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    transition: var(--transition);
    border: 1px solid var(--glass-border);
}

.flyer-img:hover {
    transform: scale(1.02);
    border-color: var(--gold);
}

@media (max-width: 768px) {
    .flyer-img {
        max-width: 100%;
    }
}

/* Location Section */
.location-section {
    padding: 100px 0;
}

.map-container {
    padding: 15px;
    border-radius: 25px;
    margin-bottom: 30px;
}

.map-container iframe {
    border-radius: 15px;
}

.contact-info {
    text-align: center;
}

.contact-info p {
    font-size: 1.2rem;
    margin-bottom: 10px;
}

.phone a {
    color: var(--gold);
    text-decoration: none;
    font-size: 1.5rem;
    font-weight: 700;
}

/* Footer */
footer {
    padding: 60px 0;
    border-top: 1px solid var(--glass-border);
    background: #050505;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 50px;
}

.footer-payments {
    margin-top: 20px;
}

.footer-payments p {
    font-size: 0.8rem;
    color: #888;
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.payment-icons {
    display: flex;
    gap: 15px;
    color: #ccc;
    font-size: 1.2rem;
    align-items: center;
}

.payment-icons span {
    font-weight: 600;
}

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

.social-links a {
    color: var(--white);
    font-size: 1.5rem;
    transition: var(--transition);
}

.social-links a:hover {
    color: var(--gold);
}

.footer-contact p {
    font-size: 0.9rem;
    color: #ccc;
    margin-bottom: 8px;
}

.footer-contact a {
    color: var(--gold);
    text-decoration: none;
}

.footer-brand h3 {
    font-size: 1.8rem;
    margin-bottom: 10px;
}

.btn-whatsapp-footer {
    background: #25d366;
    color: white;
    padding: 12px 30px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition);
}

.btn-whatsapp-footer:hover {
    background: #128c7e;
    transform: scale(1.05);
}

/* Floating WhatsApp */
.whatsapp-float {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background-color: #25d366;
    color: #FFF;
    padding: 12px 25px;
    border-radius: 50px;
    text-align: center;
    font-size: 16px;
    font-weight: 600;
    box-shadow: 0 4px 20px rgba(0,0,0,0.3);
    z-index: 1000;
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    transition: var(--transition);
}

.whatsapp-float:hover {
    transform: scale(1.1);
    background-color: #128c7e;
}

.whatsapp-icon {
    width: 24px;
    height: 24px;
}

/* Responsive Breakpoints */

/* Tablet and Small Laptops */
@media (max-width: 1024px) {
    .container {
        max-width: 95%;
    }
    
    .section-title {
        font-size: 2.5rem;
    }
    
    .hero-title {
        font-size: 4rem;
    }
    
    .culture-flex {
        gap: 30px;
        padding: 40px;
    }
}

/* Mobile Devices */
@media (max-width: 768px) {
    header {
        background: rgba(10, 10, 10, 0.95);
        backdrop-filter: blur(10px);
        padding: 15px 0;
        position: fixed;
    }

    .menu-toggle {
        display: flex;
    }

    .nav-links {
        position: fixed;
        right: -100%;
        top: 0;
        height: 100vh;
        width: 100%; /* Use full width to avoid accidental side-gaps */
        max-width: 320px; /* Limit width to be a drawer */
        background: var(--black);
        border-left: 1px solid var(--glass-border);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 25px; /* Reduced gap for tighter grouping */
        padding: 0;
        list-style: none;
        transition: 0.5s cubic-bezier(0.165, 0.84, 0.44, 1);
        z-index: 1000;
        box-shadow: -10px 0 30px rgba(0,0,0,0.8);
    }

    .nav-links.active {
        right: 0;
    }

    .nav-links a {
        font-size: 1.5rem;
    }

    .mobile-only {
        display: block !important;
    }

    .flag-wrapper {
        margin-bottom: 0px; /* Remove margin to align tightly above first item */
        width: 100%;
        text-align: center;
        padding: 0;
        list-style: none;
    }

    .menu-flag {
        display: inline-block;
        width: 80px;
        height: auto;
        filter: drop-shadow(0 4px 10px rgba(0,0,0,0.5));
        border-radius: 4px;
        transition: var(--transition);
        margin: 0 auto;
    }

    .menu-flag:hover {
        transform: scale(1.1) rotate(5deg);
    }

    .hero-title {
        font-size: 3rem;
    }

    .hero-slogan {
        font-size: 1.4rem;
    }

    .section-title {
        font-size: 2.2rem;
    }

    .culture-flex {
        flex-direction: column;
        padding: 30px;
        text-align: center;
    }

    .culture-img {
        width: 100%;
    }

    .section-title.left {
        text-align: center;
    }

    .section-title.left::after {
        left: 50%;
        transform: translateX(-50%);
    }

    .menu-grid {
        grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
        gap: 20px;
    }

    .flyer-img {
        max-width: 100%;
    }

    .footer-content {
        flex-direction: column;
        text-align: center;
        gap: 40px;
    }

    .footer-brand, .footer-contact, .footer-actions {
        width: 100%;
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    .whatsapp-float {
        bottom: 20px;
        right: 20px;
        padding: 10px 20px;
        font-size: 14px;
    }
}

/* Small Phones */
@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }

    .hero-title {
        font-size: 2.5rem;
    }

    .hero-slogan {
        font-size: 1.2rem;
    }

    .hero-btns {
        display: flex;
        flex-direction: column;
        gap: 15px;
        width: 100%;
        padding: 0 20px;
    }

    .btn {
        width: 100%;
        margin: 0 !important;
    }

    .section-title {
        font-size: 2rem;
    }

    .menu-grid {
        grid-template-columns: 1fr;
    }

    .glass {
        padding: 20px;
    }

    .picor-container {
        padding: 20px;
    }

    .picor-meter {
        height: 8px;
    }

    .picor-details {
        grid-template-columns: 1fr;
    }
}

/* --- Additive Patch Classes --- */

/* Salsa Legends Framing */
.artist-frame {
    position: absolute;
    bottom: -20px;
    width: 250px;
    height: auto;
    z-index: 5;
    opacity: 0.8;
    pointer-events: none;
    transition: var(--transition);
}

.artist-frame.hector {
    left: 20px;
}

.artist-frame.willie {
    right: 20px;
}

/* Vinyl Record Animation */
@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.vinyl-record {
    position: absolute;
    width: 150px;
    height: 150px;
    border-radius: 50%;
    z-index: 2;
    pointer-events: none;
    animation: spin 10s linear infinite;
    opacity: 0.5;
    box-shadow: 0 0 20px rgba(0,0,0,0.5);
}

.hero-vinyl {
    bottom: 5%;
    right: 5%;
}

.menu-vinyl {
    bottom: 50px;
    right: -20px;
    top: auto;
    left: auto;
    width: 120px;
    height: 120px;
}

/* Responsive Real Establishment & Menu Placeholder */
.real-location-img, 
.menu-placeholder {
    max-width: 100%;
    height: auto;
    border-radius: 12px;
    border: 1px solid var(--gold);
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    transition: var(--transition);
}

.real-location-img:hover, 
.menu-placeholder:hover {
    transform: scale(1.02);
    box-shadow: 0 15px 40px rgba(212, 175, 55, 0.2);
}

/* Responsive adjustments for new elements */
@media (max-width: 1024px) {
    .artist-frame {
        width: 180px;
    }
}

@media (max-width: 768px) {
    .artist-frame {
        display: none; /* Hide legends on small mobile to avoid clutter */
    }
    .vinyl-record {
        width: 100px;
        height: 100px;
    }
}

/* --- Artist Reveal Animation --- */

.flank-artist {
    position: absolute;
    height: 100vh; /* Spans full viewport height of .hero section */
    width: auto;
    top: 0;
    z-index: 1;
    pointer-events: none;
    transition: transform 1.5s cubic-bezier(0.165, 0.84, 0.44, 1), opacity 1.5s ease;
    filter: grayscale(40%) brightness(0.35) contrast(1.1) drop-shadow(0 0 30px rgba(0,0,0,0.8));
    opacity: 0; /* Initially hidden */
}

.flank-artist.left {
    left: 0;
    transform: translateX(-100%) scale(0.95);
    object-position: left center;
}

.flank-artist.right {
    right: 0;
    transform: translateX(100%) scale(0.95);
    object-position: right center;
}

.flank-artist.visible.left {
    transform: translateX(-20%) scale(1); /* Dramatic 80% reveal for full height */
    opacity: 1;
}

.flank-artist.visible.right {
    transform: translateX(20%) scale(1); /* Dramatic 80% reveal for full height */
    opacity: 1;
}

/* Mobile responsive adjustments */
@media (max-width: 768px) {
    /* Hero Content Mobile Offset */
    .hero-content {
        padding-top: 80px;
        padding-bottom: 20px;
    }

    /* Flanking Artist Mobile Scaling & Positioning */
    .flank-artist {
        height: 55vh !important; /* Scale down significantly on mobile */
        top: 25vh !important;    /* Re-center vertically */
    }

    .flank-artist.visible.left {
        transform: translateX(-35%); /* Brought into view specifically for mobile */
        opacity: 1;              /* Full visibility */
    }
    
    .flank-artist.visible.right {
        transform: translateX(50%); /* Maintaining a balanced but slightly more hidden look for the right */
        opacity: 0.8;              /* Subtle presence */
    }

    /* Decorative Elements Mobile Scaling */
    .decorative-sticker {
        width: 80px;
        margin: 0 auto 15px;
    }

    .fania-sticker {
        height: 2.2rem; /* Matches responsive font-size on mobile */
    }

    .title-with-sticker {
        flex-direction: column;
        text-align: center;
        gap: 10px;
    }
}
#hector-flank {
    height: 90vh; /* 90% size of the standard 100vh artist */
    top: 10vh;    /* Explicitly pushed down by 10% to align with the bottom margin */
    /* This positioning avoids the "disappearing" bug previously encountered */
}

/* --- PDF Menu Section --- */
.pdf-container {
    margin-bottom: 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    border-radius: 10px;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.05);
}

@media (max-width: 768px) {
    .pdf-container {
        display: none; /* Hide embed on mobile for better UX */
    }
}

/* --- Combined Map & Facade Section --- */
.location-flex {
    display: flex;
    gap: 20px;
    padding: 10px;
    align-items: stretch;
}

.map-box {
    flex: 2;
    min-width: 0;
}

.facade-box {
    flex: 1;
    min-width: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.facade-box img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 10px;
}

@media (max-width: 992px) {
    .location-flex {
        flex-direction: column;
    }

    .facade-box {
        height: 300px;
    }
}

/* --- Decorative Stickers --- */
.decorative-sticker {
    width: 120px;
    height: auto;
    margin-bottom: 15px;
    filter: drop-shadow(0 5px 15px rgba(0,0,0,0.3));
    transition: var(--transition);
}

.fania-sticker {
    display: block;
    height: 3rem; /* Matches the section-title font-size exactly */
    width: auto;
}

.decorative-sticker:hover {
    transform: scale(1.1) rotate(5deg);
}

