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

:root {
    --primary-color: #4F46E5;
    --primary-dark: #4338CA;
    --primary-light: #6366F1;
    --success-color: #10B981;
    --error-color: #EF4444;
    --warning-color: #F59E0B;
    --gray-50: #F9FAFB;
    --gray-100: #F3F4F6;
    --gray-200: #E5E7EB;
    --gray-300: #D1D5DB;
    --gray-400: #9CA3AF;
    --gray-500: #6B7280;
    --gray-600: #4B5563;
    --gray-700: #374151;
    --gray-800: #1F2937;
    --gray-900: #111827;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: #FFFFFF;
    color: var(--gray-800);
    line-height: 1.6;
    min-height: 100vh;
    padding-top: 70px;
    font-size: 16px;
}

.container {
    width: 100%;
    margin: 0 auto;
    padding: 0 20px;
}

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: white;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    height: 70px;
    display: flex;
    align-items: center;
}

.navbar-container {
    width: 100%;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 40px;
}

.navbar-logo {
    font-size: 1.8rem;
    font-weight: 900;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -0.8px;
    font-family: 'Poppins', 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    white-space: nowrap;
    position: relative;
    display: flex;
    align-items: center;
    gap: 8px;
}

.navbar-center {
    flex: 1;
    display: flex;
    justify-content: center;
}

.navbar-tabs {
    display: flex;
    gap: 30px;
}

.navbar-tab-btn {
    padding: 8px 16px;
    border: none;
    background: transparent;
    color: var(--gray-600);
    font-weight: 500;
    font-size: 15px;
    cursor: pointer;
    transition: all 0.3s ease;
    border-bottom: 2px solid transparent;
    white-space: nowrap;
}

.navbar-tab-btn:hover {
    color: var(--primary-color);
}

.navbar-tab-btn.active {
    color: var(--primary-color);
    border-bottom-color: var(--primary-color);
}

.navbar-language {
    display: flex;
    align-items: center;
    white-space: nowrap;
}

.language-dropdown {
    padding: 6px 10px;
    border: none;
    border-radius: 8px;
    background: linear-gradient(135deg, var(--gray-50) 0%, white 100%);
    color: var(--gray-800);
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: auto;
    max-width: 140px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.08);
    appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%234F46E5' stroke-width='2'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 5px center;
    background-size: 18px;
    padding-right: 28px;
}

.language-dropdown:hover {
    background: linear-gradient(135deg, #E8EBF8 0%, #F0F3FF 100%);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.12);
}

.language-dropdown:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1), 0 2px 8px rgba(79, 70, 229, 0.2);
}

/* Header */
.header {
    display: none;
}

/* Main Content */
.main-content {
    padding: 40px 0;
}

/* Converter Section */
.converter-section {
    margin-bottom: 60px;
}

.converter-card {
    background: white;
    border-radius: 16px;
    padding: 40px;
    box-shadow: var(--shadow-xl);
    max-width: 700px;
    margin: 0 auto;
}

.converter-card h2 {
    font-size: 2.2rem;
    margin-bottom: 30px;
    text-align: center;
    color: var(--gray-900);
}

/* Upload Area */
.upload-area {
    border: 3px dashed var(--primary-color);
    border-radius: 12px;
    padding: 40px 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    background: var(--gray-50);
    margin-bottom: 20px;
}

.upload-area:hover {
    border-color: var(--primary-dark);
    background: linear-gradient(135deg, rgba(79, 70, 229, 0.05), rgba(99, 102, 241, 0.05));
}

.upload-area.dragover {
    border-color: var(--primary-dark);
    background: linear-gradient(135deg, rgba(79, 70, 229, 0.1), rgba(99, 102, 241, 0.1));
    transform: scale(1.02);
}

.upload-icon {
    color: var(--primary-color);
    margin-bottom: 15px;
    display: flex;
    justify-content: center;
}

.upload-area h3 {
    font-size: 1.4rem;
    margin-bottom: 10px;
    color: var(--gray-900);
}

.upload-area p {
    color: var(--gray-600);
    font-size: 1rem;
}

.upload-area .file-size {
    font-size: 0.85rem;
    color: var(--gray-500);
    margin-top: 5px;
}

/* File Info */
.file-info {
    background: var(--gray-50);
    border: 1px solid var(--gray-200);
    border-radius: 8px;
    padding: 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.file-details {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.file-name {
    font-weight: 600;
    color: var(--gray-900);
}

.file-size {
    font-size: 0.85rem;
    color: var(--gray-500);
}

.btn-remove {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--gray-400);
    cursor: pointer;
    padding: 5px 10px;
    transition: color 0.2s;
}

.btn-remove:hover {
    color: var(--error-color);
}

/* Conversion Options */
.conversion-options {
    margin-bottom: 20px;
}

.format-selector {
    margin-bottom: 20px;
}

.format-selector label {
    display: block;
    font-weight: 600;
    margin-bottom: 12px;
    color: var(--gray-900);
    font-size: 1.1rem;
}

.format-buttons {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 12px;
    justify-items: center;
}

.format-btn {
    width: 120px;
    padding: 12px;
    border: 2px solid var(--gray-200);
    border-radius: 8px;
    background: white;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    font-size: 0.9rem;
}

.format-btn:hover {
    border-color: var(--primary-color);
    background: var(--gray-50);
}

.format-btn.active {
    border-color: var(--primary-color);
    background: linear-gradient(135deg, rgba(79, 70, 229, 0.1), rgba(99, 102, 241, 0.1));
    color: var(--primary-color);
}

.format-icon {
    font-size: 1.8rem;
}

.format-name {
    font-weight: 600;
    font-size: 0.95rem;
}

/* Buttons */
.btn-convert {
    width: 100%;
    padding: 14px 24px;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.btn-convert:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-convert:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.btn-text {
    flex: 1;
}

.spinner {
    width: 20px;
    height: 20px;
    stroke: white;
    animation: spin 1s linear infinite;
}

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

/* Progress Bar */
.progress-container {
    margin-top: 20px;
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: var(--gray-200);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 10px;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), var(--primary-light));
    width: 0%;
    transition: width 0.3s ease;
    border-radius: 4px;
}

.progress-text {
    text-align: center;
    font-size: 0.9rem;
    color: var(--gray-600);
}

/* Success Message */
.success-message {
    text-align: center;
    padding: 30px;
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.1), rgba(16, 185, 129, 0.05));
    border: 1px solid rgba(16, 185, 129, 0.2);
    border-radius: 12px;
}

.success-icon {
    font-size: 3rem;
    color: var(--success-color);
    margin-bottom: 15px;
}

.success-message h3 {
    color: var(--success-color);
    margin-bottom: 10px;
}

.success-message p {
    color: var(--gray-600);
    margin-bottom: 20px;
}

.btn-download {
    width: 100%;
    padding: 12px 24px;
    background: var(--success-color);
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    margin-bottom: 10px;
    transition: all 0.3s ease;
}

.btn-download:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-convert-another {
    width: 100%;
    padding: 12px 24px;
    background: white;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-convert-another:hover {
    background: var(--gray-50);
}

/* Error Message */
.error-message {
    text-align: center;
    padding: 30px;
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.1), rgba(239, 68, 68, 0.05));
    border: 1px solid rgba(239, 68, 68, 0.2);
    border-radius: 12px;
}

.error-icon {
    font-size: 3rem;
    color: var(--error-color);
    margin-bottom: 15px;
}

.error-message h3 {
    color: var(--error-color);
    margin-bottom: 10px;
}

.error-message p {
    color: var(--gray-600);
    margin-bottom: 20px;
}

.btn-try-again {
    width: 100%;
    padding: 12px 24px;
    background: var(--error-color);
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-try-again:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

/* Features Section */
.features-section {
    margin: 80px 0;
    text-align: center;
}

.features-section h2 {
    font-size: 2.3rem;
    margin-bottom: 40px;
    color: var(--gray-900);
    font-weight: 800;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.feature-card {
    background: white;
    border-radius: 12px;
    padding: 30px;
    box-shadow: var(--shadow-lg);
    transition: all 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-xl);
}

.feature-icon {
    font-size: 2.5rem;
    margin-bottom: 15px;
}

.feature-card h3 {
    font-size: 1.3rem;
    margin-bottom: 10px;
    color: var(--gray-900);
}

.feature-card p {
    color: var(--gray-600);
    font-size: 1rem;
}

/* FAQ Section */
.faq-section {
    margin: 80px 0;
    background: white;
    border-radius: 16px;
    padding: 40px;
    box-shadow: var(--shadow-xl);
}

.faq-section h2 {
    font-size: 2.3rem;
    margin-bottom: 40px;
    text-align: center;
    color: var(--gray-900);
}

.faq-container {
    max-width: 700px;
    margin: 0 auto;
}

.faq-item {
    border-bottom: 1px solid var(--gray-200);
    margin-bottom: 0;
}

.faq-item:last-child {
    border-bottom: none;
}

.faq-question {
    width: 100%;
    padding: 20px 0;
    background: none;
    border: none;
    text-align: left;
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--gray-900);
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: color 0.3s ease;
}

.faq-question:hover {
    color: var(--primary-color);
}

.faq-toggle {
    font-size: 1.5rem;
    transition: transform 0.3s ease;
}

.faq-item.active .faq-toggle {
    transform: rotate(45deg);
}

.faq-answer {
    padding: 0 0 20px 0;
    color: var(--gray-600);
    line-height: 1.8;
    font-size: 1rem;
}

/* Advertisement Containers */
.ad-container {
    margin: 30px 0;
    display: flex;
    justify-content: center;
}

.ad-placeholder {
    background: white;
    border-radius: 8px;
    padding: 10px;
    box-shadow: var(--shadow-md);
    min-height: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.ad-top {
    margin-top: 20px;
    margin-bottom: 40px;
}

.ad-bottom {
    margin-top: 40px;
    margin-bottom: 20px;
}

.ad-middle {
    margin: 60px 0;
}

.ad-side {
    display: none;
}

/* Desktop layout for side ads */
@media (min-width: 1400px) {
    .main-content {
        display: grid;
        grid-template-columns: 300px 1fr 300px;
        gap: 30px;
        align-items: start;
    }

    .ad-side {
        display: block;
    }

    .ad-side.ad-left {
        grid-column: 1;
    }

    .ad-side.ad-right {
        grid-column: 3;
    }

    .converter-section,
    .features-section,
    .faq-section {
        grid-column: 2;
    }

    .ad-placeholder {
        min-height: 600px;
        position: sticky;
        top: 20px;
    }
}

/* Footer */
.footer {
    background: var(--gray-900);
    color: white;
    text-align: center;
    padding: 30px 0;
    margin-top: 60px;
    border-top: 1px solid rgba(255, 255, 255, 0.15);
}

.footer-links {
    margin-top: 15px;
    display: flex;
    justify-content: center;
    gap: 20px;
}

.footer-links a {
    color: white;
    text-decoration: none;
    transition: opacity 0.3s ease;
}

.footer-links a:hover {
    opacity: 0.8;
}

/* Responsive */
@media (max-width: 768px) {
    .navbar {
        height: 60px;
    }

    .navbar-container {
        padding: 0 15px;
    }

    .navbar-logo {
        font-size: 1.4rem;
    }

    .language-dropdown {
        font-size: 0.8rem;
        max-width: 120px;
        padding: 5px 8px;
        padding-right: 26px;
    }

    .logo {
        font-size: 2rem;
    }

    .tagline {
        font-size: 1rem;
    }

    .converter-card {
        padding: 25px;
    }

    .converter-card h2 {
        font-size: 1.8rem;
    }

    .upload-area {
        padding: 30px 15px;
    }

    .format-buttons {
        grid-template-columns: repeat(3, 1fr);
    }

    .format-btn {
        width: 100%;
    }

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

    .features-section h2 {
        font-size: 1.5rem;
    }

    .faq-section {
        padding: 25px;
    }

    .faq-section h2 {
        font-size: 1.5rem;
    }

    .footer-links {
        flex-direction: column;
        gap: 10px;
    }
}

@media (max-width: 480px) {
    .navbar {
        height: 55px;
    }

    .navbar-container {
        padding: 0 10px;
    }

    .navbar-logo {
        font-size: 1.2rem;
    }

    .language-dropdown {
        font-size: 0.75rem;
        max-width: 100px;
        padding: 4px 6px;
        padding-right: 24px;
    }

    .container {
        padding: 0 15px;
    }

    .header {
        padding: 25px 0;
        margin-bottom: 25px;
    }

    .logo {
        font-size: 1.5rem;
    }

    .tagline {
        font-size: 0.9rem;
    }

    .converter-card {
        padding: 20px;
    }

    .converter-card h2 {
        font-size: 1.3rem;
    }

    .upload-area {
        padding: 25px 15px;
    }

    .upload-area h3 {
        font-size: 1rem;
    }

    .upload-area p {
        font-size: 0.85rem;
    }

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

    .format-btn {
        width: 100%;
        padding: 10px;
        font-size: 0.8rem;
    }

    .format-icon {
        font-size: 1.5rem;
    }

    .format-name {
        font-size: 0.75rem;
    }

    .features-section h2 {
        font-size: 1.3rem;
    }

    .feature-card {
        padding: 20px;
    }

    .faq-section h2 {
        font-size: 1.3rem;
    }
}
/* ==================== TAB CONTENT ==================== */
.tab-content-section {
    animation: fadeIn 0.3s ease;
}

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

/* ==================== CONVERTER INPUTS ==================== */
.converter-input-group {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
    margin-bottom: 20px;
}

.input-field {
    display: flex;
    flex-direction: column;
}

.input-field label {
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--gray-700);
    font-size: 16px;
}

.input-field input,
.input-field select {
    padding: 12px;
    border: 1.5px solid var(--gray-200);
    border-radius: 8px;
    font-size: 16px;
    font-family: inherit;
    transition: all 0.3s ease;
}

.input-field input:focus,
.input-field select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
}

/* ==================== RESULT BOX ==================== */
.result-box {
    background: var(--gray-50);
    border-left: 4px solid var(--success-color);
    padding: 16px;
    border-radius: 8px;
    margin-top: 20px;
    animation: slideIn 0.3s ease;
}

.result-box p {
    color: var(--gray-700);
    font-size: 1.1rem;
    margin: 0;
}

.result-box strong {
    color: var(--gray-900);
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* ==================== BUTTON STYLES ==================== */
.btn-convert {
    padding: 12px 30px;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-md);
}

.btn-convert:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-convert:active {
    transform: translateY(0);
}

/* ==================== RESPONSIVE TABS ==================== */
@media (max-width: 768px) {
    .converter-input-group {
        grid-template-columns: 1fr;
    }
}