/* ============================================================
   PayTech Facture — Frontend CSS (noir & blanc premium)
   ============================================================ */

:root {
    --ptf-bg:       #0a0a0a;
    --ptf-surface:  #111111;
    --ptf-surface2: #1a1a1a;
    --ptf-border:   #2a2a2a;
    --ptf-text:     #f5f5f5;
    --ptf-muted:    #888888;
    --ptf-accent:   #ffffff;
    --ptf-radius:   16px;
}

/* ── Wrapper ─────────────────────────────────────────────────── */
.ptf-wrapper {
    max-width: 520px;
    margin: 40px auto;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    color: var(--ptf-text);
}

/* ── Notice erreur ──────────────────────────────────────────── */
.ptf-notice {
    padding: 12px 16px;
    border-radius: 10px;
    margin-bottom: 16px;
    font-size: 14px;
}
.ptf-notice--warning {
    background: rgba(245,158,11,.1);
    border: 1px solid rgba(245,158,11,.3);
    color: #f59e0b;
}
.ptf-notice--error {
    background: rgba(239,68,68,.1);
    border: 1px solid rgba(239,68,68,.3);
    color: #ef4444;
}
.ptf-notice a { color: inherit; font-weight: 700; }

/* ── Carte principale ───────────────────────────────────────── */
.ptf-card {
    background: var(--ptf-surface);
    border: 1px solid var(--ptf-border);
    border-radius: var(--ptf-radius);
    overflow: hidden;
    box-shadow:
        0 0 0 1px rgba(255,255,255,.04) inset,
        0 24px 48px rgba(0,0,0,.6);
}

/* Header */
.ptf-card__header {
    background: var(--ptf-surface2);
    border-bottom: 1px solid var(--ptf-border);
    padding: 28px 32px 24px;
    display: flex;
    align-items: center;
    gap: 16px;
    position: relative;
    overflow: hidden;
}
.ptf-card__header::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,.15), transparent);
}
.ptf-icon {
    width: 40px; height: 40px;
    color: var(--ptf-text);
    flex-shrink: 0;
    background: rgba(255,255,255,.06);
    padding: 8px;
    border-radius: 10px;
    box-sizing: border-box;
}
.ptf-card__title {
    color: var(--ptf-text);
    font-size: 20px;
    font-weight: 700;
    margin: 0; padding: 0; border: none;
    letter-spacing: -.2px;
}

/* Body */
.ptf-card__body { padding: 28px 32px; }

/* Footer */
.ptf-card__footer {
    background: var(--ptf-surface2);
    border-top: 1px solid var(--ptf-border);
    padding: 13px 32px;
    font-size: 13px;
    color: var(--ptf-muted);
    text-align: center;
}

/* ── Formulaire ─────────────────────────────────────────────── */
.ptf-form { display: flex; flex-direction: column; gap: 20px; }
.ptf-field { display: flex; flex-direction: column; gap: 7px; }

.ptf-label {
    font-size: 12px;
    font-weight: 600;
    color: var(--ptf-muted);
    text-transform: uppercase;
    letter-spacing: .5px;
}
.ptf-required { color: #ef4444; margin-left: 3px; }

.ptf-input {
    width: 100%;
    padding: 13px 16px;
    background: var(--ptf-surface2);
    border: 1px solid var(--ptf-border);
    border-radius: 10px;
    font-size: 15px;
    color: var(--ptf-text);
    outline: none;
    transition: border-color .2s, box-shadow .2s;
    box-sizing: border-box;
}
.ptf-input:focus {
    border-color: rgba(255,255,255,.4);
    box-shadow: 0 0 0 3px rgba(255,255,255,.06);
}
.ptf-input::placeholder { color: #444; }

/* Groupe input + suffixe */
.ptf-input-group {
    display: flex;
    align-items: center;
    background: var(--ptf-surface2);
    border: 1px solid var(--ptf-border);
    border-radius: 10px;
    overflow: hidden;
    transition: border-color .2s, box-shadow .2s;
}
.ptf-input-group:focus-within {
    border-color: rgba(255,255,255,.4);
    box-shadow: 0 0 0 3px rgba(255,255,255,.06);
}
.ptf-input-group .ptf-input {
    border: none; border-radius: 0; flex: 1;
    box-shadow: none !important; background: transparent;
}
.ptf-input-suffix {
    padding: 0 16px;
    background: rgba(255,255,255,.04);
    color: var(--ptf-muted);
    font-size: 13px; font-weight: 600;
    white-space: nowrap;
    border-left: 1px solid var(--ptf-border);
    height: 48px;
    display: flex; align-items: center;
}

/* Préfixe téléphone */
.ptf-phone-prefix {
    padding: 0 14px;
    background: rgba(255,255,255,.04);
    color: var(--ptf-muted);
    font-size: 14px; font-weight: 600;
    white-space: nowrap;
    border-right: 1px solid var(--ptf-border);
    height: 48px;
    display: flex; align-items: center;
}

.ptf-hint { font-size: 12px; color: #555; }

/* ── Bouton ─────────────────────────────────────────────────── */
.ptf-btn {
    width: 100%;
    padding: 15px;
    background: var(--ptf-accent);
    color: #000;
    font-size: 15px; font-weight: 700;
    border: none; border-radius: 10px;
    cursor: pointer;
    transition: background .2s, transform .1s, opacity .2s;
    margin-top: 4px;
    letter-spacing: .1px;
}
.ptf-btn:hover:not(:disabled) {
    background: #e8e8e8;
    transform: translateY(-1px);
}
.ptf-btn:active:not(:disabled) { transform: translateY(0); }
.ptf-btn:disabled { opacity: .5; cursor: not-allowed; }

.ptf-btn__text,
.ptf-btn__loading {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

/* Spinner */
@keyframes ptf-spin {
    from { transform: rotate(0deg); }
    to   { transform: rotate(360deg); }
}
.ptf-spin { animation: ptf-spin .8s linear infinite; }

/* ── Méthodes ───────────────────────────────────────────────── */
.ptf-methods {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin-top: 22px;
    padding-top: 20px;
    border-top: 1px solid var(--ptf-border);
}
.ptf-methods__label { color: var(--ptf-muted); width: 100%; font-size: 12px; text-transform: uppercase; letter-spacing: .5px; }
.ptf-badge {
    padding: 4px 12px; border-radius: 20px;
    font-size: 12px; font-weight: 600;
    background: rgba(255,255,255,.06);
    color: rgba(255,255,255,.7);
    border: 1px solid rgba(255,255,255,.08);
}

/* ── Responsive ─────────────────────────────────────────────── */
@media (max-width: 560px) {
    .ptf-wrapper { margin: 16px; max-width: 100%; }
    .ptf-card__header, .ptf-card__body { padding: 20px; }
    .ptf-card__footer { padding: 12px 20px; }
    .ptf-card__title { font-size: 18px; }
}
