/* ======================================================================
   Zandi Trading Group — Site Header + Hero
   ====================================================================== */

:root {
    --ztg-pink: #ff4fd8;
    --ztg-purple: #8a4bff;
    --ztg-blue: #5b6bff;
    --ztg-bg: #050308;
    --ztg-bg-soft: #0b0716;
    --ztg-border: rgba(255, 255, 255, 0.1);
    --ztg-gradient: linear-gradient(90deg, var(--ztg-pink), var(--ztg-purple), var(--ztg-blue));
}

.site-header {
    position: relative;
    background: var(--ztg-bg);
}

/* ---------- Nav bar ---------- */
.site-nav {
    position: sticky;
    top: 0;
    z-index: 50;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 18px 5%;
    background: rgba(5, 3, 8, 0.55);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-bottom: 1px solid transparent;
    transition: background 0.3s ease, border-color 0.3s ease, padding 0.3s ease;
}

.site-header.is-scrolled .site-nav {
    background: rgba(5, 3, 8, 0.92);
    border-bottom-color: var(--ztg-border);
    padding-top: 12px;
    padding-bottom: 12px;
}

.site-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    flex-shrink: 0;
}

.site-logo-img {
    display: block !important;
    height: 42px !important;
    max-height: 42px !important;
    width: auto !important;
    max-width: 220px !important;
    object-fit: contain !important;
}

.logo-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: 10px;
    background: var(--ztg-gradient);
    color: #fff;
    font-weight: 800;
    font-size: 18px;
    box-shadow: 0 0 18px rgba(255, 79, 216, 0.45);
}

.logo-text {
    display: flex;
    flex-direction: column;
    line-height: 1.15;
}

.logo-name {
    font-size: 16px;
    font-weight: 800;
    letter-spacing: 1px;
    color: #fff;
}

.logo-sub {
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 1.5px;
    color: rgba(255, 255, 255, 0.5);
}

.site-menu {
    display: flex;
    align-items: center;
    gap: 30px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.site-menu a {
    position: relative;
    color: rgba(255, 255, 255, 0.75);
    text-decoration: none;
    font-size: 14.5px;
    font-weight: 500;
    padding-bottom: 6px;
    transition: color 0.25s ease;
    white-space: nowrap;
}

.site-menu a:hover {
    color: #fff;
}

.site-menu a.is-active {
    color: #ff64c8;
}

.site-menu a.is-active::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 2px;
    background: var(--ztg-gradient);
    border-radius: 2px;
}

.site-nav-actions {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-shrink: 0;
}

.menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 26px;
    height: 20px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
}

.menu-toggle span {
    display: block;
    width: 100%;
    height: 2px;
    background: #fff;
    border-radius: 2px;
    transition: transform 0.25s ease, opacity 0.25s ease;
}

.menu-toggle.is-open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.menu-toggle.is-open span:nth-child(2) { opacity: 0; }
.menu-toggle.is-open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Hero section ---------- */
.hero-section {
    position: relative;
    padding: 70px 5% 0;
    background:
        radial-gradient(600px 400px at 12% 20%, rgba(255, 79, 216, 0.14), transparent 65%),
        radial-gradient(650px 450px at 85% 10%, rgba(91, 107, 255, 0.16), transparent 60%),
        var(--ztg-bg);
    overflow: hidden;
}

.hero-particles { position: absolute; inset: 0; pointer-events: none; z-index: 0; }

.hero-particles .particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: rgba(255, 255, 255, 0.5);
    border-radius: 50%;
    animation: ztg-float 16s infinite linear;
}
.hero-particles .particle:nth-child(1) { left: 8%;  animation-delay: 0s;  animation-duration: 15s; }
.hero-particles .particle:nth-child(2) { left: 22%; animation-delay: 2s;  animation-duration: 12s; width: 6px; height: 6px; }
.hero-particles .particle:nth-child(3) { left: 40%; animation-delay: 4s;  animation-duration: 18s; width: 3px; height: 3px; }
.hero-particles .particle:nth-child(4) { left: 58%; animation-delay: 1s;  animation-duration: 14s; }
.hero-particles .particle:nth-child(5) { left: 74%; animation-delay: 3s;  animation-duration: 16s; width: 5px; height: 5px; }
.hero-particles .particle:nth-child(6) { left: 90%; animation-delay: 5s;  animation-duration: 13s; width: 6px; height: 6px; }

@keyframes ztg-float {
    0%   { transform: translateY(100vh); opacity: 0; }
    10%  { opacity: 1; }
    90%  { opacity: 1; }
    100% { transform: translateY(-10vh); opacity: 0; }
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 1300px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: center;
    gap: 40px;
    padding-bottom: 60px;
}

.hero-eyebrow {
    display: flex;
    align-items: center;
    gap: 14px;
    font-size: clamp(30px, 4.2vw, 46px);
    font-weight: 800;
    letter-spacing: 1px;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 22px;
}

.eyebrow-line {
    display: inline-block;
    width: 44px;
    height: 4px;
    background: var(--ztg-gradient);
    border-radius: 2px;
}

.hero-title {
    font-size: clamp(22px, 3vw, 36px);
    font-weight: 800;
    line-height: 1.15;
    letter-spacing: -0.3px;
    color: #fff;
    margin: 0 0 22px;
}

.hero-title-gradient {
    background: var(--ztg-gradient);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.hero-description {
    font-size: clamp(12px, 1.1vw, 14px);
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.6);
    max-width: 480px;
    margin: 0 0 36px;
}

.hero-actions {
    display: flex;
    align-items: center;
    gap: 22px;
    flex-wrap: wrap;
}

.btn-discover {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 15px 30px;
    border-radius: 50px;
    background: var(--ztg-gradient);
    color: #fff;
    font-weight: 700;
    font-size: 15px;
    text-decoration: none;
    box-shadow: 0 0 25px rgba(255, 79, 216, 0.35);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.btn-discover:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 28px rgba(255, 79, 216, 0.45);
}

.btn-watch {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    color: #fff;
    text-decoration: none;
    font-weight: 600;
    font-size: 15px;
}

.play-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: #fff;
    transition: background 0.25s ease, transform 0.25s ease;
}

.btn-watch:hover .play-icon {
    background: rgba(255, 255, 255, 0.12);
    transform: scale(1.06);
}

/* ---------- Hero visual ---------- */
.hero-visual {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 420px;
}

.hero-frame {
    position: relative;
    width: 100%;
    aspect-ratio: 4 / 5;
    max-height: 560px;
    border-radius: 28px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.12);
    box-shadow:
        0 0 0 1px rgba(255, 79, 216, 0.15),
        0 20px 60px rgba(0, 0, 0, 0.55),
        0 0 60px rgba(138, 75, 255, 0.25);
}

.hero-frame::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 28px;
    padding: 2px;
    background: linear-gradient(160deg, rgba(255, 79, 216, 0.7), rgba(138, 75, 255, 0.15) 40%, rgba(91, 107, 255, 0.6));
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
    z-index: 2;
}

.hero-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
    transition: transform 0.6s ease;
}

.hero-frame:hover .hero-image { transform: scale(1.04); }

.hero-float-icon {
    position: absolute !important;
    z-index: 3;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px !important;
    height: 40px !important;
    min-width: 40px !important;
    min-height: 40px !important;
    max-width: 40px !important;
    max-height: 40px !important;
    flex: 0 0 40px;
    border-radius: 50% !important;
    background: rgba(10, 6, 20, 0.78);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.16);
    box-shadow:
        0 8px 18px rgba(0, 0, 0, 0.45),
        0 0 16px rgba(255, 79, 216, 0.28);
    color: #fff;
    overflow: hidden !important;
    box-sizing: border-box;
}

.hero-float-icon img {
    width: 100% !important;
    height: 100% !important;
    max-width: 100% !important;
    max-height: 100% !important;
    object-fit: cover !important;
    border-radius: 50%;
    display: block;
}

.icon-bottom { box-shadow: 0 12px 30px rgba(0, 0, 0, 0.45), 0 0 26px rgba(110, 168, 255, 0.28); }

.icon-top {
    top: -10px;
    left: 6px;
    animation: ztg-drift 3s ease-in-out infinite;
}

.icon-bottom {
    bottom: -10px;
    right: 6px;
    animation: ztg-drift 3s ease-in-out infinite 1.2s;
}

@keyframes ztg-drift {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}

/* ---------- Stats bar ---------- */
.hero-stats {
    position: relative;
    z-index: 1;
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px 10px;
    padding: 30px clamp(20px, 4vw, 50px);
    border-radius: 40px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--ztg-border);
    box-shadow: 0 0 40px rgba(138, 75, 255, 0.12);
    transform: translateY(40px);
}

/* اگر تعداد آیتم‌ها دقیقاً ۴ عدد باشد، ظاهر گرد و کشیده‌ی قبلی حفظ می‌شود */
.hero-stats:has(.stat-item:nth-child(4):last-child) {
    border-radius: 100px;
    grid-template-columns: repeat(4, 1fr);
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 14px;
    min-width: 0;
}

.stat-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    border-radius: 50%;
    flex-shrink: 0;
}

.stat-icon .material-icons {
    font-size: 24px;
    line-height: 1;
}

.stat-icon-img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
}

.stat-number {
    font-size: clamp(22px, 2.4vw, 30px);
    font-weight: 800;
    color: #fff;
    line-height: 1;
    margin-right: 4px;
}

.stat-label {
    font-size: 13px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.6);
    line-height: 1.4;
}

/* spacer so content below the stats bar isn't overlapped by its negative translate */
.hero-section::after {
    content: '';
    display: block;
    height: 40px;
}

/* ======================================================================
   Responsive
   ====================================================================== */
@media (max-width: 1080px) {
    .hero-content { grid-template-columns: 1fr; }
    .hero-visual { order: -1; max-width: 460px; margin: 0 auto 30px; }
    .hero-text { text-align: center; }
    .hero-eyebrow { justify-content: center; }
    .hero-description { margin-left: auto; margin-right: auto; }
    .hero-actions { justify-content: center; }
}

@media (max-width: 900px) {
    .site-menu {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
        background: rgba(5, 3, 8, 0.97);
        border-bottom: 1px solid transparent;
        padding: 0 5%;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s ease, padding 0.3s ease;
    }
    .site-menu.is-open { max-height: 400px; padding: 16px 5% 24px; border-bottom-color: var(--ztg-border); }
    .site-menu li { width: 100%; }
    .site-menu a { display: block; padding: 12px 0; width: 100%; }
    .menu-toggle { display: flex; }
    .hero-stats,
    .hero-stats:has(.stat-item:nth-child(4):last-child) { grid-template-columns: repeat(2, 1fr); border-radius: 24px; }
}

@media (max-width: 560px) {
    .hero-float-icon { width: 30px !important; height: 30px !important; min-width: 30px !important; min-height: 30px !important; max-width: 30px !important; max-height: 30px !important; }
    .icon-top { top: -6px; left: 4px; }
    .icon-bottom { bottom: -6px; right: 4px; }
    .hero-stats,
    .hero-stats:has(.stat-item:nth-child(4):last-child) { grid-template-columns: repeat(2, 1fr); gap: 20px 10px; padding: 24px 20px; }
}
