/* Chula's Job Application Form Styles */

@font-face {
    font-family: 'Atrament';
    src: url('../fonts/atrament-bold.otf') format('opentype');
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', sans-serif;
    background-color: #ffffff;
    color: #333;
    line-height: 1.6;
}

.form-container {
    max-width: 900px;
    margin: 0 auto;
    padding: 32px 48px;
    background: white;
    min-height: 100vh;
}

/* Back Button */
.back-button {
    display: inline-block;
    padding: 12px 28px;
    border: 2px solid #c8d96f;
    border-radius: 50px;
    color: #1f2937;
    text-decoration: none;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 2px;
    background-color: transparent;
    transition: all 0.2s;
    text-transform: uppercase;
}

.back-button:hover {
    background-color: #c8d96f;
    color: #1f2937;
}

/* Hero Header */
.hero-header {
    position: relative;
    margin-top: 32px;
    margin-bottom: 0;
}

.hero-title {
    font-family: 'Atrament', Georgia, serif;
    font-weight: 700;
    font-style: normal;
    font-size: clamp(42px, 6vw, 68px);
    color: #6b5b95;
    line-height: 1.1;
    max-width: calc(100% - 180px);
}

.coming-soon-badge {
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    width: clamp(100px, 15vw, 160px);
    height: auto;
}

.hero-subtitle {
    font-size: 18px;
    color: #374151;
    margin-top: -4px;
    margin-bottom: 48px;
    line-height: 1.6;
    max-width: 700px;
}

/* Hide original form header logo */
.form-header {
    display: none;
}

/* Form Sections */
.form-section {
    margin-bottom: 32px;
}

.form-section h2 {
    display: none;
}

/* Form Groups */
.form-group {
    margin-bottom: 24px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr;
    gap: 24px;
}

/* Labels */
label {
    display: block;
    font-size: 15px;
    font-weight: 400;
    color: #1f2937;
    margin-bottom: 8px;
}

.required {
    color: #1f2937;
}

.field-hint {
    font-size: 12px;
    color: #9ca3af;
    margin-top: 6px;
}

/* Inputs */
input[type="text"],
input[type="email"],
input[type="tel"],
input[type="date"],
select,
textarea {
    width: 100%;
    padding: 14px 16px;
    border: 1px solid #d1d5db;
    border-radius: 0;
    font-size: 15px;
    font-family: inherit;
    transition: border-color 0.2s, box-shadow 0.2s;
    background-color: white;
}

input:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: #6b5b95;
    box-shadow: 0 0 0 2px rgba(107, 91, 149, 0.1);
}

input::placeholder,
textarea::placeholder {
    color: #9ca3af;
}

textarea {
    resize: vertical;
    min-height: 100px;
}

/* Phone Input with Country Selector */
.phone-input-wrapper {
    display: flex;
    align-items: stretch;
    border: 1px solid #d1d5db;
    border-radius: 0;
}

.country-selector {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 14px 12px;
    border: none;
    border-right: 1px solid #d1d5db;
    border-radius: 0;
    background: white;
    cursor: pointer;
    flex-shrink: 0;
    width: 65px;
    font-size: 18px;
}

.country-selector:focus {
    outline: none;
    background-color: #f9fafb;
}

.flag-icon {
    font-size: 18px;
}

.phone-input-wrapper input[type="tel"] {
    border: none;
    border-radius: 0;
    flex: 1;
    min-width: 0;
    width: 100%;
}

.phone-input-wrapper input[type="tel"]:focus {
    box-shadow: none;
    outline: none;
}

/* Position Checkboxes - Grid Layout */
.position-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px 32px;
}

@media (max-width: 600px) {
    .position-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 400px) {
    .position-grid {
        grid-template-columns: 1fr;
    }
}

.position-checkbox {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
}

.position-checkbox input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: #6b5b95;
    cursor: pointer;
    border: 1px solid #d1d5db;
}

.position-checkbox span {
    font-size: 15px;
    color: #374151;
}

/* Availability Checkboxes */
.checkbox-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

@media (max-width: 400px) {
    .checkbox-grid {
        grid-template-columns: 1fr;
    }
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    padding: 12px 14px;
    border: 1px solid #d1d5db;
    transition: all 0.2s;
}

.checkbox-label:hover {
    border-color: #6b5b95;
    background-color: rgba(107, 91, 149, 0.05);
}

.checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: #6b5b95;
    cursor: pointer;
}

.checkbox-label input[type="checkbox"]:checked + .checkbox-text {
    color: #6b5b95;
    font-weight: 500;
}

.checkbox-text {
    font-size: 14px;
    color: #374151;
}

/* File Upload */
.file-upload-wrapper {
    position: relative;
}

.file-input {
    position: absolute;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
    z-index: 2;
}

.file-upload-button {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 32px;
    border: 2px dashed #d1d5db;
    background-color: #fafafa;
    transition: all 0.2s;
    cursor: pointer;
}

.file-upload-wrapper:hover .file-upload-button {
    border-color: #6b5b95;
    background-color: rgba(107, 91, 149, 0.05);
}

.file-icon {
    font-size: 32px;
    margin-bottom: 8px;
}

.file-text {
    font-size: 14px;
    color: #6b7280;
}

.file-name {
    font-size: 14px;
    color: #6b5b95;
    font-weight: 500;
    margin-top: 8px;
}

/* Submit Button */
.form-actions {
    margin-top: 40px;
}

.submit-button {
    width: 100%;
    padding: 16px 24px;
    background-color: #6b5b95;
    color: white;
    border: none;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    letter-spacing: 0.5px;
}

.submit-button:hover {
    background-color: #5a4a84;
}

.submit-button:disabled {
    background-color: #a99cc4;
    cursor: not-allowed;
}

.button-loading {
    display: flex;
    align-items: center;
    gap: 8px;
}

.spinner {
    display: inline-block;
    width: 18px;
    height: 18px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

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

/* Success Message */
.success-message {
    text-align: center;
    padding: 64px 24px;
}

.success-icon {
    width: 72px;
    height: 72px;
    background-color: #dcfce7;
    color: #22c55e;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 36px;
    margin: 0 auto 24px;
}

.success-message h2 {
    font-family: 'Atrament', Georgia, serif;
    font-style: italic;
    font-size: 28px;
    color: #6b5b95;
    margin-bottom: 16px;
}

.success-message p {
    color: #6b7280;
    margin-bottom: 32px;
    font-size: 16px;
}

.submit-another-btn {
    padding: 14px 28px;
    background-color: transparent;
    color: #6b5b95;
    border: 2px solid #6b5b95;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.submit-another-btn:hover {
    background-color: #6b5b95;
    color: white;
}

/* Error Message */
.error-message {
    text-align: center;
    padding: 64px 24px;
}

.error-icon {
    width: 72px;
    height: 72px;
    background-color: #fee2e2;
    color: #ef4444;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 36px;
    margin: 0 auto 24px;
}

.error-message h2 {
    font-family: 'Atrament', Georgia, serif;
    font-style: italic;
    font-size: 28px;
    color: #1f2937;
    margin-bottom: 16px;
}

.error-message p {
    color: #6b7280;
    margin-bottom: 32px;
    font-size: 16px;
}

.try-again-btn {
    padding: 14px 28px;
    background-color: #6b5b95;
    color: white;
    border: none;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.try-again-btn:hover {
    background-color: #5a4a84;
}

/* Remove validation colors - keep it clean */
input:invalid:not(:placeholder-shown),
select:invalid:not([value=""]) {
    border-color: #d1d5db;
}

input:valid:not(:placeholder-shown) {
    border-color: #d1d5db;
}

/* Responsive */
@media (max-width: 768px) {
    .form-container {
        padding: 24px;
    }

    .hero-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
    }

    .coming-soon-badge {
        position: absolute;
        right: 24px;
        top: 80px;
        width: 100px;
    }

    .hero-title {
        padding-right: 110px;
    }
}

@media (max-width: 480px) {
    .form-container {
        padding: 16px;
    }

    .coming-soon-badge {
        right: 16px;
        top: 70px;
        width: 80px;
    }

    .hero-title {
        padding-right: 90px;
        font-size: 36px;
    }

    .hero-subtitle {
        font-size: 16px;
    }
}
