﻿/**
 * Enhanced Styles for Toy Store
 * Additional styles for new features
 */

/* ========== SEARCH BAR ========== */
.search-bar {
    position: relative;
    max-width: 600px;
    margin: 0 auto 30px;
}

.search-bar input {
    width: 100%;
    padding: 16px 50px 16px 24px;
    border: 2px solid var(--gray-200);
    border-radius: 60px;
    font-size: 1rem;
    font-family: 'Nunito', sans-serif;
    transition: var(--transition);
}

.search-bar input:focus {
    outline: none;
    border-color: var(--purple-soft);
    box-shadow: 0 0 0 4px rgba(115, 88, 133, 0.1);
}

.search-bar button {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    background: var(--purple-soft);
    color: white;
    border: none;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    cursor: pointer;
    transition: var(--transition);
}

.search-bar button:hover {
    background: var(--purple-deep);
    transform: translateY(-50%) scale(1.05);
}

/* ========== WISHLIST BUTTON ========== */
.wishlist-btn {
    position: absolute;
    top: 12px;
    right: 12px;
    background: white;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    z-index: 2;
}

.wishlist-btn i {
    color: var(--gray-600);
    font-size: 1.2rem;
    transition: var(--transition);
}

.wishlist-btn:hover,
.wishlist-btn.active {
    background: var(--purple-soft);
}

.wishlist-btn:hover i,
.wishlist-btn.active i {
    color: white;
}

.wishlist-btn.active i {
    color: #ff4757;
}

/* ========== QUICK VIEW BUTTON ========== */
.quick-view-btn {
    position: absolute;
    bottom: 12px;
    left: 50%;
    transform: translateX(-50%) translateY(20px);
    background: var(--purple-deep);
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 40px;
    font-weight: 700;
    font-size: 0.9rem;
    cursor: pointer;
    opacity: 0;
    transition: var(--transition);
    white-space: nowrap;
}

.product-card:hover .quick-view-btn {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

.quick-view-btn i {
    margin-right: 6px;
}

/* ========== QUICK VIEW MODAL ========== */
.quick-view-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    opacity: 0;
    transition: opacity 0.3s;
    padding: 20px;
}

.quick-view-modal.active {
    opacity: 1;
}

.quick-view-content {
    background: white;
    border-radius: var(--radius-card);
    max-width: 900px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    padding: 40px;
    animation: slideUp 0.3s ease;
}

@keyframes slideUp {
    from {
        transform: translateY(30px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.close-modal {
    position: absolute;
    top: 16px;
    right: 16px;
    background: var(--gray-100);
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
}

.close-modal:hover {
    background: var(--purple-soft);
    color: white;
}

.quick-view-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
}

.quick-view-image img {
    width: 100%;
    border-radius: var(--radius-element);
}

.quick-view-info h2 {
    color: var(--purple-deep);
    margin-bottom: 16px;
}

.quick-view-info .product-price {
    margin: 20px 0;
}

.quick-view-actions {
    display: flex;
    gap: 12px;
    margin-top: 24px;
    flex-wrap: wrap;
}

/* ========== NOTIFICATIONS ========== */
.notification {
    position: fixed;
    bottom: -100px;
    right: 24px;
    background: white;
    padding: 16px 24px;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.15);
    display: flex;
    align-items: center;
    gap: 12px;
    z-index: 10001;
    transition: bottom 0.3s ease;
    max-width: 400px;
}

.notification.show {
    bottom: 24px;
}

.notification-success {
    border-left: 4px solid var(--grass-green);
}

.notification-success i {
    color: var(--grass-green);
    font-size: 1.4rem;
}

.notification-info {
    border-left: 4px solid var(--sky-blue);
}

.notification-info i {
    color: var(--sky-blue);
    font-size: 1.4rem;
}

/* ========== WHATSAPP FLOATING BUTTON ========== */
.whatsapp-float {
    position: fixed;
    bottom: 24px;
    left: 24px;
    background: #25D366;
    color: white;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    box-shadow: 0 4px 12px rgba(37, 211, 102, 0.4);
    cursor: pointer;
    transition: var(--transition);
    z-index: 999;
    text-decoration: none;
}

.whatsapp-float:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 16px rgba(37, 211, 102, 0.6);
}

.whatsapp-float i {
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
}

/* ========== PRODUCT BADGES ========== */
.product-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    padding: 6px 14px;
    border-radius: 20px;
    font-weight: 700;
    font-size: 0.85rem;
    z-index: 2;
}

.product-badge.sale {
    background: var(--sun-yellow);
    color: var(--purple-deep);
}

.product-badge.new {
    background: var(--grass-green);
    color: white;
}

.product-badge.out-of-stock {
    background: #e74c3c;
    color: white;
}

/* ========== LOADING SPINNER ========== */
.loading-spinner {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 4px solid var(--gray-200);
    border-top-color: var(--purple-soft);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* ========== PRODUCT FILTERS ENHANCEMENTS ========== */
.filter-block.collapsed .filter-options {
    display: none;
}

.filter-block h4 {
    cursor: pointer;
    user-select: none;
}

.filter-block h4::after {
    content: '\f078';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    float: right;
    transition: transform 0.3s;
}

.filter-block.collapsed h4::after {
    transform: rotate(-90deg);
}

/* ========== PRICE SLIDER ========== */
.price-slider {
    margin: 20px 0;
}

.price-slider input[type="range"] {
    width: 100%;
    height: 6px;
    border-radius: 5px;
    background: var(--gray-200);
    outline: none;
    -webkit-appearance: none;
}

.price-slider input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--purple-soft);
    cursor: pointer;
}

.price-slider input[type="range"]::-moz-range-thumb {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--purple-soft);
    cursor: pointer;
    border: none;
}

/* ========== BREADCRUMBS ========== */
.breadcrumbs {
    padding: 20px 0;
    font-size: 0.9rem;
    color: var(--gray-600);
}

.breadcrumbs a {
    color: var(--purple-soft);
    text-decoration: none;
    font-weight: 600;
}

.breadcrumbs a:hover {
    text-decoration: underline;
}

.breadcrumbs i {
    margin: 0 8px;
    font-size: 0.7rem;
}

/* ========== PRODUCT RATING ========== */
.product-rating {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 12px 0;
}

.stars {
    color: #ffb703;
    font-size: 0.9rem;
}

.rating-count {
    color: var(--gray-600);
    font-size: 0.85rem;
}

/* ========== STOCK INDICATOR ========== */
.stock-indicator {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    margin: 12px 0;
}

.stock-indicator.in-stock {
    background: rgba(158, 197, 65, 0.1);
    color: var(--grass-green);
}

.stock-indicator.low-stock {
    background: rgba(255, 183, 3, 0.1);
    color: #ffb703;
}

.stock-indicator.out-of-stock {
    background: rgba(231, 76, 60, 0.1);
    color: #e74c3c;
}

/* ========== RESPONSIVE ENHANCEMENTS ========== */
@media (max-width: 900px) {
    .quick-view-grid {
        grid-template-columns: 1fr;
    }
    
    .whatsapp-float {
        width: 50px;
        height: 50px;
        font-size: 1.6rem;
    }
    
    .notification {
        right: 12px;
        left: 12px;
        max-width: none;
    }
}

@media (max-width: 650px) {
    .quick-view-content {
        padding: 24px;
    }
    
    .quick-view-actions {
        flex-direction: column;
    }
    
    .quick-view-actions .btn {
        width: 100%;
    }
}

/* ========== PAGINATION ENHANCEMENTS ========== */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin-top: 40px;
    flex-wrap: wrap;
    padding: 20px 0;
}

.page-item {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 44px;
    height: 44px;
    padding: 0 12px;
    border-radius: 12px;
    background: white;
    color: var(--purple-deep);
    font-weight: 700;
    font-size: 0.95rem;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    border: 2px solid transparent;
    cursor: pointer;
    text-decoration: none;
}

.page-item:hover:not(.active) {
    background: var(--purple-soft);
    color: white;
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.page-item.active {
    background: var(--purple-deep);
    color: white;
    border-color: var(--purple-deep);
    box-shadow: 0 4px 12px rgba(86, 69, 147, 0.3);
    cursor: default;
}

.page-prev,
.page-next {
    background: var(--grass-green);
    color: white;
    font-size: 0.9rem;
}

.page-prev:hover,
.page-next:hover {
    background: #85ad38;
    transform: translateY(-2px);
}

.page-prev:disabled,
.page-next:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.page-ellipsis {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 44px;
    height: 44px;
    color: var(--gray-600);
    font-weight: 700;
    font-size: 1.2rem;
    user-select: none;
}

/* Mobile pagination adjustments */
@media (max-width: 650px) {
    .pagination {
        gap: 6px;
    }
    
    .page-item {
        min-width: 40px;
        height: 40px;
        font-size: 0.9rem;
    }
    
    .page-ellipsis {
        min-width: 30px;
        height: 40px;
    }
}

/* ========== SCROLL TO TOP BUTTON ========== */
.scroll-to-top {
    position: fixed;
    bottom: 24px;
    right: 24px;
    background: var(--purple-soft);
    color: white;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    z-index: 998;
    border: none;
}

.scroll-to-top.visible {
    opacity: 1;
    visibility: visible;
}

.scroll-to-top:hover {
    background: var(--purple-deep);
    transform: translateY(-4px);
}

/* ========== EMPTY STATE ========== */
.empty-state {
    text-align: center;
    padding: 80px 20px;
}

.empty-state i {
    font-size: 5rem;
    color: var(--gray-200);
    margin-bottom: 24px;
}

.empty-state h3 {
    color: var(--purple-deep);
    margin-bottom: 12px;
}

.empty-state p {
    color: var(--gray-600);
    margin-bottom: 24px;
}


/* ========== LOADING STATES ========== */
.loading-spinner {
    display: inline-block;
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #564593;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Skeleton Screen */
.skeleton {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: loading 1.5s ease-in-out infinite;
}

@keyframes loading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

.skeleton-card {
    height: 300px;
    border-radius: 12px;
}

.skeleton-text {
    height: 20px;
    border-radius: 4px;
    margin-bottom: 10px;
}

.skeleton-image {
    width: 100%;
    padding-top: 100%;
    border-radius: 12px;
}

/* Loading Container */
.loading-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 300px;
    flex-direction: column;
    gap: 15px;
}

.loading-text {
    color: #564593;
    font-weight: 600;
    font-size: 1.1rem;
}

/* ========== NOTIFICATION ANIMATION ========== */
@keyframes slideIn {
    from {
        transform: translateX(-50%) translateY(20px);
        opacity: 0;
    }
    to {
        transform: translateX(-50%) translateY(0);
        opacity: 1;
    }
}

/* ========== IMPROVED PRODUCT CARDS ========== */
.product-card {
    display: flex;
    flex-direction: column;
    height: 100%;
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.12);
}

.product-image {
    position: relative;
    width: 100%;
    padding-top: 100%; /* 1:1 Aspect Ratio */
    overflow: hidden;
    background: #f8f9fa;
}

.product-image img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 15px;
    transition: transform 0.3s ease;
}

.product-card:hover .product-image img {
    transform: scale(1.05);
}

.product-info {
    padding: 15px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.product-info h3 {
    font-size: 1rem;
    margin-bottom: 8px;
    color: #564593;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    min-height: 2.4em;
    line-height: 1.2em;
}

.product-price {
    font-size: 1.2rem;
    font-weight: 700;
    color: #9DC541;
    margin-top: auto;
    margin-bottom: 10px;
}

.price-sale {
    color: var(--grass-green);
    font-weight: 800;
    margin-right: 8px;
}

.price-regular {
    text-decoration: line-through;
    color: #999;
    font-size: 0.9rem;
}

.product-actions {
    display: flex;
    gap: 8px;
    margin-top: 10px;
}

.product-actions .btn {
    flex: 1;
    padding: 10px;
    font-size: 0.9rem;
}

/* ========== SCROLL TO TOP BUTTON ANIMATION ========== */
.scroll-to-top {
    animation: fadeInUp 0.3s ease;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ========== WHATSAPP BUTTON PULSE ========== */
.whatsapp-float {
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% {
        box-shadow: 0 4px 12px rgba(0,0,0,0.3);
    }
    50% {
        box-shadow: 0 4px 20px rgba(37, 211, 102, 0.6);
    }
}

/* ========== RESPONSIVE IMPROVEMENTS ========== */
@media (max-width: 768px) {
    .product-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }
    
    .product-info h3 {
        font-size: 0.9rem;
    }
    
    .product-price {
        font-size: 1rem;
    }
    
    .scroll-to-top,
    .whatsapp-float {
        width: 50px;
        height: 50px;
        font-size: 24px;
    }
    
    .whatsapp-float {
        bottom: 70px;
        width: 60px !important;
        height: 60px !important;
    }
    
    /* Mobile WhatsApp - unified bubble + icon design */
    .whatsapp-float-container {
        bottom: 20px !important;
        left: 15px !important;
        transform: none !important;
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        gap: 8px !important;
    }
    
    .whatsapp-bubble {
        position: relative !important;
        top: auto !important;
        left: auto !important;
        transform: none !important;
        white-space: normal !important;
        max-width: 140px !important;
        text-align: center !important;
        font-size: 12px !important;
        padding: 10px 14px !important;
        margin-bottom: 0 !important;
        order: 1 !important;
    }
    
    .whatsapp-bubble-arrow {
        display: none !important;
    }
    
    .whatsapp-float-container .whatsapp-float {
        order: 2 !important;
        position: relative !important;
        bottom: auto !important;
        left: auto !important;
    }
}

@media (max-width: 480px) {
    .product-grid {
        grid-template-columns: 1fr;
    }
}


/* ========== HEADER SEARCH BAR ========== */
.header-search {
    position: relative;
    flex: 1;
    max-width: 500px;
    margin: 0 30px;
}

.header-search input {
    width: 100%;
    padding: 12px 50px 12px 20px;
    border: 2px solid #e0e0e0;
    border-radius: 50px;
    font-size: 0.95rem;
    outline: none;
    transition: all 0.3s;
    background: #f8f9fa;
}

.header-search input:focus {
    border-color: #564593;
    background: white;
    box-shadow: 0 0 0 3px rgba(86, 69, 147, 0.1);
}

.header-search button {
    position: absolute;
    right: 5px;
    top: 50%;
    transform: translateY(-50%);
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #564593, #735885);
    border: none;
    border-radius: 50%;
    color: white;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.header-search button:hover {
    background: linear-gradient(135deg, #9DC541, #8db436);
    transform: translateY(-50%) scale(1.05);
}

/* Search Results Dropdown */
.search-results-dropdown {
    position: absolute;
    top: calc(100% + 10px);
    left: 0;
    right: 0;
    background: white;
    border-radius: 12px;
    box-shadow: 0 8px 30px rgba(0,0,0,0.15);
    max-height: 400px;
    overflow-y: auto;
    display: none;
    z-index: 1000;
    border: 2px solid #e0e0e0;
}

.search-results-dropdown.active {
    display: block;
    animation: slideDown 0.3s ease;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.search-result-item {
    display: flex;
    align-items: center;
    padding: 12px 15px;
    border-bottom: 1px solid #f0f0f0;
    text-decoration: none;
    color: inherit;
    transition: background 0.2s;
    cursor: pointer;
}

.search-result-item:last-child {
    border-bottom: none;
}

.search-result-item:hover {
    background: #f8f9fa;
}

.search-result-item img {
    width: 50px;
    height: 50px;
    object-fit: contain;
    margin-right: 12px;
    border-radius: 8px;
    background: #f8f9fa;
    padding: 5px;
}

.search-result-info {
    flex: 1;
}

.search-result-name {
    font-weight: 600;
    color: #564593;
    font-size: 0.95rem;
    margin-bottom: 3px;
}

.search-result-price {
    color: #9DC541;
    font-weight: 700;
    font-size: 0.9rem;
}

.search-no-results {
    padding: 30px 20px;
    text-align: center;
    color: #999;
}

.search-no-results i {
    font-size: 2rem;
    margin-bottom: 10px;
    display: block;
    color: #ddd;
}

/* Mobile Search Button */
.search-mobile-btn {
    display: none;
    background: none;
    border: none;
    font-size: 1.3rem;
    color: #564593;
    cursor: pointer;
    padding: 8px;
    position: relative;
    z-index: 10;
    min-width: 44px;
    min-height: 44px;
    -webkit-tap-highlight-color: transparent;
}

/* Mobile Search Overlay */
.mobile-search-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.5);
    z-index: 2000;
    display: none;
}

.mobile-search-overlay.active {
    display: block;
}

.mobile-search-content {
    background: white;
    padding: 20px;
    border-radius: 0 0 20px 20px;
}

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

.mobile-search-header input {
    flex: 1;
    padding: 14px 18px;
    border: 2px solid #564593;
    border-radius: 25px;
    font-size: 1rem;
    outline: none;
}

.mobile-search-close {
    width: 44px;
    height: 44px;
    background: #f0f0f0;
    border: none;
    border-radius: 10px;
    color: #564593;
    font-size: 20px;
    cursor: pointer;
}

/* Responsive */
@media (max-width: 1024px) {
    .header-search {
        max-width: 350px;
        margin: 0 20px;
    }
}

@media (max-width: 900px) {
    .header-search {
        display: none;
    }
    
    .search-mobile-btn {
        display: block;
    }
}

@media (max-width: 768px) {
    .header-actions {
        gap: 10px;
    }
}

/* Brand Logos Horizontal Slider */
.brands-slider {
  overflow: hidden;
  width: 100%;
  position: relative;
  padding: 20px 0;
  background: transparent;
}

.brands-track {
  display: flex !important;
  flex-direction: row !important;
  flex-wrap: nowrap !important;
  gap: 60px;
  align-items: center;
  animation: scroll-brands 25s linear infinite;
  width: max-content;
  white-space: nowrap;
}

.brands-track img {
  display: inline-block !important;
  height: 80px;
  width: auto;
  min-width: 140px;
  max-width: 200px;
  object-fit: contain;
  filter: grayscale(0.3);
  opacity: 0.85;
  transition: all 0.3s ease;
  flex-shrink: 0;
  vertical-align: middle;
}

.brands-track img:hover {
  filter: grayscale(0);
  opacity: 1;
  transform: scale(1.1);
}

@keyframes scroll-brands {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(-50%);
  }
}

/* Pause animation on hover */
.brands-slider:hover .brands-track {
  animation-play-state: paused;
}

/* ========== QUOTE REQUEST MODAL ========== */
.quote-modal {
    display: none;
    position: fixed;
    z-index: 10000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.quote-modal-content {
    background-color: var(--white-pure);
    margin: 5% auto;
    padding: 40px;
    border-radius: var(--radius-card);
    max-width: 600px;
    width: 90%;
    box-shadow: var(--shadow-hover);
    animation: slideDown 0.3s ease;
    position: relative;
}

@keyframes slideDown {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.quote-modal-close {
    color: var(--gray-600);
    position: absolute;
    right: 24px;
    top: 24px;
    font-size: 32px;
    font-weight: 300;
    cursor: pointer;
    transition: var(--transition);
    line-height: 1;
}

.quote-modal-close:hover,
.quote-modal-close:focus {
    color: var(--purple-deep);
    transform: rotate(90deg);
}

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

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: var(--gray-800);
    font-weight: 600;
    font-size: 0.95rem;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid var(--gray-200);
    border-radius: 12px;
    font-size: 1rem;
    font-family: 'Nunito', sans-serif;
    transition: var(--transition);
    background-color: var(--white-pure);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--purple-soft);
    box-shadow: 0 0 0 4px rgba(115, 88, 133, 0.1);
}

.form-group textarea {
    resize: vertical;
    min-height: 100px;
}

.form-group select {
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23564593' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
    padding-right: 40px;
}

/* Responsive Modal */
@media (max-width: 768px) {
    .quote-modal-content {
        margin: 10% auto;
        padding: 24px;
        width: 95%;
    }
    
    .quote-modal-close {
        right: 16px;
        top: 16px;
        font-size: 28px;
    }
}

/* ========== PRODUCT PRICE STYLING ========== */
.current-price {
    color: var(--grass-green);
    font-size: 1.2em;
    font-weight: 800;
}

.original-price {
    text-decoration: line-through;
    color: #999;
    font-size: 0.9em;
    margin-left: 8px;
    opacity: 0.8;
}

/* Mobile spacing for catalog buttons */
@media (max-width: 768px) {
  .btn-primary + a[href*="catalogue"] {
    margin-left: 0 !important;
    margin-top: 16px;
    display: inline-block;
  }
}

/* ========== DESKTOP BREATHING SPACE ========== */
/* Add margins on left and right edges of the screen for desktop only */
@media (min-width: 1024px) {
  /* Add margins to body content sections (not header/footer/hero) */
  section:not(header):not(footer):not(.hero) {
    margin-left: 40px;
    margin-right: 40px;
  }
}

/* Extra breathing space for larger screens */
@media (min-width: 1400px) {
  section:not(header):not(footer):not(.hero) {
    margin-left: 60px;
    margin-right: 60px;
  }
}

/* ========== MOBILE HEADER ICON FIXES ========== */
/* Ensure all header icons are clickable on mobile */
@media (max-width: 900px) {
    /* Mobile header layout: hamburger left, logo center, search+cart right */
    .header-container {
        display: grid;
        grid-template-columns: auto 1fr auto;
        align-items: center;
        gap: 12px;
        padding: 12px 16px;
    }
    
    /* Hamburger menu on the left with spacing */
    .mobile-menu-btn {
        order: 1;
        position: relative;
        z-index: 10;
        min-width: 44px;
        min-height: 44px;
        padding: 8px;
        cursor: pointer;
        -webkit-tap-highlight-color: transparent;
        touch-action: manipulation;
        margin-right: 8px;
    }
    
    /* Logo in the center */
    .logo {
        order: 2;
        justify-self: center;
        margin: 0 auto;
    }
    
    /* Search and cart on the right */
    .header-actions {
        order: 3;
        position: relative;
        z-index: 10;
        display: flex;
        align-items: center;
        gap: 8px;
        margin-left: 8px;
    }
    
    /* Hide desktop nav on mobile */
    .nav-desktop {
        display: none;
    }
    
    /* Hide desktop search bar on mobile */
    .header-search {
        display: none;
    }
    
    /* Cart icon */
    .cart-icon {
        position: relative;
        z-index: 10;
        min-width: 44px;
        min-height: 44px;
        display: flex;
        align-items: center;
        justify-content: center;
        cursor: pointer;
        -webkit-tap-highlight-color: transparent;
        touch-action: manipulation;
    }
    
    /* Search mobile button */
    .search-mobile-btn {
        position: relative;
        z-index: 10;
        min-width: 44px;
        min-height: 44px;
        cursor: pointer;
        -webkit-tap-highlight-color: transparent;
        touch-action: manipulation;
    }
    
    /* Ensure header doesn't have pointer-events issues */
    header {
        position: sticky;
        z-index: 100;
        pointer-events: auto;
    }
    
    .header-container {
        position: relative;
        z-index: 10;
        pointer-events: auto;
    }
}

/* Extra small mobile devices */
@media (max-width: 650px) {
    .header-container {
        padding: 10px 12px;
        gap: 8px;
    }
    
    .mobile-menu-btn {
        min-width: 40px;
        min-height: 40px;
        padding: 6px;
        margin-right: 4px;
    }
    
    .cart-icon,
    .search-mobile-btn {
        min-width: 40px;
        min-height: 40px;
        padding: 6px;
    }
    
    .header-actions {
        gap: 6px;
        margin-left: 4px;
    }
}

/* ========== MOBILE MENU BACKDROP ========== */
.mobile-menu-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1050;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s, visibility 0.3s;
}

.mobile-menu-backdrop.active {
    opacity: 1;
    visibility: visible;
}

/* ========== ENSURE BUTTONS ARE ALWAYS CLICKABLE ========== */
button, a {
    -webkit-tap-highlight-color: rgba(0, 0, 0, 0.1);
    touch-action: manipulation;
}

/* Specific fixes for header buttons */
.mobile-menu-btn,
.search-mobile-btn,
.cart-icon {
    pointer-events: auto !important;
    user-select: none;
}

.mobile-menu-btn i,
.search-mobile-btn i,
.cart-icon i {
    pointer-events: none;
}

/* Ensure header is always on top and clickable */
header {
    pointer-events: auto !important;
}

header * {
    pointer-events: auto;
}

/* Fix for iOS Safari touch issues */
@supports (-webkit-touch-callout: none) {
    .mobile-menu-btn,
    .search-mobile-btn,
    .cart-icon {
        -webkit-tap-highlight-color: rgba(86, 69, 147, 0.2);
    }
}

/* ========== MOBILE TOUCH TARGET IMPROVEMENTS ========== */
/* Ensure minimum 44x44px touch targets for accessibility and usability */
@media (max-width: 900px) {
    /* All clickable elements in header */
    .header-actions > * {
        min-width: 44px;
        min-height: 44px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }
    
    /* Prevent any overlapping elements */
    .header-container > * {
        flex-shrink: 0;
    }
    
    /* Logo should not overlap icons */
    .logo {
        flex-shrink: 1;
        min-width: 0;
    }
    
    /* Ensure header actions don't wrap */
    .header-actions {
        flex-shrink: 0;
        flex-wrap: nowrap;
    }
    
    /* Add visual feedback on touch */
    .mobile-menu-btn:active,
    .search-mobile-btn:active,
    .cart-icon:active {
        opacity: 0.7;
        transform: scale(0.95);
    }
    
    /* Ensure icons are visible and not hidden */
    .mobile-menu-btn,
    .search-mobile-btn {
        visibility: visible !important;
        opacity: 1 !important;
    }
}

/* Extra small devices - ensure even better touch targets */
@media (max-width: 480px) {
    .header-actions {
        gap: 4px;
    }
    
    .header-actions > * {
        min-width: 40px;
        min-height: 40px;
    }
}

/* ========== DEBUG MODE (remove after testing) ========== */
/* Uncomment to visualize touch targets */
/*
@media (max-width: 900px) {
    .mobile-menu-btn,
    .search-mobile-btn,
    .cart-icon {
        outline: 2px dashed red !important;
        background: rgba(255, 0, 0, 0.1) !important;
    }
}
*/
