/* Ortak bileşenler. Her oyunda aynı; oyuna özgü stil yok. */

/* ===== Düğmeler ===== */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 36px; padding: 0 14px; border: 0; border-radius: 10px; background: var(--accent); color: var(--accent-ink); font-weight: 800; font-size: .84rem; text-decoration: none; }
.btn:hover { filter: brightness(1.07); }
.btn:disabled { opacity: .45; cursor: not-allowed; filter: none; }
.btn.ghost { background: transparent; border: 1px solid var(--line-strong); color: var(--text); font-weight: 700; }
.btn.ghost:hover { background: var(--hover); filter: none; }
.btn.danger { background: var(--danger); color: #fff; }
.btn.sm { height: 30px; padding: 0 12px; font-size: .78rem; border-radius: 9px; }
.btn.block { width: 100%; }
.icon-btn { display: inline-grid; place-items: center; width: 34px; height: 34px; border: 0; border-radius: 10px; background: transparent; color: var(--dim); }
.icon-btn:hover { background: var(--hover); color: var(--text); }

/* ===== Form ===== */
.field { display: grid; gap: 6px; }
.field > span { font-size: .78rem; font-weight: 650; color: var(--dim); }
.input, .select { width: 100%; height: 40px; padding: 0 12px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface-2); color: var(--text); }
.input::placeholder { color: var(--dim); }
.input:focus-visible, .select:focus-visible { outline: 2px solid var(--accent); outline-offset: -1px; }
.hint { font-size: .78rem; color: var(--dim); }
.error { font-size: .82rem; color: var(--danger); min-height: 1.2em; }

/* ===== Rozetler / etiketler ===== */
.badge { display: inline-block; font-size: .62rem; font-weight: 800; letter-spacing: .03em; padding: 2px 6px; border-radius: 6px; background: var(--hover); color: var(--dim); white-space: nowrap; }
.badge.staff { background: color-mix(in srgb, var(--staff) 16%, transparent); color: var(--staff); }
.badge.op { background: color-mix(in srgb, var(--info) 16%, transparent); color: var(--info); }
.badge.vip { background: color-mix(in srgb, var(--accent) 18%, transparent); color: var(--accent); }
.badge.irc, .badge.ok { background: color-mix(in srgb, var(--ok) 16%, transparent); color: var(--ok); }
.tag { font-size: .7rem; font-weight: 700; padding: 2px 8px; border-radius: 6px; background: var(--hover); color: var(--dim); }
.tag.live { background: color-mix(in srgb, var(--ok) 16%, transparent); color: var(--ok); }
.tag.red { background: color-mix(in srgb, var(--danger) 16%, transparent); color: var(--danger); }
.count { font-size: .72rem; font-weight: 700; padding: 2px 8px; border-radius: 999px; background: var(--surface-2); color: var(--dim); border: 1px solid var(--line); }
.pills { display: flex; gap: 6px; flex-wrap: wrap; }
.pill { height: 28px; padding: 0 11px; border-radius: 999px; border: 1px solid var(--line); background: transparent; color: var(--dim); font-weight: 650; font-size: .78rem; display: inline-flex; align-items: center; gap: 5px; }
.pill small { font-size: .7rem; opacity: .8; }
.pill.on { background: var(--text); color: var(--bg); border-color: var(--text); }

/* ===== Avatar ===== */
.avatar { position: relative; display: inline-block; width: 34px; height: 34px; flex: none; }
.avatar img { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; background: var(--surface-2); display: block; }
.avatar .dot { position: absolute; right: -1px; bottom: -1px; width: 10px; height: 10px; border-radius: 50%; border: 2px solid var(--surface); background: var(--ok); }
.avatar .dot.table { background: var(--info); } .avatar .dot.away { background: var(--dim); }
.avatar.lg { width: 56px; height: 56px; } .avatar.lg img { border-radius: 16px; }

/* ===== Panel ===== */
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); display: flex; flex-direction: column; min-height: 0; overflow: hidden; }
.panel-head { display: flex; align-items: center; gap: 10px; padding: 14px 16px 10px; }
.panel-head h2 { margin: 0; font-size: .95rem; font-weight: 750; letter-spacing: -.01em; flex: 1; }
.scroll { overflow-y: auto; min-height: 0; flex: 1; padding: 0 10px 10px; }

/* ===== Modal ===== */
.modal-layer { position: fixed; inset: 0; z-index: 200; display: grid; place-items: center; padding: 16px; background: rgba(2, 6, 23, .55); }
.modal { width: min(440px, 100%); max-height: calc(100vh - 32px); overflow: auto; background: var(--surface); border: 1px solid var(--line-strong); border-radius: var(--r-lg); box-shadow: var(--shadow); padding: 18px; display: grid; gap: 14px; }
.modal h3 { margin: 0; font-size: 1.05rem; }
.modal-actions { display: flex; gap: 8px; justify-content: flex-end; }

@media (max-width: 760px) {
  .modal-layer { align-items: end; padding: 0; }
  .modal { width: 100%; max-height: 90vh; border-radius: 22px 22px 0 0; padding-bottom: calc(18px + env(safe-area-inset-bottom)); animation: sheet-in .2s ease-out; }
  .modal::before { content: ''; width: 40px; height: 4px; border-radius: 4px; background: var(--line-strong); justify-self: center; margin-top: -8px; }
  .modal .btn, .modal .input, .modal .select { min-height: 44px; }
}
@keyframes sheet-in { from { transform: translateY(24px); opacity: .6; } to { transform: none; opacity: 1; } }

/* ===== Seçim düğmeleri (segmented) ===== */
.segmented { display: flex; gap: 4px; padding: 4px; border-radius: 12px; background: var(--surface-2); }
.segmented button { flex: 1; height: 34px; border: 0; border-radius: 9px; background: transparent; color: var(--dim); font-weight: 700; font-size: .84rem; }
.segmented button.on { background: var(--surface); color: var(--text); box-shadow: 0 1px 2px rgba(0, 0, 0, .18); }

/* ===== Koltuk kartları (bekleme odası) ===== */
.seat-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.seat-card { position: relative; display: grid; justify-items: center; gap: 6px; padding: 16px 10px 12px; border-radius: var(--r-md); border: 1px solid var(--line); background: var(--surface-2); text-align: center; min-height: 128px; align-content: center; }
.seat-card.empty { border-style: dashed; background: transparent; color: var(--dim); }
.seat-card .avatar { width: 52px; height: 52px; } .seat-card .avatar img { border-radius: 16px; }
.seat-card b { font-size: .88rem; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.seat-card small { color: var(--dim); font-size: .72rem; }
.seat-card .crown { position: absolute; top: 8px; right: 10px; font-size: .9rem; }
.seat-card .plus { width: 52px; height: 52px; border-radius: 16px; border: 1px dashed var(--line-strong); display: grid; place-items: center; font-size: 1.4rem; color: var(--dim); }
.room-code { display: flex; align-items: center; gap: 8px; padding: 8px 12px; border-radius: 10px; background: var(--surface-2); border: 1px solid var(--line); }
.room-code code { font-weight: 800; letter-spacing: .06em; font-size: 1rem; }

/* ===== Bildirim ===== */
.toasts { position: fixed; right: 16px; top: 68px; display: grid; gap: 8px; z-index: 400; max-width: min(380px, calc(100vw - 32px)); }
@media (max-width: 700px) { .toasts { left: 12px; right: 12px; top: calc(env(safe-area-inset-top, 0px) + 58px); max-width: none; } }
.toast { padding: 10px 14px; border-radius: 12px; background: var(--surface); border: 1px solid var(--line-strong); box-shadow: var(--shadow); font-size: .86rem; animation: toast-in .18s ease-out; }
.toast.ok { border-left: 3px solid var(--ok); } .toast.err { border-left: 3px solid var(--danger); } .toast.warn { border-left: 3px solid var(--warn); }
@keyframes toast-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

/* ===== Yönetici uyarısı ===== */
.warn-layer { position: fixed; inset: 0; z-index: 300; display: grid; place-items: center; padding: 16px; background: rgba(2, 6, 23, .7); }
.warn-card { width: min(420px, 100%); background: var(--surface); border: 1px solid var(--danger); border-radius: var(--r-lg); padding: 22px; text-align: center; display: grid; gap: 10px; box-shadow: var(--shadow); }
.warn-card b { color: var(--danger); } .warn-card p { margin: 0; }

/* Masa kurma: onay kutuları */
.checks { display: grid; gap: 8px; }
.check { display: flex; align-items: center; gap: 10px; font-size: .88rem; cursor: pointer; }
.check input { width: 18px; height: 18px; accent-color: var(--accent); }
