:root {
    /* رنگ‌های پایه */
    --bg-main: #02040a;       /* مشکی عمیق */
    --bg-card: rgba(15, 20, 28, 0.5); /* خیلی تیره و شیشه‌ای */
    
    /* رنگ‌های اختصاصی (Accent Colors) */
    --cyan: #00f0ff;
    --green: #00ff9d;
    --purple: #bd00ff;
    
    --text-white: #ffffff;
    --text-muted: #8892b0;
    
    --border-dim: rgba(255, 255, 255, 0.03); /* بوردر خیلی محو */
    --font-sans: 'Inter', sans-serif;
    --font-mono: 'JetBrains Mono', monospace;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
    background-color: var(--bg-main);
    color: var(--text-white);
    font-family: var(--font-sans);
    line-height: 1.6;
    overflow-x: hidden;
}

/* --- پترن زمینه (خیلی محو) --- */
.grid-overlay {
    position: fixed; top: 0; left: 0; width: 100%; height: 100vh;
    background-image: 
        linear-gradient(var(--border-dim) 1px, transparent 1px),
        linear-gradient(90deg, var(--border-dim) 1px, transparent 1px);
    background-size: 60px 60px;
    opacity: 0.3; pointer-events: none; z-index: -1;
}

/* نورهای محیطی (Ambient Lights) */
.ambient-light {
    position: fixed; border-radius: 50%; filter: blur(180px); z-index: -2; opacity: 0.15; /* نور خیلی کم */
}
.light-cyan { width: 600px; height: 600px; background: var(--cyan); top: -200px; left: 10%; }
.light-purple { width: 500px; height: 500px; background: var(--purple); bottom: -100px; right: 0; }

/* --- Navbar --- */
.navbar {
    position: fixed; top: 20px; left: 0; right: 0;
    display: flex; justify-content: center; z-index: 1000;
}
.nav-inner {
    background: rgba(5, 5, 10, 0.8);
    backdrop-filter: blur(12px);
    border: 1px solid var(--border-dim);
    padding: 10px 25px; border-radius: 100px;
    display: flex; align-items: center; gap: 40px;
}
.brand { font-weight: 700; color: white; text-decoration: none; font-size: 1rem; }
.dot { color: var(--cyan); }

.nav-menu { display: flex; gap: 24px; }
.nav-menu a { color: var(--text-muted); text-decoration: none; font-size: 0.85rem; font-weight: 500; transition: 0.3s; }
.nav-menu a:hover { color: white; }

.btn-contact {
    background: rgba(255,255,255,0.08); color: white; text-decoration: none;
    padding: 6px 18px; border-radius: 50px; font-size: 0.8rem; font-weight: 600;
    transition: 0.3s; border: 1px solid transparent;
}
.btn-contact:hover { background: white; color: black; }

/* --- Hero Section --- */
.main-wrapper { max-width: 1000px; margin: 0 auto; padding: 140px 20px 80px; }
.hero { text-align: center; margin-bottom: 120px; }

.availability-badge {
    display: inline-flex; align-items: center; gap: 8px;
    background: rgba(0, 240, 255, 0.03); border: 1px solid rgba(0, 240, 255, 0.1);
    color: var(--cyan); padding: 5px 14px; border-radius: 50px;
    font-size: 0.75rem; font-weight: 600; margin-bottom: 30px;
}
.pulse-dot { width: 6px; height: 6px; background: var(--cyan); border-radius: 50%; box-shadow: 0 0 8px var(--cyan); }

h1 { font-size: 4rem; font-weight: 800; line-height: 1.1; letter-spacing: -2px; margin-bottom: 24px; }
.gradient-text {
    background: linear-gradient(135deg, #fff 40%, var(--cyan));
    -webkit-background-clip: text; -webkit-text-fill-color: transparent;
}

.hero-desc { font-size: 1.1rem; color: var(--text-muted); max-width: 550px; margin: 0 auto 40px; font-weight: 300; }

.hero-btns { display: flex; justify-content: center; gap: 15px; }
.btn-primary {
    background: var(--cyan); color: #000; padding: 12px 30px; border-radius: 10px;
    font-weight: 700; text-decoration: none; transition: transform 0.2s;
    font-size: 0.95rem;
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 0 25px rgba(0, 240, 255, 0.25); }

.btn-glass {
    background: rgba(255,255,255,0.02); color: white; padding: 12px 30px; border-radius: 10px;
    font-weight: 600; text-decoration: none; border: 1px solid var(--border-dim); transition: 0.3s;
    font-size: 0.95rem;
}
.btn-glass:hover { background: rgba(255,255,255,0.08); border-color: rgba(255,255,255,0.2); }

/* --- Bento Grid (جادوی اصلی) --- */
.section-label { color: var(--text-muted); font-size: 0.8rem; font-weight: 600; text-transform: uppercase; letter-spacing: 1.5px; margin-bottom: 20px; }

.bento-grid {
    display: grid; grid-template-columns: repeat(12, 1fr);
    grid-auto-rows: minmax(260px, auto); gap: 20px;
}

.span-4 { grid-column: span 4; }
.span-5 { grid-column: span 5; }
.span-7 { grid-column: span 7; }
.span-8 { grid-column: span 8; }

/* استایل پایه کارت‌ها - بسیار تیره و محو */
.bento-card {
    background: var(--bg-card);
    border: 1px solid var(--border-dim);
    border-radius: 20px; padding: 30px;
    position: relative; overflow: hidden;
    transition: all 0.5s cubic-bezier(0.2, 0.8, 0.2, 1); /* انیمیشن خیلی نرم */
    display: flex; flex-direction: column; justify-content: space-between;
    /* بلور شیشه‌ای */
    backdrop-filter: blur(10px);
}

/* --- تنظیمات Hover اختصاصی هر کارت --- */

/* 1. کارت مهندسی (Marine) - فیروزه‌ای */
.card-marine:hover {
    border-color: rgba(0, 240, 255, 0.3); /* فقط ۳۰ درصد رنگ */
    box-shadow: 0 10px 40px -10px rgba(0, 240, 255, 0.1); /* سایه خیلی محو */
    transform: translateY(-4px);
}
.icon-cyan { color: var(--cyan); background: rgba(0, 240, 255, 0.05); }

/* 2. کارت لوگو (Logo) - سفید/خنثی */
.card-logo {
    display: flex; align-items: center; justify-content: center;
    background: radial-gradient(circle at center, rgba(255,255,255,0.02), transparent);
}
.card-logo:hover { border-color: rgba(255, 255, 255, 0.15); }
.logo-wrapper { position: relative; width: 110px; height: 110px; }
.my-logo { width: 100%; height: 100%; border-radius: 50%; border: 3px solid rgba(255,255,255,0.8); position: relative; z-index: 2; }
.logo-pulse {
    position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
    width: 140%; height: 140%; background: var(--cyan); opacity: 0.1; filter: blur(25px); border-radius: 50%;
    animation: pulse 4s infinite;
}
@keyframes pulse { 0%, 100% { opacity: 0.1; transform: translate(-50%, -50%) scale(1); } 50% { opacity: 0.2; transform: translate(-50%, -50%) scale(1.1); } }

/* 3. کارت برنامه‌نویسی (Code) - سبز */
.card-code:hover {
    border-color: rgba(0, 255, 157, 0.3);
    box-shadow: 0 10px 40px -10px rgba(0, 255, 157, 0.1);
    transform: translateY(-4px);
}
.icon-green { color: var(--green); background: rgba(0, 255, 157, 0.05); }

/* 4. کارت تحقیق (R&D) - بنفش */
.card-rnd:hover {
    border-color: rgba(189, 0, 255, 0.3);
    box-shadow: 0 10px 40px -10px rgba(189, 0, 255, 0.1);
    transform: translateY(-4px);
}
.icon-purple { color: var(--purple); background: rgba(189, 0, 255, 0.05); }

/* محتوای داخل کارت‌ها */
.icon-square {
    width: 44px; height: 44px; border-radius: 10px;
    display: flex; align-items: center; justify-content: center; font-size: 1.3rem; margin-bottom: 20px;
    border: 1px solid var(--border-dim);
}

.bento-card h3 { font-size: 1.25rem; font-weight: 700; margin-bottom: 10px; color: #fff; }
.bento-card p { font-size: 0.9rem; color: var(--text-muted); line-height: 1.5; margin-bottom: 20px; font-weight: 300; }

.tags { display: flex; gap: 6px; flex-wrap: wrap; }
.tags span {
    font-size: 0.7rem; background: rgba(255,255,255,0.03); padding: 4px 8px; border-radius: 4px; border: 1px solid var(--border-dim); color: var(--text-muted);
}

.code-block {
    background: rgba(0,0,0,0.4); padding: 12px; border-radius: 8px;
    font-family: var(--font-mono); font-size: 0.75rem; border: 1px solid var(--border-dim); color: #a5b4fc;
}
.kwd { color: #c084fc; } .func { color: #60a5fa; } .num { color: #4ade80; } .ret { color: #f472b6; }

.link-arrow { color: var(--purple); text-decoration: none; font-weight: 600; font-size: 0.85rem; }

/* --- Blog Section --- */
.blog-section { margin-top: 100px; }
.blog-header { display: flex; justify-content: space-between; align-items: flex-end; margin-bottom: 25px; border-bottom: 1px solid var(--border-dim); padding-bottom: 15px; }
.view-all { color: var(--cyan); text-decoration: none; font-size: 0.85rem; font-weight: 500; }

.blog-row {
    display: flex; align-items: center; padding: 20px 0;
    border-bottom: 1px solid var(--border-dim); text-decoration: none;
    transition: 0.3s;
}
.blog-row:hover { background: rgba(255,255,255,0.02); padding-left: 10px; padding-right: 10px; border-radius: 8px; border-color: transparent; }

.blog-date { font-family: var(--font-mono); font-size: 0.8rem; color: #555e75; width: 100px; }
.blog-info h4 { color: #e2e8f0; font-size: 1rem; margin-bottom: 4px; font-weight: 500; }
.blog-info span { color: var(--text-muted); font-size: 0.85rem; }
.blog-arrow { margin-left: auto; color: var(--cyan); opacity: 0; transform: translateX(-10px); transition: 0.3s; }
.blog-row:hover .blog-arrow { opacity: 1; transform: translateX(0); }

/* Footer */
footer { margin-top: 80px; padding: 40px 0; text-align: center; border-top: 1px solid var(--border-dim); color: #444; font-size: 0.8rem; }
.socials a { color: #888; margin: 0 10px; text-decoration: none; transition: 0.3s; }
.socials a:hover { color: white; }

/* Responsive */
@media (max-width: 900px) {
    .bento-grid { grid-template-columns: 1fr; }
    .span-4, .span-5, .span-7, .span-8 { grid-column: span 1; }
    .card-logo { display: none; }
    h1 { font-size: 2.8rem; }
    .navbar { width: 95%; }
    .nav-menu { display: none; }
}

/* Animation */
.fade-in { opacity: 0; transform: translateY(20px); animation: fadeInUp 0.8s forwards; }
.delay-1 { animation-delay: 0.1s; } .delay-2 { animation-delay: 0.3s; } .delay-3 { animation-delay: 0.5s; }
@keyframes fadeInUp { to { opacity: 1; transform: translateY(0); } }