/* Forms Shared Styles */

/* Photo instruction styles */
.photo-instructions,
.document-instructions {
    background: #f8f9fa;
    border: 2px solid #dee2e6;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 15px;
}

.instruction-header h4 {
    margin: 0 0 15px 0;
    color: #495057;
    font-size: 16px;
}

.photo-guide {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 20px;
}

.guide-section {
    background: white;
    border-radius: 6px;
    padding: 15px;
    text-align: center;
}

.guide-section.correct {
    border: 2px solid #28a745;
}

.guide-section.incorrect {
    border: 2px solid #dc3545;
}

.guide-image {
    margin-bottom: 10px;
}

.demo-image {
    width: 100%;
    max-width: 200px;
    height: auto;
    border-radius: 6px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.demo-image:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

.guide-section.correct .demo-image {
    border: 2px solid #28a745;
}

.guide-section.incorrect .demo-image {
    border: 2px solid #dc3545;
}

.status.good {
    color: #28a745;
    font-weight: bold;
    display: block;
    margin-bottom: 5px;
}

.status.bad {
    color: #dc3545;
    font-weight: bold;
    display: block;
    margin-bottom: 5px;
}

.guide-text p {
    margin: 0;
    font-size: 14px;
    line-height: 1.4;
}

/* Important notice styles */
.important-notice {
    background: #fff3cd;
    border: 1px solid #ffeaa7;
    border-radius: 4px;
    padding: 12px;
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin-bottom: 15px;
}

.notice-icon {
    font-size: 18px;
    flex-shrink: 0;
}

.notice-text {
    font-size: 13px;
    line-height: 1.4;
    color: #856404;
}

/* Tips section styles */
.tips-section {
    background: #e7f3ff;
    border: 1px solid #b8daff;
    border-radius: 4px;
    padding: 15px;
}

.tips-section h5 {
    margin: 0 0 10px 0;
    color: #004085;
    font-size: 14px;
}

.tips-section ul {
    margin: 0;
    padding-left: 20px;
}

.tips-section li {
    font-size: 13px;
    line-height: 1.4;
    margin-bottom: 3px;
    color: #004085;
}

/* Radio button styles */
.radio-group {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.radio-option {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    padding: 15px;
    border: 2px solid #dee2e6;
    border-radius: 8px;
    transition: all 0.3s ease;
    background-color: white;
}

.radio-option:hover {
    border-color: #007bff;
    background-color: #f8f9fa;
}

.radio-option input[type="radio"] {
    display: none;
}

/* When radio is checked, color the whole option */
.radio-option input[type="radio"]:checked ~ * {
    color: white;
}

.radio-option:has(input[type="radio"]:checked) {
    background-color: #007bff;
    border-color: #007bff;
    color: white;
}

.radio-option:has(input[type="radio"]:checked):hover {
    background-color: #0056b3;
    border-color: #0056b3;
}

/* File input styles */
.file-input-container {
    margin-top: 15px;
    text-align: center;
}

.file-select-btn {
    background: linear-gradient(135deg, #007bff 0%, #0056b3 100%);
    color: white;
    border: none;
    padding: 15px 30px;
    font-size: 16px;
    font-weight: 600;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 123, 255, 0.3);
    display: inline-flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    max-width: 300px;
    justify-content: center;
    text-transform: none;
    letter-spacing: 0.5px;
}

.file-select-btn:hover {
    background: linear-gradient(135deg, #0056b3 0%, #003d82 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 123, 255, 0.4);
}

.file-select-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 10px rgba(0, 123, 255, 0.3);
}

.file-select-btn::before {
    content: "📷";
    font-size: 18px;
}

.file-status {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #f8f9fa;
    border: 2px solid #28a745;
    border-radius: 6px;
    padding: 12px 15px;
    margin-top: 10px;
}

.file-name {
    font-weight: 500;
    color: #495057;
    flex: 1;
}

.clear-file-btn {
    background: #dc3545;
    color: white;
    border: none;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    cursor: pointer;
    font-size: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-left: 10px;
    transition: background 0.2s ease;
}

.clear-file-btn:hover {
    background: #c82333;
}

/* Button styles */
.btn {
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    text-decoration: none;
    display: inline-block;
    text-align: center;
    transition: all 0.3s ease;
}

.btn:hover {
    background-color: #0056b3;
    transform: translateY(-1px);
}

.btn.btn-primary {
    background-color: #ff6600;
    color: white;
    border: none;
    padding: 18px 35px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 600;
    transition: all 0.3s ease;
    min-width: 180px;
    text-align: center;
    box-shadow: 0 2px 8px rgba(255, 102, 0, 0.2);
}

.btn.btn-primary:hover {
    background-color: #e55a00;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(255, 102, 0, 0.3);
}

.btn.btn-secondary {
    background-color: #6c757d;
    color: white;
    padding: 15px 30px;
    font-size: 16px;
    font-weight: 600;
    min-width: 140px;
}

.btn.btn-secondary:hover {
    background-color: #545b62;
}

/* Form field styles */
#memo {
    width: 100%;
    box-sizing: border-box;
}

/* Temp message animation */
@keyframes fadeInOut {
    0% { opacity: 0; transform: translateY(-10px); }
    15% { opacity: 1; transform: translateY(0); }
    85% { opacity: 1; transform: translateY(0); }
    100% { opacity: 0; transform: translateY(-10px); }
}

.temp-message {
    animation: fadeInOut 3s ease-in-out;
}

/* Mobile optimization */
@media (max-width: 768px) {
    /* Remove main form container frame */
    .contact-form {
        background: transparent !important;
        border: none !important;
        box-shadow: none !important;
        padding: 0 !important;
        margin: 0 !important;
    }
    
    /* Remove page content container padding */
    .page-content .container {
        padding-left: 10px !important;
        padding-right: 10px !important;
    }
    
    /* Adjust form groups for mobile */
    .form-group {
        margin-bottom: 20px;
        padding: 0;
    }
    
    .photo-instructions,
    .document-instructions {
        background: transparent;
        border: none;
        padding: 15px 0;
        margin-bottom: 15px;
    }
    
    .instruction-header {
        background: #f8f9fa;
        border-radius: 6px;
        padding: 12px 15px;
        margin-bottom: 15px;
    }
    
    .photo-guide {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .guide-section {
        padding: 12px;
        margin-bottom: 10px;
    }
    
    .demo-image {
        max-width: 150px;
    }
    
    .important-notice {
        margin: 15px 0;
        padding: 10px;
        font-size: 12px;
    }
    
    .notice-text {
        font-size: 12px;
    }
    
    .tips-section {
        margin: 15px 0;
        padding: 12px;
    }
    
    .tips-section h5 {
        font-size: 13px;
    }
    
    .tips-section li {
        font-size: 12px;
    }
}

/* Customer Check Form Styles */
.customer-check-intro {
    background: #f8f9fa;
    border: 2px solid #dee2e6;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 25px;
    text-align: center;
}

.customer-check-intro h2 {
    color: #ff6600;
    margin-bottom: 15px;
    font-size: 24px;
}

.customer-check-intro p {
    margin-bottom: 0;
    font-size: 16px;
    line-height: 1.5;
    color: #555;
}

.customer-info {
    background: #e8f5e8;
    padding: 20px;
    border-radius: 8px;
    margin: 20px 0;
    border-left: 4px solid #ff6600;
}

.customer-info h3 {
    color: #ff6600;
    margin-top: 0;
    margin-bottom: 15px;
    font-size: 20px;
}

.customer-info p {
    margin-bottom: 8px;
    font-size: 15px;
}

.customer-info a {
    color: #ff6600;
    text-decoration: underline;
}

.new-customer {
    background: #f0f8ff;
    padding: 20px;
    border-radius: 8px;
    margin: 20px 0;
    border-left: 4px solid #007acc;
}

.new-customer h3 {
    color: #007acc;
    margin-top: 0;
    margin-bottom: 15px;
}

.new-customer .form-group {
    margin-bottom: 15px;
}

.new-customer label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    color: #333;
}

.new-customer input[type="text"] {
    width: 100%;
    padding: 12px;
    border: 2px solid #ddd;
    border-radius: 5px;
    font-size: 16px;
    transition: border-color 0.3s ease;
}

.new-customer input[type="text"]:focus {
    outline: none;
    border-color: #007acc;
    box-shadow: 0 0 0 3px rgba(0, 122, 204, 0.1);
}

.btn-continue {
    background: #ff6600;
    color: white;
    padding: 12px 30px;
    border: none;
    border-radius: 5px;
    font-size: 16px;
    cursor: pointer;
    width: 100%;
    margin-top: 15px;
    transition: background-color 0.3s ease;
}

.btn-continue:hover {
    background: #e55a00;
}

.btn-check {
    background: #007acc;
    color: white;
    padding: 12px 30px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
    width: 100%;
    transition: background-color 0.3s ease;
}

.btn-check:hover {
    background: #005a99;
}

.loading {
    display: none;
    text-align: center;
    margin: 20px 0;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
}

.loading p {
    margin: 0;
    font-size: 16px;
    color: #666;
}

#customer-result {
    margin-top: 20px;
}

.customer-info-display {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border: 2px solid #28a745;
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 40px;
    box-shadow: 0 4px 15px rgba(40, 167, 69, 0.1);
}

.customer-info-display h3 {
    margin: 0 0 20px 0;
    color: #28a745;
    font-size: 18px;
    font-weight: 600;
    text-align: center;
    padding-bottom: 15px;
    border-bottom: 1px solid #dee2e6;
}

.customer-details {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.detail-item {
    display: flex;
    align-items: center;
    padding: 8px 0;
}

.detail-label {
    font-weight: 600;
    color: #495057;
    min-width: 100px;
    font-size: 14px;
}

.detail-value {
    color: #212529;
    font-weight: 500;
    margin-left: 15px;
    flex: 1;
}

.customer-info-display p {
    margin-bottom: 5px;
}

.customer-info-display a {
    color: #ff6600;
    text-decoration: underline;
}

/* Phone number validation styling */
.form-text {
    font-size: 12px;
    color: #666;
    margin-top: 5px;
    display: block;
}

.form-text.phone-hint {
    color: #ff6600;
    font-weight: 500;
}

/* Orange button styling for customer check */
.btn-orange {
    background-color: #ff6600 !important;
    color: white !important;
    border: none !important;
    transition: background-color 0.3s ease;
}

.btn-orange:hover {
    background-color: #e55a00 !important;
    transform: translateY(-1px);
}

/* Form actions styling */
.form-actions {
    display: flex;
    gap: 30px;
    justify-content: center;
    margin-top: 60px;
    margin-bottom: 40px;
    align-items: center;
    flex-direction: row;
    padding: 30px 0;
    border-top: 1px solid #e9ecef;
    width: 100%;
}

/* Single button styling */
.form-actions .btn {
    min-width: 200px;
    max-width: 300px;
}

/* For single button layout like main form */
.form-actions .btn.btn-primary {
    margin: 0;
    min-width: 180px;
    flex: 0 0 auto;
    order: 2;
}

/* Single button centered layout for customer check page */
.single-button-action .btn.btn-primary {
    width: 100%;
    max-width: 300px;
    display: block;
    margin: 20px auto 0 auto;
}

/* Ensure secondary button in form actions looks consistent */
.form-actions .btn-secondary {
    min-width: 140px;
    flex: 0 0 auto;
    order: 1;
}

/* Responsive button layout */
@media (max-width: 480px) {
    .form-actions {
        flex-direction: column;
        gap: 15px;
        align-items: stretch;
    }
    
    .form-actions .btn {
        width: 100%;
        max-width: none;
    }
    
    /* Customer info responsive */
    .detail-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }
    
    .detail-value {
        margin-left: 0;
        padding-left: 20px;
    }
}

.btn-secondary {
    background-color: #6c757d;
    color: white;
    border: none;
    padding: 18px 35px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 600;
    transition: all 0.3s ease;
    min-width: 140px;
    text-align: center;
    box-shadow: 0 2px 8px rgba(108, 117, 125, 0.2);
}

.btn-secondary:hover {
    background-color: #545b62;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(108, 117, 125, 0.3);
}

.btn-secondary:hover {
    background-color: #545b62;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

/* Submit button styling */
.btn-submit {
    background-color: #ff6600;
    color: white;
    border: none;
    padding: 12px 30px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
    transition: all 0.3s ease;
    min-width: 140px;
}

.btn-submit:hover {
    background-color: #e55a00;
    transform: translateY(-1px);
}

.btn-submit:disabled {
    background-color: #ccc;
    cursor: not-allowed;
    transform: none;
}

/* Form spacing improvements */
.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: #333;
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="tel"] {
    width: 100%;
    padding: 12px;
    border: 2px solid #ddd;
    border-radius: 5px;
    font-size: 16px;
    transition: border-color 0.3s ease;
}

.form-group input[type="text"]:focus,
.form-group input[type="email"]:focus,
.form-group input[type="tel"]:focus {
    outline: none;
    border-color: #ff6600;
    box-shadow: 0 0 0 3px rgba(255, 102, 0, 0.1);
}

/* Customer info display styling */
.customer-info-display {
    background: linear-gradient(135deg, #e8f5e8 0%, #f0f9f0 100%);
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 25px;
    border-left: 5px solid #ff6600;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.customer-info-display h3 {
    color: #ff6600;
    margin-top: 0;
    margin-bottom: 15px;
    font-size: 18px;
    font-weight: 600;
}

.customer-info-display p {
    margin: 8px 0;
    font-size: 15px;
    line-height: 1.4;
}

.customer-info-display strong {
    color: #333;
    font-weight: 600;
}

.customer-info-display small {
    display: block;
    margin-top: 10px;
    font-style: italic;
}

/* Error message styling */
.error-message {
    background: linear-gradient(135deg, #f8d7da 0%, #f5c6cb 100%);
    color: #721c24;
    padding: 15px 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    border-left: 5px solid #dc3545;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.error-message h3 {
    margin-top: 0;
    margin-bottom: 10px;
    font-size: 16px;
}

.error-message p {
    margin: 0;
    line-height: 1.4;
}
