@font-face {
    font-family: "IRANSansXV";
    src: url("../fonts/IRANSansXV.woff") format("woff");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

:root {
    color-scheme: dark;
    --primary: #7c3aed;
    --indigo: #4f46e5;
    --blue: #2563eb;
    --cyan: #06b6d4;
    --bg: #0a0e27;
    --bg-soft: #0f1530;
    --surface: #111c3a;
    --surface-strong: #141e3a;
    --surface-soft: #1a2847;
    --surface-muted: #1f3555;
    --border: rgba(124, 58, 237, 0.25);
    --border-strong: rgba(124, 58, 237, 0.4);
    --text: #e2e8f0;
    --text-muted: #94a3b8;
    --success: #10b981;
    --danger: #ef4444;
    --warning: #f59e0b;
    --shadow-lg: 0 24px 80px rgba(2, 6, 23, 0.45);
    --shadow-md: 0 14px 36px rgba(2, 6, 23, 0.3);
    --radius-xl: 24px;
    --radius-lg: 18px;
    --radius-md: 14px;
}

* {
    box-sizing: border-box;
}

html,
body,
input,
textarea,
select,
button,
option,
optgroup,
table,
.admin-layout,
.form-control {
    font-family: "IRANSansXV", Tahoma, Arial, sans-serif;
}

html,
body {
    overflow-x: hidden;
}

input[type="file"] {
    width: 100%;
    padding: 0.22rem;
    border: 1px solid rgba(129, 140, 248, 0.28);
    border-radius: 12px;
    background: rgba(15, 23, 42, 0.88);
    color: #e2e8f0;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03);
}

input[type="file"]:focus {
    outline: none;
    border-color: rgba(124, 58, 237, 0.72);
    box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.18);
}

input[type="file"]::file-selector-button {
    margin-inline-end: 0.75rem;
    padding: 0.62rem 0.95rem;
    border: 1px solid rgba(124, 58, 237, 0.45);
    border-radius: 10px;
    background: linear-gradient(135deg, #7c3aed, #4f46e5);
    color: #ffffff;
    font: inherit;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 10px 24px rgba(37, 99, 235, 0.2);
}

input[type="file"]::file-selector-button:hover {
    background: linear-gradient(135deg, #8b5cf6, #2563eb);
}

input[type="file"]::-webkit-file-upload-button {
    margin-inline-end: 0.75rem;
    padding: 0.62rem 0.95rem;
    border: 1px solid rgba(124, 58, 237, 0.45);
    border-radius: 10px;
    background: linear-gradient(135deg, #7c3aed, #4f46e5);
    color: #ffffff;
    font: inherit;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 10px 24px rgba(37, 99, 235, 0.2);
}

input[type="file"]::-webkit-file-upload-button:hover {
    background: linear-gradient(135deg, #8b5cf6, #2563eb);
}

html,
body {
    margin: 0;
    min-height: 100%;
    background: #0a0e27;
    color: var(--text);
    direction: rtl;
    scroll-behavior: smooth;
}

body {
    line-height: 1.7;
    position: relative;
}

body.subscription-limit-modal-open {
    overflow: hidden;
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    background: transparent;
    z-index: 0;
}

img {
    display: block;
    max-width: 100%;
}

a,
button,
input,
select,
textarea {
    transition: all 0.22s ease;
}

.page-shell,
.admin-shell {
    position: relative;
    z-index: 1;
    min-width: 0;
}

.page-shell {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.85rem;
    padding: 0.8rem 1.35rem;
    margin: 0.67rem;
    border: 1px solid rgba(124, 58, 237, 0.25);
    border-radius: 18px;
    background: #111c3a;
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow-md);
}

.brand,
.admin-sidebar-brand-main,
.topbar-brand,
.login-brand {
    display: flex;
    align-items: center;
    gap: 0.71rem;
}

.brand-copy,
.topbar-brand-copy,
.login-brand-copy {
    display: grid;
    gap: 0.11rem;
}

.brand-mark {
    color: #dbeafe;
    font-size: 0.63rem;
    letter-spacing: 0.135em;
    font-weight: 700;
}

.brand-text {
    font-size: 0.74rem;
    font-weight: 700;
}

.brand-logo,
.sidebar-logo,
.topbar-logo,
.login-logo,
.hero-logo {
    width: 39px;
    height: 39px;
    object-fit: contain;
    border-radius: 12px;
    padding: 0.31rem;
    background: linear-gradient(135deg, rgba(124, 58, 237, 0.18), rgba(37, 99, 235, 0.12));
    border: 1px solid rgba(129, 140, 248, 0.24);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.sidebar-logo {
    width: 43px;
    height: 43px;
}

.topbar-logo {
    width: 31px;
    height: 31px;
    border-radius: 10px;
}

.login-logo {
    width: 49px;
    height: 49px;
    border-radius: 13px;
}

.hero-logo {
    width: 53px;
    height: 53px;
    border-radius: 15px;
}

.nav-links {
    display: flex;
    gap: 0.6rem;
    flex-wrap: wrap;
}

.nav-links a {
    color: var(--text);
    text-decoration: none;
    padding: 0.585rem 0.75rem;
    border-radius: 999px;
    border: 1px solid transparent;
}

.nav-links a:hover {
    background: rgba(124, 58, 237, 0.12);
    border-color: rgba(129, 140, 248, 0.18);
}

.nav-form {
    margin: 0;
}

.content {
    flex: 1;
    width: 100%;
    margin: 0;
    padding: 0.35rem 0 1rem;
}

.footer {
    padding: 0.67rem 1.2rem 1.2rem;
    text-align: center;
    color: var(--text-muted);
}

.hero {
    display: grid;
    grid-template-columns: minmax(0, 0.81fr) minmax(216px, 0.54fr);
    gap: 1.35rem;
    align-items: center;
    padding: 0.67rem 0 1.35rem;
}

.hero-copy,
.hero-card {
    padding: 1.35rem;
    border-radius: 19px;
    background: #111c3a;
    border: 1px solid rgba(124, 58, 237, 0.3);
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow-lg);
}

.hero-card {
    display: grid;
    gap: 0.75rem;
    position: relative;
    overflow: hidden;
}

.hero-card::after {
    content: "";
    position: absolute;
    inset: auto -10% -20% auto;
    width: 180px;
    height: 180px;
    background: radial-gradient(circle, rgba(6, 182, 212, 0.26), transparent 70%);
    pointer-events: none;
}

.eyebrow {
    margin: 0 0 0.8rem;
    color: #c4b5fd;
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 0.2em;
}

h1 {
    margin: 0;
    font-size: clamp(2.4rem, 4vw, 4.2rem);
    line-height: 1.2;
}

.hero-text {
    margin: 1.1rem 0 1.6rem;
    max-width: 45rem;
    color: var(--text-muted);
    font-size: 1.03rem;
}

.hero-actions,
.panel-actions,
.table-actions,
.filter-actions,
.form-actions-inline {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
    align-items: center;
}

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.45rem;
    min-height: 2rem;
    padding: 0 0.85rem;
    border: 1px solid transparent;
    border-radius: 999px;
    cursor: pointer;
    text-decoration: none;
    font: inherit;
    font-weight: 700;
    letter-spacing: 0.01em;
    box-shadow: 0 10px 24px rgba(2, 6, 23, 0.16);
}

.button:hover {
    transform: translateY(-0.5px);
    box-shadow: 0 16px 34px rgba(2, 6, 23, 0.24);
}

.button-primary {
    color: #fff;
    background: #7c3aed;
    border-color: rgba(124, 58, 237, 0.5);
}

.button-secondary {
    color: var(--text);
    background: rgba(51, 65, 85, 0.42);
    border-color: rgba(148, 163, 184, 0.16);
}

.button-danger {
    color: #fee2e2;
    background: #dc2626;
    border-color: rgba(248, 113, 113, 0.4);
}

.button-small {
    min-height: 1.66rem;
    padding: 0 0.67rem;
    font-size: 0.62rem;
    border-radius: 9px;
}

.is-disabled {
    opacity: 0.52;
    pointer-events: none;
}

.button-disabled {
    opacity: 0.58;
    cursor: not-allowed;
}

.button-disabled:hover {
    transform: none;
    box-shadow: 0 10px 24px rgba(2, 6, 23, 0.16);
}

.subscription-warning-card {
    margin-bottom: 1rem;
    padding: 1rem 1.1rem;
    border-radius: 18px;
    background: linear-gradient(135deg, rgba(124, 58, 237, 0.18), rgba(37, 99, 235, 0.14));
    border: 1px solid rgba(129, 140, 248, 0.28);
    box-shadow: var(--shadow-md);
}

.subscription-warning-card-normal {
    margin-bottom: 0;
    min-height: 100%;
    background: linear-gradient(135deg, rgba(124, 58, 237, 0.12), rgba(79, 70, 229, 0.1));
    border-color: rgba(129, 140, 248, 0.22);
}

.subscription-warning-card-expiring-soon {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.16), rgba(124, 58, 237, 0.12));
    border-color: rgba(251, 191, 36, 0.32);
}

.subscription-warning-card-expired {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.18), rgba(124, 58, 237, 0.12));
    border-color: rgba(248, 113, 113, 0.34);
}

.subscription-warning-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.subscription-warning-header h3 {
    margin: 0 0 0.3rem;
}

.subscription-warning-header p {
    margin: 0;
    color: var(--muted);
}

.subscription-warning-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 0.9rem;
}

.subscription-warning-meta {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.75rem;
    margin-top: 0.95rem;
}

.subscription-warning-metric {
    padding: 0.78rem 0.85rem;
    border-radius: 14px;
    background: rgba(15, 23, 42, 0.32);
    border: 1px solid rgba(148, 163, 184, 0.14);
}

.subscription-warning-metric span {
    display: block;
    color: var(--text-muted);
    font-size: 0.72rem;
    margin-bottom: 0.22rem;
}

.subscription-warning-metric strong {
    display: block;
    color: var(--text);
    font-size: 0.95rem;
}

.subscription-warning-item {
    padding: 0.55rem 0.8rem;
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.5);
    border: 1px solid rgba(148, 163, 184, 0.18);
    color: var(--text);
    font-size: 0.78rem;
}

.subscription-limit-modal[hidden] {
    display: none !important;
}

.subscription-limit-modal {
    position: fixed;
    inset: 0;
    z-index: 100000;
}

.subscription-limit-modal__overlay {
    position: absolute;
    inset: 0;
    background: rgba(2, 6, 23, 0.72);
    backdrop-filter: blur(8px);
    animation: subscriptionModalFade 0.18s ease;
}

.subscription-limit-modal__dialog {
    position: relative;
    width: min(92vw, 520px);
    margin: 8vh auto 0;
    padding: 1rem;
    border-radius: 24px;
    background: linear-gradient(180deg, rgba(26, 40, 71, 0.98), rgba(15, 23, 42, 0.97));
    border: 1px solid rgba(129, 140, 248, 0.28);
    box-shadow: 0 30px 90px rgba(2, 6, 23, 0.55);
    animation: subscriptionModalPop 0.22s ease;
}

.subscription-limit-modal__close {
    position: absolute;
    top: 0.7rem;
    left: 0.7rem;
    width: 2rem;
    height: 2rem;
    border: 0;
    border-radius: 999px;
    background: rgba(148, 163, 184, 0.12);
    color: #e2e8f0;
    font-size: 1.15rem;
    line-height: 1;
}

.subscription-limit-modal__hero {
    display: flex;
    align-items: flex-start;
    gap: 0.85rem;
    padding: 0.95rem;
    border-radius: 18px;
    background: linear-gradient(135deg, rgba(124, 58, 237, 0.22), rgba(37, 99, 235, 0.14));
    border: 1px solid rgba(129, 140, 248, 0.22);
}

.subscription-limit-modal__icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2.7rem;
    height: 2.7rem;
    border-radius: 16px;
    background: rgba(245, 158, 11, 0.18);
    color: #fbbf24;
    font-size: 1.35rem;
    font-weight: 700;
    flex-shrink: 0;
}

.subscription-limit-modal__hero h3 {
    margin: 0 0 0.25rem;
    font-size: 1rem;
}

.subscription-limit-modal__hero p,
.subscription-limit-modal__note {
    margin: 0;
    color: var(--text-muted);
}

.subscription-limit-modal__usage {
    margin-top: 0.9rem;
    padding: 0.9rem;
    border-radius: 16px;
    background: rgba(15, 23, 42, 0.52);
    border: 1px solid rgba(148, 163, 184, 0.16);
}

.subscription-limit-modal__usage-label {
    margin-bottom: 0.3rem;
    color: #c4b5fd;
    font-size: 0.74rem;
}

.subscription-limit-modal__usage-text {
    color: var(--text);
    font-size: 0.88rem;
    font-weight: 700;
}

.subscription-limit-modal__note {
    margin-top: 0.9rem;
}

.subscription-limit-modal__actions {
    display: flex;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 0.7rem;
    margin-top: 1rem;
}

@keyframes subscriptionModalFade {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes subscriptionModalPop {
    from {
        opacity: 0;
        transform: translateY(10px) scale(0.98);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.card,
.feature-card,
.dashboard-card,
.auth-card,
.panel-section,
.filter-box,
.table-wrap,
.calendar-day,
.calendar-weekdays div,
.admin-topbar,
.admin-sidebar-brand,
.admin-sidebar-foot {
    backdrop-filter: blur(18px);
}

.features {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.13rem;
}

.feature-card {
    padding: 1.08rem;
    border-radius: 16px;
    background: #111c3a;
    border: 1px solid rgba(124, 58, 237, 0.3);
    box-shadow: var(--shadow-md);
    backdrop-filter: blur(10px);
}

.feature-card h3 {
    margin: 0 0 0.45rem;
}

.auth-page {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: calc(100vh - 5.4rem);
    padding: 1.35rem 0;
}

.auth-card {
    width: min(377px, 100%);
    padding: 1.52rem;
    border-radius: 19px;
    background: #111c3a;
    border: 1px solid rgba(124, 58, 237, 0.3);
    box-shadow: var(--shadow-lg);
    backdrop-filter: blur(10px);
}

.login-brand {
    margin-bottom: 0.9rem;
}

.auth-card h1 {
    margin: 0 0 0.6rem;
}

.auth-card p {
    margin: 0 0 1.2rem;
    color: var(--text-muted);
}

.auth-form,
.admin-form,
.filter-box {
    display: grid;
    gap: 0.8rem;
}

.form-group {
    display: grid;
    gap: 0.45rem;
}

.form-group label,
.search-picker-label {
    font-weight: 700;
    color: #dbeafe;
}

.form-control {
    width: 100%;
    border: 1px solid rgba(124, 58, 237, 0.3);
    border-radius: 10px;
    padding: 0.6rem 0.65rem;
    background: #1a2847;
    color: #f8fafc;
    line-height: 1.6;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03);
    -webkit-text-fill-color: #f8fafc;
    caret-color: #f8fafc;
}

select.form-control,
select,
option,
optgroup {
    font-family: "IRANSansXV", Tahoma, Arial, sans-serif !important;
    color-scheme: dark;
}

select.form-control,
select.form-control:focus,
select {
    font-family: "IRANSansXV", Tahoma, Arial, sans-serif !important;
    font-size: 0.95rem;
    font-weight: 400;
    line-height: 1.6;
    color: #e2e8f0;
    background-color: rgba(15, 23, 42, 0.72);
}

select.form-control option,
select option {
    font-family: "IRANSansXV", Tahoma, Arial, sans-serif !important;
    font-size: 0.95rem;
    font-weight: 400;
    color: #e2e8f0 !important;
    background: #1e293b !important;
}

select.form-control option:checked,
select option:checked,
select.form-control option:hover,
select option:hover {
    color: #ffffff !important;
    background: #4f46e5 !important;
}

select.form-control option[disabled],
select option[disabled] {
    color: #94a3b8 !important;
    background: #334155 !important;
}

.form-control::placeholder {
    color: #7c8ba1;
}

.form-control:focus {
    outline: none;
    border-color: rgba(124, 58, 237, 0.7);
    box-shadow: 0 0 0 4px rgba(124, 58, 237, 0.15);
    background: #1f3555;
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
}

input,
textarea,
select {
    color: #f8fafc;
    -webkit-text-fill-color: #f8fafc;
    caret-color: #f8fafc;
}

select,
select.form-control,
select option,
select optgroup,
.admin-form select,
.admin-form select option,
.filter-box select,
.filter-box select option,
.date-picker-input-group select,
.jalali-picker-select,
.mds-bootstrap-persian-datetime-picker-popover select,
.mds-bootstrap-persian-datetime-picker-popover option {
    font-family: "IRANSansXV", Tahoma, Arial, sans-serif !important;
}

#studio_id,
#studio_id option,
#studio_id optgroup {
    font-family: "IRANSansXV", Tahoma, Arial, sans-serif !important;
    font-size: 0.95rem !important;
    font-weight: 400 !important;
}

input:focus,
textarea:focus,
select:focus {
    color: #ffffff;
    -webkit-text-fill-color: #ffffff;
}

input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus,
textarea:-webkit-autofill,
textarea:-webkit-autofill:hover,
textarea:-webkit-autofill:focus {
    -webkit-text-fill-color: #f8fafc !important;
    caret-color: #f8fafc;
    -webkit-box-shadow: 0 0 0 1000px #1a2847 inset;
    box-shadow: 0 0 0 1000px #1a2847 inset;
    transition: background-color 9999s ease-out 0s;
}

.form-control[dir="ltr"] {
    text-align: left;
}

.payment-info-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 16px;
    min-width: 0;
}

.payment-info-card {
    min-width: 0;
}

.payment-info-card.is-card-number {
    grid-column: span 1;
}

.payment-card-number {
    display: block;
    direction: ltr;
    text-align: center;
    letter-spacing: 2px;
    font-size: 1.1rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.money-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    width: 100%;
}

.money-input-wrapper input {
    width: 100%;
    padding-left: 84px;
}

.money-input-suffix {
    position: absolute;
    left: 12px;
    color: #a78bfa;
    font-size: 0.85rem;
    pointer-events: none;
    background: rgba(15, 23, 42, 0.85);
    padding: 3px 8px;
    border-radius: 999px;
    border: 1px solid rgba(129, 140, 248, 0.18);
    line-height: 1.2;
}

.custom-select {
    position: relative;
    width: 100%;
}

.custom-select__native {
    position: absolute !important;
    inset: 0 !important;
    width: 100% !important;
    height: 100% !important;
    opacity: 0 !important;
    pointer-events: none !important;
}

.custom-select__trigger {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 0.7rem;
    width: 100%;
    min-height: 43px;
    padding: 0.6rem 0.8rem;
    border: 1px solid rgba(124, 58, 237, 0.3);
    border-radius: 10px;
    background: #1a2847;
    color: #f8fafc;
    text-align: right;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03);
}

.custom-select__trigger:hover,
.custom-select.is-open .custom-select__trigger {
    border-color: rgba(124, 58, 237, 0.7);
    background: #1f3555;
}

.custom-select__arrow {
    color: #c4b5fd;
    font-size: 1rem;
    line-height: 1;
}

.custom-select__dropdown {
    position: absolute;
    top: calc(100% + 0.35rem);
    right: 0;
    left: 0;
    z-index: 99999;
    display: none;
    max-height: 260px;
    overflow-y: auto;
    padding: 0.4rem;
    border-radius: 14px;
    background: rgba(15, 23, 42, 0.98);
    border: 1px solid rgba(129, 140, 248, 0.24);
    box-shadow: var(--shadow-lg);
    backdrop-filter: blur(14px);
}

.custom-select.is-open .custom-select__dropdown {
    display: grid;
    gap: 0.25rem;
}

.custom-select__option {
    width: 100%;
    padding: 0.68rem 0.8rem;
    border: 0;
    border-radius: 10px;
    background: transparent;
    color: #e2e8f0;
    text-align: right;
    font: inherit;
}

.custom-select__option:hover,
.custom-select__option.is-selected {
    background: rgba(124, 58, 237, 0.18);
    color: #ffffff;
}

.custom-select__option:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

.form-error {
    margin: 0;
    color: #fca5a5;
    font-size: 0.63rem;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.75rem 0.85rem;
}

.form-group-full {
    grid-column: 1 / -1;
}

.form-textarea {
    min-height: 5.4rem;
    resize: vertical;
}

.checkbox-field {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.65rem 0.67rem;
    border-radius: 10px;
    background: #1a2847;
    border: 1px solid rgba(124, 58, 237, 0.25);
}

.checkbox-field input {
    width: 12px;
    height: 12px;
    accent-color: var(--primary);
}

.admin-body {
    background:
        radial-gradient(circle at 12% 20%, rgba(124, 58, 237, 0.18), transparent 18%),
        radial-gradient(circle at 100% 0%, rgba(37, 99, 235, 0.16), transparent 18%),
        radial-gradient(circle at 0% 100%, rgba(6, 182, 212, 0.12), transparent 20%),
        linear-gradient(180deg, #07101d 0%, #0b1425 36%, #0f172a 100%);
}

.admin-shell {
    display: grid;
    grid-template-columns: 270px minmax(0, 1fr);
    min-height: 100vh;
    gap: 0;
    transition: grid-template-columns 0.22s ease;
}

.admin-sidebar {
    position: sticky;
    top: 0;
    z-index: 30;
    min-height: 100vh;
    padding: 0.9rem 0.77rem;
    display: flex;
    flex-direction: column;
    gap: 0.67rem;
    width: 270px;
    background: #0f1530;
    border-left: 1px solid rgba(124, 58, 237, 0.25);
    overflow: hidden;
    transition: width 0.22s ease, transform 0.22s ease, padding 0.22s ease;
}

.admin-sidebar-brand {
    padding: 0.8rem;
    border-radius: 16px;
    background: #1a2847;
    border: 1px solid rgba(124, 58, 237, 0.35);
    box-shadow: var(--shadow-md);
}

.admin-sidebar-brand {
    position: relative;
}

.admin-sidebar-brand-copy {
    display: grid;
    gap: 0.135rem;
    min-width: 0;
}

.admin-sidebar-brand p {
    margin: 0.44rem 0 0;
    color: var(--text-muted);
    font-size: 0.62rem;
}

.admin-sidebar-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.35rem;
    height: 2.35rem;
    border: 1px solid rgba(129, 140, 248, 0.2);
    border-radius: 12px;
    background: rgba(15, 23, 42, 0.48);
    color: #e9d5ff;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03);
}

.admin-sidebar-toggle:hover {
    background: rgba(31, 53, 85, 0.9);
    border-color: rgba(129, 140, 248, 0.34);
}

.admin-sidebar-toggle--inline {
    position: absolute;
    top: 0.7rem;
    left: 0.7rem;
}

.admin-menu {
    display: grid;
    gap: 0.32rem;
}

.admin-menu-link {
    display: flex;
    align-items: center;
    min-height: 2.1rem;
    padding: 0 0.67rem;
    color: var(--text);
    text-decoration: none;
    border-radius: 10px;
    border: 1px solid transparent;
    background: transparent;
}

.admin-menu-link:hover {
    background: rgba(124, 58, 237, 0.1);
    border-color: rgba(129, 140, 248, 0.16);
    transform: translateX(-1.5px);
}

.admin-menu-link.is-active {
    background: #1f3555;
    border-color: rgba(124, 58, 237, 0.5);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03), 0 12px 28px rgba(124, 58, 237, 0.15);
}

.admin-menu {
    display: grid;
    gap: 0.9rem;
}

.admin-menu-group {
    display: grid;
    gap: 0.45rem;
}

.admin-menu-group__title {
    margin: 0;
    padding: 0 0.35rem;
    color: #c4b5fd;
    font-size: 0.74rem;
    font-weight: 700;
    letter-spacing: 0.08em;
}

.admin-menu-group__items {
    display: grid;
    gap: 0.35rem;
}

.admin-menu-link {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.72rem 0.8rem;
    border-radius: 14px;
}

.admin-menu-link__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.45rem;
    height: 1.45rem;
    border-radius: 10px;
    background: rgba(124, 58, 237, 0.14);
    color: #d8b4fe;
    font-size: 0.65rem;
    line-height: 1;
    flex-shrink: 0;
}

.admin-menu-link__icon i {
    font-size: 0.95rem;
    line-height: 1;
}

.admin-menu-link.is-active .admin-menu-link__icon {
    background: linear-gradient(135deg, rgba(124, 58, 237, 0.34), rgba(79, 70, 229, 0.28));
    color: #ffffff;
}

.admin-menu-link__label {
    min-width: 0;
}

.admin-sidebar-foot {
    margin-top: auto;
    padding: 0.67rem;
    border-radius: 13px;
    background: #1a2847;
    border: 1px solid rgba(124, 58, 237, 0.25);
}

.admin-sidebar-foot p,
.admin-sidebar-foot span {
    margin: 0;
    color: var(--text-muted);
}

.admin-sidebar-foot strong {
    display: block;
    margin: 0.135rem 0;
}

.admin-main {
    width: 100%;
    margin: 0;
    padding: 0.35rem;
    min-width: 0;
    max-width: 100%;
    transition: padding 0.22s ease;
    overflow: visible;
}

.admin-topbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.3rem;
    margin-bottom: 0.35rem;
    padding: 0.3rem 0.35rem;
    border-radius: 10px;
    background: #111c3a;
    border: 1px solid rgba(124, 58, 237, 0.25);
    box-shadow: var(--shadow-md);
    min-width: 0;
    position: relative;
    overflow: visible !important;
    z-index: 20;
}

.admin-kicker {
    margin: 0 0 0.09rem;
    color: #c4b5fd;
    font-weight: 700;
    font-size: 0.5rem;
}

.admin-page-title {
    margin: 0;
    font-size: clamp(0.67rem, 1vw, 0.9rem);
}

.admin-topbar-actions {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.admin-mobile-nav-toggle {
    display: none;
    position: relative;
    z-index: 1000001;
}

.mobile-sidebar-overlay {
    position: fixed;
    inset: 0;
    background: rgba(2, 6, 23, 0.6);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.24s ease, visibility 0.24s ease;
    z-index: 999998;
}

.notification-bell-wrapper {
    position: relative;
    z-index: 2147482999 !important;
}

.notification-bell,
.notification-bell-btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.6rem;
    height: 2.6rem;
    border: 1px solid rgba(129, 140, 248, 0.22);
    border-radius: 14px;
    background: rgba(17, 28, 58, 0.82);
    color: #e9d5ff;
    box-shadow: var(--shadow-md);
    z-index: 2147482999 !important;
}

.notification-bell i {
    font-size: 1rem;
}

.notification-badge {
    position: absolute;
    top: -0.25rem;
    left: -0.25rem;
    min-width: 1.15rem;
    height: 1.15rem;
    padding: 0 0.2rem;
    border-radius: 999px;
    background: linear-gradient(135deg, #ef4444, #f97316);
    color: #fff;
    font-size: 0.65rem;
    font-weight: 700;
    line-height: 1.15rem;
    text-align: center;
}

.admin-shell,
.admin-main,
.admin-content,
.admin-topbar {
    overflow: visible;
}

.admin-notification-panel {
    position: fixed !important;
    top: 72px;
    left: 24px;
    width: min(420px, calc(100vw - 32px));
    max-height: calc(100vh - 100px);
    padding: 0;
    overflow-y: auto;
    border-radius: 20px;
    border: 1px solid rgba(129, 140, 248, 0.24);
    background: linear-gradient(180deg, rgba(17, 28, 58, 0.98), rgba(15, 23, 42, 0.98));
    box-shadow: 0 24px 80px rgba(2, 6, 23, 0.46);
    z-index: 2147483000 !important;
    isolation: isolate;
    backdrop-filter: blur(18px);
}

.admin-notification-panel[hidden] {
    display: none !important;
}

.admin-notification-panel.is-open {
    display: block;
}

.notification-dropdown__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.9rem 1rem;
    border-bottom: 1px solid rgba(129, 140, 248, 0.14);
}

.notification-dropdown__header strong {
    font-size: 0.92rem;
}

.notification-dropdown__header span {
    color: var(--text-muted);
    font-size: 0.76rem;
}

.notification-dropdown__actions {
    display: flex;
    justify-content: flex-start;
    padding: 0.55rem 0.75rem 0;
}

.notification-dismiss-all {
    border: 0;
    background: transparent;
    color: #c4b5fd;
    font: inherit;
    font-size: 0.78rem;
    font-weight: 700;
    padding: 0.25rem 0.35rem;
    border-radius: 10px;
}

.notification-dismiss-all:hover {
    background: rgba(124, 58, 237, 0.14);
}

.notification-dropdown__list {
    display: grid;
    gap: 0.35rem;
    max-height: min(58vh, 440px);
    overflow-y: auto;
    padding: 0.55rem;
}

.notification-item {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 0.75rem;
    align-items: start;
    padding: 0.82rem 0.85rem;
    border-radius: 16px;
    color: var(--text);
    text-decoration: none;
    border: 1px solid rgba(129, 140, 248, 0.12);
    background: rgba(15, 23, 42, 0.48);
    min-width: 0;
    overflow: hidden;
}

.notification-item:hover {
    background: rgba(31, 53, 85, 0.94);
    border-color: rgba(129, 140, 248, 0.28);
}

.notification-item__link {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: 0.75rem;
    min-width: 0;
    color: inherit;
    text-decoration: none;
}

.notification-item__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.1rem;
    height: 2.1rem;
    border-radius: 14px;
    background: rgba(124, 58, 237, 0.16);
    flex-shrink: 0;
}

.notification-item__icon i {
    font-size: 1rem;
}

.notification-item__content {
    display: grid;
    gap: 0.12rem;
    min-width: 0;
}

.notification-item__content strong,
.notification-item__content span {
    min-width: 0;
}

.notification-item__content strong {
    font-size: 0.86rem;
}

.notification-item__content span {
    color: var(--text-muted);
    font-size: 0.78rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.notification-dismiss-btn {
    width: 2rem;
    height: 2rem;
    border: 0;
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.72);
    color: #cbd5e1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.notification-dismiss-btn:hover {
    background: rgba(239, 68, 68, 0.16);
    color: #fecaca;
}

.notification-item--danger .notification-item__icon {
    background: rgba(239, 68, 68, 0.16);
    color: #fecaca;
}

.notification-item--warning .notification-item__icon {
    background: rgba(245, 158, 11, 0.16);
    color: #fde68a;
}

.notification-item--success .notification-item__icon {
    background: rgba(16, 185, 129, 0.16);
    color: #d1fae5;
}

.notification-item--info .notification-item__icon {
    background: rgba(79, 70, 229, 0.16);
    color: #c7d2fe;
}

.notification-empty {
    padding: 1.1rem 1rem;
    text-align: center;
    color: var(--text-muted);
}

.admin-user-chip {
    display: inline-flex;
    align-items: center;
    min-height: 1.5rem;
    padding: 0 0.5rem;
    border-radius: 999px;
    border: 1px solid rgba(129, 140, 248, 0.2);
    background: rgba(79, 70, 229, 0.12);
    color: #c7d2fe;
    font-size: 0.57rem;
}

.admin-content {
    display: grid;
    gap: 0.6rem;
    min-width: 0;
    max-width: 100%;
    overflow-x: hidden;
}

.admin-profile-card {
    display: grid;
    gap: 0.24rem;
    min-width: min(100%, 320px);
    padding: 0.72rem 0.9rem;
    border-radius: 16px;
    background: linear-gradient(135deg, rgba(124, 58, 237, 0.12), rgba(37, 99, 235, 0.12));
    border: 1px solid rgba(129, 140, 248, 0.2);
}

.admin-profile-card__main,
.admin-profile-card__meta {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    flex-wrap: wrap;
}

.admin-profile-card__main strong {
    font-size: 0.95rem;
}

.admin-profile-card__main span,
.admin-profile-card__meta span {
    color: var(--text-muted);
    font-size: 0.78rem;
}

.admin-profile-card__meta span {
    padding: 0.18rem 0.48rem;
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.38);
    color: #cbd5e1;
}

.impersonation-banner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
    padding: 0.9rem 1rem;
    border-radius: 18px;
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.18), rgba(124, 58, 237, 0.16));
    border: 1px solid rgba(251, 191, 36, 0.34);
    box-shadow: var(--shadow-md);
}

.impersonation-banner__copy {
    display: grid;
    gap: 0.15rem;
}

.impersonation-banner__eyebrow {
    color: #fcd34d;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.08em;
}

.impersonation-banner__copy strong {
    font-size: 0.95rem;
    color: #fff7ed;
}

.impersonation-banner__copy p {
    margin: 0;
}

.impersonation-banner__action {
    margin: 0;
}

.dashboard-hero {
    display: grid;
    grid-template-columns: minmax(0, 0.92fr) minmax(320px, 0.88fr);
    gap: 1rem;
    overflow: hidden !important;
    min-width: 0;
}

.dashboard-hero__eyebrow {
    color: #c4b5fd;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.08em;
}

.dashboard-hero__copy h2 {
    margin: 0.18rem 0 0.32rem;
    font-size: 1.2rem;
}

.dashboard-hero__copy p {
    margin: 0;
    color: var(--text-muted);
    max-width: 44rem;
}

.dashboard-quick-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.75rem;
    min-width: 0;
}

.dashboard-stats {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.9rem;
    min-width: 0;
}

.dashboard-card {
    display: grid;
    gap: 0.48rem;
    padding: 1rem;
    border-radius: 20px;
    border: 1px solid rgba(129, 140, 248, 0.2);
    background: linear-gradient(180deg, rgba(17, 28, 58, 0.98), rgba(15, 23, 42, 0.96));
    box-shadow: var(--shadow-md);
    min-width: 0;
    overflow: hidden;
}

.dashboard-card__title {
    color: #dbeafe;
    font-size: 0.82rem;
    font-weight: 700;
}

.dashboard-card__value {
    font-size: clamp(1.15rem, 2vw, 1.75rem);
    line-height: 1.2;
}

.dashboard-card__meta {
    margin: 0;
    color: var(--text-muted);
    font-size: 0.82rem;
}

.dashboard-card--primary {
    border-color: rgba(129, 140, 248, 0.24);
}

.dashboard-card--success {
    border-color: rgba(16, 185, 129, 0.24);
}

.dashboard-card--warning {
    border-color: rgba(245, 158, 11, 0.28);
}

.dashboard-card--danger {
    border-color: rgba(239, 68, 68, 0.24);
}

.dashboard-card--indigo {
    border-color: rgba(124, 58, 237, 0.28);
}

.quick-action-card {
    display: grid;
    gap: 0.8rem;
    padding: 0.95rem;
    border-radius: 18px;
    text-decoration: none;
    color: var(--text);
    border: 1px solid rgba(129, 140, 248, 0.18);
    background: rgba(15, 23, 42, 0.52);
    box-shadow: var(--shadow-md);
    min-width: 0;
    overflow: hidden;
}

.quick-action-card:hover {
    transform: translateY(-1px);
    border-color: rgba(129, 140, 248, 0.32);
    background: rgba(31, 53, 85, 0.88);
}

.quick-action-card__content strong {
    display: block;
    margin-bottom: 0.22rem;
}

.quick-action-card__content p {
    margin: 0;
    color: var(--text-muted);
    font-size: 0.82rem;
}

.quick-action-card__label {
    color: #e9d5ff;
    font-size: 0.8rem;
    font-weight: 700;
}

.quick-action-card--primary {
    background: linear-gradient(135deg, rgba(124, 58, 237, 0.18), rgba(37, 99, 235, 0.12));
}

.quick-action-card--success {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.14), rgba(37, 99, 235, 0.12));
}

.quick-action-card--warning {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.16), rgba(124, 58, 237, 0.12));
}

.quick-action-card--danger {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.16), rgba(124, 58, 237, 0.12));
}

.quick-action-card--indigo {
    background: linear-gradient(135deg, rgba(79, 70, 229, 0.18), rgba(6, 182, 212, 0.1));
}

.dashboard-sections {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.95rem;
    min-width: 0;
}

.dashboard-section {
    align-content: start;
    min-width: 0;
}

.dashboard-sections-stack {
    display: flex;
    flex-direction: column;
    gap: 18px;
    width: 100%;
    min-width: 0;
}

.dashboard-full-section {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    overflow: hidden;
}

.dashboard-empty {
    display: grid;
    justify-items: start;
    gap: 0.45rem;
    padding: 1rem;
    border-radius: 18px;
    background: rgba(15, 23, 42, 0.46);
    border: 1px dashed rgba(129, 140, 248, 0.24);
}

.dashboard-empty strong {
    font-size: 0.95rem;
}

.dashboard-empty p {
    margin: 0;
    color: var(--text-muted);
}

.studio-status-widget {
    display: grid;
    gap: 0.9rem;
    min-width: 0;
}

.studio-status-widget__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
}

.studio-status-widget__eyebrow {
    color: #c4b5fd;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.08em;
}

.studio-status-widget__head h3 {
    margin: 0.18rem 0 0;
}

.studio-status-widget__grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.75rem;
}

.studio-status-widget__item {
    padding: 0.82rem 0.9rem;
    border-radius: 16px;
    background: rgba(15, 23, 42, 0.48);
    border: 1px solid rgba(129, 140, 248, 0.16);
}

.studio-status-widget__item span {
    display: block;
    color: var(--text-muted);
    font-size: 0.76rem;
    margin-bottom: 0.18rem;
}

.studio-status-widget__item strong {
    font-size: 0.95rem;
}

.studio-status-widget__note {
    margin: 0;
    color: var(--text-muted);
}

.panel-section {
    display: grid;
    gap: 0.4rem;
    padding: 0.5rem;
    border-radius: 12px;
    background: #111c3a;
    border: 1px solid rgba(124, 58, 237, 0.25);
    box-shadow: var(--shadow-md);
    overflow: hidden;
    min-width: 0;
}

.panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.panel-header h2 {
    margin: 0 0 0.18rem;
    font-size: 0.67rem;
}

.panel-header p {
    margin: 0;
    color: var(--text-muted);
}

.filter-box {
    padding: 0.5rem;
    border-radius: 10px;
    background: #111c3a;
    border: 1px solid rgba(124, 58, 237, 0.25);
    overflow: visible;
}

.filter-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 0.55rem;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1rem;
}

.stat-card {
    position: relative;
    overflow: hidden;
    padding: 0.9rem;
    border-radius: 14px;
    border: 1px solid rgba(124, 58, 237, 0.3);
    background: #111c3a;
    box-shadow: var(--shadow-md);
}

.stat-card::after {
    content: "";
    position: absolute;
    inset: auto -10% -28% auto;
    width: 76px;
    height: 76px;
    background: transparent;
}

.stat-label {
    display: block;
    margin-bottom: 0.57rem;
    color: #cbd5e1;
}

.stat-value {
    display: block;
    font-size: clamp(1.2rem, 2vw, 1.7rem);
    line-height: 1;
    margin-bottom: 0.45rem;
}

.table-wrap {
    overflow-x: auto;
    overflow-y: hidden;
    border-radius: 20px;
    border: 1px solid rgba(124, 58, 237, 0.25);
    background: #111c3a;
    max-width: 100%;
    min-width: 0;
}

.table-safe-wrapper {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    overflow-x: auto;
    overflow-y: hidden;
}

.admin-table {
    width: 100%;
    min-width: 100%;
    border-collapse: collapse;
    background: transparent;
    table-layout: fixed;
}

.admin-table th,
.admin-table td {
    padding: 0.67rem 0.67rem;
    text-align: right;
    vertical-align: top;
    border-bottom: 1px solid rgba(148, 163, 184, 0.08);
    min-width: 0;
    overflow: hidden;
}

.admin-table thead th {
    background: #0f1530;
    color: #cbd5e1;
    font-size: 0.86rem;
    font-weight: 700;
    line-height: 1.6;
    white-space: nowrap;
}

.admin-table tbody tr:hover {
    background: rgba(124, 58, 237, 0.05);
}

.table-subtext {
    color: var(--text-muted);
    font-size: 0.9rem;
    max-width: 100%;
}

.table-note {
    color: #fcd34d;
}

.status-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 2rem;
    padding: 0 0.85rem;
    border-radius: 999px;
    border: 1px solid transparent;
    font-size: 0.88rem;
    white-space: nowrap;
}

.status-active,
.status-confirmed,
.status-sent,
.status-paid {
    color: #d1fae5;
    background: rgba(16, 185, 129, 0.14);
    border-color: rgba(16, 185, 129, 0.22);
}

.status-inactive,
.status-cancelled,
.status-failed {
    color: #fecaca;
    background: rgba(239, 68, 68, 0.14);
    border-color: rgba(239, 68, 68, 0.22);
}

.status-pending,
.status-unpaid {
    color: #fde68a;
    background: rgba(245, 158, 11, 0.14);
    border-color: rgba(245, 158, 11, 0.22);
}

.status-running,
.status-completed {
    color: #dbeafe;
    background: rgba(37, 99, 235, 0.14);
    border-color: rgba(37, 99, 235, 0.22);
}

.status-paused {
    color: #fdba74;
    background: rgba(249, 115, 22, 0.16);
    border-color: rgba(249, 115, 22, 0.22);
}

.empty-state {
    padding: 2rem 1rem;
    text-align: center;
    color: var(--text-muted);
}

.alert {
    padding: 1rem 1.1rem;
    border-radius: 18px;
    border: 1px solid transparent;
    backdrop-filter: blur(14px);
}

.alert-success {
    color: #d1fae5;
    background: rgba(16, 185, 129, 0.12);
    border-color: rgba(16, 185, 129, 0.22);
}

.alert-error {
    color: #fee2e2;
    background: rgba(239, 68, 68, 0.12);
    border-color: rgba(239, 68, 68, 0.22);
}

.pagination-wrap {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.pagination-text {
    color: var(--text-muted);
}

.calendar-filter {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
    align-items: end;
}

.calendar-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.calendar-toolbar h3 {
    margin: 0;
}

.calendar-grid-wrap {
    display: grid;
    gap: 0.85rem;
}

.calendar-weekdays,
.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    gap: 0.75rem;
}

.calendar-weekdays div {
    padding: 0.85rem;
    text-align: center;
    border-radius: 16px;
    border: 1px solid var(--border);
    background: rgba(15, 23, 42, 0.54);
    color: var(--text-muted);
}

.calendar-day {
    min-height: 220px;
    padding: 0.9rem;
    border-radius: 20px;
    border: 1px solid var(--border);
    background: rgba(15, 23, 42, 0.54);
    display: grid;
    gap: 0.75rem;
    align-content: start;
}

.calendar-day.is-empty {
    background: rgba(15, 23, 42, 0.25);
}

.calendar-day.is-today {
    border-color: rgba(129, 140, 248, 0.35);
    box-shadow: inset 0 0 0 1px rgba(129, 140, 248, 0.15);
}

.calendar-day-head {
    display: flex;
    justify-content: space-between;
    gap: 0.5rem;
}

.calendar-day-head span {
    color: var(--text-muted);
    font-size: 0.85rem;
}

.calendar-bookings {
    display: grid;
    gap: 0.6rem;
}

.calendar-booking-item {
    display: grid;
    gap: 0.2rem;
    padding: 0.75rem;
    border-radius: 16px;
    text-decoration: none;
    color: var(--text);
    border: 1px solid transparent;
    background: rgba(30, 41, 59, 0.72);
}

.calendar-booking-item:hover {
    border-color: rgba(129, 140, 248, 0.28);
    background: rgba(79, 70, 229, 0.18);
}

.calendar-booking-time {
    color: #93c5fd;
    font-weight: 700;
}

.calendar-booking-item small,
.calendar-empty {
    color: var(--text-muted);
}

.jalali-date {
    display: inline-flex;
    align-items: center;
    color: #dbeafe;
    white-space: nowrap;
}

.jalali-picker,
.jalali-date-filter,
.jalali-date-picker,
.jalali-datetime-picker {
    position: relative;
    display: grid;
    gap: 0.45rem;
    z-index: 20;
    overflow: visible;
}

.mds-bootstrap-persian-datetime-picker-popover,
.popover,
.datepicker-plot-area {
    z-index: 999999 !important;
}

.md-persian-picker-wrapper,
.jalali-date-picker,
.jalali-datetime-picker {
    position: relative;
}

.filter-card,
.admin-card,
.table-responsive,
.form-card {
    overflow: visible !important;
}

.jalali-picker.is-open,
.jalali-date-picker.is-open,
.jalali-datetime-picker.is-open {
    z-index: 99999;
}

.date-picker-input-group {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    width: 100%;
    align-items: stretch;
    gap: 0.42rem;
}

.date-picker-input-group input[type="text"] {
    flex: 1;
    min-width: 148px;
    width: 100%;
    color: var(--text) !important;
    opacity: 1 !important;
}

.jalali-datetime-picker .date-picker-input-group input[type="text"] {
    min-width: 190px;
    color: var(--text) !important;
    opacity: 1 !important;
}

.jalali-picker-icon,
.date-picker-icon-btn,
.jalali-date-filter-icon {
    width: 44px;
    min-width: 44px;
    height: auto;
    min-height: 100%;
    padding: 0.6rem;
    border-radius: 10px;
    border: 1px solid rgba(148, 163, 184, 0.24);
    background: rgba(124, 58, 237, 0.08);
    color: #7c3aed;
    cursor: pointer;
    font: inherit;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: background 150ms ease, transform 150ms ease, border-color 150ms ease;
}

.jalali-picker-icon:hover,
.date-picker-icon-btn:hover,
.jalali-date-filter-icon:hover {
    background: rgba(124, 58, 237, 0.14);
    transform: translateY(-0.5px);
}

.jalali-picker-icon svg,
.date-picker-icon-btn svg,
.jalali-date-filter-icon svg {
    width: 1.05rem;
    height: 1.05rem;
    fill: currentColor;
}

.is-invalid-date {
    border-color: #ef4444 !important;
}

.jalali-picker-icon svg,
.jalali-date-filter-icon svg {
    width: 1.2rem;
    height: 1.2rem;
    fill: currentColor;
}

.form-group-date-filter {
    min-width: 0;
}

.form-group-date-filter .md-persian-picker-wrapper,
.form-group-date-filter .date-picker-input-group {
    width: 100%;
}

.jalali-picker-popup,
.jalali-date-filter-popup {
    position: absolute;
    top: calc(100% + 0.3rem);
    right: 0;
    z-index: 99999;
    width: min(100%, 240px);
    min-width: 220px;
    padding: 0.67rem;
    display: grid;
    gap: 0.63rem;
    border-radius: 15px;
    background: rgba(9, 16, 31, 0.97);
    border: 1px solid var(--border-strong);
    box-shadow: var(--shadow-lg);
}

.jalali-picker-popup[hidden],
.jalali-date-filter-popup[hidden] {
    display: none !important;
}

[data-jalali-date-popup][hidden] {
    display: none !important;
}

[data-jalali-date-popup],
[data-jalali-datetime-popup] {
    z-index: 99999 !important;
}

[data-md-jalali-display] {
    cursor: text;
}

.mds-bootstrap-persian-datetime-picker-popover,
.mds-bs-persian-datetime-picker-popover,
.popover,
.datepicker-plot-area {
    z-index: 999999 !important;
}

.filter-card,
.admin-card,
.table-responsive,
.form-card,
.filter-box,
.panel-section,
.table-wrap {
    overflow: visible !important;
}

.mds-bs-persian-datetime-picker-popover {
    min-width: 216px;
    border-radius: 15px;
    border: 1px solid var(--border-strong);
    background: rgba(9, 16, 31, 0.98);
    box-shadow: var(--shadow-lg);
    color: var(--text);
}

.mds-bs-persian-datetime-picker-popover .popover-header,
.mds-bs-persian-datetime-picker-popover .popover-body {
    background: transparent;
    color: inherit;
    border: 0;
}

.mds-bs-persian-datetime-picker-popover .table {
    width: 100%;
    color: inherit;
    border-collapse: collapse;
}

.mds-bs-persian-datetime-picker-popover .btn,
.mds-bs-persian-datetime-picker-popover .dropdown-item,
.mds-bs-persian-datetime-picker-popover input[type="time"] {
    font: inherit;
}

.mds-bs-persian-datetime-picker-popover .btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 1.55rem;
    width: 100%;
    border: 1px solid rgba(148, 163, 184, 0.18);
    border-radius: 8px;
    background: rgba(30, 41, 59, 0.84);
    color: var(--text);
    cursor: pointer;
}

.mds-bs-persian-datetime-picker-popover .btn:hover {
    background: rgba(124, 58, 237, 0.18);
}

.mds-bs-persian-datetime-picker-popover .dropdown {
    position: relative;
}

.dropdown-menu,
.mds-bs-persian-datetime-picker-popover .dropdown-menu {
    position: absolute;
    top: calc(100% + 0.23rem);
    right: 0;
    left: 0;
    display: none;
    max-height: 162px;
    overflow-y: auto;
    padding: 0.23rem;
    border-radius: 10px;
    border: 1px solid rgba(129, 140, 248, 0.24);
    background: rgba(15, 23, 42, 0.96);
    box-shadow: 0 22px 44px rgba(2, 6, 23, 0.34);
    color: #e2e8f0;
    z-index: 999999 !important;
    backdrop-filter: blur(14px);
}

.dropdown-menu.show,
.mds-bs-persian-datetime-picker-popover .dropdown-menu.show {
    display: block;
}

.dropdown-item,
.mds-bs-persian-datetime-picker-popover .dropdown-item {
    display: block;
    width: 100%;
    padding: 0.4rem 0.5rem;
    border-radius: 7px;
    color: #e2e8f0;
    text-decoration: none;
    cursor: pointer;
    background: transparent;
}

.dropdown-item:hover,
.dropdown-item:focus,
.mds-bs-persian-datetime-picker-popover .dropdown-item:hover,
.mds-bs-persian-datetime-picker-popover .dropdown-item:focus {
    background: rgba(124, 58, 237, 0.18);
    color: #f5f3ff;
    outline: none;
}

.dropdown-item.active,
.dropdown-item:active,
.mds-bs-persian-datetime-picker-popover .dropdown-item.active,
.mds-bs-persian-datetime-picker-popover .dropdown-item:active {
    background: linear-gradient(135deg, #7c3aed, #4f46e5);
    color: #ffffff;
}

.dropdown-divider {
    height: 1px;
    margin: 0.35rem 0;
    border: 0;
    background: rgba(148, 163, 184, 0.28);
}

.mds-bs-persian-datetime-picker-popover input[type="time"] {
    width: 100%;
    border: 1px solid rgba(148, 163, 184, 0.18);
    border-radius: 8px;
    padding: 0.54rem;
    background: rgba(15, 23, 42, 0.8);
    color: var(--text);
}

.jalali-picker-header,
.jalali-date-filter-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.jalali-picker-header-controls {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex: 1 1 auto;
}

.jalali-picker-header-title {
    min-width: 110px;
    text-align: center;
}

.jalali-picker-select {
    min-width: 110px;
    padding-top: 0.7rem;
    padding-bottom: 0.7rem;
}

.jalali-picker-nav,
.jalali-date-filter-nav {
    width: 2.5rem;
    height: 2.5rem;
    border: 1px solid var(--border);
    border-radius: 14px;
    background: rgba(30, 41, 59, 0.75);
    color: var(--text);
    cursor: pointer;
    font: inherit;
}

.jalali-picker-weekdays,
.jalali-picker-days,
.jalali-date-filter-weekdays,
.jalali-date-filter-days {
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    gap: 0.35rem;
}

.jalali-picker-weekdays span,
.jalali-date-filter-weekdays span {
    text-align: center;
    color: var(--text-muted);
    font-size: 0.84rem;
}

.jalali-picker-day,
.jalali-date-filter-day {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 2.5rem;
    border-radius: 14px;
    border: 1px solid transparent;
    background: rgba(30, 41, 59, 0.72);
    color: var(--text);
    cursor: pointer;
    font: inherit;
}

.jalali-picker-day:hover,
.jalali-date-filter-day:hover {
    border-color: rgba(129, 140, 248, 0.3);
    background: rgba(124, 58, 237, 0.18);
}

.jalali-picker-day.is-selected,
.jalali-date-filter-day.is-selected {
    background: linear-gradient(135deg, var(--primary), var(--blue));
    color: #fff;
}

.jalali-picker-day.is-placeholder,
.jalali-date-filter-day.is-placeholder {
    background: transparent;
    border-color: transparent;
    pointer-events: none;
}

.jalali-picker-time {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.8rem;
}

.jalali-picker-actions,
.jalali-date-filter-actions {
    display: flex;
    gap: 0.6rem;
    flex-wrap: wrap;
}

.search-picker {
    position: relative;
    display: grid;
    gap: 0.65rem;
    isolation: isolate;
    min-width: 0;
}

.search-picker-control {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 0.65rem;
}

.search-picker-selected {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 0.75rem;
    padding: 0.85rem 1rem;
    border-radius: 16px;
    background: rgba(30, 41, 59, 0.58);
    border: 1px solid rgba(148, 163, 184, 0.12);
}

.search-picker-selected.is-empty {
    color: var(--text-muted);
}

.search-picker-dropdown {
    position: absolute;
    top: calc(100% + 0.55rem);
    right: 0;
    left: 0;
    z-index: 200;
    display: none;
    gap: 0.4rem;
    max-height: 260px;
    overflow-y: auto;
    padding: 0.65rem;
    border-radius: 18px;
    background: rgba(9, 16, 31, 0.98);
    border: 1px solid var(--border-strong);
    box-shadow: var(--shadow-lg);
}

.search-picker-dropdown[hidden],
.search-picker-item[hidden] {
    display: none !important;
}

.search-picker-dropdown.is-open {
    display: grid;
}

.search-picker-item {
    width: 100%;
    padding: 0.8rem 0.9rem;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 0.75rem;
    border: 1px solid transparent;
    border-radius: 14px;
    background: rgba(30, 41, 59, 0.78);
    color: var(--text);
    cursor: pointer;
    font: inherit;
    text-align: right;
}

.search-picker-item:hover {
    border-color: rgba(129, 140, 248, 0.24);
    background: rgba(124, 58, 237, 0.14);
}

.search-picker-item small,
.search-picker-empty {
    color: var(--text-muted);
}

.search-picker-empty {
    padding: 0.8rem;
    text-align: center;
}

.session-detail-list {
    display: grid;
    gap: 0.8rem;
}

.session-section-title {
    margin: 0;
}

.dashboard-logout,
.table-actions form {
    margin: 0;
}

.card-content-safe,
.table-safe {
    min-width: 0;
    max-width: 100%;
    overflow: hidden;
}

.table-safe {
    width: 100%;
    table-layout: fixed;
}

.table-safe th,
.table-safe td {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.text-truncate-safe,
.cell-truncate {
    display: block;
    min-width: 0;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
}

.cell-nowrap {
    white-space: nowrap;
}

.line-clamp-1 {
    white-space: nowrap;
}

.line-clamp-2 {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    white-space: normal;
    overflow: hidden;
    word-break: break-word;
}

.break-safe {
    overflow-wrap: anywhere;
    word-break: break-word;
}

.admin-table td > .cell-truncate,
.admin-table td > .text-truncate-safe {
    width: 100%;
}

body.sidebar-collapsed .admin-shell {
    grid-template-columns: 84px minmax(0, 1fr);
}

body.sidebar-collapsed .admin-sidebar {
    width: 82px;
}

body.sidebar-collapsed .admin-sidebar-brand-copy,
body.sidebar-collapsed .sidebar-logo-text,
body.sidebar-collapsed .admin-sidebar-brand p,
body.sidebar-collapsed .admin-menu-group__title,
body.sidebar-collapsed .sidebar-group-title,
body.sidebar-collapsed .admin-menu-link__label,
body.sidebar-collapsed .sidebar-label,
body.sidebar-collapsed .admin-sidebar-foot p,
body.sidebar-collapsed .admin-sidebar-foot strong,
body.sidebar-collapsed .admin-sidebar-foot span {
    display: none;
}

body.sidebar-collapsed .admin-sidebar-brand,
body.sidebar-collapsed .admin-sidebar-foot {
    padding: 0.7rem 0.45rem;
}

body.sidebar-collapsed .admin-sidebar-brand-main,
body.sidebar-collapsed .admin-menu-link {
    justify-content: center;
}

body.sidebar-collapsed .admin-menu-link {
    padding-inline: 0.55rem;
}

body.sidebar-collapsed .admin-menu-link__icon {
    width: 1.95rem;
    height: 1.95rem;
}

body.sidebar-collapsed .admin-sidebar-toggle--inline {
    position: static;
    margin: 0.35rem auto 0;
}

body.sidebar-collapsed .admin-menu {
    justify-items: center;
}

body.sidebar-collapsed .admin-main {
    min-width: 0;
    max-width: 100%;
}

.auth-card,
.admin-topbar,
.panel-section,
.filter-box,
.header,
.admin-sidebar-brand,
.admin-sidebar-foot,
.hero-copy,
.hero-card,
.feature-card,
.table-wrap {
    box-shadow: var(--shadow-md);
}

@media (max-width: 1080px) {
    .stats-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .filter-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .dashboard-stats,
    .studio-status-widget__grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .dashboard-hero {
        grid-template-columns: 1fr;
    }
}

@media (min-width: 1440px) {
    .admin-shell {
        grid-template-columns: 160px 1fr;
        gap: 0;
    }

    .admin-sidebar {
        padding: 0.35rem 0.3rem;
    }

    .admin-main {
        width: 100%;
        padding: 0.3rem;
    }

    .admin-topbar {
        padding: 0.28rem 0.35rem;
        gap: 0.28rem;
        margin-bottom: 0.3rem;
    }

    .panel-section {
        padding: 0.4rem;
        gap: 0.35rem;
    }

    .filter-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 0.3rem;
    }

    .form-group {
        margin-bottom: 0.4rem;
    }

    .btn {
        padding: 0.3rem 0.5rem;
        font-size: 0.5rem;
    }
}

@media (max-width: 900px) {
    .hero,
    .features,
    .form-grid,
    .stats-grid,
    .calendar-filter,
    .calendar-weekdays,
    .calendar-grid,
    .filter-grid {
        grid-template-columns: 1fr;
    }

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

    .admin-sidebar {
        position: fixed;
        inset: 0 auto 0 0;
        width: min(82vw, 320px);
        min-height: 100vh;
        border-left: 0;
        transform: translateX(100%);
        box-shadow: 0 24px 80px rgba(2, 6, 23, 0.55);
    }

    body.sidebar-open .admin-sidebar {
        transform: translateX(0);
    }

    body.sidebar-collapsed .admin-sidebar-brand-copy,
    body.sidebar-collapsed .sidebar-logo-text,
    body.sidebar-collapsed .admin-sidebar-brand p,
    body.sidebar-collapsed .admin-menu-group__title,
    body.sidebar-collapsed .sidebar-group-title,
    body.sidebar-collapsed .admin-menu-link__label,
    body.sidebar-collapsed .sidebar-label,
    body.sidebar-collapsed .admin-sidebar-foot p,
    body.sidebar-collapsed .admin-sidebar-foot strong,
    body.sidebar-collapsed .admin-sidebar-foot span {
        display: initial;
    }

    body.sidebar-collapsed .admin-shell {
        grid-template-columns: 1fr;
    }

    .dashboard-quick-actions,
    .dashboard-stats,
    .dashboard-sections,
    .studio-status-widget__grid {
        grid-template-columns: 1fr;
    }

    .jalali-picker-popup,
    .jalali-date-filter-popup {
        min-width: 100%;
    }

    .payment-info-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 1024px) {
    .admin-shell,
    .admin-main,
    .admin-content {
        max-width: 100%;
        min-width: 0;
    }

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

    .admin-main {
        width: 100%;
        padding: 0.85rem 0.75rem;
    }

    .admin-content {
        overflow-x: hidden;
    }

    .admin-sidebar {
        position: fixed;
        top: 0;
        right: 0;
        left: auto;
        width: min(86vw, 320px);
        height: 100vh;
        min-height: 100vh;
        border-left: 1px solid rgba(129, 140, 248, 0.16);
        border-right: 0;
        transform: translateX(100%);
        transition: transform 0.28s ease;
        box-shadow: 0 24px 80px rgba(2, 6, 23, 0.55);
        overflow-y: auto;
        overflow-x: hidden;
        z-index: 999999;
    }

    body.mobile-sidebar-open .admin-sidebar {
        transform: translateX(0);
    }

    body.mobile-sidebar-open .mobile-sidebar-overlay {
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
    }

    .admin-mobile-nav-toggle {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        flex-shrink: 0;
    }

    body.sidebar-collapsed .admin-shell {
        grid-template-columns: 1fr;
    }

    body.sidebar-collapsed .admin-sidebar {
        width: min(86vw, 320px);
    }

    body.sidebar-collapsed .admin-sidebar-brand-copy,
    body.sidebar-collapsed .sidebar-logo-text,
    body.sidebar-collapsed .admin-sidebar-brand p,
    body.sidebar-collapsed .admin-menu-group__title,
    body.sidebar-collapsed .sidebar-group-title,
    body.sidebar-collapsed .admin-menu-link__label,
    body.sidebar-collapsed .sidebar-label,
    body.sidebar-collapsed .admin-sidebar-foot p,
    body.sidebar-collapsed .admin-sidebar-foot strong,
    body.sidebar-collapsed .admin-sidebar-foot span {
        display: initial;
    }

    .table-responsive,
    .table-safe-wrapper {
        max-width: 100%;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
}

@media (max-width: 700px) {
    .header {
        flex-direction: column;
        align-items: stretch;
    }

    .admin-main,
    .content {
        width: calc(100% - 1rem);
        padding-left: 0;
        padding-right: 0;
    }

    .admin-main {
        padding: 1rem 0.5rem;
    }

    .admin-topbar,
    .panel-section,
    .auth-card,
    .hero-copy,
    .hero-card {
        padding: 1.1rem;
    }

    .admin-topbar {
        align-items: stretch;
    }

    .topbar-brand {
        justify-content: space-between;
        flex-wrap: wrap;
        gap: 0.75rem;
    }

    .admin-topbar-actions,
    .studio-status-widget__head,
    .impersonation-banner {
        justify-content: stretch;
    }

    .admin-topbar-actions {
        width: 100%;
        gap: 0.6rem;
    }

    .admin-profile-card {
        min-width: 100%;
    }

    .admin-profile-card,
    .admin-profile-card__main,
    .admin-profile-card__meta {
        min-width: 0;
    }

    .admin-profile-card__main strong,
    .admin-profile-card__main span,
    .admin-profile-card__meta span {
        display: block;
        min-width: 0;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .nav-links {
        justify-content: space-between;
    }
}

@media (max-width: 640px) {
    .admin-topbar {
        gap: 0.75rem;
    }

    .admin-topbar-actions {
        flex-wrap: nowrap;
        align-items: stretch;
    }

    .notification-bell-wrapper,
    .admin-profile-card,
    .logout-form {
        min-width: 0;
    }

    .admin-notification-panel {
        top: 70px;
        left: 12px !important;
        right: 12px !important;
        width: auto;
        max-height: calc(100vh - 90px);
    }
}

@media (max-width: 768px) {
    .form-grid,
    .filter-grid,
    .calendar-filter,
    .stats-grid,
    .payment-info-grid {
        grid-template-columns: 1fr;
    }

    .dashboard-quick-actions,
    .dashboard-stats,
    .dashboard-sections,
    .studio-status-widget__grid {
        grid-template-columns: 1fr;
    }

    .form-actions,
    .form-grid .btn,
    .filter-grid .btn,
    .panel-section .btn,
    .form-grid .form-control,
    .filter-grid .form-control,
    .form-grid select,
    .filter-grid select,
    .form-grid input,
    .filter-grid input {
        width: 100%;
    }

    .btn,
    button,
    input,
    select {
        min-height: 44px;
    }
}
