.xcom-form .xcom-form-field {
    margin-bottom: 15px;
}

.xcom-form label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
}

.xcom-form input[type="text"],
.xcom-form input[type="email"],
.xcom-form input[type="tel"],
.xcom-form textarea,
.xcom-form select {
    width: 100%;
    padding: 8px;
    border: 1px solid #ccc;
    border-radius: 4px;
}

.xcom-form .xcom-form-errors {
    padding: 10px;
    margin-bottom: 15px;
    border: 1px solid #f00;
    background-color: #ffebe8;
    color: #f00;
}

.xcom-form .field-error input,
.xcom-form .field-error textarea,
.xcom-form .field-error select {
    border-color: #d63638;
    box-shadow: 0 0 0 1px #d63638;
}

.xcom-form .field-error-message {
    color: #d63638;
    font-size: 12px;
    margin-top: 5px;
}

.xcom-form .xcom-form-field-etunimi,
.xcom-form .xcom-form-field-sukunimi {
    display: inline-block;
    width: calc(50% - 8px);
}

.xcom-form .xcom-form-field-etunimi {
    margin-right: 15px;
}

/* Mobile responsive design */
@media (max-width: 500px) {
    .xcom-form .xcom-form-field-etunimi,
    .xcom-form .xcom-form-field-sukunimi {
        display: block;
        width: 100%;
        margin-right: 0;
        margin-bottom: 15px;
    }
}

/* reCAPTCHA Enterprise Button Styling */
.xcom-form .g-recaptcha {
    background-color: #1976d2;
    border: none;
    color: white;
    padding: 12px 24px;
    font-size: 16px;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    margin-top: 15px;
    min-height: 40px;
}

.xcom-form .g-recaptcha:hover {
    background-color: #1565c0;
}

.xcom-form .g-recaptcha:disabled {
    background-color: #ccc;
    cursor: not-allowed;
}

.xcom-form input[type="submit"] {
    background-color: #1976d2;
    border: none;
    color: white;
    padding: 12px 24px;
    font-size: 16px;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    margin-top: 15px;
    min-height: 40px;
}

.xcom-form input[type="submit"]:hover {
    background-color: #1565c0;
}

/* File Upload Progress and Preview Styles */
.upload-progress-container {
    margin: 15px 0;
    padding: 10px;
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 4px;
}

.upload-progress-bar {
    width: 100%;
    height: 20px;
    background-color: #e9ecef;
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 8px;
}

.upload-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #28a745, #20c997);
    width: 0%;
    transition: width 0.3s ease;
    border-radius: 10px;
}

.upload-progress-text {
    text-align: center;
    font-size: 14px;
    font-weight: bold;
    color: #495057;
}

/* File Preview Styles */
.file-preview-container {
    margin-top: 15px;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.file-preview-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 10px;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    background: #fff;
    max-width: 150px;
    position: relative;
    transition: all 0.3s ease;
}

.file-preview-item:hover {
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.file-preview-item.upload-success {
    border-color: #28a745;
    background: #f8fff9;
}

.file-thumbnail {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 4px;
    margin-bottom: 8px;
    border: 1px solid #dee2e6;
}

.file-thumbnail video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 4px;
}

.file-icon {
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    margin-bottom: 8px;
}

.file-name {
    font-size: 12px;
    font-weight: bold;
    text-align: center;
    word-break: break-word;
    margin-bottom: 4px;
    color: #495057;
}

.file-size {
    font-size: 10px;
    color: #6c757d;
    text-align: center;
}

.upload-status {
    position: absolute;
    top: -8px;
    right: -8px;
    background: #28a745;
    color: white;
    font-size: 10px;
    padding: 2px 6px;
    border-radius: 12px;
    font-weight: bold;
}

.upload-success-message {
    padding: 20px;
    background: #d4edda;
    border: 1px solid #c3e6cb;
    border-radius: 4px;
    color: #155724;
    text-align: center;
    font-weight: bold;
}

/* Mobile responsive for file previews */
@media (max-width: 500px) {
    .file-preview-container {
        justify-content: center;
    }
    
    .file-preview-item {
        max-width: 120px;
    }
    
    .file-thumbnail,
    .file-icon {
        width: 60px;
        height: 60px;
    }
    
    .file-name {
        font-size: 11px;
    }
    
    .file-size {
        font-size: 9px;
    }
}
