/*
 * Author: Milan
 * Description: Premium FSE Theme for Milica Kostic Coaching
 * Version: 1.1.13
 * Requires at least: 6.04
 * Tested up to: 6.4
 * Custom CSS for Milica Kostic Theme
 * Adds glassmorphism effects, custom styling for the Details block, and scroll reveal animations.
 */

/* ==========================================================================
   Core Theme Adjustments */
html, body {
    overflow-x: hidden;
    width: 100%;
}

main#wp--skip-link--target,
main.wp-block-group {
    margin-top: 0 !important;
}

/* Details Block (Accordion) Styling */
.wp-block-details {
    background-color: var(--wp--preset--color--base);
    border: 2px solid var(--wp--preset--color--primary);
    border-radius: 8px;
    padding: 1rem 1.5rem;
    margin-bottom: 1.5rem !important;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    transition: box-shadow 0.3s ease;
}

.wp-block-details:hover {
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.08);
}

.wp-block-details summary {
    font-weight: 700;
    font-size: 1.25rem;
    cursor: pointer;
    list-style: none; /* Hide default arrow */
    position: relative;
    padding-right: 2rem;
    outline: none;
}

.wp-block-details summary::-webkit-details-marker {
    display: none;
}

.wp-block-details summary::after {
    content: '+';
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.5rem;
    color: var(--wp--preset--color--contrast);
    transition: transform 0.3s ease;
}

.wp-block-details[open] summary::after {
    content: '−';
    transform: translateY(-50%) rotate(180deg);
}

.wp-block-details.premium-card summary {
    font-family: var(--wp--preset--font-family--open-sans) !important;
    font-size: 1.4rem !important;
    font-weight: 600 !important;
    margin-bottom: 1rem !important;
}

/* Glassmorphism Buttons */
.is-style-milicakostic-glass {
    background: rgba(229, 228, 226, 0.6); /* Pastellgrau with opacity */
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    color: var(--wp--preset--color--contrast) !important;
    transition: all 0.3s ease;
    border-radius: 30px;
    font-weight: 600;
}

.is-style-milicakostic-glass:hover {
    background: rgba(229, 228, 226, 0.9);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
    transform: translateY(-2px);
}

.is-style-milicakostic-glass a {
    color: var(--wp--preset--color--contrast) !important;
    text-decoration: none;
}

/* Scroll Reveal Animation Classes */
.reveal-text {
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.js-reveal-enabled .reveal-text {
    opacity: 0;
    transform: translateY(20px);
}

.js-reveal-enabled .reveal-text.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* Hero Image Custom Styling */
.hero-image-styled {
    position: relative;
}

/* Uklonjen stari žuti kvadrat */
.hero-image-styled::before {
    display: none;
}

/* Museum Gallery / High-End Corporate Frame */
.hero-image-styled img {
    border-radius: 4px;
    border: 8px solid rgba(255, 255, 255, 1);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.5s ease;
}

.hero-image-styled img:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

/* Separator Styling */
hr.wp-block-separator {
    border-top: 2px solid var(--wp--preset--color--primary);
    opacity: 0.5;
    margin: 2rem auto;
}

/* Premium Glassmorphism Header */
header.wp-block-template-part {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(255, 255, 255, 0.85); 
    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px);
    border-bottom: 1px solid rgba(230, 230, 250, 0.6); 
    box-shadow: 0 10px 40px -10px rgba(149, 117, 205, 0.15); /* Clean purple shadow instead of dirty gray/yellowish */
    transition: all 0.3s ease;
}

/* Premium Navigation Links */
.wp-block-navigation-item__content {
    color: #232222 !important; 
    transition: color 0.3s ease, transform 0.3s ease;
}
.wp-block-navigation-item__content:hover {
    color: #7e57c2 !important; /* Darker purple for visibility */
    transform: translateY(-1px);
}

/* Premium Background Gradients - Opcija 1 (Geometric Bauhaus) */
/* Premium Asymmetric Polygon Background */
.has-polygon-bg {
    position: relative;
    z-index: 1;
    overflow: hidden;
}

/* Premium Header Styles */
.header-logo-group {
    gap: 12px;
}
.header-text-group {
    gap: 0px;
}
.header-logo-title {
    color: #836aaf !important;
    font-family: var(--wp--preset--font-family--open-sans) !important;
    font-size: clamp(1.1rem, 3vw, 1.4rem) !important;
    font-weight: 600 !important;
    letter-spacing: 2px !important;
    text-transform: uppercase !important;
    margin: 0 !important;
    line-height: 1 !important;
    white-space: nowrap !important;
}
.header-logo-title a, .header-logo-subtitle a {
    text-decoration: none !important;
    color: inherit !important;
}
.header-logo-subtitle {
    color: #000000 !important;
    font-family: var(--wp--preset--font-family--open-sans) !important;
    font-size: clamp(0.55rem, 1.5vw, 0.65rem) !important;
    font-weight: 500 !important;
    letter-spacing: 1px !important;
    text-transform: uppercase !important;
    margin: 5px 0 0 0 !important;
    line-height: 1 !important;
    white-space: nowrap !important;
}
.header-nav-menu {
    font-size: 0.9rem !important;
    font-weight: 500 !important;
    text-transform: uppercase !important;
    letter-spacing: 1.5px !important;
}

/* Premium Universal Pill Buttons */
.premium-pill-btn .wp-block-button__link {
    background-color: var(--wp--preset--color--tertiary) !important;
    color: #000 !important;
    font-weight: 600 !important;
    border-radius: 50px !important;
    padding: 1rem 2.5rem !important;
    transition: all 0.3s ease !important;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05) !important;
}
.premium-pill-btn .wp-block-button__link:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 10px 20px rgba(0,0,0,0.1) !important;
    background-color: #fff176 !important; /* Slightly darker yellow on hover */
}

/* Premium Footer */
.premium-footer {
    background-color: #f7f7fc !important;
    border-top: 1px solid rgba(149, 117, 205, 0.2);
    padding-top: 2.5rem !important;
    padding-bottom: 1.5rem !important;
    padding-left: max(2rem, 5vw) !important;
    padding-right: max(2rem, 5vw) !important;
}

.footer-brand-group {
    gap: 0px;
    margin-bottom: 1.5rem;
}

.footer-logo-text {
    font-family: var(--wp--preset--font-family--open-sans) !important;
    font-size: 1.5rem !important;
    font-weight: 600 !important;
    letter-spacing: 3px !important;
    text-transform: uppercase !important;
    margin: 10px 0 0 0 !important;
    line-height: 1 !important;
}

.footer-logo-text a, .footer-logo-subtext a {
    text-decoration: none !important;
    color: inherit !important;
}

.footer-logo-subtext {
    color: #4b5563 !important;
    font-family: var(--wp--preset--font-family--open-sans) !important;
    font-size: 0.7rem !important;
    font-weight: 500 !important;
    letter-spacing: 1.5px !important;
    text-transform: uppercase !important;
    margin: 5px 0 0 0 !important;
    line-height: 1 !important;
}

.footer-quote {
    font-size: 0.95rem !important;
    font-style: italic !important;
    margin-bottom: 2rem !important;
}

.footer-contact-info {
    font-size: 0.95rem !important;
    line-height: 1.6 !important;
}

.footer-heading {
    margin-bottom: 1.5rem !important;
    font-family: var(--wp--preset--font-family--open-sans) !important;
    font-size: 1.2rem !important;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.footer-nav {
    gap: 0.8rem !important;
    font-size: 0.95rem !important;
}

.footer-cta-text {
    font-size: 0.95rem !important;
    line-height: 1.6 !important;
}

.footer-buttons {
    margin-top: 1.5rem !important;
    margin-bottom: 2rem !important;
}

.footer-btn .wp-block-button__link {
    background-color: var(--wp--preset--color--primary) !important;
    color: #000 !important;
    font-weight: 600 !important;
    border-radius: 50px !important;
    padding: 0.8rem 2rem !important;
}

.footer-separator {
    margin-top: 2rem !important;
    margin-bottom: 1.5rem !important;
    opacity: 0.2 !important;
    border-top: 2px solid var(--wp--preset--color--primary) !important;
}

.footer-legal-text {
    color: #6b7280 !important;
    font-size: 0.75rem !important;
    line-height: 1.5 !important;
}

.footer-copyright {
    font-size: 0.85rem !important;
    margin-top: 1rem !important;
}

.has-polygon-bg::before {
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    width: 60%;
    height: 100%;
    /* Angled glass/light polygon starting from top-middle to bottom-left */
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.4) 0%, rgba(255, 255, 255, 0.05) 100%);
    clip-path: polygon(30% 0, 100% 0, 100% 100%, 0% 100%);
    z-index: -1;
}

/* Premium Card Styling for Patterns */
.premium-card {
    background: linear-gradient(135deg, rgba(255, 255, 255, 1) 0%, rgba(248, 248, 250, 1) 100%) !important;
    box-shadow: 0 20px 50px rgba(0,0,0,0.06), 0 2px 10px rgba(0,0,0,0.03);
    border: 2px solid var(--wp--preset--color--primary);
    backdrop-filter: blur(10px);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.premium-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 25px 60px rgba(0,0,0,0.08), 0 5px 15px rgba(0,0,0,0.04);
}

/* Footer Styling */
footer.wp-block-template-part {
    background: var(--wp--preset--color--base);
    border-top: 1px solid var(--wp--preset--color--secondary);
}

/* Remove footer top border specifically on the homepage to seamlessly blend with the hero section */
.home footer.wp-block-template-part,
.front-page footer.wp-block-template-part,
.home .premium-footer,
.front-page .premium-footer {
    border-top: none !important;
    margin-top: 0 !important;
}

/* Destroy WordPress default block gap on homepage to prevent white line before footer */
.home .wp-site-blocks > * + *,
.front-page .wp-site-blocks > * + * {
    margin-block-start: 0 !important;
    margin-top: 0 !important;
}

.footer-heading {
    color: #333333 !important;
    font-size: 0.85rem !important;
    letter-spacing: 2px !important;
    text-transform: uppercase !important;
}

/* ==========================================================================
   Premium Custom Mobile Menu
   ========================================================================== */

/* Hide default Gutenberg menu entirely on mobile */
@media (max-width: 781px) {
    .header-nav-menu,
    .wp-block-navigation__responsive-container-open,
    .wp-block-navigation__responsive-container {
        display: none !important;
    }
}

/* Show custom hamburger only on mobile */
.custom-mobile-menu-toggle {
    display: none;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 10px;
    margin: 0;
    z-index: 100001; /* Above overlay */
    -webkit-tap-highlight-color: transparent;
    outline: none;
}

@media (max-width: 781px) {
    .header-inner-group {
        display: grid !important;
        grid-template-columns: 1fr auto 1fr !important;
        align-items: center !important;
        padding-left: 1rem !important;
        padding-right: 1rem !important;
    }
    
    .custom-mobile-menu-toggle {
        display: flex;
        align-items: center;
        justify-content: center;
        justify-self: end !important;
        flex-shrink: 0 !important;
        margin-left: 0 !important;
    }
    
    .wp-block-site-logo {
        justify-self: start !important;
    }
    
    .wp-block-site-logo img {
        width: 90px !important;
    }
    
    .header-logo-group {
        display: contents !important; /* Makes logo and text direct grid children */
    }
    
    .header-text-group {
        justify-self: center !important;
        text-align: center !important;
    }
    
    .header-logo-title {
        font-size: 1.1rem !important;
        letter-spacing: 1px !important;
    }
    
    .header-logo-subtitle {
        font-size: 0.55rem !important;
        letter-spacing: 0.5px !important;
        white-space: normal !important;
        line-height: 1.2 !important;
    }

    /* Fix narrow content on mobile for all patterns */
    .premium-card {
        padding: 1.5rem !important;
    }
    .wp-block-details.premium-card {
        padding: 1.25rem !important;
    }
}

/* Hamburger Icon Animation */
.hamburger-box {
    width: 26px;
    height: 20px;
    display: inline-block;
    position: relative;
    margin-right: 0.5rem; /* Ensure it is separated from the right edge */
}

.hamburger-inner, .hamburger-inner::before, .hamburger-inner::after {
    width: 26px;
    height: 1.5px;
    background-color: var(--wp--preset--color--contrast, #333);
    position: absolute;
    transition: transform 0.3s ease, opacity 0.3s ease, background-color 0.3s ease;
    border-radius: 4px;
}

.hamburger-inner {
    top: 50%;
    transform: translateY(-50%);
}

.hamburger-inner::before {
    content: "";
    top: -8px;
}

.hamburger-inner::after {
    content: "";
    bottom: -8px;
}

/* Hamburger active state */
.custom-mobile-menu-open .custom-mobile-menu-toggle .hamburger-inner {
    background-color: transparent;
}

.custom-mobile-menu-open .custom-mobile-menu-toggle .hamburger-inner::before {
    transform: translateY(8px) rotate(45deg);
    background-color: #333;
}

.custom-mobile-menu-open .custom-mobile-menu-toggle .hamburger-inner::after {
    transform: translateY(-8px) rotate(-45deg);
    background-color: #333;
}

/* Overlay Structure */
.custom-mobile-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    z-index: 100000;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.4s ease, visibility 0.4s ease;
}

.custom-mobile-menu-open .custom-mobile-overlay {
    opacity: 1;
    visibility: visible;
}

/* Elevate header above overlay when menu is open */
.custom-mobile-menu-open header.wp-block-template-part {
    z-index: 100002 !important;
}

/* Ensure padding on mobile header so logo and hamburger don't touch edges */
@media (max-width: 781px) {
    header.wp-block-template-part .wp-block-group.alignfull {
        padding-left: 0 !important;
        padding-right: 0 !important;
    }
    
    .header-inner-group {
        padding-left: 1rem !important;
        padding-right: 1.25rem !important;
    }
}

/* Body lock */
body.custom-mobile-menu-open {
    overflow: hidden;
}

/* Nav List within Overlay */
.custom-mobile-nav-list {
    list-style: none !important;
    padding: 0 !important;
    margin: 0 !important;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2rem;
}

/* Remove bullets specifically */
.custom-mobile-nav-list li,
.custom-mobile-nav-item {
    list-style-type: none !important;
    list-style: none !important;
    margin-left: 0 !important;
    padding: 0 !important;
}

.custom-mobile-nav-list li::before,
.custom-mobile-nav-item::before {
    display: none !important;
}

/* Premium Links Styling */
.custom-mobile-nav-list a {
    font-size: 2.5rem;
    font-family: var(--wp--preset--font-family--open-sans, "open-sans Display", serif);
    font-weight: 500;
    color: #222 !important;
    text-decoration: none !important;
    transition: color 0.3s ease, transform 0.3s ease;
    display: block;
    text-align: center;
    padding: 0.5rem 1rem;
    -webkit-tap-highlight-color: transparent;
    outline: none;
}

.custom-mobile-nav-list a:hover {
    color: var(--wp--preset--color--primary, #9575cd) !important;
    transform: scale(1.05);
}

/* Make logo larger on mobile */
@media (max-width: 781px) {
    .wp-block-site-logo img {
        width: 80px !important; /* Reverted to a reasonable size so it fits */
        height: auto !important;
    }
}

/* Staggered Animations for Links */
.custom-mobile-nav-list li {
    opacity: 0;
    transform: translateY(30px);
    width: 100%;
    text-align: center;
    display: flex;
    justify-content: center;
}

.custom-mobile-nav-list li.animate-in {
    animation: fadeInUpStaggered 0.5s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    animation-delay: calc(var(--item-index) * 0.1s + 0.2s);
}

.custom-mobile-nav-list li.animate-out {
    animation: fadeOutDownStaggered 0.3s ease forwards;
}

@keyframes fadeInUpStaggered {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeOutDownStaggered {
    from {
        opacity: 1;
        transform: translateY(0);
    }
    to {
        opacity: 0;
        transform: translateY(30px);
    }
}
/* ==========================================================================
   Premium Cookie Banner
   ========================================================================== */

.premium-cookie-banner {
    position: fixed;
    bottom: -100%;
    left: 50%;
    transform: translateX(-50%);
    width: 90%;
    max-width: 600px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(230, 230, 250, 0.8);
    box-shadow: 0 20px 50px rgba(0,0,0,0.15);
    border-radius: 12px;
    padding: 2rem;
    z-index: 100005;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    transition: bottom 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.premium-cookie-banner.is-visible {
    bottom: 2rem;
}

.cookie-content {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.cookie-title {
    font-family: var(--wp--preset--font-family--open-sans, "open-sans Display", serif);
    font-size: 1.3rem;
    font-weight: 600;
    color: #333;
    margin: 0;
}

.cookie-text {
    font-size: 0.9rem;
    color: #555;
    line-height: 1.5;
    margin: 0;
}

.cookie-text a {
    color: #7e57c2; /* Darker purple for readability */
    text-decoration: underline;
    font-weight: 600;
    transition: color 0.3s ease;
}

.cookie-text a:hover {
    color: #5e35b1; /* Even darker on hover */
}

.cookie-actions {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
}

.cookie-btn {
    border: none;
    border-radius: 50px;
    padding: 0.7rem 1.5rem;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.cookie-btn-essential {
    background-color: transparent;
    color: #666;
    border: 1px solid #ccc;
}

.cookie-btn-essential:hover {
    background-color: #f5f5f5;
    color: #333;
}

.cookie-btn-accept {
    background-color: var(--wp--preset--color--primary, #9575cd);
    color: #000;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.cookie-btn-accept:hover {
    background-color: #d1c4e9;
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0,0,0,0.15);
}

@media (max-width: 600px) {
    .premium-cookie-banner {
        width: calc(100% - 2rem);
        bottom: -100%;
        border-radius: 12px;
        padding: 1.5rem;
        left: 50%;
        transform: translateX(-50%);
    }
    
    .premium-cookie-banner.is-visible {
        bottom: 1rem;
    }
    
    .cookie-actions {
        flex-direction: column;
        width: 100%;
    }
    
    .cookie-btn {
        width: 100%;
    }
}

/* Fix long words overflowing containers (e.g. German compound nouns or email addresses) */
p, h1, h2, h3, h4, h5, h6, li, a {
    word-wrap: break-word;
    overflow-wrap: break-word;
    -webkit-hyphens: auto;
    -ms-hyphens: auto;
    hyphens: auto;
}

/* ==========================================================================
   Tutor LMS & WooCommerce Cart / Checkout Premium Styling
   ========================================================================== */

/* Cart and Checkout Page Wrappers */
.woocommerce-cart .woocommerce,
.woocommerce-checkout .woocommerce,
.tutor-cart-page .tutor-cart-page-wrapper,
.tutor-checkout-page .tutor-checkout-page-wrapper {
    background: linear-gradient(135deg, rgba(255, 255, 255, 1) 0%, rgba(248, 248, 250, 1) 100%);
    border-radius: 12px;
    box-shadow: 0 20px 50px rgba(0,0,0,0.06), 0 2px 10px rgba(0,0,0,0.03);
    border: 1px solid rgba(149, 117, 205, 0.2);
    padding: max(1.5rem, 3vw);
    margin: 2rem auto;
    width: 100%;
    box-sizing: border-box;
}

/* Disable hyphenation for cart and checkout headings */
.tutor-cart-page h1, .tutor-cart-page h2, .tutor-cart-page h3, .tutor-cart-page h4,
.tutor-checkout-page h1, .tutor-checkout-page h2, .tutor-checkout-page h3, .tutor-checkout-page h4,
.woocommerce-cart h1, .woocommerce-cart h2, .woocommerce-cart h3, .woocommerce-cart h4,
.woocommerce-checkout h1, .woocommerce-checkout h2, .woocommerce-checkout h3, .woocommerce-checkout h4 {
    -webkit-hyphens: none !important;
    -ms-hyphens: none !important;
    hyphens: none !important;
    word-wrap: normal !important;
    overflow-wrap: normal !important;
}

/* Headings */
.woocommerce-cart h2,
.woocommerce-checkout h3,
#order_review_heading,
.tutor-cart-title {
    font-family: var(--wp--preset--font-family--open-sans, "open-sans Display", serif) !important;
    color: var(--wp--preset--color--primary, #9575cd) !important;
    border-bottom: 2px solid rgba(149, 117, 205, 0.2);
    padding-bottom: 1rem;
    margin-bottom: 1.5rem;
}

/* Tables (Cart / Checkout) */
.woocommerce-cart table.shop_table,
.woocommerce-checkout table.shop_table,
.tutor-cart-table {
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid rgba(149, 117, 205, 0.2);
    box-shadow: 0 5px 15px rgba(0,0,0,0.02);
}

.woocommerce-cart table.shop_table th,
.woocommerce-checkout table.shop_table th,
.tutor-cart-table th {
    background-color: #f7f7fc;
    color: #232222;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 1rem;
}

.woocommerce-cart table.shop_table td,
.woocommerce-checkout table.shop_table td,
.tutor-cart-table td {
    padding: 1rem;
    border-top: 1px solid rgba(149, 117, 205, 0.1);
}

/* Inputs and Forms */
.woocommerce-checkout .form-row input.input-text,
.woocommerce-checkout .form-row textarea,
.tutor-form-group input,
.tutor-form-group textarea,
.select2-container--default .select2-selection--single {
    border-radius: 8px !important;
    border: 1px solid rgba(149, 117, 205, 0.3) !important;
    padding: 0.8rem !important;
    background-color: #fff !important;
    transition: all 0.3s ease !important;
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.02);
}

.woocommerce-checkout .form-row input.input-text:focus,
.woocommerce-checkout .form-row textarea:focus,
.tutor-form-group input:focus,
.tutor-form-group textarea:focus,
.select2-container--default.select2-container--open .select2-selection--single {
    border-color: var(--wp--preset--color--primary, #9575cd) !important;
    box-shadow: 0 0 0 3px rgba(149, 117, 205, 0.2) !important;
    outline: none !important;
}

/* Buttons */
.woocommerce-cart .wc-proceed-to-checkout a.checkout-button,
.woocommerce-checkout #place_order,
.tutor-btn-primary,
.tutor-cart-checkout-btn,
button[name="apply_coupon"],
button[name="update_cart"] {
    background-color: var(--wp--preset--color--primary, #9575cd) !important;
    color: #000 !important;
    font-weight: 600 !important;
    border-radius: 50px !important;
    padding: 0.8rem 1rem !important;
    transition: all 0.3s ease !important;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1) !important;
    text-transform: uppercase;
    letter-spacing: 1px;
    border: none !important;
    display: inline-block;
    text-align: center;
    white-space: nowrap !important;
    width: 100% !important;
    box-sizing: border-box !important;
    font-size: clamp(0.75rem, 2vw, 0.9rem) !important;
}

.woocommerce-cart .wc-proceed-to-checkout a.checkout-button:hover,
.woocommerce-checkout #place_order:hover,
.tutor-btn-primary:hover,
.tutor-cart-checkout-btn:hover,
button[name="apply_coupon"]:hover,
button[name="update_cart"]:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 10px 20px rgba(0,0,0,0.15) !important;
    background-color: #d1c4e9 !important;
}

/* Payment Section Box */
#payment.woocommerce-checkout-payment {
    background: #f7f7fc;
    border-radius: 12px;
    padding: 1.5rem;
    border: 1px solid rgba(149, 117, 205, 0.2);
    box-shadow: 0 5px 15px rgba(0,0,0,0.03);
}

#payment ul.payment_methods {
    border-bottom: 1px solid rgba(149, 117, 205, 0.2);
    padding-bottom: 1rem;
    margin-bottom: 1rem;
}



/* Cart Summary Spacing & Layout Fix */
.tutor-cart-summery {
    background: transparent !important;
    border: none !important;
    padding: 0 !important;
    box-shadow: none !important;
}

.tutor-cart-summery-item {
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    padding: 1.2rem 0 !important;
    border-bottom: 1px solid rgba(149, 117, 205, 0.1) !important;
    width: 100% !important;
}

.tutor-cart-summery-bottom .tutor-cart-summery-item {
    border-bottom: none !important;
    padding-bottom: 2rem !important;
}

.tutor-cart-summery-item div:first-child {
    font-weight: 600 !important;
    color: #232222 !important;
}

.tutor-cart-summery-item div:last-child {
    font-weight: 800 !important;
    color: #5e35b1 !important; /* Deep, highly visible purple */
    font-size: 1.25rem !important;
    padding-left: 15px !important;
    white-space: nowrap !important;
}

/* Fix narrow column issues on Cart */
@media (min-width: 992px) {
    .tutor-cart-page-wrapper .tutor-row {
        display: flex !important;
        flex-wrap: nowrap !important;
        gap: 4% !important;
        align-items: flex-start !important;
        margin: 0 !important; /* Fix negative margin bleed */
        width: 100% !important;
    }
    .tutor-cart-page-wrapper .tutor-col-lg-8 {
        width: 58% !important;
        flex: 0 0 58% !important;
        max-width: 58% !important;
        padding: 0 !important;
    }
    .tutor-cart-page-wrapper .tutor-col-lg-4 {
        width: 38% !important;
        flex: 0 0 38% !important;
        max-width: 38% !important;
        padding: 0 !important;
    }
}

/* Mobile Optimizations for Cart, Checkout & Global Spacing (Reduce Empty Space) */
@media (max-width: 781px) {


    /* 3. Reduce outer margins and inner padding of the main white box (Cart/Checkout) */
    .woocommerce-cart .woocommerce,
    .woocommerce-checkout .woocommerce,
    .tutor-cart-page .tutor-cart-page-wrapper,
    .tutor-checkout-page .tutor-checkout-page-wrapper {
        margin: 0 auto 1.5rem auto !important; /* Removed top margin completely */
        padding: 1rem !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }



    /* Reduce padding inside the summary list to save vertical space */
    .tutor-cart-summery-item {
        padding: 0.75rem 0 !important;
    }

    .tutor-cart-summery-bottom .tutor-cart-summery-item {
        padding-bottom: 1.5rem !important;
    }

    /* Make the button slightly more compact on mobile */
    .tutor-cart-summery-bottom .tutor-btn,
    .tutor-cart-checkout-btn,
    .checkout-button {
        padding: 0.8rem 1rem !important;
    }
}

/* Make Tutor LMS Dashboard match site style */
.tutor-dashboard-layout {
    max-width: 1200px !important;
    margin: 3rem auto !important;
    border-radius: 12px !important;
    box-shadow: 0 10px 30px rgba(149, 117, 205, 0.1) !important;
    background-color: #ffffff !important;
    border: 1px solid rgba(149, 117, 205, 0.2) !important;
    overflow: hidden !important;
    box-sizing: border-box !important;
}

/* Style the sidebar area */
.tutor-dashboard-layout .tutor-dashboard-left-menu,
.tutor-dashboard-layout .tutor-dashboard-sidebar {
    background-color: #f7f7fc !important;
    border-right: 1px solid rgba(149, 117, 205, 0.15) !important;
    padding-top: 1.5rem !important;
}

/* Active sidebar item */
.tutor-dashboard-layout .tutor-dashboard-left-menu .tutor-dashboard-menu-item.active a,
.tutor-dashboard-layout .tutor-dashboard-sidebar .tutor-dashboard-menu-item.active a {
    background-color: rgba(149, 117, 205, 0.1) !important;
    color: #5e35b1 !important;
    border-left: 4px solid #5e35b1 !important;
    border-radius: 0 8px 8px 0 !important;
}

/* Style the main content area */
.tutor-dashboard-layout .tutor-dashboard-main {
    padding: 2rem !important;
    background-color: #ffffff !important;
}

@media (max-width: 1240px) {
    .tutor-dashboard-layout {
        margin: 2rem 1rem !important;
    }
}
