/* Products Page Specific Styles */

/* Hero Section */
.products-hero {
    min-height: 60vh;
    display: flex;
    align-items: center;
    position: relative;
    background: linear-gradient(135deg, var(--dark-bg) 0%, var(--dark-card) 50%, var(--dark-bg) 100%);
    padding: 120px 0 80px;
    overflow: hidden;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 30% 70%, rgba(99, 102, 241, 0.2) 0%, transparent 50%),
                radial-gradient(circle at 70% 30%, rgba(139, 92, 246, 0.2) 0%, transparent 50%);
    z-index: 0;
}

.hero-content {
    position: relative;
    z-index: 1;
    text-align: center;
}

.hero-title {
    font-size: 3.5rem;
    margin-bottom: 1.5rem;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 1.3rem;
    color: var(--text-secondary);
    margin-bottom: 3rem;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.6;
}

/* Filter Buttons */
.hero-filters {
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 0.8rem 1.5rem;
    border: 2px solid rgba(99, 102, 241, 0.3);
    background: transparent;
    color: var(--text-secondary);
    border-radius: 25px;
    font-weight: 500;
    transition: var(--transition);
    cursor: pointer;
    font-size: 0.9rem;
}

.filter-btn:hover,
.filter-btn.active {
    background: var(--gradient-primary);
    color: white;
    border-color: transparent;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(99, 102, 241, 0.4);
}

/* Products Section */
.products-section {
    padding: 6rem 0;
    background: var(--dark-bg);
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2.5rem;
    perspective: 1000px;
}

/* Product Cards with Flip Effect */
.product-card {
    height: 400px;
    position: relative;
    transition: var(--transition);
    opacity: 1;
    transform: scale(1);
}

.product-card.filtered {
    opacity: 0;
    transform: scale(0.8);
    pointer-events: none;
}

.card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    text-align: center;
    transition: transform 0.8s;
    transform-style: preserve-3d;
    cursor: pointer;
}

.product-card:hover .card-inner {
    transform: rotateY(180deg);
}

.card-front,
.card-back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    border-radius: var(--border-radius);
    padding: 2.5rem 2rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: var(--dark-card);
}

.card-front {
    background: linear-gradient(135deg, var(--dark-card) 0%, rgba(30, 41, 59, 0.8) 100%);
}

.card-back {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: white;
    transform: rotateY(180deg);
}

.product-icon {
    font-size: 3.5rem;
    margin-bottom: 1.5rem;
    display: block;
}

.product-title {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.card-back .product-title,
.card-back h4 {
    color: white;
}

.product-excerpt {
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 1.5rem;
    flex-grow: 1;
}

.product-tags {
    display: flex;
    gap: 0.5rem;
    justify-content: center;
    flex-wrap: wrap;
}

.tag {
    background: rgba(99, 102, 241, 0.2);
    color: var(--primary-color);
    padding: 0.3rem 0.8rem;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: 500;
    border: 1px solid rgba(99, 102, 241, 0.3);
}

.card-back .tag {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border-color: rgba(255, 255, 255, 0.3);
}

/* Card Back Content */
.card-back h4 {
    margin-bottom: 1.5rem;
    font-size: 1.3rem;
}

.feature-list {
    list-style: none;
    margin-bottom: 2rem;
    text-align: left;
}

.feature-list li {
    padding: 0.5rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    position: relative;
    padding-left: 1.5rem;
}

.feature-list li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--accent-color);
    font-weight: bold;
}

.product-metrics {
    display: flex;
    justify-content: space-around;
    margin-bottom: 2rem;
}

.metric {
    text-align: center;
}

.metric-value {
    display: block;
    font-family: 'Orbitron', monospace;
    font-size: 1.5rem;
    font-weight: 900;
    color: var(--accent-color);
    line-height: 1;
}

.metric-label {
    font-size: 0.9rem;
    opacity: 0.8;
    margin-top: 0.3rem;
}

.product-cta {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    padding: 0.8rem 1.5rem;
    border-radius: 25px;
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition);
    border: 2px solid rgba(255, 255, 255, 0.3);
    display: inline-block;
}

.product-cta:hover {
    background: white;
    color: var(--primary-color);
    transform: translateY(-2px);
}

/* Comparison Section */
.comparison-section {
    padding: 6rem 0;
    background: rgba(30, 41, 59, 0.3);
}

.comparison-table-wrapper {
    overflow-x: auto;
    margin-top: 3rem;
    border-radius: var(--border-radius);
    background: var(--dark-card);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.comparison-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}

.comparison-table th,
.comparison-table td {
    padding: 1.5rem 1rem;
    text-align: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.comparison-table th {
    background: var(--gradient-primary);
    color: white;
    font-weight: 600;
    font-family: 'Orbitron', monospace;
}

.comparison-table td {
    color: var(--text-secondary);
}

.comparison-table tr:hover {
    background: rgba(99, 102, 241, 0.1);
}

.comparison-table td:first-child {
    font-weight: 600;
    color: var(--text-primary);
    text-align: left;
}

/* CTA Section */
.cta-section {
    padding: 6rem 0;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    text-align: center;
}

.cta-content h2 {
    color: white;
    margin-bottom: 1.5rem;
    font-size: 2.5rem;
}

.cta-content p {
    color: rgba(255, 255, 255, 0.9);
    font-size: 1.2rem;
    margin-bottom: 2.5rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.cta-buttons {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    flex-wrap: wrap;
}

.cta-section .btn {
    padding: 1rem 2rem;
    font-size: 1.1rem;
}

.cta-section .btn-primary {
    background: white;
    color: var(--primary-color);
}

.cta-section .btn-primary:hover {
    background: var(--accent-color);
    color: white;
}

.cta-section .btn-outline {
    border-color: white;
    color: white;
}

.cta-section .btn-outline:hover {
    background: white;
    color: var(--primary-color);
}

/* Animations */
@keyframes cardFloat {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-5px);
    }
}

.product-card {
    animation: cardFloat 6s ease-in-out infinite;
}

.product-card:nth-child(2n) {
    animation-delay: 1s;
}

.product-card:nth-child(3n) {
    animation-delay: 2s;
}

/* Filter Animation */
.products-grid {
    transition: var(--transition);
}

.product-card {
    transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Responsive Design */
@media (max-width: 1024px) {
    .products-grid {
        grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
        gap: 2rem;
    }
    
    .comparison-table {
        font-size: 0.8rem;
    }
    
    .comparison-table th,
    .comparison-table td {
        padding: 1rem 0.5rem;
    }
}

@media (max-width: 768px) {
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-subtitle {
        font-size: 1.1rem;
    }
    
    .hero-filters {
        gap: 0.5rem;
    }
    
    .filter-btn {
        padding: 0.6rem 1rem;
        font-size: 0.8rem;
    }
    
    .products-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .product-card {
        height: 350px;
    }
    
    .card-front,
    .card-back {
        padding: 2rem 1.5rem;
    }
    
    .product-icon {
        font-size: 2.5rem;
    }
    
    .product-title {
        font-size: 1.3rem;
    }
    
    .cta-content h2 {
        font-size: 2rem;
    }
    
    .cta-content p {
        font-size: 1rem;
    }
    
    .cta-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .cta-section .btn {
        width: 100%;
        max-width: 300px;
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-filters {
        flex-direction: column;
        align-items: center;
    }
    
    .filter-btn {
        width: 200px;
    }
    
    .product-card {
        height: 320px;
    }
    
    .card-front,
    .card-back {
        padding: 1.5rem 1rem;
    }
    
    .comparison-table-wrapper {
        margin: 2rem -1rem 0;
        border-radius: 0;
    }
}

/* Accessibility and Performance */
@media (prefers-reduced-motion: reduce) {
    .card-inner {
        transition: none;
    }
    
    .product-card {
        animation: none;
    }
    
    .product-card:hover .card-inner {
        transform: none;
    }
}

/* Touch devices - show back on tap */
@media (hover: none) {
    .product-card.touched .card-inner {
        transform: rotateY(180deg);
    }
}

/* Loading states */
.product-card.loading {
    opacity: 0.5;
    pointer-events: none;
}

.product-card.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 30px;
    height: 30px;
    border: 3px solid var(--primary-color);
    border-top: 3px solid transparent;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    transform: translate(-50%, -50%);
}

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