/* ========================================
   MARKSY - Products Page Styles
   ======================================== */

/* Page Header */
.page-header {
    background: linear-gradient(135deg, var(--navy) 0%, var(--navy-light) 100%);
    padding: var(--space-3xl) 0;
    position: relative;
    overflow: hidden;
}

.page-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.03'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    opacity: 0.5;
}

.page-header__content {
    position: relative;
    text-align: center;
    max-width: 700px;
    margin: 0 auto;
}

.page-header h1 {
    font-family: var(--font-display);
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--white);
    margin-bottom: var(--space-md);
}

.page-header p {
    font-size: 1.125rem;
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.6;
}

@media (max-width: 768px) {
    .page-header h1 {
        font-size: 1.75rem;
    }
    
    .page-header p {
        font-size: 1rem;
    }
}

/* Products Main */
.products-main {
    padding: var(--space-2xl) 0 var(--space-3xl);
    background: var(--gray-50);
    min-height: calc(100vh - 400px);
}

/* Products Layout */
.products-layout {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: var(--space-2xl);
    align-items: start;
}

@media (max-width: 1024px) {
    .products-layout {
        grid-template-columns: 1fr;
    }
    
    .products-sidebar {
        display: none;
    }
    
    .products-sidebar.active {
        display: block;
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        z-index: 1000;
        background: var(--white);
        padding: var(--space-lg);
        overflow-y: auto;
    }
}

/* Sidebar */
.products-sidebar {
    position: sticky;
    top: 100px;
}

.sidebar-section {
    background: var(--white);
    border-radius: var(--radius-lg);
    padding: var(--space-lg);
    margin-bottom: var(--space-lg);
    box-shadow: var(--shadow-sm);
}

.sidebar-section__title {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    font-size: 0.9375rem;
    font-weight: 700;
    color: var(--navy);
    margin-bottom: var(--space-md);
}

.sidebar-section__title svg {
    width: 18px;
    height: 18px;
    color: var(--teal);
}

/* Search Filter */
.search-filter {
    display: flex;
    gap: var(--space-xs);
}

.search-filter__input {
    flex: 1;
    padding: var(--space-sm) var(--space-md);
    border: 2px solid var(--gray-200);
    border-radius: var(--radius-md);
    font-size: 0.875rem;
}

.search-filter__input:focus {
    outline: none;
    border-color: var(--teal);
}

.search-filter__btn {
    padding: var(--space-sm);
    background: var(--teal);
    color: var(--white);
    border: none;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: background var(--transition-fast);
}

.search-filter__btn:hover {
    background: var(--teal-dark);
}

.search-filter__btn svg {
    width: 18px;
    height: 18px;
}

/* Filter Options */
.filter-options {
    display: flex;
    flex-direction: column;
    gap: var(--space-sm);
}

.filter-option {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    cursor: pointer;
    padding: var(--space-xs) 0;
}

.filter-option input {
    display: none;
}

.filter-option__mark {
    width: 18px;
    height: 18px;
    border: 2px solid var(--gray-300);
    border-radius: var(--radius-sm);
    position: relative;
    flex-shrink: 0;
    transition: all var(--transition-fast);
}

.filter-option input:checked + .filter-option__mark {
    background: var(--teal);
    border-color: var(--teal);
}

.filter-option input:checked + .filter-option__mark::after {
    content: '';
    position: absolute;
    top: 2px;
    left: 5px;
    width: 4px;
    height: 8px;
    border: solid var(--white);
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

.filter-option__label {
    flex: 1;
    font-size: 0.875rem;
    color: var(--gray-700);
}

.filter-option__count {
    font-size: 0.75rem;
    color: var(--gray-400);
    background: var(--gray-100);
    padding: 2px 6px;
    border-radius: var(--radius-full);
}

/* Price Filter */
.price-filter__inputs {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    margin-bottom: var(--space-md);
}

.price-filter__inputs input {
    flex: 1;
    padding: var(--space-sm);
    border: 2px solid var(--gray-200);
    border-radius: var(--radius-md);
    font-size: 0.875rem;
    max-width: 80px;
}

.price-filter__inputs input:focus {
    outline: none;
    border-color: var(--teal);
}

.price-filter__inputs span {
    color: var(--gray-400);
    font-size: 0.875rem;
}

/* Sidebar Help */
.sidebar-help {
    background: linear-gradient(135deg, var(--teal) 0%, var(--teal-dark) 100%);
    border-radius: var(--radius-lg);
    padding: var(--space-lg);
    color: var(--white);
    text-align: center;
}

.sidebar-help__icon {
    width: 48px;
    height: 48px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto var(--space-md);
}

.sidebar-help__icon svg {
    width: 24px;
    height: 24px;
}

.sidebar-help h4 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: var(--space-xs);
}

.sidebar-help p {
    font-size: 0.8125rem;
    opacity: 0.9;
    margin-bottom: var(--space-md);
}

.sidebar-help__phone {
    display: block;
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--white);
}

/* Products Content */
.products-content {
    min-width: 0;
}

/* Products Section */
.products-section {
    margin-bottom: var(--space-3xl);
}

.products-section__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--space-xl);
    flex-wrap: wrap;
    gap: var(--space-md);
}

.products-section__title-group {
    display: flex;
    align-items: center;
    gap: var(--space-md);
}

.products-section__title {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--navy);
}

.products-section__title svg {
    width: 28px;
    height: 28px;
    color: var(--teal);
}

.products-section__badge {
    display: inline-block;
    padding: var(--space-xs) var(--space-md);
    background: linear-gradient(135deg, var(--breezy-blue) 0%, var(--turquoise) 100%);
    color: var(--navy);
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-radius: var(--radius-full);
}

.products-section__link {
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--teal);
}

.products-section__link:hover {
    text-decoration: underline;
}

/* Carousel Controls */
.carousel-controls {
    display: flex;
    gap: var(--space-sm);
}

.carousel-btn {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--white);
    border: 2px solid var(--gray-200);
    border-radius: 50%;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.carousel-btn:hover {
    border-color: var(--teal);
    color: var(--teal);
}

.carousel-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.carousel-btn svg {
    width: 20px;
    height: 20px;
}

/* Products Carousel */
.products-carousel {
    position: relative;
    overflow: hidden;
    margin: 0 -var(--space-sm);
    padding: 0 var(--space-sm);
}

.products-carousel__track {
    display: flex;
    gap: var(--space-lg);
    transition: transform 0.5s ease;
}

.products-carousel .product-card {
    flex: 0 0 calc(33.333% - var(--space-lg) * 2 / 3);
    min-width: 280px;
}

@media (max-width: 1024px) {
    .products-carousel .product-card {
        flex: 0 0 calc(50% - var(--space-lg) / 2);
    }
}

@media (max-width: 640px) {
    .products-carousel .product-card {
        flex: 0 0 100%;
    }
}

/* Products Grid */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: var(--space-lg);
}

/* Product Card */
.product-card {
    background: var(--white);
    border-radius: var(--radius-xl);
    padding: var(--space-xl);
    box-shadow: var(--shadow-sm);
    transition: all var(--transition-base);
    display: flex;
    flex-direction: column;
    position: relative;
}

.product-card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-4px);
}

.product-card--featured {
    border: 2px solid transparent;
    background: linear-gradient(var(--white), var(--white)) padding-box,
                linear-gradient(135deg, var(--breezy-blue), var(--turquoise)) border-box;
}

.product-card__badge {
    position: absolute;
    top: var(--space-md);
    right: var(--space-md);
    padding: var(--space-xs) var(--space-sm);
    background: var(--success);
    color: var(--white);
    font-size: 0.6875rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-radius: var(--radius-full);
}

.product-card__badge--info {
    background: var(--info);
}

.product-card__icon {
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--breezy-blue) 0%, var(--turquoise) 100%);
    border-radius: var(--radius-lg);
    margin-bottom: var(--space-lg);
}

.product-card__icon svg {
    width: 28px;
    height: 28px;
    color: var(--navy);
}

.product-card__title {
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--navy);
    margin-bottom: var(--space-sm);
    line-height: 1.3;
}

.product-card__desc {
    font-size: 0.9375rem;
    color: var(--gray-500);
    line-height: 1.5;
    margin-bottom: var(--space-lg);
    flex: 1;
}

.product-card__features {
    display: flex;
    flex-direction: column;
    gap: var(--space-xs);
    margin-bottom: var(--space-lg);
}

.product-card__features span {
    display: flex;
    align-items: center;
    gap: var(--space-xs);
    font-size: 0.8125rem;
    color: var(--gray-600);
}

.product-card__features svg {
    width: 14px;
    height: 14px;
    color: var(--success);
}

.product-card__pricing {
    display: flex;
    align-items: baseline;
    gap: var(--space-xs);
    margin-bottom: var(--space-lg);
}

.product-card__price {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--navy);
}

.product-card__price-note {
    font-size: 0.875rem;
    color: var(--gray-500);
}

/* Bundles Section */
.products-section--bundles {
    background: linear-gradient(135deg, var(--navy) 0%, var(--navy-light) 100%);
    border-radius: var(--radius-2xl);
    padding: var(--space-2xl);
}

.products-section--bundles .products-section__title {
    color: var(--white);
}

.products-section--bundles .products-section__title svg {
    color: var(--turquoise);
}

.products-section--bundles .products-section__badge {
    background: var(--success);
    color: var(--white);
}

/* Bundles Grid */
.bundles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: var(--space-lg);
}

/* Bundle Card */
.bundle-card {
    background: var(--white);
    border-radius: var(--radius-xl);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    position: relative;
    transition: transform var(--transition-base);
}

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

.bundle-card--featured {
    border: 3px solid var(--turquoise);
    box-shadow: 0 8px 32px rgba(0, 255, 255, 0.2);
}

.bundle-card__badge {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    padding: var(--space-xs) var(--space-lg);
    background: var(--turquoise);
    color: var(--navy);
    font-size: 0.6875rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-radius: 0 0 var(--radius-md) var(--radius-md);
}

.bundle-card__header {
    padding: var(--space-xl);
    text-align: center;
    background: var(--gray-50);
}

.bundle-card--featured .bundle-card__header {
    padding-top: var(--space-2xl);
}

.bundle-card__header h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--navy);
    margin-bottom: var(--space-xs);
}

.bundle-card__header p {
    font-size: 0.875rem;
    color: var(--gray-500);
}

.bundle-card__body {
    padding: var(--space-xl);
    flex: 1;
}

.bundle-card__features {
    list-style: none;
    padding: 0;
    margin: 0;
}

.bundle-card__features li {
    display: flex;
    align-items: flex-start;
    gap: var(--space-sm);
    padding: var(--space-sm) 0;
    font-size: 0.9375rem;
    color: var(--gray-700);
}

.bundle-card__features svg {
    width: 18px;
    height: 18px;
    color: var(--success);
    flex-shrink: 0;
    margin-top: 2px;
}

.bundle-card__footer {
    padding: var(--space-xl);
    border-top: 1px solid var(--gray-100);
    text-align: center;
}

.bundle-card__pricing {
    display: flex;
    justify-content: center;
    align-items: baseline;
    gap: var(--space-sm);
    margin-bottom: var(--space-xs);
}

.bundle-card__original {
    font-size: 1rem;
    color: var(--gray-400);
    text-decoration: line-through;
}

.bundle-card__price {
    font-size: 2rem;
    font-weight: 700;
    color: var(--navy);
}

.bundle-card__savings {
    display: inline-block;
    padding: var(--space-xs) var(--space-sm);
    background: rgba(16, 185, 129, 0.1);
    color: var(--success);
    font-size: 0.8125rem;
    font-weight: 600;
    border-radius: var(--radius-full);
    margin-bottom: var(--space-lg);
}

/* Products Results */
.products-results {
    text-align: center;
    padding: var(--space-lg);
    color: var(--gray-500);
    font-size: 0.9375rem;
}

/* No Results */
.no-results {
    text-align: center;
    padding: var(--space-3xl);
    background: var(--white);
    border-radius: var(--radius-xl);
}

.no-results__icon {
    width: 80px;
    height: 80px;
    background: var(--gray-100);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto var(--space-lg);
}

.no-results__icon svg {
    width: 40px;
    height: 40px;
    color: var(--gray-400);
}

.no-results h3 {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--navy);
    margin-bottom: var(--space-sm);
}

.no-results p {
    color: var(--gray-500);
    margin-bottom: var(--space-lg);
}

/* Mobile Filter Toggle */
.mobile-filter-toggle {
    display: none;
    position: fixed;
    bottom: var(--space-lg);
    left: 50%;
    transform: translateX(-50%);
    z-index: 100;
    padding: var(--space-md) var(--space-xl);
    background: var(--navy);
    color: var(--white);
    border: none;
    border-radius: var(--radius-full);
    font-size: 0.9375rem;
    font-weight: 600;
    cursor: pointer;
    box-shadow: var(--shadow-lg);
}

.mobile-filter-toggle svg {
    width: 18px;
    height: 18px;
    margin-right: var(--space-sm);
}

@media (max-width: 1024px) {
    .mobile-filter-toggle {
        display: flex;
        align-items: center;
    }
}

/* Hidden Products */
.product-card.hidden {
    display: none;
}

/* Loading State */
.products-loading {
    display: flex;
    justify-content: center;
    padding: var(--space-3xl);
}

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

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