.sticker-pack-page {
    min-height: calc(100vh - 72px);
    background: var(--body-bg);
    padding: 2rem 0;
}

.container-small {
    max-width: 900px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* Карточка стикер-пака */
.sticker-pack-card {
    background: var(--post-bg);
    border-radius: 16px;
    padding: 2rem;
    margin-bottom: 2rem;
    border: 1px solid var(--post-border);
    transition: all 0.2s ease;
}

/* Превью */
.sticker-pack-preview {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 2rem;
    min-height: 200px;
    background: var(--sidebar-bg);
    border-radius: 12px;
    padding: 2rem;
}

.pack-preview-image {
    max-width: 100%;
    max-height: 300px;
    border-radius: 12px;
    object-fit: contain;
}

.pack-preview-grid {
    display: grid;
    grid-template-columns: repeat(2, 150px);
    gap: 1rem;
}

.pack-preview-sticker {
    width: 150px;
    height: 150px;
    object-fit: contain;
    transition: transform 0.2s ease;
    background: var(--post-bg);
    border-radius: 12px;
    padding: 0.5rem;
}

.pack-preview-sticker:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* Информация о паке */
.sticker-pack-info {
    text-align: center;
}

.pack-title {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.pack-description {
    font-size: 1rem;
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

/* Мета информация */
.pack-meta {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.pack-meta-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-secondary);
    font-size: 0.9375rem;
}

.pack-meta-item svg {
    color: var(--accent-color);
    flex-shrink: 0;
}

.pack-author {
    color: var(--accent-color);
    text-decoration: none;
    font-weight: 500;
    transition: opacity 0.2s ease;
}

.pack-author:hover {
    opacity: 0.8;
}

/* Кнопки действий */
.pack-actions {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    max-width: 400px;
    margin: 0 auto;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.25rem;
    font-size: 0.9375rem;
    font-weight: 500;
    line-height: 1.2;
    border-radius: 12px;
    border: none;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
}

.btn-primary {
    background: var(--button-primary-bg);
    color: var(--button-primary-text);
}

.btn-primary:hover:not(:disabled) {
    opacity: 0.9;
    transform: translateY(-1px);
}

.btn-secondary {
    background: var(--button-secondary-bg);
    color: var(--text-primary);
    border: 1px solid var(--post-border);
}

.btn-secondary:hover:not(:disabled) {
    background: var(--sidebar-bg);
}

.btn-danger {
    background: #ff4444;
    color: white;
}

.btn-danger:hover:not(:disabled) {
    background: #e63946;
    transform: translateY(-1px);
}

.btn-block {
    width: 100%;
    justify-content: center;
}

.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Сетка стикеров */
.stickers-grid-section {
    background: var(--post-bg);
    border-radius: 16px;
    padding: 2rem;
    border: 1px solid var(--post-border);
}

.section-title {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.stickers-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 1rem;
}

.sticker-item {
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--sidebar-bg);
    border-radius: 12px;
    padding: 0.75rem;
    transition: all 0.2s ease;
    cursor: pointer;
    position: relative;
}

.sticker-item:hover {
    background: var(--body-bg);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.sticker-item img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

/* Модальное окно */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.modal.show {
    opacity: 1;
}

.modal-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
}

.modal-dialog {
    position: relative;
    width: 90%;
    max-width: 500px;
    margin: 50px auto;
    z-index: 10001;
    transform: translateY(-50px);
    transition: transform 0.3s ease;
}

.modal.show .modal-dialog {
    transform: translateY(0);
}

.modal-content {
    background: var(--post-bg);
    border-radius: 16px;
    border: 1px solid var(--post-border);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    overflow: hidden;
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.5rem;
    border-bottom: 1px solid var(--post-border);
    background: var(--sidebar-bg);
}

.modal-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
}

.modal-close {
    background: transparent;
    border: none;
    padding: 0.5rem;
    cursor: pointer;
    color: var(--text-secondary);
    transition: all 0.2s ease;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-close:hover {
    background: var(--post-bg);
    color: var(--text-primary);
}

.modal-body {
    padding: 1.5rem;
}

.modal-footer {
    display: flex;
    gap: 0.75rem;
    padding: 1.5rem;
    border-top: 1px solid var(--post-border);
    justify-content: flex-end;
    background: var(--sidebar-bg);
}

/* Поле поделиться */
.share-link-container {
    display: flex;
    gap: 0.5rem;
}

.share-link-input {
    flex: 1;
    padding: 0.75rem 1rem;
    border: 1px solid var(--input-border);
    border-radius: 12px;
    background: var(--input-bg);
    color: var(--text-primary);
    font-size: 0.9375rem;
    outline: none;
    transition: all 0.2s ease;
}

.share-link-input:focus {
    border-color: var(--accent-color);
    box-shadow: 0 0 0 3px rgba(var(--accent-color-rgb), 0.1);
}

.copy-link-btn {
    padding: 0.75rem 1rem;
    background: var(--button-primary-bg);
    color: var(--button-primary-text);
    border: none;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.copy-link-btn:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}

.copy-link-btn:active {
    transform: scale(0.95);
}

/* Body с открытым модальным окном */
body.modal-open {
    overflow: hidden;
}

/* Анимации */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.stickers-grid-section {
    animation: fadeIn 0.3s ease;
}

/* Адаптивность */
@media (max-width: 768px) {
    .sticker-pack-card {
        padding: 1.5rem;
    }
    
    .pack-title {
        font-size: 1.5rem;
    }
    
    .pack-preview-grid {
        grid-template-columns: repeat(2, 100px);
        gap: 0.75rem;
    }
    
    .pack-preview-sticker {
        width: 100px;
        height: 100px;
    }
    
    .pack-meta {
        gap: 1rem;
        font-size: 0.875rem;
    }
    
    .stickers-grid {
        grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
        gap: 0.75rem;
    }
    
    .modal-dialog {
        width: 95%;
        margin: 20px auto;
    }
    
    .modal-header,
    .modal-body,
    .modal-footer {
        padding: 1rem;
    }
}

@media (max-width: 480px) {
    .pack-title {
        font-size: 1.25rem;
    }
    
    .pack-preview {
        padding: 1rem;
        min-height: 150px;
    }
    
    .stickers-grid {
        grid-template-columns: repeat(auto-fill, minmax(70px, 1fr));
        gap: 0.5rem;
    }
    
    .sticker-item {
        padding: 0.5rem;
    }
    
    .pack-actions {
        gap: 0.5rem;
    }
    
    .btn {
        padding: 0.625rem 1rem;
        font-size: 0.875rem;
    }
}

/* Отключение скролла при открытом модальном окне */
body.modal-open {
    overflow: hidden;
    padding-right: var(--scrollbar-width, 0);
}