/* =========================================
   NEGOCIOS Y FÚTBOL - CONSOLIDATED STYLES
   ========================================= 
   
   This file contains all styles specific to the 
   Negocios y Fútbol event page.
   
   Organization:
   1. CSS Variables
   2. Background Icons & Utilities
   3. Hero Section
   4. Info Modules
   5. FAQ Accordion
   6. Agenda Section (Cards & Tabs)
   7. Allies Logos
   8. Navigation Menu (Mobile & Desktop)
   9. Mobile Optimizations
*/

/* =========================================
   1. CSS VARIABLES
   ========================================= */
:root {
    --nyf-green-dark: #0b3519;
    --nyf-green-light: #08923a;
    --nyf-white: #ffffff;
}

/* =========================================
   2. BACKGROUND ICONS & UTILITIES
   ========================================= */

/* Base Background Icon */
.nyf-bg-icon {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 500px;
    height: 500px;
    background-color: var(--nyf-green-dark);
    opacity: 0.08;
    -webkit-mask-size: contain;
    mask-size: contain;
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
    -webkit-mask-position: center;
    mask-position: center;
    z-index: 0;
    pointer-events: none;
}

/* Icon Positioning */
.nyf-bg-icon-left {
    left: -30px;
}

.nyf-bg-icon-right {
    right: -30px;
}

.nyf-bg-icon-tarjeta-contactless {
    right: 20px;
    top: 70%;
}

.nyf-bg-icon-balon {
    left: -30px;
    top: 60%;
    height: 100%;
}

.nyf-bg-icon-jersey {
    right: -130px;
    scale: 1.2;
}

.nyf-bg-icon-cancha {
    right: 0%;
    top: 60%;
    transform: translateX(-50%) translateY(-50%);
    rotate: -20deg;
}

.nyf-bg-icon-globo {
    right: 0px;
    scale: 0.7;
    top: 30%;
    opacity: 0.05;
}

.nyf-bg-icon-NL {
    left: 50px;
    top: 75%;
    scale: 1.3;
}

.nyf-bg-icon-balon-faq {
    right: -50px;
    top: 50%;
    scale: 1.2;
    rotate: 15deg;
}

/* Section Utilities */
.nyf-section-relative {
    position: relative;
    overflow: hidden;
}

.nyf-section-relative .container {
    position: relative;
    z-index: 2;
}

/* Flip Utilities */
.nyf-flip-v {
    transform: translateY(-50%) scaleY(-1) !important;
}

.nyf-flip-h {
    transform: translateY(-50%) scaleX(-1) !important;
}

/* =========================================
   3. HERO SECTION
   ========================================= */

/* Hero Grid Icons Visibility Fix */
.nyf-hero-grid .nyf-icon {
    opacity: 1 !important;
    -webkit-mask-size: contain;
    mask-size: contain;
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
    -webkit-mask-position: center;
    mask-position: center;
    -webkit-mask-mode: alpha;
    mask-mode: alpha;
}

.nyf-hero-grid .nyf-grid-item {
    opacity: 1;
}

.nyf-hero-grid .nyf-item-cancha {
    z-index: -1;
}

/* =========================================
   4. INFO MODULES
   ========================================= */

.nyf-info-card {
    aspect-ratio: 1/1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    transition: all 0.3s ease-in-out;
}

.nyf-info-card:hover {
    background-color: var(--nyf-green-dark) !important;
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
}

/* Force all text elements to white on hover */
.nyf-info-card:hover h5,
.nyf-info-card:hover p,
.nyf-info-card:hover li,
.nyf-info-card:hover i,
.nyf-info-card:hover span,
.nyf-info-card:hover .text-medium-gray,
.nyf-info-card:hover .text-deep-green,
.nyf-info-card:hover .text-dark-gray {
    color: #ffffff !important;
}

/* =========================================
   5. FAQ ACCORDION
   ========================================= */

.nyf-faq-accordion .accordion-item {
    border-color: rgba(0, 0, 0, 0.05);
}

.nyf-faq-accordion .accordion-button:not(.collapsed) {
    color: var(--nyf-green-light);
    background-color: transparent;
    box-shadow: none;
    font-family: "sculpin-variable", sans-serif;
}

.nyf-faq-accordion .accordion-button {
    font-family: "sculpin-variable", sans-serif;
}

.nyf-faq-accordion .accordion-button:focus {
    box-shadow: none;
    border-color: rgba(0, 0, 0, 0.125);
}

.nyf-faq-accordion .accordion-button::after {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%230b3519'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e");
}

.nyf-faq-accordion .accordion-body {
    padding-top: 0;
    padding-bottom: 25px;
}

/* =========================================
   6. AGENDA SECTION
   ========================================= */

/* --- Agenda Cards (Legacy - if still used) --- */
.nyf-agenda-card {
    aspect-ratio: 1/1;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    background-color: #ffffff;
    transition: all 0.3s ease-in-out;
    border: 1px solid #e0e0e0;
    position: relative;
    overflow: hidden;
}

.nyf-agenda-img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 0;
    transition: transform 0.5s ease;
}

.nyf-agenda-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 70%;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.9) 0%, rgba(0, 0, 0, 0.6) 50%, rgba(0, 0, 0, 0) 100%);
    z-index: 1;
    pointer-events: none;
}

.nyf-agenda-content {
    position: relative;
    z-index: 2;
    padding: 30px;
    color: #ffffff;
}

.nyf-agenda-card p,
.nyf-agenda-card h6,
.nyf-agenda-card .text-small {
    color: #ffffff !important;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.nyf-agenda-card:hover {
    border-color: var(--nyf-green-dark);
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.nyf-agenda-card:hover .nyf-agenda-img {
    transform: scale(1.05);
}

/* --- Agenda Tabs (Current Implementation) --- */
.nyf-agenda-tabs {
    display: flex;
    flex-direction: column;
    gap: 10px;
    border-bottom: 0;
}

.nyf-agenda-tab-link {
    display: block;
    padding: 12px;
    background-color: #f7f7f7;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    border-left: 4px solid transparent;
    text-align: left;
    width: 100%;
}

.nyf-agenda-tab-link:hover {
    background-color: #e0e0e0;
}

.nyf-agenda-tab-link.active {
    background-color: #ffffff;
    border-left-color: var(--nyf-green-dark);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.nyf-agenda-tab-time {
    display: block;
    font-size: 13px;
    color: #626262;
    margin-bottom: 4px;
    font-weight: 600;
}

.nyf-agenda-tab-title {
    display: block;
    font-size: 15px;
    font-weight: 700;
    color: #232323;
    line-height: 1.2;
}

.nyf-agenda-tab-link.active .nyf-agenda-tab-time {
    color: var(--nyf-green-dark);
}

.nyf-agenda-tab-link.active .nyf-agenda-tab-title {
    color: var(--nyf-green-dark);
}

/* Content Panel */
.nyf-agenda-pane {
    background-color: #ffffff;
    border-radius: 6px;
    overflow: hidden;
    min-height: 450px;
    animation: fadeIn 0.5s ease;
}

.nyf-agenda-pane-img {
    width: 100%;
    height: 100%;
    min-height: 450px;
    object-fit: cover;
    border-radius: 6px;
}

/* Date/Time Badge */
.nyf-agenda-datetime {
    display: inline-flex;
    flex-direction: column;
    gap: 2px;
    margin-bottom: 15px;
    border-left: 2px solid var(--nyf-green-light);
    padding-left: 8px;
}

.nyf-agenda-datetime-date {
    display: inline-block;
    background-color: transparent;
    color: var(--nyf-green-light);
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    line-height: 1.4;
}

.nyf-agenda-datetime-time {
    display: inline-block;
    background-color: transparent;
    color: var(--nyf-green-light);
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    line-height: 1.4;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* =========================================
   7. ALLIES LOGOS
   ========================================= */

.nyf-sponsor-grid img {
    height: 38px;
    /* Base height (VISA 100%) */
    width: auto;
    filter: grayscale(1) opacity(0.5);
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
}

/* Individual Optical Scaling */
.nyf-logo-ola {
    height: 38px !important;
}

/* 125% */
.nyf-logo-ihcdmx {
    height: 46px !important;
}

/* 120% */
.nyf-logo-visa {
    height: 38px !important;
}

/* 100% */
.nyf-logo-nl {
    height: 58px !important;
}

/* 110% */
.nyf-logo-ihmty {
    height: 44px !important;
}

/* 100% */
.nyf-logo-condusef {
    height: 48px !important;
}

/* 110% */

.nyf-sponsor-grid img:hover {
    filter: grayscale(0) opacity(1);
    transform: translateY(-3px);
}

.nyf-sponsor-grid a {
    display: flex;
    justify-content: center;
    align-items: center;
}

.nyf-sponsor-grid [class*="col-"] {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 10px 15px;
}

/* Specific spacing for mobile stacking */
@media (max-width: 767px) {
    .nyf-sponsor-grid [class*="col-"] {
        padding: 12px 10px;
        /* Reduced vertical spacing */
    }

    /* Mobile Optical Scaling (proportional reduction) */
    .nyf-logo-ola {
        height: 32px !important;
    }

    .nyf-logo-ihcdmx {
        height: 36px !important;
    }

    .nyf-logo-visa {
        height: 30px !important;
    }

    .nyf-logo-nl {
        height: 54px !important;
    }

    .nyf-logo-ihmty {
        height: 36px !important;
    }

    .nyf-logo-condusef {
        height: 40px !important;
    }
}

@media (min-width: 768px) {
    .flex-nowrap-md {
        flex-wrap: nowrap !important;
    }

    .nyf-sponsor-grid {
        gap: 40px;
        /* Generous horizontal spacing */
    }

    .nyf-sponsor-grid [class*="col-"] {
        width: auto !important;
        flex: 0 0 auto !important;
    }
}

/* =========================================
   8. NAVIGATION MENU (MOBILE & DESKTOP)
   ========================================= */

/* Hide Default Navbar */
body.nyf-page nav.navbar {
    background-color: transparent !important;
    border: none !important;
    box-shadow: none !important;
    pointer-events: none;
    height: 0;
    min-height: 0;
    padding: 0;
    overflow: hidden;
}

body.nyf-page nav.navbar .container-lg,
body.nyf-page nav.navbar .center-logo,
body.nyf-page nav.navbar .accordion-menu {
    display: none !important;
}

/* Toggle Button - Circular Floating */
#nyf-menu-toggle {
    display: flex !important;
    position: fixed;
    top: 30px;
    right: 30px;
    z-index: 10001;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background-color: var(--nyf-green-dark);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 6px;
    border: none;
    outline: none;
    cursor: pointer;
    pointer-events: auto;
    padding: 16px;
    transition: transform 0.3s ease, background-color 0.3s ease;
}

#nyf-menu-toggle:active {
    transform: scale(0.95);
}

.nyf-burger-line {
    display: block;
    width: 24px;
    height: 2px;
    background-color: var(--nyf-white);
    border-radius: 2px;
    transition: all 0.3s ease-in-out;
}

/* Toggle Open State */
#nyf-menu-toggle.open .nyf-burger-line:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}

#nyf-menu-toggle.open .nyf-burger-line:nth-child(2) {
    opacity: 0;
}

#nyf-menu-toggle.open .nyf-burger-line:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
}

/* Menu Container */
#nyf-navbar-menu {
    display: flex !important;
    position: fixed;
    z-index: 10000;
    background-color: var(--nyf-green-dark);
    flex-direction: column;
    justify-content: center;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    margin: 0 !important;
    padding: 0 !important;
    max-height: none !important;
    border: none !important;
}

#nyf-navbar-menu.open {
    opacity: 1;
    visibility: visible;
    pointer-events: all;
}

/* Menu Links */
#nyf-navbar-menu .navbar-nav {
    display: flex !important;
    flex-direction: column !important;
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
    list-style: none;
}

#nyf-navbar-menu .navbar-nav li {
    flex: 1;
    width: 100%;
    display: flex;
}

#nyf-navbar-menu .navbar-nav li a {
    color: #ffffff !important;
    font-family: 'futura-pt', sans-serif;
    font-weight: 600;
    font-size: 20px;
    text-decoration: none;
    background: none;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: background-color 0.2s ease, opacity 0.4s ease;
}

#nyf-navbar-menu .navbar-nav li a:hover {
    background-color: var(--nyf-green-light);
}

#nyf-navbar-menu.open .navbar-nav li a {
    opacity: 1;
}

/* Stagger Animations */
#nyf-navbar-menu.open .navbar-nav li:nth-child(1) a {
    transition-delay: 0.1s;
}

#nyf-navbar-menu.open .navbar-nav li:nth-child(2) a {
    transition-delay: 0.15s;
}

#nyf-navbar-menu.open .navbar-nav li:nth-child(3) a {
    transition-delay: 0.2s;
}

#nyf-navbar-menu.open .navbar-nav li:nth-child(4) a {
    transition-delay: 0.25s;
}

/* =========================================
   9. MOBILE OPTIMIZATIONS
   ========================================= */

/* --- DESKTOP (≥992px) --- */
@media (min-width: 992px) {

    /* Desktop Tile Menu */
    #nyf-navbar-menu {
        width: 350px;
        height: 350px;
        top: 30px;
        right: 30px;
        transform-origin: top right;
        transform: scale(0);
        transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease, visibility 0.4s step-end;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    }

    #nyf-navbar-menu.open {
        transform: scale(1);
        transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease, visibility 0.4s step-start;
    }
}

/* --- MOBILE (<992px) --- */
@media (max-width: 991px) {

    /* Background Icons - Mobile Optimizations */
    .nyf-bg-icon-tarjeta-contactless {
        right: -100px;
        top: 80%;
        opacity: 0.04;
        scale: 0.6;
        width: 350px;
        height: 350px;
    }

    .nyf-bg-icon-balon {
        opacity: 0;
    }

    .nyf-bg-icon-jersey {
        right: -200px;
        top: -20%;
        transform: none;
        scale: 0.4;
        opacity: 0.04;
    }

    .nyf-bg-icon-NL {
        right: -200px;
        top: -20%;
        transform: none;
        scale: 0.6;
        opacity: 0.04;
    }

    .nyf-bg-icon-cancha {
        scale: 0.3;
        top: -6%;
        left: -170px;
    }

    .nyf-bg-icon-globo {
        right: -130px;
        top: -10%;
        width: 400px;
        height: 400px;
        scale: 0.4;
        opacity: 0.04;
    }

    /* Transparent Cards on Mobile */
    .nyf-section-relative .bg-white {
        background-color: rgba(255, 255, 255, 0.92) !important;
        backdrop-filter: blur(5px);
    }

    /* Mobile Menu Toggle */
    #nyf-menu-toggle {
        top: 20px;
        right: 20px;
        width: 50px;
        height: 50px;
        background-color: white;
        padding: 13px;
        gap: 5px;
    }

    .nyf-burger-line {
        background-color: var(--nyf-green-dark);
        width: 20px;
    }

    #nyf-menu-toggle.open {
        background-color: white;
        box-shadow: none;
    }

    #nyf-menu-toggle.open .nyf-burger-line {
        background-color: var(--nyf-green-dark);
    }

    /* Mobile Menu Container */
    #nyf-navbar-menu {
        top: 0;
        left: 0;
        right: 0;
        width: 100%;
        height: auto;
        aspect-ratio: 1 / 1;
        background-color: rgba(11, 53, 25, 0.98);
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
        transition: opacity 0.3s ease, visibility 0.3s step-end;
    }

    #nyf-navbar-menu.open {
        transition: opacity 0.3s ease, visibility 0.3s step-start;
    }

    #nyf-navbar-menu .navbar-nav li a {
        font-size: 24px;
    }

    /* Mobile Agenda Navigation Buttons */
    .nyf-agenda-nav-buttons {
        display: flex;
        justify-content: center;
        gap: 15px;
        margin-bottom: 15px;
    }

    .nyf-agenda-nav-btn {
        width: 40px;
        height: 40px;
        border-radius: 50%;
        border: 2px solid var(--nyf-green-dark);
        background-color: white;
        color: var(--nyf-green-dark);
        display: flex;
        align-items: center;
        justify-content: center;
        cursor: pointer;
        transition: all 0.3s ease;
        font-size: 16px;
    }

    .nyf-agenda-nav-btn:active {
        background-color: var(--nyf-green-dark);
        color: white;
        transform: scale(0.95);
    }

    .nyf-agenda-nav-btn:disabled {
        opacity: 0.3;
        cursor: not-allowed;
    }

    /* Agenda Tabs - Horizontal Scroll with Snap */
    .nyf-agenda-tabs {
        flex-direction: row !important;
        overflow-x: auto;
        overflow-y: hidden;
        padding-bottom: 10px;
        scroll-behavior: smooth;
        -webkit-overflow-scrolling: touch;
        gap: 12px;
        margin-bottom: 20px;
        flex-wrap: nowrap !important;

        /* Scroll Snap for carousel effect */
        scroll-snap-type: x mandatory;
        scroll-padding: 0 20px;

        /* Hide scrollbar but keep functionality */
        scrollbar-width: none;
        -ms-overflow-style: none;
    }

    .nyf-agenda-tabs::-webkit-scrollbar {
        display: none;
    }

    .nyf-agenda-tab-link {
        min-width: 85%;
        max-width: 85%;
        flex-shrink: 0;
        border-left: none;
        border-bottom: 4px solid transparent;
        white-space: normal;

        /* Scroll snap alignment */
        scroll-snap-align: start;
        scroll-snap-stop: always;
    }

    .nyf-agenda-tab-link.active {
        border-left: none;
        border-bottom-color: var(--nyf-green-dark);
    }

    .nyf-agenda-pane {
        min-height: auto;
    }

    .nyf-agenda-pane-img {
        display: none !important;
    }
}