/* Modern Styles for AVIF to JPG Converter */
body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
    margin: 0;
    padding: 0;
    color: #333;
    background-color: #f5f7fa;
    line-height: 1.6;
}

header {
    background-color: #0066FF; /* Primary blue for AVIF converter */
    color: white;
    padding: 3rem 0;
    text-align: center;
}

.header-content {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 1rem;
}

header h1 {
    font-size: 2.5rem;
    margin: 0 0 1rem 0;
    font-weight: 800;
}

header p {
    font-size: 1.2rem;
    margin: 0 0 1.5rem 0;
    opacity: 0.9;
}

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

.feature {
    display: flex;
    align-items: center;
    background-color: rgba(255, 255, 255, 0.15);
    padding: 0.5rem 1rem;
    border-radius: 2rem;
    font-size: 0.9rem;
    font-weight: 500;
}

.icon {
    margin-right: 0.5rem;
}

main {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 1rem;
}

/* Drop Zone Styling */
.drop-zone {
    background-color: white;
    border-radius: 1rem;
    padding: 2rem;
    text-align: center;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
    position: relative;
}

.drop-zone.dragover {
    border: 2px dashed #0066FF;
    background-color: rgba(0, 102, 255, 0.03);
}

.credit-counter {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background-color: #f0f5ff;
    padding: 0.5rem 1rem;
    border-radius: 1rem;
    font-size: 0.9rem;
    color: #0066FF;
    font-weight: 500;
}

.drop-zone-content {
    padding: 3rem 0;
}

.upload-icon-container {
    margin-bottom: 1.5rem;
}

.upload-icon {
    width: 70px;
    height: 70px;
    opacity: 0.8;
}

.drop-zone h2 {
    font-size: 1.8rem;
    margin: 0 0 1rem 0;
    color: #333;
}

.drop-subtitle {
    color: #666;
    margin-bottom: 1.5rem;
}

.button {
    background-color: #0066FF;
    color: white;
    border: none;
    padding: 0.8rem 1.5rem;
    border-radius: 0.5rem;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
}

.button:hover {
    background-color: #0052cc;
}

.file-types {
    margin-top: 1rem;
    color: #666;
    font-size: 0.9rem;
}

/* Progress & Upload Styling */
.upload-progress {
    background-color: white;
    border-radius: 1rem;
    padding: 2rem;
    margin-top: 2rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
}

.progress-status {
    margin-bottom: 1.5rem;
}

.progress-bar {
    height: 8px;
    background-color: #eee;
    border-radius: 4px;
    overflow: hidden;
    margin: 1rem 0;
}

.progress-fill {
    height: 100%;
    background-color: #0066FF;
    width: 0%;
    transition: width 0.3s;
}

.uploaded-files, .result-files, .files-container {
    margin-top: 1rem;
}

.file-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem;
    background-color: #f8f9fa;
    border-radius: 0.5rem;
    margin-bottom: 0.8rem;
}

.file-name {
    font-weight: 500;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    flex: 1;
}

.file-status {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.status-badge {
    padding: 0.3rem 0.6rem;
    border-radius: 1rem;
    font-size: 0.8rem;
    font-weight: 500;
}

.status-badge.uploading {
    background-color: #f0f5ff;
    color: #0066FF;
}

.status-badge.success {
    background-color: #e6f7ef;
    color: #00a86b;
}

.status-badge.failed {
    background-color: #fff0f0;
    color: #ff3b30;
}

.download-button {
    background-color: #0066FF;
    color: white;
    text-decoration: none;
    padding: 0.4rem 0.8rem;
    border-radius: 0.4rem;
    font-size: 0.8rem;
    font-weight: 500;
    transition: all 0.2s;
}

.download-button:hover {
    background-color: #0052cc;
}

/* Conversion Results */
.conversion-results {
    background-color: white;
    border-radius: 1rem;
    padding: 2rem;
    margin-top: 2rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
    text-align: center;
}

.conversion-results h3 {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    color: #333;
}

.result-files {
    margin-bottom: 1.5rem;
}

.result-file {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem;
    background-color: #f8f9fa;
    border-radius: 0.5rem;
    margin-bottom: 0.8rem;
    text-align: left;
}

.file-info {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex: 1;
}

.error-message {
    color: #ff3b30;
    font-size: 0.9rem;
    margin-top: 0.5rem;
}

.download-all {
    margin-top: 1rem;
}

/* Pricing Section */
.credit-purchase {
    margin-top: 3rem;
    text-align: center;
}

.credit-purchase h2 {
    font-size: 2rem;
    margin-bottom: 2rem;
    color: #333;
}

.pricing-tiers {
    display: flex;
    justify-content: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.tier {
    background-color: white;
    border-radius: 1rem;
    padding: 2rem;
    width: 280px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
    position: relative;
    transition: transform 0.3s, box-shadow 0.3s;
}

.tier:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.tier.popular {
    border: 2px solid #0066FF;
}

.popular-badge {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background-color: #0066FF;
    color: white;
    padding: 0.3rem 1rem;
    border-radius: 1rem;
    font-size: 0.8rem;
    font-weight: 500;
}

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

.tier-header h3 {
    font-size: 1.6rem;
    margin: 0 0 0.5rem 0;
    color: #333;
}

.price {
    font-size: 2rem;
    font-weight: 700;
    color: #0066FF;
    margin: 0;
}

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

.tier-features p {
    margin: 0.5rem 0;
    position: relative;
    padding-left: 1.5rem;
}

.tier-features p:before {
    content: '✓';
    position: absolute;
    left: 0;
    color: #0066FF;
}

.credits {
    font-weight: 700;
    color: #333;
}

/* Info Section */
.info-section {
    margin-top: 3rem;
    display: flex;
    gap: 2rem;
    flex-wrap: wrap;
    justify-content: center;
}

.info-card {
    background-color: white;
    border-radius: 1rem;
    padding: 2rem;
    flex: 1;
    min-width: 300px;
    max-width: 500px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
}

.info-card h3 {
    font-size: 1.5rem;
    margin-top: 0;
    color: #333;
}

.info-card ul {
    padding-left: 1.5rem;
}

.info-card li {
    margin-bottom: 0.8rem;
}

/* Footer */
footer {
    background-color: #f0f5ff;
    padding: 3rem 0;
    margin-top: 5rem;
    text-align: center;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 1.5rem;
}

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

.footer-links a:hover {
    color: #0052cc;
}

.copyright {
    color: #666;
    font-size: 0.9rem;
}

/* Helper Classes */
.hidden {
    display: none;
}

/* Responsive Styles */
@media (max-width: 768px) {
    header {
        padding: 2rem 0;
    }
    
    header h1 {
        font-size: 2rem;
    }
    
    .features {
        flex-direction: column;
        align-items: center;
        gap: 0.8rem;
    }
    
    .pricing-tiers {
        flex-direction: column;
        align-items: center;
    }
    
    .tier {
        width: 100%;
        max-width: 350px;
        margin-bottom: 2rem;
    }
    
    .info-section {
        flex-direction: column;
    }
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    header nav {
        text-align: center;
        margin-top: 10px;
    }
    
    header h1 {
        text-align: center;
    }
    
    .card-title {
        font-size: 1.5rem;
    }
    
    #dropzone h3 {
        font-size: 1.2rem;
    }
}

/* Animation for Upload Icon */
@keyframes pulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
    100% {
        transform: scale(1);
    }
}

#dropzone-content img {
    animation: pulse 2s infinite;
}

/* Badge Styling */
.badge {
    font-weight: normal;
    padding: 5px 10px;
}

/* Button Hover Effects */
.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 123, 255, 0.2);
    transition: all 0.3s ease;
}

.btn-success:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(40, 167, 69, 0.2);
    transition: all 0.3s ease;
}

/* Footer Styling */
footer {
    border-top: 1px solid #eee;
}

/* Card Hover Effect */
.card:hover {
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}

/* Tier Cards Styling */
#purchase-options .card {
    transition: all 0.3s ease;
    border: 1px solid #dee2e6;
}

#purchase-options .card:hover {
    border-color: #007bff;
    transform: translateY(-5px);
}

/* Highlight the Pro tier as best value */
#purchase-options .card:nth-child(2) {
    border-color: #007bff;
    position: relative;
}

#purchase-options .card:nth-child(2)::before {
    content: "Best Value";
    position: absolute;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    background-color: #007bff;
    color: white;
    padding: 2px 10px;
    border-radius: 10px;
    font-size: 0.8rem;
    font-weight: bold;
}
