/*
 Theme Name:   Mercury Child
 Theme URI:    https://shamlocksports.com
 Description:  Child theme for Mercury - Paid Picks
 Author:       You
 Template:     mercury
 Version:      1.3.2
*/

/* === HOMEPAGE LAYOUT FIX - Override Elementor === */
.shamlock-homepage {
    width: 100% !important;
    max-width: 100% !important;
    position: relative !important;
    top: -4px !important;
}

/* === PAID PICKS CUSTOM CSS (MOBILE + GRID) === */
.paid-picks-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    font-family: 'Helvetica Neue', Arial, sans-serif;
}

.paid-picks-header {
    text-align: center;
    margin-bottom: 30px;
}

.paid-picks-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    margin-bottom: 40px;
}

.pick-card {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    overflow: hidden;
    transition: transform 0.2s;
}

.pick-card:hover {
    transform: translateY(-4px);
}

.pick-card-header {
    background: linear-gradient(135deg, #1a5fb4, #2b7cf6);
    color: white;
    padding: 16px;
    text-align: center;
    font-weight: bold;
    font-size: 1.1em;
}

.pick-card-body {
    padding: 20px;
}

.pick-card-body h4 {
    margin: 0 0 12px;
    color: #1a5fb4;
    font-size: 1.3em;
}

.pick-card-body .teams {
    font-size: 1.1em;
    margin-bottom: 8px;
    color: #333;
}

.pick-card-body .line {
    color: #e74c3c;
    font-weight: bold;
    margin-bottom: 12px;
}

.pick-card-footer {
    background: #f8f9fa;
    padding: 12px 20px;
    font-size: 0.9em;
    color: #555;
    border-top: 1px solid #eee;
}

/* Mobile adjustments */
@media (max-width: 768px) {
    .paid-picks-grid {
        grid-template-columns: 1fr;
    }
    .pick-card-header {
        font-size: 1em;
        padding: 12px;
    }
    .pick-card-body {
        padding: 16px;
    }
}

/* === RESPONSIBLE GAMBLING BANNER === */
.responsible-gambling-banner {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    padding: 1.5rem 0;
    border-top: 3px solid #16a34a;
}

.responsible-gambling-banner .shamlock-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

.gambling-disclaimer {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    color: #e5e7eb;
}

.disclaimer-icon {
    flex-shrink: 0;
    color: #fbbf24;
}

.disclaimer-text {
    flex: 1;
}

.disclaimer-text strong {
    color: #fbbf24;
    font-size: 1rem;
}

.disclaimer-text p {
    margin: 0.5rem 0 0;
    font-size: 0.8rem;
    color: #9ca3af;
    line-height: 1.4;
}

@media (max-width: 768px) {
    .gambling-disclaimer {
        flex-direction: column;
        text-align: center;
    }
}

/* === HIDE "NEW" BADGE ON MENU ITEMS === */
ul.main-menu > li.new > a:before,
.space-mobile-menu-list > ul > li.new:before {
    display: none !important;
}

/* === MENU DROPDOWN ARROW FIX === */
/* Replace broken Font Awesome square with CSS chevron - PRIMARY menu items */
.space-header-menu ul.main-menu li.menu-item-has-children > a:after,
.space-header-2-nav ul.main-menu li.menu-item-has-children > a:after {
    content: '' !important;
    font-family: inherit !important;
    display: inline-block !important;
    width: 6px !important;
    height: 6px !important;
    border-right: 2px solid currentColor !important;
    border-bottom: 2px solid currentColor !important;
    transform: rotate(45deg) !important;
    margin-left: 6px !important;
    margin-bottom: 3px !important;
    vertical-align: middle !important;
    position: relative !important;
    top: -1px !important;
}

/* Replace broken Font Awesome square with CSS chevron - SUBMENU items with children */
/* The broken icon is on the <li>::after, not the <a>::after */
/* This creates the RIGHT ARROW (>) for nested submenus */
.space-header-menu ul.main-menu .sub-menu li.menu-item-has-children:after,
.space-header-2-nav ul.main-menu .sub-menu li.menu-item-has-children:after,
ul.main-menu .sub-menu li.menu-item-has-children:after {
    content: '' !important;
    font-family: inherit !important;
    display: inline-block !important;
    width: 5px !important;
    height: 5px !important;
    border-right: 2px solid currentColor !important;
    border-bottom: 2px solid currentColor !important;
    border-left: none !important;
    border-top: none !important;
    transform: rotate(-45deg) !important;  /* Points right > */
    position: absolute !important;
    right: 10px !important;
    top: 50% !important;
    margin-top: -3px !important;
    background: transparent !important;
}

/* HIDE the down arrow on submenu items - only show the right arrow (>) */
/* The <a>::after has the down chevron which we don't want in submenus */
.space-header-menu ul.main-menu .sub-menu li.menu-item-has-children > a:after,
.space-header-2-nav ul.main-menu .sub-menu li.menu-item-has-children > a:after,
ul.main-menu .sub-menu li.menu-item-has-children > a:after {
    display: none !important;
}

/* Fix for search icon - hide if broken */
.space-header-search i:empty,
.space-header-2-search i:empty {
    display: none;
}

/* === MOBILE: Hide desktop menu links but keep hamburger visible === */
@media (max-width: 991px) {
    /* Hide only the menu list, not the entire container (hamburger is inside container) */
    .space-header-menu ul.main-menu,
    .space-header-2-nav ul.main-menu {
        display: none !important;
        visibility: hidden !important;
    }

    /* Ensure the menu container stays visible for the hamburger */
    .space-header-menu,
    .space-header-2-nav {
        display: block !important;
        visibility: visible !important;
    }

    /* Show mobile hamburger icon */
    .space-mobile-menu-icon {
        display: block !important;
        visibility: visible !important;
        opacity: 1 !important;
        position: absolute !important;
        top: 20px !important;
        right: 15px !important;
        left: auto !important;
        z-index: 9999 !important;
    }
}

/* === HOMEPAGE/ELEMENTOR MENU FIX === */
/* Ensure menu items are visible on all pages including Elementor (desktop only) */
@media (min-width: 992px) {
    .space-header-menu ul.main-menu,
    .space-header-2-nav ul.main-menu {
        display: flex !important;
        visibility: visible !important;
        opacity: 1 !important;
    }
}

@media (min-width: 992px) {
    .space-header-menu ul.main-menu > li,
    .space-header-2-nav ul.main-menu > li {
        display: inline-block !important;
        visibility: visible !important;
        opacity: 1 !important;
    }

    .space-header-menu ul.main-menu > li > a,
    .space-header-2-nav ul.main-menu > li > a {
        display: inline-block !important;
        visibility: visible !important;
        opacity: 1 !important;
        color: inherit !important;
    }

    /* Force menu text to show on Elementor pages */
    .elementor-page .space-header-menu ul.main-menu > li > a,
    .elementor-page .space-header-2-nav ul.main-menu > li > a,
    body.elementor-default .space-header-menu ul.main-menu > li > a,
    body.elementor-default .space-header-2-nav ul.main-menu > li > a {
        font-size: 14px !important;
        visibility: visible !important;
        opacity: 1 !important;
    }
}

/* Homepage specific menu fix - high specificity for Elementor override (desktop only) */
@media (min-width: 992px) {
    .home .space-header-menu ul.main-menu > li > a,
    .home .space-header-2-nav ul.main-menu > li > a,
    .page-id-2 .space-header-menu ul.main-menu > li > a,
    .page-id-2 .space-header-2-nav ul.main-menu > li > a,
    body.home ul.main-menu > li > a,
    body.elementor-page ul.main-menu > li > a,
    body.elementor-page.home ul.main-menu > li > a,
    body.elementor-default ul.main-menu > li > a,
    body.elementor-template-full-width ul.main-menu > li > a,
    body.page-template-template-enhanced-homepage ul.main-menu > li > a,
    body.page-template-template-enhanced-homepage .space-header-menu ul.main-menu > li > a,
    body.page-template-template-enhanced-homepage .space-header-2-nav ul.main-menu > li > a {
        font-size: 14px !important;
        line-height: 1.4 !important;
        visibility: visible !important;
        opacity: 1 !important;
        color: #ffffff !important;
    }

    /* Desktop menu dropdown arrows - CSS chevrons */
    .home .main-menu li.menu-item-has-children > a:after,
    body.home .main-menu li.menu-item-has-children > a:after {
        content: '' !important;
        font-family: inherit !important;
        display: inline-block !important;
        width: 6px !important;
        height: 6px !important;
        border-right: 2px solid currentColor !important;
        border-bottom: 2px solid currentColor !important;
        transform: rotate(45deg) !important;
        margin-left: 6px !important;
        margin-bottom: 3px !important;
    }
}

/* === MOBILE MENU ICON FIXES (Font Awesome 4/5 mismatch fix) === */

/* Mobile menu dropdown arrows - replace Font Awesome with CSS chevrons */
.space-mobile-menu-list ul li.menu-item-has-children:after {
    content: '' !important;
    font-family: inherit !important;
    display: block !important;
    width: 8px !important;
    height: 8px !important;
    border-right: 2px solid currentColor !important;
    border-bottom: 2px solid currentColor !important;
    border-left: none !important;
    border-top: none !important;
    transform: rotate(45deg) !important;
    position: absolute !important;
    top: 12px !important;
    right: 8px !important;
    background: transparent !important;
}

/* Mobile menu expanded state - arrow points up */
.space-mobile-menu-list ul li.menu-item-has-children.space-up:after {
    content: '' !important;
    font-family: inherit !important;
    transform: rotate(-135deg) !important;
    top: 16px !important;
}

/* Search icon fix - replace Font Awesome with CSS magnifying glass */
.space-header-search i.fas.fa-search,
.space-header-search i.fa.fa-search,
.space-header-search i.fa-search {
    display: inline-block !important;
    width: 18px !important;
    height: 18px !important;
    position: relative !important;
}

.space-header-search i.fas.fa-search:before,
.space-header-search i.fa.fa-search:before,
.space-header-search i.fa-search:before {
    content: '' !important;
    display: block !important;
    width: 12px !important;
    height: 12px !important;
    border: 2px solid currentColor !important;
    border-radius: 50% !important;
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    box-sizing: border-box !important;
}

.space-header-search i.fas.fa-search:after,
.space-header-search i.fa.fa-search:after,
.space-header-search i.fa-search:after {
    content: '' !important;
    display: block !important;
    width: 7px !important;
    height: 2px !important;
    background: currentColor !important;
    position: absolute !important;
    bottom: 2px !important;
    right: 0 !important;
    transform: rotate(45deg) !important;
}

/* === MEMBER NAVIGATION & PASSWORD FORMS === */

/* Password reset link on login form */
.shamlock-password-reset {
    text-align: center;
    margin: 15px 0;
}
.shamlock-password-reset a {
    color: #059669;
    text-decoration: none;
}
.shamlock-password-reset a:hover {
    text-decoration: underline;
}

/* Member navigation items in menu */
.menu-item-member a,
.menu-item-logout a {
    color: inherit;
}
.menu-item-logout a {
    opacity: 0.8;
}
.menu-item-logout a:hover {
    opacity: 1;
}

/* Logout link shortcode */
.shamlock-logout-link {
    color: #059669;
    text-decoration: none;
}
.shamlock-logout-link:hover {
    text-decoration: underline;
}

/* Change password form */
.shamlock-change-password-form {
    max-width: 400px;
    margin: 0 auto;
    padding: 20px;
}
.shamlock-change-password-form p {
    margin-bottom: 15px;
}
.shamlock-change-password-form label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    color: #374151;
}
.shamlock-change-password-form input[type="password"] {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 16px;
}
.shamlock-change-password-form input[type="password"]:focus {
    outline: none;
    border-color: #059669;
    box-shadow: 0 0 0 3px rgba(5, 150, 105, 0.1);
}
.shamlock-change-password-form .shamlock-btn {
    width: 100%;
    padding: 12px;
    background: #059669;
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}
.shamlock-change-password-form .shamlock-btn:hover {
    background: #047857;
}

/* Form messages */
.shamlock-message {
    padding: 12px 16px;
    border-radius: 6px;
    margin-bottom: 20px;
    font-weight: 500;
}
.shamlock-message.success {
    background: #d1fae5;
    color: #065f46;
    border: 1px solid #a7f3d0;
}
.shamlock-message.error {
    background: #fee2e2;
    color: #991b1b;
    border: 1px solid #fecaca;
}

/* === HEADER MENU AUTH ITEMS === */

/* Mobile menu logout styling */
.space-mobile-menu .menu-item-logout a {
    color: #9ca3af !important;
    text-align: center;
}

/* === SEARCH ICON POSITIONING FIX === */
/* Ensure search icon stays aligned with menu regardless of menu content changes */
@media (min-width: 992px) {
    .space-header-menu {
        position: relative;
    }

    .space-header-search {
        position: absolute !important;
        top: 30px !important;
        bottom: auto !important;
        right: 15px !important;
        transform: none !important;
    }
}

/* On smaller desktop screens where Mercury moves the icon */
@media (max-width: 1199px) and (min-width: 992px) {
    .space-header-search {
        right: 55px !important;
    }
}

/* ============================================
   PMPRO CHECKOUT PAGE STYLING
   ============================================ */

/* Hide sidebar on checkout page - Mercury theme classes */
body.pmpro-checkout .space-sidebar-section {
    display: none !important;
}

/* Make content full width on checkout - Mercury theme classes */
body.pmpro-checkout .space-content-section {
    width: 100% !important;
    max-width: 100% !important;
}

/* Checkout page container - center the form */
body.pmpro-checkout .space-page-content-wrap {
    max-width: 640px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Hide the title box entirely - form has its own context */
body.pmpro-checkout .space-title-box {
    display: none;
}

/* Add simple header above form */
body.pmpro-checkout .space-page-section {
    padding-top: 40px;
}

/* Form sections styling */
#pmpro_form .pmpro_checkout-fields,
#pmpro_form fieldset,
#pmpro_form .pmpro_checkout-field {
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 20px;
    background: #fff;
}

#pmpro_form legend,
#pmpro_form h3 {
    font-size: 1.125rem;
    font-weight: 600;
    color: #0f4c2e;
    padding: 0 8px;
    margin-bottom: 16px;
}

/* Membership level info */
#pmpro_level_cost,
.pmpro_checkout-field-level_cost {
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    border-radius: 8px;
    padding: 16px;
    margin-bottom: 20px;
}

#pmpro_level_cost strong,
.pmpro_level_name {
    color: #16a34a;
    font-weight: 600;
}

/* Input fields */
#pmpro_form input[type="text"],
#pmpro_form input[type="email"],
#pmpro_form input[type="password"],
#pmpro_form input[type="tel"],
#pmpro_form select,
#pmpro_form textarea {
    width: 100%;
    padding: 12px 16px;
    font-size: 1rem;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    box-sizing: border-box;
}

#pmpro_form input:focus,
#pmpro_form select:focus,
#pmpro_form textarea:focus {
    outline: none;
    border-color: #16a34a;
    box-shadow: 0 0 0 3px rgba(22, 163, 74, 0.1);
}

#pmpro_form label {
    display: block;
    font-size: 0.875rem;
    font-weight: 600;
    color: #374151;
    margin-bottom: 6px;
}

/* Discount code section */
#pmpro_form .pmpro_checkout-field-discount_code {
    background: #f9fafb;
}

/* Apply discount button - green */
#discount_code_button {
    background: #16a34a !important;
    color: #fff !important;
}

#discount_code_button:hover {
    background: #15803d !important;
}

/* Payment info section - Stripe elements */
#pmpro_form .StripeElement,
#pmpro_form .pmpro_payment-card-number,
#pmpro_form .pmpro_payment-expiration,
#pmpro_form .pmpro_payment-cvc {
    padding: 12px 16px;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    background: #fff;
}

/* Terms checkbox */
#pmpro_form .pmpro_checkout-field-tos {
    background: transparent;
    border: none;
    padding: 0;
}

#pmpro_form .pmpro_checkout-field-tos label {
    display: inline;
    font-weight: normal;
}

/* Show Password toggle - HIDDEN */
.pmpro_form_field-password-toggle,
button.pmpro_btn-password-toggle {
    display: none !important;
}

/* Submit button - gold */
#pmpro_btn-submit {
    background: #d6b25e !important;
    color: #0f4c2e !important;
}

#pmpro_btn-submit:hover {
    background: #c5a04d !important;
}

/* Already have account link */
#pmpro_form .pmpro_checkout-field-login a,
.pmpro_checkout-field-login a {
    color: #16a34a;
    font-weight: 600;
}

/* Error messages */
#pmpro_form .pmpro_message,
.pmpro_error {
    padding: 12px 16px;
    border-radius: 8px;
    margin-bottom: 20px;
}

#pmpro_form .pmpro_error,
.pmpro_message.pmpro_error {
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #dc2626;
}

#pmpro_form .pmpro_success,
.pmpro_message.pmpro_success {
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    color: #16a34a;
}

/* Mobile adjustments */
@media (max-width: 600px) {
    #pmpro_form fieldset,
    #pmpro_form .pmpro_checkout-field {
        padding: 16px;
    }

    .pmpro-checkout .space-page-title-box {
        padding: 30px 16px 16px;
    }
}

/* === DASHBOARD NAV MENU FIX === */
/* Ensure header dropdown menus appear above dashboard content */
.space-header-wrap {
    z-index: 1000 !important;
}

.space-header-menu ul.main-menu > li > ul.sub-menu,
.space-header-menu ul.main-menu > li > ul.sub-menu ul.sub-menu {
    z-index: 1001 !important;
}

/* Dashboard content should be below header */
.shamlock-dashboard-wrapper {
    position: relative;
    z-index: 1;
}

/* === SHAMLOCK FOOTER === */
.shamlock-footer {
    background: #1a1a1a;
    padding: 40px 0 0;
}

.shamlock-footer-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Footer Navigation */
.shamlock-footer-nav {
    display: flex;
    justify-content: center;
    gap: 60px;
    padding-bottom: 30px;
    border-bottom: 1px solid #333;
}

.footer-nav-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.footer-nav-label {
    font-size: 0.75rem;
    font-weight: 600;
    color: #16a34a;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
}

.footer-nav-group a {
    font-size: 0.9rem;
    color: #9a9a9a;
    text-decoration: none;
    transition: color 0.2s;
}

.footer-nav-group a:hover {
    color: #ffffff;
}

/* Discord link - brand color on hover */
.footer-nav-group a[href*="discord"] {
    display: flex;
    align-items: center;
    gap: 6px;
}

.footer-nav-group a[href*="discord"]:hover {
    color: #5865F2;
}

.footer-nav-group a[href*="discord"] i {
    font-size: 1rem;
}

/* Footer Bottom Bar */
.shamlock-footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 0;
}

.footer-copyright {
    font-size: 0.8rem;
    color: #666;
}

.footer-copyright a {
    color: #888;
    text-decoration: none;
}

.footer-copyright a:hover {
    color: #16a34a;
}

.footer-veteran {
    font-size: 0.85rem;
    color: #9a9a9a;
}

/* Tablet Footer - 2x2 grid layout */
@media (max-width: 1024px) and (min-width: 601px) {
    .shamlock-footer-nav {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 30px 40px;
        justify-items: center;
        text-align: center;
    }

    .footer-nav-group {
        align-items: center;
    }

    .shamlock-footer-bottom {
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }
}

/* Mobile Footer - single column */
@media (max-width: 600px) {
    .shamlock-footer-nav {
        flex-direction: column;
        align-items: center;
        gap: 30px;
        text-align: center;
    }

    .footer-nav-group {
        align-items: center;
    }

    .shamlock-footer-bottom {
        flex-direction: column;
        gap: 12px;
        text-align: center;
    }
}

/* Hide old footer elements */
.space-footer-copy {
    display: none !important;
}
