/* ===== MODAL OVERLAY ===== */
.greeting-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(8px);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    opacity: 0;
    transition: opacity 0.3s ease;
    padding: 1rem;
}

.greeting-overlay.is-open {
    display: flex;
    opacity: 1;
}

/* ===== MODAL CARD ===== */
.greeting-modal {
    background: #1a1b23;
    border: 1px solid #2a2b36;
    border-radius: 16px;
    width: 600px;
    max-width: calc(100% - 2rem);
    box-shadow: 
        0 20px 40px rgba(0, 0, 0, 0.4),
        0 0 0 1px rgba(255, 255, 255, 0.05);
    position: relative;
    padding: calc(12px + 1vw);
    color: #fff;
    transform: translateY(20px) scale(0.95);
    opacity: 0;
    transition: 
        transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275),
        opacity 0.4s ease;
}

.greeting-overlay.is-open .greeting-modal {
    transform: translateY(0) scale(1);
    opacity: 1;
}

/* ===== CLOSE BUTTON ===== */
.greeting-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 36px;
    height: 36px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.05);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #8f8f9c;
    font-size: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    cursor: pointer;
    transition: all 0.2s ease;
}

.greeting-close:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    transform: translateY(-1px);
}

.greeting-close:active {
    transform: translateY(0);
}

/* ===== CONTENT LAYOUT ===== */
.greeting-content {
    display: flex;
    gap: clamp(1rem, 3vw, 1.5rem);
    align-items: flex-start;
}

.greeting-icon {
    flex-shrink: 0;
}

.greeting-icon img {
    width: clamp(72px, 8vw, 96px);
    height: clamp(72px, 8vw, 96px);
    border-radius: 12px;
    object-fit: cover;
}

.greeting-text {
    flex: 1;
    min-width: 0;
}

/* ===== TYPOGRAPHY ===== */
.greeting-title {
    font-size: clamp(1.25rem, 3vw, 1.5rem);
    font-weight: 700;
    margin-bottom: 0.5rem;
    background: linear-gradient(135deg, #fff 0%, #a6d8ff 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    line-height: 1.3;
    letter-spacing: -0.01em;
}

.greeting-subtitle {
    font-size: clamp(0.875rem, 2vw, 1rem);
    line-height: 1.5;
    color: #b4b4c0;
    margin-bottom: 1.25rem;
}

/* ===== BUTTONS CONTAINER ===== */
.greeting-actions {
  display: flex;
  flex-wrap: wrap; /* Позволяет кнопкам переноситься на новую строку при нехватке места */
  gap: 0.75rem; /* Отступ между кнопками */
  justify-content: center; /* Выравнивание по центру */
  margin-top: 1rem;
}

/* ===== BUTTON BASE STYLES ===== */
.btn-skins,
.btn-cases,
.btn-tg,
.btn-ds {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.25rem;
    border-radius: 10px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.875rem;
    border: none;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    min-width: 140px;
    flex: 1 0 calc(50% - 0.375rem);
}
.btn-cases::before,
.btn-skins::before,
.btn-tg::before,
.btn-ds::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}
.btn-cases:hover::before,
.btn-skins:hover::before,
.btn-tg:hover::before,
.btn-ds:hover::before {
    left: 100%;
}

/* ===== TELEGRAM BUTTON ===== */
.btn-tg {
    background: linear-gradient(135deg, #0088cc 0%, #24a1de 100%);
    color: #fff;
    box-shadow: 
        0 4px 12px rgba(34, 158, 217, 0.3),
        0 2px 4px rgba(34, 158, 217, 0.2);
}

.btn-tg:hover {
    transform: translateY(-2px);
    box-shadow: 
        0 8px 20px rgba(34, 158, 217, 0.4),
        0 4px 8px rgba(34, 158, 217, 0.3);
    filter: brightness(1.1);
}

.btn-tg:active {
    transform: translateY(0);
}

.btn-skins {
    background: linear-gradient(135deg, #f97bfd 0%, #ba4dfa 100%);
    color: #fff;
    box-shadow: 
        0 4px 12px rgba(104, 34, 217, 0.3),
        0 2px 4px rgba(187, 34, 217, 0.2);
}
.btn-skins:hover{
    transform: translateY(-2px);
    box-shadow: 
        0 8px 20px rgba(216, 88, 242, 0.4),
        0 4px 8px rgba(88, 101, 242, 0.3);
    filter: brightness(1.1);
}
.btn-cases{
    background: linear-gradient(135deg, #38d145 0%, #34a777 100%);
    color: #fff;
    box-shadow: 
        0 4px 12px rgba(49, 217, 34, 0.3),
        0 2px 4px rgba(34, 217, 126, 0.2);
}
.btn-cases:hover{
    transform: translateY(-2px);
    box-shadow: 
        0 8px 20px rgba(88, 242, 157, 0.4),
        0 4px 8px rgba(86, 241, 169, 0.3);
    filter: brightness(1.1);
}
.btn-ds {
    background: linear-gradient(135deg, #5865f2 0%, #454fbf 100%);
    color: #fff;
    box-shadow: 
        0 4px 12px rgba(88, 101, 242, 0.3),
        0 2px 4px rgba(88, 101, 242, 0.2);
}

.btn-ds:hover {
    transform: translateY(-2px);
    box-shadow: 
        0 8px 20px rgba(88, 101, 242, 0.4),
        0 4px 8px rgba(88, 101, 242, 0.3);
    filter: brightness(1.1);
}

.btn-ds:active {
    transform: translateY(0);
}

/* ===== BUTTON ICONS ===== */
.btn-icon {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
}

/* ===== RESPONSIVE DESIGN ===== */
@media (max-width: 640px) {
    .greeting-overlay {
        padding: 0.5rem;
    }
    
    .greeting-modal {
        padding: 1.25rem;
        border-radius: 12px;
    }
    
    .greeting-content {
        flex-direction: column;
        text-align: center;
        align-items: center;
        gap: 1rem;
    }
    
    .greeting-actions {
        justify-content: center;
    }
    
    .btn-tg,
    .btn-ds {
        min-width: 140px;
        padding: 0.875rem 1.5rem;
        flex: 1;
    }
    
    .greeting-close {
        top: 8px;
        right: 8px;
        width: 32px;
        height: 32px;
        font-size: 18px;
    }
}

@media (max-width: 480px) {
    .greeting-modal {
        padding: 1rem;
    }
    
    .greeting-actions {
        flex-direction: column;
        width: 100%;
    }
    
    .btn-tg,
    .btn-ds {
        width: 100%;
        min-width: auto;
    }
    
    .greeting-icon img {
        width: 64px;
        height: 64px;
    }
}

/* ===== ACCESSIBILITY ===== */
@media (prefers-reduced-motion: reduce) {
    .greeting-overlay,
    .greeting-modal,
    .btn-tg,
    .btn-ds,
    .greeting-close {
        transition: none;
    }
}

/* ===== FOCUS STATES ===== */
.greeting-close:focus-visible,
.btn-tg:focus-visible,
.btn-ds:focus-visible {
    outline: 2px solid #a6d8ff;
    outline-offset: 2px;
}