/* ==========================================================================
   CarePDF - Homepage Styles (Clean & Optimized)
   Inspired by iLovePDF - Simple, Fast, User-Friendly
   ========================================================================== */

/* ==========================================================================
   1. Hero Section - Clean & Focused
   ========================================================================== */

.hero-modern {
    position: relative;
    min-height: 520px;
    display: flex;
    align-items: center;
    padding: 100px 0 60px;
    overflow: hidden;
}

/* Simple Gradient Background */
.hero-bg {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, #1e1e2e 0%, #2d1f3d 50%, #1a1a2e 100%);
    z-index: 0;
}

.hero-gradient,
.hero-pattern,
.hero-glow {
    position: absolute;
    inset: 0;
}

.hero-gradient {
    background: radial-gradient(ellipse at 30% 20%, rgba(239, 68, 68, 0.15) 0%, transparent 50%),
                radial-gradient(ellipse at 70% 80%, rgba(139, 92, 246, 0.1) 0%, transparent 50%);
}

.hero-pattern {
    opacity: 0.02;
    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='1'%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");
}

.hero-glow-1 {
    background: radial-gradient(circle at 20% 30%, rgba(239, 68, 68, 0.08) 0%, transparent 40%);
}

.hero-glow-2 {
    background: radial-gradient(circle at 80% 70%, rgba(139, 92, 246, 0.06) 0%, transparent 40%);
}

/* Hero Layout */
.hero-wrapper {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 32px;
}

.hero-content {
    max-width: 800px;
}

/* Trust Badge */
.trust-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 100px;
    margin-bottom: 20px;
}

.trust-badge-icon {
    color: var(--primary-400);
    display: flex;
}

.trust-badge-text {
    font-size: 0.875rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.8);
}

/* Hero Title */
.hero-title {
    font-size: clamp(2.5rem, 5vw, 3.5rem);
    font-weight: 800;
    color: #ffffff;
    line-height: 1.15;
    margin-bottom: 16px;
    letter-spacing: -0.02em;
}

.hero-title .text-highlight {
    background: linear-gradient(135deg, var(--primary-400) 0%, #f97316 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Hero Subtitle */
.hero-subtitle {
    font-size: 1.125rem;
    color: rgba(255, 255, 255, 0.65);
    max-width: 600px;
    margin: 0 auto 28px;
    line-height: 1.6;
}

.hero-subtitle strong {
    color: rgba(255, 255, 255, 0.9);
}

/* ==========================================================================
   2. Search Box - Clean Pill Style
   ========================================================================== */

.hero-search-wrapper {
    max-width: 480px;
    margin: 0 auto 24px;
    width: 100%;
}

.hero-search-form-premium {
    display: flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 100px;
    padding: 6px;
    transition: all 0.2s ease;
}

.hero-search-form-premium:focus-within {
    background: rgba(255, 255, 255, 0.14);
    border-color: rgba(255, 255, 255, 0.25);
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.15);
}

.search-icon-wrapper {
    padding-left: 16px;
    color: rgba(255, 255, 255, 0.5);
    display: flex;
}

.search-input-premium {
    flex: 1;
    padding: 12px 16px;
    font-size: 1rem;
    color: #ffffff;
    background: transparent;
    border: none;
    outline: none;
}

.search-input-premium::placeholder {
    color: rgba(255, 255, 255, 0.45);
}

.search-submit-icon {
    width: 42px;
    height: 42px;
    background: var(--primary);
    border: none;
    border-radius: 50%;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.search-submit-icon:hover {
    background: var(--primary-600);
    transform: scale(1.05);
}

/* ==========================================================================
   3. Quick Tool Chips
   ========================================================================== */

.hero-quick-tools {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px;
}

.quick-label {
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.5);
    margin-right: 4px;
}

.quick-tools-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
}

.quick-tool-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 100px;
    font-size: 0.875rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.85);
    text-decoration: none;
    transition: all 0.2s ease;
}

.quick-tool-chip:hover {
    background: rgba(255, 255, 255, 0.14);
    border-color: rgba(255, 255, 255, 0.2);
    color: #ffffff;
    transform: translateY(-1px);
}

.quick-tool-chip svg {
    opacity: 0.7;
}

/* ==========================================================================
   4. Hero Stats Card
   ========================================================================== */

.hero-stats-card {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 20px 32px;
    margin-top: 8px;
}

.hero-stats-grid {
    display: flex;
    align-items: center;
    gap: 24px;
}

.stat-item {
    text-align: center;
    padding: 0 16px;
}

.stat-value {
    font-size: 1.75rem;
    font-weight: 700;
    color: #ffffff;
    line-height: 1.2;
}

.stat-label {
    font-size: 0.8125rem;
    color: rgba(255, 255, 255, 0.55);
    margin-top: 2px;
}

.stat-divider {
    width: 1px;
    height: 36px;
    background: rgba(255, 255, 255, 0.12);
}

/* ==========================================================================
   5. Scroll Indicator
   ========================================================================== */

.scroll-indicator {
    position: absolute;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%);
    color: rgba(255, 255, 255, 0.35);
    animation: bounce 2s infinite;
}

@keyframes bounce {
    0%, 100% { transform: translateX(-50%) translateY(0); }
    50% { transform: translateX(-50%) translateY(8px); }
}

/* ==========================================================================
   6. Wave Divider
   ========================================================================== */

.wave-divider {
    margin-top: -1px;
    line-height: 0;
}

.wave-divider svg {
    width: 100%;
    height: 60px;
}

/* ==========================================================================
   7. Tools Section - Clean Grid
   ========================================================================== */

.tools-section {
    padding: 60px 0 80px;
    background: #ffffff;
}

.section-header-modern {
    text-align: center;
    margin-bottom: 48px;
}

.section-badge {
    display: inline-block;
    padding: 6px 14px;
    background: var(--primary-50);
    color: var(--primary);
    font-size: 0.8125rem;
    font-weight: 600;
    border-radius: 100px;
    margin-bottom: 12px;
}

.section-header-modern h2 {
    font-size: 2rem;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 8px;
}

.section-header-modern p {
    font-size: 1.0625rem;
    color: var(--gray-500);
}

/* Category Sections */
.category-section {
    margin-bottom: 48px;
}

.category-heading-modern {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--gray-800);
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.category-icon-modern {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: 10px;
    background: var(--gray-100);
    color: var(--gray-600);
}

.category-icon-modern.organize { color: var(--primary); background: var(--primary-50); }
.category-icon-modern.optimize { color: #f59e0b; background: #fef3c7; }
.category-icon-modern.convert { color: #3b82f6; background: #dbeafe; }
.category-icon-modern.security { color: #10b981; background: #d1fae5; }
.category-icon-modern.edit { color: #8b5cf6; background: #ede9fe; }

/* ==========================================================================
   8. Tool Cards - iLovePDF Style
   ========================================================================== */

.tools-grid-premium {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 16px;
}

.tool-card-premium {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 20px;
    background: #ffffff;
    border: 1px solid var(--gray-200);
    border-radius: 12px;
    text-decoration: none;
    transition: all 0.2s ease;
}

.tool-card-premium:hover {
    border-color: var(--primary-200);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
    transform: translateY(-2px);
}

.tool-icon-circle {
    flex-shrink: 0;
    width: 44px;
    height: 44px;
    background: var(--gray-50);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    transition: all 0.2s ease;
}

.tool-card-premium:hover .tool-icon-circle {
    background: var(--primary);
    color: white;
}

.tool-card-content {
    flex: 1;
    min-width: 0;
}

.tool-title-premium {
    display: block;
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--gray-900);
    margin-bottom: 4px;
}

.tool-desc-premium {
    display: block;
    font-size: 0.8125rem;
    color: var(--gray-500);
    line-height: 1.4;
}

/* View All Button */
.text-center.mt-2xl {
    margin-top: 40px;
}

/* ==========================================================================
   9. Features Section - Simple Grid
   ========================================================================== */

.features-showcase {
    padding: 80px 0;
    background: var(--gray-50);
}

.features-row {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}

.feature-showcase-card {
    background: #ffffff;
    border-radius: 16px;
    padding: 28px;
    text-align: center;
    border: 1px solid var(--gray-100);
    transition: all 0.2s ease;
}

.feature-showcase-card:hover {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.06);
    transform: translateY(-2px);
}

.feature-showcase-icon {
    width: 56px;
    height: 56px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
}

.feature-showcase-icon.red {
    background: var(--primary-50);
    color: var(--primary);
}

.feature-showcase-icon.green {
    background: #d1fae5;
    color: #10b981;
}

.feature-showcase-icon.purple {
    background: #ede9fe;
    color: #8b5cf6;
}

.feature-showcase-icon.blue {
    background: #dbeafe;
    color: #3b82f6;
}

.feature-showcase-card h3 {
    font-size: 1.0625rem;
    font-weight: 600;
    color: var(--gray-900);
    margin-bottom: 8px;
}

.feature-showcase-card p {
    font-size: 0.875rem;
    color: var(--gray-500);
    line-height: 1.5;
}

/* ==========================================================================
   10. CTA Section
   ========================================================================== */

.cta-section-modern {
    padding: 80px 0;
    background: linear-gradient(135deg, var(--gray-900) 0%, #1e1e2e 100%);
}

.cta-content {
    text-align: center;
    max-width: 600px;
    margin: 0 auto;
}

.cta-content h2 {
    font-size: 2rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 12px;
}

.cta-content p {
    font-size: 1.0625rem;
    color: rgba(255, 255, 255, 0.65);
    margin-bottom: 28px;
}

.btn-white {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 28px;
    background: #ffffff;
    color: var(--gray-900);
    font-size: 1rem;
    font-weight: 600;
    border-radius: 10px;
    text-decoration: none;
    transition: all 0.2s ease;
}

.btn-white:hover {
    background: var(--gray-100);
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
}

/* ==========================================================================
   11. Animations - Minimal & Performant
   ========================================================================== */

.animate-fade-in {
    animation: fadeIn 0.4s ease-out;
}

.animate-fade-in-up {
    animation: fadeInUp 0.5s ease-out;
}

.delay-1 { animation-delay: 0.1s; animation-fill-mode: both; }
.delay-2 { animation-delay: 0.2s; animation-fill-mode: both; }
.delay-3 { animation-delay: 0.3s; animation-fill-mode: both; }

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

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

/* ==========================================================================
   12. Responsive Design
   ========================================================================== */

@media (max-width: 1024px) {
    .features-row {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .hero-modern {
        min-height: auto;
        padding: 90px 0 50px;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .hero-stats-grid {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .stat-divider {
        display: none;
    }
    
    .stat-item {
        padding: 8px 20px;
    }
    
    .tools-grid-premium {
        grid-template-columns: 1fr;
    }
    
    .features-row {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    
    .wave-divider svg {
        height: 40px;
    }
    
    .tools-section {
        padding: 40px 0 60px;
    }
    
    .features-showcase {
        padding: 60px 0;
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 1.75rem;
    }
    
    .trust-badge {
        padding: 6px 12px;
    }
    
    .trust-badge-text {
        font-size: 0.75rem;
    }
    
    .quick-tool-chip {
        padding: 6px 12px;
        font-size: 0.8125rem;
    }
    
    .hero-stats-card {
        padding: 16px 20px;
    }
    
    .stat-value {
        font-size: 1.5rem;
    }
    
    .section-header-modern h2 {
        font-size: 1.625rem;
    }
    
    .cta-content h2 {
        font-size: 1.625rem;
    }
}

/* ==========================================================================
   13. Dark Mode Support
   ========================================================================== */

[data-theme="dark"] .tools-section {
    background: var(--gray-900);
}

[data-theme="dark"] .section-badge {
    background: rgba(239, 68, 68, 0.15);
}

[data-theme="dark"] .section-header-modern h2 {
    color: #ffffff;
}

[data-theme="dark"] .section-header-modern p {
    color: var(--gray-400);
}

[data-theme="dark"] .category-heading-modern {
    color: #ffffff;
}

[data-theme="dark"] .tool-card-premium {
    background: var(--gray-800);
    border-color: var(--gray-700);
}

[data-theme="dark"] .tool-card-premium:hover {
    border-color: var(--primary-600);
}

[data-theme="dark"] .tool-icon-circle {
    background: var(--gray-700);
}

[data-theme="dark"] .tool-title-premium {
    color: #ffffff;
}

[data-theme="dark"] .tool-desc-premium {
    color: var(--gray-400);
}

[data-theme="dark"] .features-showcase {
    background: var(--gray-800);
}

[data-theme="dark"] .feature-showcase-card {
    background: var(--gray-900);
    border-color: var(--gray-700);
}

[data-theme="dark"] .feature-showcase-card h3 {
    color: #ffffff;
}

[data-theme="dark"] .feature-showcase-card p {
    color: var(--gray-400);
}

[data-theme="dark"] .wave-divider svg path {
    fill: var(--gray-900);
}
