* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    color: #333;
}


.navbar {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    padding: 0.75rem 0;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.05);
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid rgba(255, 255, 255, 0.3);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo {
    font-size: 1.8rem;
    font-weight: 700;
    color: #4f46e5;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.nav-branding {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-left: auto;
    font-size: 0.9rem;
    color: #666;
}

.logo-link {
    display: flex;
    align-items: center;
    text-decoration: none;
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.logo-link:hover {
    transform: scale(1.05);
}

.powered-by {
    font-size: 0.8rem;
    font-weight: 500;
    color: #475569;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.nav-slogan {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
}

.nav-slogan span {
    font-size: 0.95rem;
    font-weight: 600;
    font-style: italic;
    background: linear-gradient(135deg, #4f46e5, #7c3aed);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    border: 1px solid rgba(79, 70, 229, 0.2);
    padding: 0.4rem 1.2rem;
    border-radius: 50px;
    background-color: rgba(79, 70, 229, 0.05);
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.nav-user {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    background: rgba(241, 245, 249, 0.8);
    padding: 0.4rem 0.6rem;
    padding-right: 1.2rem;
    border-radius: 50px;
    border: 1px solid #e2e8f0;
}

.user-avatar,
.user-avatar-placeholder {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid white;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.user-avatar-placeholder {
    background: #4f46e5;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
}

.username {
    font-size: 0.9rem;
    font-weight: 600;
    color: #1f2937;
}

.logout-btn {
    color: #ef4444;
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.4rem 0.8rem;
    border-radius: 8px;
    transition: all 0.2s;
}

.logout-btn:hover {
    background: #fee2e2;
}

.auth-links {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.login-link-nav {
    color: #475569;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    transition: color 0.2s;
}

.login-link-nav:hover {
    color: #4f46e5;
}

.signup-btn-nav {
    background: #4f46e5;
    color: white;
    padding: 0.6rem 1.4rem;
    border-radius: 12px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    transition: all 0.23s cubic-bezier(0.4, 0, 0.2, 1);
}

.signup-btn-nav:hover {
    background: #4338ca;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.25);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

.hero-section {
    text-align: center;
    color: white;
    margin-bottom: 3rem;
}

.hero-content h1 {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.hero-content p {
    font-size: 1.2rem;
    opacity: 0.9;
    max-width: 600px;
    margin: 0 auto;
}

.upload-card {
    background: white;
    border-radius: 20px;
    padding: 3rem;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    margin-bottom: 3rem;
}

.card-header {
    text-align: center;
    margin-bottom: 2rem;
}

.card-header i {
    font-size: 3rem;
    color: #4f46e5;
    margin-bottom: 1rem;
}

.card-header h2 {
    font-size: 2rem;
    color: #333;
}

.file-input-container {
    margin-bottom: 2rem;
}

#fileInput {
    display: none;
}

.file-input-label {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border: 3px dashed #4f46e5;
    border-radius: 15px;
    padding: 3rem 2rem;
    cursor: pointer;
    transition: all 0.3s ease;
    background: #f8faff;
}

.file-input-label:hover {
    background: #f0f4ff;
    transform: translateY(-2px);
}

.file-input-label i {
    font-size: 4rem;
    color: #4f46e5;
    margin-bottom: 1rem;
}

.file-text {
    font-size: 1.5rem;
    font-weight: 600;
    color: #333;
    margin-bottom: 0.5rem;
}

.file-size {
    color: #666;
    font-size: 1rem;
}

.conversion-options h3 {
    text-align: center;
    margin-bottom: 2rem;
    font-size: 1.5rem;
    color: #333;
}

.option-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.option-card input {
    display: none;
}

.option-card input:checked+.card-content {
    border-color: #4f46e5;
    background: #f0f4ff;
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(79, 70, 229, 0.2);
}

.card-content {
    border: 2px solid #e5e7eb;
    border-radius: 15px;
    padding: 2rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    height: 100%;
}

.card-content:hover {
    border-color: #4f46e5;
    transform: translateY(-2px);
}

.card-content i {
    font-size: 2.5rem;
    color: #4f46e5;
    margin-bottom: 1rem;
}

.card-content h4 {
    font-size: 1.3rem;
    margin-bottom: 1rem;
    color: #333;
}

.card-content p {
    color: #666;
    margin-bottom: 1.5rem;
}

.card-features {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.card-features span {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    color: #555;
    font-size: 0.9rem;
}

.convert-btn {
    width: 100%;
    background: linear-gradient(135deg, #4f46e5, #7c3aed);
    color: white;
    border: none;
    padding: 1.2rem 2rem;
    font-size: 1.2rem;
    font-weight: 600;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.convert-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(79, 70, 229, 0.3);
}

.convert-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.features-section {
    margin-top: 4rem;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.feature {
    text-align: center;
    color: white;
}

.feature i {
    font-size: 3rem;
    margin-bottom: 1rem;
    opacity: 0.9;
}

.feature h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.feature p {
    opacity: 0.8;
}

.result-section {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 60vh;
}

.success-card {
    background: white;
    border-radius: 20px;
    padding: 3rem;
    text-align: center;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    max-width: 500px;
    width: 100%;
}

.success-icon {
    font-size: 4rem;
    color: #10b981;
    margin-bottom: 1rem;
}

.success-card h1 {
    font-size: 2rem;
    margin-bottom: 1rem;
    color: #333;
}

.file-info {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin: 2rem 0;
    padding: 1rem;
    background: #f0f4ff;
    border-radius: 10px;
    color: #4f46e5;
}

.action-buttons {
    display: flex;
    gap: 1rem;
    margin: 2rem 0;
    flex-direction: column;
}

.download-btn,
.convert-again-btn {
    padding: 1rem 2rem;
    border-radius: 10px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.download-btn {
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
}

.download-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(16, 185, 129, 0.3);
}

.convert-again-btn {
    background: #f3f4f6;
    color: #333;
}

.convert-again-btn:hover {
    background: #e5e7eb;
    transform: translateY(-2px);
}

.tips {
    text-align: left;
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid #e5e7eb;
}

.tips h3 {
    margin-bottom: 1rem;
    color: #333;
}

.tips ul {
    list-style: none;
    padding-left: 0;
}

.tips li {
    padding: 0.5rem 0;
    color: #666;
}

.alert {
    padding: 1rem;
    border-radius: 10px;
    margin-bottom: 2rem;
    font-weight: 500;
}

.alert-error {
    background: #fee2e2;
    color: #dc2626;
    border: 1px solid #fecaca;
}

.alert-success {
    background: #d1fae5;
    color: #065f46;
    border: 1px solid #a7f3d0;
}

.footer {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    color: white;
    text-align: center;
    padding: 2rem 0;
    margin-top: 4rem;
}

.loading {
    display: none;
    text-align: center;
    margin: 2rem 0;
}

.loading-spinner {
    border: 4px solid #f3f3f3;
    border-top: 4px solid #4f46e5;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 0 auto 1rem;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

@media (max-width: 768px) {
    .hero-content h1 {
        font-size: 2.5rem;
    }

    .upload-card {
        padding: 2rem 1rem;
    }

    .option-cards {
        grid-template-columns: 1fr;
    }

    .action-buttons {
        flex-direction: column;
    }
}

.login-section {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 70vh;
}

.login-card {
    background: white;
    border-radius: 20px;
    padding: 3rem;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    max-width: 400px;
    width: 100%;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #333;
}

.form-group input {
    width: 100%;
    padding: 1rem;
    border: 2px solid #e5e7eb;
    border-radius: 10px;
    font-size: 1rem;
    transition: border-color 0.3s ease;
}

.form-group input:focus {
    outline: none;
    border-color: #4f46e5;
}

.login-btn {
    width: 100%;
    background: linear-gradient(135deg, #4f46e5, #7c3aed);
    color: white;
    border: none;
    padding: 1.2rem 2rem;
    font-size: 1.2rem;
    font-weight: 600;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.login-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(79, 70, 229, 0.3);
}

.demo-credentials {
    margin-top: 2rem;
    padding: 1.5rem;
    background: #f8faff;
    border-radius: 10px;
    border-left: 4px solid #4f46e5;
}

.demo-credentials h3 {
    margin-bottom: 1rem;
    color: #333;
}

.demo-credentials p {
    margin-bottom: 0.5rem;
    color: #666;
}

.nav-user {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.username {
    color: #4f46e5;
    font-weight: 500;
}

.logout-btn {
    background: #ef4444;
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    text-decoration: none;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.logout-btn:hover {
    background: #dc2626;
    transform: translateY(-1px);
}

/* Global Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    color: #333;
}

/* Navbar Styles */
.navbar {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    padding: 1rem 0;
    box-shadow: 0 2px 20px 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;
}

.nav-logo {
    font-size: 1.8rem;
    font-weight: 700;
    color: #4f46e5;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.nav-branding {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-left: auto;
    font-size: 0.9rem;
    color: #666;
}

.nav-logo-image {
    height: 50px;
    width: auto;
}

.logo-link {
    display: flex;
    align-items: center;
    text-decoration: none;
}

.logo-link:hover {
    opacity: 0.8;
}

/* Main Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

/* Hero Section */
.hero-section {
    text-align: center;
    color: white;
    margin-bottom: 3rem;
}

.hero-content h1 {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.hero-content p {
    font-size: 1.2rem;
    opacity: 0.9;
    max-width: 600px;
    margin: 0 auto;
}

/* Upload Card */
.upload-card {
    background: white;
    border-radius: 20px;
    padding: 3rem;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    margin-bottom: 3rem;
}

.card-header {
    text-align: center;
    margin-bottom: 2rem;
}

.card-header i {
    font-size: 3rem;
    color: #4f46e5;
    margin-bottom: 1rem;
}

.card-header h2 {
    font-size: 2rem;
    color: #333;
}

.file-input-container {
    margin-bottom: 2rem;
}

#fileInput {
    display: none;
}

.file-input-label {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border: 3px dashed #4f46e5;
    border-radius: 15px;
    padding: 3rem 2rem;
    cursor: pointer;
    transition: all 0.3s ease;
    background: #f8faff;
}

.file-input-label:hover {
    background: #f0f4ff;
    transform: translateY(-2px);
}

.file-input-label i {
    font-size: 4rem;
    color: #4f46e5;
    margin-bottom: 1rem;
}

.file-text {
    font-size: 1.5rem;
    font-weight: 600;
    color: #333;
    margin-bottom: 0.5rem;
}

.file-size {
    color: #666;
    font-size: 1rem;
}

/* Conversion Options */
.conversion-options h3 {
    text-align: center;
    margin-bottom: 2rem;
    font-size: 1.5rem;
    color: #333;
}

.option-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.option-card input {
    display: none;
}

.option-card input:checked+.card-content {
    border-color: #4f46e5;
    background: #f0f4ff;
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(79, 70, 229, 0.2);
}

.card-content {
    border: 2px solid #e5e7eb;
    border-radius: 15px;
    padding: 2rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    height: 100%;
}

.card-content:hover {
    border-color: #4f46e5;
    transform: translateY(-2px);
}

.card-content i {
    font-size: 2.5rem;
    color: #4f46e5;
    margin-bottom: 1rem;
}

.card-content h4 {
    font-size: 1.3rem;
    margin-bottom: 1rem;
    color: #333;
}

.card-content p {
    color: #666;
    margin-bottom: 1.5rem;
}

.card-features {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.card-features span {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    color: #555;
    font-size: 0.9rem;
}

/* Convert Button */
.convert-btn {
    width: 100%;
    background: linear-gradient(135deg, #4f46e5, #7c3aed);
    color: white;
    border: none;
    padding: 1.2rem 2rem;
    font-size: 1.2rem;
    font-weight: 600;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.convert-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(79, 70, 229, 0.3);
}

.convert-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

/* Features Section */
.features-section {
    margin-top: 4rem;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.feature {
    text-align: center;
    color: white;
}

.feature i {
    font-size: 3rem;
    margin-bottom: 1rem;
    opacity: 0.9;
}

.feature h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.feature p {
    opacity: 0.8;
}

/* Result Section */
.result-section {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 60vh;
}

.success-card {
    background: white;
    border-radius: 20px;
    padding: 3rem;
    text-align: center;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    max-width: 500px;
    width: 100%;
}

.success-icon {
    font-size: 4rem;
    color: #10b981;
    margin-bottom: 1rem;
}

.success-card h1 {
    font-size: 2rem;
    margin-bottom: 1rem;
    color: #333;
}

.file-info {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin: 2rem 0;
    padding: 1rem;
    background: #f0f4ff;
    border-radius: 10px;
    color: #4f46e5;
}

.action-buttons {
    display: flex;
    gap: 1rem;
    margin: 2rem 0;
    flex-direction: column;
}

.download-btn,
.convert-again-btn {
    padding: 1rem 2rem;
    border-radius: 10px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.download-btn {
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
}

.download-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(16, 185, 129, 0.3);
}

.convert-again-btn {
    background: #f3f4f6;
    color: #333;
}

.convert-again-btn:hover {
    background: #e5e7eb;
    transform: translateY(-2px);
}

/* Tips Section */
.tips {
    text-align: left;
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid #e5e7eb;
}

.tips h3 {
    margin-bottom: 1rem;
    color: #333;
}

.tips ul {
    list-style: none;
    padding-left: 0;
}

.tips li {
    padding: 0.5rem 0;
    color: #666;
}

/* Alert Messages */
.alert {
    padding: 1rem;
    border-radius: 10px;
    margin-bottom: 2rem;
    font-weight: 500;
}

.alert-error {
    background: #fee2e2;
    color: #dc2626;
    border: 1px solid #fecaca;
}

.alert-success {
    background: #d1fae5;
    color: #065f46;
    border: 1px solid #a7f3d0;
}

/* Footer */
.footer {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    color: white;
    text-align: center;
    padding: 2rem 0;
    margin-top: 4rem;
}

/* Loading State */
.loading {
    display: none;
    text-align: center;
    margin: 2rem 0;
}

.loading-spinner {
    border: 4px solid #f3f3f3;
    border-top: 4px solid #4f46e5;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 0 auto 1rem;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

/* Media Queries */
@media (max-width: 768px) {
    .hero-content h1 {
        font-size: 2.5rem;
    }

    .upload-card {
        padding: 2rem 1rem;
    }

    .option-cards {
        grid-template-columns: 1fr;
    }

    .action-buttons {
        flex-direction: column;
    }

    .nav-container {
        flex-direction: column;
        gap: 1rem;
    }

    .nav-user {
        flex-direction: column;
        gap: 0.5rem;
    }
}

/* Processing Message */
.processing-message {
    margin-top: 15px;
    text-align: center;
    font-size: 1rem;
    color: #ffffff;
    background: linear-gradient(90deg, #6a5af9, #836fff);
    padding: 12px;
    border-radius: 8px;
    width: 60%;
    margin-left: auto;
    margin-right: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.15);
}

.processing-message i {
    font-size: 1.2rem;
}

/* Error Message */
.error-message {
    background: #fee2e2;
    color: #dc2626;
    padding: 1.5rem;
    border-radius: 10px;
    margin: 1rem 0;
    border-left: 4px solid #dc2626;
}

.error-details {
    margin-bottom: 1rem;
}

.error-details strong {
    display: block;
    margin-bottom: 0.5rem;
}

.error-solutions {
    background: #fef2f2;
    padding: 1rem;
    border-radius: 5px;
    border: 1px solid #fecaca;
}

.error-solutions ul {
    margin: 0.5rem 0 0 1.5rem;
}

.error-solutions li {
    margin: 0.25rem 0;
}

/* Deleted Count */
.deleted-count {
    color: #6b7280;
    font-size: 0.8rem;
    margin-left: 0.5rem;
    font-style: italic;
}

/* Custom Converter Specific Styles */

/* Custom Option Card */
.custom-option .card-content {
    border: 2px solid #8b5cf6;
}

.custom-option .card-content i {
    color: #8b5cf6;
}

.custom-option input:checked+.card-content {
    border-color: #8b5cf6;
    background: linear-gradient(135deg, #f5f3ff, #ede9fe);
    box-shadow: 0 15px 30px rgba(139, 92, 246, 0.2);
}

/* Custom Prompt Section */
.custom-prompt-section {
    background: linear-gradient(135deg, #fafafb, #f5f5f5);
    border-radius: 15px;
    padding: 2.5rem;
    border: 2px solid #e5e7eb;
    margin-top: 2rem;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.section-header {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 2rem;
    text-align: center;
}

.section-header i {
    font-size: 2rem;
    color: #8b5cf6;
    background: linear-gradient(135deg, #8b5cf6, #7c3aed);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.section-header h3 {
    margin: 0;
    color: #333;
    font-size: 1.4rem;
    font-weight: 700;
}

.prompt-container {
    position: relative;
    margin-bottom: 2.5rem;
}

#customPrompt {
    width: 100%;
    padding: 1.5rem;
    border: 2px solid #d1d5db;
    border-radius: 12px;
    font-family: 'Poppins', sans-serif;
    font-size: 1rem;
    line-height: 1.6;
    resize: vertical;
    transition: all 0.3s ease;
    background: white;
    color: #333;
    min-height: 150px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

#customPrompt:focus {
    outline: none;
    border-color: #8b5cf6;
    box-shadow: 0 0 0 4px rgba(139, 92, 246, 0.15);
    transform: translateY(-1px);
}

#customPrompt::placeholder {
    color: #9ca3af;
    font-style: italic;
}

.char-counter {
    text-align: right;
    margin-top: 0.5rem;
    color: #6b7280;
    font-size: 0.85rem;
    font-weight: 500;
}

/* Examples Section */
.examples-section {
    background: white;
    border-radius: 12px;
    padding: 2rem;
    border: 1px solid #e5e7eb;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.04);
}

.examples-section h4 {
    color: #4b5563;
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
    font-weight: 600;
    text-align: center;
}

.example-buttons {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1rem;
}

.example-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 1.5rem 1rem;
    background: linear-gradient(135deg, #f8fafc, #f1f5f9);
    border: 2px solid #e5e7eb;
    border-radius: 10px;
    color: #4b5563;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
    min-height: 100px;
}

.example-btn:hover {
    background: linear-gradient(135deg, #f0f4ff, #e0e7ff);
    border-color: #8b5cf6;
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(139, 92, 246, 0.15);
}

.example-btn i {
    font-size: 1.8rem;
    margin-bottom: 0.75rem;
    color: #8b5cf6;
}

.example-btn span {
    font-weight: 500;
    line-height: 1.4;
}

/* Processing Message for Custom Converter */
#processingMessage {
    margin-top: 2rem;
    text-align: center;
    font-size: 1rem;
    color: #ffffff;
    background: linear-gradient(135deg, #4f46e5, #7c3aed);
    padding: 1.5rem 2rem;
    border-radius: 12px;
    width: 100%;
    margin-left: auto;
    margin-right: auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 15px;
    box-shadow: 0 5px 20px rgba(79, 70, 229, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

#processingMessage .spinner {
    font-size: 2rem;
    animation: pulse 1.5s infinite;
}

#processingMessage .message-content {
    text-align: center;
}

#processingMessage .message-content h4 {
    margin: 0 0 0.5rem 0;
    color: white;
    font-size: 1.3rem;
    font-weight: 600;
}

#processingMessage .message-content p {
    margin: 0;
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.95rem;
    max-width: 400px;
    line-height: 1.5;
}

/* Error Message Styling */
.error-message {
    background: linear-gradient(135deg, #fee2e2, #fecaca);
    color: #dc2626;
    padding: 1.5rem 2rem;
    border-radius: 12px;
    margin: 1.5rem 0;
    border-left: 4px solid #dc2626;
    display: flex;
    align-items: center;
    gap: 1rem;
    box-shadow: 0 3px 10px rgba(220, 38, 38, 0.1);
}

.error-message i {
    font-size: 1.5rem;
    flex-shrink: 0;
}

.error-details {
    flex: 1;
}

.error-details strong {
    display: block;
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
}

.error-solutions {
    background: rgba(255, 255, 255, 0.7);
    padding: 1rem;
    border-radius: 8px;
    margin-top: 1rem;
    border: 1px solid rgba(220, 38, 38, 0.2);
}

.error-solutions p {
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: #7f1d1d;
}

.error-solutions ul {
    margin: 0.5rem 0 0 1.5rem;
    color: #7f1d1d;
}

.error-solutions li {
    margin: 0.25rem 0;
    font-size: 0.9rem;
}

/* Convert Button Custom State */
.custom-mode .convert-btn {
    background: linear-gradient(135deg, #8b5cf6, #7c3aed);
}

.custom-mode .convert-btn:hover:not(:disabled) {
    box-shadow: 0 10px 25px rgba(139, 92, 246, 0.4);
}

/* Custom Mode Form Indicator */
.upload-card.custom-mode {
    border: 2px solid rgba(139, 92, 246, 0.3);
}

/* Animations */
@keyframes pulse {
    0% {
        opacity: 0.6;
        transform: scale(0.95);
    }

    50% {
        opacity: 1;
        transform: scale(1);
    }

    100% {
        opacity: 0.6;
        transform: scale(0.95);
    }
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.custom-prompt-section {
    animation: slideIn 0.3s ease-out;
}

/* Responsive Design for Custom Converter */
@media (max-width: 768px) {
    .custom-prompt-section {
        padding: 1.5rem;
        margin-top: 1.5rem;
    }

    .section-header {
        flex-direction: column;
        gap: 0.75rem;
    }

    .section-header i {
        font-size: 1.8rem;
    }

    .section-header h3 {
        font-size: 1.2rem;
    }

    .example-buttons {
        grid-template-columns: 1fr;
    }

    .example-btn {
        padding: 1.25rem 1rem;
        min-height: 90px;
    }

    .example-btn i {
        font-size: 1.5rem;
    }

    #customPrompt {
        padding: 1.25rem;
        min-height: 120px;
    }

    #processingMessage {
        padding: 1.25rem 1.5rem;
    }

    #processingMessage .spinner {
        font-size: 1.8rem;
    }

    #processingMessage .message-content h4 {
        font-size: 1.1rem;
    }

    #processingMessage .message-content p {
        font-size: 0.9rem;
    }
}

@media (max-width: 480px) {
    .option-cards {
        grid-template-columns: 1fr;
    }

    .custom-prompt-section {
        padding: 1.25rem;
    }

    .examples-section {
        padding: 1.5rem 1rem;
    }

    .error-message {
        flex-direction: column;
        text-align: center;
        padding: 1.25rem;
    }

    .error-message i {
        margin-bottom: 0.5rem;
    }
}

/* Success Card Additional Styles for Custom Mode */
.success-card .custom-prompt-info {
    background: linear-gradient(135deg, #f5f3ff, #ede9fe);
    padding: 1.5rem;
    border-radius: 10px;
    margin: 1.5rem 0;
    border-left: 4px solid #8b5cf6;
    text-align: left;
}

.success-card .custom-prompt-info h4 {
    color: #5b21b6;
    margin-bottom: 0.75rem;
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.success-card .custom-prompt-info p {
    color: #6d28d9;
    margin: 0;
    font-size: 0.95rem;
    line-height: 1.5;
    white-space: pre-wrap;
    word-break: break-word;
}

/* File Input Styling Enhancement */
.file-input-container .file-selected {
    background: linear-gradient(135deg, #dcfce7, #bbf7d0);
    border-color: #22c55e;
}

.file-input-container .file-selected i {
    color: #22c55e;
}

.file-input-container .file-selected .file-text {
    color: #166534;
}

.file-input-container .file-selected .file-size {
    color: #15803d;
}