﻿/* ══════════════════════════════════════════════════════
   TRI-PLATFORM HERO STYLES
   Modern, accessible, conversion-optimized design
══════════════════════════════════════════════════════ */

:root {
    --color-commerce: #667eea;
    --color-commerce-light: #764ba2;
    --color-services: #f093fb;
    --color-services-light: #f5576c;
    --color-artisan: #4facfe;
    --color-artisan-light: #00f2fe;
    --gradient-commerce: linear-gradient(135deg, var(--color-commerce) 0%, var(--color-commerce-light) 100%);
    --gradient-services: linear-gradient(135deg, var(--color-services) 0%, var(--color-services-light) 100%);
    --gradient-artisan: linear-gradient(135deg, var(--color-artisan) 0%, var(--color-artisan-light) 100%);
}

/* Hero Tabs Navigation */
.hero-tri-platform {
    position: relative;
    overflow: hidden;
}

.hero-tabs {
    background: #fff;
    border-bottom: 1px solid #e5e7eb;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}

.hero-tabs__nav {
    display: flex;
    gap: 0;
    justify-content: center;
    max-width: 800px;
    margin: 0 auto;
    padding: 0;
}

.hero-tab {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 20px 24px;
    border: none;
    background: transparent;
    cursor: pointer;
    position: relative;
    transition: all 0.3s ease;
    border-bottom: 3px solid transparent;
}

.hero-tab svg {
    width: 28px;
    height: 28px;
    stroke: #6b7280;
    transition: all 0.3s ease;
}

.hero-tab span {
    font-size: 15px;
    font-weight: 600;
    color: #6b7280;
    transition: all 0.3s ease;
}

.hero-tab:hover {
    background: #f9fafb;
}

.hero-tab:hover svg {
    stroke: #374151;
    transform: scale(1.1);
}

.hero-tab:hover span {
    color: #374151;
}

/* Active tab states */
.hero-tab.active[data-platform="marketplace"] {
    border-bottom-color: var(--color-commerce);
    background: linear-gradient(to bottom, rgba(102, 126, 234, 0.05), transparent);
}

.hero-tab.active[data-platform="marketplace"] svg {
    stroke: var(--color-commerce);
}

.hero-tab.active[data-platform="marketplace"] span {
    color: var(--color-commerce);
}

.hero-tab.active[data-platform="services"] {
    border-bottom-color: var(--color-services);
    background: linear-gradient(to bottom, rgba(240, 147, 251, 0.05), transparent);
}

.hero-tab.active[data-platform="services"] svg {
    stroke: var(--color-services);
}

.hero-tab.active[data-platform="services"] span {
    color: var(--color-services);
}

.hero-tab.active[data-platform="artisan"] {
    border-bottom-color: var(--color-artisan);
    background: linear-gradient(to bottom, rgba(79, 172, 254, 0.05), transparent);
}

.hero-tab.active[data-platform="artisan"] svg {
    stroke: var(--color-artisan);
}

.hero-tab.active[data-platform="artisan"] span {
    color: var(--color-artisan);
}

/* Hero Content Sections */
.hero-content {
    display: none;
    min-height: 600px;
    position: relative;
    animation: fadeIn 0.5s ease-in-out;
}

.hero-content.active {
    display: block;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Gradient overlays for each platform */
.hero__gradient--commerce {
    background: var(--gradient-commerce);
}

.hero__gradient--services {
    background: var(--gradient-services);
}

.hero__gradient--artisan {
    background: var(--gradient-artisan);
}

/* Search Bar Component */
.search-bar {
    display: flex;
    align-items: stretch;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.15);
    overflow: hidden;
    max-width: 800px;
    margin: 32px 0;
    transition: box-shadow 0.3s ease;
}

.search-bar:focus-within {
    box-shadow: 0 15px 50px rgba(0,0,0,0.2);
}

.search-bar__icon {
    width: 24px;
    height: 24px;
    margin: auto 16px;
    stroke: #9ca3af;
}

.search-bar__input {
    flex: 1;
    border: none;
    padding: 16px 8px;
    font-size: 16px;
    outline: none;
}

.search-bar__input::placeholder {
    color: #9ca3af;
}

.search-bar__category {
    border: none;
    border-left: 1px solid #e5e7eb;
    padding: 16px 20px;
    font-size: 14px;
    color: #374151;
    outline: none;
    cursor: pointer;
    background: #f9fafb;
    min-width: 180px;
}

.search-bar__btn {
    background: var(--gradient-commerce);
    color: #fff;
    border: none;
    padding: 16px 32px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.search-bar__btn:hover {
    transform: scale(1.02);
    box-shadow: 0 8px 20px rgba(102, 126, 234, 0.4);
}

/* Quick Navigation Cards */
.hero__quick-nav {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    margin-top: 40px;
}

.quick-cat-card,
.quick-service-card {
    background: #fff;
    border-radius: 12px;
    padding: 20px;
    text-align: center;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    cursor: pointer;
    transition: all 0.3s ease;
}

.quick-cat-card:hover,
.quick-service-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 24px rgba(0,0,0,0.15);
}

.quick-cat-card img {
    width: 100%;
    height: 80px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 12px;
}

.quick-cat-card span,
.quick-service-card span {
    display: block;
    font-weight: 600;
    color: #1f2937;
    font-size: 14px;
}

.quick-service-card__icon {
    width: 48px;
    height: 48px;
    margin: 0 auto 12px;
    padding: 12px;
    background: var(--gradient-services);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.quick-service-card__icon svg {
    width: 24px;
    height: 24px;
    stroke: #fff;
}

/* Platform Showcase Section */
.platform-showcase {
    padding: 80px 0;
    background: linear-gradient(to bottom, #f9fafb 0%, #fff 100%);
}

.platform-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
    margin-top: 48px;
}

.platform-card {
    background: #fff;
    border-radius: 16px;
    padding: 40px;
    text-align: center;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.platform-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--gradient-commerce);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.platform-card--commerce::before {
    background: var(--gradient-commerce);
}

.platform-card--services::before {
    background: var(--gradient-services);
}

.platform-card--artisan::before {
    background: var(--gradient-artisan);
}

.platform-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 40px rgba(0,0,0,0.15);
}

.platform-card:hover::before {
    transform: scaleX(1);
}

.platform-card__icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 24px;
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.platform-card--commerce .platform-card__icon {
    background: var(--gradient-commerce);
}

.platform-card--services .platform-card__icon {
    background: var(--gradient-services);
}

.platform-card--artisan .platform-card__icon {
    background: var(--gradient-artisan);
}

.platform-card__icon svg {
    width: 40px;
    height: 40px;
    stroke: #fff;
}

.platform-card h3 {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 12px;
    color: #1f2937;
}

.platform-card p {
    color: #6b7280;
    line-height: 1.6;
    margin-bottom: 24px;
}

.platform-card__link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--color-commerce);
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
}

.platform-card--services .platform-card__link {
    color: var(--color-services);
}

.platform-card--artisan .platform-card__link {
    color: var(--color-artisan);
}

.platform-card__link:hover {
    gap: 12px;
}

.platform-card__stats {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #e5e7eb;
    font-size: 13px;
    color: #6b7280;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

/* Remove or modify the gradient background */
.tri-platform-hero {
    background: #ffffff; /* Replace gradient with solid white */
    padding: 4rem 0;
    position: relative;
    overflow: hidden;
}

/* If you want to keep some visual interest without gradient, use a subtle pattern or color */
/* Alternative option:
.tri-platform-hero {
    background: #f8f9fa;
    padding: 4rem 0;
    position: relative;
    overflow: hidden;
}
*/

/* Ensure Font Awesome icons are displayed proportionally */
.tri-platform-hero .platform-card i,
.tri-platform-hero .feature-icon i {
    display: inline-block;
    width: 1em;
    height: 1em;
    line-height: 1;
    vertical-align: middle;
}

/* Fix icon container sizing */
.tri-platform-hero .icon-wrapper,
.tri-platform-hero .feature-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 80px;
    height: 80px;
    margin: 0 auto 1rem;
}

/* Ensure images maintain aspect ratio */
.tri-platform-hero img {
    max-width: 100%;
    height: auto;
    object-fit: contain;
}

/* Fix platform card images */
.tri-platform-hero .platform-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-radius: 8px 8px 0 0;
}

/* Fix any hero section images */
.tri-platform-hero .hero-image,
.tri-platform-hero .platform-illustration {
    max-width: 100%;
    height: auto;
    object-fit: contain;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .platform-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .hero__quick-nav {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .hero-tabs__nav {
        gap: 0;
    }

    .hero-tab {
        padding: 16px 12px;
        gap: 6px;
    }

    .hero-tab svg {
        width: 24px;
        height: 24px;
    }

    .hero-tab span {
        font-size: 13px;
    }

    .search-bar {
        flex-direction: column;
    }

    .search-bar__category {
        border-left: none;
        border-top: 1px solid #e5e7eb;
    }

    .hero__quick-nav {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
}

@media (max-width: 480px) {
    .hero-tab span {
        font-size: 11px;
    }

    .hero__quick-nav {
        grid-template-columns: 1fr;
    }
}

/* Section Headers */
.section-header--center {
    text-align: center;
    max-width: 700px;
    margin: 0 auto 48px;
}

.section-title {
    font-size: 36px;
    font-weight: 800;
    color: #1f2937;
    margin-bottom: 16px;
}

.section-desc {
    font-size: 18px;
    color: #6b7280;
    line-height: 1.6;
}

/* Accessibility */
.hero-tab:focus-visible {
    outline: 3px solid var(--color-commerce);
    outline-offset: 2px;
}

.search-bar__input:focus,
.search-bar__category:focus,
.search-bar__btn:focus {
    outline: 3px solid rgba(102, 126, 234, 0.3);
    outline-offset: 2px;
}

/* Print styles */
@media print {
    .hero-tabs,
    .hero-content:not(.active) {
        display: none;
    }
}