/* ==========================================
   تنظیمات کلی و فونت‌ها
   ========================================== */

@font-face {
    font-family: "IranSans";
    src: url('assets/fonts/IRANSansWeb.woff2') format('woff2'),
         url('assets/fonts/IranSans.woff') format('woff');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Vazir', sans-serif;
    line-height: 1.6;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ==========================================
   هدر و منوی ناوبری
   ========================================== */

header {
    background: rgba(255, 193, 7, 0.9);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 193, 7, 0.3);
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    transition: all 0.3s ease;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
    position: relative;
}

.logo {
    font-size: 1.8rem;
    font-weight: 700;
    color: #2c3e50;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.1);
}

/* منوی دسکتاپ */
.nav-links {
    display: flex;
    gap: 2rem;
    list-style: none;
    transition: all 0.3s ease;
}

.nav-links.desktop-menu {
    display: flex;
}

.nav-links a {
    color: #2c3e50;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
}

.nav-links a:hover {
    color: #34495e;
    transform: translateY(-2px);
}

/* منوی همبرگری */
.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    padding: 5px;
    z-index: 1001;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background-color: #2c3e50;
    margin: 3px 0;
    transition: 0.3s;
    border-radius: 2px;
}

.hamburger.active span:nth-child(1) {
    transform: rotate(-45deg) translate(-5px, 6px);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:nth-child(3) {
    transform: rotate(45deg) translate(-5px, -6px);
}

/* منوی موبایل */
.nav-links.mobile {
    position: fixed;
    top: 0;
    right: -100%;
    width: 280px;
    height: 100vh;
    background: rgba(255, 193, 7, 0.98);
    backdrop-filter: blur(10px);
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 3rem;
    z-index: 1000;
    transition: right 0.3s ease;
    box-shadow: -5px 0 15px rgba(0,0,0,0.1);
    display: none;
}

.nav-links.mobile.active {
    right: 0;
    display: flex;
}

.nav-links.mobile a {
    font-size: 1.2rem;
    padding: 1rem 2rem;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
    width: 200px;
    text-align: center;
    justify-content: center;
}

.nav-links.mobile a:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: scale(1.05);
}

/* ==========================================
   محتوای اصلی
   ========================================== */

main {
    padding-top: 100px;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* بخش هیرو */
.hero {
    text-align: center;
    color: white;
    margin-bottom: 4rem;
}

.hero h1 {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    text-shadow: 3px 3px 6px rgba(0,0,0,0.3);
    animation: fadeInDown 1s ease-out;
}

.hero p {
    font-size: 1.3rem;
    margin-bottom: 2rem;
    opacity: 0.9;
    animation: fadeInUp 1s ease-out 0.3s both;
}

/* ==========================================
   دسته‌بندی محصولات
   ========================================== */

.categories {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 3rem;
    margin: 4rem 0;
    padding: 0 2rem;
}

.category-card {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 20px;
    padding: 3rem 2rem;
    text-align: center;
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.category-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.4), transparent);
    transition: left 0.5s;
}

.category-card:hover::before {
    left: 100%;
}

.category-card:hover {
    transform: translateY(-10px) scale(1.03);
    box-shadow: 0 30px 60px rgba(0,0,0,0.2);
}

.category-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 1.5rem;
    background: linear-gradient(45deg, #ff6b6b, #ee5a24);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    color: white;
    box-shadow: 0 10px 30px rgba(238, 90, 36, 0.3);
    animation: pulse 2s infinite;
}

.category-card:nth-child(2) .category-icon {
    background: linear-gradient(45deg, #4834d4, #686de0);
    box-shadow: 0 10px 30px rgba(72, 52, 212, 0.3);
}

.category-card h3 {
    font-size: 1.8rem;
    color: #2c3e50;
    margin-bottom: 1rem;
    font-weight: 600;
}

.category-card p {
    color: #7f8c8d;
    font-size: 1.1rem;
    line-height: 1.8;
    margin-bottom: 2rem;
}

.category-btn {
    background: linear-gradient(45deg, #667eea, #fff);
    color: white;
    border: none;
    padding: 1rem 0.5rem;
    border-radius: 50px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.3);
}

.category-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(102, 126, 234, 0.4);
}

/* ==========================================
   بخش سئو
   ========================================== */

.seo-section {
    background: rgba(255, 255, 255, 0.95);
    margin: 4rem 0 2rem;
    padding: 3rem;
    border-radius: 20px;
    backdrop-filter: blur(10px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
}

.seo-section h2 {
    color: #2c3e50;
    font-size: 2rem;
    margin-bottom: 1.5rem;
    text-align: center;
}

.seo-content {
    color: #34495e;
    font-size: 1rem;
    line-height: 1.8;
    text-align: justify;
}

/* ==========================================
   مودال‌ها
   ========================================== */

.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(5px);
    animation: fadeIn 0.3s ease-out;
}

.modal-content {
    background: white;
    margin: 5% auto;
    padding: 0;
    border-radius: 15px;
    max-width: 600px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: 0 25px 50px rgba(0,0,0,0.3);
    animation: slideIn 0.3s ease-out;
    position: relative;
}

.modal-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 2rem;
    border-radius: 15px 15px 0 0;
    text-align: center;
}

.modal-header h2 {
    font-size: 2rem;
    margin: 0;
    font-weight: 600;
}

.modal-body {
    padding: 2rem;
    line-height: 1.8;
    color: #2c3e50;
}

.close {
    position: absolute;
    left: 1rem;
    top: 1rem;
    color: white;
    font-size: 2rem;
    font-weight: bold;
    cursor: pointer;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.close:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: rotate(90deg);
}

.contact-info {
    display: grid;
    gap: 1.5rem;
    margin-top: 1rem;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    background: #f8f9fa;
    border-radius: 10px;
    transition: all 0.3s ease;
}

.contact-item:hover {
    background: #e9ecef;
    transform: translateY(-2px);
}

.contact-icon {
    width: 50px;
    height: 50px;
    background: linear-gradient(45deg, #667eea, #764ba2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.2rem;
}

.contact-details h4 {
    margin: 0;
    color: #2c3e50;
    font-size: 1.1rem;
}

.contact-details p {
    margin: 0.5rem 0 0 0;
    color: #7f8c8d;
}

/* ==========================================
   انیمیشن‌ها
   ========================================== */

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
    100% {
        transform: scale(1);
    }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-50px) scale(0.9);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* ==========================================
   عناصر شناور پس‌زمینه
   ========================================== */

.floating-shapes {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
}

.shape {
    position: absolute;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    animation: float 6s ease-in-out infinite;
}

.shape:nth-child(1) {
    width: 100px;
    height: 100px;
    top: 20%;
    left: 10%;
    animation-delay: 0s;
}

.shape:nth-child(2) {
    width: 150px;
    height: 150px;
    top: 60%;
    right: 10%;
    animation-delay: 2s;
}

.shape:nth-child(3) {
    width: 80px;
    height: 80px;
    bottom: 20%;
    left: 20%;
    animation-delay: 4s;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-20px);
    }
}

/* ==========================================
   ریسپانسیو - تبلت و موبایل
   ========================================== */

@media (max-width: 768px) {
    .hero h1 {
        font-size: 2.5rem;
    }
    
    .hero p {
        font-size: 1.1rem;
    }
    
    .categories {
        grid-template-columns: 1fr;
        gap: 2rem;
        padding: 0 1rem;
    }
    
    .hamburger {
        display: flex;
    }
    
    .nav-links.desktop-menu {
        display: none;
    }
    
    .nav-links.mobile {
        display: flex;
    }
    
    .category-card {
        padding: 2rem 1.5rem;
    }
    
    .seo-section {
        margin: 2rem 1rem;
        padding: 2rem;
    }

    .modal-content {
        width: 95%;
        margin: 10% auto;
    }

    .modal-header h2 {
        font-size: 1.5rem;
    }

    .modal-body {
        padding: 1.5rem;
    }

    .contact-item {
        flex-direction: column;
        text-align: center;
        gap: 0.5rem;
    }
}

@media (max-width: 480px) {
    .hero h1 {
        font-size: 2rem;
    }
    
    main {
        padding-top: 120px;
    }

    .hamburger {
        display: flex;
    }

    .nav-links.mobile a {
        font-size: 1.1rem;
        width: 180px;
    }

    .contact-info {
        gap: 1rem;
    }

    .contact-item {
        padding: 1rem 0.5rem;
    }

    .modal-content {
        margin: 15% auto;
    }

    .category-icon {
        width: 70px;
        height: 70px;
        font-size: 2rem;
    }

    .category-card h3 {
        font-size: 1.5rem;
    }

    .category-card p {
        font-size: 1rem;
    }

    .category-btn {
        padding: 0.8rem 2rem;
        font-size: 1rem;
    }
}