/* ======================================
   متغیرهای تم
====================================== */
:root {
    --primary-color: #00e676;
    --primary-dark: #00c853;
    --text-color: #333;
    --bg-color: #f9f9f9;
    --card-bg: #fff;
    --header-bg: #222;
    --border-color: #e0e0e0;
    --shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
    --transition: all 0.3s ease;
}

body[data-theme="dark"] {
    --text-color: #e0e0e0;
    --bg-color: #1a1a1a;
    --card-bg: #2d2d2d;
    --header-bg: #0a0a0a;
    --border-color: #404040;
    --shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    margin: 0;
    background: var(--bg-color);
    color: var(--text-color);
    font-family: 'Vazir', 'Tahoma', sans-serif;
    transition: var(--transition);
    line-height: 1.6;
}

a {
    text-decoration: none;
    color: inherit;
}

/* ======================================
   عنوان‌های یکدست و مدرن
====================================== */
.section-title {
    font-size: 2rem;
    font-weight: 800;
    color: var(--text-color);
    text-align: center;
    margin-bottom: 30px;
    position: relative;
    padding-bottom: 15px;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--primary-dark));
    border-radius: 2px;
}

.subsection-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-color);
    text-align: center;
    margin-bottom: 20px;
}

/* ======================================
   هدر - Header
====================================== */
.app-header {
    background: var(--header-bg);
    color: #fff;
    padding: 12px 20px;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.app-header .container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
}

.brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--primary-color);
    padding: 5px 0;
}

.brand img {
    width: 50px;
    height: 50px;
    object-fit: contain;
    display: block;
}

.nav-links {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    align-items: center;
}

.nav-links a {
    color: #eee;
    padding: 8px 14px;
    border-radius: 8px;
    font-weight: 600;
    transition: var(--transition);
    font-size: 0.95rem;
    white-space: nowrap;
}

.nav-links a:hover {
    background: var(--primary-color);
    color: #000;
}

.theme-switcher {
    display: flex;
    gap: 8px;
    background: rgba(255, 255, 255, 0.1);
    padding: 6px;
    border-radius: 12px;
}

.theme-btn {
    background: transparent;
    border: none;
    padding: 8px 16px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.95rem;
    transition: var(--transition);
    color: #fff;
    font-weight: 600;
    white-space: nowrap;
}

.theme-btn:hover {
    background: rgba(255, 255, 255, 0.2);
}

.theme-btn.active {
    background: var(--primary-color);
    color: #000;
}

@media (max-width: 768px) {
    .app-header {
        padding: 10px 15px;
    }

    .app-header .container {
        flex-direction: column;
        gap: 12px;
    }

    .brand {
        font-size: 1.3rem;
    }

    .brand img {
        width: 45px;
        height: 45px;
    }

    .nav-links {
        width: 100%;
        justify-content: center;
        gap: 10px;
    }

    .nav-links a {
        font-size: 0.9rem;
        padding: 6px 12px;
    }

    .theme-switcher {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .brand {
        font-size: 1.2rem;
    }

    .brand img {
        width: 40px;
        height: 40px;
    }

    .nav-links a {
        font-size: 0.85rem;
        padding: 5px 10px;
    }
}


.nav-links a:hover {
    background: var(--primary-color);
    color: #000;
}

.theme-switcher {
    display: flex;
    gap: 8px;
    background: rgba(255, 255, 255, 0.1);
    padding: 6px;
    border-radius: 12px;
}

.theme-btn {
    background: transparent;
    border: none;
    padding: 8px 16px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.95rem;
    transition: var(--transition);
    color: #fff;
    font-weight: 600;
}

.theme-btn:hover {
    background: rgba(255, 255, 255, 0.2);
}

.theme-btn.active {
    background: var(--primary-color);
    color: #000;
}

@media (max-width: 768px) {
    .app-header .container {
        flex-direction: column;
        gap: 15px;
    }

    .nav-links {
        width: 100%;
        justify-content: center;
    }

    .theme-switcher {
        width: 100%;
        justify-content: center;
    }
}

/* ======================================
   Landing Split
====================================== */
.landing-split {
    display: flex;
    gap: 20px;
    padding: 50px 20px;
    background: var(--bg-color);
    flex-wrap: wrap;
    justify-content: center;
}

.landing-box {
    flex: 1 1 300px;
    max-width: 450px;
    background: var(--card-bg);
    padding: 30px;
    border-radius: 20px;
    box-shadow: var(--shadow);
    text-align: center;
    transition: transform 0.3s;
}

.landing-box:hover {
    transform: translateY(-5px);
}

.landing-box h2 {
    font-size: 1.8rem;
    margin-bottom: 15px;
    color: var(--text-color);
}

.landing-box p {
    font-size: 1rem;
    margin-bottom: 20px;
    line-height: 1.8;
}

.landing-box ul {
    list-style: none;
    padding: 0;
    margin-bottom: 20px;
}

.landing-box ul li {
    margin: 10px 0;
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.landing-box.athlete {
    background: var(--card-bg);
    border-right: 5px solid #00c853;
}

.landing-box.coach {
    background: var(--card-bg);
    border-left: 5px solid #2196f3;
}

.cta-button {
    display: inline-block;
    margin-top: 20px;
    background: var(--primary-color);
    padding: 12px 28px;
    border-radius: 30px;
    font-weight: bold;
    color: #000;
    transition: var(--transition);
}

.cta-button:hover {
    background: var(--primary-dark);
    transform: scale(1.05);
}

.login-panel-wrapper {
    width: 100%;
    text-align: center;
    margin-top: 20px;
}

.login-panel-button {
    display: inline-block;
    background: linear-gradient(135deg, #ff7f50, #ff6347);
    color: #fff;
    font-size: 1.15rem;
    font-weight: 600;
    padding: 14px 32px;
    border-radius: 12px;
    transition: var(--transition);
    box-shadow: 0 5px 15px rgba(255, 99, 71, 0.3);
}

.login-panel-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(255, 99, 71, 0.5);
}

/* ======================================
   بخش‌های اسلایدری
====================================== */
.top-coaches,
.top-students,
.posts-section {
    padding: 50px 20px;
    background: var(--bg-color);
    text-align: center;
}

.coach-slider-container,
.slider-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    margin: 20px auto;
    max-width: 90%;
}

.coach-slider,
.student-slider,
.post-slider {
    display: flex;
    gap: 15px;
    overflow-x: auto;
    scroll-behavior: smooth;
    padding: 15px 5px;
    cursor: grab;
    scrollbar-width: thin;
    scrollbar-color: var(--primary-color) transparent;
}

.coach-slider::-webkit-scrollbar,
.student-slider::-webkit-scrollbar,
.post-slider::-webkit-scrollbar {
    height: 6px;
}

.coach-slider::-webkit-scrollbar-thumb,
.student-slider::-webkit-scrollbar-thumb,
.post-slider::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 10px;
}

.coach-slider:active,
.student-slider:active,
.post-slider:active {
    cursor: grabbing;
}

/* ======================================
   فلش‌های مدرن Material Design
====================================== */
.arrow-btn {
    background: var(--card-bg);
    border: 2px solid var(--primary-color);
    width: 48px;
    height: 48px;
    min-width: 48px;
    min-height: 48px;
    border-radius: 50%;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: var(--shadow);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
    flex-shrink: 0;
}

.arrow-btn:hover {
    background: var(--primary-color);
    color: #000;
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(0, 230, 118, 0.4);
}

.arrow-btn .material-icons {
    font-size: 28px;
    line-height: 1;
}

/* ======================================
   کارت مربی - ارتفاع یکسان
====================================== */
.coach-card {
    min-width: 160px;
    max-width: 160px;
    height: 200px;
    background: var(--card-bg);
    padding: 20px;
    border-radius: 16px;
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: var(--shadow);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.coach-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 8px 20px rgba(0, 230, 118, 0.4);
}

.profile-pic img {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    object-fit: cover;
    margin-bottom: 12px;
    border: 3px solid var(--primary-color);
}

.coach-name {
    font-weight: bold;
    font-size: 1rem;
    color: var(--text-color);
    margin-bottom: 8px;
}

.coach-stars {
    color: #ffc107;
    font-size: 0.9rem;
}

/* ======================================
   کارت شاگرد - ارتفاع کمتر
====================================== */
.student-card {
    min-width: 180px;
    max-width: 180px;
    height: 250px;
    background: var(--card-bg);
    padding: 12px;
    border-radius: 16px;
    text-align: center;
    box-shadow: var(--shadow);
    transition: var(--transition);
    cursor: pointer;
    display: flex;
    flex-direction: column;
}

.student-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 8px 20px rgba(0, 230, 118, 0.4);
}

.student-pic {
    width: 100%;
    height: 140px;
    overflow: hidden;
    border-radius: 12px;
    margin-bottom: 10px;
    border: 2px solid var(--primary-color);
}

.student-pic img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 12px;
    transition: var(--transition);
}

.student-desc-short,
.student-desc-full {
    font-size: 0.9rem;
    margin-bottom: 8px;
    color: var(--text-color);
    font-weight: 500;
    line-height: 1.4;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.student-desc-full {
    white-space: normal;
}

.student-coach {
    font-size: 0.85rem;
    color: #777;
    margin-top: auto;
}

body[data-theme="dark"] .student-coach {
    color: #aaa;
}

/* ======================================
   کارت پست - ارتفاع کمتر
====================================== */
.post-card {
    min-width: 180px;
    max-width: 180px;
    height: 280px;
    background: var(--card-bg);
    padding: 12px;
    border-radius: 16px;
    box-shadow: var(--shadow);
    cursor: pointer;
    transition: var(--transition);
    text-align: center;
    display: flex;
    flex-direction: column;
}

.post-card:hover {
    transform: scale(1.05);
    box-shadow: 0 8px 20px rgba(0, 230, 118, 0.4);
}

.post-pic {
    width: 100%;
    height: 120px;
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 10px;
    border: 2px solid var(--primary-color);
}

.post-pic img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 12px;
}

.post-title {
    font-weight: 700;
    font-size: 0.95rem;
    margin-bottom: 8px;
    color: var(--text-color);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.post-desc-short,
.post-desc-full {
    font-size: 0.85rem;
    color: #666;
    margin-bottom: 10px;
    line-height: 1.4;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.post-desc-full {
    white-space: normal;
}

body[data-theme="dark"] .post-desc-short,
body[data-theme="dark"] .post-desc-full {
    color: #aaa;
}

.post-meta {
    font-size: 0.8rem;
    color: #888;
    margin-top: auto;
}

/* دکمه مشاهده بیشتر */
.view-more-wrapper {
    text-align: center;
    margin-top: 25px;
}

.view-more-btn {
    display: inline-block;
    background: var(--primary-color);
    color: #000;
    padding: 12px 30px;
    border-radius: 30px;
    font-weight: bold;
    font-size: 1rem;
    transition: var(--transition);
    box-shadow: var(--shadow);
}

.view-more-btn:hover {
    background: var(--primary-dark);
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 230, 118, 0.5);
}

@media (max-width: 768px) {
    .arrow-btn {
        display: none;
    }

    .coach-slider,
    .student-slider,
    .post-slider {
        overflow-x: scroll;
        -webkit-overflow-scrolling: touch;
        scroll-snap-type: x mandatory;
    }

    .coach-card,
    .student-card,
    .post-card {
        scroll-snap-align: start;
    }
}

/* ======================================
   بخش دانلود اپلیکیشن
====================================== */
#download {
    padding: 50px 30px;
    background: var(--card-bg);
    max-width: 1000px;
    margin: 50px auto;
    border-radius: 24px;
    box-shadow: var(--shadow);
    text-align: center;
}

.app-download-section {
    margin-bottom: 40px;
}

.download-links {
    display: flex;
    justify-content: center;
    gap: 25px;
    flex-wrap: wrap;
}

.download-links a {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 15px;
    transition: var(--transition);
    border-radius: 16px;
    background: var(--bg-color);
    box-shadow: var(--shadow);
}

.download-links a img {
    width: 80px;
    height: 80px;
    object-fit: contain;
}

.download-links a span {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-color);
}

.download-links a:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 230, 118, 0.4);
}

/* ======================================
   گالری عکس‌ها
====================================== */
.gallery {
    padding: 50px 20px;
    text-align: center;
    background: var(--bg-color);
}

.slideshow-container {
    position: relative;
    max-width: 800px;
    margin: 0 auto 20px;
    height: 450px;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: var(--shadow);
}

.slide {
    display: none;
    height: 100%;
}

.slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.gallery-prev,
.gallery-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(0, 0, 0, 0.6);
    color: white;
    font-size: 24px;
    font-weight: bold;
    padding: 12px 18px;
    border-radius: 50%;
    cursor: pointer;
    transition: var(--transition);
    user-select: none;
    z-index: 10;
}

.gallery-prev {
    right: 15px;
}

.gallery-next {
    left: 15px;
}

.gallery-prev:hover,
.gallery-next:hover {
    background-color: var(--primary-color);
    color: #000;
}

.dots-container {
    text-align: center;
    margin-top: 15px;
}

.dot {
    cursor: pointer;
    height: 12px;
    width: 12px;
    margin: 0 5px;
    background-color: #bbb;
    border-radius: 50%;
    display: inline-block;
    transition: var(--transition);
}

.dot.active,
.dot:hover {
    background-color: var(--primary-color);
    transform: scale(1.3);
}

/* ======================================
   فوتر
====================================== */
.footer {
    background-color: var(--header-bg);
    color: #eee;
    padding: 40px 20px 20px;
    direction: rtl;
}

.footer-container {
    max-width: 1100px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 30px;
}

.footer-section {
    flex: 1 1 250px;
    min-width: 250px;
}

.footer-section h3 {
    font-size: 1.3rem;
    margin-bottom: 20px;
    color: var(--primary-color);
    font-weight: 700;
    border-bottom: 2px solid var(--primary-color);
    padding-bottom: 8px;
}

.social-icons a {
    display: inline-block;
    margin: 0 12px 12px 0;
    transition: var(--transition);
}

.social-icons a img {
    width: 40px;
    height: 40px;
    filter: grayscale(40%);
    transition: var(--transition);
}

.social-icons a:hover img {
    filter: grayscale(0%);
    transform: scale(1.2);
}

.footer-section.contact p {
    position: relative;
    padding-right: 30px;
    font-size: 1rem;
    line-height: 1.8;
    color: #eee;
    margin: 12px 0;
}

.footer-section.contact p .icon {
    position: absolute;
    right: 5px;
    top: 50%;
    transform: translateY(-50%);
    width: 18px;
    height: 18px;
    background-repeat: no-repeat;
    background-size: contain;
}

.footer-section.contact p .address-icon {
    background-image: url("data:image/svg+xml,%3Csvg fill='white' height='18' viewBox='0 0 24 24' width='18' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M12 2C8.13 2 5 5.13 5 9c0 5.25 7 13 7 13s7-7.75 7-13c0-3.87-3.13-7-7-7zm0 9.5c-1.38 0-2.5-1.12-2.5-2.5S10.62 6.5 12 6.5s2.5 1.12 2.5 2.5S13.38 11.5 12 11.5z'/%3E%3C/svg%3E");
}

.footer-section.contact p .phone-icon {
    background-image: url("data:image/svg+xml,%3Csvg fill='white' height='18' viewBox='0 0 24 24' width='18' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M6.62 10.79a15.05 15.05 0 006.59 6.59l2.2-2.2a1 1 0 011.11-.21c1.21.49 2.53.76 3.87.76a1 1 0 011 1v3.5a1 1 0 01-1 1C9.94 21.94 2 14 2 4.5a1 1 0 011-1h3.5a1 1 0 011 1c0 1.34.27 2.66.76 3.87a1 1 0 01-.21 1.11l-2.2 2.21z'/%3E%3C/svg%3E");
}

.footer-section.contact p .mobile-icon {
    background-image: url("data:image/svg+xml,%3Csvg fill='white' height='18' viewBox='0 0 24 24' width='18' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M17 1H7a2 2 0 00-2 2v18a2 2 0 002 2h10a2 2 0 002-2V3a2 2 0 00-2-2zm-5 20a1 1 0 110-2 1 1 0 010 2zm5-4H7V5h10z'/%3E%3C/svg%3E");
}

.license-logos a {
    display: inline-block;
    margin: 0 15px 10px 0;
    transition: var(--transition);
}

.license-logos img {
    width: 90px;
    height: auto;
}

.license-logos a:hover {
    transform: scale(1.15);
}

.footer-bottom {
    text-align: center;
    padding: 20px 10px 10px;
    font-size: 0.9rem;
    color: #888;
    border-top: 1px solid #444;
    margin-top: 30px;
}

/* ======================================
   استایل صفحات درونی (about, contact, etc)
====================================== */
.page-content {
    max-width: 1000px;
    margin: 50px auto;
    padding: 40px 30px;
    background: var(--card-bg);
    border-radius: 24px;
    box-shadow: var(--shadow);
    line-height: 1.8;
}

.page-content h1 {
    color: var(--text-color);
    font-size: 2.5rem;
    margin-bottom: 30px;
    text-align: center;
    position: relative;
    padding-bottom: 15px;
}

.page-content h1::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--primary-dark));
    border-radius: 2px;
}

.page-content h2 {
    color: var(--text-color);
    font-size: 1.8rem;
    margin: 30px 0 15px;
}

.page-content p {
    color: var(--text-color);
    font-size: 1.1rem;
    margin-bottom: 20px;
}

.page-content ul {
    margin: 20px 0;
    padding-right: 30px;
}

.page-content ul li {
    color: var(--text-color);
    font-size: 1.05rem;
    margin-bottom: 12px;
}

.contact-info {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin: 30px 0;
}

.contact-item {
    background: var(--bg-color);
    padding: 20px;
    border-radius: 16px;
    text-align: center;
}

.contact-item .material-icons {
    font-size: 48px;
    color: var(--primary-color);
    margin-bottom: 10px;
}

.faq-item {
    background: var(--bg-color);
    padding: 20px;
    border-radius: 16px;
    margin-bottom: 20px;
}

.faq-item h3 {
    color: var(--primary-color);
    font-size: 1.3rem;
    margin-bottom: 10px;
}

.faq-item p {
    font-size: 1.05rem;
}

@media (max-width: 768px) {
    .page-content {
        padding: 30px 20px;
        margin: 30px 20px;
    }

    .page-content h1 {
        font-size: 2rem;
    }

    .slideshow-container {
        height: 300px;
    }
}

@media (max-width: 480px) {
    .section-title {
        font-size: 1.5rem;
    }

    .page-content h1 {
        font-size: 1.7rem;
    }
}
