﻿/* =========================================================
   PYTHON PROJECTS PAGE
   PREMIUM / FANTASY / MODERN
   ========================================================= */

.python-projects-page {
    direction: rtl;
    width: 100%;
    max-width: 1380px;
    margin: 0 auto;
    padding: 25px 20px 60px;
    color: #263142;
}


/* =========================================================
   HERO
   ========================================================= */

.python-hero {
    position: relative;
    min-height: 285px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 28px;
    padding: 32px 42px;
    margin-bottom: 35px;
    border-radius: 30px;
    overflow: hidden;
    background: linear-gradient( 135deg, #111827 0%, #172554 45%, #312e81 100% );
    color: #fff;
    box-shadow: 0 25px 65px rgba(30, 41, 59, .18);
}


    /* =========================================================
   HERO LIGHT
   ========================================================= */

    .python-hero::before {
        content: "";
        position: absolute;
        width: 500px;
        height: 500px;
        left: -180px;
        top: -250px;
        border-radius: 50%;
        background: radial-gradient( circle, rgba(59, 130, 246, .25), transparent 68% );
        pointer-events: none;
    }


    .python-hero::after {
        content: "";
        position: absolute;
        width: 400px;
        height: 400px;
        right: -180px;
        bottom: -250px;
        border-radius: 50%;
        background: radial-gradient( circle, rgba(139, 92, 246, .25), transparent 68% );
        pointer-events: none;
    }


/* =========================================================
   HERO DECORATIONS
   ========================================================= */

.python-hero-glow {
    position: absolute;
    border-radius: 50%;
    pointer-events: none;
    filter: blur(2px);
}

.python-glow-one {
    width: 120px;
    height: 120px;
    right: 38%;
    top: -50px;
    background: rgba(56, 189, 248, .12);
}

.python-glow-two {
    width: 100px;
    height: 100px;
    left: 35%;
    bottom: -50px;
    background: rgba(168, 85, 247, .12);
}

.python-hero-circle {
    position: absolute;
    border: 1px solid rgba(255,255,255,.07);
    border-radius: 50%;
    pointer-events: none;
}

.python-circle-one {
    width: 220px;
    height: 220px;
    right: 25px;
    top: -100px;
}

.python-circle-two {
    width: 160px;
    height: 160px;
    left: 30%;
    bottom: -90px;
}


/* =========================================================
   HERO CONTENT
   ========================================================= */

.python-hero-content {
    position: relative;
    z-index: 3;
    display: flex;
    align-items: center;
    gap: 25px;
    flex: 1;
    min-width: 0;
}


/* =========================================================
   HERO ICON
   ========================================================= */

.python-hero-icon-wrap {
    position: relative;
    flex-shrink: 0;
}

.python-hero-icon {
    width: 88px;
    height: 88px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 30px;
    background: linear-gradient( 145deg, #3776ab, #2563eb );
    border: 1px solid rgba(255,255,255,.20);
    font-size: 46px;
    color: #ffd43b;
    box-shadow: 0 20px 45px rgba(37, 99, 235, .35), inset 0 1px rgba(255,255,255,.30);
    transform: rotate(-3deg);
    transition: transform .4s ease, box-shadow .4s ease;
}

.python-hero:hover .python-hero-icon {
    transform: rotate(2deg) translateY(-5px);
    box-shadow: 0 25px 55px rgba(37, 99, 235, .45);
}


/* =========================================================
   SPARKLES
   ========================================================= */

.python-sparkle {
    position: absolute;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    color: #fff;
    box-shadow: 0 5px 15px rgba(0,0,0,.18);
    animation: pythonFloat 3s ease-in-out infinite;
}

.sparkle-one {
    width: 28px;
    height: 28px;
    right: -9px;
    top: -8px;
    background: linear-gradient( 135deg, #f59e0b, #ef4444 );
    font-size: 11px;
}

.sparkle-two {
    width: 25px;
    height: 25px;
    left: -7px;
    bottom: 4px;
    background: linear-gradient( 135deg, #8b5cf6, #6366f1 );
    font-size: 9px;
    animation-delay: 1s;
}

@keyframes pythonFloat {

    0%,100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-6px);
    }
}


/* =========================================================
   HERO TEXT
   ========================================================= */

.python-hero-text {
    max-width: 720px;
}

.python-hero-label {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 6px 12px;
    margin-bottom: 10px;
    border-radius: 50px;
    background: rgba(255,255,255,.09);
    border: 1px solid rgba(255,255,255,.12);
    color: #bfdbfe;
    font-size: 10px;
    font-weight: 800;
    backdrop-filter: blur(10px);
}

    .python-hero-label i {
        color: #60a5fa;
    }


/* =========================================================
   HERO TITLE
   ========================================================= */

/*
   عنوان داخل هدر کاملاً سفید
*/

.python-hero-text h1 {
    margin: 0 0 12px;
    color: #ffffff !important;
    font-size: 34px;
    font-weight: 950;
    line-height: 1.6;
    letter-spacing: -.5px;
    text-shadow: 0 3px 20px rgba(0,0,0,.20);
}


    /* اگر داخل عنوان span داشته باشی،
   این بخش هم سفید باقی می‌ماند */

    .python-hero-text h1 span {
        color: #ffffff !important;
    }


.python-hero-text p {
    max-width: 690px;
    margin: 0;
    color: rgba(255,255,255,.78);
    font-size: 14px;
    line-height: 2.2;
}


/* =========================================================
   HERO FEATURES
   ========================================================= */

.python-hero-features {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 20px;
}

    .python-hero-features span {
        display: inline-flex;
        align-items: center;
        gap: 6px;
        padding: 7px 11px;
        border-radius: 10px;
        background: rgba(255,255,255,.07);
        border: 1px solid rgba(255,255,255,.08);
        color: rgba(255,255,255,.80);
        font-size: 9px;
    }

    .python-hero-features i {
        color: #60a5fa;
    }


/* =========================================================
   CODE WINDOW
   ========================================================= */

.python-hero-code {
    position: relative;
    z-index: 3;
    width: 285px;
    min-width: 285px;
    border-radius: 17px;
    overflow: hidden;
    background: rgba(10,15,28,.82);
    border: 1px solid rgba(255,255,255,.10);
    box-shadow: 0 20px 45px rgba(0,0,0,.20);
    backdrop-filter: blur(15px);
    direction: ltr;
}

.code-window-header {
    display: flex;
    align-items: center;
    gap: 6px;
    height: 35px;
    padding: 0 12px;
    background: rgba(255,255,255,.05);
}

    .code-window-header span {
        width: 8px;
        height: 8px;
        border-radius: 50%;
        background: rgba(255,255,255,.35);
    }

    .code-window-header small {
        margin-left: auto;
        color: rgba(255,255,255,.40);
        font-size: 8px;
    }

.code-window-body {
    padding: 15px;
    font-family: Consolas, Monaco, monospace;
    font-size: 11px;
    line-height: 2.1;
}

.code-purple {
    color: #c084fc;
}

.code-blue {
    color: #60a5fa;
}

.code-green {
    color: #4ade80;
}

.code-white {
    color: #e5e7eb;
}

.code-indent {
    padding-left: 18px;
}


/* =========================================================
   SECTION HEADING
   ========================================================= */

.python-section-heading {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 25px;
    padding: 0 5px;
}

.python-section-icon {
    width: 52px;
    height: 52px;
    min-width: 52px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 16px;
    background: linear-gradient( 135deg, #2563eb, #7c3aed );
    color: #fff;
    font-size: 19px;
    box-shadow: 0 10px 25px rgba(79,70,229,.18);
}

.python-section-heading span {
    color: #6366f1;
    font-size: 10px;
    font-weight: 800;
}

.python-section-heading h2 {
    margin: 2px 0;
    color: #202938;
    font-size: 22px;
    font-weight: 900;
}

.python-section-heading p {
    margin: 0;
    color: #8b95a3;
    font-size: 11px;
}


/* =========================================================
   PROJECT GRID
   ========================================================= */

.python-project-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 26px;
}


/* =========================================================
   PROJECT CARD
   ========================================================= */

.python-project-card {
    position: relative;
    display: flex;
    flex-direction: column;
    min-width: 0;
    overflow: hidden;
    border-radius: 22px;
    background: #fff;
    border: 1px solid rgba(30,41,59,.065);
    box-shadow: 0 10px 28px rgba(30,41,59,.055);
    transition: transform .35s ease, box-shadow .35s ease, border-color .35s ease;
}

    .python-project-card:hover {
        transform: translateY(-8px);
        border-color: rgba(37,99,235,.13);
        box-shadow: 0 22px 45px rgba(30,41,59,.11);
    }


/* =========================================================
   PROJECT IMAGE
   ========================================================= */

.python-project-image-wrap {
    position: relative;
    height: 135px;
    overflow: hidden;
    background: linear-gradient( 135deg, #eef2ff, #e0f2fe );
}

.python-project-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform .6s ease;
}

.python-project-card:hover
.python-project-image {
    transform: scale(1.07);
}


/* =========================================================
   IMAGE OVERLAY
   ========================================================= */

.python-image-overlay {
    position: absolute;
    right: 13px;
    top: 13px;
}

    .python-image-overlay span {
        display: inline-flex;
        align-items: center;
        gap: 6px;
        padding: 7px 10px;
        border-radius: 50px;
        background: rgba(15,23,42,.72);
        color: #fff;
        font-size: 9px;
        font-weight: 800;
        backdrop-filter: blur(8px);
    }

    .python-image-overlay i {
        color: #ffd43b;
    }


/* =========================================================
   FLOATING ICON
   ========================================================= */

.python-project-floating-icon {
    position: absolute;
    left: 13px;
    bottom: -18px;
    width: 43px;
    height: 43px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 13px;
    background: linear-gradient( 135deg, #2563eb, #6366f1 );
    color: #fff;
    font-size: 14px;
    border: 3px solid #fff;
    box-shadow: 0 7px 18px rgba(37,99,235,.22);
    transition: transform .3s ease;
}

.python-project-card:hover
.python-project-floating-icon {
    transform: rotate(-8deg) scale(1.05);
}


/* =========================================================
   PROJECT BODY
   ========================================================= */

.python-project-body {
    display: flex;
    flex-direction: column;
    flex: 1;
    padding: 16px 16px 14px;
}


/* =========================================================
   CARD TOP
   ========================================================= */

.python-project-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin-bottom: 7px;
}

.python-project-type {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: #526173;
    /*
       بزرگ‌تر از قبل
    */
    font-size: 10px;
    font-weight: 800;
}

    .python-project-type i {
        color: #2563eb;
    }

.python-level {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 6px 9px;
    border-radius: 8px;
    background: #f1f5f9;
    color: #64748b;
    font-size: 9px;
    font-weight: 700;
}

    .python-level i {
        color: #6366f1;
    }


/* =========================================================
   CARD TITLE
   ========================================================= */

.python-project-title {
    margin: 0 0 11px;
    color: #202938;
    /*
       قبلاً 17px بود
       الان بزرگ‌تر و خواناتر شده
    */
    font-size: 18px;
    font-weight: 900;
    line-height: 1.6;
    transition: color .25s ease;
}

.python-project-card:hover
.python-project-title {
    color: #2563eb;
}


/* =========================================================
   CARD DESCRIPTION
   ========================================================= */

.python-project-description {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin: 0 0 11px;
    color: #000;
    /*
       قبلاً 11px بود
       الان 13px شده
    */
    font-size: 12px;
    font-weight: 500;
    line-height: 1.85;
}


/* =========================================================
   TAGS
   ========================================================= */

.python-project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    margin-top: auto;
}

.python-tag {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 7px 10px;
    border-radius: 12px;
    background: #f5f7fb;
    border: 1px solid #edf0f5;
    color: #000;
    /*
       کمی بزرگ‌تر
    */
    font-size: 9px;
    font-weight: 700;
}

    .python-tag i {
        color: #6366f1;
    }

.python-tag-python {
    color: #3776ab;
    background: rgba(55,118,171,.06);
    border-color: rgba(55,118,171,.10);
}

    .python-tag-python i {
        color: #3776ab;
    }


/* =========================================================
   CARD FOOTER
   ========================================================= */

.python-project-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 8px 11px;
    border-top: 1px solid #edf0f4;
    background: linear-gradient( 145deg, #ffffff, #fafbfc );
}

.python-project-action-info {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
}

.python-download-icon {
    width: 34px;
    height: 34px;
    min-width: 34px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 9px;
    background: rgba(37,99,235,.08);
    color: #2563eb;
    font-size: 11px;
}

.python-project-action-info strong {
    display: block;
    color: #3b4656;
    font-size: 9px;
    font-weight: 800;
}

.python-project-action-info small {
    display: block;
    margin-top: 2px;
    color: #9aa3af;
    font-size: 8px;
}


/* =========================================================
   BUTTON
   ========================================================= */

.python-project-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    flex-shrink: 0;
    padding: 10px 14px;
    border-radius: 10px;
    background: linear-gradient( 135deg, #2563eb, #6366f1 );
    color: #fff;
    text-decoration: none;
    /*
       بزرگ‌تر از قبل
    */
    font-size: 10px;
    font-weight: 800;
    box-shadow: 0 6px 15px rgba(37,99,235,.15);
    transition: transform .25s ease, box-shadow .25s ease;
}

    .python-project-button:hover {
        color: #fff;
        transform: translateY(-2px);
        box-shadow: 0 9px 20px rgba(37,99,235,.23);
    }

    .python-project-button i {
        font-size: 10px;
        transition: transform .25s ease;
    }

    .python-project-button:hover i {
        transform: translateX(-3px);
    }


/* =========================================================
   EMPTY STATE
   ========================================================= */

.python-empty-state {
    grid-column: 1 / -1;
    text-align: center;
    padding: 70px 25px;
    border-radius: 25px;
    background: #fff;
    border: 1px solid #edf0f5;
    box-shadow: 0 12px 35px rgba(30,41,59,.055);
}

.python-empty-icon {
    width: 75px;
    height: 75px;
    margin: 0 auto 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 22px;
    background: linear-gradient( 135deg, #eff6ff, #eef2ff );
    color: #6366f1;
    font-size: 27px;
}

.python-empty-state h3 {
    margin: 0 0 7px;
    color: #293447;
    font-size: 18px;
    font-weight: 850;
}

.python-empty-state p {
    margin: 0;
    color: #8b95a3;
    font-size: 11px;
}


/* =========================================================
   BOTTOM BANNER
   ========================================================= */

.python-bottom-banner {
    position: relative;
    display: flex;
    align-items: center;
    gap: 15px;
    margin-top: 45px;
    padding: 22px 25px;
    border-radius: 20px;
    overflow: hidden;
    background: linear-gradient( 135deg, #eff6ff, #eef2ff );
    border: 1px solid rgba(99,102,241,.10);
}

    .python-bottom-banner::after {
        content: "";
        position: absolute;
        width: 180px;
        height: 180px;
        left: -80px;
        top: -90px;
        border-radius: 50%;
        background: rgba(99,102,241,.06);
    }

.python-bottom-icon {
    position: relative;
    z-index: 2;
    width: 50px;
    height: 50px;
    min-width: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 15px;
    background: linear-gradient( 135deg, #f59e0b, #f97316 );
    color: #fff;
    font-size: 19px;
    box-shadow: 0 8px 20px rgba(245,158,11,.18);
}

.python-bottom-banner h3 {
    margin: 0 0 4px;
    color: #263142;
    font-size: 15px;
    font-weight: 900;
}

.python-bottom-banner p {
    margin: 0;
    color: #7b8594;
    font-size: 10px;
    line-height: 2;
}

.python-bottom-badge {
    margin-right: auto;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 12px;
    border-radius: 50px;
    background: #fff;
    border: 1px solid #e7ebf2;
    color: #3776ab;
    font-size: 10px;
    font-weight: 900;
    box-shadow: 0 5px 15px rgba(30,41,59,.05);
}

    .python-bottom-badge i {
        color: #3776ab;
    }


/* =========================================================
   TABLET
   ========================================================= */

@media (max-width: 1100px) {

    .python-project-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .python-hero-code {
        width: 270px;
        min-width: 270px;
    }

    .python-hero-text h1 {
        font-size: 29px;
        color: #fff !important;
    }

    .python-project-title {
        font-size: 19px;
    }

    .python-project-description {
        font-size: 12px;
    }
}


/* =========================================================
   MOBILE
   ========================================================= */

@media (max-width: 767px) {

    .python-projects-page {
        padding: 15px 10px 40px;
    }


    /* HERO */

    .python-hero {
        min-height: auto;
        display: block;
        padding: 23px 17px;
        margin-bottom: 24px;
        border-radius: 22px;
    }

    .python-hero-content {
        display: flex;
        flex-direction: column;
        text-align: center;
        gap: 17px;
    }


    /* HERO ICON */

    .python-hero-icon {
        width: 78px;
        height: 78px;
        border-radius: 23px;
        font-size: 42px;
    }

    .sparkle-one {
        width: 23px;
        height: 23px;
        right: -7px;
        top: -7px;
        font-size: 8px;
    }

    .sparkle-two {
        width: 21px;
        height: 21px;
        left: -6px;
        font-size: 7px;
    }


    /* HERO TEXT */

    .python-hero-label {
        font-size: 8px;
    }

    .python-hero-text h1 {
        font-size: 23px;
        line-height: 1.7;
        color: #ffffff !important;
    }

        .python-hero-text h1 span {
            color: #ffffff !important;
        }

    .python-hero-text p {
        font-size: 11px;
        line-height: 2.1;
    }


    /* HERO FEATURES */

    .python-hero-features {
        justify-content: center;
        gap: 5px;
        margin-top: 15px;
    }

        .python-hero-features span {
            padding: 6px 8px;
            font-size: 7px;
        }


    /* CODE */

    .python-hero-code {
        width: 100%;
        min-width: 0;
        max-width: 330px;
        margin: 25px auto 0;
    }


    /* SECTION */

    .python-section-heading {
        gap: 10px;
        margin-bottom: 18px;
    }

    .python-section-icon {
        width: 43px;
        height: 43px;
        min-width: 43px;
        border-radius: 13px;
        font-size: 15px;
    }

    .python-section-heading span {
        font-size: 8px;
    }

    .python-section-heading h2 {
        font-size: 17px;
    }

    .python-section-heading p {
        font-size: 8px;
    }


    /* GRID */

    .python-project-grid {
        grid-template-columns: 1fr;
        gap: 17px;
    }


    /* CARD */

    .python-project-card {
        border-radius: 18px;
    }

    .python-project-image-wrap {
        height: 145px;
    }

    .python-project-body {
        padding: 15px 14px 13px;
    }


    /*
       موبایل:
       عنوان بزرگ‌تر
    */

    .python-project-title {
        font-size: 16px;
        line-height: 1.65;
    }

    .python-project-description {
        font-size: 10.5px;
        line-height: 1.9;
    }

    .python-project-type {
        font-size: 9px;
    }

    .python-tag {
        font-size: 8px;
        padding: 6px 9px;
    }


    /* FOOTER */

    .python-project-footer {
        padding: 9px;
        gap: 6px;
    }

    .python-project-action-info {
        display: none;
    }

    .python-project-button {
        width: 100%;
        min-height: 36px;
        font-size: 10px;
    }


    /* BOTTOM */

    .python-bottom-banner {
        align-items: flex-start;
        margin-top: 30px;
        padding: 17px;
        border-radius: 17px;
    }

    .python-bottom-icon {
        width: 40px;
        height: 40px;
        min-width: 40px;
        border-radius: 12px;
        font-size: 15px;
    }

    .python-bottom-banner h3 {
        font-size: 12px;
    }

    .python-bottom-banner p {
        font-size: 8px;
    }

    .python-bottom-badge {
        display: none;
    }
}


/* =========================================================
   VERY SMALL MOBILE
   ========================================================= */

@media (max-width: 380px) {

    .python-projects-page {
        padding-left: 7px;
        padding-right: 7px;
    }

    .python-hero {
        padding: 25px 15px;
    }

    .python-hero-text h1 {
        font-size: 21px;
        color: #ffffff !important;
    }

        .python-hero-text h1 span {
            color: #ffffff !important;
        }

    .python-hero-text p {
        font-size: 10px;
    }

    .python-hero-features span {
        font-size: 6px;
        padding: 5px 7px;
    }

    .python-project-image-wrap {
        height: 155px;
    }

    .python-project-title {
        font-size: 16px;
    }

    .python-project-description {
        font-size: 10.5px;
    }
}
