/* LIZZYLANDIA · Amigas de Lizzy (panel de Lizzy: invitar con 3 fotos, estado de Meshy y enlaces).
   Usa las variables y clases de lizzy.css (.btn, .field, .check, .note, .form-error, .section-title).
   Se enlaza después de lizzy.css: <link rel="stylesheet" href="/css/friends.css"> */
.friends { display: grid; gap: 10px; }
.friends .section-title { margin: 8px 0 2px; }
.friends-banner { margin: 0; padding: 10px 12px; border-radius: 12px; font-size: 14px; color: var(--warn); background: rgba(255, 211, 110, 0.1); border: 1px solid rgba(255, 211, 110, 0.4); }
.friends-quota { margin: 0; color: var(--muted); font-size: 14px; }
.friends-empty { margin: 0; color: var(--muted); }
.friends-list { display: grid; gap: 10px; }
.friends > .form-error:empty { display: none; }

/* tarjeta de cada amiga */
.friend-card { display: grid; gap: 8px; padding: 12px 14px; border-radius: 14px; background: rgba(255, 255, 255, 0.05); border: 1px solid var(--line-soft); }
.friend-card.is-ready { border-color: rgba(127, 227, 180, 0.55); }
.friend-card.is-failed { border-color: rgba(255, 122, 143, 0.6); }
.friend-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.friend-name { flex: 1; min-width: 0; font-family: var(--serif); font-size: 18px; color: var(--pink-2); overflow-wrap: anywhere; }
.friend-meta { color: var(--muted); font-size: 13px; }
.friend-status { padding: 3px 10px; border-radius: 999px; font-size: 12px; font-weight: 750; white-space: nowrap; background: rgba(255, 255, 255, 0.08); }
.friend-status.is-ready { background: rgba(127, 227, 180, 0.18); color: var(--ok); }
.friend-status.is-failed { background: rgba(255, 122, 143, 0.18); color: var(--danger); }
.friend-status.is-working { background: rgba(255, 211, 110, 0.16); color: var(--warn); }
.friend-progress { height: 6px; border-radius: 6px; background: rgba(255, 255, 255, 0.12); overflow: hidden; }
.friend-progress i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--pink), var(--gold)); transition: width 0.4s ease; }
.friend-hint { margin: 0; color: var(--muted); font-size: 13px; line-height: 1.4; }
.friend-error { margin: 0; color: var(--danger); font-size: 14px; line-height: 1.4; }
.friend-invite { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.friend-invite input { flex: 1; min-width: 0; padding: 8px 10px; border-radius: 10px; border: 1px solid var(--line-soft); background: rgba(0, 0, 0, 0.32); font-size: 13px; }
.friend-invite input:focus { border-color: var(--gold); outline: none; }
.friend-actions, .friend-confirm { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.friend-confirm span { flex: 1 1 220px; font-size: 14px; color: var(--cream); }
.friend-card .btn.danger, .friend-confirm .btn.danger { border-color: rgba(255, 122, 143, 0.55); color: #ffc2cc; }
.friend-card .btn.danger:hover { background: rgba(255, 122, 143, 0.14); }

/* formulario para invitar */
.friend-form { display: grid; gap: 12px; padding: 14px; border-radius: 16px; border: 1px solid var(--line); background: rgba(255, 255, 255, 0.03); }
.friend-form .field { margin: 0; }
.friend-form .check { margin: 0; }
.friend-form .note { margin: 0; }
.friend-label { font-weight: 600; color: var(--cream); }
.friend-form input[type='number'] { width: 130px; padding: 12px 14px; border-radius: 12px; border: 1px solid var(--line-soft); background: rgba(0, 0, 0, 0.32); }
.friend-form input[type='number']:focus { border-color: var(--gold); outline: none; box-shadow: 0 0 0 3px rgba(227, 183, 99, 0.2); }
.friend-form input:disabled { opacity: 0.6; }
.photo-slots { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.photo-slot { position: relative; display: grid; gap: 4px; justify-items: center; text-align: center; padding: 8px; border-radius: 14px; border: 1px dashed var(--line); background: rgba(0, 0, 0, 0.2); cursor: pointer; }
.photo-slot:hover { border-color: var(--gold-2); }
.photo-slot:focus-within { outline: 2px solid var(--gold-2); outline-offset: 2px; }
.photo-slot.has-photo { border-style: solid; border-color: var(--pink); }
.photo-slot .preview { width: 100%; aspect-ratio: 3 / 4; border-radius: 10px; object-fit: cover; background: rgba(255, 255, 255, 0.05); }
.photo-slot .preview.placeholder { display: grid; place-items: center; font-size: 28px; color: var(--muted); }
.photo-slot b { font-size: 13px; }
.photo-slot small { color: var(--muted); font-size: 12px; }
/* el selector de archivo queda oculto pero enfocable (lo abre la etiqueta) */
.photo-input { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; border: 0; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; }
.friend-sending { color: var(--warn); min-height: 1.3em; margin: 6px 0; }
.friend-sent { color: var(--ok); min-height: 1.3em; margin: 6px 0; }

@media (max-width: 640px) {
  .photo-slots { gap: 6px; }
  .photo-slot { padding: 6px; }
  .friend-name { font-size: 16px; }
}
