/* Modern Blue & White Design */

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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: #ffffff;
    min-height: 100vh;
    color: #333;
    display: flex;
    flex-direction: column;
}

/* Smooth animated gradient with two colors */
@keyframes smoothGradient {
    0% {
        background-position: 0% 0%, 100% 100%;
    }

    25% {
        background-position: 100% 0%, 0% 100%;
    }

    50% {
        background-position: 100% 100%, 0% 0%;
    }

    75% {
        background-position: 0% 100%, 100% 0%;
    }

    100% {
        background-position: 0% 0%, 100% 100%;
    }
}

header {
    background:
        linear-gradient(135deg, #1a6aff 0%, #00008b 100%),
        linear-gradient(-135deg, #00008b 0%, #1a6aff 100%);
    background-size: 200% 200%, 200% 200%;
    animation: smoothGradient 8s ease-in-out infinite;
    color: white;
    padding: 40px 20px;
    text-align: center;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: relative;
    /* For absolute positioning of home button */
}

.home-btn {
    position: absolute;
    left: 20px;
    top: 30px;
    /* Aligned with top padding */
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: all 0.2s ease;
    padding: 8px 12px;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.1);
}

.home-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    transform: translateX(-2px);
}

header h1 {
    font-size: 2.5rem;
    margin-bottom: 10px;
    font-weight: 600;
}

header p {
    font-size: 1rem;
    opacity: 0.95;
}

footer {
    background: #f5f5f5;
    color: #666;
    padding: 30px 20px;
    text-align: center;
    margin-top: auto;
    border-top: 1px solid #e0e0e0;
}

footer p {
    font-size: 0.9rem;
    margin: 5px 0;
}

footer a {
    color: #1a6aff;
    text-decoration: none;
    transition: color 0.3s ease;
}

footer a:hover {
    color: #00008b;
    text-decoration: underline;
}

.container {
    width: 100%;
    max-width: 500px;
    margin: 40px auto;
    flex: 1;
    padding: 0 20px;
}

h2 {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    color: #00008b;
    text-align: center;
    margin-bottom: 15px;
    font-size: 1.1rem;
    font-weight: 600;
}

h2:first-of-type {
    margin-top: 0;
}

/* Form Card - Simple white box */
.form-card {
    background: #f9f9f9;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 30px;
    margin-bottom: 50px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
    width: 100%;
    box-sizing: border-box;
}

.form-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

#vidyardForm {
    margin-top: 0;
}

#youtubeForm {
    margin-bottom: 80px;
}

/* Form Styling */
form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

label {
    color: #333;
    font-size: 0.95rem;
    font-weight: 500;
    display: block;
    margin-bottom: 5px;
}

input[type="text"],
textarea {
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 6px;
    background: #ffffff;
    color: #333;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    width: 100%;
    box-sizing: border-box;
}

input[type="text"]::placeholder,
textarea::placeholder {
    color: #999;
}

input[type="text"]:focus,
textarea:focus {
    outline: none;
    border-color: #1a6aff;
    box-shadow: 0 0 0 3px rgba(26, 106, 255, 0.1);
}

input[type="submit"] {
    background: linear-gradient(135deg, #1a6aff 0%, #00008b 100%);
    color: white;
    font-weight: 600;
    cursor: pointer;
    border: none;
    margin-top: 10px;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: 0.85rem;
    padding: 12px 18px;
    border-radius: 6px;
    width: 100%;
    box-sizing: border-box;
    box-shadow: 0 4px 15px rgba(26, 106, 255, 0.3);
}

input[type="submit"]:hover {
    box-shadow: 0 6px 20px rgba(26, 106, 255, 0.4);
    transform: translateY(-2px);
}

input[type="submit"]:active {
    transform: translateY(0);
}

input[type="submit"]:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Loading Overlay */
#loadingOverlay {
    background: #f0f0f0;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 20px;
    margin-top: 15px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    animation: slideIn 0.3s ease;
}

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

#loadingOverlay p {
    color: #333;
    margin: 10px 0;
    font-size: 0.95rem;
}

#loadingOverlay strong {
    color: #1a6aff;
    font-weight: 600;
}

#statusText {
    color: #666;
    font-weight: 500;
}

/* Progress Bar */
.progress-bar-container {
    width: 100%;
    height: 24px;
    background: #e0e0e0;
    border-radius: 12px;
    overflow: hidden;
    margin: 15px 0;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1);
}

.progress-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, #1a6aff 0%, #00008b 100%);
    width: 0%;
    transition: width 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    color: white;
    font-weight: 600;
}

#progressPercent {
    display: block;
    text-align: center;
    color: #1a6aff;
    font-weight: 600;
    margin-top: 10px;
}

/* Error Styling */
#loadingOverlay.error {
    background: #ffe6e6;
    border-color: #ffb3b3;
}

/* Responsive Design */
@media (max-width: 600px) {
    header h1 {
        font-size: 1.8rem;
    }

    h2 {
        font-size: 1.2rem;
    }

    .form-card {
        padding: 20px;
        border-radius: 6px;
    }

    input[type="text"],
    input[type="submit"] {
        padding: 10px 12px;
        font-size: 0.9rem;
    }
}

/* Text content styling */
span {
    color: inherit;
}

/* Success message styling */
.success-message {
    color: #00a86b;
    font-weight: 600;
    margin-top: 10px;
}