/* ==========================================================================
   Saudi Trainers - Trainers Registration & Listing CSS (Front-end)
   ========================================================================== */

/* ── RTL Base ── */
.st-trainers-wrap,
.st-register-wrap {
    direction: rtl;
    font-family: 'Inter', 'Segoe UI', Tahoma, sans-serif;
}

/* ══════════════════════════════════════════
   REGISTRATION FORM
══════════════════════════════════════════ */
/* ── Registration Form Upgraded ── */
.st-registration-hero {
    background: linear-gradient(rgba(0, 51, 102, 0.7), rgba(0, 51, 102, 0.7)), url('../images/hero-bg.jpg');
    /* Placeholder for image */
    background-size: cover;
    background-position: center;
    padding: 80px 20px;
    text-align: center;
    color: #fff;
    margin-bottom: -60px;
    /* Overlap effect */
}

.st-registration-hero h1 {
    font-size: 2.8rem;
    font-weight: 800;
    margin-bottom: 12px;
}

.st-registration-hero p {
    font-size: 1.25rem;
    opacity: 0.9;
}

.st-register-wrap {
    max-width: 640px;
    margin: 0 auto 60px;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    padding: 48px;
    position: relative;
    z-index: 10;
}

.st-form-header {
    text-align: center;
    margin-bottom: 36px;
}

.st-form-subtitle {
    color: #64748b;
    font-size: 1rem;
    font-weight: 500;
}

.st-form-row {
    margin-bottom: 24px;
}

.st-form-group label {
    display: block;
    font-size: 0.9rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 10px;
    text-align: right;
}

.st-form-group .st-required {
    color: #ef4444;
}

/* Inputs */
.st-form-group input[type="text"],
.st-form-group input[type="email"],
.st-form-group input[type="tel"],
.st-form-group select {
    width: 100%;
    padding: 14px 16px;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    font-size: 1rem;
    color: #1e293b;
    background: #fff;
    transition: all 0.2s;
    outline: none;
    text-align: right;
}

.st-form-group input:focus,
.st-form-group select:focus {
    border-color: #00873c;
    box-shadow: 0 0 0 4px rgba(0, 135, 60, 0.1);
}

/* Phone Input with +966 */
.st-phone-input {
    display: flex;
    align-items: center;
    direction: ltr;
    /* To keep prefix on left or right? Screenshot shows +966 on left, but standard RTL is suffix. Logic: Saudi is +966. */
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    overflow: hidden;
    background: #fff;
}

.st-phone-input .st-country-code {
    padding: 0 16px;
    background: #f8fafc;
    color: #64748b;
    font-weight: 600;
    border-right: 1px solid #e2e8f0;
    height: 100%;
    display: flex;
    align-items: center;
    font-size: 0.95rem;
}

.st-phone-input input {
    border: none !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    padding: 14px 16px;
    flex: 1;
}

/* Select spacing */
.st-form-group select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%2394a3b8' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: left 16px center;
    padding-left: 40px;
}

/* File Upload Box */
.st-file-upload {
    border: 2px dashed #e2e8f0;
    border-radius: 12px;
    padding: 32px;
    text-align: center;
    cursor: pointer;
    background: #f8fafc;
    transition: all 0.2s;
    position: relative;
}

.st-file-upload:hover {
    border-color: #00873c;
    background: #f0fdf4;
}

.st-file-upload input[type="file"] {
    position: absolute;
    inset: 0;
    opacity: 0;
    cursor: pointer;
    z-index: 5;
}

.st-upload-icon {
    font-size: 2.5rem;
    color: #94a3b8;
    margin-bottom: 12px;
    display: block;
}

.st-upload-label {
    font-weight: 700;
    color: #1e293b;
    display: block;
    margin-bottom: 4px;
}

.st-upload-hint {
    font-size: 0.85rem;
    color: #64748b;
}

/* Submit Button */
.st-submit-btn {
    width: 100%;
    padding: 16px;
    background: #00873c;
    color: #fff;
    border: none;
    border-radius: 12px;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
    margin-top: 12px;
}

.st-submit-btn:hover {
    background: #007032;
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 135, 60, 0.25);
}

.st-form-terms {
    text-align: center;
    font-size: 0.85rem;
    color: #64748b;
    margin-top: 20px;
}

.st-form-terms a {
    color: #00873c;
    text-decoration: none;
    font-weight: 600;
}

/* Field Errors */
.st-field-error {
    color: #ef4444;
    font-size: 0.8rem;
    margin-top: 6px;
    display: block;
}

.st-form-message {
    padding: 16px;
    border-radius: 12px;
    margin-bottom: 24px;
    font-weight: 600;
    display: none;
}

.st-form-message.success {
    background: #f0fdf4;
    color: #166534;
    border: 1px solid #bbf7d0;
    display: block;
}

.st-form-message.error {
    background: #fef2f2;
    color: #991b1b;
    border: 1px solid #fecaca;
    display: block;
}


/* ══════════════════════════════════════════
   TRAINERS LISTING
══════════════════════════════════════════ */
.st-trainers-wrap {
    max-width: 1100px;
    margin: 40px auto;
    padding: 0 20px;
}

/* Filter Bar */
.st-filter-bar {
    background: #fff;
    border-radius: 12px;
    padding: 16px 20px;
    display: flex;
    gap: 12px;
    align-items: center;
    flex-wrap: wrap;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    margin-bottom: 24px;
    direction: rtl;
}

.st-filter-bar select {
    flex: 1;
    min-width: 160px;
    padding: 10px 14px;
    border: 1.5px solid #e2e8f0;
    border-radius: 8px;
    font-size: 0.875rem;
    color: #475569;
    background: #f8fafc;
    direction: rtl;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%2394a3b8' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: left 12px center;
    padding-left: 32px;
    cursor: pointer;
}

.st-filter-btn {
    padding: 10px 24px;
    background: linear-gradient(135deg, #1a6b2a, #22863a);
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 6px;
}

.st-filter-btn:hover {
    background: linear-gradient(135deg, #155222, #1a6b2a);
}

.st-results-count {
    text-align: left;
    font-size: 0.875rem;
    color: #64748b;
    margin-bottom: 16px;
    direction: rtl;
}

/* Trainers Grid */
.st-trainers-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

/* Trainer Card */
.st-trainer-card {
    background: #fff;
    border-radius: 14px;
    padding: 24px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    border: 1px solid #f1f5f9;
    transition: all 0.25s;
    direction: rtl;
    position: relative;
}

.st-trainer-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 30px rgba(0, 51, 102, 0.12);
    border-color: #e2e8f0;
}

.st-trainer-header {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 16px;
}

.st-trainer-avatar {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: linear-gradient(135deg, #003366, #005599);
    color: #fff;
    font-size: 1.25rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.st-trainer-name {
    font-size: 1rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 4px;
}

.st-trainer-stars {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 0.8rem;
    color: #f59e0b;
}

.st-trainer-stars .st-rating-num {
    color: #64748b;
    font-size: 0.78rem;
}

.st-trainer-meta {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 18px;
}

.st-trainer-meta-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.85rem;
    color: #475569;
}

.st-trainer-meta-item .st-meta-icon {
    font-size: 1rem;
    flex-shrink: 0;
}

.st-trainer-meta-item strong {
    color: #94a3b8;
    font-size: 0.78rem;
    margin-left: 4px;
}

.st-trainer-btn {
    display: block;
    width: 100%;
    padding: 11px;
    background: linear-gradient(135deg, #1a6b2a, #22863a);
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 0.875rem;
    font-weight: 600;
    text-align: center;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.2s;
}

.st-trainer-btn:hover {
    background: linear-gradient(135deg, #155222, #1a6b2a);
    color: #fff;
    transform: translateY(-1px);
}

/* Loading / Empty */
.st-trainers-loading,
.st-trainers-empty {
    text-align: center;
    padding: 60px 20px;
    color: #94a3b8;
    font-size: 1rem;
    grid-column: 1 / -1;
}

.st-trainers-empty .st-empty-icon {
    font-size: 3rem;
    margin-bottom: 12px;
    display: block;
}

/* Responsive */
@media (max-width: 640px) {
    .st-register-wrap {
        padding: 24px 16px;
    }

    .st-filter-bar {
        flex-direction: column;
    }

    .st-filter-bar select,
    .st-filter-btn {
        width: 100%;
    }

    .st-trainers-grid {
        grid-template-columns: 1fr;
    }
}