* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Vazirmatn', 'Segoe UI', sans-serif;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    position: relative;
    transition: background 0.3s ease;
}

/* ========== تم دارک ========== */
body.dark {
    background: radial-gradient(circle at 25% 20%, #0a0f1c, #03050b);
}
body.dark .welcome-card {
    background: rgba(10, 15, 30, 0.7);
    backdrop-filter: blur(18px);
    border: 1px solid rgba(255, 180, 80, 0.4);
    box-shadow: 0 30px 50px -20px rgba(0, 0, 0, 0.6);
}
body.dark .logo {
    background: linear-gradient(135deg, #FFE6B3, #F0B85B, #FFD966);
    -webkit-background-clip: text;
    background-clip: text;
}
body.dark .subtitle {
    color: #eedbac;
    background: rgba(0, 0, 0, 0.45);
    border-color: rgba(255, 200, 100, 0.5);
}
body.dark .coffee-icon i {
    color: #ffdd99;
    text-shadow: 0 0 8px rgba(255, 200, 100, 0.6);
}
body.dark .enter-btn {
    background: linear-gradient(105deg, #e6a13a, #b96f20);
    color: #1f1a0c;
}
body.dark .enter-btn:hover {
    background: linear-gradient(105deg, #ffb851, #d4882c);
}
body.dark .floating-icon {
    color: rgba(245, 210, 130, 0.35);
}
body.dark .footer-note {
    color: #b88f54;
}

/* ========== تم لایت ========== */
body.light {
    background: linear-gradient(145deg, #fff9ef, #fce5cf);
}
body.light .welcome-card {
    background: rgba(255, 248, 235, 0.8);
    backdrop-filter: blur(18px);
    border: 1px solid rgba(200, 140, 80, 0.3);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.05);
}
body.light .logo {
    background: linear-gradient(135deg, #C47A44, #A55D2E, #E2A16F);
    -webkit-background-clip: text;
    background-clip: text;
}
body.light .subtitle {
    color: #8B5A2B;
    background: rgba(250, 240, 225, 0.8);
    border-color: #D9B48B;
}
body.light .coffee-icon i {
    color: #D98C2B;
    text-shadow: 0 0 6px rgba(210, 120, 30, 0.4);
}
body.light .enter-btn {
    background: linear-gradient(105deg, #E8B56B, #C88A3A);
    color: #3A2A1F;
}
body.light .enter-btn:hover {
    background: linear-gradient(105deg, #F7CD8C, #E0A152);
}
body.light .floating-icon {
    color: rgba(180, 110, 50, 0.3);
}
body.light .footer-note {
    color: #B48C5C;
}
body.light .orb1 { background: #FFE0B5; }
body.light .orb2 { background: #FFC4A2; }
body.light .orb3 { background: #C8E6C9; }

/* ========== عناصر مشترک ========== */
.welcome-card {
    text-align: center;
    z-index: 20;
    position: relative;
    width: 90%;
    max-width: 560px;
    border-radius: 56px;
    transition: all 0.3s;
    animation: fadeScale 0.6s cubic-bezier(0.2, 0.9, 0.4, 1.1);
}
@keyframes fadeScale {
    0% { opacity: 0; transform: scale(0.95) translateY(20px); }
    100% { opacity: 1; transform: scale(1) translateY(0); }
}

.logo-img {
    width: auto;
    filter: drop-shadow(0 6px 12px rgba(0, 0, 0, 0.15));
    transition: transform 0.2s;
}
.logo-img:hover { transform: scale(1.02); }

.logo {
    font-weight: 900;
    margin-bottom: 0.3rem;
    letter-spacing: -0.5px;
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    line-height: 1.3;
}
.logo-break {
    display: inline;
}
.subtitle {
    font-weight: 500;
    display: inline-block;
    border-radius: 40px;
    backdrop-filter: blur(4px);
    border: 0.5px solid;
    white-space: nowrap;
}
.coffee-icon {
    position: relative;
    display: inline-block;
}
.coffee-icon i {
    transition: all 0.2s;
    animation: softGlow 2.5s infinite alternate;
}
@keyframes softGlow {
    0% { filter: drop-shadow(0 0 2px currentColor); transform: scale(1); }
    100% { filter: drop-shadow(0 0 12px currentColor); transform: scale(1.02); }
}
.rotating-ring {
    position: absolute;
    border-radius: 50%;
    border: 1px solid rgba(255, 200, 100, 0.5);
    border-top: 2px solid #f5b042;
    animation: spin 5s linear infinite;
    pointer-events: none;
}
@keyframes spin { 100% { transform: rotate(360deg); } }

.enter-btn {
    display: inline-flex;
    flex-direction: row-reverse;
    align-items: center;
    justify-content: center;
    gap: clamp(8px, 3vw, 16px);
    border: none;
    font-family: inherit;
    font-weight: 700;
    border-radius: 60px;
    cursor: pointer;
    transition: all 0.25s;
    position: relative;
    overflow: hidden;
}
.enter-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 210, 0.3), transparent);
    transition: left 0.4s;
}
.enter-btn:hover::before { left: 100%; }
.enter-btn:active { transform: scale(0.98); }

.loading-dots {
    display: flex;
    justify-content: center;
    gap: 6px;
    visibility: hidden;
    opacity: 0;
    transition: 0.2s;
}
.loading-dots span {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    animation: pulse 1.2s infinite ease-in-out both;
}
body.dark .loading-dots span { background: #f5cf8b; }
body.light .loading-dots span { background: #b87c4f; }
@keyframes pulse {
    0%,80%,100% { transform: scale(0.4); opacity: 0.4; }
    40% { transform: scale(1); opacity: 1; }
}

.floating-icon {
    position: absolute;
    transition: transform 0.1s linear;
    pointer-events: none;
    z-index: 12;
    will-change: transform;
}
.footer-note {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}
.glow-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    transition: background 0.5s;
    animation: orbMove 20s infinite alternate;
    z-index: 0;
}
.orb1 { top: -150px; left: -200px; animation-duration: 25s; }
.orb2 { bottom: -250px; right: -200px; animation-duration: 30s; }
.orb3 { top: 40%; right: 10%; animation-duration: 18s; }
@keyframes orbMove {
    0% { transform: translate(0,0) scale(1); }
    100% { transform: translate(5%,8%) scale(1.2); }
}

.theme-switch {
    position: fixed;
    z-index: 100;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(10px);
    border-radius: 60px;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    border: 1px solid rgba(255, 200, 120, 0.5);
    transition: 0.2s;
    font-weight: 500;
    color: #ffefcf;
}
body.light .theme-switch {
    background: rgba(255, 245, 230, 0.8);
    color: #5a3a28;
    border-color: #d9b48b;
}

/* ========== مدیریت سایز با clamp و breakpoints ========== */
/* مقادیر پایه (موبایل خیلی کوچک) */
.welcome-card {
    padding: 1rem 0.8rem 1.2rem;
    border-radius: 32px;
}
.logo-img {
    max-width: 70px;
}
.logo {
    font-size: 1.2rem;
    margin-bottom: 0.1rem;
}
.logo-break {
    display: block;
}
.subtitle {
    font-size: 0.6rem;
    padding: 0.2rem 0.6rem;
    margin-bottom: 0.6rem;
    white-space: normal;
}
.coffee-icon {
    margin-bottom: 0.8rem;
}
.coffee-icon i {
    font-size: 1.8rem;
}
.rotating-ring {
    top: -5px; left: -5px; right: -5px; bottom: -5px;
}
.enter-btn {
    padding: 5px 12px;
    font-size: 0.7rem;
    min-width: 110px;
}
.footer-note {
    margin-top: 0.5rem;
    font-size: 0.5rem;
}
.floating-icon {
    font-size: 0.9rem;
}
.theme-switch {
    top: 10px;
    left: 10px;
    padding: 4px 10px;
    font-size: 0.6rem;
}
.orb1, .orb2, .orb3 {
    transform: scale(0.5);
}

/* موبایل متوسط (400px تا 550px) */
@media (min-width: 400px) {
    .welcome-card {
        padding: 1.2rem 1rem 1.5rem;
        border-radius: 40px;
    }
    .logo-img {
        max-width: 85px;
    }
    .logo {
        font-size: 1.5rem;
        margin-bottom: 0.2rem;
    }
    .logo-break {
        display: inline;
    }
    .subtitle {
        font-size: 0.7rem;
        padding: 0.2rem 0.7rem;
        margin-bottom: 0.8rem;
        white-space: nowrap;
    }
    .coffee-icon i {
        font-size: 2.2rem;
    }
    .rotating-ring {
        top: -6px; left: -6px; right: -6px; bottom: -6px;
    }
    .enter-btn {
        padding: 6px 14px;
        font-size: 0.75rem;
        min-width: 120px;
    }
    .footer-note {
        margin-top: 0.6rem;
        font-size: 0.55rem;
    }
    .floating-icon {
        font-size: 1rem;
    }
    .theme-switch {
        top: 12px;
        left: 12px;
        padding: 5px 12px;
        font-size: 0.65rem;
    }
    .orb1, .orb2, .orb3 {
        transform: scale(0.7);
    }
}

/* تبلت‌های کوچک (550px تا 768px) */
@media (min-width: 550px) {
    .welcome-card {
        padding: 1.5rem 1.2rem 1.8rem;
        border-radius: 48px;
    }
    .logo-img {
        max-width: 100px;
    }
    .logo {
        font-size: 1.8rem;
        margin-bottom: 0.2rem;
    }
    .subtitle {
        font-size: 0.8rem;
        padding: 0.25rem 0.8rem;
        margin-bottom: 1rem;
    }
    .coffee-icon i {
        font-size: 2.6rem;
    }
    .enter-btn {
        padding: 7px 18px;
        font-size: 0.85rem;
        min-width: 130px;
    }
    .footer-note {
        margin-top: 0.7rem;
        font-size: 0.6rem;
    }
    .floating-icon {
        font-size: 1.2rem;
    }
    .theme-switch {
        top: 14px;
        left: 14px;
        padding: 6px 14px;
        font-size: 0.7rem;
    }
    .orb1, .orb2, .orb3 {
        transform: scale(0.85);
    }
}

/* تبلت و دسکتاپ کوچک (768px تا 1024px) */
@media (min-width: 768px) {
    .welcome-card {
        padding: 1.8rem 1.5rem 2rem;
        border-radius: 52px;
        max-width: 520px;
    }
    .logo-img {
        max-width: 110px;
    }
    .logo {
        font-size: 2rem;
    }
    .subtitle {
        font-size: 0.85rem;
    }
    .coffee-icon i {
        font-size: 3rem;
    }
    .enter-btn {
        padding: 8px 22px;
        font-size: 0.9rem;
        min-width: 150px;
    }
    .footer-note {
        font-size: 0.65rem;
    }
    .floating-icon {
        font-size: 1.4rem;
    }
    .theme-switch {
        top: 16px;
        left: 16px;
        padding: 6px 14px;
        font-size: 0.75rem;
    }
    .orb1, .orb2, .orb3 {
        transform: scale(1);
    }
}

/* دسکتاپ استاندارد (1024px تا 1200px) */
@media (min-width: 1024px) {
    .welcome-card {
        max-width: 540px;
        padding: 2rem 1.8rem 2.2rem;
        border-radius: 56px;
    }
    .logo-img {
        max-width: 120px;
    }
    .logo {
        font-size: 2.2rem;
    }
    .subtitle {
        font-size: 0.9rem;
    }
    .coffee-icon i {
        font-size: 3.2rem;
    }
    .enter-btn {
        padding: 9px 24px;
        font-size: 0.95rem;
        min-width: 160px;
    }
    .floating-icon {
        font-size: 1.5rem;
    }
}

/* دسکتاپ بزرگ (1200px تا 1600px) */
@media (min-width: 1200px) {
    .welcome-card {
        max-width: 580px;
        padding: 2.2rem 2rem 2.5rem;
    }
    .logo-img {
        max-width: 130px;
    }
    .logo {
        font-size: 2.4rem;
    }
    .subtitle {
        font-size: 0.95rem;
    }
    .coffee-icon i {
        font-size: 3.5rem;
    }
    .enter-btn {
        padding: 10px 28px;
        font-size: 1rem;
        min-width: 170px;
    }
    .floating-icon {
        font-size: 1.6rem;
    }
    .theme-switch {
        top: 18px;
        left: 18px;
        padding: 8px 16px;
        font-size: 0.8rem;
    }
}

/* فوق عریض (1600px به بالا) */
@media (min-width: 1600px) {
    .welcome-card {
        max-width: 650px;
        padding: 2.8rem 2.2rem 3rem;
    }
    .logo-img {
        max-width: 150px;
    }
    .logo {
        font-size: 2.8rem;
    }
    .subtitle {
        font-size: 1rem;
    }
    .coffee-icon i {
        font-size: 4rem;
    }
    .enter-btn {
        padding: 12px 36px;
        font-size: 1.1rem;
        min-width: 200px;
        gap: 16px;
    }
    .footer-note {
        font-size: 0.7rem;
    }
    .floating-icon {
        font-size: 1.8rem;
    }
    .theme-switch {
        top: 20px;
        left: 20px;
        padding: 8px 18px;
        font-size: 0.85rem;
    }
}