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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: #1a1a1a;
    background-color: #ffffff;
}

/* Page Switching */
.page {
    display: none;
}

.page.active {
    display: block;
}

.page.hidden {
    display: none;
}

/* Typography */
h1 {
    font-size: 3rem;
    font-weight: 700;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    color: #1a1a1a;
}

h2 {
    font-size: 2.5rem;
    font-weight: 600;
    line-height: 1.2;
    margin-bottom: 1rem;
    color: #1a1a1a;
}

h3 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
    color: #1a1a1a;
}

p {
    font-size: 1.125rem;
    color: #4a4a4a;
    margin-bottom: 1.5rem;
    max-width: 65ch;
}

/* Layout */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

section {
    padding: 6rem 0;
}

.section-sm {
    padding: 4rem 0;
}

/* Navigation */
nav {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    z-index: 1000;
    padding: 1rem 0;
    box-shadow: 0 1px 0 rgba(0, 0, 0, 0.1);
}

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

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: #2563eb;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    padding: 0.875rem 2rem;
    font-size: 1.125rem;
    font-weight: 600;
    text-decoration: none;
    border-radius: 0.5rem;
    transition: all 0.2s ease;
    cursor: pointer;
    border: none;
}

.btn-primary {
    background: #2563eb;
    color: white;
}

.btn-primary:hover {
    background: #1d4ed8;
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(37, 99, 235, 0.3);
}

.btn-secondary {
    background: #f3f4f6;
    color: #374151;
}

.btn-secondary:hover {
    background: #e5e7eb;
}

.btn-large {
    padding: 1.125rem 2.5rem;
    font-size: 1.25rem;
}

/* Hero Section */
.hero {
    padding-top: 10rem;
    padding-bottom: 6rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.2);
    z-index: 1;
}

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

.hero h1 {
    color: white;
    margin-bottom: 1.5rem;
}

.hero p {
    font-size: 1.375rem;
    color: rgba(255, 255, 255, 0.9);
    max-width: 600px;
    margin: 0 auto 2.5rem;
}

.hero-cta {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* Features Grid */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 3rem;
    margin-top: 4rem;
}

.feature-card {
    text-align: center;
    padding: 2rem;
    background: #f9fafb;
    border-radius: 1rem;
    transition: all 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.feature-icon {
    font-size: 3rem;
    margin-bottom: 1.5rem;
    display: block;
}

/* Process Steps */
.process {
    background: #f9fafb;
}

.steps-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    counter-reset: step-counter;
}

.step-card {
    position: relative;
    padding: 2rem;
    background: white;
    border-radius: 1rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

.step-card::before {
    counter-increment: step-counter;
    content: counter(step-counter);
    position: absolute;
    top: -1rem;
    left: 2rem;
    width: 2rem;
    height: 2rem;
    background: #2563eb;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
}

.step-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

/* Requirements */
.requirements-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.requirement-item {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    padding: 1.5rem;
    background: white;
    border-radius: 0.75rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.requirement-icon {
    font-size: 1.5rem;
    flex-shrink: 0;
    margin-top: 0.25rem;
}

/* Pricing */
.pricing-card {
    background: white;
    border-radius: 1rem;
    padding: 3rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    text-align: center;
    max-width: 500px;
    margin: 0 auto;
}

.price {
    font-size: 4rem;
    font-weight: 700;
    color: #2563eb;
    margin: 1rem 0;
}

.price-currency {
    font-size: 2rem;
    vertical-align: top;
}

/* FAQ */
.faq-list {
    max-width: 800px;
    margin: 0 auto;
}

.faq-item {
    background: white;
    border-radius: 0.75rem;
    padding: 2rem;
    margin-bottom: 1rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

.faq-item:hover {
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.faq-question {
    font-weight: 600;
    margin-bottom: 0.75rem;
    color: #1a1a1a;
}

.faq-answer {
    color: #4a4a4a;
}

/* Footer */
footer {
    background: #111827;
    color: #9ca3af;
    padding: 4rem 0 2rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-section h3 {
    color: white;
    margin-bottom: 1rem;
}

.footer-links {
    list-style: none;
}

.footer-links a {
    color: #9ca3af;
    text-decoration: none;
    transition: color 0.2s;
}

.footer-links a:hover {
    color: white;
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid #374151;
}

/* Upload Zone Styles */
.upload-zone {
    border: 2px dashed #d1d5db;
    border-radius: 12px;
    padding: 3rem;
    text-align: center;
    background: #f9fafb;
    transition: all 0.3s ease;
    cursor: pointer;
}

.upload-zone:hover {
    border-color: #2563eb;
    background: rgba(37, 99, 235, 0.05);
}

.upload-zone.dragover {
    border-color: #2563eb;
    background: rgba(37, 99, 235, 0.1);
    transform: scale(1.02);
}

.upload-content {
    pointer-events: none;
}

.upload-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
    display: block;
}

.upload-zone p {
    color: #374151;
    margin-bottom: 0.5rem;
}

.upload-hint {
    color: #6b7280 !important;
    font-size: 1rem !important;
}

.upload-format {
    color: #9ca3af !important;
    font-size: 0.875rem !important;
    margin-top: 1rem !important;
}

/* AI Status Section Styles */
.ai-status-section {
    margin: 2rem auto;
}

.ai-status-card {
    background: white;
    border-radius: 1rem;
    padding: 2rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

.ai-status-steps {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.status-step {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    border-radius: 0.75rem;
    background: #f9fafb;
    transition: all 0.3s ease;
}

.status-step.active {
    background: #eff6ff;
    border: 2px solid #2563eb;
}

.status-step.completed {
    background: #f0fdf4;
    border: 2px solid #10b981;
}

.step-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #2563eb;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.125rem;
    flex-shrink: 0;
}

.status-step.completed .step-icon {
    background: #10b981;
}

.step-content {
    flex: 1;
}

.step-title {
    font-weight: 600;
    color: #1a1a1a;
    font-size: 1rem;
    margin-bottom: 0.25rem;
}

.step-desc {
    font-size: 0.875rem;
    color: #6b7280;
}

.step-indicator {
    font-size: 1.5rem;
    font-weight: 700;
    flex-shrink: 0;
}

.step-indicator.completed {
    color: #10b981;
}

.step-indicator.pending {
    color: #d1d5db;
}

.step-indicator.processing {
    color: #2563eb;
    animation: pulse 1.5s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

/* Result Preview Section */
.result-preview-section {
    margin: 2rem auto;
}

/* Action Section */
.action-section {
    margin: 2rem auto;
}

/* Upload Section Wrapper */
.upload-section-wrapper {
    margin: 3rem auto;
}

/* Preview Before/After Section Styles */
.preview-difference {
    padding: 6rem 0;
    background: #f9fafb;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 600;
    text-align: center;
    margin-bottom: 1rem;
    color: #1a1a1a;
}

.section-subtitle {
    font-size: 1.125rem;
    text-align: center;
    color: #4a4a4a;
    margin-bottom: 4rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.before-after-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    max-width: 1000px;
    margin: 0 auto;
    position: relative;
}

.comparison-card {
    background: white;
    border-radius: 1rem;
    padding: 2.5rem;
    text-align: center;
    position: relative;
    transition: transform 0.3s ease;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

.comparison-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.comparison-card.incorrect {
    border: 2px solid #ef4444;
    background: #fef2f2;
}

.comparison-card.correct {
    border: 2px solid #10b981;
    background: #f0fdf4;
}

.card-header {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.status-icon {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    font-weight: 700;
}

.status-icon.incorrect {
    background: #ef4444;
    color: white;
}

.status-icon.correct {
    background: #10b981;
    color: white;
}

.card-title {
    font-size: 1.5rem;
    font-weight: 600;
    margin: 0;
}

.card-title.incorrect {
    color: #ef4444;
}

.card-title.correct {
    color: #10b981;
}

.illustration-container {
    background: white;
    border-radius: 0.5rem;
    padding: 2rem;
    margin: 1.5rem 0;
    min-height: 300px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.illustration-before,
.illustration-after {
    width: 100%;
    height: 250px;
}

.problems-list,
.highlights-list {
    text-align: left;
    margin-top: 1.5rem;
}

.problem-item,
.highlight-item {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
    font-size: 14px;
    color: #4a4a4a;
}

.problem-icon,
.highlight-icon {
    font-size: 16px;
    margin-top: 2px;
    flex-shrink: 0;
}

.problem-icon {
    color: #ef4444;
}

.highlight-icon {
    color: #10b981;
}

.vs-badge {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60px;
    height: 60px;
    background: #2563eb;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    font-weight: 700;
    z-index: 10;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

/* Responsive adjustments for Before/After section */
@media (max-width: 768px) {
    .preview-difference {
        padding: 4rem 0;
    }

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

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

    .before-after-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .vs-badge {
        position: static;
        transform: none;
        margin: 1rem auto;
        display: none;
    }

    .comparison-card {
        padding: 2rem;
    }

    .illustration-container {
        padding: 1.5rem;
        min-height: 250px;
    }

    .illustration-before,
    .illustration-after {
        height: 200px;
    }
}

/* Utility */
.text-center {
    text-align: center;
}

.mb-2 { margin-bottom: 0.5rem; }
.mb-4 { margin-bottom: 1rem; }
.mb-6 { margin-bottom: 1.5rem; }

/* Responsive */
@media (max-width: 768px) {
    h1 { font-size: 2.5rem; }
    h2 { font-size: 2rem; }
    h3 { font-size: 1.25rem; }

    .hero {
        padding-top: 8rem;
        padding-bottom: 4rem;
    }

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

    .hero p {
        font-size: 1.125rem;
    }

    .hero-cta {
        flex-direction: column;
        align-items: center;
    }

    .btn {
        width: 100%;
        max-width: 300px;
    }

    .price {
        font-size: 3rem;
    }
}

/* ============================================
   AI Processing Status Section Styles
   ============================================ */

/* Upload section card */
.upload-section-card,
.status-section-card,
.result-section-card,
.action-section-card {
    margin: 2rem auto;
    max-width: 700px;
    padding: 2rem;
    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    border: 1px solid #e5e7eb;
}

/* Upload subtitle */
.upload-subtitle {
    color: #6b7280;
    font-size: 1rem;
    margin-top: 0.5rem;
}

/* AI Status Section */
.ai-status-section {
    margin: 2rem auto;
    max-width: 600px;
}

.ai-status-card {
    background: #ffffff;
    border-radius: 12px;
    padding: 2rem;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
}

/* Processing Steps */
.processing-steps {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.processing-step {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    padding: 1rem;
    border-radius: 8px;
    transition: background-color 0.2s;
}

.processing-step.completed {
    background-color: #f0fdf4;
}

.processing-step.active {
    background-color: #eff6ff;
}

.step-icon {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 14px;
    flex-shrink: 0;
}

.processing-step.completed .step-icon {
    background-color: #10b981;
    color: white;
}

.processing-step.active .step-icon {
    background-color: #3b82f6;
    color: white;
}

.step-icon.processing {
    background-color: #3b82f6;
    color: white;
}

.step-content {
    flex: 1;
}

.step-title {
    font-weight: 600;
    color: #1f2937;
    font-size: 15px;
    margin-bottom: 0.25rem;
}

.step-desc {
    color: #6b7280;
    font-size: 13px;
    line-height: 1.4;
}

/* Processing spinner */
.spinner {
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

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

/* Detection note */
.detection-note {
    color: #9ca3af;
    font-size: 12px;
    line-height: 1.5;
    max-width: 400px;
    margin: 2rem auto 0;
}

/* Result Section */
.result-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 0.5rem;
}

.result-desc {
    color: #6b7280;
    font-size: 0.95rem;
    margin-bottom: 1rem;
}

.result-image-wrapper {
    background: white;
    padding: 1rem;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.result-secondary-info {
    margin-top: 0.75rem;
    font-size: 13px;
    color: #9ca3af;
}

.original-toggle {
    cursor: pointer;
    color: #6b7280;
    font-size: 14px;
    padding: 0.5rem;
    border-radius: 4px;
    transition: color 0.2s;
}

.original-toggle:hover {
    color: #3b82f6;
}

.original-toggle::-webkit-details-marker {
    display: none;
}

/* Action Section */
.action-section-card {
    text-align: center;
    padding: 1.5rem 2rem;
}

.action-buttons {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}