﻿
html {
  font-size: 14px;
}

html, body {
    height: 100%;
    margin: 0;
}

body {
    display: flex;
    flex-direction: column;
}

main {
    flex: 1; /* فضای اصلی محتوا را پر می‌کند */
}

/* استایل فوتر */
footer {
    background-color: #111; /* کاملاً سیاه */
    color: #fff;
    padding: 30px 20px;
    text-align: center;
    font-family: Tahoma, Arial, sans-serif;
}

    footer a {
        color: inherit;
        text-decoration: none;
    }

.footer-chips a {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin: 5px 10px;
    color: inherit;
}

.footer-chips i {
    font-size: 1.2rem;
}

@font-face {
    font-family: "iransans";
    src: url("../fonts/IRANSansWeb_Light.woff2") format("woff2");
    src: url("../fonts/IRANSansWeb_Light.woff") format("woff");
}

@font-face {
    font-family: "dana";
    src: url("../fonts/dana-fanum-regular.woff2") format("woff2");
    src: url("../fonts/dana-fanum-regular.woff") format("woff");
}

@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

html {
  position: relative;
  min-height: 100%;
}

header {
    position: sticky;
    top: 0;
    background-color: white; /* بهتره رنگ پس‌زمینه داشته باشه */
    z-index: 1000; /* بالاتر از بقیه عناصر باشه */
}

body {
    display: grid;
    grid-template-rows: auto 1fr auto;
    min-height: 100vh;
    margin-bottom: 60px;
    font: normal 300 1.4rem/1.86 "iransans", "Poppins", sans-serif;
    color: #666;
    background-color: #fff;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
  
}

.featurette{
    padding-top:3rem;
}

.features {
    color: blue;
    color: rgb(61, 153, 245);
    font-weight: bold;
    text-align: center;
   
}



.footer {
    grid-row: 3;
    color:black;
}



body, main {
    padding-top: 0 !important;
}


* {
    box-sizing: border-box;
}

/* Position the image container (needed to position the left and right arrows) */
.container {
    position: relative;
}

/* Hide the images by default */
.mySlides {
    display: none;
}

/* Add a pointer when hovering over the thumbnail images */
.cursor {
    cursor: pointer;
}

/* Next & previous buttons */
.prev,
.next {
    cursor: pointer;
    position: absolute;
    top: 40%;
    width: auto;
    padding: 16px;
    margin-top: -50px;
    color: white;
    font-weight: bold;
    font-size: 20px;
    border-radius: 0 3px 3px 0;
    user-select: none;
    -webkit-user-select: none;
}

/* Position the "next button" to the right */
.next {
    right: 0;
    border-radius: 3px 0 0 3px;
}

    /* On hover, add a black background color with a little bit see-through */
    .prev:hover,
    .next:hover {
        background-color: rgba(0, 0, 0, 0.8);
    }

/* Number text (1/3 etc) */
.numbertext {
    color: #f2f2f2;
    font-size: 12px;
    padding: 8px 12px;
    position: absolute;
    top: 0;
}

/* Container for image text */
.caption-container {
    text-align: center;
    background-color: #222;
    padding: 2px 16px;
    color: white;
}

.row:after {
    content: "";
    display: table;
    clear: both;
}

/* Six columns side by side */
.column {
    float: left;
    width: 16.66%;
}

/* Add a transparency effect for thumnbail images */
.demo {
    opacity: 0.6;
}

    .active,
    .demo:hover {
        opacity: 1;
    }



/*اسلایدر پروژه ها*/

.carousel-item {
    display: none;
}

    .carousel-item.active {
        display: block;
    }

.slide-group {
    display: flex;
    gap: 1rem; /* فاصله بین کارت‌ها */
}

    .slide-group .card {
        flex: 1 0 calc(100% / 3 - 1rem);
    }

@media (max-width: 768px) {
    .slide-group .card {
        flex: 1 0 100%;
    }
}
/*اسلایدر پروژه ها انتهای */


/* فاصله‌ها و انیمیشن برای موبایل */
@media (max-width: 768px) {
    .col-sm-6

{
    margin: .5rem auto; /* فاصله از بالا و اطراف */
    float: none; /* غیر فعال کردن float/grid دسکتاپ */
    width: 90%; /* پهنای کمتر برای موبایل */
    opacity: 0; /* شروع انیمیشن با مخفی بودن */
    transform: translateY(20px); /* افکت پایین به بالا */
    animation: fadeInUp 0.6s forwards;
}

/* اضافه کردن فاصله بین ردیف‌ها */
.row {
    margin-bottom: 1rem;
}

}

/* انیمیشن ظاهر شدن */
@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}


/*بخش what we do*/

/* با این کلاس اندازه تصویرها را دقیقاً 500x500 می‌کنیم */
.carousel-500 .carousel-item img {
    width: 500px;
    height: 500px;
    object-fit: cover; /* برش تمیز بدون کشیدگی */
    border-radius: 16px;
}
/* مرکزچین کردن اسلایدها */
.carousel-500 .carousel-item {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 12px;
}
/* در موبایل اگر عرض کمتر از 500 باشد، اجازه بده کمی کوچکتر شود */
@@media (max-width: 520px) {
    .carousel-500 .carousel-item img {
        width: 100%;
        height: auto;
        max-width: 500px;
        max-height: 500px;
    }
}

/*##################################################################################################################33*/
/* ---------- Section why us ---------- */
.section {
    padding: 60px 20px;
    text-align: center;
}

    .section h2 {
        font-size: 2.5rem;
        margin-bottom: 15px;
        color: #222;
    }

    .section p.muted {
        font-size: 1.1rem;
        color: #666;
        margin-bottom: 40px;
    }

/* ---------- Grid ---------- */
.grid {
    display: grid;
    gap: 20px;
}

.grid-4 {
    grid-template-columns: repeat(4, 1fr);
}

/* Responsive */
@media (max-width: 1024px) {
    .grid-4 {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 600px) {
    .grid-4 {
        grid-template-columns: 1fr;
    }
}

/* ---------- Card ---------- */
.card {
    background-color: #fff;
    border-radius: 12px;
    padding: 30px 20px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.08);
    transition: transform 0.3s, box-shadow 0.3s;
}

    .card:hover {
        transform: translateY(-5px);
        box-shadow: 0 8px 25px rgba(0,0,0,0.15);
    }

    .card .icon {
        width: 50px;
        height: 50px;
        color: #4CAF50; /* رنگ آیکون */
        margin-bottom: 20px;
    }

    .card h3 {
        font-size: 1.3rem;
        margin-bottom: 10px;
        color: #222;
    }

    .card p.muted {
        font-size: 1rem;
        color: #666;
    }

/*###########################################################################################################################################*/

/* Courses Section */
#courses {
    padding: 56px 0;
}

    #courses h2 {
        font-size: clamp(22px, 3vw, 34px);
        margin-bottom: 20px;
        font-weight: 700;
    }

/* گرید سه ستونه برای دوره‌ها */
.grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

/* کارت دوره‌ها */
.course {
    display: flex;
    flex-direction: column;
    gap: 12px;
    background: var(--card);
    border: 1px solid rgba(255,255,255,.08);
    border-radius: 18px;
    padding: 18px;
    box-shadow: 0 10px 30px rgba(0,0,0,.25);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

    .course:hover {
        transform: translateY(-6px);
        box-shadow: 0 14px 34px rgba(0,0,0,.35);
    }

    /* تصویر یا جایگاه بندانگشتی */
    .course .thumb {
        aspect-ratio: 16/9;
        background: linear-gradient(145deg, rgba(67,211,255,.12), rgba(122,240,182,.12));
        border: 1px solid rgba(255,255,255,.08);
        border-radius: 14px;
    }

    /* عنوان دوره */
    .course h3 {
        margin: 0;
        font-size: 18px;
        font-weight: 700;
    }

    /* توضیح دوره */
    .course p {
        font-size: 14px;
        color: var(--muted);
        margin: 0;
        line-height: 1.6;
    }

/* برچسب‌ها */
.tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.tag {
    border: 1px solid rgba(255,255,255,.18);
    border-radius: 999px;
    padding: 6px 10px;
    font-size: 12px;
    color: var(--muted);
}

/* دکمه ثبت‌نام */
.course .cta {
    align-self: flex-start;
    margin-top: auto; /* دکمه همیشه پایین کارت می‌ماند */
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

    .course .cta:hover {
        transform: translateY(-2px);
        box-shadow: 0 6px 18px rgba(67,211,255,.4);
    }

/* واکنش‌گرا */
@media (max-width: 900px) {
    .grid-3 {
        grid-template-columns: 1fr; /* در موبایل یک ستونه */
    }
}
/*##################################################################################################################################33*/
.gallery-card {
    position: relative;
    cursor: pointer;
    transition: transform 0.3s ease;
}

    .gallery-card:hover {
        transform: scale(1.05);
    }

    .gallery-card img {
        object-fit: cover;
        height: 250px;
        width: 100%;
        transition: opacity 0.3s ease;
    }

    .gallery-card .overlay-text {
        background-color: rgba(0, 0, 0, 0.5);
        opacity: 0;
        transition: opacity 0.3s ease;
        text-align: center;
    }

    .gallery-card:hover .overlay-text {
        opacity: 1;
    }

.overlay-text h5 {
    font-size: 1.2rem;
    font-weight: bold;
}

@media (max-width: 576px) {
    .gallery-card img {
        height: 200px;
    }
}
/*#######################################################################################################################################*/
/* Testimonials & News Section */
#news {
    padding: 56px 0; /* فاصله عمودی بخش */
}

    #news h3 {
        font-size: 18px;
        margin: 0 0 12px;
        font-weight: 700;
    }

.testimonial {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

    .testimonial p {
        color: var(--muted);
        font-size: 14px;
        margin: 0;
        line-height: 1.6;
    }

/* آواتار برای افراد */
.avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: linear-gradient(145deg, var(--brand), var(--brand-2));
    flex-shrink: 0;
}

/* کارت رویدادها */
#news .card {
    background: var(--card);
    border: 1px solid rgba(255, 255, 255, .06);
    border-radius: 18px;
    padding: 18px;
    box-shadow: 0 10px 30px rgba(0,0,0,.35);
}

    #news .card ul {
        list-style: none;
        padding: 0;
        margin: 0;
        display: grid;
        gap: 10px;
    }

    #news .card li {
        font-size: 14px;
        color: var(--text);
        line-height: 1.6;
    }

    #news .card .tag {
        display: inline-block;
        border: 1px solid rgba(255,255,255,.18);
        border-radius: 999px;
        padding: 4px 10px;
        font-size: 12px;
        color: var(--muted);
        margin-left: 6px;
    }

/* گرید سه‌ستونه */
.grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

/* واکنش‌گرا برای موبایل */
@media (max-width: 900px) {
    .grid-3 {
        grid-template-columns: 1fr; /* یک ستونه در موبایل */
    }
}
/*####################################################################################################################################*/

/* Consultation CTA Section */
#consult {
    padding: 56px 0; /* فاصله عمودی بخش */
}

.cta-banner {
    display: grid;
    grid-template-columns: 1.4fr 1fr; /* دو ستون: متن + فرم */
    gap: 20px;
    align-items: center;
    background: linear-gradient(135deg, rgba(67,211,255,.18), rgba(122,240,182,.18));
    border: 1px solid rgba(255,255,255,.10);
    border-radius: 18px;
    padding: 22px;
}

    .cta-banner h2 {
        font-size: clamp(22px, 3vw, 34px);
        margin: 0 0 12px;
    }

    .cta-banner p {
        color: var(--muted); /* رنگ خاکستری روشن */
        margin: 0;
    }

#consult form.card {
    background: var(--card);
    border: 1px solid rgba(255,255,255,.06);
    border-radius: 18px;
    padding: 18px;
    box-shadow: 0 10px 30px rgba(0,0,0,.35);
    display: flex;
    flex-direction: column;
    gap: 10px;
}

#consult form label {
    font-size: 14px;
    color: var(--text);
}

#consult form input {
    width: 100%;
    padding: 10px;
    margin-top: 6px;
    border-radius: 10px;
    border: 1px solid rgba(255,255,255,.18);
    background: transparent;
    color: var(--text);
}

    #consult form input:focus {
        outline: none;
        border-color: var(--brand); /* تغییر رنگ هنگام فوکوس */
        box-shadow: 0 0 0 2px rgba(67,211,255,.3);
    }

#consult form button.cta {
    margin-top: 12px;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

    #consult form button.cta:hover {
        transform: translateY(-2px);
        box-shadow: 0 8px 20px rgba(67,211,255,.4);
    }

@media (max-width: 900px) {
    .cta-banner {
        grid-template-columns: 1fr; /* در موبایل یک ستونه شود */
    }
}


/*گالری*/

/* حالت پر کردن کامل کادر (برش ممکن است اتفاق بیفتد) */
.img-cover {
    width: 100%;
    height: 250px;
    object-fit: cover;
    border-radius: 0.5rem; /* گوشه گرد مثل card */
}

/* حالت نمایش کل عکس بدون برش (ممکنه اطراف خالی بمونه) */
.img-contain {
    width: 100%;
    height: 250px;
    object-fit: contain;
    background-color: #f8f9fa; /* پس‌زمینه روشن برای پر کردن فضای خالی */
    border-radius: 0.5rem;
}
