/*
Theme Name: AdminFlow Pro
Theme URI: https://eslamdev.com/
Author: EsLaM Hamed
Author URI: https://eslamdev.com
Description: A premium, ultra-fast Light Mode SaaS WordPress theme tailored specifically for selling AdminFlow Pro.
Version: 1.0.0
Tested up to: 6.9
Requires PHP: 7.4
License: GNU General Public License v2 or later
Text Domain: adminflow-pro
Tags: one-column, custom-logo, custom-menu, e-commerce, translation-ready
*/

/* Reset & Base */
:root {
    --bg-color: #f8fafc;
    --text-color: #1e293b;
    --primary-color: #4f46e5;
    --secondary-color: #0ea5e9;
    --accent-color: #8b5cf6;
    --glass-bg: rgba(255, 255, 255, 0.85);
    --glass-border: rgba(0, 0, 0, 0.05);
    --font-main: 'Inter', sans-serif;
}

body {
    background-color: var(--bg-color);
    color: var(--text-color);
    font-family: var(--font-main);
    margin: 0;
    padding: 0;
    overflow-x: hidden;
}



/* Typography */
h1, h2, h3, h4, h5, h6 {
    color: #0f172a;
    font-weight: 700;
    letter-spacing: -0.5px;
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: all 0.3s ease;
}

a:hover {
    color: var(--secondary-color);
}

/* Buttons (Strictly no text color change on hover) */
.button, button, input[type="submit"], a.button {
    color: #ffffff !important;
    transition: transform 0.2s ease, box-shadow 0.2s ease !important;
}

.button:hover, button:hover, input[type="submit"]:hover, a.button:hover {
    color: #ffffff !important; /* Forces color to stay white */
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
}

/* Utility Classes */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.glass-panel {
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 2rem;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
}

/* Screen Reader Text - Required by WordPress */
.screen-reader-text {
    border: 0;
    clip: rect(1px, 1px, 1px, 1px);
    clip-path: inset(50%);
    height: 1px;
    margin: -1px;
    overflow: hidden;
    padding: 0;
    position: absolute !important;
    width: 1px;
    word-wrap: normal !important;
}

.screen-reader-text:focus {
    background-color: #f1f1f1;
    border-radius: 3px;
    box-shadow: 0 0 2px 2px rgba(0, 0, 0, 0.6);
    clip: auto !important;
    clip-path: none;
    color: #21759b;
    display: block;
    font-size: 0.875rem;
    font-weight: 700;
    height: auto;
    left: 5px;
    line-height: normal;
    padding: 15px 23px 14px;
    text-decoration: none;
    top: 5px;
    width: auto;
    z-index: 100000;
}

/* WordPress Required Classes */
.wp-caption {
    max-width: 100%;
    margin-bottom: 1.5em;
}

.wp-caption img {
    display: block;
    max-width: 100%;
    height: auto;
}

.wp-caption-text {
    text-align: center;
    font-style: italic;
    color: var(--text-color);
    padding: 0.5em 0;
}

.sticky {
    display: block;
}

.gallery-caption {
    display: block;
    font-size: 0.875em;
    color: var(--text-color);
}

.bypostauthor {
    display: block;
}

.alignright {
    float: right;
    margin-left: 1.5em;
    margin-bottom: 1em;
}

.alignleft {
    float: left;
    margin-right: 1.5em;
    margin-bottom: 1em;
}

.aligncenter {
    display: block;
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 1em;
}

/* Animations */
@keyframes float {
    0% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-10px);
    }

    100% {
        transform: translateY(0px);
    }
}

.animate-float {
    animation: float 6s ease-in-out infinite;
}

/* WooCommerce Overrides */
.woocommerce ul.products li.product,
.woocommerce-page ul.products li.product {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 1rem;
}

.woocommerce ul.products li.product .woocommerce-loop-product__title {
    color: #fff;
}

.woocommerce span.onsale {
    background-color: var(--primary-color);
}

.woocommerce #respond input#submit,
.woocommerce a.button,
.woocommerce button.button,
.woocommerce input.button {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: #fff;
    border-radius: 12px;
    padding: 12px 24px;
    font-weight: 600;
    border: none;
    transition: transform 0.2s, box-shadow 0.2s;
}

.woocommerce #respond input#submit:hover,
.woocommerce a.button:hover,
.woocommerce button.button:hover,
.woocommerce input.button:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(79,70,229,0.2);
}

/* Light SaaS Cart/Checkout Tables & Forms */
.woocommerce table.shop_table {
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    overflow: hidden;
    background: #ffffff;
}

.woocommerce table.shop_table th {
    background: #f8fafc;
    color: #475569;
    font-weight: 600;
    border-bottom: 1px solid #e2e8f0;
    padding: 15px;
}

.woocommerce table.shop_table td {
    border-bottom: 1px solid #f1f5f9;
    padding: 15px;
    color: #0f172a;
}

.woocommerce-cart .cart-collaterals .cart_totals, 
.woocommerce-checkout #customer_details {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.03);
}

.woocommerce form .form-row input.input-text, 
.woocommerce form .form-row textarea {
    background: #f8fafc;
    border: 1px solid #cbd5e1;
    border-radius: 10px;
    padding: 12px;
    color: #0f172a;
    transition: border-color 0.2s;
}

.woocommerce form .form-row input.input-text:focus, 
.woocommerce form .form-row textarea:focus {
    border-color: var(--primary-color);
    outline: none;
}

.woocommerce form .form-row label {
    color: #475569;
    font-weight: 500;
}

.woocommerce-checkout #payment {
    background: #f8fafc;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
}

.woocommerce-checkout #payment div.payment_box {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    color: #64748b;
}

.woocommerce-checkout #payment div.payment_box::before {
    border-bottom-color: #ffffff;
}

/* Fix Notices & WooCommerce Broken Icons */
/* Fix Notices & WooCommerce Broken Icons */
/* Fix Notices & WooCommerce Broken Icons (Bulletproof Grid Layout) */
.woocommerce-error, .woocommerce-info, .woocommerce-message {
    background: #ffffff !important;
    border-radius: 12px !important;
    border: 1px solid #e2e8f0 !important;
    border-left: 5px solid var(--primary-color) !important;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05) !important;
    color: #0f172a !important;
    padding: 15px 20px !important; /* Uniform padding */
    font-weight: 500 !important;
    list-style: none !important;
    margin-bottom: 25px !important;
    
    /* Bulletproof Layout Engine */
    display: flex !important;
    align-items: center !important;
    gap: 15px !important;
}

/* For errors which are UL lists, stack the LIs as a column inside the flex */
.woocommerce-error {
    flex-wrap: wrap !important;
    align-items: flex-start !important;
}

/* Treat ::before as a dedicated flex child */
.woocommerce-error::before, .woocommerce-info::before, .woocommerce-message::before {
    font-family: 'remixicon' !important;
    font-size: 1.6rem !important;
    line-height: 1 !important;
    margin: 0 !important;
    flex-shrink: 0 !important;
    display: inline-block !important;
}

/* Remove default WC pseudo elements so we don't duplicate icons */
.woocommerce-error li::before, .woocommerce-info li::before, .woocommerce-message li::before {
    display: none !important;
    content: none !important;
}

/* Ensure text inside wrappers or LIs takes the remaining width and won't wrap under the icon */
.woocommerce-error li, .woocommerce-info p, .woocommerce-message p {
    flex: 1 1 0% !important;
    min-width: 0 !important; /* Allows truncation or proper wrapping */
    margin: 0 !important;
}

/* Fix Action Buttons inside Notices (like "View Cart") */
.woocommerce-error a.button, .woocommerce-info a.button, .woocommerce-message a.button {
    flex: 0 0 auto !important; /* Do NOT stretch to full width! */
    order: 2 !important; /* Push it to the END of the box (after the text!) */
    margin-left: auto !important; /* Push against the right edge */
    padding: 8px 16px !important;
    background: #f1f5f9 !important;
    color: #475569 !important;
    border-radius: 8px !important;
    font-size: 0.9rem !important;
    white-space: nowrap !important;
    border: 1px solid #cbd5e1 !important;
}
.woocommerce-error a.button:hover, .woocommerce-info a.button:hover, .woocommerce-message a.button:hover {
    background: #e2e8f0 !important;
    color: #0f172a !important;
}


/* Align list items safely */
.woocommerce-error li {
    flex-basis: 100% !important; /* Force each error onto a new line if using flex wrap */
    margin-bottom: 8px !important;
    padding: 0 !important;
}
.woocommerce-error li:last-child {
    margin-bottom: 0 !important;
}

/* Styling by Type */
.woocommerce-error { border-left-color: #ef4444 !important; }
.woocommerce-error::before { content: "\eb96"; color: #ef4444; } /* ri-error-warning-fill */

.woocommerce-info { border-left-color: #3b82f6 !important; }
.woocommerce-info::before { content: "\ee58"; color: #3b82f6; } /* ri-information-fill */

.woocommerce-message { border-left-color: #10b981 !important; }
.woocommerce-message::before { content: "\ea60"; color: #10b981; } /* ri-checkbox-circle-fill */
