/* ========================================
   MainStreet Exchange - Homepage Styles
   Blending Traditional Americana with Modern Marketplace
   ======================================== */

/* ========================================
   CSS RESET & BASE
   ======================================== */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    line-height: 1.6;
    color: #1e293b;
    background-color: #ffffff;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ========================================
   NAVIGATION
   ======================================== */

.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid #e5e7eb;
    z-index: 1000;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.nav-container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo a {
    font-size: 1.25rem;
    font-weight: 700;
    color: #1e293b;
    text-decoration: none;
    letter-spacing: -0.02em;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.nav-link {
    color: #64748b;
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    transition: color 0.2s ease;
}

.nav-link:hover {
    color: #1e293b;
}

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 4px;
    background: none;
    border: none;
    cursor: pointer;
}

.nav-toggle span {
    width: 24px;
    height: 2px;
    background-color: #1e293b;
    transition: all 0.3s ease;
}

/* ========================================
   BUTTONS
   ======================================== */

.btn {
    display: inline-block;
    padding: 0.875rem 1.75rem;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1rem;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s ease;
    border: 2px solid transparent;
    font-family: inherit;
    white-space: nowrap;
}

.btn-primary {
    background: linear-gradient(135deg, #2563eb 0%, #1e40af 100%);
    color: #ffffff;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.25);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(37, 99, 235, 0.35);
}

.btn-primary-nav {
    background: linear-gradient(135deg, #2563eb 0%, #1e40af 100%);
    color: #ffffff;
    padding: 0.625rem 1.25rem;
    font-size: 0.9rem;
}

.btn-secondary {
    background-color: #ffffff;
    color: #1e293b;
    border-color: #d1d5db;
}

.btn-secondary:hover {
    background-color: #f8fafc;
    border-color: #94a3b8;
}

.btn-secondary-light {
    background-color: rgba(255, 255, 255, 0.1);
    color: #ffffff;
    border-color: rgba(255, 255, 255, 0.3);
}

.btn-secondary-light:hover {
    background-color: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.5);
}

.btn-outline {
    background-color: transparent;
    color: #2563eb;
    border-color: #2563eb;
}

.btn-outline:hover {
    background-color: #eff6ff;
}

.btn-outline-full {
    width: 100%;
    background-color: transparent;
    color: #2563eb;
    border-color: #e5e7eb;
}

.btn-outline-full:hover {
    border-color: #2563eb;
    background-color: #eff6ff;
}

.btn-primary-full {
    width: 100%;
    background: linear-gradient(135deg, #2563eb 0%, #1e40af 100%);
    color: #ffffff;
}

.btn-large {
    padding: 1.125rem 2.25rem;
    font-size: 1.1rem;
}

/* ========================================
   HERO SECTION
   ======================================== */

.hero {
    margin-top: 80px;
    padding: 6rem 2rem;
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    overflow: hidden;
}

.hero-content {
    max-width: 1280px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.hero-text {
    animation: fadeInUp 0.8s ease;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1.1;
    color: #1e293b;
    margin-bottom: 1.5rem;
    letter-spacing: -0.03em;
}

.hero-title .highlight {
    background: linear-gradient(135deg, #2563eb 0%, #7c3aed 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: #475569;
    margin-bottom: 2.5rem;
    line-height: 1.7;
}

.hero-cta {
    display: flex;
    gap: 1rem;
    margin-bottom: 3rem;
}

.hero-stats {
    display: flex;
    gap: 3rem;
    padding-top: 2rem;
    border-top: 1px solid #e5e7eb;
}

.stat {
    display: flex;
    flex-direction: column;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 800;
    color: #2563eb;
    line-height: 1;
    margin-bottom: 0.5rem;
}

.stat-label {
    font-size: 0.875rem;
    color: #64748b;
    font-weight: 500;
}

.hero-image {
    position: relative;
    animation: fadeInRight 0.8s ease;
}

.hero-img {
    width: 100%;
    height: auto;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
    object-fit: cover;
}

.hero-badge {
    position: absolute;
    bottom: 2rem;
    left: 2rem;
    background: #ffffff;
    padding: 1.25rem 1.5rem;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
    display: flex;
    align-items: center;
    gap: 1rem;
    animation: floatBadge 3s ease-in-out infinite;
}

.badge-icon {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: #ffffff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.25rem;
}

.badge-title {
    font-weight: 600;
    color: #1e293b;
    font-size: 0.95rem;
}

.badge-subtitle {
    font-size: 0.875rem;
    color: #64748b;
}

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

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

@keyframes floatBadge {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

/* ========================================
   CONTAINER & SECTION UTILITIES
   ======================================== */

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 2rem;
}

section {
    padding: 6rem 0;
}

.section-header {
    margin-bottom: 4rem;
}

.section-header.centered {
    text-align: center;
}

.section-title {
    font-size: 2.75rem;
    font-weight: 800;
    color: #1e293b;
    margin-bottom: 1rem;
    letter-spacing: -0.02em;
}

.section-subtitle {
    font-size: 1.25rem;
    color: #64748b;
    line-height: 1.6;
}

/* ========================================
   PROBLEM SECTION
   ======================================== */

.problem-section {
    background-color: #ffffff;
}

.problem-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    margin-bottom: 4rem;
}

.problem-card {
    text-align: center;
    padding: 2rem;
}

.problem-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 1.5rem;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
}

.problem-icon.red {
    background: linear-gradient(135deg, #fef2f2 0%, #fee2e2 100%);
}

.problem-icon.orange {
    background: linear-gradient(135deg, #fff7ed 0%, #fed7aa 100%);
}

.problem-icon.yellow {
    background: linear-gradient(135deg, #fefce8 0%, #fef08a 100%);
}

.problem-icon.purple {
    background: linear-gradient(135deg, #faf5ff 0%, #e9d5ff 100%);
}

.problem-card h3 {
    font-size: 1.25rem;
    color: #1e293b;
    margin-bottom: 0.75rem;
    font-weight: 700;
}

.problem-card p {
    color: #64748b;
    line-height: 1.6;
}

.stat-highlight {
    text-align: center;
    padding: 3rem;
    background: linear-gradient(135deg, #fef2f2 0%, #fee2e2 100%);
    border-radius: 16px;
    border: 2px solid #fecaca;
}

.stat-highlight-number {
    font-size: 5rem;
    font-weight: 900;
    color: #dc2626;
    line-height: 1;
    margin-bottom: 1rem;
}

.stat-highlight-text {
    font-size: 1.5rem;
    color: #991b1b;
}

.stat-highlight-text strong {
    font-weight: 700;
}

/* ========================================
   SOLUTION SECTION
   ======================================== */

.solution-section {
    background: linear-gradient(180deg, #f8fafc 0%, #ffffff 100%);
}

.solution-features {
    display: flex;
    flex-direction: column;
    gap: 4rem;
}

.feature-large {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.feature-large.reverse {
    direction: rtl;
}

.feature-large.reverse > * {
    direction: ltr;
}

.feature-badge {
    display: inline-block;
    padding: 0.5rem 1rem;
    background: linear-gradient(135deg, #eff6ff 0%, #dbeafe 100%);
    color: #1e40af;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.875rem;
    margin-bottom: 1.5rem;
}

.feature-large-content h3 {
    font-size: 2rem;
    color: #1e293b;
    margin-bottom: 1.25rem;
    font-weight: 700;
}

.feature-large-content p {
    font-size: 1.125rem;
    color: #475569;
    margin-bottom: 2rem;
    line-height: 1.7;
}

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

.feature-list li {
    padding: 0.75rem 0;
    color: #475569;
    font-size: 1.05rem;
}

.feature-large-visual {
    position: relative;
}

.listing-preview {
    background: #ffffff;
    border: 2px solid #e5e7eb;
    border-radius: 16px;
    padding: 2rem;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
}

.preview-header {
    margin-bottom: 1.5rem;
}

.preview-badges {
    display: flex;
    gap: 0.75rem;
}

.badge {
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: 600;
}

.badge-verified {
    background: linear-gradient(135deg, #d1fae5 0%, #a7f3d0 100%);
    color: #065f46;
}

.badge-trust {
    background: linear-gradient(135deg, #dbeafe 0%, #bfdbfe 100%);
    color: #1e40af;
}

.preview-title {
    font-size: 1.75rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 1.5rem;
}

.preview-stats-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.preview-stat-label {
    font-size: 0.875rem;
    color: #64748b;
    margin-bottom: 0.25rem;
}

.preview-stat-value {
    font-size: 1.25rem;
    font-weight: 700;
    color: #1e293b;
}

.filter-preview {
    background: #ffffff;
    border: 2px solid #e5e7eb;
    border-radius: 16px;
    padding: 2rem;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
}

.filter-section {
    margin-bottom: 2rem;
}

.filter-section:last-child {
    margin-bottom: 0;
}

.filter-label {
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 1rem;
    font-size: 0.95rem;
}

.filter-options {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.filter-tag {
    padding: 0.625rem 1.25rem;
    background: #f8fafc;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    font-weight: 500;
    font-size: 0.9rem;
    color: #64748b;
    cursor: pointer;
    transition: all 0.2s ease;
}

.filter-tag:hover {
    border-color: #cbd5e1;
}

.filter-tag.active {
    background: linear-gradient(135deg, #dbeafe 0%, #bfdbfe 100%);
    border-color: #2563eb;
    color: #1e40af;
}

.filter-slider {
    position: relative;
    height: 6px;
    margin: 1.5rem 0;
}

.slider-track {
    position: absolute;
    width: 100%;
    height: 6px;
    background: #e5e7eb;
    border-radius: 3px;
}

.slider-range {
    position: absolute;
    height: 6px;
    background: linear-gradient(90deg, #2563eb 0%, #7c3aed 100%);
    border-radius: 3px;
    width: 60%;
    left: 0;
}

.filter-values {
    color: #64748b;
    font-size: 0.9rem;
    font-weight: 500;
}

/* ========================================
   TRUST SECTION
   ======================================== */

.trust-section {
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
}

.trust-tiers {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.trust-tier {
    background: #ffffff;
    border: 2px solid #e5e7eb;
    border-radius: 16px;
    padding: 2.5rem;
    transition: all 0.3s ease;
}

.trust-tier:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.12);
}

.trust-tier.featured {
    border-color: #2563eb;
    border-width: 3px;
    box-shadow: 0 10px 40px rgba(37, 99, 235, 0.15);
    position: relative;
}

.trust-tier.featured::before {
    content: "MOST POPULAR";
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, #2563eb 0%, #1e40af 100%);
    color: #ffffff;
    padding: 0.375rem 1rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.05em;
}

.tier-header {
    text-align: center;
    padding-bottom: 2rem;
    border-bottom: 2px solid #f1f5f9;
    margin-bottom: 2rem;
}

.tier-badge {
    display: inline-block;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-weight: 700;
    font-size: 0.875rem;
    margin-bottom: 1rem;
}

.tier-badge.level-1 {
    background: linear-gradient(135deg, #f1f5f9 0%, #e2e8f0 100%);
    color: #475569;
}

.tier-badge.level-2 {
    background: linear-gradient(135deg, #dbeafe 0%, #bfdbfe 100%);
    color: #1e40af;
}

.tier-badge.level-3 {
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
    color: #92400e;
}

.tier-header h3 {
    font-size: 1.5rem;
    color: #1e293b;
    margin-bottom: 0.75rem;
}

.tier-price {
    font-size: 2.5rem;
    font-weight: 800;
    color: #1e293b;
}

.tier-features {
    margin-bottom: 2rem;
}

.tier-feature {
    padding: 0.875rem 0;
    color: #475569;
    border-bottom: 1px solid #f1f5f9;
}

.tier-feature:last-child {
    border-bottom: none;
}

.tier-feature strong {
    color: #1e293b;
}

/* ========================================
   HOW IT WORKS
   ======================================== */

.how-it-works {
    background: #ffffff;
}

.steps-container {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 3rem;
}

.step {
    text-align: center;
    position: relative;
}

.step::after {
    content: "→";
    position: absolute;
    top: 30px;
    right: -1.75rem;
    font-size: 2rem;
    color: #cbd5e1;
    font-weight: 300;
}

.step:last-child::after {
    display: none;
}

.step-number {
    width: 64px;
    height: 64px;
    margin: 0 auto 1.5rem;
    background: linear-gradient(135deg, #2563eb 0%, #1e40af 100%);
    color: #ffffff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.75rem;
    font-weight: 800;
    box-shadow: 0 8px 24px rgba(37, 99, 235, 0.3);
}

.step h3 {
    font-size: 1.25rem;
    color: #1e293b;
    margin-bottom: 1rem;
    font-weight: 700;
}

.step p {
    color: #64748b;
    line-height: 1.6;
}

/* ========================================
   SOCIAL PROOF
   ======================================== */

.social-proof {
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
}

.testimonials {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    margin-bottom: 4rem;
}

.testimonial {
    background: #ffffff;
    border-radius: 16px;
    padding: 2rem;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.06);
}

.testimonial-quote {
    font-size: 1.05rem;
    color: #475569;
    line-height: 1.7;
    margin-bottom: 1.5rem;
    font-style: italic;
}

.testimonial-quote::before {
    content: '"';
    font-size: 3rem;
    color: #cbd5e1;
    line-height: 0;
    display: block;
    margin-bottom: 0.5rem;
}

.author-name {
    font-weight: 700;
    color: #1e293b;
    font-size: 1rem;
}

.author-title {
    font-size: 0.9rem;
    color: #64748b;
    margin-top: 0.25rem;
}

.platform-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 3rem;
    padding: 3rem;
    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.06);
}

.platform-stat {
    text-align: center;
}

.platform-stat-number {
    font-size: 3rem;
    font-weight: 800;
    color: #2563eb;
    line-height: 1;
    margin-bottom: 0.5rem;
}

.platform-stat-label {
    font-size: 0.95rem;
    color: #64748b;
    font-weight: 500;
}

/* ========================================
   CTA SECTION
   ======================================== */

.cta-section {
    background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
    padding: 6rem 2rem;
    text-align: center;
}

.cta-content {
    max-width: 800px;
    margin: 0 auto;
}

.cta-title {
    font-size: 3rem;
    font-weight: 800;
    color: #ffffff;
    margin-bottom: 1.25rem;
}

.cta-subtitle {
    font-size: 1.25rem;
    color: #cbd5e1;
    margin-bottom: 2.5rem;
    line-height: 1.6;
}

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

.cta-note {
    color: #94a3b8;
    font-size: 0.95rem;
}

/* ========================================
   FOOTER
   ======================================== */

.footer {
    background: #f8fafc;
    border-top: 1px solid #e5e7eb;
    padding: 4rem 0 2rem;
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr 1fr;
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-section h4,
.footer-section h5 {
    margin-bottom: 1.25rem;
    color: #1e293b;
}

.footer-logo {
    font-size: 1.25rem;
    font-weight: 700;
}

.footer-tagline {
    color: #64748b;
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.footer-social {
    display: flex;
    gap: 1.5rem;
}

.social-link {
    color: #64748b;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease;
}

.social-link:hover {
    color: #2563eb;
}

.footer-section a {
    display: block;
    color: #64748b;
    text-decoration: none;
    padding: 0.5rem 0;
    transition: color 0.2s ease;
}

.footer-section a:hover {
    color: #2563eb;
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid #e5e7eb;
    color: #94a3b8;
    font-size: 0.9rem;
}

.footer-bottom p {
    margin-bottom: 0.5rem;
}

/* ========================================
   RESPONSIVE DESIGN
   ======================================== */

@media (max-width: 1024px) {
    .hero-content {
        grid-template-columns: 1fr;
        gap: 3rem;
    }

    .hero-title {
        font-size: 2.75rem;
    }

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

    .feature-large {
        grid-template-columns: 1fr;
        gap: 3rem;
    }

    .trust-tiers {
        grid-template-columns: 1fr;
    }

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

    .step::after {
        display: none;
    }

    .testimonials {
        grid-template-columns: 1fr;
    }

    .platform-stats {
        grid-template-columns: repeat(2, 1fr);
        gap: 2rem;
    }

    .footer-content {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 768px) {
    .nav-links {
        display: none;
    }

    .nav-toggle {
        display: flex;
    }

    .hero {
        padding: 3rem 1.5rem;
    }

    .hero-title {
        font-size: 2rem;
    }

    .hero-subtitle {
        font-size: 1.1rem;
    }

    .hero-cta {
        flex-direction: column;
    }

    .hero-stats {
        gap: 1.5rem;
    }

    .stat-number {
        font-size: 1.75rem;
    }

    section {
        padding: 3rem 0;
    }

    .section-title {
        font-size: 2rem;
    }

    .section-subtitle {
        font-size: 1.1rem;
    }

    .problem-grid {
        grid-template-columns: 1fr;
    }

    .steps-container {
        grid-template-columns: 1fr;
    }

    .platform-stats {
        grid-template-columns: 1fr;
    }

    .cta-title {
        font-size: 2rem;
    }

    .cta-buttons {
        flex-direction: column;
    }

    .footer-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
}

/* ========================================
   ACCESSIBILITY
   ======================================== */

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
