@import url(fontiran.css);

/* ===== استایل عمومی ===== */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: IRANSansX, sans-serif !important;
    direction: rtl;
    background: url('<?= e($site_background) ?>') no-repeat center center fixed;
    background-size: cover;
    color: #fff;
    margin: 0;
    padding: 0;
    min-height: 100vh;
    padding-top: 85px !important;
    display: flex;
    flex-direction: column;
}

h1, h2, h3, h4, h5, h6, input, textarea {
    font-family: IRANSansX, sans-serif !important;
}

::placeholder {
    color: #f5f5f5;
    opacity: 1;
}

:-ms-input-placeholder { color: #f5f5f5; }
::-ms-input-placeholder { color: #f5f5f5; }

/* ===== فرم ورود/ثبت‌نام ===== */
.auth-page {
    display: flex;
    align-items: center;
    justify-content: center;
}

.card {
    background: rgba(20, 20, 20, 0.95);
    box-shadow: 0 0 25px rgba(138, 43, 255, 0.7);
    border-radius: 15px;
    padding: 40px;
    width: 100%;
    max-width: 500px;
    animation: fadeInUp 0.6s ease-out;
}

.logo {
    text-align: center;
    margin-bottom: 25px;
}

.logo img {
    width: 120px;
    filter: drop-shadow(0 0 12px rgba(138, 43, 255, 0.9));
}

.form-control {
    background-color: #121212;
    border: 1px solid #5e17eb;
    color: #fff;
    border-radius: 8px;
    font-size: 18px;
    padding: 10px 14px;
}

.form-control:focus {
    background-color: #1c1c1c;
    border-color: #8a2bff;
    box-shadow: 0 0 12px rgba(138, 43, 255, 0.8);
    color: #fff;
}

.form-check-input {
    background-color: transparent;
    border: 2px solid #5e17eb;
}

.form-check-input:checked {
    background-color: #8a2bff;
    border-color: #8a2bff;
}

.btn-gaming {
    background: linear-gradient(90deg, #5e17eb, #8a2bff);
    border: none;
    color: #fff;
    font-weight: bold;
    text-transform: uppercase;
    padding: 12px 20px;
    border-radius: 8px;
    transition: all 0.3s ease;
    font-size: 18px;
}

.btn-gaming:hover {
    background: linear-gradient(90deg, #8a2bff, #5e17eb);
    box-shadow: 0 0 18px rgba(138, 43, 255, 0.9);
}

@keyframes fadeInUp {
    from { transform: translateY(40px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

/* ===== هدر ===== */
.dashboard-header, header {
    position: fixed !important;
    top: 0;
    left: 0;
    right: 0;
    z-index: 9999 !important;
    background: rgba(26, 0, 51, 0.85);
    backdrop-filter: blur(20px);
    border-bottom: 2px solid rgba(138, 43, 255, 0.3);
    padding: 15px 40px;
    box-shadow: 0 4px 30px rgba(138, 43, 255, 0.4);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.dashboard-header.scrolled {
    background: rgba(26, 0, 51, 0.95);
    box-shadow: 0 4px 40px rgba(138, 43, 255, 0.6);
    padding: 10px 40px;
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1400px;
    margin: 0 auto;
    width: 100%;
    position: relative;
    z-index: 10000;
}

.header-logo {
    position: relative;
    z-index: 10001;
    display: flex;
    align-items: center;
    font-weight: bold;
    font-size: 1.2rem;
    gap: 8px;
}

.header-logo img, header .logo img {
    height: 50px;
    border-radius: 12px;
    box-shadow: 0 0 8px rgba(138, 43, 255, 0.99);
    filter: drop-shadow(0 0 8px rgba(138, 43, 255, 1));
    border: 2px solid #fff;
}

.desktop-nav, header nav {
    display: flex;
    gap: 20px;
    align-items: center;
    position: relative;
    z-index: 10001;
}

.desktop-nav a, header nav a {
    color: #ffe46a;
    text-decoration: none;
    font-weight: bold;
    font-size: 1.05rem;
    transition: all 0.3s ease;
    white-space: nowrap;
    padding: 5px 10px;
    border-radius: 5px;
}

.desktop-nav a:hover, header nav a:hover {
    color: #fff;
    text-shadow: 0 0 10px #8a2bff, 0 0 3px #23233c;
    transform: translateY(-2px);
    background-color: rgba(138,43,255,0.2);
}

.desktop-nav .btn-profile {
    background: rgba(138, 43, 255, 0.15);
    border: 1px solid #8a2bff77;
    padding: 8px 20px;
    border-radius: 25px;
    color: #fff !important;
}

.desktop-nav .btn-profile:hover {
    background: rgba(138, 43, 255, 0.3);
    box-shadow: 0 0 15px rgba(138, 43, 255, 0.6);
}

.hamburger-btn {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 5px;
    z-index: 10001;
    position: relative;
}

.hamburger-btn span {
    width: 35px;
    height: 3px;
    background: #fff;
    border-radius: 3px;
    transition: all 0.3s ease;
}

.hamburger-btn.active span:nth-child(1) {
    transform: rotate(45deg) translate(8px, 8px);
}

.hamburger-btn.active span:nth-child(2) {
    opacity: 0;
}

.hamburger-btn.active span:nth-child(3) {
    transform: rotate(-45deg) translate(8px, -8px);
}

.mobile-nav {
    display: none;
    position: fixed !important;
    top: 85px;
    right: -100%;
    width: 280px;
    height: calc(100vh - 85px);
    background: linear-gradient(180deg, rgba(26, 0, 51, 0.95) 0%, rgba(57, 26, 70, 0.95) 100%);
    backdrop-filter: blur(20px);
    box-shadow: -4px 0 30px rgba(138, 43, 255, 0.6);
    border-left: 2px solid rgba(138, 43, 255, 0.3);
    transition: right 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    z-index: 9998 !important;
    overflow-y: auto;
    padding: 25px 20px;
}

.mobile-nav.active {
    right: 0;
}

.mobile-nav a {
    display: block;
    color: #ffe46a;
    text-decoration: none;
    font-weight: bold;
    font-size: 1.1rem;
    padding: 15px 20px;
    margin: 8px 0;
    border-radius: 12px;
    background: rgba(138, 43, 255, 0.15);
    border: 1px solid rgba(138, 43, 255, 0.3);
    transition: all 0.3s ease;
    text-align: center;
}

.mobile-nav a:hover,
.mobile-nav a:active {
    background: rgba(138, 43, 255, 0.35);
    color: #fff;
    transform: translateX(-5px);
    box-shadow: 0 0 15px rgba(138, 43, 255, 0.5);
}

.mobile-nav .user-welcome {
    text-align: center;
    padding: 15px;
    margin: 15px 0;
    background: rgba(255, 228, 106, 0.1);
    border-radius: 12px;
    color: #ffe46a;
    font-size: 0.95rem;
    border: 1px solid rgba(255, 228, 106, 0.3);
}

.mobile-nav .btn-logout {
    background: rgba(220, 53, 69, 0.2) !important;
    border-color: rgba(220, 53, 69, 0.5) !important;
    color: #ff6b6b !important;
}

.mobile-nav .btn-logout:hover {
    background: rgba(220, 53, 69, 0.4) !important;
}

.menu-overlay {
    display: none;
    position: fixed !important;
    top: 85px;
    left: 0;
    width: 100%;
    height: calc(100vh - 85px);
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
    z-index: 9997 !important;
    opacity: 0;
    transition: opacity 0.4s ease;
}

.menu-overlay.active {
    display: block;
    opacity: 1;
}

.mobile-nav::-webkit-scrollbar {
    width: 6px;
}

.mobile-nav::-webkit-scrollbar-track {
    background: rgba(138, 43, 255, 0.1);
    border-radius: 10px;
}

.mobile-nav::-webkit-scrollbar-thumb {
    background: rgba(138, 43, 255, 0.5);
    border-radius: 10px;
}

.mobile-nav::-webkit-scrollbar-thumb:hover {
    background: rgba(138, 43, 255, 0.7);
}

/* ===== محتوا ===== */
main, .container, .content-wrapper {
    position: relative;
    z-index: 1;
    flex: 1;
    padding: 40px 20px;
}

section, article, .modal {
    position: relative;
    z-index: auto;
}

/* ===== کارت‌ها ===== */
.cards, .dashboard-cards-row {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap;
    margin: 30px auto;
    width: 90%;
    max-width: 1200px;
}

.card-info, .stats-card {
    flex: 1;
    min-width: 280px;
    background: rgba(20, 20, 20, 0.85);
    backdrop-filter: blur(10px);
    border-radius: 18px;
    padding: 25px;
    text-align: center;
    box-shadow: 0 0 18px rgba(138,43,255,0.7);
    transition: 0.3s;
    border: 1px solid rgba(138,43,255,0.4);
}

.card-info:hover, .stats-card:hover {
    transform: translateY(-7px);
    box-shadow: 0 0 30px rgba(138,43,255,1.2);
}

.card-info h3, .stats-card h3, .stats-card .stat-title {
    color: #ffda6a;
    margin-bottom: 12px;
    font-size: 1.35rem;
}

.stats-card h3 {
    font-family: 'Orbitron', sans-serif;
    font-size: 2rem;
    color: #8a2bff;
}

.card-info p, .stats-card .stat-value {
    color: #e0e0e0;
    font-size: 0.95rem;
}

.stats-card .icon-box {
    font-size: 2.3rem;
    margin-bottom: 12px;
    text-shadow: 0 0 16px #8a2bff88;
}

.stats-card .stat-value {
    font-size: 1.38rem;
    color: #fff;
    font-weight: bold;
    margin-bottom: 6px;
}
/* ===== کارت‌ها - راست به چپ - 4 تا در هر ردیف ===== */
.dashboard-cards-row {
    direction: rtl !important;
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    justify-content: flex-start;
    margin: 30px auto;
    width: 90%;
    max-width: 1200px;
}

.dashboard-cards-row > [class*="col-"] {
    direction: rtl !important;
    flex: 0 0 calc(25% - 15px);
    max-width: calc(25% - 15px);
}

.stats-card {
    width: 100%;
    background: rgba(20, 20, 20, 0.85);
    backdrop-filter: blur(10px);
    border-radius: 18px;
    padding: 25px;
    text-align: center;
    box-shadow: 0 0 18px rgba(138,43,255,0.7);
    transition: 0.3s;
    border: 1px solid rgba(138,43,255,0.4);
    direction: rtl !important;
}

.stats-card:hover {
    transform: translateY(-7px);
    box-shadow: 0 0 30px rgba(138,43,255,1.2);
}

.stats-card .icon-box {
    font-size: 2.3rem;
    margin-bottom: 12px;
    text-shadow: 0 0 16px #8a2bff88;
}

.stats-card .stat-title {
    font-size: 1.09rem;
    color: #ffe46a;
    margin-bottom: 7px;
}

.stats-card .stat-value {
    font-size: 1.38rem;
    color: #fff;
    font-weight: bold;
    margin-bottom: 6px;
}

/* ===== تبلت - 2 تا در هر ردیف ===== */
@media (max-width: 991.98px) {
    .dashboard-cards-row > [class*="col-"] {
        flex: 0 0 calc(50% - 10px);
        max-width: calc(50% - 10px);
    }
    
    .stats-card { 
        margin-bottom: 18px;
    }
}

/* ===== موبایل - 1 تا در هر ردیف ===== */
@media (max-width: 768px) {
    .dashboard-cards-row > [class*="col-"] {
        flex: 0 0 100%;
        max-width: 100%;
    }
}

.profile-box, .profile-card {
    background: rgba(20, 20, 20, 0.95);
    padding: 20px;
    border-radius: 15px;
    box-shadow: 0 0 15px rgba(138, 43, 255, 0.6);
    margin-bottom: 22px;
}

.profile-box h4, .profile-card h4 {
    color: #8a2bff;
}

.profile-header {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 30px;
    background: rgba(20, 20, 20, 0.85);
    backdrop-filter: blur(10px);
    padding: 20px;
    border-radius: 15px;
    box-shadow: 0px 4px 6px rgba(138, 43, 255, 0.4);
}

.profile-header img {
    width: 100px;
    height: 100px;
    border-radius: 50%;
}

.profile-info {
    color: #ffffff;
}

.profile-info h2 {
    margin: 0;
    font-size: 24px;
}

.profile-info p {
    margin: 5px 0;
    font-size: 14px;
}

.steam-card {
    display: flex;
    gap: 12px;
    align-items: center;
    background: rgba(0, 0, 0, 0.23);
    padding: 14px;
    border-radius: 15px;
    margin-top: 6px;
    box-shadow: 0 2px 14px #8a2bff16;
}

.steam-card img {
    width: 74px;
    height: 74px;
    border-radius: 8px;
}

.steam-card div { 
    color: #e9eef8; 
}

.steam-card a { 
    color: #1f8ef1; 
    text-decoration: none; 
}

.steam-card a:hover { 
    text-decoration: underline;
}

/* ===== بخش رزرو ===== */
.reserve-section {
    width: 90%;
    max-width: 1200px;
    margin: 30px auto;
    background: rgba(255,255,255,0.1);
    backdrop-filter: blur(20px);
    border-radius: 18px;
    padding: 30px;
    box-shadow: 0 0 20px rgba(255,255,255,0.4);
    text-align: center;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid rgba(255,255,255,0.2);
    min-height: 150px;
}

.reserve-section:hover {
    transform: translateY(-10px);
    box-shadow: 0 0 25px rgba(255,255,255,0.6);
}

.reserve-section h2 {
    color: #fff;
    font-size: 1.6rem;
    z-index: 2;
    background: rgba(0,0,0,0.4);
    padding: 10px 20px;
    border-radius: 10px;
}

.reserve-section::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('assets/img/calendar.png') no-repeat center center;
    background-size: cover;
    opacity: 0.2;
    z-index: 1;
}

/* ===== تورنومنت‌ها ===== */
.page-title {
    text-align: center;
    margin-bottom: 40px;
    font-size: 2.5rem;
    font-weight: bold;
    background: linear-gradient(90deg, #8a2bff, #ff00ff, #ffda6a);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 0 30px rgba(138,43,255,0.5);
    animation: glow 2s ease-in-out infinite alternate;
    padding-top: 25px;
}

@keyframes glow {
    from {
        filter: drop-shadow(0 0 10px rgba(138,43,255,0.8));
    }
    to {
        filter: drop-shadow(0 0 20px rgba(255,0,255,1));
    }
}

.nav-tabs {
    border: none;
    justify-content: center;
    margin-bottom: 40px;
    gap: 15px;
}

.nav-tabs .nav-link {
    background: rgba(20,20,20,0.7);
    backdrop-filter: blur(10px);
    border: 2px solid rgba(138,43,255,0.5);
    color: #fff;
    font-weight: bold;
    padding: 12px 30px;
    border-radius: 12px;
    transition: all 0.3s ease;
    font-size: 1.1rem;
}

.nav-tabs .nav-link:hover {
    background: rgba(138,43,255,0.3);
    border-color: #8a2bff;
    transform: translateY(-3px);
    box-shadow: 0 5px 20px rgba(138,43,255,0.6);
}

.nav-tabs .nav-link.active {
    background: linear-gradient(135deg, #8a2bff, #ff00ff);
    border-color: #ff00ff;
    color: #fff;
    box-shadow: 0 5px 25px rgba(138,43,255,0.9);
}

.tournament-cards-wrapper, .tournaments-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 25px;
    justify-content: center;
    width: 90%;
    max-width: 1200px;
    margin: 30px auto;
}

.tournaments-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    max-width: 1400px;
}

.tournament-card {
    flex: 1 1 calc(50% - 12.5px);
    min-width: 350px;
    background: rgba(20,20,20,0.85);
    backdrop-filter: blur(15px);
    border-radius: 18px;
    padding: 30px;
    box-shadow: 0 0 30px rgba(138,43,255,0.8);
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(138,43,255,0.6);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.tournament-cards-wrapper.has-more-than-two .tournament-card {
    flex: 1 1 calc(33.333% - 16.666px);
}

.tournament-card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(138,43,255,0.1), transparent);
    transform: rotate(45deg);
    transition: all 0.6s ease;
}

.tournament-card:hover::before {
    left: 100%;
}

.tournament-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 0 40px rgba(138,43,255,1.5);
}

.tournament-card h2, .tournament-card h3 {
    color: #ffda6a;
    margin-bottom: 10px;
    font-size: 1.7rem;
}

.tournament-card .description {
    color: #e0e0e0;
    font-size: 0.9rem;
    margin-bottom: 15px;
    max-height: 100px;
    overflow: hidden;
    text-overflow: ellipsis;
    min-height: 60px;
    line-height: 1.6;
}

.tournament-card .info-details, .tournament-card .info-section {
    margin-bottom: 20px;
    font-size: 0.95rem;
    color: #c0c0c0;
    line-height: 1.8;
}

.tournament-card .info-details span {
    font-weight: bold;
    color: #fff;
}

.tournament-card .info-details .date-row, .date-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.tournament-card .date-display, .date-box {
    padding: 5px 10px;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: bold;
    text-align: center;
    direction: ltr;
    flex: 1;
}

.tournament-card .date-start, .date-start {
    background-color: rgba(40, 167, 69, 0.4);
    color: #e6ffe6;
    border: 1px solid rgba(40,167,69,0.6);
}

.tournament-card .date-end, .date-end {
    background-color: rgba(220, 53, 69, 0.4);
    color: #ffe6e6;
    border: 1px solid rgba(220,53,69,0.6);
}

.tournament-card .countdown, .countdown {
    background: rgba(138,43,255,0.3);
    padding: 8px 10px;
    border-radius: 10px;
    margin-bottom: 15px;
    font-size: 1.1rem;
    font-weight: bold;
    color: #fff;
    text-shadow: 0 0 5px rgba(138,43,255,0.7);
    direction: ltr;
    text-align: center;
    border: 1px solid rgba(138,43,255,0.6);
}

.tournament-card .fee-capacity-row, .stats-row {
    display: flex;
    justify-content: space-around;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
    background: rgba(255,255,255,0.08);
    border-radius: 10px;
    padding: 10px;
}

.tournament-card .fee-capacity-item, .stat-item {
    text-align: center;
    flex: 1;
}

.tournament-card .fee-capacity-item span, .stat-item .value {
    display: block;
    font-size: 1.1rem;
    color: #fff;
}

.tournament-card .fee-capacity-item small, .stat-item .label {
    font-size: 0.8rem;
    color: #c0c0c0;
}

.stat-item .icon {
    font-size: 1.5rem;
    margin-bottom: 5px;
}

.tournament-card form {
    position: relative;
    margin-top: auto;
}

.tournament-card input {
    width: 100%;
    padding: 12px;
    margin-bottom: 12px;
    border-radius: 8px;
    border: 1px solid #5e17eb;
    background-color: rgba(18,18,18,0.8);
    color: #fff;
    font-family: IRANSansX, sans-serif;
}

.tournament-card input::placeholder {
    color: rgba(255,255,255,0.6);
}

.tournament-card input:focus {
    border-color: #8a2bff;
    box-shadow: 0 0 12px rgba(138,43,255,0.8);
    outline: none;
}

.tournament-card button, .btn-register {
    width: 100%;
    padding: 12px;
    background: linear-gradient(90deg, #5e17eb, #8a2bff);
    border: none;
    color: #fff;
    font-weight: bold;
    text-transform: uppercase;
    border-radius: 8px;
    transition: all 0.3s ease;
    cursor: pointer;
    font-family: IRANSansX, sans-serif;
    margin-top: auto;
    box-shadow: 0 4px 15px rgba(138,43,255,0.5);
}

.tournament-card button:hover, .btn-register:hover {
    background: linear-gradient(90deg, #8a2bff, #5e17eb);
    box-shadow: 0 0 18px rgba(138,43,255,0.9);
    transform: translateY(-2px);
}

.finished-badge {
    background: rgba(108,117,125,0.6);
    padding: 8px 15px;
    border-radius: 20px;
    font-size: 0.9rem;
    color: #fff;
    text-align: center;
    margin-top: auto;
}

.empty-message {
    text-align: center;
    padding: 60px 20px;
    font-size: 1.3rem;
    color: #c0c0c0;
    background: rgba(20,20,20,0.6);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    margin: 40px auto;
    max-width: 600px;
    border: 2px dashed rgba(138,43,255,0.4);
}

.login-required-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.8);
    backdrop-filter: blur(15px);
    border-radius: 18px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 5;
    text-align: center;
    padding: 20px;
}

.login-required-overlay p {
    font-size: 1.2rem;
    margin-bottom: 20px;
    color: #fff;
    font-weight: 500;
}

.login-required-overlay .btn-login-register {
    display: inline-block;
    padding: 10px 25px;
    margin: 0 10px;
    background: linear-gradient(90deg, #5e17eb, #8a2bff);
    border: none;
    color: #fff;
    font-weight: bold;
    border-radius: 8px;
    text-decoration: none;
    transition: all 0.3s ease;
}

.login-required-overlay .btn-login-register:hover {
    background: linear-gradient(90deg, #8a2bff, #5e17eb);
    box-shadow: 0 0 15px rgba(138,43,255,0.9);
    transform: translateY(-2px);
}

.login-required-overlay .btn-login-register.register {
    background: linear-gradient(90deg, #007bff, #0056b3);
}

.login-required-overlay .btn-login-register.register:hover {
    background: linear-gradient(90deg, #0056b3, #007bff);
    box-shadow: 0 0 15px rgba(0, 123, 255, 0.9);
}

/* ===== بازی‌ها ===== */
.search-container {
    margin-top: 20px;
    text-align: center;
}

.search-bar {
    max-width: 600px;
    margin: 0 auto;
    padding: 0 15px;
    display: flex;
    gap: 10px;
    align-items: center;
    justify-content: center;
}

.search-bar input {
    width: 100%;
    border-radius: 20px;
    padding: 8px 16px;
    background: rgba(0, 0, 0, 0.5);
    color: white;
    border: 1px solid rgba(138, 43, 255, 0.6);
}

.search-bar input:focus {
    outline: none;
    box-shadow: 0 0 10px rgba(138, 43, 255, 0.9);
}

.games-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
    margin: 20px 0;
}

/* ادامه کد CSS */

.game-card {
    background: rgba(26, 26, 26, 0.9);
    width: calc(33.333% - 20px);
    min-height: 300px;
    max-width: 300px;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    overflow: hidden;
    transition: transform 0.3s, box-shadow 0.3s;
}

.game-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.5);
}

.game-card img {
    width: 100%;
    height: 160px;
    object-fit: cover;
}

.game-card .card-body {
    text-align: center;
    padding: 15px;
    color: #fff;
}

.game-card .game-title {
    font-weight: bold;
    color: #40c4ff;
    margin-bottom: 8px;
}

.game-card .game-platform {
    font-size: 0.9rem;
    color: #b0bec5;
}

/* ===== جداول ===== */
.registered-tournaments-table, table {
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 0 18px #8a2bff33;
    width: 100%;
}

.registered-tournaments-table th, 
.registered-tournaments-table td {
    background: rgba(28,24,45,0.89);
    color: #fff;
    border: none;
    vertical-align: middle;
    font-size: 0.98rem;
    padding: 12px;
}

.registered-tournaments-table th {
    color: #ffe46a;
    font-size: 1.08rem;
    font-weight: bold;
}

.status-active { 
    color: #19fa8e; 
    font-weight: bold;
}

.status-inactive { 
    color: #8a2bff; 
    font-weight: bold;
}

.status-finished { 
    color: #e95f5f; 
    font-weight: bold;
}

.section-title {
    font-size: 1.2rem;
    font-weight: bold;
    color: #8a2bff;
    margin: 45px 0 20px 0;
    text-shadow: 0 0 14px #5e17eb55;
}

/* ===== هشدارها ===== */
.alert {
    padding: 15px;
    border-radius: 10px;
    margin-bottom: 20px;
    font-weight: bold;
    text-align: center;
    width: 90%;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
}

.alert-success, .alert.success {
    background-color: rgba(26, 0, 51, 0.85);
    color: #40f76d;
    border: 1px solid #40f76d;
}

.alert-danger, .alert.error {
    background-color: rgba(26, 0, 51, 0.85);
    color: #ff6b6b;
    border: 1px solid #ff6b6b;
}

.alert.info {
    background-color: rgba(0, 123, 255, 0.2);
    color: #66b3ff;
    border: 1px solid #66b3ff;
}

/* ===== لیبل‌ها ===== */
label, .profile-label {
    color: #ffe46a;
    margin-bottom: 3px;
    font-weight: bold;
}

/* ===== فوتر ===== */
footer, .footer {
    position: relative;
    z-index: 1;
    background: rgba(0,0,0,0.7);
    backdrop-filter: blur(8px);
    color: #ccc;
    text-align: center;
    padding: 20px;
    margin-top: auto;
    box-shadow: 0 -2px 12px rgba(0,0,0,0.4);
    font-size: 0.9rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

footer .social a, .footer a {
    color: #ffcc00;
    text-decoration: none;
    font-weight: bold;
    transition: color 0.3s ease;
}

footer .social a:hover, .footer a:hover {
    color: #fff;
    text-shadow: 0 0 10px rgba(255,218,106,0.8);
}

footer .enamad { 
    margin-top: 15px; 
}

footer p, .footer p {
    margin: 8px 0;
    line-height: 1.6;
}

/* ===== رفع مشکل Bootstrap ===== */
.modal {
    z-index: 9000 !important;
}

.modal-backdrop {
    z-index: 8999 !important;
}

.dropdown-menu {
    z-index: 9996 !important;
}

.tooltip, .popover {
    z-index: 9995 !important;
}

/* ===== نمودار ===== */
.chart-container {
    width: 100%;
    max-width: 800px;
    margin: auto;
    margin-top: 30px;
}

.stats-section {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-top: 20px;
}

.stats-box {
    flex: 1;
    min-width: 300px;
    background: rgba(20, 20, 20, 0.85);
    backdrop-filter: blur(10px);
    padding: 20px;
    border-radius: 15px;
    box-shadow: 0px 4px 6px rgba(138, 43, 255, 0.4);
}

.stats-box h4 {
    margin-bottom: 15px;
    font-size: 18px;
    color: #ffcc00;
}

.stats-box p {
    margin: 8px 0;
    font-size: 14px;
    color: #cdd6e6;
}

/* ===== ریسپانسیو ===== */
@media (min-width: 769px) and (max-width: 991px) {
    .desktop-nav, header nav {
        gap: 15px;
    }

    .desktop-nav a, header nav a {
        font-size: 0.95rem;
    }
}

@media (min-width: 992px) {
    .desktop-nav, header nav {
        gap: 25px;
    }
}

@media (min-width: 1200px) {
    .tournament-cards-wrapper.has-more-than-two .tournament-card,
    .tournaments-grid .tournament-card {
        flex: 1 1 calc(33.333% - 16.666px);
    }
}

@media (max-width: 1199px) {
    .tournament-cards-wrapper .tournament-card,
    .tournaments-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 25px;
    }

    .tournament-card {
        flex: 1 1 calc(50% - 12.5px);
    }
}

@media (max-width: 991.98px) {
    .stats-card, .card-info { 
        margin-bottom: 18px;
    }
}

@media (max-width: 768px) {
    body {
        padding-top: 75px !important;
    }

    .dashboard-header, header {
        padding: 12px 20px;
    }

    .dashboard-header.scrolled {
        padding: 10px 20px;
    }

    .header-container {
        flex-direction: row;
        justify-content: space-between;
    }

    .desktop-nav, header nav {
        display: none !important;
    }

    .hamburger-btn {
        display: flex;
        order: 1;
    }

    .header-logo {
        order: 2;
        flex: 1;
        text-align: center;
        font-size: 1.1rem;
    }

    .header-logo img, header .logo img {
        height: 45px;
        width: 40px;
    }

    .header-spacer {
        order: 3;
        width: 40px;
    }

    .mobile-nav {
        display: block;
        top: 75px;
        height: calc(100vh - 75px);
    }

    .menu-overlay {
        top: 75px;
        height: calc(100vh - 75px);
    }

    .cards, .reserve-section, .tournament-cards-wrapper, .dashboard-cards-row {
        width: 95%;
        gap: 15px;
    }

    .card-info {
        padding: 20px;
        min-width: unset;
        width: 100%;
    }

    .reserve-section h2, .tournament-card h2, .tournament-card h3 {
        font-size: 1.4rem;
    }

    .reserve-section {
        width: 100%;
        max-width: unset;
        min-height: 120px;
    }

    .tournament-cards-wrapper, .tournaments-grid {
        width: 100%;
        max-width: unset;
        grid-template-columns: 1fr;
        gap: 20px;
        padding: 0 10px;
    }

    .tournament-cards-wrapper .tournament-card,
    .tournaments-grid .tournament-card {
        flex: 1 1 100%;
        min-width: unset;
    }

    .tournament-card {
        padding: 20px;
    }

    .login-required-overlay p {
        font-size: 1rem;
    }

    .login-required-overlay .btn-login-register {
        padding: 8px 20px;
        font-size: 0.9rem;
    }

    .page-title {
        font-size: 1.8rem;
        margin-bottom: 30px;
    }

    .nav-tabs {
        flex-direction: column;
        gap: 10px;
    }

    .nav-tabs .nav-link {
        width: 100%;
        text-align: center;
    }

    .stats-row {
        flex-direction: column;
        gap: 10px;
    }

    .game-card {
        width: calc(50% - 20px);
    }

    .registered-tournaments-table th, 
    .registered-tournaments-table td {
        font-size: 0.92rem;
        padding: 6px;
    }
}

@media (max-width: 576px) {
    .game-card {
        width: calc(100% - 20px);
    }

    .stats-box {
        min-width: unset;
    }
}

@media (max-width: 480px) {
    body {
        padding-top: 70px !important;
    }

    .dashboard-header, header {
        padding: 10px 15px;
    }

    .mobile-nav {
        top: 70px;
        height: calc(100vh - 70px);
        width: 260px;
    }

    .menu-overlay {
        top: 70px;
        height: calc(100vh - 70px);
    }

    .page-title {
        font-size: 1.5rem;
    }

    .tournament-card h2, .tournament-card h3 {
        font-size: 1.2rem;
    }

    .btn-register, .tournament-card button {
        font-size: 1rem;
        padding: 12px;
    }
}
body {
    background: #171729;
    font-family: IRANSansX, Yekan, Tahoma;
}
.steam-profile-card {
    background: rgba(38, 38, 58, 0.97);
    border-radius: 18px;
    padding: 36px 28px;
    color: #fff;
    max-width: 1000px;
    margin: 0 auto;
    box-shadow: 0 8px 38px #8a2bff44;
}
.steam-avatar {
    width: 120px; height: 120px;
    border-radius: 18px;
    box-shadow: 0 2px 15px #0005;
    border: 4px solid #ffcc00;
}
.steam-name {
    color: #ffcc00;
    font-weight: bold;
    font-size: 2.2rem;
    margin-bottom: 10px;
    text-shadow: 0 0 16px #8a2bff60;
    direction: ltr;
}
.steam-info-list {
    list-style: none;
    padding: 0;
    margin: 0 0 15px 0;
}
.steam-info-list li {
    margin-bottom: 7px;
    font-size: 1.12rem;
}
.game-card-profile {
    background: rgba(21,21,33,0.92);
    border-radius: 12px;
    padding: 0;
    margin-bottom: 10px;
    transition: transform 0.2s;
    text-align: center;
    overflow: hidden;
    box-shadow: 0 1px 8px #8a2bff33;
}
.game-card-profile:hover {
    transform: translateY(-6px) scale(1.025);
    box-shadow: 0 4px 16px #8a2bff77;
}
.game-cover-profile {
    width: 100%;
    height: 80px;
    object-fit: cover;
    border-top-left-radius: 12px;
    border-top-right-radius: 12px;
}
@media (max-width: 767px) {
    .steam-profile-card { padding: 20px 8px; }
    .steam-avatar { width: 75px; height: 75px; }
    .steam-name { font-size: 1.4rem; }
}

