:root {
    --primary-color: #2c3e50;
    --secondary-color: #3498db;
    --accent-color: #1abc9c;
    --light-color: #ecf0f1;
    --dark-color: #34495e;
    --error-color: #e74c3c;
    --success-color: #2ecc71;
    --warning-color: #f39c12;
    --border-radius: 4px;
    --box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background-color: #f5f7fa;
    color: var(--dark-color);
    line-height: 1.6;
    padding: 20px;
}

.container {
    max-width: 800px;
    margin: 0 auto;
    background-color: white;
    border-radius: 8px;
    box-shadow: var(--box-shadow);
    overflow: hidden;
}

.form-header {
    background-color: var(--primary-color);
    color: white;
    padding: 20px 30px;
    text-align: center;
    position: relative;
}

.form-header h1 {
    font-size: 24px;
    margin-bottom: 10px;
}

.form-header p {
    opacity: 0.9;
    font-size: 16px;
}

.test-mode-toggle {
    margin-top: 10px;
}

.test-mode-banner {
    margin-top: 10px;
    padding: 5px 10px;
    background-color: var(--warning-color);
    color: white;
    border-radius: var(--border-radius);
}

.btn-small {
    display: inline-block;
    padding: 5px 10px;
    background-color: rgba(255, 255, 255, 0.2);
    color: white;
    border-radius: var(--border-radius);
    text-decoration: none;
    font-size: 12px;
    margin-top: 5px;
    transition: background-color 0.3s ease;
}

.btn-small:hover {
    background-color: rgba(255, 255, 255, 0.3);
}

.progress-container {
    padding: 15px 30px;
    background-color: #e3e8f0;
}

.progress-bar {
    display: flex;
    justify-content: space-between;
    position: relative;
    margin-bottom: 30px;
    max-width: 100%;
}

.progress-bar::before {
    content: '';
    background-color: #ddd;
    position: absolute;
    top: 14px;
    left: 0;
    height: 4px;
    width: 100%;
    z-index: 1;
}

.progress-step {
    position: relative;
    z-index: 2;
    text-align: center;
    width: 30px;
    height: 30px;
    background-color: white;
    border: 3px solid #ddd;
    border-radius: 50%;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.progress-step.active {
    border-color: var(--secondary-color);
    background-color: var(--secondary-color);
    color: white;
}

.progress-step.completed {
    border-color: var(--success-color);
    background-color: var(--success-color);
    color: white;
}

.progress-step-label {
    position: absolute;
    top: 35px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 12px;
    color: var(--dark-color);
    white-space: nowrap;
}

.form-body {
    padding: 30px;
}

.form-section {
    display: none;
}

.form-section.active {
    display: block;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 6px;
    font-weight: 600;
    font-size: 14px;
}

.form-group label .optional {
    color: #95a5a6;
    font-weight: normal;
    font-size: 12px;
}

.form-control {
    width: 100%;
    padding: 10px 15px;
    border: 1px solid #ddd;
    border-radius: var(--border-radius);
    font-size: 14px;
    transition: border-color 0.3s ease;
}

.form-control:focus {
    outline: none;
    border-color: var(--secondary-color);
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.2);
}

.form-row {
    display: flex;
    flex-wrap: wrap;
    margin: 0 -10px;
}

.form-col {
    flex: 1;
    padding: 0 10px;
    min-width: 200px;
}

.checkbox-group {
    margin-top: 15px;
}

.checkbox-container {
    display: flex;
    align-items: flex-start;
    margin-bottom: 10px;
}

.checkbox-container input[type="checkbox"] {
    margin-top: 5px;
    margin-right: 10px;
}

.checkbox-container label {
    font-weight: normal;
    font-size: 14px;
}

.character-count {
    font-size: 12px;
    color: #7f8c8d;
    text-align: right;
    margin-top: 5px;
}

.file-input-container {
    position: relative;
    margin-top: 10px;
}

.file-input-label {
    display: inline-block;
    padding: 10px 15px;
    background-color: var(--secondary-color);
    color: white;
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.file-input-label:hover {
    background-color: #2980b9;
}

.file-input {
    position: absolute;
    left: 0;
    top: 0;
    opacity: 0;
    width: 100%;
    height: 100%;
    cursor: pointer;
}

.file-name {
    margin-top: 5px;
    font-size: 14px;
}

.section-title {
    font-size: 18px;
    color: var(--primary-color);
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #eee;
}

.form-footer {
    display: flex;
    justify-content: space-between;
    padding: 20px 30px;
    background-color: #f9fafb;
    border-top: 1px solid #eee;
}

.btn {
    padding: 10px 20px;
    border: none;
    border-radius: var(--border-radius);
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-secondary {
    background-color: #e0e0e0;
    color: var(--dark-color);
}

.btn-secondary:hover {
    background-color: #d0d0d0;
}

.btn-primary {
    background-color: var(--secondary-color);
    color: white;
}

.btn-primary:hover {
    background-color: #2980b9;
}

.btn-submit {
    background-color: var(--success-color);
    color: white;
}

.btn-submit:hover {
    background-color: #27ae60;
}

.error-message {
    color: var(--error-color);
    font-size: 12px;
    margin-top: 5px;
    display: none;
}

.has-error .form-control {
    border-color: var(--error-color);
}

.has-error .error-message {
    display: block;
}

.required:after {
    content: ' *';
    color: var(--error-color);
}

/* Form-wide error message styling */
.form-error-container {
    margin: 20px 0;
    padding: 15px;
    background-color: #fef2f2;
    border: 1px solid var(--error-color);
    border-radius: var(--border-radius);
}

.form-error-message {
    color: var(--error-color);
}

.form-error-message ul {
    margin-top: 10px;
    padding-left: 20px;
}

/* Success page styling */
.success-container {
    background-color: white;
    border-radius: 8px;
    overflow: hidden;
}

.success-header {
    background-color: var(--success-color);
    color: white;
    padding: 20px 30px;
    text-align: center;
}

.success-header h1 {
    font-size: 24px;
}

.success-body {
    padding: 30px;
    text-align: center;
}

.success-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 20px;
    background-color: var(--success-color);
    color: white;
    border-radius: 50%;
    font-size: 40px;
    line-height: 80px;
}

.reference-code {
    margin: 30px 0;
    padding: 20px;
    background-color: #f9fafb;
    border-radius: var(--border-radius);
    border: 1px dashed #ccc;
}

.reference-code h2 {
    font-size: 28px;
    color: var(--primary-color);
    margin: 10px 0;
}

.reference-code .small {
    font-size: 12px;
    color: #777;
}

.success-body ul {
    text-align: left;
    max-width: 400px;
    margin: 20px auto;
}

.success-footer {
    margin-top: 30px;
}

@media screen and (max-width: 768px) {
    .form-col {
        flex: 100%;
        margin-bottom: 15px;
    }

    .form-header h1 {
        font-size: 20px;
    }

    .progress-step-label {
        font-size: 10px;
    }

    .form-body {
        padding: 20px;
    }

    .form-footer {
        padding: 15px 20px;
        flex-direction: column;
        gap: 10px;
    }

    .btn {
        width: 100%;
        text-align: center;
    }
}