/* =========================================================
   TG PRISM — MAIN STYLESHEET
   Structure:
   01. Reset / Base
   02. Background / Frame
   03. Sidebar
   04. Layout / Topbar
   05. Hero
   06. Section Titles
   07. Recommended Cards
   08. Channels Grid
   09. Pagination / Load More
   10. Detail Pages
   11. Forms
   12. Admin Panel
   13. Profile
   14. Responsive
   ========================================================= */


/* =========================================================
   01. RESET / BASE
   ========================================================= */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

.topbar-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.mobile-top-brand {
    display: none;
}

html {
    scroll-behavior: smooth;
}

html.lenis {
    height: auto;
}

.lenis.lenis-smooth {
    scroll-behavior: auto;
}

.lenis.lenis-smooth [data-lenis-prevent] {
    overscroll-behavior: contain;
}

body {
    min-height: 100vh;

    background: #000;
    color: #fff;

    font-family: Arial, sans-serif;

    overflow-x: hidden;

    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

a,
button,
input,
textarea,
select {
    font-family: inherit;
}


/* =========================================================
   02. BACKGROUND / FRAME
   ========================================================= */

#bgCanvas {
    position: fixed;
    inset: 0;
    z-index: 1;

    width: 100vw;
    height: 100vh;

    background: #000;
    pointer-events: none;
}

.frame {
    position: fixed;
    inset: 12px;
    z-index: 50;

    border: 1px solid rgba(255, 255, 255, .18);

    pointer-events: none;
}


/* =========================================================
   03. SIDEBAR
   ========================================================= */

.sidebar {
    position: fixed;
    left: 12px;
    top: 12px;
    bottom: 12px;
    z-index: 10;

    width: 260px;
    padding: 24px;

    overflow: hidden;

    background: rgba(0, 0, 0, .72);
    border-right: 1px solid rgba(255, 255, 255, .12);
    backdrop-filter: blur(14px);
}

.brand {
    display: flex;
    align-items: center;
    gap: 14px;

    padding-bottom: 24px;

    border-bottom: 1px solid rgba(255, 255, 255, .12);

    font-size: 14px;
    font-weight: 700;
    letter-spacing: 3px;
}

.brand-icon {
    flex-shrink: 0;

    width: 38px;
    height: 38px;

    display: block;
    object-fit: cover;
    object-position: center;

    border-radius: 8px;
    filter: contrast(1.08) brightness(1.08);
}

.side-block {
    margin-top: 24px;
}

.side-title {
    margin-bottom: 12px;

    color: rgba(255, 255, 255, .35);

    font-size: 10px;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.categories-list {
    max-height: 360px;
    padding-right: 6px;

    display: flex;
    flex-direction: column;
    gap: 6px;

    overflow-y: auto;

    scroll-behavior: smooth;
    overscroll-behavior: contain;
}

.categories-list::-webkit-scrollbar {
    width: 3px;
}

.categories-list::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, .22);
}

.category-btn {
    position: relative;

    width: 100%;
    min-height: 40px;
    padding: 0 11px;

    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;

    background: rgba(255, 255, 255, .025);
    border: 1px solid rgba(255, 255, 255, .06);

    color: rgba(255, 255, 255, .62);

    font-size: 10px;
    letter-spacing: 1px;
    text-align: left;
    text-transform: uppercase;

    cursor: pointer;

    transition:
        color .2s ease,
        background .2s ease,
        border-color .2s ease;
}
.category-btn,
.category-btn:hover,
.category-btn:visited {
    text-decoration: none;
}
.category-btn em {
    text-decoration: none;
}

.category-btn span {
    overflow: hidden;

    white-space: nowrap;
    text-overflow: ellipsis;
}

.category-btn em {
    flex-shrink: 0;

    color: rgba(255, 255, 255, .28);

    font-size: 10px;
    font-style: normal;
}

.category-btn:hover {
    color: #fff;
    background: rgba(255, 255, 255, .06);
    border-color: rgba(255, 255, 255, .16);
}

.category-btn.active {
    color: #fff;
    background: rgba(255, 255, 255, .08);
    border-color: rgba(255, 255, 255, .22);
}

.category-btn.active::before {
    content: "";

    position: absolute;
    left: -1px;
    top: 8px;
    bottom: 8px;

    width: 3px;

    background: #fff;
    box-shadow: 0 0 12px rgba(255, 255, 255, .9);
}

.side-link {
    display: block;

    padding: 8px 0;

    color: rgba(255, 255, 255, .65);
    text-decoration: none;

    font-size: 13px;

    transition:
        color .2s ease,
        transform .2s ease;
}

.side-link:hover {
    color: #fff;
    transform: translateX(4px);
}

.side-actions {
    margin-top: 22px;

    display: flex;
    flex-direction: column;
    gap: 10px;
}

.side-action {
    display: block;

    padding: 12px;

    border: 1px solid rgba(255, 255, 255, .12);

    color: #fff;
    text-align: center;
    text-decoration: none;

    font-size: 12px;
    font-weight: 700;

    transition: transform .2s ease;
}

.side-action:hover {
    transform: translateY(-2px);
}

.side-action.vip {
    background: linear-gradient(90deg, #f59e0b, #facc15);
    color: #000;
}

.side-action.add {
    background: #2563eb;
    color: #fff;
}

.sidebar-status {
    position: absolute;
    left: 24px;
    right: 24px;
    bottom: 18px;

    display: flex;
    align-items: center;
    gap: 10px;

    color: rgba(255, 255, 255, .45);

    font-size: 10px;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.dot {
    width: 7px;
    height: 7px;

    background: #22c55e;
    border-radius: 50%;
    box-shadow: 0 0 12px #22c55e;
}


/* =========================================================
   04. LAYOUT / TOPBAR
   ========================================================= */

.app {
    position: relative;
    z-index: 5;

    min-height: 100vh;
    margin-left: 272px;
}

.topbar {
    height: 76px;
    padding: 0 42px;

    position: sticky;
    top: 0;
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: space-between;

    background: rgba(0, 0, 0, .45);
    border-bottom: 1px solid rgba(255, 255, 255, .12);
    backdrop-filter: blur(14px);
}

.topbar-title {
    color: rgba(255, 255, 255, .45);

    font-size: 11px;
    letter-spacing: 3px;
}

.mobile-top-brand {
    align-items: center;
    gap: 10px;
    min-width: 0;
    color: #fff;
    text-decoration: none;
    font-size: 13px;
    font-weight: 800;
    letter-spacing: 4px;
    white-space: nowrap;
}

.mobile-top-brand-icon {
    width: 34px;
    height: 34px;
    object-fit: cover;
    flex-shrink: 0;
}

.top-add-btn {
    height: 44px;
    padding: 0 18px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    border: 1px solid rgba(255, 255, 255, .15);

    color: #fff;
    text-decoration: none;

    transition:
        color .2s ease,
        background .2s ease;
}

.top-add-btn:hover {
    background: #fff;
    color: #000;
}

.content {
    padding: 48px 42px;
}


/* =========================================================
   05. HERO
   ========================================================= */

.hero {
    position: relative;

    max-width: 1100px;
    margin: 0 auto 50px;
    padding: 50px;

    overflow: hidden;

    background: rgba(0, 0, 0, .55);
    border: 1px solid rgba(255, 255, 255, .12);
    backdrop-filter: blur(12px);

    text-align: center;
}

.hero::before {
    content: "";

    position: absolute;
    left: 50%;
    top: 50%;

    width: 600px;
    height: 600px;

    background: radial-gradient(circle, rgba(255, 255, 255, .05), transparent 70%);

    transform: translate(-50%, -50%);
    pointer-events: none;
}

.eyebrow {
    display: block;

    margin-bottom: 20px;

    color: rgba(255, 255, 255, .45);

    font-size: 11px;
    letter-spacing: 3px;
}

.hero h1 {
    margin-bottom: 18px;

    font-size: 64px;
    font-weight: 300;
    letter-spacing: -2px;
    line-height: .95;
}

.hero p {
    max-width: 560px;
    margin: 0 auto 30px;

    color: rgba(255, 255, 255, .55);

    font-size: 16px;
    line-height: 1.7;
}

.hero-search {
    max-width: 700px;
    height: 64px;
    margin: auto;
    padding: 18px 22px;

    display: flex;
    align-items: center;
    gap: 12px;

    background: rgba(255, 255, 255, .03);
    border: 1px solid rgba(255, 255, 255, .18);
    backdrop-filter: blur(10px);

    box-shadow:
        0 0 25px rgba(255, 255, 255, .03),
        inset 0 0 15px rgba(255, 255, 255, .03);
}

.hero-search input {
    width: 100%;

    background: transparent;
    border: 0;
    outline: 0;

    color: #fff;

    font-size: 15px;
}


/* =========================================================
   06. SECTION TITLES
   ========================================================= */

.block-title {
    display: flex;
    align-items: center;
    gap: 12px;

    margin-bottom: 20px;
}

.block-title h2 {
    font-size: 34px;
    font-weight: 300;
}

.block-icon {
    width: 34px;
    height: 34px;

    display: grid;
    place-items: center;

    border: 1px solid rgba(255, 255, 255, .2);
}


/* =========================================================
   07. RECOMMENDED CARDS
   ========================================================= */

.recommended-title .block-icon {
    border-color: rgba(245, 197, 66, .55);
    color: #f5c542;
    box-shadow: 0 0 24px rgba(245, 197, 66, .12);
}

.recommended-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;

    margin-bottom: 50px;
}

.recommended-card {
    position: relative;
    min-height: 240px;
    overflow: hidden;
    min-height: 270px;
    display: flex;
    flex-direction: column;
    padding: 22px;

    background:
        radial-gradient(circle at top right, rgba(245, 197, 66, .13), transparent 36%),
        rgba(255, 255, 255, .035);

    border: 1px solid rgba(245, 197, 66, .55);
    box-shadow: 0 0 30px rgba(245, 197, 66, .08);   
    backdrop-filter: blur(12px);

    transition:
        transform .35s ease,
        border-color .35s ease,
        box-shadow .35s ease,
        background .35s ease;
}
.recommended-card .card-top {
    display: flex;
    justify-content: space-between;
    align-items: start;
}

.recommended-card:hover {
    transform: translateY(-7px);
    border-color: rgba(245, 197, 66, .7);
    box-shadow: 0 0 35px rgba(245, 197, 66, .14);
}

.recommend-badge {
    position: absolute;

    top: 18px;
    right: 18px;

    padding: 6px 12px;

    background: rgba(245, 197, 66, .12);

    border: 1px solid rgba(245, 197, 66, .4);

    color: #f5c542;

    font-size: 11px;
    letter-spacing: 1px;

    text-transform: uppercase;

    z-index: 5;
}



.big {
    width: 70px;
    height: 70px;
    margin-bottom: 20px;

    border-color: rgba(245, 197, 66, .55);
    color: #f5c542;
}

.recommended-content {
    height: 100%;
    display: flex;
    flex-direction: column;
}

.recommended-card .stats {
    margin-top: auto;
}


.locked-layer strong {
    max-width: 90%;

    font-size: 20px;
    font-weight: 500;
}

.locked-layer span {
    color: rgba(255, 255, 255, .55);
    font-size: 13px;
}

.card-link {
    position: absolute;
    inset: 0;
    z-index: 5;
}


/* =========================================================
   08. CHANNELS GRID
   ========================================================= */

.channels-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    scroll-margin-top: 120px;

    margin-bottom: 25px;
}

.sort-tabs {
    display: flex;
    gap: 10px;
}

.sort-btn {
    padding: 10px 14px;

    background: transparent;
    border: 1px solid rgba(255, 255, 255, .15);

    color: rgba(255, 255, 255, .55);

    cursor: pointer;

    transition:
        color .2s ease,
        background .2s ease;
}

.sort-btn.active,
.sort-btn:hover {
    background: #fff;
    color: #000;
}

.channels-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 18px;

    transition: opacity .2s ease;
}

.channels-grid.loading {
    opacity: .25;
}

.channel-card {
    min-height: 270px;
    padding: 22px;
    display: flex;
    flex-direction: column;

    background: rgba(0, 0, 0, .62);
    border: 1px solid rgba(255, 255, 255, .12);
    backdrop-filter: blur(10px);

    transition:
        transform .35s ease,
        border-color .35s ease,
        background .35s ease;

    will-change: transform;
}

.channel-card:hover {
    background: rgba(255, 255, 255, .04);
    border-color: rgba(255, 255, 255, .65);

    transform: translateY(-6px);
}

.card-top {
    display: flex;
    align-items: center;
    justify-content: space-between;

    margin-bottom: 24px;
}

.avatar {
    width: 42px;
    height: 42px;

    display: grid;
    place-items: center;

    border: 1px solid rgba(255, 255, 255, .7);

    font-size: 18px;
}

.card-code {
    color: rgba(255, 255, 255, .3);

    font-size: 10px;
    letter-spacing: 2px;
}

.category {
    margin-bottom: 12px;

    color: rgba(255, 255, 255, .35);

    font-size: 10px;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.channel-title {
    margin-bottom: 6px;

    color: #fff;

    font-size: 24px;
    font-weight: 300;

    line-height: 1.3;
}

.channel-username {
    margin-bottom: 12px;

    color: rgba(255,255,255,.45);

    font-size: 13px;

    letter-spacing: 1px;
}

.channel-card p {
    min-height: 70px;

    color: rgba(255,255,255,.5);

    font-size: 14px;
    line-height: 1.55;

    overflow: hidden;
    display: -webkit-box;

    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;

    line-clamp: 3;

    text-overflow: ellipsis;
}

.stats {
    display: flex;
    gap: 16px;

    margin-top: auto;
    padding-top: 18px;

    color: rgba(255, 255, 255, .55);

    font-size: 13px;
}

.actions {
    display: flex;
    gap: 10px;
}

.actions a {
    flex: 1;

    padding: 11px;

    border: 1px solid rgba(255, 255, 255, .18);

    color: #fff;
    text-align: center;
    text-decoration: none;

    font-size: 12px;
    letter-spacing: 1px;
    text-transform: uppercase;

    transition:
        color .2s ease,
        background .2s ease;
}

.actions a:first-child {
    background: #fff;
    color: #000;
}

.empty-state {
    display: none;

    margin-top: 24px;
    padding: 30px;

    background: rgba(0, 0, 0, .6);
    border: 1px solid rgba(255, 255, 255, .12);

    color: rgba(255, 255, 255, .5);
    text-align: center;
}


/* =========================================================
   09. PAGINATION / LOAD MORE
   ========================================================= */

.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 16px;

    margin-top: 40px;
    margin-bottom: 40px;
}

.page-btn {
    padding: 12px 20px;

    border: 1px solid rgba(255,255,255,.15);

    color: #fff;
    text-decoration: none;

    background: rgba(255,255,255,.03);
}

.page-btn:hover {
    background: rgba(255,255,255,.08);
}

.page-btn.disabled {
    opacity: .3;
    pointer-events: none;
}

.page-current {
    color: rgba(255,255,255,.7);
}

.page-btn,
.page-current {
    padding: 12px 18px;

    background: rgba(0, 0, 0, .55);
    border: 1px solid rgba(255, 255, 255, .15);

    color: #fff;
    text-decoration: none;

    font-size: 13px;
    letter-spacing: 1px;
}

.page-btn:hover {
    background: #fff;
    color: #000;
}

.page-btn.disabled {
    opacity: .35;
    pointer-events: none;
}

.page-current {
    color: rgba(255, 255, 255, .65);
}

.load-more-btn {
    display: block;

    margin: 40px auto 20px;
    padding: 14px 24px;

    background: #fff;
    border: 0;

    color: #000;

    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;

    cursor: pointer;

    transition: opacity .2s ease;
}

.load-more-btn:hover {
    opacity: .85;
}


/* =========================================================
   10. DETAIL PAGES
   ========================================================= */

.channel-page {
    position: relative;
    z-index: 5;

    width: 900px;
    max-width: 90%;
    min-height: 100vh;
    margin: 0 auto;
    padding: 80px 0;

    display: flex;
    flex-direction: column;
    justify-content: center;
}

.back-link {
    display: inline-block;
    width: fit-content;

    margin-bottom: 24px;

    color: rgba(255, 255, 255, .6);
    text-decoration: none;

    font-size: 13px;
    letter-spacing: 1px;
    text-transform: uppercase;

    transition: color .2s ease;
}

.back-link:hover {
    color: #fff;
}

.channel-detail {
    padding: 55px;

    background: rgba(0, 0, 0, .62);
    border: 1px solid rgba(255, 255, 255, .14);
    backdrop-filter: blur(14px);
}

.detail-avatar {
    width: 86px;
    height: 86px;
    margin-bottom: 24px;

    display: grid;
    place-items: center;

    border: 1px solid rgba(255, 255, 255, .35);

    font-size: 36px;
    font-weight: 700;
}

.detail-category {
    margin-bottom: 16px;

    color: rgba(255, 255, 255, .42);

    font-size: 11px;
    letter-spacing: 3px;
    text-transform: uppercase;
}

.channel-detail h1 {
    margin-bottom: 20px;

    font-size: 56px;
    font-weight: 300;
}

.channel-detail p {
    max-width: 650px;
    margin-bottom: 40px;

    color: rgba(255, 255, 255, .6);

    font-size: 17px;
    line-height: 1.7;
}

.detail-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;

    margin: 36px 0;
}

.detail-stats div {
    padding: 20px;

    background: rgba(255, 255, 255, .03);
    border: 1px solid rgba(255, 255, 255, .12);
}

.detail-stats strong {
    display: block;

    margin-bottom: 8px;

    font-size: 24px;
    font-weight: 400;
}

.detail-stats span {
    color: rgba(255, 255, 255, .45);

    font-size: 12px;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.detail-actions {
    display: flex;
    gap: 14px;
}

.detail-btn {
    padding: 14px 20px;

    border: 1px solid rgba(255, 255, 255, .18);

    color: #fff;
    text-decoration: none;

    font-size: 13px;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.detail-btn.primary {
    background: #fff;
    color: #111;
    border: 1px solid #fff;
}

.detail-btn.primary:hover {
    transform: translateY(-2px);
}

.detail-btn.secondary {
    color: #fff;
}


/* =========================================================
   11. FORMS
   ========================================================= */

.add-form {
    margin-top: 34px;

    display: flex;
    flex-direction: column;
    gap: 18px;
}

.add-form label {
    display: flex;
    flex-direction: column;
    gap: 8px;

    color: rgba(255, 255, 255, .55);

    font-size: 12px;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.add-form input,
.add-form textarea {
    width: 100%;
    padding: 15px 16px;

    background: rgba(255, 255, 255, .04);
    border: 1px solid rgba(255, 255, 255, .14);
    outline: 0;

    color: #fff;

    font-size: 15px;
}

.add-form textarea {
    min-height: 130px;
    resize: vertical;
}

.add-form input:focus,
.add-form textarea:focus {
    background: rgba(255, 255, 255, .06);
    border-color: rgba(255, 255, 255, .45);
}

.form-message {
    margin-top: 24px;
    padding: 14px 16px;

    border: 1px solid rgba(255, 255, 255, .14);

    font-size: 14px;
}

.form-message.success {
    background: rgba(34, 197, 94, .08);
    color: #86efac;
}

.form-message.error {
    background: rgba(239, 68, 68, .08);
    color: #fca5a5;
}


/* =========================================================
   12. ADMIN PANEL
   ========================================================= */

.admin-page {
    width: 1200px;
}

.submission-stats {
    margin: 28px 0 24px;

    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
}

.submission-stats div {
    padding: 18px;

    background: rgba(255, 255, 255, .025);
    border: 1px solid rgba(255, 255, 255, .1);
}

.submission-stats span {
    display: block;
    margin-bottom: 8px;

    color: rgba(255, 255, 255, .45);

    font-size: 11px;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.submission-stats strong {
    color: #fff;
    font-size: 28px;
    font-weight: 400;
}

.admin-filters {
    margin-top: 28px;

    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.admin-filters a {
    padding: 11px 16px;

    display: inline-flex;
    align-items: center;
    gap: 8px;

    background: rgba(255, 255, 255, .03);
    border: 1px solid rgba(255, 255, 255, .14);

    color: rgba(255, 255, 255, .65);
    text-decoration: none;

    font-size: 12px;
    letter-spacing: 1px;
    text-transform: uppercase;

    transition:
        color .2s ease,
        background .2s ease;
}

.admin-filters a:hover,
.admin-filters a.active {
    background: #fff;
    color: #000;
}

.admin-filters span {
    opacity: .65;
}

.submissions-list {
    margin-top: 34px;

    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
}

.admin-submission-card {
    padding: 22px;

    display: grid;
    gap: 16px;

    background: rgba(255, 255, 255, .03);
    border: 1px solid rgba(255, 255, 255, .12);

    transition:
        border-color .25s ease,
        background .25s ease;
}

.admin-submission-card:hover {
    background: rgba(255, 255, 255, .045);
    border-color: rgba(255, 255, 255, .22);
}

.submission-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.submission-id {
    color: rgba(255, 255, 255, .45);

    font-size: 12px;
    letter-spacing: 2px;
}

.submission-status {
    margin-left: 10px;
    padding: 4px 8px;

    border: 1px solid rgba(255, 255, 255, .12);

    font-size: 10px;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.submission-status.pending {
    color: #facc15;
}

.submission-status.approved {
    color: #86efac;
}

.submission-status.rejected {
    color: #fca5a5;
}

.submission-meta,
.submission-owner,
.submission-channel-state {
    color: rgba(255, 255, 255, .38);

    font-size: 12px;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.submission-owner span {
    margin-left: 8px;
    color: rgba(255, 255, 255, .28);
}

.submission-channel-state {
    width: fit-content;
    padding: 8px 10px;

    background: rgba(255, 255, 255, .025);
    border: 1px solid rgba(255, 255, 255, .08);
}

.submission-fields-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.admin-submission-card label {
    display: flex;
    flex-direction: column;
    gap: 8px;

    color: rgba(255, 255, 255, .55);

    font-size: 11px;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.admin-submission-card input,
.admin-submission-card textarea,
.admin-submission-card select {
    width: 100%;
    padding: 13px 14px;

    background: rgba(0, 0, 0, .5);
    border: 1px solid rgba(255, 255, 255, .14);
    outline: 0;

    color: #fff;
}

.admin-submission-card input[readonly] {
    color: rgba(255, 255, 255, .45);
}

.admin-submission-card textarea {
    min-height: 90px;
    resize: vertical;
}

.submission-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.submission-actions button {
    padding: 12px 16px;

    background: #fff;
    border: 0;

    color: #000;

    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;

    cursor: pointer;

    transition: opacity .2s ease;
}

.submission-actions button:hover {
    opacity: .85;
}

.submission-actions .secondary {
    background: rgba(255, 255, 255, .08);
    border: 1px solid rgba(255, 255, 255, .18);

    color: #fff;
}

.submission-actions .danger {
    background: rgba(239, 68, 68, .15);
    border: 1px solid rgba(239, 68, 68, .35);

    color: #fca5a5;
}

.admin-open-btn {
    padding: 12px 16px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    background: rgba(34, 197, 94, .15);
    border: 1px solid rgba(34, 197, 94, .35);

    color: #86efac;
    text-decoration: none;

    font-size: 13px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;

    transition: background .2s ease;
}

.admin-open-btn:hover {
    background: rgba(34, 197, 94, .25);
}

.admin-empty-state {
    display: block;
}


/* =========================================================
   13. PROFILE
   ========================================================= */

.profile-name {
    display: block;
}

.profile-name .admin-badge {
    margin-left: 16px;
    vertical-align: middle;
}

.admin-badge {
    display: inline-block;

    padding: 6px 12px;

    border: 1px solid #22c55e;
    box-shadow: 0 0 12px rgba(34, 197, 94, .25);

    color: #22c55e;

    font-size: 12px;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.profile-email {
    margin: 20px 0 40px;

    color: rgba(255, 255, 255, .65);
}

.profile-actions {
    display: flex;
    gap: 14px;

    margin-top: 10px;
}

.profile-action {
    position: relative;

    min-width: 180px;
    padding: 15px 18px;

    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;

    overflow: hidden;

    background: rgba(255, 255, 255, .035);
    border: 1px solid rgba(255, 255, 255, .16);

    color: #fff;
    text-decoration: none;

    font-size: 13px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;

    transition:
        transform .25s ease,
        border-color .25s ease,
        background .25s ease,
        color .25s ease;
}

.profile-action::before {
    content: "";

    position: absolute;
    inset: 0;

    background: linear-gradient(
        120deg,
        transparent,
        rgba(255, 255, 255, .18),
        transparent
    );

    transform: translateX(-120%);
    transition: transform .55s ease;
}

.profile-action:hover::before {
    transform: translateX(120%);
}

.profile-action:hover {
    background: rgba(255, 255, 255, .08);
    border-color: rgba(255, 255, 255, .45);

    transform: translateY(-3px);
}

.profile-action span,
.profile-action em {
    position: relative;
    z-index: 2;
}

.profile-action em {
    opacity: .55;

    font-style: normal;

    transition:
        opacity .25s ease,
        transform .25s ease;
}

.profile-action:hover em {
    opacity: 1;
    transform: translateX(4px);
}

.admin-action {
    border-color: rgba(34, 197, 94, .35);
    box-shadow: 0 0 18px rgba(34, 197, 94, .08);

    color: #86efac;
}

.admin-action:hover {
    background: rgba(34, 197, 94, .12);
    border-color: #22c55e;
}

.logout-action {
    border-color: rgba(239, 68, 68, .28);
    color: #fca5a5;
}

.logout-action:hover {
    background: rgba(239, 68, 68, .12);
    border-color: rgba(239, 68, 68, .65);
}


/* =========================================================
   14. RESPONSIVE
   ========================================================= */



/* =========================
   PROFILE PAGE
========================= */

.profile-page {
    position: relative;
    z-index: 5;

    width: 1180px;
    max-width: 92%;

    margin: 0 auto;
    padding: 70px 0;
}

.profile-hero {
    overflow: hidden;

    border: 1px solid rgba(255,255,255,.14);
    background: rgba(0,0,0,.62);
    backdrop-filter: blur(14px);
}

.profile-cover {
    height: 170px;

    background:
        radial-gradient(circle at 20% 50%, rgba(34,197,94,.18), transparent 35%),
        radial-gradient(circle at 80% 30%, rgba(255,255,255,.08), transparent 35%),
        linear-gradient(135deg, rgba(255,255,255,.08), rgba(255,255,255,.015));
    border-bottom: 1px solid rgba(255,255,255,.12);
}

.profile-main {
    position: relative;

    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 26px;

    padding: 0 42px 34px;
}

.profile-avatar {
    width: 118px;
    height: 118px;

    display: grid;
    place-items: center;

    margin-top: -58px;

    border: 2px solid rgba(255,255,255,.8);
    background: #050505;

    font-size: 48px;
    font-weight: 700;

    box-shadow:
        0 0 0 8px rgba(0,0,0,.65),
        0 0 35px rgba(255,255,255,.08);
}

.profile-info h1 {
    display: flex;
    align-items: center;
    gap: 16px;

    margin-bottom: 12px;

    font-size: 42px;
    font-weight: 300;
    letter-spacing: -1px;
}

.profile-meta {
    display: flex;
    gap: 18px;
    flex-wrap: wrap;

    color: rgba(255,255,255,.5);

    font-size: 13px;
    letter-spacing: 1px;
}

.profile-buttons {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.profile-tabs {
    display: flex;
    gap: 24px;

    margin: 34px 0 28px;

    border-bottom: 1px solid rgba(255,255,255,.12);
}

.profile-tab {
    position: relative;

    padding: 0 0 16px;

    background: transparent;
    border: none;

    color: rgba(255,255,255,.55);

    font-size: 14px;
    font-weight: 700;
    letter-spacing: 1px;

    cursor: pointer;
}

.profile-tab.active {
    color: white;
}

.profile-tab.active::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: -1px;

    height: 2px;

    background: white;
    box-shadow: 0 0 12px rgba(255,255,255,.65);
}

.profile-section {
    margin-top: 34px;
}

.admin-tools-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
}

.admin-tool-card {
    min-height: 130px;

    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 10px;

    padding: 24px;

    border: 1px solid rgba(34,197,94,.24);
    background: rgba(34,197,94,.045);

    color: white;
    text-decoration: none;

    transition:
        transform .25s ease,
        border-color .25s ease,
        background .25s ease;
}

.admin-tool-card strong {
    color: #86efac;

    font-size: 20px;
    font-weight: 500;
}

.admin-tool-card span {
    color: rgba(255,255,255,.5);

    font-size: 14px;
    line-height: 1.5;
}

.admin-tool-card:hover {
    transform: translateY(-4px);
    border-color: #22c55e;
    background: rgba(34,197,94,.09);
}

.profile-empty-box {
    padding: 36px;

    border: 1px dashed rgba(255,255,255,.18);
    background: rgba(255,255,255,.025);

    display: flex;
    flex-direction: column;
    gap: 8px;

    color: rgba(255,255,255,.55);
}

.profile-empty-box strong {
    color: white;
    font-size: 20px;
    font-weight: 400;
}


.submissions-list {
    transition: opacity .2s ease, transform .2s ease;
}

.submissions-list.loading {
    opacity: .25;
    transform: translateY(6px);
}

.add-form select {
    width: 100%;
    padding: 15px 16px;

    background: rgba(255,255,255,.04);
    border: 1px solid rgba(255,255,255,.14);

    color: white;

    font-size: 15px;
    outline: none;
}

.add-form select:focus {
    border-color: rgba(255,255,255,.45);
    background: rgba(255,255,255,.06);
}

/* =========================
   PAGE NAVIGATION
========================= */

.page-nav {
    display: flex;
    align-items: center;
    gap: 22px;

    margin-bottom: 28px;
}

.page-nav-link {
    color: rgba(255,255,255,.58);
    text-decoration: none;

    font-size: 13px;
    letter-spacing: 1px;
    text-transform: uppercase;

    transition: .25s ease;
}

.page-nav-link:hover {
    color: white;
    transform: translateX(-3px);
}

.page-nav-home {
    color: white;
    font-weight: 700;
    letter-spacing: 3px;
}

.page-nav-home:hover {
    opacity: .75;
    transform: none;
}

/* =========================
   AVATAR UPLOAD
========================= */

.profile-avatar {
    overflow: hidden;
}

.profile-avatar-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.avatar-upload-form {
    margin-top: 18px;
}

.avatar-upload-label {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    padding: 10px 14px;

    border: 1px solid rgba(255,255,255,.14);
    background: rgba(255,255,255,.035);

    color: rgba(255,255,255,.75);

    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;

    cursor: pointer;
    transition: .25s ease;
}

.avatar-upload-label:hover {
    color: white;
    border-color: rgba(255,255,255,.35);
    background: rgba(255,255,255,.07);
}

.avatar-upload-label input {
    display: none;
}

/* =========================
   AVATAR CROPPER
========================= */

.avatar-save-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    padding: 10px 14px;

    border: 1px solid rgba(34,197,94,.35);
    background: rgba(34,197,94,.12);

    color: #86efac;

    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;

    cursor: pointer;
    transition: .25s ease;
}

.avatar-save-btn:hover {
    border-color: #22c55e;
    background: rgba(34,197,94,.18);
}

.avatar-cropper-box {
    width: 400px;
    height: 400px;

    overflow: hidden;

    margin-top: 20px;

    border: 1px solid rgba(255,255,255,.15);
    background: #050505;
}

.avatar-cropper-box img {
    display: block;
    max-width: 100%;
}


.cropper-view-box,
.cropper-face {
    border-radius: 50%;
}

.avatar-cancel-btn,
.avatar-delete-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    padding: 10px 14px;

    margin-left: 10px;

    border: 1px solid rgba(239,68,68,.25);
    background: rgba(239,68,68,.08);

    color: #fca5a5;

    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;

    cursor: pointer;
    transition: .25s ease;
}

.avatar-cancel-btn:hover,
.avatar-delete-btn:hover {
    border-color: #ef4444;
    background: rgba(239,68,68,.15);
}

/* =========================
   AVATAR ACTIONS LAYOUT
========================= */

.avatar-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;

    margin-top: 18px;
}

.avatar-upload-form {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;

    margin: 0;
}

.avatar-delete-form {
    margin: 0;
}

.avatar-upload-label,
.avatar-save-btn,
.avatar-cancel-btn,
.avatar-delete-btn {
    min-height: 38px;
}

/* =========================
   TOP PROFILE BUTTON
========================= */

.top-profile-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;

    height: 44px;
    padding: 0 14px;

    border: 1px solid rgba(255,255,255,.15);

    color: white;
    text-decoration: none;

    font-size: 14px;
    font-weight: 700;

    transition: .25s ease;
}

.top-profile-btn:hover {
    background: white;
    color: black;
}

.top-profile-avatar {
    width: 26px;
    height: 26px;

    border-radius: 50%;
    object-fit: cover;

    border: 1px solid rgba(255,255,255,.35);
}

.top-profile-avatar.placeholder {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    background: rgba(255,255,255,.08);

    font-size: 12px;
}

.brand {
    color: inherit;
    text-decoration: none;
}

.brand:hover {
    color: inherit;
    text-decoration: none;
}

.category-btn {
    text-decoration: none;
}

.category-btn em {
    text-decoration: none;
}

select option {
    background: #0b0b0b;
    color: #ffffff;
}

.channel-card {
    cursor: pointer;
    transition: transform .2s ease, border-color .2s ease;
}

.channel-card:hover {
    transform: translateY(-4px);
}

.detail-btn.danger {
    background: #b3261e;
    border-color: #b3261e;
}

.detail-btn.danger:hover {
    opacity: .9;
}

.auth-links {
    margin-top: 24px;
}

.auth-links p {
    margin: 10px 0;
}

.auth-link {
    color: #158550;
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: .2s ease;
}

.auth-link:hover {
    color: #00ff88;
    border-bottom-color: #00ff88;
}

.admin-search-form {
    display: flex;
    gap: 12px;
    margin-bottom: 20px;
}

.admin-search-form input {
    flex: 1;
}

.admin-search-form button {
    padding: 12px 18px;
    cursor: pointer;
}

.pagination {
    display: flex;
    gap: 8px;
    justify-content: center;
    margin-top: 30px;
}

.pagination a {
    padding: 10px 14px;
    border: 1px solid #333;
    text-decoration: none;
    color: #fff;
}

.pagination a.active {
    background: #fff;
    color: #000;
}

/* ===== VIP BUTTON ===== */

.vip-action {
    min-width: 180px;

    border: 1px solid rgba(245, 197, 66, .35);

    background: rgba(245, 197, 66, .05);

    transition: .25s ease;
}

.vip-action em {
    color: #f5c542;
}

.vip-action:hover {
    border-color: rgba(245, 197, 66, .7);

    background: rgba(245, 197, 66, .12);

    box-shadow: 0 0 25px rgba(245, 197, 66, .15);
}

.vip-remove {
    border: 1px solid rgba(255, 90, 90, .35);

    background: rgba(255, 90, 90, .05);
}

.vip-remove em {
    color: #ff6b6b;
}

.vip-remove:hover {
    border-color: rgba(255, 90, 90, .7);

    background: rgba(255, 90, 90, .12);

    box-shadow: 0 0 25px rgba(255, 90, 90, .15);
}

.vip-expire-note {
    margin-top: 14px;
    padding: 10px 12px;

    border: 1px solid rgba(245, 197, 66, .28);
    background: rgba(245, 197, 66, .06);

    color: #f5c542;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.vip-duration-form {
    display: flex;
    align-items: stretch;
    gap: 10px;
    flex-wrap: wrap;
}

.vip-duration-form label {
    width: 92px;
    min-height: 56px;
    padding: 7px 10px;

    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 4px;

    border: 1px solid rgba(245, 197, 66, .28);
    background: rgba(245, 197, 66, .045);
}

.vip-duration-form label span {
    color: rgba(255,255,255,.5);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.vip-duration-form input {
    width: 100%;
    padding: 0;

    background: transparent;
    border: 0;
    outline: 0;

    color: #f5c542;
    font-size: 17px;
    font-weight: 700;
}

.admin-channel-card {
    gap: 16px;
}

.admin-channel-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
}

.admin-channel-title {
    min-width: 0;
}

.admin-channel-title .channel-title {
    margin-bottom: 6px;
}

.admin-channel-actions {
    display: flex;
    align-items: stretch;
    justify-content: flex-end;
    gap: 10px;
    flex: 0 0 auto;
}

.admin-channel-actions form {
    display: inline-flex;
    margin: 0;
}

.admin-channel-actions .detail-btn {
    min-width: 150px;
    height: 48px;
    padding: 0 14px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    font-size: 12px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    cursor: pointer;
}

.admin-channel-actions .vip-duration-form {
    flex-wrap: nowrap;
}

.admin-channel-actions .vip-duration-form label {
    min-height: 48px;
}

.channel-admin-toolbar {
    display: flex;
    align-items: stretch;
    justify-content: flex-end;
    gap: 10px;
    flex-wrap: wrap;

    margin-bottom: 28px;
    padding-bottom: 22px;

    border-bottom: 1px solid rgba(255,255,255,.08);
}

.channel-admin-toolbar form {
    display: inline-flex;
    margin: 0;
}

.channel-admin-toolbar .detail-action-btn {
    min-width: 172px;
    height: 48px;
    padding: 0 14px;
}

.channel-admin-toolbar .vip-duration-form {
    flex-wrap: nowrap;
}

.channel-admin-toolbar .vip-duration-form label {
    min-height: 48px;
}

/* ===== CHANNEL ACTIONS ===== */

.detail-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 24px;
}

.detail-actions .detail-btn,
.detail-actions .profile-action,
.detail-actions form {
    margin: 0;
}

.detail-actions form {
    display: inline-flex;
}

.detail-actions .detail-btn,
.detail-actions .profile-action {
    min-width: 180px;
    height: 56px;

    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;

    font-size: 13px;
    font-weight: 600;
    letter-spacing: .08em;
    text-transform: uppercase;

    transition: .25s ease;
}

.edit-action {
    border: 1px solid rgba(255,255,255,.15);
    background: rgba(255,255,255,.03);
}

.edit-action:hover {
    border-color: rgba(255,255,255,.4);
}

.delete-action {
    border: 1px solid rgba(255,70,70,.3);
    color: #ff6b6b;
}

.delete-action:hover {
    background: rgba(255,70,70,.08);
    border-color: rgba(255,70,70,.7);
}

.detail-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 28px;
}

.detail-actions form {
    margin: 0;
}

.detail-action-btn {
    min-width: 190px;
    height: 56px;
    padding: 0 18px;

    display: inline-flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;

    background: rgba(255, 255, 255, .035);
    border: 1px solid rgba(255, 255, 255, .16);

    color: #fff;
    text-decoration: none;

    font-size: 13px;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;

    cursor: pointer;
    transition: .25s ease;
}

.detail-action-btn:hover {
    transform: translateY(-3px);
    background: rgba(255, 255, 255, .08);
    border-color: rgba(255, 255, 255, .45);
}

.detail-action-btn em {
    font-style: normal;
    opacity: .65;
}

.detail-action-btn.telegram {
    background: #fff;
    border-color: #fff;
    color: #111;
}

.detail-action-btn.vip-add {
    border-color: rgba(245, 197, 66, .45);
    color: #f5c542;
}

.detail-action-btn.vip-add:hover {
    background: rgba(245, 197, 66, .12);
    box-shadow: 0 0 24px rgba(245, 197, 66, .16);
}

.detail-action-btn.vip-remove,
.detail-action-btn.delete {
    border-color: rgba(239, 68, 68, .35);
    color: #fca5a5;
}

.detail-action-btn.vip-remove:hover,
.detail-action-btn.delete:hover {
    background: rgba(239, 68, 68, .12);
    border-color: rgba(239, 68, 68, .65);
}

.detail-action-btn.edit {
    border-color: rgba(34, 197, 94, .35);
    color: #86efac;
}

.detail-action-btn.edit:hover {
    background: rgba(34, 197, 94, .12);
    border-color: #22c55e;
}

.search-results-info {
    max-width: 700px;

    margin: 12px auto 0;

    font-size: 14px;
    font-weight: 700;

    text-align: left;

    background: linear-gradient(
        90deg,
        #4dffb8 0%,
        #00e5ff 50%,
        #8a7dff 100%
    );

    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;

    opacity: 0;

    transition:
        opacity .25s ease,
        transform .25s ease;

    transform: translateY(-3px);
    text-shadow:
    0 0 8px rgba(77,255,184,.25),
    0 0 16px rgba(0,229,255,.15);
}

.search-results-info.visible {
    opacity: 1;
    transform: translateY(0);
}

.channel-avatar {
    width: 48px;
    height: 48px;

    display: flex;
    align-items: center;
    justify-content: center;

    overflow: hidden;

    border-radius: 12px;

    border: 1px solid rgba(255,255,255,.12);

    background:
        linear-gradient(
            135deg,
            rgba(255,255,255,.04),
            rgba(255,255,255,.01)
        );

    flex-shrink: 0;

    transition:
        transform .25s ease,
        border-color .25s ease,
        box-shadow .25s ease;
}

.channel-card:hover .channel-avatar {
    border-color: rgba(255,255,255,.45);

    box-shadow:
        0 0 18px rgba(255,255,255,.08);

    transform: scale(1.05);
}

.channel-detail-avatar {
    width: 120px;
    height: 120px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 28px;
    overflow: hidden;
}

.channel-avatar img,
.channel-detail-avatar img {
    width: 100%;
    height: 100%;

    display: block;

    object-fit: cover;
}

.channel-avatar-placeholder {
    font-size: 22px;
    line-height: 1;

    color: rgb(255, 255, 255);

    display: flex;
    align-items: center;
    justify-content: center;
}

.channel-avatar img {
    width: 100%;
    height: 100%;

    object-fit: cover;
    display: block;
}

.channel-avatar-placeholder {
    width: 100%;
    height: 100%;

    display: flex;
    align-items: center;
    justify-content: center;
}

.channel-avatar-placeholder[hidden] {
    display: none;
}

.channel-avatar-diamond {
    width: 34px;
    height: 34px;

    display: flex;
    align-items: center;
    justify-content: center;

    font-size: 52px;


}

.detail-btn.secondary {
    background: rgba(255,255,255,.05);

    border: 1px solid rgba(255,255,255,.12);

    color: #fff;
}

.detail-btn.secondary:hover {
    border-color: rgba(255,255,255,.3);

    transform: translateY(-2px);
}

.avatar-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;

    margin-bottom: 30px;
}

.stat-card {
    padding: 24px;

    border: 1px solid rgba(255,255,255,.08);

    background: rgba(255,255,255,.02);
}

.stat-card span {
    display: block;

    color: #888;

    margin-bottom: 8px;
}

.stat-card strong {
    font-size: 28px;
}

.stat-card.success strong {
    color: #3ddc84;
}

.stat-card.warning strong {
    color: #ffb400;
}


.admin-btn {
    padding: 14px 22px;

    border: 1px solid rgba(255,255,255,.15);

    color: #fff;

    text-decoration: none;

    transition: .2s;
}

.admin-btn:hover {
    transform: translateY(-2px);
}

.admin-btn.gold {
    border-color: #ffb400;

    color: #ffb400;
}


.avatar-actions {
    display: flex;
    gap: 12px;
    margin-top: 24px;
    flex-wrap: wrap;
}

.profile-info {
    display: flex;
    flex-direction: column;
}

.avatar-cropper-box {
    align-self: flex-start;
}

.avatar-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;

    padding: 14px 22px;

    background: rgba(255,255,255,0.02);
    border: 1px solid rgba(255,255,255,0.12);

    color: #fff;
    text-decoration: none;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: .08em;
    text-transform: uppercase;

    cursor: pointer;
    transition: .25s ease;
}

.avatar-btn:hover {
    transform: translateY(-2px);
}

.avatar-btn.download {
    border-color: rgba(0,255,170,.25);
    color: #00ffaa;
    background: rgba(0,255,170,.05);
}

.avatar-btn.download:hover {
    background: rgba(0,255,170,.12);
    box-shadow: 0 0 25px rgba(0,255,170,.15);
}

.avatar-btn.update {
    border-color: rgba(255,196,0,.25);
    color: #ffc400;
    background: rgba(255,196,0,.05);
}

.avatar-btn.update:hover {
    background: rgba(255,196,0,.12);
    box-shadow: 0 0 25px rgba(255,196,0,.15);
}

.avatar-log {
    margin-top: 25px;
    padding: 20px;

    border: 1px solid rgba(255,255,255,.08);
    background: rgba(255,255,255,.02);

    max-height: 500px;
    overflow-y: auto;
}

.avatar-log-title {
    color: #ffc400;
    font-size: 14px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .08em;
    margin-bottom: 15px;
}

.avatar-log-line {
    color: #d0d0d0;
    font-size: 13px;
    line-height: 1.7;
    font-family: monospace;
    border-bottom: 1px solid rgba(255,255,255,.05);
    padding: 4px 0;
}

.avatar-progress{
    margin-top:20px;
    margin-bottom:20px;
}

.avatar-progress-bar{
    width:100%;
    height:10px;
    background:rgba(255,255,255,.05);
    border:1px solid rgba(255,255,255,.08);
    overflow:hidden;
}

#avatarProgressFill{
    width:0%;
    height:100%;
    background:linear-gradient(
        90deg,
        #00ff88,
        #00ccff
    );
    transition:.3s;
}

#avatarProgressText{
    margin-top:10px;
    color:#888;
    font-size:13px;
}

.avatar-log{
    margin-top:20px;
    background:#050505;
    border:1px solid rgba(255,255,255,.08);
    padding:20px;
    max-height:500px;
    overflow-y:auto;
}

.avatar-log-title{
    color:#ffcc00;
    font-weight:700;
    margin-bottom:15px;
    text-transform:uppercase;
}

.avatar-log-line{
    padding:8px 0;
    border-bottom:1px solid rgba(255,255,255,.05);
    color:#ddd;
    font-size:13px;
}

.avatar-settings{
    display:flex;
    align-items:center;
    gap:12px;
    margin-bottom:15px;
}

.avatar-settings label{
    color:#aaa;
    font-size:13px;
}

.avatar-select{
    background:#090909;
    border:1px solid rgba(255,255,255,.1);
    color:#fff;
    padding:10px 14px;
    min-width:120px;
}

/* ================================
   TELEGRAM MANAGER
================================ */

.tg-manager-page {
    width: min(1120px, 94vw);
    margin: 0 auto;
    padding: 48px 0 70px;
}

.tg-manager-hero,
.tg-control-panel,
.tg-log-panel {
    background:
        linear-gradient(
            135deg,
            rgba(0, 255, 136, .045),
            rgba(255, 255, 255, .015)
        ),
        rgba(0, 0, 0, .68);

    border: 1px solid rgba(255, 255, 255, .12);
    backdrop-filter: blur(14px);
}

.tg-manager-hero {
    min-height: 240px;
    padding: 46px;

    display: grid;
    grid-template-columns: minmax(0, 1fr) 220px;
    align-items: end;
    gap: 28px;
}

.tg-manager-hero h1 {
    max-width: 760px;
    margin: 0 0 18px;

    color: #fff;
    font-size: 52px;
    font-weight: 300;
    line-height: 1.05;
}

.tg-manager-hero p {
    max-width: 650px;
    margin: 0;

    color: rgba(255,255,255,.62);
    font-size: 16px;
    line-height: 1.7;
}

.tg-manager-status {
    padding: 22px;

    border: 1px solid rgba(0,255,136,.22);
    background: rgba(0,255,136,.04);
}

.tg-manager-status span {
    display: block;
    margin-bottom: 8px;

    color: rgba(255,255,255,.45);
    font-size: 11px;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.tg-manager-status strong {
    color: #00ff88;
    font-size: 30px;
    font-weight: 400;
}

.tg-stat-grid {
    margin-top: 18px;

    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 14px;
}

.tg-stat-card {
    position: relative;
    min-height: 126px;
    padding: 22px;

    overflow: hidden;

    background: rgba(255,255,255,.025);
    border: 1px solid rgba(255,255,255,.1);
}

.tg-stat-card::before {
    content: "";

    position: absolute;
    left: 0;
    top: 18px;
    bottom: 18px;

    width: 3px;
    background: rgba(255,255,255,.28);
}

.tg-stat-card span {
    display: block;
    margin-bottom: 18px;

    color: rgba(255,255,255,.48);
    font-size: 11px;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.tg-stat-card strong {
    color: #fff;
    font-size: 28px;
    font-weight: 400;
}

.tg-stat-card.green::before,
.tg-stat-card.mint::before {
    background: #00ff88;
    box-shadow: 0 0 18px rgba(0,255,136,.45);
}

.tg-stat-card.cyan::before {
    background: #00d4ff;
    box-shadow: 0 0 18px rgba(0,212,255,.35);
}

.tg-stat-card.gold::before {
    background: #ffcc00;
    box-shadow: 0 0 18px rgba(255,204,0,.35);
}

.tg-stat-card.red::before {
    background: #ff4d4d;
    box-shadow: 0 0 18px rgba(255,77,77,.35);
}

.tg-control-panel {
    margin-top: 18px;
    padding: 28px;
}

.tg-panel-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 24px;
    margin-bottom: 22px;
}

.tg-panel-head h2 {
    margin: 0;

    color: #fff;
    font-size: 26px;
    font-weight: 400;
}

.tg-progress-text {
    max-width: 420px;
    padding: 12px 14px;

    background: rgba(0,0,0,.48);
    border: 1px solid rgba(255,255,255,.1);

    color: rgba(255,255,255,.7);
    font-size: 13px;
    line-height: 1.5;
}

.tg-control-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(140px, 170px)) repeat(3, minmax(0, 1fr));
    gap: 12px;
    align-items: end;
}

.tg-control-field {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.tg-control-field span {
    color: rgba(255,255,255,.48);
    font-size: 11px;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.tg-action-btn {
    height: 48px;
    padding: 0 18px;

    border: 1px solid rgba(255,255,255,.14);
    background: rgba(255,255,255,.035);

    color: #fff;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;

    cursor: pointer;
    transition:
        transform .2s ease,
        border-color .2s ease,
        background .2s ease;
}

.tg-action-btn:hover {
    transform: translateY(-2px);
    background: rgba(255,255,255,.07);
    border-color: rgba(255,255,255,.32);
}

.tg-action-btn.primary {
    border-color: rgba(0,255,136,.35);
    color: #00ff88;
}

.tg-action-btn.gold {
    border-color: rgba(255,204,0,.35);
    color: #ffcc00;
}

.tg-action-btn.danger {
    border-color: rgba(255,77,77,.35);
    color: #ff8a8a;
}

.tg-progress-track {
    height: 12px;
    margin-top: 22px;

    overflow: hidden;

    background: rgba(255,255,255,.04);
    border: 1px solid rgba(255,255,255,.08);
}

.tg-progress-track div {
    width: 0%;
    height: 100%;

    background: linear-gradient(90deg, #00ff88, #00d4ff);
    box-shadow: 0 0 20px rgba(0,255,136,.3);
    transition: width .25s ease;
}

.tg-log-layout {
    margin-top: 18px;

    display: grid;
    grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr);
    gap: 18px;
}

.tg-log-panel {
    min-height: 320px;
    padding: 24px;
}

.tg-log-title {
    margin-bottom: 16px;

    color: #ffcc00;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.tg-log-body {
    max-height: 420px;
    overflow-y: auto;
    padding-right: 8px;
}

.tg-log-line,
.tg-history-item {
    padding: 11px 0;

    border-bottom: 1px solid rgba(255,255,255,.06);

    color: rgba(255,255,255,.72);
    font-size: 13px;
    line-height: 1.5;
}

.tg-history-item {
    display: grid;
    grid-template-columns: 170px minmax(0, 1fr);
    gap: 16px;
}

.tg-history-item strong {
    display: block;
    margin-bottom: 4px;

    color: #fff;
    font-size: 12px;
}

.tg-history-item span {
    color: rgba(255,255,255,.36);
    font-size: 11px;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.tg-history-item p {
    margin: 0;
    color: rgba(255,255,255,.68);
}

.tg-history-item.success p {
    color: rgba(134,239,172,.88);
}

.tg-history-item.error p {
    color: rgba(255,138,138,.9);
}

.admin-card {
    display: flex;
    flex-direction: column;
    gap: 12px;

    padding: 24px;

    background: rgba(0, 20, 10, 0.45);

    border: 1px solid rgba(0, 255, 150, 0.25);

    text-decoration: none;

    transition: 0.25s ease;

    min-height: 120px;
}

.admin-card:hover {
    border-color: #00ff88;

    box-shadow: 0 0 25px rgba(0, 255, 136, 0.2);

    transform: translateY(-3px);
}

.admin-card-icon {
    font-size: 26px;
}

.admin-card h3 {
    color: #00ff88;

    font-size: 28px;

    margin: 0;
}

.admin-card p {
    color: rgba(255,255,255,.65);

    margin: 0;

    line-height: 1.5;
}

/* =========================
   ADMIN ANALYTICS
========================= */

.admin-dashboard-page {
    width: min(1180px, 94vw);
}

.admin-dashboard {
    display: flex;
    flex-direction: column;
    gap: 28px;
}

.admin-dashboard > p {
    margin-bottom: 0;
}

.admin-analytics-section {
    display: grid;
    gap: 16px;
}

.admin-section-title {
    display: flex;
    align-items: center;
    gap: 10px;
}

.admin-section-title span {
    width: 28px;
    height: 28px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    border: 1px solid rgba(255,255,255,.14);
    background: rgba(255,255,255,.04);

    font-size: 18px;
}

.admin-section-title h2 {
    margin: 0;

    color: #fff;
    font-size: 22px;
    font-weight: 500;
}

.admin-section-title.purple span {
    color: #a78bfa;
    border-color: rgba(167,139,250,.35);
    background: rgba(167,139,250,.08);
}

.admin-section-title.gold span {
    color: #ffcc00;
    border-color: rgba(255,204,0,.35);
    background: rgba(255,204,0,.08);
}

.admin-section-title.mint span {
    color: #00ff88;
    border-color: rgba(0,255,136,.35);
    background: rgba(0,255,136,.08);
}

.admin-section-title.cyan span {
    color: #00d4ff;
    border-color: rgba(0,212,255,.35);
    background: rgba(0,212,255,.08);
}

.admin-metric-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
}

.admin-metric-card,
.admin-online-card,
.admin-period-card {
    background:
        radial-gradient(circle at top right, rgba(255,255,255,.055), transparent 42%),
        rgba(255,255,255,.035);
    border: 1px solid rgba(255,255,255,.12);
    backdrop-filter: blur(12px);
}

.admin-metric-card {
    position: relative;
    min-height: 128px;
    padding: 22px;
    overflow: hidden;
}

.admin-metric-card::before {
    content: "";
    position: absolute;
    left: 0;
    top: 20px;
    bottom: 20px;
    width: 3px;
    background: rgba(255,255,255,.3);
}

.admin-metric-card span,
.admin-online-card span,
.admin-period-card span {
    display: block;
    margin-bottom: 8px;

    color: rgba(255,255,255,.48);
    font-size: 11px;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.admin-metric-card strong,
.admin-online-card strong,
.admin-period-card strong {
    display: block;
    color: #fff;
    font-size: 30px;
    font-weight: 500;
    line-height: 1.1;
}

.admin-metric-card em,
.admin-online-card em {
    display: block;
    margin-top: 10px;

    color: rgba(255,255,255,.45);
    font-size: 13px;
    font-style: normal;
}

.admin-metric-card.purple::before {
    background: #a78bfa;
    box-shadow: 0 0 18px rgba(167,139,250,.38);
}

.admin-metric-card.blue::before {
    background: #60a5fa;
    box-shadow: 0 0 18px rgba(96,165,250,.36);
}

.admin-metric-card.cyan::before {
    background: #00d4ff;
    box-shadow: 0 0 18px rgba(0,212,255,.34);
}

.admin-metric-card.white::before {
    background: #fff;
    box-shadow: 0 0 18px rgba(255,255,255,.26);
}

.admin-online-card {
    max-width: 380px;
    padding: 24px;

    border-color: rgba(34,197,94,.22);
    background:
        radial-gradient(circle at top right, rgba(34,197,94,.12), transparent 42%),
        rgba(34,197,94,.045);
}

.admin-online-card strong {
    color: #86efac;
}

.admin-small-stats {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 28px;
}

.admin-period-card {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    overflow: hidden;
}

.admin-period-card div {
    min-height: 88px;
    padding: 18px;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    border-right: 1px solid rgba(255,255,255,.08);
    border-bottom: 1px solid rgba(255,255,255,.08);
    text-align: center;
}

.admin-period-card div:nth-child(2n) {
    border-right: 0;
}

.admin-period-card div:nth-last-child(-n + 2) {
    border-bottom: 0;
}

.admin-period-card strong {
    font-size: 22px;
}

/* =========================
   ADMIN CHANNELS PAGE
========================= */

.admin-channels-page {
    width: min(1440px, 94vw);
    margin: 0 auto;
}

.admin-channels-hero {
    min-height: 220px;
    padding: 36px;

    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(280px, 420px);
    align-items: end;
    gap: 32px;

    background:
        radial-gradient(circle at 18% 0%, rgba(34,197,94,.12), transparent 34%),
        radial-gradient(circle at 82% 18%, rgba(245,197,66,.1), transparent 32%),
        rgba(0,0,0,.66);
    border: 1px solid rgba(255,255,255,.12);
    backdrop-filter: blur(14px);
}

.admin-channels-hero h1 {
    margin: 0 0 16px;

    color: #fff;
    font-size: 54px;
    font-weight: 300;
    line-height: 1;
}

.admin-channels-hero p {
    max-width: 620px;
    margin: 0;

    color: rgba(255,255,255,.64);
    font-size: 16px;
    line-height: 1.7;
}

.admin-channels-summary {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
}

.admin-channels-summary div {
    min-height: 94px;
    padding: 16px;

    display: flex;
    flex-direction: column;
    justify-content: center;

    background: rgba(255,255,255,.035);
    border: 1px solid rgba(255,255,255,.1);
}

.admin-channels-summary span {
    margin-bottom: 8px;

    color: rgba(255,255,255,.44);
    font-size: 11px;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.admin-channels-summary strong {
    color: #fff;
    font-size: 28px;
    font-weight: 500;
}

.admin-channel-search {
    margin: 18px 0;
    padding: 16px;

    display: grid;
    grid-template-columns: minmax(0, 1fr) 132px;
    gap: 12px;

    background: rgba(0,0,0,.58);
    border: 1px solid rgba(255,255,255,.1);
    backdrop-filter: blur(12px);
}

.admin-channel-search input {
    width: 100%;
    min-width: 0;
    height: 48px;
    padding: 0 16px;

    background: rgba(255,255,255,.04);
    border: 1px solid rgba(255,255,255,.13);
    outline: 0;

    color: #fff;
}

.admin-channel-search input:focus {
    border-color: rgba(255,255,255,.4);
    background: rgba(255,255,255,.065);
}

.admin-channel-search button {
    height: 48px;

    border: 1px solid rgba(255,255,255,.18);
    background: #fff;

    color: #050505;
    font-weight: 800;
    letter-spacing: 1px;
    text-transform: uppercase;
    cursor: pointer;
}

.admin-channel-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(310px, 1fr));
    gap: 18px;
}

.admin-channel-card {
    position: relative;
    min-height: 360px;
    padding: 22px;

    display: flex;
    flex-direction: column;
    gap: 18px;
    overflow: hidden;

    background:
        linear-gradient(145deg, rgba(255,255,255,.035), rgba(255,255,255,.012)),
        rgba(0,0,0,.68);
    border: 1px solid rgba(255,255,255,.11);
    backdrop-filter: blur(12px);

    transition:
        transform .22s ease,
        border-color .22s ease,
        background .22s ease;
}

.admin-channel-card:hover {
    transform: translateY(-3px);
    border-color: rgba(255,255,255,.3);
    background:
        linear-gradient(145deg, rgba(255,255,255,.05), rgba(255,255,255,.018)),
        rgba(0,0,0,.72);
}

.admin-channel-card.vip-card {
    border-color: rgba(245,197,66,.5);
    box-shadow: 0 0 24px rgba(245,197,66,.08);
}

.admin-channel-card-top {
    display: grid;
    grid-template-columns: 54px minmax(0, 1fr) auto;
    align-items: center;
    gap: 14px;
}

.admin-channel-title {
    min-width: 0;
}

.admin-channel-title h3 {
    margin: 0 0 5px;

    color: #fff;
    font-size: 24px;
    font-weight: 500;
    line-height: 1.15;
    overflow-wrap: anywhere;
}

.admin-channel-title span {
    color: rgba(255,255,255,.45);
    font-size: 13px;
    overflow-wrap: anywhere;
}

.admin-channel-status {
    padding: 7px 9px;

    border: 1px solid rgba(245,197,66,.42);
    background: rgba(245,197,66,.08);

    color: #f5c542;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 1px;
}

.admin-channel-card p {
    min-height: 72px;
    margin: 0;

    color: rgba(255,255,255,.56);
    font-size: 14px;
    line-height: 1.55;

    overflow: hidden;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    line-clamp: 3;
}

.admin-channel-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: auto;
}

.admin-channel-meta span {
    padding: 8px 10px;

    background: rgba(255,255,255,.035);
    border: 1px solid rgba(255,255,255,.09);

    color: rgba(255,255,255,.6);
    font-size: 12px;
}

.admin-channel-card-actions {
    padding-top: 2px;

    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
}

.admin-channel-card-actions form {
    display: flex;
    gap: 10px;
    margin: 0;
}

.admin-card-action {
    min-height: 48px;
    padding: 0 14px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    border: 1px solid rgba(255,255,255,.16);
    background: rgba(255,255,255,.04);

    color: #fff;
    text-decoration: none;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 1px;
    text-transform: uppercase;
    cursor: pointer;
}

.admin-card-action.edit {
    background: #fff;
    border-color: #fff;
    color: #050505;
}

.admin-card-action.vip {
    flex: 1;
    border-color: rgba(245,197,66,.36);
    color: #f5c542;
}

.admin-card-action.remove {
    width: 100%;
    border-color: rgba(239,68,68,.32);
    color: #fca5a5;
}

.admin-channel-card-actions .vip-duration-form {
    flex-wrap: nowrap;
}

/* =========================
   ADMIN USERS PAGE
========================= */

.admin-users-page {
    width: min(1240px, 94vw);
    margin: 0 auto;
}

.admin-users-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 18px;
}

.admin-user-card {
    padding: 22px;

    display: flex;
    flex-direction: column;
    gap: 18px;

    background:
        linear-gradient(145deg, rgba(255,255,255,.035), rgba(255,255,255,.012)),
        rgba(0,0,0,.68);
    border: 1px solid rgba(255,255,255,.11);
    backdrop-filter: blur(12px);
}

.admin-user-top {
    display: grid;
    grid-template-columns: 52px minmax(0, 1fr) auto;
    align-items: center;
    gap: 14px;
}

.admin-user-avatar {
    width: 52px;
    height: 52px;

    display: flex;
    align-items: center;
    justify-content: center;

    overflow: hidden;

    border: 1px solid rgba(255,255,255,.18);
    background: rgba(255,255,255,.045);

    color: #fff;
    font-weight: 800;
}

.admin-user-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.admin-user-top h3 {
    margin: 0 0 4px;

    color: #fff;
    font-size: 21px;
    font-weight: 500;
    overflow-wrap: anywhere;
}

.admin-user-top span,
.admin-user-meta span {
    color: rgba(255,255,255,.45);
    font-size: 12px;
}

.admin-user-role {
    padding: 7px 10px;

    border: 1px solid rgba(255,255,255,.14);

    color: rgba(255,255,255,.68);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.admin-user-role.admin {
    border-color: rgba(34,197,94,.35);
    color: #86efac;
}

.admin-user-meta {
    display: grid;
    gap: 8px;
}

.admin-user-stats {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    border: 1px solid rgba(255,255,255,.08);
}

.admin-user-stats div {
    padding: 14px;
    text-align: center;
}

.admin-user-stats div + div {
    border-left: 1px solid rgba(255,255,255,.08);
}

.admin-user-stats span {
    display: block;
    margin-bottom: 6px;

    color: rgba(255,255,255,.42);
    font-size: 11px;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.admin-user-stats strong {
    color: #fff;
    font-size: 24px;
}

.admin-user-actions {
    margin: 0;
}

.admin-user-actions button {
    width: 100%;
    min-height: 46px;

    border: 1px solid rgba(255,255,255,.16);
    background: #fff;

    color: #050505;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 1px;
    text-transform: uppercase;
    cursor: pointer;
}

/* =========================
   MOBILE
========================= */

.mobile-menu-btn {
    display: none;
}

.sidebar-overlay {
    display: none;
}

@media (max-width: 900px) {

    html,
    body {
        overflow-x: hidden;
    }

    body.mobile-menu-open {
        overflow-x: hidden;
        overflow-y: auto;
    }

    body.mobile-menu-open .sidebar-overlay {
        display: block;
    }

    .sidebar-overlay {
        position: fixed;
        inset: 0;
        z-index: 9997;

        padding: 0;

        background: rgba(0, 0, 0, .68);
        border: 0;
        backdrop-filter: blur(5px);
        cursor: pointer;
    }

    .frame {
        inset: 0;
        border-left: 0;
        border-right: 0;
    }

    .mobile-menu-btn {
        display: flex;

        position: fixed;
        top: 14px;
        left: 14px;
        z-index: 9999;

        width: 48px;
        height: 48px;

        align-items: center;
        justify-content: center;

        background: transparent;
        border: 1px solid transparent;

        color: white;
        font-size: 21px;

        cursor: pointer;
        transition: color .2s ease, opacity .2s ease;
    }

    .mobile-menu-btn.active {
        background: transparent;
        border-color: transparent;
        color: #fff;
        opacity: .72;
    }

    .sidebar {
        position: fixed !important;

        left: -286px;
        top: 0;
        bottom: 0;

        width: min(286px, 86vw);
        max-width: 86vw;
        overflow-y: auto;

        z-index: 9998;

        transition: left .28s ease;
        box-shadow: 20px 0 60px rgba(0,0,0,.48);
    }

    .sidebar.mobile-open {
        left: 0;
    }

    .sidebar .brand {
        display: none;
    }

    .sidebar .side-block:first-of-type {
        margin-top: 72px;
    }

    .app {
        margin-left: 0 !important;
    }

    .topbar {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        z-index: 9990;
        min-height: 72px;
        height: auto;
        padding: 12px 16px 12px 76px;
        gap: 12px;
        justify-content: space-between;
        background: rgba(0,0,0,.86);
        box-shadow: 0 18px 34px rgba(0,0,0,.32);
    }

    .mobile-top-brand {
        display: inline-flex;
        margin-right: auto;
    }

    .topbar-title {
        display: none;
    }

    .topbar-actions {
        min-width: 0;
        margin-left: auto;
        display: flex;
        justify-content: flex-end;
        gap: 8px;
    }

    .top-add-btn,
    .top-profile-btn {
        min-height: 44px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        white-space: nowrap;
    }

    .top-add-btn {
        padding: 9px 12px;
        font-size: 13px;
    }

    .content {
        padding: 106px 20px 34px;
    }

    .hero,
    .channel-detail,
    .profile-hero,
    .admin-submission-card,
    .tg-manager-hero,
    .tg-control-panel,
    .tg-log-panel {
        backdrop-filter: blur(10px);
    }

    .hero {
        max-width: none;
        margin-bottom: 34px;
        padding: 34px 24px;
    }

    .hero h1 {
        font-size: 40px;
        line-height: 1.05;
        letter-spacing: 0;
    }

    .hero p {
        font-size: 15px;
    }

    .hero-search {
        max-width: 100%;
    }

    .channels-head {
        align-items: flex-start;
        flex-direction: column;
        gap: 16px;
    }

    .block-title {
        margin-bottom: 0;
    }

    .sort-tabs {
        width: 100%;
        overflow-x: auto;
        padding-bottom: 4px;
        scrollbar-width: thin;
    }

    .sort-btn {
        flex: 0 0 auto;
    }

    .recommended-grid {
        grid-template-columns: 1fr;
        gap: 14px;
    }

    .channels-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 14px;
    }

    .channel-card,
    .recommended-card,
    .admin-tool-card {
        min-width: 0;
    }

    .admin-tools-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .admin-metric-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .admin-small-stats {
        grid-template-columns: 1fr;
    }

    .admin-online-card {
        max-width: none;
    }

    .tg-manager-hero {
        grid-template-columns: 1fr;
        padding: 34px;
    }

    .admin-channels-page {
        width: 100%;
    }

    .admin-channels-hero {
        grid-template-columns: 1fr;
        padding: 30px;
    }

    .admin-channels-hero h1 {
        font-size: 42px;
        letter-spacing: 0;
    }

    .admin-channel-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .tg-stat-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .tg-control-grid,
    .tg-log-layout {
        grid-template-columns: 1fr;
    }

    .tg-action-btn {
        width: 100%;
    }

    .submission-stats {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .avatar-stats {
        grid-template-columns: 1fr;
    }

    .channel-page,
    .profile-page,
    .admin-page {
        width: 100%;
        max-width: none;
        padding: 34px 0;
    }

    .channel-page {
        min-height: auto;
        justify-content: flex-start;
    }

    .channel-detail {
        padding: 34px;
    }

    .channel-detail h1 {
        font-size: 40px;
        line-height: 1.12;
        word-break: break-word;
    }

    .detail-stats {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .profile-main {
        grid-template-columns: 1fr;
        padding: 0 28px 30px;
    }

    .profile-buttons {
        justify-content: flex-start;
    }

    .profile-info h1 {
        align-items: flex-start;
        flex-direction: column;
        gap: 10px;
        font-size: 34px;
        letter-spacing: 0;
    }

    .profile-actions,
    .profile-buttons {
        width: 100%;
    }

    .profile-action {
        flex: 1 1 220px;
        min-width: 0;
    }

    .admin-search-form {
        align-items: stretch;
        flex-direction: column;
    }

    .admin-channel-search {
        grid-template-columns: 1fr;
    }

    .admin-search-form button {
        min-height: 46px;
    }

    .admin-channel-head {
        flex-direction: column;
    }

    .admin-channel-actions {
        width: 100%;
        justify-content: flex-start;
        flex-wrap: wrap;
    }

    .channel-admin-toolbar {
        justify-content: flex-start;
    }

    .add-form input,
    .add-form textarea,
    .add-form select,
    .admin-submission-card input,
    .admin-submission-card textarea,
    .admin-submission-card select,
    .avatar-select {
        min-width: 0;
    }

    .topbar-actions {
        gap: 8px;
    }

    .top-profile-btn span {
        display: none;
    }
}

@media (max-width: 600px) {

    .topbar {
        padding: 12px 12px 12px 70px;
        gap: 8px;
    }

    .mobile-top-brand {
        gap: 8px;
        font-size: 12px;
        letter-spacing: 3px;
    }

    .mobile-top-brand-icon {
        width: 30px;
        height: 30px;
    }

    .topbar-actions {
        margin-left: auto;
    }

    .top-add-btn {
        max-width: 92px;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .topbar-actions .top-add-btn[href="/add-channel"],
    .topbar-actions .top-add-btn.admin-direct-add {
        min-width: 82px;
        padding-left: 10px;
        padding-right: 10px;
        font-size: 0;
    }

    .topbar-actions .top-add-btn[href="/add-channel"]::before,
    .topbar-actions .top-add-btn.admin-direct-add::before {
        content: "+ Канал";
        font-size: 12px;
        letter-spacing: .4px;
    }

    .content {
        padding: 96px 12px 24px;
    }

    .hero {
        padding: 28px 18px;
        text-align: left;
    }

    .hero::before {
        width: 360px;
        height: 360px;
    }

    .eyebrow {
        margin-bottom: 14px;
        font-size: 10px;
        letter-spacing: 2px;
    }

    .hero h1 {
        font-size: 34px;
    }

    .hero p {
        margin-left: 0;
        margin-right: 0;
    }

    .block-title h2 {
        font-size: 26px;
    }

    .hero-search {
        height: auto;
        padding: 13px 14px;
    }

    .channels-grid {
        grid-template-columns: 1fr;
    }

    .admin-channels-hero {
        padding: 24px 18px;
    }

    .admin-channels-hero h1 {
        font-size: 34px;
    }

    .admin-channels-summary {
        grid-template-columns: 1fr;
    }

    .admin-channel-grid {
        grid-template-columns: 1fr;
    }

    .admin-channel-card {
        min-height: 0;
        padding: 18px;
    }

    .admin-channel-card-top {
        grid-template-columns: 48px minmax(0, 1fr);
    }

    .admin-channel-status {
        grid-column: 1 / -1;
        width: fit-content;
    }

    .admin-channel-card-actions form,
    .admin-channel-card-actions .vip-duration-form {
        flex-direction: column;
    }

    .admin-channel-card-actions .vip-duration-form label,
    .admin-channel-card-actions .admin-card-action {
        width: 100%;
    }

    .channel-card,
    .recommended-card {
        min-height: 0;
        padding: 18px;
    }

    .card-top {
        margin-bottom: 18px;
    }

    .channel-title {
        font-size: 22px;
    }

    .stats {
        flex-wrap: wrap;
        gap: 8px 14px;
    }

    .actions {
        flex-direction: column;
    }

    .sort-tabs {
        flex-wrap: wrap;
        overflow: visible;
    }

    .sort-btn {
        flex: 1 1 calc(50% - 5px);
        min-height: 42px;
        padding: 9px 10px;
    }

    .detail-stats {
        grid-template-columns: 1fr;
    }

    .detail-actions {
        flex-direction: column;
    }

    .channel-detail {
        padding: 24px 18px;
    }

    .channel-detail h1 {
        font-size: 32px;
    }

    .channel-detail p,
    .channel-description {
        font-size: 15px;
        line-height: 1.65;
    }

    .detail-action-btn {
        width: 100%;
        min-width: 0;
        justify-content: center;
    }

    .detail-actions form {
        width: 100%;
    }

    .admin-channel-actions,
    .admin-channel-actions form,
    .admin-channel-actions .detail-btn,
    .channel-admin-toolbar,
    .channel-admin-toolbar form,
    .channel-admin-toolbar .detail-action-btn {
        width: 100%;
    }

    .admin-channel-actions .vip-duration-form,
    .channel-admin-toolbar .vip-duration-form {
        flex-wrap: wrap;
    }

    .vip-duration-form label,
    .vip-duration-form button {
        width: 100%;
    }

    .pagination {
        flex-wrap: wrap;
        gap: 8px;
    }

    .page-btn,
    .page-current,
    .pagination a {
        padding: 10px 12px;
        font-size: 12px;
    }

    .tg-manager-page {
        width: 100%;
        padding-top: 26px;
    }

    .tg-manager-hero,
    .tg-control-panel,
    .tg-log-panel {
        padding: 20px 16px;
    }

    .tg-manager-hero h1 {
        font-size: 31px;
        letter-spacing: 0;
    }

    .tg-stat-grid {
        grid-template-columns: 1fr;
    }

    .tg-panel-head,
    .tg-history-item {
        flex-direction: column;
        grid-template-columns: 1fr;
    }

    .tg-panel-head {
        align-items: stretch;
    }

    .tg-progress-text {
        max-width: none;
    }

    .tg-log-body {
        max-height: 300px;
    }

    .profile-page {
        padding-top: 24px;
    }

    .profile-cover {
        height: 118px;
    }

    .profile-main {
        padding: 0 18px 24px;
    }

    .profile-avatar {
        width: 96px;
        height: 96px;
        margin-top: -48px;
        font-size: 38px;
    }

    .profile-info h1 {
        font-size: 28px;
    }

    .profile-tabs {
        gap: 16px;
        overflow-x: auto;
        padding-bottom: 1px;
    }

    .profile-tab {
        flex: 0 0 auto;
        white-space: nowrap;
    }

    .admin-tools-grid {
        grid-template-columns: 1fr;
    }

    .admin-dashboard {
        gap: 22px;
    }

    .admin-metric-grid,
    .admin-period-card {
        grid-template-columns: 1fr;
    }

    .admin-metric-card,
    .admin-online-card {
        min-height: 0;
        padding: 20px 18px;
    }

    .admin-period-card div,
    .admin-period-card div:nth-child(2n),
    .admin-period-card div:nth-last-child(-n + 2) {
        border-right: 0;
        border-bottom: 1px solid rgba(255,255,255,.08);
    }

    .admin-period-card div:last-child {
        border-bottom: 0;
    }

    .admin-section-title h2 {
        font-size: 19px;
    }

    .profile-empty-box,
    .submission-card,
    .admin-submission-card {
        padding: 20px 16px;
    }

    .submission-header {
        align-items: flex-start;
        flex-direction: column;
        gap: 10px;
    }

    .avatar-cropper-box {
        width: min(100%, 320px);
        height: auto;
        aspect-ratio: 1;
    }

    .avatar-actions,
    .avatar-upload-form {
        align-items: stretch;
        flex-direction: column;
    }

    .avatar-upload-label,
    .avatar-save-btn,
    .avatar-cancel-btn,
    .avatar-delete-btn {
        width: 100%;
        margin-left: 0;
    }

    .submission-stats,
    .submission-fields-grid {
        grid-template-columns: 1fr;
    }

    .submission-head,
    .submission-actions {
        align-items: stretch;
        flex-direction: column;
    }

    .submission-actions button,
    .admin-open-btn {
        width: 100%;
    }
}

/* =====================================================
   CHANNEL VIP DESIGN
===================================================== */

.card-meta {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 8px;
}


.vip-badge {
    color: #ffcc00;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
}


.vip-card {
    border-color: rgba(255, 204, 0, 0.45);
    box-shadow:
        0 0 25px rgba(255, 204, 0, 0.08);
}


.vip-card:hover {
    border-color: #ffcc00;
    box-shadow:
        0 0 40px rgba(255, 204, 0, 0.18);
}


.channel-username {
    color: rgba(255,255,255,0.45);
    font-size: 13px;
    margin-top: -6px;
    margin-bottom: 12px;
    letter-spacing: 1px;
}


.category {
    margin-bottom: 14px;
}

/* ================================
   CHANNEL DETAIL REDESIGN
================================ */

.channel-title-block {
    margin-top: 20px;
}


.channel-vip-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;

    padding: 6px 12px;

    margin-bottom: 16px;

    color: #ffcc00;

    font-size: 12px;
    font-weight: 700;

    letter-spacing: 2px;
    text-transform: uppercase;

    border: 1px solid rgba(255, 204, 0, 0.35);

    background: rgba(255, 204, 0, 0.05);

    box-shadow: 0 0 20px rgba(255, 204, 0, 0.15);
}


.channel-name {
    margin: 0;

    color: #fff;

    font-size: 56px;

    font-weight: 600;

    line-height: 1.05;
}


.channel-page .channel-username {
    margin-top: 10px;
    margin-bottom: 20px;

    color: rgba(255,255,255,.45);

    font-size: 18px;

    letter-spacing: 1px;
}


.channel-detail > p {
    max-width: 600px;

    color: rgba(255,255,255,.75);

    font-size: 16px;

    line-height: 1.6;
}

/* ================================
   CHANNEL CATEGORY BADGE
================================ */

.channel-category-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;

    padding: 6px 12px;

    margin-bottom: 16px;

    color: #86efac;

    font-size: 14px;
    font-weight: 700;

    letter-spacing: 2px;
    text-transform: uppercase;
    text-decoration: none;
    border: 1px solid rgba(34, 197, 94, .35);

    background: rgba(0, 0, 0, 0.05);

}
.channel-category-badge:hover {
    transform: translateY(-2px);
    background: rgba(0, 255, 170, 0.082);
    text-decoration: none;
}

/* ===== CHANNEL DESCRIPTION ===== */

.channel-description {
    max-width: 700px;

    margin-top: 22px;
    margin-bottom: 35px;

    color: rgba(255,255,255,.72);

    font-size: 16px;
    line-height: 1.8;

    white-space: pre-line;
}

.recommended-card p {
    min-height: 65px;

    overflow: hidden;
    display: -webkit-box;

    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;

    line-clamp: 3;
}

/* ==========================================
   18+ ADULT CENSOR
========================================== */

.adult-card {
    position: relative;
    overflow: hidden;
}

/* Размываем весь контент карточки */
.adult-card > *:not(.adult-overlay) {
    filter: blur(10px);
    pointer-events: none;
    user-select: none;
    transition: .3s ease;
}

/* Сама цензура */
.adult-overlay {
    position: absolute;
    inset: 0;
    z-index: 50;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    background:
        linear-gradient(
            180deg,
            rgba(0,0,0,.65),
            rgba(0,0,0,.90)
        );

    backdrop-filter: blur(8px);

    cursor: pointer;
    transition: .3s ease;
}

/* Иконка 🔞 */
.adult-icon {
    font-size: 42px;
    margin-bottom: 14px;
}

/* Заголовок */
.adult-title {
    color: #ff4d4d;
    font-size: 16px;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
}

/* Текст */
.adult-text {
    margin-top: 8px;

    color: rgba(255,255,255,.65);

    font-size: 12px;
}

/* После снятия цензуры */

.adult-open > * {
    filter: none !important;
    pointer-events: auto !important;
    user-select: auto !important;
}

.adult-category-locked {
    overflow: hidden;
}

.adult-category-modal {
    position: fixed;
    inset: 0;
    z-index: 10050;

    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;

    background: rgba(0,0,0,.78);
    backdrop-filter: blur(12px);
}

.adult-category-modal[hidden] {
    display: none;
}

.adult-category-dialog {
    position: relative;
    overflow: hidden;
    width: min(520px, 100%);
    padding: 34px 28px;

    display: flex;
    flex-direction: column;
    align-items: center;

    background:
        radial-gradient(circle at top, rgba(239,68,68,.12), transparent 38%),
        rgba(0,0,0,.86);
    border: 1px solid rgba(255,255,255,.14);
    box-shadow:
        0 24px 80px rgba(0,0,0,.62),
        inset 0 0 0 1px rgba(255,255,255,.025);
    backdrop-filter: blur(18px);
    color: #fff;
    text-align: center;
}

.adult-category-dialog::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent, rgba(239,68,68,.95), #f5c542, transparent);
}

.adult-category-dialog::after {
    content: "";
    position: absolute;
    inset: 1px;
    pointer-events: none;
    background:
        linear-gradient(135deg, rgba(255,255,255,.045), transparent 34%),
        radial-gradient(circle at 50% 0, rgba(245,197,66,.08), transparent 34%);
}

.adult-category-dialog > * {
    position: relative;
    z-index: 1;
}

.adult-category-icon {
    width: 62px;
    height: 62px;
    margin-bottom: 18px;

    display: flex;
    align-items: center;
    justify-content: center;

    border: 1px solid rgba(239,68,68,.42);
    background: rgba(239,68,68,.1);
    box-shadow:
        0 0 26px rgba(239,68,68,.18),
        inset 0 0 0 1px rgba(255,255,255,.035);

    color: #ff6b6b;
    font-size: 28px;
    font-weight: 800;
}

.adult-category-dialog h2 {
    margin: 0 0 12px;

    color: #fff;
    font-size: 24px;
    font-weight: 800;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.adult-category-dialog p {
    max-width: 380px;
    margin: 0 0 24px;

    color: rgba(255,255,255,.62);
    font-size: 15px;
    line-height: 1.55;
}

.adult-category-dialog button {
    width: min(464px, 100%);
    min-height: 48px;
    margin-top: 10px;

    border: 1px solid rgba(255,255,255,.14);
    background: rgba(255,255,255,.045);

    color: #fff;
    font-size: 14px;
    font-weight: 800;
    letter-spacing: 1px;
    text-transform: uppercase;
    cursor: pointer;
    transition:
        transform .2s ease,
        border-color .2s ease,
        background .2s ease;
}

.adult-category-dialog button:hover {
    transform: translateY(-2px);
}

.adult-category-confirm {
    border-color: rgba(239,68,68,.55) !important;
    background:
        linear-gradient(90deg, rgba(239,68,68,.2), rgba(239,68,68,.1)) !important;
    color: #ff8a8a !important;
}

.adult-category-confirm:hover {
    background: rgba(239,68,68,.24) !important;
}

.adult-category-back {
    background: rgba(255,255,255,.055) !important;
    color: rgba(255,255,255,.72) !important;
}

.adult-category-back:hover {
    border-color: rgba(255,255,255,.32) !important;
    background: rgba(255,255,255,.09) !important;
}

.section-more-link {
    margin-left: auto;

    color: #f5c542;
    text-decoration: none;

    font-size: 13px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.section-more-link:hover {
    opacity: .75;
}

/* ===== PROFILE CHANNELS ===== */

.submission-card {
    background: rgba(10, 10, 10, 0.85);
    border: 1px solid rgba(255,255,255,0.08);
    padding: 22px 24px;
    margin-bottom: 16px;
    position: relative;
    overflow: hidden;

    transition: 
        border-color .25s ease,
        transform .25s ease,
        background .25s ease;
}


.submission-card:hover {
    border-color: var(--accent);
    background: rgba(15,15,15,0.95);
    transform: translateY(-3px);
}


.submission-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;

    margin-bottom: 10px;
}


.submission-header h3 {
    font-size: 24px;
    font-weight: 600;
    color: #fff;
}


.submission-card .channel-username {
    color: rgba(255,255,255,.45);
    font-size: 14px;

    margin-top: 4px;
}


.submission-card p {
    color: rgba(255,255,255,.65);
    line-height: 1.5;

    margin: 16px 0;
}


.submission-date {
    color: rgba(255,255,255,.35);
    font-size: 12px;

    letter-spacing: 1px;
    text-transform: uppercase;
}


/* Статусы */

.status-pending,
.status-approved,
.status-rejected {

    padding: 8px 14px;

    border: 1px solid;
    font-size: 12px;
    font-weight: 700;

    letter-spacing: 1px;
    text-transform: uppercase;

    white-space: nowrap;
}


.status-pending {
    color: #f4c542;
    border-color: rgba(244,197,66,.5);
    background: rgba(244,197,66,.08);
}


.status-approved {
    color: #00ff99;
    border-color: rgba(0,255,153,.4);
    background: rgba(0,255,153,.08);
}


.status-rejected {
    color: #ff4d4d;
    border-color: rgba(255,77,77,.4);
    background: rgba(255,77,77,.08);
}

/* =========================
   FOOTER / LEGAL
========================= */

.site-footer {
    position: relative;
    z-index: 5;
    margin: 34px 12px 12px 284px;
}

.site-footer-inner {
    padding: 28px 32px;

    display: grid;
    gap: 22px;

    background:
        radial-gradient(circle at 10% 0, rgba(0,255,136,.06), transparent 30%),
        rgba(0,0,0,.76);
    border: 1px solid rgba(255,255,255,.1);
    border-top: 2px solid rgba(245,197,66,.72);
    backdrop-filter: blur(12px);
}

.site-footer-topline,
.site-footer-bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.site-footer-brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    color: #fff;
    text-decoration: none;
    font-size: 14px;
    font-weight: 800;
    letter-spacing: 4px;
}

.site-footer-logo {
    width: 34px;
    height: 34px;
    object-fit: cover;
}

.site-footer-text {
    margin: 0;
    padding: 18px 0;
    border-top: 1px solid rgba(255,255,255,.12);
    border-bottom: 1px solid rgba(255,255,255,.12);
    color: rgba(255,255,255,.68);
    font-size: 14px;
    line-height: 1.7;
}

.site-footer-tags {
    display: flex;
    align-items: center;
    gap: 0;
    flex-wrap: wrap;
}

.site-footer-tags a {
    color: #00b7ff;
    text-decoration: underline;
    text-underline-offset: 3px;
    font-size: 13px;
    line-height: 1.9;
    transition: color .2s ease;
}

.site-footer-tags a::after {
    content: "|";
    margin: 0 7px;
    color: rgba(255,255,255,.45);
    text-decoration: none;
}

.site-footer-tags a:last-child::after {
    content: "";
    margin: 0;
}

.site-footer-tags a:hover {
    color: #f5c542;
}

.site-footer-bottom {
    padding-top: 4px;
    color: rgba(255,255,255,.42);
    font-size: 13px;
}

.site-footer-compact .site-footer-inner {
    min-height: 76px;
    padding: 20px 32px;
}

.site-footer-compact .site-footer-bottom {
    width: 100%;
    padding-top: 0;
}

.site-footer-links {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.site-footer-links a {
    color: rgba(255,255,255,.55);
    text-decoration: none;
    font-size: 13px;
    transition: color .2s ease;
}

.site-footer-links a + a::before {
    content: "|";
    margin-right: 8px;
    color: rgba(255,255,255,.35);
}

.site-footer-links a:hover {
    color: #fff;
}

.site-footer-links a:last-child {
    color: #fff;
    font-weight: 700;
}

.legal-page {
    width: min(980px, 94vw);
    margin: 0 auto;
}

.legal-card {
    padding: 48px;

    background: rgba(0,0,0,.68);
    border: 1px solid rgba(255,255,255,.12);
    backdrop-filter: blur(14px);
}

.legal-card h1 {
    margin: 0 0 12px;

    color: #fff;
    font-size: 48px;
    font-weight: 300;
    line-height: 1.08;
}

.legal-date {
    margin-bottom: 34px;

    color: #f5c542;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.legal-card h2 {
    margin: 34px 0 12px;

    color: #fff;
    font-size: 24px;
    font-weight: 500;
}

.legal-card p,
.legal-card li {
    color: rgba(255,255,255,.68);
    font-size: 15px;
    line-height: 1.75;
}

.legal-card p {
    margin: 0 0 14px;
}

.legal-card ul {
    margin: 0 0 18px 20px;
    display: grid;
    gap: 8px;
}

@media (max-width: 900px) {
    .site-footer {
        margin: 26px 12px 12px;
    }

    .site-footer-inner {
        padding: 22px;
    }

    .site-footer-compact .site-footer-inner {
        padding: 18px 20px;
    }

    .site-footer-topline,
    .site-footer-bottom {
        align-items: flex-start;
        flex-direction: column;
        justify-content: flex-start;
        gap: 16px;
    }

    .legal-card {
        padding: 34px 24px;
    }
}

@media (max-width: 600px) {
    .site-footer-inner {
        padding: 18px;
        gap: 18px;
    }

    .site-footer-brand {
        font-size: 13px;
        letter-spacing: 3px;
    }

    .site-footer-text {
        font-size: 13px;
    }

    .site-footer-tags a {
        font-size: 12px;
    }

    .site-footer-links {
        flex-direction: row;
        align-items: flex-start;
        gap: 8px;
    }

    .legal-page {
        width: 100%;
    }

    .legal-card {
        padding: 26px 18px;
    }

    .legal-card h1 {
        font-size: 34px;
    }

    .legal-card h2 {
        font-size: 21px;
    }
}

/* =========================================================
   RICH QUEEN INSPIRED WARM THEME OVERRIDES
   ========================================================= */

:root {
    --rq-bg: #070302;
    --rq-panel: rgba(22, 10, 4, .72);
    --rq-panel-strong: rgba(35, 14, 5, .84);
    --rq-line: rgba(255, 131, 38, .18);
    --rq-line-strong: rgba(255, 131, 38, .42);
    --rq-orange: #ff7a1a;
    --rq-orange-soft: #d25a16;
    --rq-gold: #ffb45c;
    --rq-text: #f7efe8;
    --rq-muted: rgba(247, 239, 232, .62);
    --rq-faint: rgba(247, 239, 232, .38);
    --rq-radius: 8px;
    --rq-shadow: 0 24px 70px rgba(0, 0, 0, .52);
    --rq-glow: 0 0 34px rgba(255, 122, 26, .16);
}

html,
body {
    background:
        radial-gradient(circle at 72% 4%, rgba(255, 122, 26, .22), transparent 31%),
        radial-gradient(circle at 12% 22%, rgba(136, 54, 12, .20), transparent 28%),
        linear-gradient(180deg, #0b0402 0%, #050201 48%, #090403 100%) !important;
    color: var(--rq-text);
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: 1;
    pointer-events: none;
    background:
        linear-gradient(90deg, rgba(255,255,255,.025) 1px, transparent 1px),
        linear-gradient(180deg, rgba(255,255,255,.018) 1px, transparent 1px);
    background-size: 86px 86px;
    mask-image: radial-gradient(circle at 50% 18%, black, transparent 78%);
}

#bgCanvas {
    opacity: .34;
    filter: sepia(.9) saturate(1.55) hue-rotate(342deg) brightness(.9);
}

.frame {
    border-color: rgba(255, 131, 38, .18);
    box-shadow: inset 0 0 80px rgba(255, 122, 26, .035);
}

.sidebar,
.topbar,
.hero,
.channel-detail,
.profile-hero,
.admin-submission-card,
.admin-tool-card,
.profile-empty-box,
.submission-card,
.tg-manager-hero,
.tg-control-panel,
.tg-log-panel,
.site-footer-inner,
.legal-card,
.admin-channels-hero,
.admin-channel-card,
.admin-dashboard-panel,
.admin-metric-card,
.admin-online-card,
.admin-period-card,
.visits-panel,
.visits-card {
    background:
        radial-gradient(circle at 80% 8%, rgba(255, 122, 26, .12), transparent 34%),
        linear-gradient(135deg, rgba(255,255,255,.045), transparent 34%),
        var(--rq-panel) !important;
    border-color: var(--rq-line) !important;
    box-shadow: var(--rq-shadow), var(--rq-glow);
    backdrop-filter: blur(18px);
}

.sidebar {
    border-right-color: var(--rq-line);
}

.topbar {
    border-bottom-color: var(--rq-line);
}

.brand,
.mobile-top-brand,
.site-footer-brand,
.topbar-title {
    color: var(--rq-text);
}

.brand span,
.mobile-top-brand span,
.site-footer-brand span {
    text-shadow: 0 0 18px rgba(255, 122, 26, .28);
}

.brand-icon,
.mobile-top-brand-icon,
.site-footer-logo {
    border-radius: var(--rq-radius);
    box-shadow: 0 0 22px rgba(255, 122, 26, .18);
}

.side-title,
.eyebrow,
.detail-category,
.legal-date,
.admin-section-title span {
    color: var(--rq-gold) !important;
    letter-spacing: 2.6px;
}

.hero h1,
.channel-detail h1,
.profile-info h1,
.admin-channels-hero h1,
.tg-manager-hero h1,
.legal-card h1 {
    color: var(--rq-text);
    text-shadow: 0 0 40px rgba(255, 122, 26, .16);
}

.hero h1::first-line,
.channel-detail h1::first-line,
.block-title h2,
.recommended-title h2 {
    color: var(--rq-text);
}

.hero p,
.channel-detail p,
.legal-card p,
.legal-card li,
.site-footer-text,
.profile-meta,
.channel-username,
.category-btn em,
.admin-tool-card span,
.profile-action em,
.recommended-card p,
.channel-card p {
    color: var(--rq-muted) !important;
}

.hero::before,
.profile-cover {
    background:
        radial-gradient(circle at center, rgba(255, 122, 26, .26), transparent 58%),
        radial-gradient(circle at 65% 20%, rgba(255, 180, 92, .12), transparent 42%) !important;
}

.hero-search,
.add-form input,
.add-form textarea,
.add-form select,
.admin-submission-card input,
.admin-submission-card textarea,
.admin-submission-card select,
.avatar-select,
.admin-search-form input,
.tg-control-panel input,
.tg-control-panel select {
    background: rgba(8, 3, 1, .72) !important;
    border-color: rgba(255, 131, 38, .20) !important;
    color: var(--rq-text) !important;
    border-radius: var(--rq-radius);
}

.hero-search:focus-within,
.add-form input:focus,
.add-form textarea:focus,
.add-form select:focus,
.admin-submission-card input:focus,
.admin-submission-card textarea:focus,
.admin-submission-card select:focus {
    border-color: var(--rq-orange) !important;
    box-shadow: 0 0 0 3px rgba(255, 122, 26, .12);
}

.top-add-btn,
.top-profile-btn,
.detail-btn,
.detail-action-btn,
.sort-btn,
.page-btn,
.pagination a,
.admin-filters a,
.admin-open-btn,
.profile-action,
.side-action,
.admin-card-action,
.tg-action-btn,
.adult-category-dialog button,
button {
    border-radius: var(--rq-radius) !important;
    border-color: rgba(255, 131, 38, .24) !important;
    background:
        linear-gradient(180deg, rgba(255, 122, 26, .10), rgba(255, 122, 26, .035)) !important;
    color: var(--rq-text) !important;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.06);
}

.top-add-btn:hover,
.top-profile-btn:hover,
.detail-btn:hover,
.detail-action-btn:hover,
.sort-btn:hover,
.page-btn:hover,
.pagination a:hover,
.admin-filters a:hover,
.admin-open-btn:hover,
.profile-action:hover,
.side-action:hover,
.admin-card-action:hover,
.tg-action-btn:hover {
    background:
        linear-gradient(180deg, rgba(255, 122, 26, .24), rgba(136, 54, 12, .22)) !important;
    border-color: var(--rq-orange) !important;
    color: #fff !important;
    box-shadow: 0 12px 28px rgba(255, 122, 26, .12);
}

.detail-btn.primary,
.topbar-actions .top-add-btn:first-child,
.side-action.vip,
.sort-btn.active,
.page-current,
.admin-filters a.active,
.adult-category-confirm {
    background:
        linear-gradient(135deg, #ff8a2a, #f06618 46%, #9e3d10) !important;
    border-color: rgba(255, 180, 92, .62) !important;
    color: #180804 !important;
    font-weight: 800;
    box-shadow:
        0 16px 34px rgba(255, 122, 26, .22),
        inset 0 1px 0 rgba(255,255,255,.25);
}

.detail-btn.primary:hover,
.topbar-actions .top-add-btn:first-child:hover,
.side-action.vip:hover,
.adult-category-confirm:hover {
    filter: brightness(1.08);
    color: #140704 !important;
}

.side-action.add {
    background:
        linear-gradient(135deg, rgba(255, 122, 26, .16), rgba(255, 180, 92, .08)) !important;
    color: var(--rq-text) !important;
}

.category-btn,
.side-link,
.profile-tab,
.site-footer-links a,
.site-footer-tags a,
.auth-link {
    color: var(--rq-muted) !important;
}

.category-btn {
    border-radius: var(--rq-radius);
    background: rgba(255, 255, 255, .025);
    border-color: rgba(255, 131, 38, .10);
}

.category-btn:hover,
.category-btn.active {
    background:
        linear-gradient(90deg, rgba(255, 122, 26, .18), rgba(255, 122, 26, .035)) !important;
    border-color: var(--rq-line-strong) !important;
    color: #fff !important;
}

.category-btn.active::before,
.profile-tab.active::after {
    background: var(--rq-orange) !important;
    box-shadow: 0 0 18px rgba(255, 122, 26, .55);
}

.block-icon,
.channel-avatar,
.top-profile-avatar,
.profile-avatar,
.adult-category-icon {
    border-color: rgba(255, 131, 38, .26) !important;
    background: rgba(255, 122, 26, .065) !important;
    box-shadow: inset 0 0 0 1px rgba(255,255,255,.03), 0 0 22px rgba(255, 122, 26, .12);
}

.recommended-card,
.channel-card {
    border-radius: var(--rq-radius);
    border-color: rgba(255, 131, 38, .18) !important;
    background:
        radial-gradient(circle at 78% 18%, rgba(255, 122, 26, .14), transparent 42%),
        linear-gradient(145deg, rgba(255,255,255,.045), transparent 36%),
        rgba(12, 5, 2, .78) !important;
    box-shadow: 0 16px 42px rgba(0,0,0,.34);
}

.recommended-card:hover,
.channel-card:hover,
.admin-tool-card:hover,
.admin-channel-card:hover {
    border-color: rgba(255, 122, 26, .64) !important;
    box-shadow: 0 24px 60px rgba(0,0,0,.42), 0 0 38px rgba(255, 122, 26, .16);
}

.recommend-badge,
.vip-badge,
.channel-card .vip-label,
.category,
.admin-badge,
.vip-until {
    border-color: rgba(255, 180, 92, .45) !important;
    background: rgba(255, 122, 26, .12) !important;
    color: var(--rq-gold) !important;
    border-radius: 6px;
}

.stats span,
.channel-detail .stats div,
.admin-metric-card,
.admin-online-card,
.admin-period-card div {
    border-color: rgba(255, 131, 38, .14) !important;
    background: rgba(255, 122, 26, .04) !important;
}

.stats span,
.admin-metric-card strong,
.admin-online-card strong,
.admin-period-card strong,
.profile-action span,
.admin-tool-card strong {
    color: var(--rq-gold) !important;
}

.site-footer-inner {
    border-top-color: rgba(255, 122, 26, .78) !important;
}

.site-footer-tags a {
    color: #ff9b3f !important;
}

.site-footer-tags a:hover,
.site-footer-links a:hover,
.auth-link:hover {
    color: var(--rq-gold) !important;
}

.form-message.success {
    background: rgba(255, 122, 26, .10);
    border-color: rgba(255, 122, 26, .34);
    color: var(--rq-gold);
}

.form-message.error,
.adult-title {
    color: #ff6b4a !important;
}

.mobile-menu-btn {
    color: var(--rq-text);
}

@media (max-width: 900px) {
    .topbar,
    .sidebar {
        background:
            radial-gradient(circle at 75% 0, rgba(255, 122, 26, .16), transparent 38%),
            rgba(8, 3, 1, .88) !important;
    }
}

/* =========================================================
   WARM GLASS REFINEMENT
   ========================================================= */

:root {
    --rq-panel: rgba(10, 6, 4, .46);
    --rq-panel-strong: rgba(16, 8, 4, .58);
    --rq-line: rgba(255, 174, 104, .16);
    --rq-line-strong: rgba(255, 134, 44, .34);
    --rq-orange: #f47a25;
    --rq-gold: #f4b16a;
    --rq-muted: rgba(247, 239, 232, .58);
    --rq-shadow: 0 22px 70px rgba(0, 0, 0, .44);
    --rq-glow: 0 0 26px rgba(244, 122, 37, .08);
}

html,
body {
    background:
        radial-gradient(circle at 74% 6%, rgba(244, 122, 37, .12), transparent 32%),
        radial-gradient(circle at 12% 28%, rgba(244, 122, 37, .075), transparent 31%),
        linear-gradient(180deg, #070403 0%, #020101 54%, #070302 100%) !important;
}

body::before {
    opacity: .42;
}

#bgCanvas {
    opacity: .42;
    filter: sepia(.45) saturate(1.15) hue-rotate(344deg) brightness(.82);
}

.hero,
.channel-detail,
.profile-hero,
.admin-submission-card,
.admin-tool-card,
.profile-empty-box,
.submission-card,
.tg-manager-hero,
.tg-control-panel,
.tg-log-panel,
.site-footer-inner,
.legal-card,
.admin-channels-hero,
.admin-channel-card,
.admin-dashboard-panel,
.admin-metric-card,
.admin-online-card,
.admin-period-card,
.visits-panel,
.visits-card {
    background:
        linear-gradient(135deg, rgba(255,255,255,.07), rgba(255,255,255,.018) 42%, rgba(255,255,255,.035)),
        radial-gradient(circle at 76% 8%, rgba(244, 122, 37, .075), transparent 38%),
        rgba(7, 4, 3, .42) !important;
    border-color: rgba(255, 255, 255, .105) !important;
    box-shadow:
        0 24px 70px rgba(0,0,0,.38),
        inset 0 1px 0 rgba(255,255,255,.075),
        inset 0 -1px 0 rgba(255, 134, 44, .045);
    backdrop-filter: blur(22px) saturate(1.18);
}

.sidebar {
    background:
        linear-gradient(135deg, rgba(255,255,255,.055), rgba(255,255,255,.014)),
        radial-gradient(circle at 65% 0, rgba(244, 122, 37, .08), transparent 40%),
        rgba(5, 3, 2, .68) !important;
    border-color: rgba(255,255,255,.11) !important;
    box-shadow:
        20px 0 70px rgba(0,0,0,.40),
        inset 1px 0 0 rgba(255,255,255,.04);
}

.topbar {
    background:
        linear-gradient(90deg, rgba(8,4,2,.70), rgba(12,6,3,.50)),
        rgba(4,2,1,.48) !important;
    border-bottom-color: rgba(255,255,255,.10) !important;
    box-shadow:
        0 18px 42px rgba(0,0,0,.28),
        inset 0 -1px 0 rgba(244,122,37,.05);
    backdrop-filter: blur(24px) saturate(1.2);
}

.hero::before,
.profile-cover {
    background:
        radial-gradient(circle at center, rgba(244, 122, 37, .12), transparent 60%),
        radial-gradient(circle at 65% 20%, rgba(244, 177, 106, .065), transparent 45%) !important;
}

.hero-search,
.add-form input,
.add-form textarea,
.add-form select,
.admin-submission-card input,
.admin-submission-card textarea,
.admin-submission-card select,
.avatar-select,
.admin-search-form input,
.tg-control-panel input,
.tg-control-panel select {
    background:
        linear-gradient(180deg, rgba(255,255,255,.045), rgba(255,255,255,.018)),
        rgba(3, 2, 1, .38) !important;
    border-color: rgba(255,255,255,.14) !important;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.045);
}

.top-add-btn,
.top-profile-btn,
.detail-btn,
.detail-action-btn,
.sort-btn,
.page-btn,
.pagination a,
.admin-filters a,
.admin-open-btn,
.profile-action,
.side-action,
.admin-card-action,
.tg-action-btn,
.adult-category-dialog button,
button {
    background:
        linear-gradient(180deg, rgba(255,255,255,.055), rgba(255,255,255,.015)),
        rgba(244, 122, 37, .035) !important;
    border-color: rgba(255,255,255,.14) !important;
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,.07),
        0 10px 26px rgba(0,0,0,.16);
}

.top-add-btn:hover,
.top-profile-btn:hover,
.detail-btn:hover,
.detail-action-btn:hover,
.sort-btn:hover,
.page-btn:hover,
.pagination a:hover,
.admin-filters a:hover,
.admin-open-btn:hover,
.profile-action:hover,
.side-action:hover,
.admin-card-action:hover,
.tg-action-btn:hover {
    background:
        linear-gradient(180deg, rgba(244,122,37,.16), rgba(255,255,255,.035)) !important;
    border-color: rgba(244, 177, 106, .42) !important;
    box-shadow:
        0 14px 30px rgba(0,0,0,.22),
        0 0 24px rgba(244,122,37,.075);
}

.detail-btn.primary,
.topbar-actions .top-add-btn:first-child,
.side-action.vip,
.sort-btn.active,
.page-current,
.admin-filters a.active,
.adult-category-confirm {
    background:
        linear-gradient(135deg, rgba(255, 154, 65, .92), rgba(213, 91, 28, .90)) !important;
    border-color: rgba(255, 201, 145, .52) !important;
    box-shadow:
        0 16px 34px rgba(244, 122, 37, .14),
        inset 0 1px 0 rgba(255,255,255,.22);
}

.category-btn:hover,
.category-btn.active {
    background:
        linear-gradient(90deg, rgba(244, 122, 37, .105), rgba(255,255,255,.025)) !important;
    border-color: rgba(244, 177, 106, .26) !important;
}

.recommended-card,
.channel-card {
    background:
        linear-gradient(145deg, rgba(255,255,255,.06), rgba(255,255,255,.018) 44%, rgba(244,122,37,.035)),
        radial-gradient(circle at 78% 18%, rgba(244, 122, 37, .07), transparent 44%),
        rgba(5, 3, 2, .38) !important;
    border-color: rgba(255,255,255,.10) !important;
    box-shadow:
        0 18px 48px rgba(0,0,0,.28),
        inset 0 1px 0 rgba(255,255,255,.055);
    backdrop-filter: blur(20px) saturate(1.16);
}

.recommended-card:hover,
.channel-card:hover,
.admin-tool-card:hover,
.admin-channel-card:hover {
    border-color: rgba(244, 177, 106, .36) !important;
    box-shadow:
        0 26px 64px rgba(0,0,0,.34),
        0 0 28px rgba(244, 122, 37, .085),
        inset 0 1px 0 rgba(255,255,255,.08);
}

.recommend-badge,
.vip-badge,
.channel-card .vip-label,
.category,
.admin-badge,
.vip-until {
    background: rgba(244, 122, 37, .075) !important;
    border-color: rgba(244, 177, 106, .28) !important;
}

.stats span,
.channel-detail .stats div,
.admin-metric-card,
.admin-online-card,
.admin-period-card div {
    background: rgba(255,255,255,.025) !important;
    border-color: rgba(255,255,255,.10) !important;
}

.site-footer-inner {
    border-top-color: rgba(244, 122, 37, .42) !important;
}

.site-footer-tags a {
    color: rgba(244, 177, 106, .92) !important;
}

@media (max-width: 900px) {
    .topbar,
    .sidebar {
        background:
            linear-gradient(135deg, rgba(255,255,255,.055), rgba(255,255,255,.014)),
            radial-gradient(circle at 75% 0, rgba(244, 122, 37, .09), transparent 40%),
            rgba(5, 3, 2, .72) !important;
    }
}

/* =========================================================
   SMOOTHER SCROLL + MOBILE CARD FIXES
   ========================================================= */

html {
    scroll-padding-top: 96px;
}

body {
    overscroll-behavior-y: none;
}

.sidebar,
.categories-list,
.sort-tabs,
.profile-tabs,
.tg-log-stream {
    -webkit-overflow-scrolling: touch;
}

.channel-card,
.recommended-card,
.admin-channel-card,
.admin-submission-card {
    contain-intrinsic-size: 320px;
}

.channel-card .category,
.recommended-card .category {
    width: fit-content !important;
    max-width: 100%;
    min-height: 0;
    display: inline-flex !important;
    align-items: center;
    margin: 0 0 16px !important;
    padding: 4px 9px !important;
    border-radius: 999px !important;
    line-height: 1.2;
    white-space: nowrap;
    letter-spacing: 4px;
}

@media (max-width: 900px) {
    html,
    body {
        overflow-y: auto !important;
        touch-action: pan-y;
        overscroll-behavior-y: auto;
    }

    body.adult-category-locked {
        overflow: hidden !important;
    }

    .channel-card,
    .recommended-card,
    .admin-channel-card,
    .admin-submission-card,
    .hero,
    .channel-detail,
    .profile-hero,
    .site-footer-inner {
        backdrop-filter: blur(12px) saturate(1.08);
    }

}

@media (max-width: 600px) {
    .channel-card .category,
    .recommended-card .category {
        margin-bottom: 14px !important;
        padding: 3px 8px !important;
        font-size: 10px;
        letter-spacing: 3px;
    }
}

/* =========================================================
   BLACK-FIRST PALETTE BALANCE
   ========================================================= */

:root {
    --rq-panel: rgba(4, 4, 4, .56);
    --rq-panel-strong: rgba(8, 8, 8, .72);
    --rq-line: rgba(255, 255, 255, .12);
    --rq-line-strong: rgba(244, 122, 37, .30);
    --rq-shadow: 0 24px 70px rgba(0, 0, 0, .50);
    --rq-glow: 0 0 22px rgba(244, 122, 37, .055);
}

html,
body {
    background:
        radial-gradient(circle at 78% 7%, rgba(244, 122, 37, .07), transparent 29%),
        radial-gradient(circle at 16% 26%, rgba(255,255,255,.035), transparent 26%),
        linear-gradient(180deg, #040404 0%, #000 54%, #030303 100%) !important;
}

#bgCanvas {
    opacity: .36;
    filter: sepia(.2) saturate(.92) hue-rotate(348deg) brightness(.72);
}

.hero,
.channel-detail,
.profile-hero,
.admin-submission-card,
.admin-tool-card,
.profile-empty-box,
.submission-card,
.tg-manager-hero,
.tg-control-panel,
.tg-log-panel,
.site-footer-inner,
.legal-card,
.admin-channels-hero,
.admin-channel-card,
.admin-dashboard-panel,
.admin-metric-card,
.admin-online-card,
.admin-period-card,
.visits-panel,
.visits-card {
    background:
        linear-gradient(135deg, rgba(255,255,255,.065), rgba(255,255,255,.012) 44%, rgba(255,255,255,.03)),
        radial-gradient(circle at 82% 12%, rgba(244, 122, 37, .038), transparent 36%),
        rgba(3, 3, 3, .58) !important;
    border-color: rgba(255,255,255,.105) !important;
    box-shadow:
        0 24px 70px rgba(0,0,0,.42),
        inset 0 1px 0 rgba(255,255,255,.075),
        inset 0 -1px 0 rgba(244,122,37,.026);
}

.sidebar,
.topbar {
    background:
        linear-gradient(135deg, rgba(255,255,255,.05), rgba(255,255,255,.01)),
        radial-gradient(circle at 82% 0, rgba(244,122,37,.045), transparent 38%),
        rgba(2, 2, 2, .72) !important;
}

.hero::before,
.profile-cover {
    background:
        radial-gradient(circle at center, rgba(244, 122, 37, .06), transparent 62%),
        radial-gradient(circle at 65% 20%, rgba(255,255,255,.035), transparent 46%) !important;
}

.recommended-card,
.channel-card {
    background:
        linear-gradient(145deg, rgba(255,255,255,.06), rgba(255,255,255,.012) 45%, rgba(255,255,255,.025)),
        radial-gradient(circle at 80% 18%, rgba(244,122,37,.04), transparent 42%),
        rgba(2, 2, 2, .58) !important;
    border-color: rgba(255,255,255,.105) !important;
}

.hero-search,
.add-form input,
.add-form textarea,
.add-form select,
.admin-submission-card input,
.admin-submission-card textarea,
.admin-submission-card select,
.avatar-select,
.admin-search-form input,
.tg-control-panel input,
.tg-control-panel select {
    background:
        linear-gradient(180deg, rgba(255,255,255,.05), rgba(255,255,255,.014)),
        rgba(0, 0, 0, .54) !important;
    border-color: rgba(255,255,255,.14) !important;
}

.top-add-btn,
.top-profile-btn,
.detail-btn,
.detail-action-btn,
.sort-btn,
.page-btn,
.pagination a,
.admin-filters a,
.admin-open-btn,
.profile-action,
.side-action,
.admin-card-action,
.tg-action-btn,
.adult-category-dialog button,
button {
    background:
        linear-gradient(180deg, rgba(255,255,255,.055), rgba(255,255,255,.012)),
        rgba(0, 0, 0, .38) !important;
    border-color: rgba(255,255,255,.15) !important;
}

.detail-btn.primary,
.topbar-actions .top-add-btn:first-child,
.side-action.vip,
.sort-btn.active,
.page-current,
.admin-filters a.active,
.adult-category-confirm {
    background:
        linear-gradient(135deg, #ff8a2a, #e5631f 48%, #b54815) !important;
    border-color: rgba(255, 174, 104, .50) !important;
}

.category-btn:hover,
.category-btn.active {
    background:
        linear-gradient(90deg, rgba(244, 122, 37, .075), rgba(255,255,255,.018)) !important;
    border-color: rgba(244, 122, 37, .24) !important;
}

.channel-card .category,
.recommended-card .category,
.recommend-badge,
.vip-badge,
.channel-card .vip-label,
.admin-badge,
.vip-until {
    background: rgba(244, 122, 37, .055) !important;
    border-color: rgba(244, 122, 37, .24) !important;
}

.stats span,
.channel-detail .stats div,
.admin-metric-card,
.admin-online-card,
.admin-period-card div {
    background: rgba(255,255,255,.022) !important;
    border-color: rgba(255,255,255,.095) !important;
}

@media (max-width: 900px) {
    .topbar,
    .sidebar {
        background:
            linear-gradient(135deg, rgba(255,255,255,.055), rgba(255,255,255,.012)),
            radial-gradient(circle at 78% 0, rgba(244, 122, 37, .055), transparent 40%),
            rgba(2, 2, 2, .74) !important;
    }
}

/* =========================================================
   MOBILE POLISH: SORT TABS + CHANNEL TITLES
   ========================================================= */

.sort-btn,
.sort-btn:hover,
.sort-btn:focus,
.sort-btn:visited,
.sort-btn.active {
    text-decoration: none !important;
}

.channel-title,
.recommended-card .channel-title,
.channel-card h3,
.recommended-card h3 {
    font-weight: 650 !important;
    letter-spacing: 0;
}

@media (max-width: 600px) {
    .channel-title,
    .recommended-card .channel-title,
    .channel-card h3,
    .recommended-card h3 {
        font-weight: 680 !important;
    }
}

/* =========================================================
   RENDER PERFORMANCE WITHOUT VISUAL RESET
   ========================================================= */

#bgCanvas {
    pointer-events: none;
}

@media (min-width: 901px) {
    .channel-card,
    .recommended-card,
    .admin-channel-card,
    .admin-submission-card,
    .admin-tool-card,
    .admin-dashboard-panel,
    .admin-metric-card,
    .admin-online-card,
    .admin-period-card,
    .visits-card,
    .tg-log-panel {
        content-visibility: auto;
        contain-intrinsic-size: 360px;
        contain: layout paint style;
    }

    .sidebar,
    .topbar,
    .frame,
    .hero,
    .channel-detail,
    .admin-channels-hero,
    .tg-manager-hero,
    .tg-control-panel,
    .site-footer-inner {
        contain: paint;
    }

    body.is-scrolling .channel-card,
    body.is-scrolling .recommended-card,
    body.is-scrolling .admin-channel-card,
    body.is-scrolling .admin-submission-card {
        transition: none !important;
    }
}

/* =========================================================
   FILTER PERFORMANCE FIX
   backdrop-filter/filter forces expensive repaints while scrolling.
   Keep the glass look with backgrounds/borders/shadows instead.
   ========================================================= */

*,
*::before,
*::after {
    -webkit-backdrop-filter: none !important;
    backdrop-filter: none !important;
    filter: none !important;
}

body::before,
#bgCanvas,
.hero::before,
.profile-cover,
.detail-btn.primary:hover,
.topbar-actions .top-add-btn:first-child:hover,
.side-action.vip:hover,
.adult-category-confirm:hover {
    filter: none !important;
}

.adult-card:not(.adult-open) > *:not(.adult-overlay) {
    filter: blur(10px) !important;
}

.adult-open > * {
    filter: none !important;
}

/* =========================================================
   SOFTER MAIN CTA BUTTONS
   ========================================================= */

.topbar-actions .top-add-btn[href="/add-channel"],
.topbar-actions .top-add-btn.admin-direct-add,
.side-action.vip {
    background:
        linear-gradient(135deg, rgba(255, 138, 42, .78), rgba(213, 83, 20, .56)) !important;
    border-color: rgba(255, 174, 104, .42) !important;
    color: #120703 !important;
    font-weight: 650 !important;
    box-shadow:
        0 10px 24px rgba(255, 122, 26, .14),
        inset 0 1px 0 rgba(255, 255, 255, .18) !important;
}

.topbar-actions .top-add-btn[href="/add-channel"]:hover,
.topbar-actions .top-add-btn.admin-direct-add:hover,
.side-action.vip:hover {
    background:
        linear-gradient(135deg, rgba(255, 146, 50, .86), rgba(213, 83, 20, .64)) !important;
    border-color: rgba(255, 190, 126, .52) !important;
    color: #100602 !important;
    box-shadow:
        0 12px 28px rgba(255, 122, 26, .18),
        inset 0 1px 0 rgba(255, 255, 255, .22) !important;
}

/* =========================================================
   TYPOGRAPHY MIX
   ========================================================= */

:root {
    --font-body: "Segoe UI", Roboto, Arial, sans-serif;
    --font-display: "Trebuchet MS", "Segoe UI", Arial, sans-serif;
    --font-tech: Consolas, "Cascadia Mono", "Courier New", monospace;
}

body,
input,
textarea,
select,
button {
    font-family: var(--font-body) !important;
}

.hero h1,
.channel-detail h1,
.profile-info h1,
.admin-channels-hero h1,
.tg-manager-hero h1,
.legal-card h1,
.block-title h2,
.recommended-title h2,
.admin-section-title h2,
.adult-category-dialog h2 {
    font-family: var(--font-display) !important;
    font-weight: 520 !important;
}

.brand span,
.mobile-top-brand span,
.site-footer-brand span,
.topbar-title,
.side-title,
.eyebrow,
.detail-category,
.category,
.channel-card .category,
.recommended-card .category,
.recommend-badge,
.vip-badge,
.vip-until,
.admin-badge,
.tg-log-title,
.tg-control-field span,
.tg-progress-text,
.stats span,
.channel-detail .stats div,
.admin-metric-card strong,
.admin-online-card strong,
.admin-period-card strong {
    font-family: var(--font-tech) !important;
}

.channel-title,
.recommended-card .channel-title,
.channel-card h3,
.recommended-card h3,
.admin-channel-title h3,
.admin-user-top h3,
.submission-header h3 {
    font-family: var(--font-display) !important;
}

.channel-username,
.profile-meta,
.tg-log-body,
.tg-history-item span,
.legal-date {
    font-family: var(--font-tech) !important;
}

/* =========================================================
   BRIGHTER CHANNEL OUTLINES
   ========================================================= */

.channel-card,
.recommended-card,
.admin-channel-card {
    border-color: rgba(255, 204, 112, .28) !important;
    box-shadow:
        0 18px 44px rgba(0, 0, 0, .32),
        0 0 24px rgba(255, 92, 168, .075),
        inset 0 1px 0 rgba(255, 228, 140, .08) !important;
}

.channel-card:not(.vip-card),
.recommended-card:not(.vip-card),
.admin-channel-card:not(.vip-card) {
    background:
        linear-gradient(145deg, rgba(255, 226, 122, .045), rgba(255, 86, 166, .032) 48%, rgba(255,255,255,.018)),
        radial-gradient(circle at 84% 12%, rgba(255, 92, 168, .08), transparent 38%),
        rgba(3, 3, 3, .56) !important;
    border-color: rgba(255, 191, 91, .34) !important;
}

.channel-card:not(.vip-card):hover,
.recommended-card:not(.vip-card):hover,
.admin-channel-card:not(.vip-card):hover {
    border-color: rgba(255, 111, 185, .62) !important;
    box-shadow:
        0 22px 54px rgba(0, 0, 0, .36),
        0 0 30px rgba(255, 111, 185, .16),
        inset 0 1px 0 rgba(255, 230, 150, .11) !important;
}

.vip-card,
.admin-channel-card.vip-card {
    background:
        linear-gradient(145deg, rgba(183, 255, 75, .065), rgba(255,255,255,.014) 46%, rgba(104, 255, 126, .035)),
        radial-gradient(circle at 82% 12%, rgba(190, 255, 79, .105), transparent 42%),
        rgba(3, 4, 2, .58) !important;
    border-color: rgba(190, 255, 79, .52) !important;
    box-shadow:
        0 18px 46px rgba(0, 0, 0, .34),
        0 0 30px rgba(190, 255, 79, .14),
        inset 0 1px 0 rgba(230, 255, 150, .13) !important;
}

.vip-card:hover,
.admin-channel-card.vip-card:hover {
    border-color: rgba(210, 255, 92, .82) !important;
    box-shadow:
        0 24px 58px rgba(0, 0, 0, .38),
        0 0 36px rgba(190, 255, 79, .24),
        inset 0 1px 0 rgba(235, 255, 165, .16) !important;
}

.vip-badge,
.channel-card .vip-label,
.channel-vip-badge,
.vip-until,
.admin-card-action.vip {
    background: rgba(190, 255, 79, .105) !important;
    border-color: rgba(190, 255, 79, .48) !important;
    color: #d9ff73 !important;
}

.recommend-badge {
    background: rgba(255, 92, 168, .09) !important;
    border-color: rgba(255, 191, 91, .42) !important;
    color: #ffd075 !important;
}

/* =========================================================
   SOFTER CARD GLOW + LIME RECOMMENDATIONS
   ========================================================= */

.channel-card,
.admin-channel-card {
    box-shadow:
        0 14px 34px rgba(0, 0, 0, .30),
        0 0 12px rgba(255, 92, 168, .045),
        inset 0 1px 0 rgba(255, 228, 140, .06) !important;
}

.channel-card:not(.vip-card):hover,
.admin-channel-card:not(.vip-card):hover {
    box-shadow:
        0 18px 42px rgba(0, 0, 0, .34),
        0 0 16px rgba(255, 111, 185, .095),
        inset 0 1px 0 rgba(255, 230, 150, .08) !important;
}

.recommended-card {
    background:
        linear-gradient(145deg, rgba(183, 255, 75, .055), rgba(255,255,255,.014) 46%, rgba(104, 255, 126, .028)),
        radial-gradient(circle at 82% 12%, rgba(190, 255, 79, .085), transparent 42%),
        rgba(3, 4, 2, .56) !important;
    border-color: rgba(190, 255, 79, .48) !important;
    box-shadow:
        0 14px 34px rgba(0, 0, 0, .30),
        0 0 14px rgba(190, 255, 79, .095),
        inset 0 1px 0 rgba(230, 255, 150, .10) !important;
}

.recommended-card:hover {
    border-color: rgba(210, 255, 92, .72) !important;
    box-shadow:
        0 18px 42px rgba(0, 0, 0, .34),
        0 0 18px rgba(190, 255, 79, .15),
        inset 0 1px 0 rgba(235, 255, 165, .13) !important;
}

.vip-card,
.admin-channel-card.vip-card {
    box-shadow:
        0 14px 36px rgba(0, 0, 0, .32),
        0 0 16px rgba(190, 255, 79, .12),
        inset 0 1px 0 rgba(230, 255, 150, .11) !important;
}

.vip-card:hover,
.admin-channel-card.vip-card:hover {
    box-shadow:
        0 18px 44px rgba(0, 0, 0, .36),
        0 0 20px rgba(190, 255, 79, .18),
        inset 0 1px 0 rgba(235, 255, 165, .14) !important;
}

.recommend-badge {
    background: rgba(190, 255, 79, .09) !important;
    border-color: rgba(190, 255, 79, .42) !important;
    color: #d9ff73 !important;
}

/* =========================================================
   OUTLINE ONLY CARDS
   ========================================================= */

.channel-card,
.recommended-card,
.admin-channel-card,
.channel-card:hover,
.recommended-card:hover,
.admin-channel-card:hover {
    box-shadow:
        0 14px 30px rgba(0, 0, 0, .28),
        0 0 10px rgba(255, 178, 112, .055),
        inset 0 1px 0 rgba(255, 255, 255, .045) !important;
}

.channel-card:not(.vip-card),
.admin-channel-card:not(.vip-card) {
    border-color: rgba(255, 181, 92, .42) !important;
}

.channel-card:not(.vip-card):hover,
.admin-channel-card:not(.vip-card):hover {
    border-color: rgba(255, 116, 186, .58) !important;
}

.recommended-grid .recommended-card,
.recommended-grid .recommended-card:not(.vip-card),
#recommendedContainer .channel-card.vip-card,
.vip-card,
.admin-channel-card.vip-card {
    border-width: 2px !important;
    border-color: rgba(190, 255, 79, .62) !important;
    box-shadow:
        0 14px 30px rgba(0, 0, 0, .28),
        0 0 18px rgba(190, 255, 79, .18),
        inset 0 1px 0 rgba(255, 255, 255, .045) !important;
}

.recommended-grid .recommended-card:hover,
.recommended-grid .recommended-card:not(.vip-card):hover,
#recommendedContainer .channel-card.vip-card:hover,
.vip-card:hover,
.admin-channel-card.vip-card:hover {
    border-color: rgba(210, 255, 92, .82) !important;
    box-shadow:
        0 16px 34px rgba(0, 0, 0, .31),
        0 0 22px rgba(190, 255, 79, .24),
        inset 0 1px 0 rgba(255, 255, 255, .055) !important;
}

.recommend-badge,
.vip-badge,
.channel-card .vip-label,
.channel-vip-badge,
.vip-until,
.admin-card-action.vip {
    border-color: rgba(190, 255, 79, .50) !important;
    box-shadow: none !important;
}

/* =========================================================
   NEUTRAL GLASS CARD BACKGROUNDS
   ========================================================= */

.channel-card,
.recommended-card,
.admin-channel-card,
.channel-card:not(.vip-card),
.recommended-card:not(.vip-card),
.admin-channel-card:not(.vip-card),
.vip-card,
.admin-channel-card.vip-card,
#recommendedContainer .channel-card.vip-card {
    background:
        linear-gradient(145deg, rgba(255, 255, 255, .052), rgba(255, 255, 255, .014) 48%, rgba(255, 255, 255, .028)),
        rgba(0, 0, 0, .52) !important;
}

.channel-card:hover,
.recommended-card:hover,
.admin-channel-card:hover,
.channel-card:not(.vip-card):hover,
.recommended-card:not(.vip-card):hover,
.admin-channel-card:not(.vip-card):hover,
.vip-card:hover,
.admin-channel-card.vip-card:hover,
#recommendedContainer .channel-card.vip-card:hover {
    background:
        linear-gradient(145deg, rgba(255, 255, 255, .06), rgba(255, 255, 255, .018) 48%, rgba(255, 255, 255, .032)),
        rgba(0, 0, 0, .58) !important;
}

/* =========================================================
   STATIC GRADIENT OUTLINE FOR REGULAR CARDS
   ========================================================= */

.channel-card:not(.vip-card),
.admin-channel-card:not(.vip-card) {
    border-color: transparent !important;
}

.channel-card:not(.vip-card):hover,
.admin-channel-card:not(.vip-card):hover {
    border-color: transparent !important;
}

.channel-card:not(.vip-card)::before,
.admin-channel-card:not(.vip-card)::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 6;
    pointer-events: none;
    border-radius: inherit;
    padding: 2px;
    background:
        linear-gradient(135deg, rgba(255, 214, 102, .82), rgba(255, 93, 181, .76));
    box-shadow: 0 0 20px rgba(255, 93, 181, .18);
    -webkit-mask:
        linear-gradient(#000 0 0) content-box,
        linear-gradient(#000 0 0);
    -webkit-mask-composite: xor;
    mask:
        linear-gradient(#000 0 0) content-box,
        linear-gradient(#000 0 0);
    mask-composite: exclude;
}

.channel-card:not(.vip-card):hover::before,
.admin-channel-card:not(.vip-card):hover::before {
    background:
        linear-gradient(135deg, rgba(255, 214, 102, .82), rgba(255, 93, 181, .76));
    box-shadow: 0 0 24px rgba(255, 93, 181, .22);
}

/* =========================================================
   SECTION ICON BACKPLATES
   ========================================================= */

.block-title .block-icon {
    position: relative;
    z-index: 0;
    width: 38px;
    height: 38px;
    overflow: hidden;
    border-radius: 8px;
    border-color: transparent !important;
    border-width: 0;
    background:
        linear-gradient(145deg, rgba(255,255,255,.07), rgba(255,255,255,.014)),
        rgba(0, 0, 0, .52) !important;
    box-shadow:
        0 8px 18px rgba(0, 0, 0, .22),
        inset 0 1px 0 rgba(255,255,255,.08) !important;
}

.block-title .block-icon::before {
    content: "";
    position: absolute;
    inset: 5px;
    z-index: -1;
    border-radius: 6px;
    opacity: .75;
}

.recommended-title .block-icon {
    color: #d9ff73 !important;
    border-color: transparent !important;
    background:
        radial-gradient(circle at 50% 50%, rgba(190,255,79,.15), rgba(190,255,79,.035) 54%, transparent 72%),
        linear-gradient(145deg, rgba(255,255,255,.07), rgba(255,255,255,.014)),
        rgba(0, 0, 0, .52) !important;
}

.recommended-title .block-icon::before {
    background:
        radial-gradient(circle, rgba(190,255,79,.24), rgba(190,255,79,.055) 58%, transparent 70%);
    box-shadow: 0 0 12px rgba(190, 255, 79, .10);
}

.channels-head .block-title:not(.recommended-title) .block-icon {
    color: #ffd66a !important;
    border-color: transparent !important;
    background:
        radial-gradient(circle at 50% 50%, rgba(255,93,181,.12), rgba(255,214,102,.04) 54%, transparent 72%),
        linear-gradient(145deg, rgba(255,255,255,.07), rgba(255,255,255,.014)),
        rgba(0, 0, 0, .52) !important;
}

.channels-head .block-title:not(.recommended-title) .block-icon::before {
    background:
        radial-gradient(circle, rgba(255,93,181,.20), rgba(255,214,102,.075) 58%, transparent 70%);
    box-shadow: 0 0 12px rgba(255, 93, 181, .09);
}

/* =========================================================
   GLASS CATEGORY BUTTONS
   ========================================================= */

.category-btn {
    isolation: isolate;
    overflow: hidden;
    border-color: transparent !important;
    background:
        linear-gradient(145deg, rgba(255,255,255,.045), rgba(255,255,255,.012)),
        rgba(0, 0, 0, .44) !important;
    box-shadow:
        0 8px 18px rgba(0,0,0,.18),
        inset 0 1px 0 rgba(255,255,255,.035) !important;
}

.category-btn::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    border-radius: inherit;
    padding: 1px;
    background:
        linear-gradient(135deg, rgba(255, 214, 102, .34), rgba(255, 93, 181, .24));
    -webkit-mask:
        linear-gradient(#000 0 0) content-box,
        linear-gradient(#000 0 0);
    -webkit-mask-composite: xor;
    mask:
        linear-gradient(#000 0 0) content-box,
        linear-gradient(#000 0 0);
    mask-composite: exclude;
}

.category-btn:hover,
.category-btn.active {
    background:
        linear-gradient(145deg, rgba(255,255,255,.06), rgba(255,255,255,.016)),
        rgba(0, 0, 0, .52) !important;
}

.category-btn:hover::after,
.category-btn.active::after {
    background:
        linear-gradient(135deg, rgba(255, 214, 102, .54), rgba(255, 93, 181, .42));
}

.category-btn.active::before {
    left: 0;
    top: 9px;
    bottom: 9px;
    width: 3px;
    border-radius: 999px;
    background:
        linear-gradient(180deg, rgba(255,214,102,.95), rgba(255,93,181,.78)) !important;
    box-shadow: 0 0 10px rgba(255, 122, 26, .22) !important;
}

/* =========================================================
   ADMIN STATS RESET
   ========================================================= */

.admin-stats-message {
    margin: 14px 0 0;
    padding: 12px 14px;
    border: 1px solid rgba(190, 255, 79, .34);
    background: rgba(18, 30, 10, .42);
    color: #caff66;
    font-size: 13px;
    font-weight: 800;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.admin-stats-reset-form {
    display: flex;
    justify-content: flex-end;
    margin-top: 18px;
}

.admin-stats-reset-form button {
    min-height: 44px;
    padding: 0 22px;
    border: 1px solid rgba(255, 92, 92, .38);
    border-radius: 8px;
    background:
        linear-gradient(135deg, rgba(255, 122, 26, .14), rgba(255, 72, 120, .08)),
        rgba(0, 0, 0, .46);
    color: #ffb4a8;
    box-shadow:
        0 0 16px rgba(255, 72, 120, .08),
        inset 0 1px 0 rgba(255,255,255,.04);
    font-size: 12px;
    font-weight: 900;
    letter-spacing: .08em;
    text-transform: uppercase;
    cursor: pointer;
}

.admin-stats-reset-form button:hover {
    border-color: rgba(255, 120, 120, .64);
    color: #fff;
    background:
        linear-gradient(135deg, rgba(255, 122, 26, .22), rgba(255, 72, 120, .14)),
        rgba(0, 0, 0, .58);
}

@media (max-width: 768px) {
    .admin-stats-reset-form {
        justify-content: stretch;
    }

    .admin-stats-reset-form button {
        width: 100%;
    }
}

@media (min-width: 769px) and (max-width: 1180px) {
    .recommended-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

/* =========================================================
   COMPACT CHANNEL DETAIL AND MODERATION LINKS
   ========================================================= */

.channel-primary-action {
    width: fit-content;
    min-width: 210px;
    height: 48px;
    margin-top: 20px;
    padding: 0 18px;
    justify-content: center;
}

.channel-primary-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 20px;
}

.channel-primary-actions .channel-primary-action {
    margin-top: 0;
}

.channel-back-action {
    min-width: 120px;
    height: 48px;
    justify-content: center;
}

.telegram-button-icon,
.submission-telegram-open > span {
    font-size: 17px;
    line-height: 1;
    transform: rotate(-18deg);
}

.channel-description-compact {
    display: -webkit-box;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    max-width: 100%;
    margin: 18px 0 0;
    color: rgba(255, 245, 238, .66);
    line-height: 1.55;
}

.channel-card p,
.recommended-card p {
    min-height: 48px;
    -webkit-line-clamp: 2;
    line-clamp: 2;
}

.channel-detail .detail-stats {
    margin-top: 24px;
}

.channel-detail .detail-stats.public-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.channel-detail .detail-actions {
    margin-top: 18px;
}

.channel-detail > .detail-actions {
    display: none;
}

.submission-telegram-field {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px;
}

.submission-telegram-open {
    min-height: 48px;
    padding: 0 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border: 1px solid rgba(255, 138, 42, .55);
    border-radius: 8px;
    background: rgba(255, 122, 26, .10);
    color: #ffb066;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .05em;
    text-decoration: none;
    text-transform: uppercase;
}

.submission-telegram-open:hover {
    border-color: rgba(255, 174, 104, .82);
    background: rgba(255, 122, 26, .18);
    color: #fff;
}

.channel-username-link {
    display: block;
    width: fit-content;
    color: rgba(255, 255, 255, .54) !important;
    text-decoration: none;
}

.channel-username-link:hover,
.admin-channel-telegram-link:hover {
    color: #ffb066 !important;
    text-decoration: underline;
    text-underline-offset: 4px;
}

.admin-channel-card {
    position: relative;
    cursor: pointer;
}

.admin-channel-card-link {
    position: absolute;
    inset: 0;
    z-index: 1;
    border-radius: inherit;
}

.admin-channel-card-actions,
.admin-channel-telegram-link {
    position: relative;
    z-index: 2;
}

.admin-channel-telegram-link {
    display: inline-block;
    color: inherit;
    text-decoration: none;
}

.profile-channel-card {
    position: relative;
    overflow: hidden;
}

.profile-channel-card .submission-header,
.profile-channel-card .profile-channel-description,
.profile-channel-card .submission-date {
    position: relative;
    z-index: 2;
}

.profile-channel-link {
    position: absolute;
    inset: 0;
    z-index: 1;
    border-radius: inherit;
}

.profile-channel-head {
    display: flex;
    align-items: center;
    gap: 14px;
}

.profile-channel-avatar {
    width: 48px;
    height: 48px;
    flex: 0 0 48px;
    border: 1px solid rgba(255, 138, 42, .34);
    border-radius: 12px;
    background: rgba(0, 0, 0, .36);
    display: grid;
    place-items: center;
    overflow: hidden;
}

.profile-channel-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.profile-channel-avatar span {
    color: rgba(255, 255, 255, .8);
    font-size: 18px;
}

.profile-channel-description {
    display: -webkit-box;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    max-width: 100%;
}

.profile-channel-card .submission-date {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.profile-channel-card .channel-username-link {
    position: relative;
    z-index: 3;
}

@media (max-width: 768px) {
    .channel-primary-actions {
        width: 100%;
        gap: 8px;
    }

    .channel-primary-actions .detail-action-btn {
        width: auto !important;
        min-width: 0 !important;
        height: 48px;
        padding: 0 12px;
        font-size: 11px;
        letter-spacing: .04em;
        white-space: nowrap;
    }

    .channel-primary-actions .channel-primary-action {
        flex: 1 1 0;
    }

    .channel-primary-actions .channel-back-action {
        flex: 0 0 88px;
    }

    .channel-description-compact {
        -webkit-line-clamp: 2;
        line-clamp: 2;
        margin-top: 14px;
    }

    .submission-telegram-field {
        grid-template-columns: 1fr;
    }

    .submission-telegram-open {
        width: 100%;
    }
}

/* =========================================================
   FINAL ALIGNMENT PASS
   ========================================================= */

.content,
.admin-channels-page,
.admin-users-page,
.profile-page,
.channel-page,
.legal-page,
.admin-page {
    min-width: 0;
    max-width: 100%;
    box-sizing: border-box;
}

.admin-channel-search,
.admin-channel-grid,
.admin-users-grid,
.channels-grid,
.recommended-grid,
.admin-tools-grid,
.admin-stats-grid {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    box-sizing: border-box;
}

.admin-users-page {
    width: 100% !important;
    max-width: 1480px;
    margin-inline: auto;
}

.admin-channel-search {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(116px, max-content);
    gap: 14px;
    align-items: stretch;
}

.admin-channel-search input {
    min-width: 0;
}

.admin-channel-search button {
    min-width: 116px;
    width: auto;
}

.admin-channel-grid {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)) !important;
    gap: 24px !important;
    align-items: stretch;
}

.admin-users-grid {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)) !important;
    gap: 24px !important;
    align-items: stretch;
}

.channels-grid {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)) !important;
    align-items: stretch;
}

.recommended-grid {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)) !important;
    align-items: stretch;
}

.admin-channel-card,
.channel-card,
.recommended-card,
.admin-user-card {
    min-width: 0 !important;
    width: 100% !important;
    max-width: 100%;
    box-sizing: border-box;
}

.admin-user-card {
    min-height: 400px;
    display: grid !important;
    grid-template-rows: auto auto 1fr auto;
    align-content: stretch;
}

.admin-user-top {
    min-width: 0;
    align-items: flex-start;
}

.admin-user-top > div:not(.admin-user-avatar):not(.admin-user-role),
.admin-user-top h3,
.admin-user-meta span {
    min-width: 0;
    max-width: 100%;
}

.admin-user-top h3 {
    display: -webkit-box;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    line-clamp: 2;
}

.admin-user-role {
    justify-self: end;
    max-width: 86px;
    overflow: hidden;
    text-overflow: ellipsis;
}

.admin-user-meta span {
    overflow-wrap: anywhere;
}

.admin-user-actions {
    margin-top: auto !important;
}

.admin-channel-card {
    min-height: 430px;
    padding: 28px !important;
    display: grid !important;
    grid-template-rows: auto minmax(72px, auto) auto auto auto;
    align-content: stretch;
    gap: 16px;
}

.admin-channel-card-top {
    min-width: 0;
    align-items: flex-start;
}

.admin-channel-title,
.admin-channel-title h3,
.admin-channel-title span,
.admin-channel-telegram-link {
    min-width: 0;
    max-width: 100%;
}

.admin-channel-title h3 {
    display: -webkit-box;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    line-clamp: 2;
}

.admin-channel-card p {
    min-height: 72px;
    max-height: 72px;
    display: -webkit-box;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    line-clamp: 3;
}

.admin-channel-meta {
    align-self: end;
    margin-top: 0 !important;
}

.admin-channel-card-actions {
    margin-top: auto;
}

.admin-channel-card-actions form {
    min-width: 0;
}

.admin-channel-card-actions .vip-duration-form {
    display: grid !important;
    grid-template-columns: minmax(84px, 112px) minmax(0, 1fr);
    gap: 10px;
}

.admin-channel-card-actions .vip-duration-form label,
.admin-channel-card-actions .admin-card-action,
.admin-channel-card-actions button {
    min-width: 0;
    width: 100%;
}

.channel-card,
.recommended-card {
    display: flex;
    flex-direction: column;
}

.channel-card p,
.recommended-card p {
    max-height: 48px;
}

.channel-card .stats,
.recommended-card .stats {
    margin-top: auto;
}

@media (max-width: 768px) {
    .admin-channel-grid,
    .admin-users-grid,
    .channels-grid,
    .recommended-grid {
        grid-template-columns: 1fr !important;
    }

    .admin-channel-search {
        grid-template-columns: 1fr;
    }

    .admin-channel-search button {
        width: 100%;
    }

    .admin-channel-card {
        min-height: 0;
        padding: 20px !important;
    }

    .admin-user-card {
        min-height: 0;
    }

    .admin-channel-card-actions .vip-duration-form {
        grid-template-columns: 1fr;
    }
}

/* Webmaster mobile safety: prevent wide controls/media from breaking viewport. */
html,
body {
    max-width: 100%;
}

img,
video,
canvas,
svg {
    max-width: 100%;
}

input,
select,
textarea,
button {
    max-width: 100%;
}

table {
    max-width: 100%;
}

@media (max-width: 900px) {
    .app,
    .content,
    main,
    section,
    article,
    form {
        max-width: 100%;
        min-width: 0;
        box-sizing: border-box;
    }

    .content {
        overflow-x: clip;
    }

    .channel-page,
    .profile-page,
    .legal-page,
    .channels-head,
    .hero,
    .channel-detail,
    .admin-page {
        width: 100%;
        max-width: 100%;
        min-width: 0;
    }
}
