/**
 * Petitlou — Profil vendeur (store-form.php) + champs SCF (edit-account)
 *
 * Chargé sur /parametres/profil/ et /articles/settings/store/
 */

.pl-profile-form { max-width: 580px; }
.pl-settings-title { font-size: 20px; font-weight: 500; margin: 0 0 24px; color: #3E211F; }
.pl-form-group { margin-bottom: 24px; }
.pl-label { display: block; font-size: 14px; font-weight: 500; color: #3E211F; margin-bottom: 6px; }
.pl-input,
.pl-textarea {
    width: 100%;
    border: 1px solid #e0dad5;
    border-radius: 8px;
    padding: 10px 14px;
    font-size: 14px;
    color: #4A4A4A;
    transition: border-color 0.15s;
    box-sizing: border-box;
    font-family: inherit;
}
.pl-input:focus,
.pl-textarea:focus { outline: none; border-color: #F9867B; }
.pl-field-hint { font-size: 12px; color: #888; margin: 5px 0 0; }
.pl-field-error { font-size: 12px; color: #e53935; margin: 5px 0 0; }

/* Avatar */
.pl-avatar-wrap { display: flex; gap: 16px; align-items: flex-start; }
.pl-avatar-preview { position: relative; }
.pl-avatar-preview img {
    width: 88px;
    height: 88px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #f0ebe7;
    display: block;
}
.pl-avatar-preview.is-loading::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 50%;
    background: rgba(255,255,255,.7) url('data:image/svg+xml;utf8,<svg xmlns=%22http://www.w3.org/2000/svg%22 width=%2230%22 height=%2230%22 viewBox=%220 0 50 50%22><circle cx=%2225%22 cy=%2225%22 r=%2220%22 fill=%22none%22 stroke=%22%23F9867B%22 stroke-width=%224%22 stroke-dasharray=%2280 50%22><animateTransform attributeName=%22transform%22 type=%22rotate%22 from=%220 25 25%22 to=%22360 25 25%22 dur=%221s%22 repeatCount=%22indefinite%22/></circle></svg>') center / 30px no-repeat;
}
.pl-avatar-actions { display: flex; flex-direction: column; gap: 8px; padding-top: 8px; align-items: flex-start; }
.pl-btn-secondary {
    background: #fff;
    border: 1px solid #e0dad5;
    border-radius: 8px;
    padding: 8px 16px;
    font-size: 13px;
    cursor: pointer;
    color: #3E211F;
    font-family: inherit;
    font-weight: 400;
    text-transform: none;
    letter-spacing: normal;
    line-height: 1.4;
    width: auto;
    display: inline-block;
}
.pl-btn-secondary:hover { border-color: #F9867B; color: #F9867B; background: #fff; }
.pl-btn-secondary:disabled { opacity: .5; cursor: not-allowed; }
.pl-btn-ghost {
    background: none;
    border: none;
    padding: 2px 0;
    font-size: 12px;
    color: #888;
    cursor: pointer;
    text-decoration: underline;
    text-align: left;
    font-family: inherit;
    text-transform: none;
    letter-spacing: normal;
    line-height: 1.4;
    width: auto;
    display: inline-block;
}
.pl-btn-ghost:hover { color: #e53935; }

/* 2 colonnes ville / CP */
.pl-row-2 { display: grid; grid-template-columns: 2fr 1fr; gap: 14px; }
@media (max-width: 480px) { .pl-row-2 { grid-template-columns: 1fr; } }

/* Toggle vacation */
.pl-vacation-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    padding: 14px;
    border: 1px solid #f0ebe7;
    border-radius: 10px;
    background: #fdfaf8;
}
.pl-vacation-info { flex: 1; }
.pl-vacation-title { font-size: 14px; font-weight: 500; color: #3E211F; margin: 0 0 2px; }
.pl-vacation-desc { font-size: 12px; color: #888; margin: 0; }
.pl-switch { position: relative; width: 44px; height: 24px; flex-shrink: 0; display: inline-block; }
.pl-switch input { opacity: 0; width: 0; height: 0; position: absolute; }
.pl-switch-track {
    position: absolute;
    inset: 0;
    background: #d8d4cf;
    border-radius: 24px;
    cursor: pointer;
    transition: background .2s;
}
.pl-switch-track::before {
    content: '';
    position: absolute;
    left: 3px;
    top: 3px;
    width: 18px;
    height: 18px;
    background: #fff;
    border-radius: 50%;
    transition: transform .2s;
    box-shadow: 0 1px 3px rgba(0,0,0,.15);
}
.pl-switch input:checked + .pl-switch-track { background: #F9867B; }
.pl-switch input:checked + .pl-switch-track::before { transform: translateX(20px); }

/* Actions */
.pl-form-actions { margin-top: 32px; padding-top: 20px; border-top: 1px solid #f0ebe7; }
.pl-btn-save {
    background: #F9867B;
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 12px 28px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    font-family: inherit;
    text-transform: none;
    letter-spacing: normal;
}
.pl-btn-save:hover { background: #f06b5e; color: #fff; }
.pl-btn-save:disabled { opacity: .7; cursor: not-allowed; }

/* Toast feedback */
.pl-toast {
    position: fixed;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%) translateY(20px);
    background: #3E211F;
    color: #fff;
    padding: 12px 20px;
    border-radius: 8px;
    font-size: 14px;
    z-index: 10000;
    opacity: 0;
    transition: opacity .2s, transform .2s;
    pointer-events: none;
    max-width: 90%;
    box-shadow: 0 4px 12px rgba(0,0,0,.2);
}
.pl-toast.is-visible { opacity: 1; transform: translateX(-50%) translateY(0); }
.pl-toast.is-error { background: #e53935; }
.pl-toast.is-success { background: #2e7d32; }

/* ─── /parametres/compte/ — uniformiser hauteur input date ─── */
.woocommerce-EditAccountForm input#petitlou_date_naissance,
.woocommerce-EditAccountForm select#petitlou_genre {
    height: 40px;
    box-sizing: border-box;
    padding: 8px 12px;
    line-height: 1.4;
}
