:root {
    --bg-primary: #06060A;
    --bg-secondary: #0C0C14;
    --bg-card: #12121C;
    --bg-card-hover: #1A1A28;
    --accent: #C9A84C;
    --accent-light: #E8C95A;
    --accent-dark: #9A7B2E;
    --accent-glow: rgba(201, 168, 76, 0.15);
    --text-primary: #F0ECE2;
    --text-secondary: #8A877E;
    --text-muted: #504D45;
    --border: #1E1E2E;
    --border-hover: #2E2E44;
    --cat-3char: #E8913A;
    --cat-4char: #3AAFB9;
    --cat-brand: #5CB85C;
    --cat-twoword: #D4726A;
    --radius: 16px;
    --radius-sm: 10px;
    --font-fa: 'Vazirmatn', sans-serif;
    --font-en: 'Space Grotesk', sans-serif;
    --transition: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    font-family: var(--font-fa);
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.7;
    overflow-x: hidden;
    min-height: 100vh;
}
a { text-decoration: none; color: inherit; }
button { cursor: pointer; border: none; font-family: inherit; background: none; }
input, textarea { font-family: inherit; }
::selection { background: var(--accent); color: var(--bg-primary); }

/* === استایل اسکرول‌بار === */
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: var(--bg-primary); }
::-webkit-scrollbar-thumb { background: var(--border-hover); border-radius: 10px; }
::-webkit-scrollbar-thumb:hover { background: var(--accent-dark); }

/* === دسترسی‌پذیری (Focus) === */
a:focus-visible, button:focus-visible, .form-input:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

/* === انیمیشن گرادینت متحرک پس‌زمینه === */
.animated-bg {
    position: fixed; inset: 0; z-index: 0; pointer-events: none;
    background: linear-gradient(125deg, #0a0a12, #0d0b18, #0f0e12, #080a14, #0e0c10);
    background-size: 400% 400%;
    animation: gradientShift 15s ease infinite;
}
@keyframes gradientShift { 
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.bg-grid {
    position: fixed; inset: 0; z-index: 0; pointer-events: none;
    background-image: radial-gradient(circle, rgba(201,168,76,0.03) 1px, transparent 1px);
    background-size: 48px 48px;
}

/* === لودینگ === */
.loader-screen {
    position: fixed; inset: 0; z-index: 9999;
    background: var(--bg-primary);
    display: flex; align-items: center; justify-content: center; flex-direction: column; gap: 24px;
    transition: opacity 0.8s ease, visibility 0.8s ease;
}
.loader-screen.hidden { opacity: 0; visibility: hidden; pointer-events: none; }
.loader-logo {
    font-family: var(--font-en); font-weight: 700; font-size: 32px;
    background: linear-gradient(90deg, var(--accent-dark), var(--accent-light), var(--accent));
    background-size: 200% auto;
    -webkit-background-clip: text; background-clip: text; color: transparent;
    animation: textShine 2s linear infinite;
}
@keyframes textShine { to { background-position: 200% center; } }
.loader-bar { width: 120px; height: 3px; background: var(--border); border-radius: 10px; overflow: hidden; }
.loader-bar::after { content: ''; display: block; width: 40%; height: 100%; background: var(--accent); border-radius: 10px; animation: loading 1s ease-in-out infinite; }
@keyframes loading { 0% { transform: translateX(-100%); } 100% { transform: translateX(350%); } }

/* === هدر === */
.site-header {
    position: fixed; top: 0; right: 0; left: 0; z-index: 100;
    background: rgba(6,6,10,0.85); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border); padding: 0 32px; height: 72px;
    display: flex; align-items: center; justify-content: space-between;
    transform: translateY(-100%); animation: headerSlide 0.6s ease 1s forwards;
}
@keyframes headerSlide { to { transform: translateY(0); } }
.header-brand { display: flex; align-items: center; gap: 14px; }
.header-logo {
    width: 42px; height: 42px; border-radius: 12px; position: relative; display: flex; align-items: center; justify-content: center;
    background: linear-gradient(135deg, var(--accent), var(--accent-dark));
    box-shadow: 0 0 15px rgba(201, 168, 76, 0.2);
    animation: logoPulse 3s ease-in-out infinite;
}
@keyframes logoPulse { 0%, 100% { box-shadow: 0 0 15px rgba(201, 168, 76, 0.2); } 50% { box-shadow: 0 0 25px rgba(201, 168, 76, 0.5); } }
.header-logo span { font-family: var(--font-en); font-weight: 800; font-size: 20px; color: var(--bg-primary); }
.header-info { display: flex; flex-direction: column; }
.header-title { font-weight: 700; font-size: 16px; color: var(--text-primary); line-height: 1.2; }
.header-reg { font-size: 11px; color: var(--text-muted); }
.btn-contact-header {
    border: 1px solid var(--border-hover); color: var(--text-primary);
    padding: 10px 22px; border-radius: var(--radius-sm); font-size: 14px; font-weight: 500;
    transition: var(--transition); display: flex; align-items: center; gap: 8px;
    position: relative; overflow: hidden;
}
.btn-contact-header::before {
    content: ''; position: absolute; top: 0; left: -100%; width: 100%; height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.1), transparent);
    transition: 0.5s;
}
.btn-contact-header:hover::before { left: 100%; }
.btn-contact-header:hover { border-color: var(--accent); color: var(--accent); }

/* === هیرو === */
.hero { position: relative; z-index: 1; min-height: 85vh; display: flex; align-items: center; justify-content: center; padding: 120px 32px 60px; text-align: center; }
.hero-content { max-width: 850px; }
.hero-badge { display: inline-flex; align-items: center; gap: 8px; background: rgba(201,168,76,0.08); border: 1px solid rgba(201,168,76,0.2); padding: 8px 24px; border-radius: 100px; font-size: 13px; font-weight: 500; color: var(--accent); margin-bottom: 32px; opacity: 0; animation: fadeUp 0.8s ease 1.2s forwards; }
.pulse-dot { width: 8px; height: 8px; background: #5CB85C; border-radius: 50%; animation: pulse 2s ease-in-out infinite; }
@keyframes pulse { 0%,100%{opacity:1;transform:scale(1)} 50%{opacity:0.5;transform:scale(1.6)} }

.hero-title { font-size: clamp(30px, 5.5vw, 52px); font-weight: 900; line-height: 1.3; margin-bottom: 24px; opacity: 0; animation: fadeUp 0.8s ease 1.4s forwards; }
.text-gradient {
    background: linear-gradient(90deg, var(--accent), var(--accent-light), #fff, var(--accent));
    background-size: 300% auto;
    -webkit-background-clip: text; background-clip: text; color: transparent;
    animation: textShine 4s linear infinite;
}

.parked-domain-display {
    font-family: var(--font-en); font-size: clamp(44px, 9vw, 90px); font-weight: 700; letter-spacing: -3px;
    margin-bottom: 16px; opacity: 0; animation: fadeUp 0.8s ease 1.4s forwards;
    background: linear-gradient(90deg, var(--accent-light), #fff, var(--accent-light), var(--accent));
    background-size: 300% auto;
    -webkit-background-clip: text; background-clip: text; color: transparent;
    animation: fadeUp 0.8s ease 1.4s forwards, textShine 3s linear infinite 2.2s;
    filter: drop-shadow(0 0 30px rgba(201,168,76,0.3));
}
.parked-domain-price { font-size: clamp(22px, 4vw, 38px); font-weight: 800; color: var(--text-primary); margin-bottom: 12px; opacity: 0; animation: fadeUp 0.8s ease 1.6s forwards; }
.parked-domain-price .unit { font-size: 0.6em; color: var(--text-secondary); font-weight: 400; }
.hero-desc { font-size: 17px; color: var(--text-secondary); max-width: 600px; margin: 0 auto 40px; opacity: 0; animation: fadeUp 0.8s ease 1.6s forwards; }
.hero-buttons { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; opacity: 0; animation: fadeUp 0.8s ease 1.8s forwards; }
.scroll-indicator { position: absolute; bottom: 30px; left: 50%; transform: translateX(-50%); opacity: 0; animation: fadeUp 0.8s ease 2.2s forwards; }
.scroll-indicator i { font-size: 20px; color: var(--text-muted); animation: scrollBounce 2s ease-in-out infinite; }
@keyframes scrollBounce { 0%,100%{transform:translateY(0)} 50%{transform:translateY(10px)} }
@keyframes fadeUp { from{opacity:0;transform:translateY(30px)} to{opacity:1;transform:translateY(0)} }

/* === دکمه‌های متحرک === */
.btn-primary {
    background: linear-gradient(135deg, var(--accent), var(--accent-dark));
    color: var(--bg-primary); font-weight: 700; padding: 15px 36px; border-radius: var(--radius-sm);
    font-size: 15px; transition: var(--transition); display: inline-flex; align-items: center; gap: 10px;
    position: relative; overflow: hidden;
}
.btn-primary::after {
    content: ''; position: absolute; top: -50%; left: -60%; width: 40%; height: 200%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.4), transparent);
    transform: skewX(-20deg); animation: shimmer 3s ease-in-out infinite;
}
@keyframes shimmer { 0% { left: -60%; } 100% { left: 140%; } }
.btn-primary:hover { transform: translateY(-3px); box-shadow: 0 10px 40px rgba(201,168,76,0.4); }
.btn-secondary {
    border: 1px solid var(--border-hover); color: var(--text-primary); font-weight: 500;
    padding: 15px 32px; border-radius: var(--radius-sm); font-size: 15px; transition: var(--transition);
    display: inline-flex; align-items: center; gap: 10px;
}
.btn-secondary:hover { border-color: var(--accent); color: var(--accent); background: var(--accent-glow); transform: translateY(-2px); }

/* === نوار آمار === */
.stats-bar { position: relative; z-index: 1; display: flex; justify-content: center; gap: 48px; flex-wrap: wrap; padding: 40px 32px; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); background: rgba(12,12,20,0.6); backdrop-filter: blur(10px); }
.stat-item { text-align: center; }
.stat-value {
    font-family: var(--font-en); font-size: 34px; font-weight: 700; line-height: 1.2;
    background: linear-gradient(180deg, var(--accent-light), var(--accent-dark));
    -webkit-background-clip: text; background-clip: text; color: transparent;
    animation: statGlow 3s ease-in-out infinite alternate;
}
@keyframes statGlow { from { filter: drop-shadow(0 0 2px rgba(201,168,76,0.2)); } to { filter: drop-shadow(0 0 8px rgba(201,168,76,0.6)); } }
.stat-label { font-size: 13px; color: var(--text-secondary); margin-top: 4px; }

/* === بخش اصلی === */
.domains-section { position: relative; z-index: 1; max-width: 1200px; margin: 0 auto; padding: 70px 32px 80px; }
.section-header { text-align: center; margin-bottom: 45px; }
.section-title { font-size: 28px; font-weight: 800; margin-bottom: 8px; }
.section-subtitle { font-size: 15px; color: var(--text-secondary); }

/* === فیلترها === */
.filters { display: flex; justify-content: center; gap: 10px; flex-wrap: wrap; margin-bottom: 45px; }
.filter-btn { background: var(--bg-card); border: 1px solid var(--border); color: var(--text-secondary); padding: 10px 24px; border-radius: 100px; font-size: 14px; font-weight: 500; transition: var(--transition); }
.filter-btn:hover { border-color: var(--border-hover); color: var(--text-primary); transform: translateY(-2px); }
.filter-btn.active { background: var(--accent-glow); border-color: var(--accent); color: var(--accent); box-shadow: 0 0 20px rgba(201,168,76,0.15); }

/* === کارت دامنه === */
.domains-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); gap: 24px; }
.domain-card {
    position: relative; overflow: hidden; background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius); padding: 28px;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    opacity: 0; transform: translateY(40px) scale(0.97);
}
.domain-card.visible { opacity: 1; transform: translateY(0) scale(1); transition-delay: var(--delay, 0s); }
.domain-card::before {
    content: ''; position: absolute; top: 0; left: 0; right: 0; height: 2px;
    background: linear-gradient(90deg, transparent, var(--accent), transparent);
    opacity: 0; transition: opacity 0.4s ease;
}
.domain-card::after {
    content: ''; position: absolute; inset: 0; border-radius: var(--radius);
    background: radial-gradient(circle at 50% 0%, rgba(201,168,76,0.08), transparent 70%);
    opacity: 0; transition: opacity 0.4s ease; pointer-events: none;
}
.domain-card:hover { border-color: var(--border-hover); background: var(--bg-card-hover); transform: translateY(-6px) scale(1.01); box-shadow: 0 20px 50px rgba(0,0,0,0.4); }
.domain-card:hover::before, .domain-card:hover::after { opacity: 1; }

.domain-card.parked-highlight { border-color: var(--accent); animation: parkedPulse 3s ease-in-out infinite; }
@keyframes parkedPulse { 0%, 100% { box-shadow: 0 0 15px rgba(201,168,76,0.2); } 50% { box-shadow: 0 0 35px rgba(201,168,76,0.4), inset 0 0 20px rgba(201,168,76,0.03); } }
.domain-card.parked-highlight .parked-tag { position: absolute; top: 14px; left: 14px; background: var(--accent); color: var(--bg-primary); font-size: 11px; font-weight: 700; padding: 5px 14px; border-radius: 100px; }

.card-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.cat-badge { font-size: 12px; font-weight: 600; padding: 5px 14px; border-radius: 100px; }
.cat-3char { background: rgba(232,145,58,0.12); color: var(--cat-3char); }
.cat-4char { background: rgba(58,175,185,0.12); color: var(--cat-4char); }
.cat-brand { background: rgba(92,184,92,0.12); color: var(--cat-brand); }
.cat-twoword { background: rgba(212,114,106,0.12); color: var(--cat-twoword); }
.card-status { width: 8px; height: 8px; background: #5CB85C; border-radius: 50%; animation: pulse 2s ease-in-out infinite; }
.domain-name { font-family: var(--font-en); font-size: 26px; font-weight: 700; letter-spacing: -0.5px; color: var(--text-primary); margin-bottom: 8px; direction: ltr; text-align: right; transition: color 0.3s; }
.domain-card:hover .domain-name { color: #fff; }
.domain-tld { color: var(--accent); }
.domain-desc { font-size: 13px; color: var(--text-muted); margin-bottom: 18px; line-height: 1.6; min-height: 42px; }
.card-price { font-family: var(--font-en); font-size: 20px; font-weight: 600; color: var(--text-secondary); margin-bottom: 22px; }
.card-price .unit { font-size: 13px; color: var(--text-muted); font-weight: 400; margin-right: 4px; }
.card-actions { display: flex; gap: 10px; }
.btn-offer { flex: 1; background: rgba(201,168,76,0.08); border: 1px solid rgba(201,168,76,0.15); color: var(--accent); font-weight: 600; padding: 12px 16px; border-radius: var(--radius-sm); font-size: 13px; transition: var(--transition); display: flex; align-items: center; justify-content: center; gap: 6px; }
.btn-offer:hover { background: rgba(201,168,76,0.15); border-color: var(--accent); transform: translateY(-2px); }
.btn-buy { flex: 1; background: linear-gradient(135deg, var(--accent), var(--accent-dark)); color: var(--bg-primary); font-weight: 700; padding: 12px 16px; border-radius: var(--radius-sm); font-size: 13px; transition: var(--transition); display: flex; align-items: center; justify-content: center; gap: 6px; position: relative; overflow: hidden; }
.btn-buy::after { content: ''; position: absolute; top: -50%; left: -60%; width: 40%; height: 200%; background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent); transform: skewX(-20deg); animation: shimmer 3s ease-in-out infinite; }
.btn-buy:hover { box-shadow: 0 6px 25px rgba(201,168,76,0.35); transform: translateY(-2px); }
.empty-state { grid-column: 1 / -1; text-align: center; padding: 60px 20px; color: var(--text-muted); }
.empty-state i { font-size: 48px; margin-bottom: 16px; display: block; }

/* === فوتر === */
.site-footer { position: relative; z-index: 1; border-top: 1px solid var(--border); padding: 40px 32px; text-align: center; background: rgba(6,6,10,0.8); }
.footer-brand { font-weight: 800; font-size: 18px; color: var(--accent); margin-bottom: 4px; }
.footer-reg { font-size: 12px; color: var(--text-muted); margin-bottom: 12px; }
.footer-text { font-size: 13px; color: var(--text-muted); }

/* === مودال === */
.modal-overlay { position: fixed; inset: 0; z-index: 200; background: rgba(0,0,0,0.75); backdrop-filter: blur(10px); display: flex; align-items: center; justify-content: center; padding: 20px; opacity: 0; visibility: hidden; transition: all 0.4s ease; }
.modal-overlay.active { opacity: 1; visibility: visible; }
.modal-card { background: var(--bg-secondary); border: 1px solid var(--border); border-radius: var(--radius); width: 100%; max-width: 480px; padding: 36px; transform: translateY(40px) scale(0.95); transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1); max-height: 90vh; overflow-y: auto; }
.modal-overlay.active .modal-card { transform: translateY(0) scale(1); }
.modal-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 28px; }
.modal-title { font-size: 20px; font-weight: 800; }
.modal-close { width: 36px; height: 36px; background: var(--bg-card); border: 1px solid var(--border); border-radius: 50%; color: var(--text-secondary); display: flex; align-items: center; justify-content: center; font-size: 14px; transition: var(--transition); }
.modal-close:hover { border-color: var(--accent); color: var(--accent); transform: rotate(90deg); }
.modal-domain-tag { font-family: var(--font-en); background: var(--accent-glow); border: 1px solid rgba(201,168,76,0.2); color: var(--accent); font-weight: 600; padding: 12px 20px; border-radius: var(--radius-sm); text-align: center; margin-bottom: 8px; font-size: 20px; letter-spacing: -0.3px; direction: ltr; }
.modal-domain-price-tag { text-align: center; margin-bottom: 24px; font-size: 14px; color: var(--text-secondary); }
.modal-domain-price-tag strong { font-family: var(--font-en); color: var(--accent); font-size: 18px; }

/* === فرم‌ها === */
.form-group { margin-bottom: 18px; }
.form-label { display: block; font-size: 13px; font-weight: 600; color: var(--text-secondary); margin-bottom: 8px; }
.form-label .required { color: var(--cat-twoword); margin-right: 2px; }
.form-input { width: 100%; background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 14px 16px; color: var(--text-primary); font-size: 14px; transition: var(--transition); outline: none; }
.form-input::placeholder { color: var(--text-muted); }
.form-input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-glow); }
textarea.form-input { resize: vertical; min-height: 100px; }
.form-submit { width: 100%; margin-top: 8px; background: linear-gradient(135deg, var(--accent), var(--accent-dark)); color: var(--bg-primary); font-weight: 700; padding: 15px; border-radius: var(--radius-sm); font-size: 15px; transition: var(--transition); display: flex; align-items: center; justify-content: center; gap: 8px; position: relative; overflow: hidden; }
.form-submit::after { content: ''; position: absolute; top: -50%; left: -60%; width: 40%; height: 200%; background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent); transform: skewX(-20deg); animation: shimmer 2.5s ease-in-out infinite; }
.form-submit:hover { box-shadow: 0 8px 30px rgba(201,168,76,0.3); transform: translateY(-2px); }
.form-submit:disabled { opacity: 0.7; cursor: not-allowed; transform: none !important; box-shadow: none !important; }
.form-submit .spinner { width: 18px; height: 18px; border: 2px solid rgba(6,6,10,0.3); border-top-color: var(--bg-primary); border-radius: 50%; animation: spin 0.6s linear infinite; display: none; }
.form-submit.loading .spinner { display: block; }
.form-submit.loading .btn-text { display: none; }
@keyframes spin { to { transform: rotate(360deg); } }

/* === توست === */
.toast-container { position: fixed; top: 88px; left: 24px; z-index: 300; display: flex; flex-direction: column; gap: 10px; }
.toast { background: var(--bg-secondary); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 16px 22px; display: flex; align-items: center; gap: 12px; font-size: 14px; min-width: 300px; box-shadow: 0 12px 40px rgba(0,0,0,0.5); transform: translateX(-120%); animation: toastIn 0.5s cubic-bezier(0.4, 0, 0.2, 1) forwards; }
.toast.removing { animation: toastOut 0.4s ease forwards; }
.toast.success { border-color: rgba(92,184,92,0.4); background: linear-gradient(135deg, var(--bg-secondary), rgba(92,184,92,0.05)); }
.toast.success i { color: #5CB85C; font-size: 18px; }
.toast.error { border-color: rgba(212,114,106,0.4); background: linear-gradient(135deg, var(--bg-secondary), rgba(212,114,106,0.05)); }
.toast.error i { color: var(--cat-twoword); font-size: 18px; }
@keyframes toastIn { to { transform: translateX(0); } }
@keyframes toastOut { to { transform: translateX(-120%); opacity: 0; } }

/* === ریسپانسیو === */
@media (max-width: 768px) {
    .site-header { padding: 0 16px; height: 64px; }
    .header-info { display: none; }
    .hero { padding: 100px 20px 50px; min-height: 75vh; }
    .stats-bar { gap: 24px; padding: 28px 20px; }
    .stat-value { font-size: 26px; }
    .domains-section { padding: 40px 16px 60px; }
    .domains-grid { grid-template-columns: 1fr; gap: 16px; }
    .domain-card { padding: 22px; }
    .domain-name { font-size: 22px; }
    .modal-card { padding: 24px; }
    .hero-buttons { flex-direction: column; align-items: stretch; }
    .btn-primary, .btn-secondary { width: 100%; justify-content: center; }
    
    /* اصلاحات توست در موبایل */
    .toast-container { left: 16px; right: 16px; top: 80px; }
    .toast { min-width: auto; width: 100%; margin: 0; }

    /* بهینه‌سازی انیمیشن‌ها در موبایل */
    .animated-bg { animation: none; background: var(--bg-primary); }
    .bg-grid { display: none; }
    .btn-primary::after, .btn-buy::after, .form-submit::after { animation: none; }
}
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
    .domain-card { opacity: 1; transform: none; }
    .site-header { transform: none; }
    .hero-badge, .hero-title, .hero-desc, .hero-buttons, .parked-domain-display, .parked-domain-price { opacity: 1; }
}