:root {
    --ink: #070708;
    --ink-2: #101114;
    --panel: #16171c;
    --panel-2: #1d1f26;
    --line: rgba(255, 255, 255, 0.08);
    --line-strong: rgba(255, 255, 255, 0.16);
    --text: #f6f1e8;
    --muted: #9b958c;
    --gold: #e8b45a;
    --gold-2: #f3c97a;
    --ember: #ff6b3d;
    --danger: #ff6b6b;
    --ok: #7dcea0;
    --radius: 22px;
    --shadow: 0 24px 60px rgba(0, 0, 0, 0.35);
    --gk-black: #070708;
    --gk-white: #f6f1e8;
    --gk-gray: #9b958c;
    --gk-border: rgba(255, 255, 255, 0.08);
    --gk-soft: #1d1f26;
    --bs-primary: #e8b45a;
    --bs-primary-rgb: 232, 180, 90;
    --bs-body-bg: #070708;
    --bs-body-color: #f6f1e8;
    --bs-border-radius: 16px;
    --bs-link-color: #e8b45a;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: 'Vazirmatn', sans-serif;
    background:
        radial-gradient(900px 420px at 90% -10%, rgba(232, 180, 90, 0.16), transparent 50%),
        radial-gradient(700px 380px at -10% 20%, rgba(255, 107, 61, 0.08), transparent 45%),
        var(--ink);
    color: var(--text);
    line-height: 1.85;
}

body.home-collage {
    background-image:
        linear-gradient(180deg, rgba(7, 7, 8, 0.38) 0%, rgba(7, 7, 8, 0.62) 48%, rgba(7, 7, 8, 0.9) 100%),
        url('../img/hero-collage.jpg');
    background-size: cover;
    background-position: center top;
    background-attachment: fixed;
    background-repeat: no-repeat;
}

body.home-collage .navbar-wrap {
    background: rgba(7, 7, 8, 0.35);
}

body.home-collage .hero {
    min-height: calc(100vh - 90px);
    display: flex;
    align-items: center;
}

body.home-collage .hero-grid-layout {
    grid-template-columns: 1fr;
    max-width: 720px;
}

body.home-collage .stat {
    background: rgba(7, 7, 8, 0.45);
    backdrop-filter: blur(10px);
}

a {
    text-decoration: none;
    color: inherit;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-weight: 900;
    letter-spacing: -0.4px;
    line-height: 1.35;
    color: var(--text);
}

.container {
    width: 100%;
    max-width: 1160px;
    margin: 0 auto;
    padding: 0 22px;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--gold);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    margin-bottom: 10px;
}

.navbar-wrap {
    position: sticky;
    top: 0;
    z-index: 80;
    backdrop-filter: blur(18px);
    background: rgba(7, 7, 8, 0.72);
    border-bottom: 1px solid var(--line);
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 0;
    gap: 16px;
}

.brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 900;
    font-size: 1.05rem;
    letter-spacing: 0.5px;
}

.brand-mark {
    width: 38px;
    height: 38px;
    border-radius: 12px;
    display: grid;
    place-items: center;
    background: linear-gradient(160deg, var(--gold), var(--ember));
    color: #111;
    font-weight: 900;
}

.brand span {
    color: var(--gold);
}

.nav-toggle {
    display: none;
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 12px;
    color: var(--text);
    font-size: 1.3rem;
    padding: 7px 12px;
    cursor: pointer;
}

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

.nav-links a {
    color: var(--muted);
    font-size: 0.92rem;
    font-weight: 600;
    padding: 8px 12px;
    border-radius: 999px;
    transition: 0.2s;
}

.nav-links a:hover,
.nav-links a.is-active {
    color: var(--text);
    background: rgba(255, 255, 255, 0.05);
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    border-radius: 999px;
    font-weight: 800;
    font-size: 0.92rem;
    border: 1px solid transparent;
    cursor: pointer;
    transition: 0.2s ease;
    font-family: inherit;
    text-decoration: none !important;
}

.btn-accent,
.btn-primary {
    background: linear-gradient(135deg, var(--gold), #c8892e) !important;
    color: #16120a !important;
    border-color: transparent !important;
    box-shadow: 0 10px 24px rgba(232, 180, 90, 0.25);
}

.btn-accent:hover,
.btn-primary:hover {
    transform: translateY(-1px);
    filter: brightness(1.05);
    color: #16120a !important;
}

.btn-outline,
.btn-outline-secondary,
.btn-outline-primary {
    background: transparent !important;
    color: var(--text) !important;
    border: 1px solid var(--line-strong) !important;
}

.btn-outline:hover,
.btn-outline-secondary:hover,
.btn-outline-primary:hover {
    background: rgba(255, 255, 255, 0.06) !important;
    color: var(--text) !important;
}

.btn-outline-danger {
    background: transparent !important;
    color: var(--danger) !important;
    border: 1px solid rgba(255, 107, 107, 0.35) !important;
    border-radius: 999px !important;
}

.btn-outline-danger:hover {
    background: rgba(255, 107, 107, 0.12) !important;
    color: #fff !important;
}

.btn-success {
    background: linear-gradient(135deg, var(--gold), #c8892e) !important;
    border-color: transparent !important;
    color: #16120a !important;
}

.card {
    background: linear-gradient(180deg, rgba(255,255,255,0.04), rgba(255,255,255,0.02));
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 24px;
    box-shadow: var(--shadow);
    backdrop-filter: blur(12px);
    color: var(--text);
}

.section {
    padding: 72px 0;
}

.section-title {
    font-size: 2rem;
    margin: 0 0 8px;
}

.section-subtitle {
    color: var(--muted);
    margin: 0 0 36px;
}

.alert {
    padding: 14px 18px;
    border-radius: 14px;
    margin-bottom: 18px;
}

.alert-success {
    background: rgba(125, 206, 160, 0.12);
    border: 1px solid rgba(125, 206, 160, 0.35);
    color: var(--ok);
}

.alert-danger {
    background: rgba(255, 107, 107, 0.12);
    border: 1px solid rgba(255, 107, 107, 0.4);
    color: var(--danger);
}

.messages-wrap {
    padding-top: 22px;
}

footer.site-footer {
    border-top: 1px solid var(--line);
    padding: 48px 0 28px;
    margin-top: 40px;
    color: var(--muted);
    font-size: 0.9rem;
}

.footer-grid {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 24px;
}

.footer-links {
    display: flex;
    gap: 18px;
    flex-wrap: wrap;
}

.footer-links a:hover {
    color: var(--gold);
}

input,
textarea,
select,
.form-control,
.form-select {
    width: 100%;
    padding: 12px 14px;
    border-radius: 14px;
    border: 1px solid var(--line-strong);
    background: #0d0e12 !important;
    color: var(--text) !important;
    font-family: inherit;
    font-size: 15px;
}

input:focus,
textarea:focus,
select:focus,
.form-control:focus,
.form-select:focus {
    outline: none;
    border-color: var(--gold) !important;
    box-shadow: 0 0 0 0.18rem rgba(232, 180, 90, 0.18) !important;
}

label,
.form-label {
    display: block;
    margin-bottom: 8px;
    font-weight: 700;
    font-size: 0.88rem;
    color: var(--muted);
}

table {
    color: var(--text);
}

table thead {
    background: var(--panel-2);
}

.table {
    --bs-table-bg: transparent;
    --bs-table-color: var(--text);
    --bs-table-border-color: var(--line);
}

.badge.bg-success {
    background: var(--gold) !important;
    color: #16120a !important;
}

.badge.bg-warning {
    background: var(--panel-2) !important;
    color: var(--gold) !important;
    border: 1px solid var(--line);
}

.gk-search-box {
    position: relative;
    margin-bottom: 24px;
    max-width: 420px;
}

.gk-search-box input {
    padding-right: 44px;
    border-radius: 999px;
}

.gk-search-box .gk-search-icon {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--muted);
    pointer-events: none;
}

.app-shell {
    display: flex;
    min-height: 100vh;
}

.sidebar {
    width: 250px;
    flex-shrink: 0;
    background: #0c0d10;
    border-left: 1px solid var(--line);
    padding: 22px 16px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.sidebar a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-radius: 14px;
    color: var(--muted);
    font-weight: 700;
    font-size: 0.92rem;
}

.sidebar a:hover,
.sidebar a.is-active {
    background: rgba(232, 180, 90, 0.1);
    color: var(--gold);
}

.app-main {
    flex: 1;
    min-width: 0;
}

.site-topbar {
    background: rgba(7, 7, 8, 0.8);
    backdrop-filter: blur(16px);
    padding: 16px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--line);
    margin-bottom: 0;
    flex-wrap: wrap;
    gap: 10px;
    position: sticky;
    top: 0;
    z-index: 100;
}

.site-brand {
    font-weight: 900;
    color: var(--text) !important;
    text-decoration: none;
    font-size: 1.1rem;
}

.site-brand span {
    color: var(--gold);
}

.app-content {
    padding: 28px 24px 48px;
}

.auth-stage {
    min-height: calc(100vh - 90px);
    display: grid;
    place-items: center;
    padding: 40px 16px;
}

.auth-card {
    width: 100%;
    max-width: 480px;
}

.hero {
    padding: 56px 0 20px;
}

.hero-grid-layout {
    display: grid;
    grid-template-columns: 1.15fr 0.85fr;
    gap: 40px;
    align-items: center;
}

.hero h1 {
    font-size: clamp(2.1rem, 4.4vw, 3.6rem);
    margin: 0 0 16px;
}

.hero p.lead {
    color: var(--muted);
    font-size: 1.08rem;
    max-width: 540px;
    margin: 0 0 28px;
}

.hero-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin-top: 36px;
}

.stat {
    background: rgba(255,255,255,0.03);
    border: 1px solid var(--line);
    border-radius: 18px;
    padding: 16px;
}

.stat b {
    display: block;
    font-size: 1.4rem;
    color: var(--gold);
}

.mosaic {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 160px 220px;
    gap: 12px;
}

.tile {
    border-radius: 24px;
    overflow: hidden;
    position: relative;
    background:
        linear-gradient(160deg, rgba(232,180,90,0.18), rgba(255,107,61,0.08)),
        #1a1b22;
    border: 1px solid var(--line);
}

.tile.tall {
    grid-row: span 2;
}

.tile::after {
    content: attr(data-label);
    position: absolute;
    inset: auto 14px 14px auto;
    font-size: 0.8rem;
    font-weight: 800;
    color: #fff;
    background: rgba(0,0,0,0.45);
    padding: 6px 10px;
    border-radius: 999px;
}

.services-grid,
.dash-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px;
}

.service-card,
.dash-card {
    text-align: center;
    transition: 0.2s;
}

.service-card:hover,
.dash-card:hover {
    transform: translateY(-4px);
    border-color: rgba(232, 180, 90, 0.35);
}

.service-icon,
.dash-icon {
    font-size: 2.2rem;
    margin-bottom: 10px;
}

.card-link {
    display: block;
    color: inherit;
}

.gallery-grid,
.full-gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 14px;
}

.gallery-grid img,
.full-gallery-grid img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-radius: 18px;
    border: 1px solid var(--line);
}

.cta-section {
    text-align: center;
    background: linear-gradient(135deg, rgba(232,180,90,0.12), rgba(255,107,61,0.08));
    border: 1px solid rgba(232, 180, 90, 0.25);
    border-radius: 28px;
    padding: 56px 28px;
}

.page-hero {
    padding: 48px 0 8px;
    text-align: center;
}

.page-hero h1 {
    font-size: clamp(1.8rem, 3vw, 2.5rem);
}

.page-hero p {
    color: var(--muted);
}

.contact-grid,
.about-content {
    display: grid;
    grid-template-columns: 1fr 1.15fr;
    gap: 24px;
    align-items: start;
}

.about-content img {
    width: 100%;
    border-radius: 24px;
    border: 1px solid var(--line);
}

.info-row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
    color: var(--muted);
}

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

hr {
    border-color: var(--line);
    opacity: 1;
}

.article-card {
    transition: 0.2s;
    display: block;
}

.article-card:hover {
    border-color: rgba(232, 180, 90, 0.35);
}

.article-cover {
    width: 100%;
    height: 170px;
    object-fit: cover;
    border-radius: 18px 18px 0 0;
}

.mobile-nav {
    display: none;
    gap: 8px;
    overflow-x: auto;
    padding: 0 16px 14px;
    border-bottom: 1px solid var(--line);
}

.mobile-nav a {
    white-space: nowrap;
    padding: 8px 12px;
    border-radius: 999px;
    background: var(--panel);
    border: 1px solid var(--line);
    color: var(--muted);
    font-size: 0.82rem;
    font-weight: 700;
}

/* دکمه‌های ورود و ثبت‌نام در منوی بالا */
.nav-links .nav-auth-btn {
    width: 96px;
    min-width: 96px;
    height: 42px;
    padding: 0 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--gold), #c8892e) !important;
    color: #16120a !important;
    border: 1px solid transparent !important;
    border-radius: 999px;
    font-weight: 800;
    line-height: 1;
    box-shadow: 0 10px 24px rgba(232, 180, 90, 0.25);
}

.nav-links .nav-auth-btn:hover {
    background: linear-gradient(135deg, var(--gold-2), var(--gold)) !important;
    color: #16120a !important;
    transform: translateY(-1px);
}

@media (max-width: 980px) {
    .hero-grid-layout,
    .contact-grid,
    .about-content {
        grid-template-columns: 1fr;
    }

    .mosaic {
        grid-template-columns: 1fr 1fr;
        grid-template-rows: 140px 180px;
    }

    .sidebar {
        display: none;
    }

    .mobile-nav {
        display: flex;
    }

    .nav-toggle {
        display: block;
    }

    .navbar {
        position: relative;
    }

    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        right: 0;
        left: 0;
        background: #101114;
        flex-direction: column;
        align-items: stretch;
        padding: 10px;
        border: 1px solid var(--line);
        border-radius: 16px;
        z-index: 50;
    }

    .nav-links.open {
        display: flex;
    }

    .nav-links a,
    .nav-links .btn,
    .nav-links .nav-auth-btn {
        width: 100%;
        min-width: 100%;
        text-align: center;
    }
}

@media (max-width: 768px) {
    body.home-collage {
        background-attachment: scroll;
        background-position: center;
    }

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

@media (max-width: 560px) {
    .stats {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 16px;
    }

    .section {
        padding: 48px 0;
    }

    .hero-actions .btn {
        width: 100%;
    }
}


/* بازگرداندن استایل جستجوی صفحه اصلی */
.home-search-form {
    width: 100%;
    max-width: 620px;
    margin: 0 auto;
    display: flex;
    align-items: stretch;
    overflow: hidden;
    background: #0d0e12;
    border: 1px solid var(--gold);
    border-radius: 999px;
    box-shadow: 0 10px 28px rgba(232, 180, 90, 0.12);
}

.home-search-form input,
.home-search-form input.form-control {
    flex: 1;
    min-width: 0;
    height: 52px;
    padding: 0 20px;
    border: 0 !important;
    border-radius: 0 !important;
    outline: none;
    box-shadow: none !important;
    background: transparent !important;
    color: var(--text) !important;
}

.home-search-form input::placeholder {
    color: var(--muted);
}

.home-search-form button,
.home-search-form .search-submit {
    flex-shrink: 0;
    min-width: 108px;
    height: 52px;
    padding: 0 22px;
    border: 0;
    border-right: 1px solid rgba(232, 180, 90, 0.55);
    border-radius: 0 !important;
    background: transparent !important;
    color: var(--gold) !important;
    font-family: inherit;
    font-weight: 800;
    cursor: pointer;
    transition: 0.2s ease;
}

.home-search-form button:hover,
.home-search-form .search-submit:hover {
    background: var(--gold) !important;
    color: #16120a !important;
}

@media (max-width: 560px) {
    .home-search-form {
        border-radius: 16px;
    }

    .home-search-form input,
    .home-search-form input.form-control {
        height: 50px;
        padding: 0 14px;
    }

    .home-search-form button,
    .home-search-form .search-submit {
        min-width: 88px;
        height: 50px;
        padding: 0 12px;
    }
}


/* =========================
   بخش نظرات کاربران
   ========================= */

.comment-form-card {
    max-width: 560px;
}

.comment-form-description {
    color: var(--muted);
    margin: 0 0 26px;
}

.comment-form-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.comments-home-header {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 28px;
}

.comments-home-header .section-subtitle {
    margin-bottom: 0;
}

.comments-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(245px, 1fr));
    gap: 16px;
}

.user-comment-card {
    padding: 22px;
    height: 100%;
}

.comment-card-head {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.comment-avatar {
    width: 44px;
    height: 44px;
    flex-shrink: 0;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--gold), #c8892e);
    color: #16120a;
    font-weight: 900;
    font-size: 1.1rem;
}

.comment-card-head h3 {
    margin: 0;
    font-size: 1rem;
}

.comment-card-head span {
    display: block;
    margin-top: 2px;
    color: var(--muted);
    font-size: 0.78rem;
}

.user-comment-card p {
    margin: 0;
    color: var(--text);
    line-height: 2;
}

.empty-comments {
    grid-column: 1 / -1;
    text-align: center;
    padding: 42px 24px;
}

.empty-comments h3 {
    margin-top: 0;
}

.empty-comments p {
    color: var(--muted);
    margin-bottom: 24px;
}

/* مدیریت نظرات در پنل مربی */
.page-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 28px;
}

.page-heading h1 {
    margin: 0 0 6px;
}

.coach-comments-list {
    display: grid;
    gap: 16px;
    max-width: 880px;
}

.coach-comment-card {
    padding: 22px;
}

.coach-comment-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
}

.coach-comment-top h3 {
    margin: 0 0 3px;
    font-size: 1.05rem;
}

.coach-comment-message {
    margin-top: 18px;
    padding-top: 18px;
    border-top: 1px solid var(--line);
    color: var(--text);
    line-height: 2;
}

.comment-status {
    display: inline-flex;
    align-items: center;
    white-space: nowrap;
    padding: 5px 11px;
    border-radius: 999px;
    font-size: 0.78rem;
    font-weight: 800;
}

.comment-status.approved {
    background: rgba(125, 206, 160, 0.14);
    border: 1px solid rgba(125, 206, 160, 0.3);
    color: var(--ok);
}

.comment-status.pending {
    background: rgba(232, 180, 90, 0.12);
    border: 1px solid rgba(232, 180, 90, 0.28);
    color: var(--gold);
}

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

    .comments-home-header .btn {
        width: 100%;
    }

    .comment-form-actions .btn {
        width: 100%;
    }

    .coach-comment-top {
        flex-direction: column;
    }
}


/* =====================================================
   تغییر تم پنل مربی و ورزشکار
   ===================================================== */

.topbar-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.sidebar-theme-switcher {
    margin-top: auto;
    margin-bottom: 12px;
    padding: 14px 12px;
    border-top: 1px solid rgba(212, 175, 55, 0.18);
}

.sidebar-theme-switcher > span {
    display: block;
    margin-bottom: 9px;
    font-size: 12px;
    color: var(--muted);
}

.sidebar-theme-switcher form {
    margin: 0;
}

.theme-toggle-btn {
    width: 100%;
    border: 1px solid var(--gold);
    border-radius: 10px;
    background: transparent;
    color: var(--gold);
    padding: 9px 12px;
    font-size: 13px;
    cursor: pointer;
    transition: 0.2s ease;
}

.theme-toggle-btn:hover {
    background: var(--gold);
    color: #151515;
}

.mobile-theme-form {
    display: none;
    margin: 0;
}

.mobile-theme-form .theme-toggle-btn {
    width: 38px;
    height: 34px;
    padding: 0;
    display: grid;
    place-items: center;
}

/* تم روشن، فقط برای صفحات پنل */
body.panel-theme-light {
    --bg: #f4f6f8;
    --surface: #ffffff;
    --surface-2: #edf1f5;
    --text: #1d2630;
    --muted: #65717d;
    --border: #d8dee5;
    --gold: #b48316;
}

body.panel-theme-light .app-shell,
body.panel-theme-light .app-main,
body.panel-theme-light .app-content {
    background: #f4f6f8;
    color: #1d2630;
}

body.panel-theme-light .sidebar {
    background: #ffffff;
    border-left: 1px solid #d8dee5;
    box-shadow: -4px 0 22px rgba(22, 32, 42, 0.06);
}

body.panel-theme-light .sidebar a {
    color: #2f3a45;
}

body.panel-theme-light .sidebar a:hover {
    background: #f7f0dc;
    color: #8b6511;
}

body.panel-theme-light .site-topbar {
    background: #ffffff;
    border-bottom: 1px solid #d8dee5;
}

body.panel-theme-light .card,
body.panel-theme-light .stat,
body.panel-theme-light .cta-section,
body.panel-theme-light .table-wrap,
body.panel-theme-light .form-card {
    background: #ffffff;
    border-color: #d8dee5;
    color: #1d2630;
    box-shadow: 0 8px 24px rgba(18, 30, 42, 0.06);
}

body.panel-theme-light input,
body.panel-theme-light textarea,
body.panel-theme-light select {
    background: #ffffff;
    border-color: #cbd3dc;
    color: #1d2630;
}

body.panel-theme-light input::placeholder,
body.panel-theme-light textarea::placeholder {
    color: #8a96a3;
}

body.panel-theme-light table {
    color: #1d2630;
}

body.panel-theme-light table thead th {
    background: #f1f4f7;
    color: #26313b;
}

body.panel-theme-light table tbody tr {
    border-color: #e1e6eb;
}

body.panel-theme-light table tbody tr:hover {
    background: #fffaf0;
}

body.panel-theme-light .mobile-nav {
    background: #ffffff;
    border-color: #d8dee5;
}

body.panel-theme-light .mobile-nav a {
    color: #2f3a45;
}

body.panel-theme-light .alert-success {
    background: #eaf8ef;
    color: #176536;
    border-color: #b9e6c7;
}

body.panel-theme-light .alert-danger {
    background: #fff0f0;
    color: #a72b2b;
    border-color: #f1c4c4;
}

@media (max-width: 980px) {
    .sidebar-theme-switcher {
        display: none;
    }

    .mobile-theme-form {
        display: block;
    }
}

@media (max-width: 560px) {
    .topbar-actions {
        gap: 7px;
    }

    .topbar-actions .btn {
        padding: 7px 9px;
        font-size: 11px;
    }
}


/* اصلاح کامل خوانایی فرم‌ها در تم روشن پنل */
body.panel-theme-light .form-control,
body.panel-theme-light .form-select,
body.panel-theme-light input,
body.panel-theme-light textarea,
body.panel-theme-light select {
    background-color: #ffffff !important;
    background: #ffffff !important;
    color: #1d2630 !important;
    border: 1px solid #cbd3dc !important;
    caret-color: #1d2630;
}

body.panel-theme-light .form-control:focus,
body.panel-theme-light .form-select:focus,
body.panel-theme-light input:focus,
body.panel-theme-light textarea:focus,
body.panel-theme-light select:focus {
    background-color: #ffffff !important;
    color: #1d2630 !important;
    border-color: var(--gold) !important;
    box-shadow: 0 0 0 0.18rem rgba(180, 131, 22, 0.16) !important;
}

body.panel-theme-light input::placeholder,
body.panel-theme-light textarea::placeholder {
    color: #8793a0 !important;
    opacity: 1;
}

body.panel-theme-light label,
body.panel-theme-light .form-label,
body.panel-theme-light .form-text,
body.panel-theme-light .helptext,
body.panel-theme-light small {
    color: #35414d !important;
}

body.panel-theme-light option {
    background: #ffffff;
    color: #1d2630;
}


@media (max-width: 980px) {
    .mobile-theme-form .theme-toggle-btn {
        width: auto;
        height: 34px;
        padding: 0 10px;
        font-size: 11px;
        white-space: nowrap;
    }
}


/* =========================
   صفحه‌بندی
   ========================= */

.pagination-wrap {
    display: flex;
    justify-content: center;
    margin: 32px 0 12px;
}

.pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    flex-wrap: wrap;
}

.page-link {
    min-width: 38px;
    height: 38px;
    padding: 0 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(212, 175, 55, 0.55);
    border-radius: 10px;
    background: var(--surface);
    color: var(--gold);
    text-decoration: none;
    font-size: 13px;
    transition: 0.2s ease;
}

.page-link:hover {
    background: var(--gold);
    color: #171717;
    border-color: var(--gold);
}

.page-link.active {
    background: var(--gold);
    color: #171717;
    border-color: var(--gold);
    font-weight: 800;
    cursor: default;
}

body.panel-theme-light .page-link {
    background: #ffffff;
    color: #9a7015;
    border-color: #d4b766;
}

body.panel-theme-light .page-link:hover,
body.panel-theme-light .page-link.active {
    background: #b48316;
    border-color: #b48316;
    color: #ffffff;
}

@media (max-width: 560px) {
    .pagination {
        gap: 6px;
    }

    .page-link {
        min-width: 34px;
        height: 34px;
        padding: 0 9px;
        font-size: 12px;
    }
}

/* ======================================================
   تم تیره پنل: فرم‌ها، placeholderها، جدول‌ها و دکمه‌ها
   ====================================================== */

.panel-theme-dark {
    --ink: #070708;
    --ink-2: #101114;
    --panel: #16171c;
    --panel-2: #1d1f26;
    --line: rgba(255, 255, 255, 0.10);
    --line-strong: rgba(255, 255, 255, 0.18);
    --text: #f6f1e8;
    --muted: #b9b2a8;
}

/* کادرهای ورود اطلاعات */
.panel-theme-dark input,
.panel-theme-dark textarea,
.panel-theme-dark select,
.panel-theme-dark .form-control,
.panel-theme-dark .form-select {
    background-color: #0d0e12 !important;
    color: #f6f1e8 !important;
    border-color: rgba(232, 180, 90, 0.38) !important;
}

/* نوشته‌های راهنما درون کادرها */
.panel-theme-dark input::placeholder,
.panel-theme-dark textarea::placeholder,
.panel-theme-dark .form-control::placeholder {
    color: #bdb7af !important;
    opacity: 1 !important;
}

/* دکمه‌های اصلی */
.panel-theme-dark .btn-primary,
.panel-theme-dark .btn-success,
.panel-theme-dark .btn-accent {
    background-color: #e8b45a !important;
    border-color: #e8b45a !important;
    color: #16120a !important;
    font-weight: 800;
}

.panel-theme-dark .btn-primary:hover,
.panel-theme-dark .btn-success:hover,
.panel-theme-dark .btn-accent:hover {
    background-color: #f3c97a !important;
    border-color: #f3c97a !important;
    color: #16120a !important;
}

/* دکمه‌های دورخطی */
.panel-theme-dark .btn-outline-primary,
.panel-theme-dark .btn-outline-secondary {
    border-color: #e8b45a !important;
    color: #f3c97a !important;
    background: transparent !important;
}

.panel-theme-dark .btn-outline-primary:hover,
.panel-theme-dark .btn-outline-secondary:hover {
    background-color: #e8b45a !important;
    color: #16120a !important;
}

/* کارت‌ها و جدول‌های صفحات برنامه */
.panel-theme-dark .program-detail-page .card,
.panel-theme-dark .program-detail-page .program-card {
    background: #16171c !important;
    color: #f6f1e8 !important;
    border: 1px solid rgba(255, 255, 255, 0.10) !important;
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.22) !important;
}

.panel-theme-dark .program-detail-page .table,
.panel-theme-dark .program-detail-page .table td,
.panel-theme-dark .program-detail-page .table th {
    background-color: transparent !important;
    color: #f6f1e8 !important;
    border-color: rgba(255, 255, 255, 0.10) !important;
}

.panel-theme-dark .program-detail-page .table-light,
.panel-theme-dark .program-detail-page .table-light th {
    background: #24262e !important;
    color: #f3c97a !important;
}

.panel-theme-dark .program-detail-page .text-muted {
    color: #b9b2a8 !important;
}

.panel-theme-dark .program-detail-page .day-card {
    border-right-color: #e8b45a !important;
}

/* صفحه‌بندی تمام فهرست‌ها */
.pagination-wrap {
    display: flex;
    justify-content: center;
    margin: 28px 0 12px;
}

.pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    flex-wrap: wrap;
}

.pagination .page-link {
    min-width: 38px;
    height: 38px;
    padding: 6px 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--line-strong);
    border-radius: 10px;
    background: var(--panel);
    color: var(--text);
    text-decoration: none;
    font-weight: 700;
    transition: 0.18s ease;
}

.pagination a.page-link:hover,
.pagination .page-link.active {
    background: var(--gold);
    border-color: var(--gold);
    color: #16120a;
}

.panel-theme-light .pagination .page-link {
    background: #ffffff;
    color: #1f2937;
    border-color: #d7dbe2;
}


/* فاصله بین بخش نظرات و دکمه‌های آن */
.comment-actions {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 14px;
    flex-wrap: wrap;
    margin-top: 32px;
}

@media (max-width: 560px) {
    .comment-actions {
        margin-top: 24px;
        gap: 10px;
    }

    .comment-actions .btn {
        width: 100%;
        max-width: 280px;
    }
}

/* کارت نظرات صفحه اصلی */
.user-comment-card {
    display: flex;
    flex-direction: column;
    min-height: 0;
    padding: 20px;
}



.comment-card-head strong {
    font-size: 0.95rem;
}

.comment-card-head span {
    color: var(--gold);
    font-size: 1.5rem;
    line-height: 1;
}

.comment-message-wrapper {
    margin-top: 0;
}

.comment-message {
    color: var(--muted);
    line-height: 1.8;
    margin: 0;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis; /* سه نقطه در پایان متن */
    display: block;
}

.comment-message.is-expanded {
    display: block;
    overflow: visible;
    white-space: normal;
    text-overflow: unset;
}

.comment-toggle-btn {
    border: 0;
    background: transparent;
    padding: 4px 0 0;
    margin: 0;
    color: var(--gold);
    font-family: inherit;
    font-size: 0.8rem;
    font-weight: 700;
    cursor: pointer;
    transition: opacity 0.2s ease;
}

.comment-toggle-btn:hover {
    opacity: 0.75;
    text-decoration: underline;
}

/* فاصله بخش نظرات با دکمه‌ها */
.comments-home-section .comments-actions {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
    margin-top: 42px; /* فاصله از آخرین کارت نظر */
}

/* اگر هیچ نظری وجود نداشت */
.comments-home-section .comments-empty + .comments-actions {
    margin-top: 30px;
}

.comments-home-section .comments-actions .btn {
    min-width: 170px;
    text-align: center;
}

@media (max-width: 560px) {
    .comments-home-section .comments-actions {
        flex-direction: column;
        gap: 12px;
        margin-top: 30px;
    }

    .comments-home-section .comments-actions .btn {
        width: 100%;
        max-width: 270px;
    }
}

/* عنوان صفحه لیست مطالب */
.articles-page-title,
.blog-page-title,
.page-title {
    font-size: clamp(1.8rem, 4vw, 2.8rem);
    font-weight: 900;
    line-height: 1.5;
    color: var(--gold);
    margin-bottom: 28px;
}

/* عنوان هر مقاله در کارت مطالب */
.article-card h2,
.article-card h3,
.article-card .article-title {
    font-size: 1.3rem;
    font-weight: 850;
    line-height: 1.8;
    color: var(--text);
}

/* عنوان اصلی داخل صفحه جزئیات یک مطلب */
.article-detail-title,
.article-detail h1,
.blog-detail h1,
.article-content h1 {
    font-size: clamp(1.9rem, 4vw, 3rem);
    font-weight: 900;
    line-height: 1.65;
    color: var(--gold);
    margin: 0 0 25px;
}

/* تیترهای داخل متن مقاله */
.article-detail h2,
.article-content h2,
.blog-detail h2 {
    font-size: clamp(1.3rem, 2.5vw, 1.75rem);
    font-weight: 850;
    color: var(--gold);
    margin: 35px 0 14px;
    line-height: 1.8;
}

.article-detail h3,
.article-content h3,
.blog-detail h3 {
    font-size: 1.15rem;
    font-weight: 800;
    color: var(--text);
    margin: 26px 0 10px;
}

/* نمایش مطالب مفید به‌صورت زیر هم */
.articles-grid,
.article-grid,
.articles-list {
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 22px;
    width: 100%;
}

/* هر کارت عرض کامل داشته باشد */
.articles-grid .article-card,
.article-grid .article-card,
.articles-list .article-card {
    width: 100%;
    max-width: none;
}

/* چیدمان داخلی کارت: تصویر و محتوا کنار هم در دسکتاپ */
.article-card {
    display: flex !important;
    flex-direction: row;
    align-items: stretch;
    overflow: hidden;
}

.article-card .article-cover,
.article-card img {
    width: 240px;
    min-width: 240px;
    height: 170px;
    object-fit: cover;
    margin: 0;
}

.article-card .card-body,
.article-card .article-content {
    flex: 1;
    padding: 22px;
}

/* موبایل: تصویر بالا و متن زیر آن */
@media (max-width: 650px) {
    .article-card {
        flex-direction: column;
    }

    .article-card .article-cover,
    .article-card img {
        width: 100%;
        min-width: 0;
        height: 190px;
    }

    .article-card .card-body,
    .article-card .article-content {
        padding: 18px;
    }
}

/* صفحه درباره ما بدون تصویر */
.about-text-card {
    max-width: 900px;
    margin: 0 auto;
    padding: clamp(22px, 4vw, 42px);
}

.about-text-card p {
    margin: 0;
    color: var(--muted);
    font-size: clamp(0.98rem, 1.8vw, 1.08rem);
    line-height: 2.35;
    white-space: pre-line;
}

/* تصویر امکانات در صفحه اصلی، بدون ایموجی */
.service-home-image {
    width: 100%;
    height: 150px;
    object-fit: cover;
    border-radius: 14px;
    margin-bottom: 14px;
}

.service-card h6 {
    margin: 0;
    color: var(--text);
    font-size: 1rem;
    font-weight: 850;
}


/* نمایش امکانات باشگاه به‌صورت زیر هم */
.services-list {
    display: flex;
    flex-direction: column;
    gap: 22px;
    max-width: 900px;
    margin: 0 auto;
}

.services-list .service-card {
    width: 100%;
}

.services-list .service-card img {
    width: 100%;
    height: 260px;
    object-fit: cover;
    border-radius: 14px;
}

@media (max-width: 576px) {
    .services-list .service-card img {
        height: 190px;
    }
}
