/* страницы входа, регистрации и личного кабинета — в стиле главной */
body.auth-page { background-image: url(/img/bg.jpg); background-size: max(100%, 1500px) auto; background-position: center top; background-repeat: no-repeat; min-height: 100vh; }

.auth-main { min-height: 100vh; display: grid; place-items: center; padding: 120px 16px 60px; }
.form-container.highlight { display: block; width: min(440px, 100%); padding: 36px; border-radius: 32px; line-height: 1.4; font-size: 16px; background: rgba(14, 14, 16, 0.6); overflow: visible; }
.form-container .text h2 { font-size: 34px; font-weight: 500; letter-spacing: -0.5px; margin-bottom: 6px; color: #fff; }
.form-container .text p { color: var(--text-desc); font-size: 15px; margin-bottom: 26px; }
.form { display: flex; flex-direction: column; gap: 16px; }
.input-group label { display: block; font-size: 14px; color: var(--text-other-color); margin-bottom: 8px; }
.input-wrapper { display: flex; align-items: center; gap: 10px; padding: 0 16px; border-radius: 16px; background: rgba(255, 255, 255, 0.05); border: 1px solid rgba(255, 255, 255, 0.1); transition: border-color 0.2s, background 0.2s; }
.input-wrapper:focus-within { border-color: rgba(255, 255, 255, 0.35); background: rgba(255, 255, 255, 0.08); }
.input-wrapper i { color: var(--text-desc); font-size: 18px; }
.input-wrapper input { flex: 1; min-width: 0; padding: 14px 0; background: none; border: 0; outline: none; color: #fff; font-size: 16px; }
.input-wrapper input::placeholder { color: rgba(255, 255, 255, 0.3); }
.terms { display: flex; align-items: center; gap: 10px; font-size: 14px; color: var(--text-other-color); cursor: pointer; }
.terms a, .account a { color: #fff; text-decoration: underline; text-underline-offset: 3px; }
.terms input { width: 18px; height: 18px; accent-color: #fff; }
.submit-btn { padding: 15px; border: 0; border-radius: 16px; background: #f2f2f4; color: #000; font-size: 16px; font-weight: 600; cursor: pointer; transition: transform 0.2s, background 0.2s; }
.submit-btn:hover { background: #fff; transform: translateY(-1px); }
.submit-btn:disabled { opacity: 0.5; cursor: default; transform: none; }
.account { text-align: center; color: var(--text-desc); font-size: 14px; }
.error-message { min-height: 18px; font-size: 14px; }

/* личный кабинет */
.profile-main { width: min(1100px, calc(100% - 32px)); margin: 0 auto; padding: 130px 0 100px; color: var(--text-color); display: flex; flex-direction: column; gap: 50px; }
.profile-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; }
.profile-head h1 { font-size: 56px; font-weight: 500; letter-spacing: -1px; background-image: linear-gradient(to bottom, #fff 50%, #979797); -webkit-background-clip: text; color: transparent; }
.profile-head .button { display: inline-flex; align-items: center; gap: 8px; padding: 11px 20px; border-radius: 999px; font-size: 15px; color: #fff; cursor: pointer;
  background: rgba(20, 20, 22, 0.7); border: 1px solid rgba(255, 255, 255, 0.14); backdrop-filter: blur(20px); transition: background 0.2s; }
.profile-head .button:hover { background: rgba(50, 50, 54, 0.85); }
.muted { color: var(--text-desc); }
.profile-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.highlight.card, .highlight.plan, .highlight.order { display: flex; flex-direction: column; align-items: stretch; line-height: 1.4; font-size: 16px; border-radius: 28px; padding: 28px; background: rgba(14, 14, 16, 0.6); }
.card-title { display: flex; align-items: center; gap: 10px; font-size: 18px; color: var(--text-other-color); margin-bottom: 18px; }
.card-title i { font-size: 22px; }
.facts { display: grid; gap: 12px; }
.facts div { display: flex; justify-content: space-between; gap: 16px; }
.facts dt { color: var(--text-desc); }
.facts dd { margin: 0; text-align: right; word-break: break-all; }
.sub-state { font-size: 34px; font-weight: 500; letter-spacing: -0.5px; color: var(--text-desc); }
.sub-state.active { color: #fff; }
.section-title { font-size: 40px; font-weight: 500; letter-spacing: -1px; margin-bottom: 22px; }
.plans { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.highlight.plan { gap: 16px; }
.highlight.plan.best { box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.35), 0 0 60px -20px rgba(255, 255, 255, 0.4); }
.highlight.plan.current { box-shadow: 0 0 0 1px #4caf50; }
.plan .badge { align-self: flex-start; font-size: 12px; font-weight: 600; padding: 5px 12px; border-radius: 999px; background: #f2f2f4; color: #000; }
.plan h3 { font-size: 22px; font-weight: 500; }
.plan .price { font-size: 44px; font-weight: 500; letter-spacing: -1px; }
.plan .price small { font-size: 15px; color: var(--text-desc); letter-spacing: 0; }
.plan ul { display: grid; gap: 8px; color: var(--text-other-color); font-size: 15px; flex: 1; }
.plan li::before { content: "✓"; margin-right: 10px; color: #fff; }
.orders { display: grid; gap: 10px; }
.highlight.order { flex-direction: row; align-items: center; justify-content: space-between; gap: 16px; padding: 18px 24px; border-radius: 20px; }
.order span { color: var(--text-desc); }
.order-status { padding: 5px 12px; border-radius: 999px; font-size: 13px; }
.order-status.pending { background: rgba(224, 138, 30, 0.2); color: #f0b35a; }
.order-status.paid { background: rgba(76, 175, 80, 0.2); color: #7ed283; }

@media (max-width: 860px) {
    .profile-grid, .plans { grid-template-columns: 1fr; }
    .profile-head h1 { font-size: 40px; }
    .highlight.order { flex-wrap: wrap; }
}

/* админ-панель */
.head-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.head-actions .button, .section-row .button, .admin-user .button { display: inline-flex; align-items: center; gap: 8px; padding: 10px 18px; border-radius: 999px; font-size: 14px; color: #fff; cursor: pointer;
  background: rgba(20, 20, 22, 0.7); border: 1px solid rgba(255, 255, 255, 0.14); transition: background 0.2s; white-space: nowrap; }
.head-actions .button:hover, .section-row .button:hover, .admin-user .button:hover { background: rgba(50, 50, 54, 0.85); }
.admin-user .button.danger, .icon-btn.danger { color: #ff8a80; border-color: rgba(255, 82, 82, 0.35); }
.section-row { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; margin-bottom: 18px; }
.section-row .section-title { margin: 0; }
.row-actions { display: flex; gap: 10px; }
.submit-btn.small { padding: 10px 22px; border-radius: 999px; font-size: 14px; }
.buy-url { margin-bottom: 14px; }
.field-label { display: block; font-size: 13px; color: var(--text-desc); margin-bottom: 6px; }
.admin-plans { display: grid; gap: 14px; }
.admin-plan { gap: 14px; }
.plan-fields { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; }
.admin-plan textarea, .select { width: 100%; padding: 12px 14px; border-radius: 14px; background: rgba(255, 255, 255, 0.05); border: 1px solid rgba(255, 255, 255, 0.1); color: #fff; font: inherit; font-size: 15px; resize: vertical; outline: none; }
.select option { background: #111; }
.admin-plan .input-wrapper input { padding: 11px 0; font-size: 15px; }
.plan-actions { display: flex; justify-content: flex-end; gap: 8px; }
.icon-btn { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; font-size: 18px; color: #fff; cursor: pointer; background: rgba(255, 255, 255, 0.05); border: 1px solid rgba(255, 255, 255, 0.12); }
.search { width: min(320px, 100%); }
.admin-users { display: grid; gap: 14px; }
.admin-user { gap: 12px; }
.user-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.user-name { font-size: 22px; font-weight: 500; display: flex; align-items: center; gap: 10px; }
.tag { font-size: 12px; padding: 3px 10px; border-radius: 999px; background: #f2f2f4; color: #000; }
.user-sub { font-size: 16px; color: var(--text-desc); }
.user-sub.active { color: #7ed283; }
.user-fields { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.user-fields .input-wrapper { flex: 1 1 200px; }
.user-fields .input-wrapper input { padding: 10px 0; font-size: 15px; }
.user-fields .select { flex: 1 1 200px; width: auto; padding: 10px 12px; }
.user-orders { display: grid; gap: 8px; padding-top: 6px; border-top: 1px solid rgba(255, 255, 255, 0.08); }
.order-line { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; font-size: 15px; }

/* атрибут hidden сильнее стилей кнопок */
[hidden] { display: none !important; }

/* активация кода, скачивание, промокоды */
.profile-grid { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.download-btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; margin-top: 18px; }
.redeem { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 10px; }
.redeem .input-wrapper { flex: 1 1 100%; min-width: 0; }
.redeem .input-wrapper input { text-transform: uppercase; letter-spacing: 1px; }
.redeem .submit-btn { padding: 12px 20px; }
.code-form { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; align-items: end; }
.code-form .submit-btn { padding: 13px 20px; }
.admin-codes { display: grid; gap: 10px; margin-top: 14px; }
.code-row { justify-content: flex-start; }
.code-row .code-value { font-family: ui-monospace, Consolas, monospace; letter-spacing: 1px; font-size: 17px; }
.code-row .muted { flex: 1; }
.code-row.spent { opacity: 0.5; }

/* вкладки админки */
.admin-tabs { display: flex; gap: 6px; padding: 6px; border-radius: 999px; width: fit-content; max-width: 100%; overflow-x: auto;
  background: rgba(14, 14, 16, 0.65); border: 1px solid rgba(255, 255, 255, 0.1); backdrop-filter: blur(24px); position: sticky; top: 84px; z-index: 5; }
.admin-tabs button { display: inline-flex; align-items: center; gap: 8px; padding: 10px 18px; border-radius: 999px; border: 0; background: none;
  color: var(--text-other-color); font-size: 15px; cursor: pointer; white-space: nowrap; transition: background 0.2s, color 0.2s; }
.admin-tabs button:hover { color: #fff; }
.admin-tabs button.on { background: #f2f2f4; color: #000; }
#users-badge:not(:empty) { font-size: 12px; padding: 2px 8px; border-radius: 999px; background: rgba(127, 127, 127, 0.25); }
.profile-main:has(.admin-tabs) { gap: 28px; }
