/* Кабинет: собственная вёрстка, не завязанная на разметку пульта. */

.lf-body {
  min-height: 100%;
  padding: 0 0 64px;
}

/* ---------- шапка ---------- */

.lf-top {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: calc(14px + env(safe-area-inset-top, 0px)) 24px 14px;
  background: rgba(10, 10, 10, 0.82);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border-bottom: 1px solid var(--border);
}

.lf-brand { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.lf-brand .name { font-family: var(--display); font-size: 15px; font-weight: 600; letter-spacing: 0.02em; }
.lf-brand .who { font-size: 13px; color: var(--muted); }

.lf-top-right { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }

/* ---------- вкладки ---------- */

.lf-tabs {
  display: flex;
  gap: 8px;
  padding: 18px 24px 0;
  max-width: 1240px;
  margin: 0 auto;
}

.lf-tab {
  padding: 10px 18px;
  min-height: 44px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--muted);
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
}
.lf-tab[aria-selected="true"] {
  background: var(--fg);
  color: var(--bg);
  border-color: var(--fg);
}

/* ---------- сетка ---------- */

.lf-wrap { max-width: 1240px; margin: 0 auto; padding: 20px 24px 0; }

.lf-cols {
  display: grid;
  grid-template-columns: minmax(0, 380px) minmax(0, 1fr);
  gap: 20px;
  align-items: start;
}

@media (max-width: 900px) {
  .lf-cols { grid-template-columns: minmax(0, 1fr); }
  .lf-tabs, .lf-wrap { padding-left: 16px; padding-right: 16px; }
  .lf-top { padding-left: 16px; padding-right: 16px; }
}

.lf-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 22px;
}

.lf-card + .lf-card { margin-top: 16px; }

.lf-card h2 {
  font-size: 19px;
  margin: 0 0 4px;
}

.lf-card .lf-sub {
  margin: 0 0 18px;
  font-size: 13px;
  line-height: 1.5;
  color: var(--muted);
}

.lf-field { margin-bottom: 14px; }
.lf-field:last-of-type { margin-bottom: 18px; }

.lf-label {
  display: block;
  margin-bottom: 7px;
  font-size: 13px;
  font-weight: 500;
  color: var(--muted);
}

.lf-input {
  width: 100%;
  min-height: 48px;
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border);
  border-radius: 12px;
  color: var(--fg);
  font-size: 15px;
  outline: none;
}
.lf-input:focus { border-color: var(--fg); }
.lf-input::placeholder { color: rgba(255, 255, 255, 0.35); }

.lf-row { display: flex; gap: 8px; align-items: stretch; }
.lf-row .lf-input { flex: 1 1 auto; min-width: 0; }

/* ---------- кнопки ---------- */

.lf-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 12px 18px;
  border: 1px solid transparent;
  border-radius: 12px;
  background: var(--fg);
  color: var(--bg);
  font-size: 15px;
  font-weight: 600;
  text-align: center;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
}
.lf-btn:disabled { opacity: 0.45; cursor: default; }
.lf-btn.wide { width: 100%; }

.lf-btn.ghost {
  background: transparent;
  color: var(--fg);
  border-color: var(--border);
}
.lf-btn.small { min-height: 40px; padding: 8px 14px; font-size: 14px; }
.lf-btn.danger { background: transparent; color: #E58A8A; border-color: rgba(229, 138, 138, 0.45); }
.lf-btn.danger:hover { background: rgba(229, 138, 138, 0.12); }
.lf-btn.icon { min-width: 48px; padding: 12px; }

/* ---------- список ---------- */

.lf-list { display: flex; flex-direction: column; gap: 12px; }

.lf-item {
  padding: 18px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border);
  border-radius: 16px;
}
.lf-item.live { border-color: var(--fg); }
.lf-item.off { opacity: 0.55; }

.lf-item-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 6px;
}

.lf-item-title { font-size: 16px; font-weight: 600; }
.lf-item-meta { font-size: 13px; color: var(--muted); }

.lf-badge {
  padding: 3px 9px;
  border-radius: 7px;
  background: rgba(255, 255, 255, 0.1);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  white-space: nowrap;
}
.lf-badge.live { background: var(--fg); color: var(--bg); }
.lf-badge.off { background: rgba(229, 138, 138, 0.2); color: #E58A8A; }

.lf-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

/* ---------- ссылки мероприятия ---------- */

.lf-links { margin-top: 14px; display: flex; flex-direction: column; gap: 10px; }

.lf-link-label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 5px;
}

.lf-link-row { display: flex; gap: 8px; }
.lf-link-row .lf-input { font-size: 12px; min-height: 42px; padding: 9px 12px; }

.lf-empty {
  padding: 28px 18px;
  text-align: center;
  font-size: 14px;
  line-height: 1.6;
  color: var(--muted);
}

/* ---------- выдача доступа ---------- */

.lf-issued {
  margin-top: 16px;
  padding: 18px;
  border: 1px solid var(--fg);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.05);
}
.lf-issued pre {
  margin: 12px 0;
  padding: 14px;
  background: rgba(0, 0, 0, 0.35);
  border-radius: 10px;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 13px;
  line-height: 1.6;
  white-space: pre-wrap;
  word-break: break-all;
}

/* ---------- вход ---------- */

.lf-login-shell {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 24px;
}
.lf-login { width: 100%; max-width: 400px; }
.lf-error { margin-top: 12px; font-size: 14px; color: #E58A8A; min-height: 20px; }

/* ---------- срок доступа ---------- */

select.lf-input {
  appearance: none;
  -webkit-appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%),
                    linear-gradient(135deg, var(--muted) 50%, transparent 50%);
  background-position: calc(100% - 20px) 50%, calc(100% - 14px) 50%;
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
  padding-right: 40px;
  cursor: pointer;
}
select.lf-input option { background: #14151a; color: #fff; }

select.lf-renew {
  min-height: 40px;
  padding: 8px 34px 8px 14px;
  font-size: 14px;
  background-position: calc(100% - 16px) 50%, calc(100% - 10px) 50%;
}

.lf-badge.soon { background: rgba(233, 164, 74, 0.2); color: #E9A44A; }

/* ---------- тарифы ---------- */

.lf-tariff {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 14px 16px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border);
  border-radius: 14px;
}

.lf-tariff-name { font-size: 15px; font-weight: 600; }
.lf-tariff-note { font-size: 12px; color: var(--muted); margin-top: 3px; }
.lf-tariff-price { font-size: 17px; font-weight: 600; white-space: nowrap; }
