﻿/* =========================================
   متغیرهای رنگی - تم رسمی سرمه‌ای و طلایی
========================================= */
:root {
    --bg-light: #f4f6f9; /* پس‌زمینه روشن و رسمی */
    --navy-blue: #1b263b; /* سرمه‌ای تیره اداری */
    --navy-dark: #0d1b2a;
    --gold-light: #f2d06b;
    --gold-main: #c59b27;
    --gold-dark: #8c6d18;
    --gold-gradient: linear-gradient(135deg, #f2d06b 0%, #c59b27 50%, #8c6d18 100%);
    --text-dark: #2d3436;
    --text-gray: #636e72;
    --white: #ffffff;
}

/* =========================================
   تنظیمات پایه و عمومی
========================================= */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Vazirmatn', Tahoma, sans-serif;
    background-color: var(--bg-light);
    color: var(--text-dark);
    line-height: 1.9;
    direction: rtl;
}

.container {
    width: 90%;
    max-width: 1100px;
    margin: 0 auto;
}

.text-center {
    text-align: center;
}

.text-right {
    text-align: right;
}

section {
    padding: 80px 0;
}

/* =========================================
   المان روبان (Ribbon) برای عناوین
========================================= */
.ribbon-title {
    position: relative;
    display: inline-block;
    background: var(--gold-gradient);
    color: var(--white);
    padding: 15px 50px;
    font-size: 1.8rem;
    font-weight: 800;
    margin-bottom: 60px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

    .ribbon-title::before, .ribbon-title::after {
        content: "";
        position: absolute;
        top: 100%;
        border-style: solid;
        border-width: 10px 15px;
    }

    .ribbon-title::before {
        left: 0;
        border-color: var(--gold-dark) var(--gold-dark) transparent transparent;
    }

    .ribbon-title::after {
        right: 0;
        border-color: var(--gold-dark) transparent transparent var(--gold-dark);
    }

/* =========================================
   دکمه‌های رسمی طلایی
========================================= */
.btn-gold {
    display: inline-block;
    background: var(--gold-gradient);
    color: var(--white);
    padding: 12px 40px;
    border: none;
    font-size: 1.2rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 10px rgba(197, 155, 39, 0.4);
    text-decoration: none;
    font-family: inherit;
    border-radius: 2px;
}

    .btn-gold:hover {
        background: linear-gradient(135deg, #8c6d18 0%, #c59b27 50%, #f2d06b 100%);
        box-shadow: 0 6px 15px rgba(197, 155, 39, 0.6);
    }

/* =========================================
   هدر (Header) و نویگیشن
========================================= */
.main-header {
    background-color: var(--navy-dark);
    color: var(--white);
    padding: 15px 0;
    border-bottom: 4px solid var(--gold-main);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--gold-light);
}

.hamburger-btn {
    display: none;
    background: none;
    border: none;
    color: var(--gold-light);
    font-size: 28px;
    cursor: pointer;
    padding: 5px;
}

.main-nav ul {
    list-style: none;
    display: flex;
    gap: 25px;
    align-items: center;
}

.main-nav a {
    text-decoration: none;
    color: var(--white);
    font-weight: 600;
    transition: 0.3s;
}

    .main-nav a:hover {
        color: var(--gold-light);
    }

.nav-btn {
    background: var(--gold-gradient);
    color: var(--white) !important;
    padding: 8px 20px;
    border-radius: 4px;
}

/* =========================================
   بخش Hero (اصلی) و افکت‌های نوری
========================================= */
.hero-section {
    position: relative;
    padding: 120px 0;
    text-align: center;
    color: var(--white);
    border-bottom: 5px solid var(--gold-main);
    background-color: var(--navy-blue);
    overflow: hidden;
}

    .hero-section::before {
        content: "";
        position: absolute;
        top: -15px;
        left: -15px;
        right: -15px;
        bottom: -15px;
        background-image: url('image/festival.jpg');
        background-size: cover;
        background-position: center;
        background-repeat: no-repeat;
        filter: blur(2px) brightness(0.7);
        z-index: 1;
    }

    .hero-section > .container {
        position: relative;
        z-index: 2;
    }

/* افکت نورهای متحرک */
.glow-light {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    pointer-events: none;
    z-index: 1;
}

.light-top-right {
    width: 400px;
    height: 400px;
    background: var(--gold-main);
    top: -100px;
    right: -100px;
    animation: floatingLightRight 8s ease-in-out infinite alternate;
}

.light-bottom-left {
    width: 350px;
    height: 350px;
    background: rgba(255, 255, 255, 0.4);
    bottom: -100px;
    left: -100px;
    animation: floatingLightLeft 10s ease-in-out infinite alternate;
}

@keyframes floatingLightRight {
    0% {
        transform: translate(0, 0) scale(0.8);
        opacity: 0.3;
    }

    100% {
        transform: translate(-50px, 50px) scale(1.2);
        opacity: 0.7;
    }
}

@keyframes floatingLightLeft {
    0% {
        transform: translate(0, 0) scale(0.9);
        opacity: 0.2;
    }

    100% {
        transform: translate(60px, -40px) scale(1.3);
        opacity: 0.6;
    }
}

/* متون بخش Hero */
.hero-ribbon {
    display: inline-block;
    background-color: var(--gold-main);
    color: var(--white);
    padding: 5px 25px;
    font-size: 1rem;
    font-weight: bold;
    margin-bottom: 20px;
    position: relative;
}

    .hero-ribbon::before, .hero-ribbon::after {
        content: "";
        position: absolute;
        top: 0;
        width: 0;
        height: 0;
        border-top: 17px solid transparent;
        border-bottom: 17px solid transparent;
    }

    .hero-ribbon::before {
        right: -15px;
        border-left: 15px solid var(--gold-main);
    }

    .hero-ribbon::after {
        left: -15px;
        border-right: 15px solid var(--gold-main);
    }

.hero-content h1 {
    font-size: 3rem;
    margin-bottom: 20px;
    color: var(--gold-light);
}

.hero-subtitle {
    font-size: 1.2rem;
    max-width: 800px;
    margin: 0 auto 40px;
    line-height: 2;
    color: #f1f2f6;
}

/* =========================================
   درباره طرح، جوایز و قوانین
========================================= */
.about-section, .contact-section {
    background-color: var(--white);
}

.awards-section {
    background-color: var(--white);
}

.rules-section {
    background-color: var(--navy-blue);
    color: var(--white);
}

.about-box, .award-box {
    max-width: 900px;
    margin: 0 auto;
    padding: 40px;
    background: var(--bg-light);
    border: 1px solid #e0e0e0;
    border-top: 4px solid var(--gold-main);
    font-size: 1.2rem;
    text-align: justify;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

.award-box {
    text-align: center;
    font-size: 1.4rem;
}

    .award-box strong {
        color: var(--gold-main);
    }

.rules-list {
    list-style: none;
    max-width: 800px;
    margin: 0 auto;
}

    .rules-list li {
        background: rgba(255, 255, 255, 0.05);
        margin-bottom: 15px;
        padding: 20px;
        border-right: 4px solid var(--gold-main);
        font-size: 1.1rem;
    }

        .rules-list li strong {
            color: var(--gold-light);
        }

/* =========================================
   عرصه‌ها (کارت‌های شیشه‌ای و رنگی اختصاصی)
========================================= */
.arenas-section {
    background-color: var(--bg-light);
}

.arenas-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    padding: 20px 0 50px 0;
}

.arena-card {
    position: relative;
    border-radius: 24px;
    padding: 40px 25px;
    text-align: center;
    overflow: hidden;
    z-index: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

    .arena-card h3 {
        font-size: 1.6rem;
        font-weight: 800;
        margin: 0;
        letter-spacing: 0.5px;
        text-shadow: 0 2px 5px rgba(0,0,0,0.4);
    }

    .arena-card p {
        font-size: 0.95rem;
        line-height: 1.8;
        margin: 0;
        text-shadow: 0 1px 3px rgba(0,0,0,0.2);
    }

/* باکس شیشه ای برای آیکن ها */
.icon-wrapper {
    width: 85px;
    height: 85px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 38px;
    margin-bottom: 10px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2), inset 0 0 10px rgba(255, 255, 255, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.3);
    transition: transform 0.5s ease, background 0.3s ease;
}

/* افکت هاور کارت‌ها */
.arena-card:hover {
    transform: translateY(-12px) scale(1.02);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    filter: brightness(1.15);
}

    .arena-card:hover .icon-wrapper {
        transform: scale(1.15) rotate(10deg);
        background: rgba(255, 255, 255, 0.25);
    }

/* افکت عبور نور (Shine Effect) */
.arena-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -150%;
    width: 50%;
    height: 100%;
    background: linear-gradient(to right, rgba(255,255,255,0) 0%, rgba(255,255,255,0.2) 50%, rgba(255,255,255,0) 100%);
    transform: skewX(-25deg);
    transition: all 0.7s ease;
    z-index: -1;
}

.arena-card:hover::before {
    left: 200%;
}

/* --- رنگ‌بندی اختصاصی عرصه‌ها --- */
/* ۱. ورزشی */
.arena-sports {
    background: linear-gradient(145deg, #8B0000, #500000);
    border: 1px solid #ffffff;
}

    .arena-sports h3, .arena-sports p, .arena-sports i {
        color: #ffffff;
    }

/* ۲. علمی ادبی */
.arena-science {
    background: linear-gradient(145deg, #4B6584, #0D1B2A);
    border: 1px solid #F5F5DC;
}

    .arena-science h3, .arena-science p, .arena-science i {
        color: #F5F5DC;
    }

/* ۳. مهندسی */
.arena-engineering {
    background: linear-gradient(145deg, #B85000, #8A3300);
    border: 1px solid #87CEEB;
}

    .arena-engineering h3, .arena-engineering p {
        color: #F5F5DC;
    }

    .arena-engineering i {
        color: #87CEEB;
    }

/* ۴. مذهبی */
.arena-religious {
    background: linear-gradient(145deg, #145A32, #4A5D23);
    border: 1px solid #5C4033;
}

    .arena-religious h3, .arena-religious p {
        color: #F5F5DC;
    }

    .arena-religious i {
        color: #ffffff;
    }

/* ۵. رسانه */
.arena-media {
    background: linear-gradient(145deg, #006666, #7C9873);
    border: 1px solid #ffffff;
}

    .arena-media h3, .arena-media p, .arena-media i {
        color: #ffffff;
    }

/* =========================================
   ارتباط با دبیرخانه
========================================= */
.contact-wrapper {
    display: flex;
    flex-wrap: wrap;
    max-width: 1000px;
    margin: 0 auto;
    background: var(--bg-light);
    border: 1px solid #e0e0e0;
}

.contact-info {
    flex: 1;
    min-width: 300px;
    background-color: var(--navy-blue);
    color: var(--white);
    padding: 40px;
    text-align: right;
}

.info-item {
    margin-bottom: 25px;
}

    .info-item span {
        color: var(--gold-light);
        font-weight: bold;
        display: block;
        margin-bottom: 5px;
    }

.contact-form {
    flex: 2;
    min-width: 300px;
    padding: 40px;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.form-input {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ccc;
    font-family: inherit;
    font-size: 1rem;
    background: var(--white);
}

    .form-input:focus {
        outline: none;
        border-color: var(--gold-main);
    }

/* =========================================
   فوتر و لوگوی موسسه
========================================= */
.main-footer {
    background-color: var(--navy-dark);
    color: #a4b0be;
    text-align: center;
    padding: 20px 0;
    font-size: 0.9rem;
    border-top: 1px solid rgba(255,255,255,0.1);
}

.sponsor-info {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
}

    .sponsor-info p {
        margin: 0;
        font-size: 1.1rem;
        color: var(--gold-main);
        font-weight: bold;
    }

.sponsor-logo {
    height: 60px;
    width: auto;
    object-fit: contain;
}

.copyright-text {
    font-size: 0.9rem;
    opacity: 0.7;
    margin: 0;
}

/* =========================================
   Responsive Design (Mobile & Tablet)
========================================= */
@media screen and (max-width: 768px) {
    p {
        text-align: right !important;
    }

    section {
        padding: 50px 0;
    }

    /* هدر و منوی موبایل */
    .header-container {
        flex-wrap: wrap;
        padding: 5px 0;
    }

    .hamburger-btn {
        display: block;
    }

    .main-nav {
        display: none;
        width: 100%;
        background-color: var(--navy-dark);
        margin-top: 15px;
        border-top: 1px solid var(--gold-main);
    }

        .main-nav.active {
            display: block;
        }

        .main-nav ul {
            flex-direction: column;
            width: 100%;
            gap: 0;
        }

            .main-nav ul li {
                width: 100%;
            }

        .main-nav a {
            display: block;
            width: 100%;
            padding: 12px 20px;
            text-align: right;
            border-bottom: 1px solid rgba(255, 255, 255, 0.05);
        }

    .nav-btn {
        border-radius: 0;
        text-align: center !important;
    }

    /* هیرو و عناوین */
    .hero-section {
        padding: 60px 0;
    }

    .hero-content h1 {
        font-size: 1.8rem;
    }

    .hero-subtitle {
        font-size: 1rem;
    }

    .ribbon-title {
        font-size: 1.3rem;
        padding: 10px 30px;
        margin-bottom: 40px;
    }

    /* گریدها و فرم‌ها */
    .arenas-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .rules-list li, .about-box, .award-box {
        font-size: 0.95rem;
        padding: 20px;
    }

    .contact-wrapper {
        flex-direction: column;
    }

    .contact-info, .contact-form {
        width: 100%;
        padding: 25px;
    }

    /* فوتر */
    .sponsor-info {
        flex-direction: column;
        gap: 10px;
    }
}

@media screen and (max-width: 480px) {
    .hero-content h1 {
        font-size: 1.5rem;
    }

    .btn-gold {
        width: 100%;
        text-align: center;
        padding: 12px 20px;
    }
}
