@font-face {
    font-family: 'Kyiv*Type Serif';
    src: url('путь/к/шрифту.woff2') format('woff2');
    font-weight: 350;
    font-style: normal;
}

/* Базовые стили */
body {
    margin-left: 250px;
    margin-top: 120px;
    padding: 0;
    background: #D9D9D9;
    font-family: 'Kyiv*Type Serif', Georgia, serif;
    position: relative;
}

.container {
    position: absolute;
    width: 1080px;
    background: #D9D9D9;
}

.header {
    position: absolute;
    width: 1100px;
    height: 498px;
    background: #FFFFFF;
}

/* Область предпросмотра */
.meme-preview {
    position: absolute;
    width: 309px;
    height: 307px;
    left: 15px;
    top: 38px;
    background: #D9D9D9;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.meme-image {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

/* Специальная картинка */
.meme-image.special {
    filter: grayscale(100%);
    border: 3px dashed #ff0000;
    padding: 5px;
    opacity: 0.7;
}

/* Кнопки */
.save-btn, .delete-btn {
    position: absolute;
    font-size: 24px;
    cursor: pointer;
    padding: 8px 16px;
    background: #ffffff;
    border: 2px solid #000;
    border-radius: 5px;
    transition: all 0.3s;
}

.save-btn:hover, .delete-btn:hover {
    background: #000;
    color: #fff;
}

.save-btn {
    left: 37px;
    top: 386px;
}

.delete-btn {
    left: 199px;
    top: 386px;
}

/* Секция генерации */
/* Секция генерации */
.generator-section {
    position: absolute;
    width: 569px;
    height: 142px;
    left: 443px;
    top: 33px;
    background: #D9D9D9;
}

.generate-btn {
    font-size: 24px;
    cursor: pointer;
    padding: 12px 24px;
    background: #D9D9D9;
    color: #000;
    border: 2px solid #808080;
    border-radius: 8px;
    transition: all 0.3s;
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    white-space: nowrap;
}

.generate-btn:hover {
    background: #C0C0C0;
    box-shadow: 0 2px 6px rgba(0,0,0,0.2);
}

/* Секция обновлений */
.updates-section {
    position: absolute;
    width: 569px;
    left: 443px;
    top: 239px;
    background: #D9D9D9;
    padding: 20px;
}

.recent-memes {
    font-size: 24px;
    text-align: center;
    margin-bottom: 20px;
}

.thumbnails-container {
    display: flex;
    gap: 15px;
    justify-content: center;
    overflow-x: auto;
    padding: 10px 0;
}

/* Стили для уведомлений */
.toast {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 12px 24px;
    border-radius: 25px;
    font-size: 16px;
    animation: fadeInOut 2s ease-in-out;
}

@keyframes fadeInOut {
    0% { opacity: 0; }
    15% { opacity: 1; }
    85% { opacity: 1; }
    100% { opacity: 0; }
}

/* Миниатюры */
.thumbnails-container {
    display: flex;
    gap: 15px;
    justify-content: center;
    padding: 10px 0;
}

.meme-thumbnail {
    width: 180px;
    height: 180px;
    flex-shrink: 0;
    border: 2px solid #fff;
    border-radius: 8px;
    overflow: hidden;
    background: #fff;
    position: relative;
}

.thumbnail-image-container {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.thumbnail-img {
    object-fit: cover;
    object-position: center;
    transition: transform 0.3s;
}

/* Вертикальные мемы */
.meme-thumbnail.portrait .thumbnail-img {
    width: auto;
    height: 100%;
}

/* Горизонтальные мемы */
.meme-thumbnail.landscape .thumbnail-img {
    width: 100%;
    height: auto;
}

/* Анимация */
.meme-thumbnail:hover .thumbnail-img {
    transform: scale(1.05);
}

.meme-thumbnail:hover {
    transform: scale(1.05);
    z-index: 1;
}

.thumbnail-image-container {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.thumbnail-img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    padding: 4px;
}

/* Заголовок */
.main-title {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    top: -110px;
    font-size: 40px;
    line-height: 100px;
    text-align: center;
}
