/**
 * Frontend styles for HubApp API shortcodes.
 *
 * @package WooCommerceHubAppAPI
 */

/* Global Header Styles */
.wcff-global-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: #fff;
    border-bottom: 1px solid #ddd;
    z-index: 10000;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    padding: 10px 20px;
    display: block !important; /* Force visibility for webview compatibility */
    visibility: visible !important;
    opacity: 1 !important;
}

.wcff-header-content {
    max-width: 1200px;
    margin: 0 auto;
}

.wcff-header-search {
    display: flex;
    gap: 10px;
    align-items: center;
}

.wcff-header-search .wcff-search-wrapper {
    flex: 1;
    max-width: 600px;
    position: relative;
}

.wcff-header-search input {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
}

/* Basket Pill Styles */
.wcff-basket-pill {
    position: fixed;
    bottom: 90px; /* Above navbar (navbar is ~65px + safe area) */
    right: 20px;
    z-index: 9998;
    background: #0073aa;
    color: #fff;
    border-radius: 50px;
    padding: 12px 20px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    transition: all 0.3s;
}

.wcff-basket-pill:hover {
    box-shadow: 0 6px 16px rgba(0,0,0,0.2);
    transform: translateY(-2px);
}

.wcff-basket-pill-link {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: #fff;
}

.wcff-basket-pill-icon {
    font-size: 24px;
}

.wcff-basket-pill-info {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    line-height: 1.2;
}

.wcff-basket-pill-count {
    font-size: 14px;
    opacity: 0.9;
}

.wcff-basket-pill-total {
    font-size: 18px;
    font-weight: 600;
}

/* Container Styles */
.wcff-login-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.wcff-dashboard-container,
.wcff-products-container,
.wcff-favourites-container,
.wcff-basket-container,
.wcff-checkout-container,
.wcff-thankyou-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0px;
    padding-top: 40px; /* Account for fixed header */
}

/* Form Styles */
.wcff-form-group {
    margin-bottom: 12px;
}

.wcff-form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    color: #333;
}

.wcff-form-group input[type="text"],
.wcff-form-group input[type="email"],
.wcff-form-group input[type="password"],
.wcff-form-group input[type="tel"],
.wcff-form-group input[type="number"],
.wcff-form-group select {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
    transition: border-color 0.2s, box-shadow 0.2s;
    box-sizing: border-box;
}

.wcff-form-group input:focus,
.wcff-form-group select:focus {
    outline: none;
    border-color: #0073aa;
    box-shadow: 0 0 0 2px rgba(0, 115, 170, 0.1);
}

.wcff-form-group input.wcff-field-error-state,
.wcff-form-group select.wcff-field-error-state {
    border-color: #d63638;
    box-shadow: 0 0 0 2px rgba(214, 54, 56, 0.1);
}

.wcff-field-error {
    display: block;
    color: #d63638;
    font-size: 13px;
    margin-top: 4px;
    line-height: 1.4;
}

.wcff-field-error:empty {
    display: none;
}

.wcff-form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

/* Button Styles */
.wcff-button-disabled,
.wcff-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    background-color: #999 !important;
    border-color: #999 !important;
}

.wcff-button-disabled:hover,
.wcff-button:disabled:hover {
    background-color: #999 !important;
    border-color: #999 !important;
    transform: none;
}

.wcff-button {
    display: inline-block;
    padding: 12px 24px;
    border: none;
    border-radius: 4px;
    font-size: 16px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: background-color 0.3s;
}

.wcff-button-primary {
    background-color: #0073aa;
    color: #fff;
}

.wcff-button-primary:hover {
    background-color: #005a87;
}

.wcff-button-secondary {
    background-color: #666;
    color: #fff;
}

.wcff-button-secondary:hover {
    background-color: #555;
}

.wcff-button-large {
    padding: 16px 32px;
    font-size: 18px;
}

.wcff-button-small {
    padding: 6px 12px;
    font-size: 14px;
}

/* Remove button (cross icon) */
.wcff-remove-item {
    background: transparent;
    border: none;
    color: #d63638;
    font-size: 28px;
    line-height: 1;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
    border-radius: 4px;
}

.wcff-remove-item:hover {
    background: #f0f0f0;
    color: #a00;
    transform: scale(1.1);
}

.wcff-remove-item:active {
    transform: scale(0.95);
}

/* Login Styles */
.wcff-login-form {
    max-width: 400px;
    margin: 0 auto;
    padding: 40px;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.wcff-login-form h2 {
    margin-top: 0;
    margin-bottom: 30px;
    text-align: center;
}

/* Message Styles */
.wcff-message {
    padding: 12px;
    margin-bottom: 20px;
    border-radius: 4px;
}

.wcff-message-error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.wcff-message-success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.wcff-error {
    padding: 20px;
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
    border-radius: 4px;
    text-align: center;
}

.wcff-loading {
    text-align: center;
    padding: 40px;
    font-size: 18px;
}

/* Loading Bar Component */
.wcff-loading-bar-container {
    width: 100%;
    max-width: 400px;
    margin: 40px auto;
    padding: 20px;
    text-align: center;
}

.wcff-loading-bar-wrapper {
    width: 100%;
    height: 100px;
    min-height: 8px;
    background: #f0f0f0;
    border-radius: 4px;
    overflow: hidden;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: flex-start;
}

/* SVG Loading Bar - Reveal animation */
.wcff-loading-bar-wrapper.wcff-has-svg {
    background: transparent !important;
    overflow: visible;
    height: auto;
    min-height: 0;
    display: inline-block;
    position: relative;
    width: auto;
    max-width: 100%;
    border-radius: 0;
    padding: 0;
    /* Ensure no filters or color modifications */
    filter: none !important;
    -webkit-filter: none !important;
}

/* Background SVG layer at 10% opacity */
.wcff-loading-bar-svg-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    pointer-events: none;
}

.wcff-loading-bar-svg-bg-image {
    display: block;
    width: auto;
    max-width: 100%;
    height: auto;
    max-height: 200px;
    margin: 0;
    padding: 0;
    opacity: 0.1 !important;
    filter: none !important;
    -webkit-filter: none !important;
    visibility: visible !important;
}

/* Container for SVG reveal animation (on top of background) */
.wcff-loading-bar-svg-reveal {
    position: relative;
    display: inline-block;
    width: auto;
    height: auto;
    overflow: hidden;
    /* Clip from right to left, revealing from left to right */
    clip-path: inset(0 100% 0 0);
    -webkit-clip-path: inset(0 100% 0 0);
    animation: wcff-svg-reveal 1.5s ease-in-out infinite;
    background: transparent;
    /* Ensure container doesn't affect SVG colors */
    filter: none;
    -webkit-filter: none;
    z-index: 2;
}

/* SVG image (base styles for both background and fill) */
.wcff-loading-bar-svg-image {
    display: block;
    width: auto;
    max-width: 100%;
    height: auto;
    max-height: 200px;
    margin: 0;
    padding: 0;
    filter: none !important;
    /* Ensure SVG colors are preserved */
    -webkit-filter: none !important;
    /* Prevent any color modifications */
    mix-blend-mode: normal;
    /* Ensure SVG is not inverted or modified */
    image-rendering: auto;
}

/* Fill SVG image (full opacity, on top) */
.wcff-loading-bar-svg-fill-image {
    opacity: 1 !important;
    visibility: visible !important;
}

/* Default loading bar (no SVG) */
.wcff-loading-bar {
    height: 100%;
    width: 0%;
    background: #0073aa;
    border-radius: 4px;
    animation: wcff-loading-bar-animate 1.5s ease-in-out infinite;
    background-size: 200% 100%;
    transition: width 0.3s ease;
    position: relative;
    z-index: 2;
}

/* Animation: Reveal SVG from left to right */
@keyframes wcff-svg-reveal {
    0% {
        clip-path: inset(0 100% 0 0);
        -webkit-clip-path: inset(0 100% 0 0);
    }
    50% {
        clip-path: inset(0 30% 0 0);
        -webkit-clip-path: inset(0 30% 0 0);
    }
    100% {
        clip-path: inset(0 0 0 0);
        -webkit-clip-path: inset(0 0 0 0);
    }
}

/* Fallback animation for default bar */
@keyframes wcff-loading-bar-animate {
    0% {
        width: 0%;
        transform: translateX(0);
    }
    50% {
        width: 70%;
    }
    100% {
        width: 100%;
        transform: translateX(0);
    }
}

.wcff-loading-text {
    margin-top: 15px;
    font-size: 14px;
    color: #666;
}

/* Dashboard Styles */
.wcff-dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 2px solid #eee;
}

.wcff-dashboard-banners {
    margin-bottom: 30px;
}

.wcff-banners-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.wcff-banner-link {
    display: block;
    text-decoration: none;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.wcff-banner-link:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.wcff-banner-image {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
}

.wcff-dashboard-info {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
}

.wcff-info-card {
    padding: 20px;
    background: #f9f9f9;
    border-radius: 8px;
}

.wcff-info-card h3 {
    margin-top: 0;
}

.wcff-info-card ul {
    list-style: none;
    padding: 0;
}

.wcff-info-card li {
    padding: 8px 0;
    border-bottom: 1px solid #eee;
}

.wcff-info-card li:last-child {
    border-bottom: none;
}

.wcff-info-card p {
    margin: 0;
    color: #666;
}

.wcff-quick-links {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

/* Products Styles */
.wcff-products-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    flex-wrap: wrap;
    gap: 20px;
}

.wcff-products-controls {
    display: flex;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
}

.wcff-brochure-filter {
    display: flex;
    align-items: center;
    gap: 10px;
}

.wcff-brochure-filter label {
    font-weight: 600;
    margin: 0;
    white-space: nowrap;
}

.wcff-brochure-select {
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    min-width: 200px;
    background-color: #fff;
    cursor: pointer;
}

.wcff-brochure-select:hover {
    border-color: #0073aa;
}

.wcff-brochure-select:focus {
    outline: none;
    border-color: #0073aa;
    box-shadow: 0 0 0 2px rgba(0, 115, 170, 0.1);
}

.wcff-brochure-select option {
    padding: 8px 12px;
    white-space: pre;
}

.wcff-products-search {
    display: flex;
    gap: 10px;
}

.wcff-view-toggle {
    display: flex;
    gap: 5px;
    border: 1px solid #ddd;
    border-radius: 4px;
    overflow: hidden;
}

.wcff-view-btn {
    background: #fff;
    border: none;
    padding: 8px 12px;
    cursor: pointer;
    font-size: 18px;
    transition: background-color 0.2s;
    margin: 0;
}

.wcff-view-btn:hover {
    background: #f5f5f5;
}

.wcff-view-btn-active {
    background: #0073aa;
    color: #fff;
}

.wcff-view-btn-active:hover {
    background: #005a87;
}

.wcff-search-wrapper {
    position: relative;
    flex: 1;
    max-width: 400px;
}

.wcff-products-search input {
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    min-width: 250px;
    width: 100%;
}

.wcff-search-suggestions {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #fff;
    border: 1px solid #ddd;
    border-top: none;
    border-radius: 0 0 4px 4px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    z-index: 1000;
    max-height: 300px;
    overflow-y: auto;
}

.wcff-search-suggestions ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.wcff-search-suggestions li {
    padding: 12px 15px;
    cursor: pointer;
    border-bottom: 1px solid #eee;
    transition: background-color 0.2s;
}

.wcff-search-suggestions li:last-child {
    border-bottom: none;
}

.wcff-search-suggestions li:hover {
    background-color: #f5f5f5;
}

.wcff-search-suggestions li strong {
    font-weight: 600;
    color: #0073aa;
}

.wcff-load-more-container {
    text-align: center;
    margin: 30px 0;
}

.wcff-load-more-btn {
    min-width: 150px;
}

.wcff-products-grid {
    display: grid;
    gap: 30px;
    margin-bottom: 40px;
}

.wcff-products-grid.wcff-columns-2 {
    grid-template-columns: repeat(2, 1fr);
}

.wcff-products-grid.wcff-columns-3 {
    grid-template-columns: repeat(3, 1fr);
}

.wcff-products-grid.wcff-columns-4 {
    grid-template-columns: repeat(4, 1fr);
}

.wcff-product-card {
    border: 1px solid #ddd;
    border-radius: 8px;
    overflow: hidden;
    transition: box-shadow 0.3s;
    display: flex;
    flex-direction: column;
}

.wcff-product-card:hover {
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.wcff-product-card a {
    text-decoration: none;
    color: inherit;
}

.wcff-product-card a:hover {
    text-decoration: underline;
}

.wcff-product-sku {
    font-size: 12px;
    color: #666;
    margin: 5px 0;
}

.wcff-product-price {
    margin: 10px 0;
    font-size: 18px;
    font-weight: 600;
}

.wcff-original-price {
    color: #999;
    margin-right: 8px;
}

.wcff-original-price del {
    text-decoration: line-through;
}

.wcff-role-price {
    color: #0073aa;
}

.wcff-product-quantity {
    margin: 10px 0;
}

.wcff-product-quantity label {
    display: block;
    margin-bottom: 5px;
    font-size: 14px;
    font-weight: 600;
}

.wcff-qty-input {
    width: 80px;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
}

/* List View Styles */
.wcff-products-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.wcff-product-list-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    background: #fff;
    transition: box-shadow 0.3s;
    flex-wrap: nowrap;
    overflow: hidden;
    width: 100%;
}

.wcff-product-list-item:hover {
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

/* List item image removed - using eye icon instead */

.wcff-list-item-info {
    flex: 1;
    min-width: 200px;
    overflow: hidden;
    position: relative;
    padding-left: 60px; /* Space for eye icon and link icon */
}

.wcff-view-image-btn,
.wcff-view-webpage-btn {
    position: absolute;
    top: 0;
    background: transparent;
    border: none;
    font-size: 16px;
    cursor: pointer;
    padding: 3px;
    line-height: 1;
    opacity: 0.6;
    transition: opacity 0.2s ease;
    text-decoration: none;
    color: inherit;
}

.wcff-view-image-btn {
    left: 0;
}

.wcff-view-webpage-btn {
    left: 30px;
}

.wcff-view-image-btn:hover,
.wcff-view-webpage-btn:hover {
    opacity: 1;
}

.wcff-view-image-btn:active,
.wcff-view-webpage-btn:active {
    transform: scale(0.95);
}

.wcff-list-item-info h3 {
    margin: 0 0 2px 0;
    font-size: 14px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    line-height: 1.2;
}

.wcff-list-item-info a {
    text-decoration: none;
    color: inherit;
    display: block;
}

.wcff-list-item-info a:hover {
    text-decoration: underline;
}

.wcff-list-item-info .wcff-product-sku {
    font-size: 10px;
    margin: 1px 0;
}

.wcff-list-item-info .wcff-product-price {
    margin: 2px 0;
    font-size: 14px;
}

.wcff-list-item-info .wcff-product-stock {
    font-size: 11px;
    margin: 2px 0;
}

.wcff-list-item-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
    min-width: 110px;
    justify-content: flex-end;
}

.wcff-qty-btn {
    width: 28px;
    height: 28px;
    border: 1px solid #ddd;
    background: #fff;
    border-radius: 4px;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    padding: 0;
}

.wcff-qty-btn:hover {
    background: #f5f5f5;
    border-color: #0073aa;
}

.wcff-qty-btn:active {
    background: #0073aa;
    color: #fff;
}

.wcff-qty-display {
    min-width: 32px;
    text-align: center;
    font-weight: 600;
    font-size: 14px;
}

.wcff-product-image {
    width: 100%;
    height: 200px;
    overflow: hidden;
    background: #f5f5f5;
}

.wcff-product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.wcff-product-info {
    padding: 20px;
}

.wcff-product-info h3 {
    margin-top: 0;
    margin-bottom: 10px;
}

.wcff-product-description {
    color: #666;
    font-size: 14px;
    margin-bottom: 15px;
}

.wcff-product-price {
    font-size: 24px;
    font-weight: 700;
    color: #0073aa;
    margin-bottom: 10px;
}

.wcff-product-stock {
    margin-bottom: 15px;
}

.wcff-in-stock {
    color: #28a745;
    font-weight: 600;
}

.wcff-out-of-stock {
    color: #dc3545;
    font-weight: 600;
}

/* Disabled button styles */
.wcff-add-to-cart:disabled,
.wcff-qty-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    pointer-events: none;
}

.wcff-qty-input:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    background-color: #f5f5f5;
}

/* Basket Styles */
.wcff-basket-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 30px;
}

.wcff-basket-table th,
.wcff-basket-table td {
    padding: 15px;
    text-align: left;
    border-bottom: 1px solid #eee;
}

.wcff-basket-table th {
    background-color: #f9f9f9;
    font-weight: 600;
}

.wcff-quantity-input {
    width: 60px;
    padding: 5px;
    text-align: center;
}

.wcff-basket-totals {
    background: #f9f9f9;
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 30px;
}

.wcff-total-row {
    display: flex;
    justify-content: space-between;
    padding: 10px 0;
    font-size: 18px;
}

.wcff-basket-actions {
    display: flex;
    gap: 15px;
    justify-content: flex-end;
}

/* Checkout Styles */
/* Stripe Payment Element Styles */
#wcff-stripe-payment-element {
    padding: 20px;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 4px;
    margin: 20px 0;
    min-height: 200px;
}

#wcff-stripe-payment-element .StripeElement {
    padding: 10px;
}

#wcff-stripe-payment-errors {
    margin-top: 10px;
    padding: 10px;
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
    border-radius: 4px;
}

.wcff-checkout-form {
    max-width: 800px;
    margin: 0 auto;
}

.wcff-checkout-form h3 {
    margin-top: 30px;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #eee;
}

.wcff-shipping-address-block {
    background: #f9f9f9;
    padding: 15px;
    border-radius: 4px;
    border: 1px solid #ddd;
    margin: 10px 0;
}

.wcff-shipping-address-content {
    color: #333;
    line-height: 1.6;
}

.wcff-shipping-address-content p {
    margin: 5px 0;
}

.wcff-shipping-address-content p:first-child {
    margin-top: 0;
}

.wcff-shipping-address-content p:last-child {
    margin-bottom: 0;
}

.wcff-order-summary {
    background: #f9f9f9;
    padding: 20px;
    border-radius: 8px;
    margin: 30px 0;
}

.wcff-summary-item {
    display: flex;
    justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px solid #eee;
}

.wcff-summary-total {
    display: flex;
    justify-content: space-between;
}

/* Mobile App Navbar Styles */
.wcff-navbar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    width: 100%;
    background: #ffffff;
    border-top: 1px solid #e0e0e0;
    display: flex;
    justify-content: space-around;
    align-items: flex-start;
    padding: 0;
    z-index: 9999;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.08);
    /* Ensure it's above GeneratePress elements */
    position: fixed !important;
    /* Safe area for iOS devices */
    padding-bottom: env(safe-area-inset-bottom);
}

/* GeneratePress compatibility - ensure navbar is above theme elements */
body .wcff-navbar {
    z-index: 9999 !important;
}

.wcff-navbar-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    color: #757575;
    padding: 8px 4px 10px;
    min-width: 0;
    transition: all 0.2s ease;
    flex: 1;
    position: relative;
    -webkit-tap-highlight-color: transparent;
    user-select: none;
    cursor: pointer;
}

/* Inactive state */
.wcff-navbar-item {
    color: #757575;
    opacity: 0.7;
}

/* Active state */
.wcff-navbar-item.wcff-navbar-active {
    color: #0073aa;
    opacity: 1;
}

/* Active indicator dot */
.wcff-navbar-item.wcff-navbar-active::before {
    content: '';
    position: absolute;
    top: 4px;
    left: 50%;
    transform: translateX(-50%);
    width: 4px;
    height: 4px;
    background: #0073aa;
    border-radius: 50%;
}

/* Hover state (for desktop) */
.wcff-navbar-item:hover {
    color: #0073aa;
    opacity: 1;
    text-decoration: none;
    background-color: rgba(0, 115, 170, 0.05);
}

/* Touch/Active state */
.wcff-navbar-item:active {
    background-color: rgba(0, 115, 170, 0.1);
    transform: scale(0.95);
}

.wcff-navbar-icon {
    font-size: 24px;
    line-height: 1;
    margin-bottom: 4px;
    transition: transform 0.2s ease;
    display: block;
}

/* Slightly scale icon on active */
.wcff-navbar-item.wcff-navbar-active .wcff-navbar-icon {
    transform: scale(1.1);
}

.wcff-navbar-label {
    font-size: 11px;
    font-weight: 500;
    text-align: center;
    line-height: 1.2;
    letter-spacing: 0.01em;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
}

/* Add bottom padding to containers to account for fixed navbar */
.wcff-dashboard-container,
.wcff-products-container,
.wcff-favourites-container,
.wcff-basket-container,
.wcff-checkout-container,
.wcff-thankyou-container {
    padding-bottom: 70px;
}

/* Login page doesn't need padding (no navbar) */
.wcff-login-container {
    padding-bottom: 20px;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .wcff-navbar {
        padding-bottom: calc(8px + env(safe-area-inset-bottom));
    }
    
    .wcff-navbar-item {
        padding: 6px 2px 8px;
    }
    
    .wcff-navbar-icon {
        font-size: 22px;
        margin-bottom: 3px;
    }
    
    .wcff-navbar-label {
        font-size: 10px;
    }
    
    .wcff-dashboard-container,
    .wcff-products-container,
    .wcff-favourites-container,
    .wcff-basket-container,
    .wcff-checkout-container,
    .wcff-thankyou-container {
        padding-bottom: 65px;
    }
}

/* Very small screens */
@media (max-width: 480px) {
    .wcff-navbar-icon {
        font-size: 20px;
    }
    
    .wcff-navbar-label {
        font-size: 9px;
    }
}

/* Ensure navbar doesn't interfere with GeneratePress footer */
body:not(.admin-bar) .wcff-navbar {
    bottom: 0;
}

body.admin-bar .wcff-navbar {
    bottom: 0;
}

/* Print styles - hide navbar */
@media print {
    .wcff-navbar {
        display: none !important;
    }
}

/* Thank You Styles */
.wcff-thankyou-content {
    text-align: center;
    max-width: 600px;
    margin: 0 auto;
    padding: 60px 20px;
}

.wcff-thankyou-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 30px;
    background-color: #28a745;
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 48px;
    font-weight: bold;
}

.wcff-thankyou-message {
    font-size: 18px;
    color: #666;
    margin-bottom: 30px;
}

.wcff-order-details {
    background: #f9f9f9;
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 30px;
}

.wcff-thankyou-actions {
    display: flex;
    gap: 15px;
    justify-content: center;
}

.wcff-empty-state {
    text-align: center;
    padding: 60px 20px;
}

.wcff-pagination {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 30px;
}

.wcff-pagination button {
    padding: 8px 16px;
    border: 1px solid #ddd;
    background: #fff;
    cursor: pointer;
    border-radius: 4px;
}

.wcff-pagination button:hover {
    background: #f5f5f5;
}

.wcff-pagination button.active {
    background: #0073aa;
    color: #fff;
    border-color: #0073aa;
}

/* Responsive */
@media (max-width: 768px) {
    .wcff-form-row {
        grid-template-columns: 1fr;
    }
    
    .wcff-products-grid.wcff-columns-3,
    .wcff-products-grid.wcff-columns-4 {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .wcff-dashboard-info {
        grid-template-columns: 1fr;
    }
    
    .wcff-products-header {
        flex-direction: column;
        align-items: stretch;
    }
    
    .wcff-products-search {
        width: 100%;
    }
    
    .wcff-products-controls {
        flex-direction: column;
        align-items: stretch;
    }
    
    .wcff-view-toggle {
        align-self: flex-end;
    }
    
    .wcff-product-list-item {
        flex-wrap: nowrap;
        gap: 8px;
        padding: 6px 10px;
    }
    
    .wcff-list-item-image {
        width: 60px;
        height: 60px;
        flex-shrink: 0;
    }
    
    .wcff-list-item-info {
        min-width: 120px;
        flex: 1;
    }
    
    .wcff-list-item-actions {
        flex-shrink: 0;
        min-width: 100px;
    }
    
    .wcff-products-search input {
        flex: 1;
        min-width: 0;
    }
}

@media (max-width: 480px) {
    .wcff-products-grid {
        grid-template-columns: 1fr !important;
    }
    
    .wcff-basket-table {
        font-size: 14px;
    }
    
    .wcff-basket-table th,
    .wcff-basket-table td {
        padding: 10px 5px;
    }
}

/* Image Modal Styles */
.wcff-image-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 100000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.wcff-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    cursor: pointer;
}

.wcff-modal-content {
    position: relative;
    max-width: 90%;
    max-height: 90%;
    background: #fff;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    z-index: 100001;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.wcff-modal-close {
    position: absolute;
    top: 10px;
    right: 10px;
    background: transparent;
    border: none;
    font-size: 32px;
    line-height: 1;
    cursor: pointer;
    color: #333;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background-color 0.2s ease;
}

.wcff-modal-close:hover {
    background-color: #f5f5f5;
}

#wcff-modal-image {
    max-width: 100%;
    max-height: 70vh;
    object-fit: contain;
    border-radius: 4px;
}

#wcff-modal-caption {
    margin-top: 15px;
    font-size: 16px;
    font-weight: 600;
    color: #333;
    text-align: center;
}


