:root {
    --bg-color: #ffffff;
    --text-color: #000000;
    --header-footer-bg: #f0f0f0;
    --button-bg: #e0e0e0;
    --active-btn-bg: #d0d0d0;
    --accent-color: #6a5acd;
    --error-color: #e74c3c;
}

.dark-theme {
    --bg-color: #121212;
    --text-color: #ffffff;
    --header-footer-bg: #1e1e1e;
    --button-bg: #333333;
    --active-btn-bg: #444444;
    --accent-color: #9370db;
}

/* Общие стили */
body {
    margin: 0;
    padding: 0;
    font-family: 'Segoe UI', Arial, sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    transition: background-color 0.3s, color 0.3s;
}

.section-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Шапка */
header {
    background-color: var(--header-footer-bg);
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 100;
}

.logo {
    font-size: 24px;
    font-weight: bold;
    color: var(--accent-color);
}

.header-buttons {
    display: flex;
    gap: 10px;
}

/* Кнопки */
.header-btn {
    background-color: var(--button-bg);
    border: none;
    padding: 8px 20px;
    border-radius: 20px;
    cursor: pointer;
    color: var(--text-color);
    font-weight: 600;
    transition: all 0.3s;
}

.header-btn:hover {
    background-color: var(--active-btn-bg);
    transform: translateY(-2px);
}

.header-btn.active {
    background-color: var(--accent-color);
    color: white;
}

.theme-toggle {
    background-color: var(--button-bg);
    border: none;
    padding: 8px 20px;
    border-radius: 20px;
    cursor: pointer;
    color: var(--text-color);
    font-weight: 600;
    transition: all 0.3s;
}

.theme-toggle:hover {
    background-color: var(--active-btn-bg);
}

/* Основное содержимое */
main {
    flex: 1;
    padding: 20px 0;
}

.content-section {
    display: none;
    animation: fadeIn 0.5s ease-in-out;
}

.content-section.active {
    display: block;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Информационный раздел */
.info-content {
    background-color: var(--button-bg);
    border-radius: 12px;
    padding: 25px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

.info-wrapper {
    display: flex;
    align-items: center;
    gap: 30px;
}

.info-image {
    width: 200px;
    height: 200px;
    border-radius: 12px;
    object-fit: cover;
    border: 3px solid var(--accent-color);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.info-text {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.info-text p {
    margin: 0;
    line-height: 1.6;
    position: relative;
    padding-left: 20px;
}

.info-text p::before {
    content: "•";
    color: var(--accent-color);
    position: absolute;
    left: 0;
}

/* Стили для элементов хранилища */
.storage-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    gap: 15px;
    flex-wrap: wrap;
    background-color: var(--button-bg);
    padding: 15px;
    border-radius: 10px;
}

.search-box {
    display: flex;
    flex: 1;
    min-width: 250px;
    max-width: 400px;
    position: relative;
}

.search-box input {
    flex: 1;
    padding: 10px 40px 10px 15px;
    border: 2px solid var(--header-footer-bg);
    border-radius: 20px;
    background-color: var(--bg-color);
    color: var(--text-color);
    transition: all 0.3s;
}

.search-box input:focus {
    outline: none;
    border-color: var(--accent-color);
    box-shadow: 0 0 0 2px rgba(106, 90, 205, 0.2);
}

.search-btn {
    position: absolute;
    right: 40px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    cursor: pointer;
    color: var(--text-color);
    opacity: 0.6;
}

.clear-search {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    cursor: pointer;
    color: var(--text-color);
    opacity: 0.4;
    transition: opacity 0.2s;
}

.clear-search:hover {
    opacity: 0.8;
}

.sort-options select {
    padding: 10px 15px;
    border: 2px solid var(--header-footer-bg);
    border-radius: 20px;
    background-color: var(--bg-color);
    color: var(--text-color);
    cursor: pointer;
}

.storage-status {
    text-align: center;
    padding: 20px;
    color: var(--text-color);
    opacity: 0.7;
}

.storage-items {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 15px;
    margin-top: 15px;
}

.storage-item {
    display: flex;
    align-items: center;
    background-color: var(--button-bg);
    padding: 15px;
    border-radius: 10px;
    transition: all 0.3s;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    border-left: 4px solid var(--accent-color);
}

.storage-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.item-icon {
    font-size: 28px;
    margin-right: 15px;
    color: var(--accent-color);
}

.item-info {
    flex: 1;
    min-width: 0;
}

.item-info h3 {
    margin: 0 0 5px 0;
    font-size: 16px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.item-info p {
    margin: 0;
    color: var(--text-color);
    opacity: 0.7;
    font-size: 13px;
    display: -webkit-box;
    line-clamp: 2;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.download-btn {
    background-color: var(--accent-color);
    color: white;
    padding: 8px 12px;
    border-radius: 15px;
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
    transition: all 0.3s;
    white-space: nowrap;
}

.download-btn:hover {
    background-color: var(--text-color);
    color: var(--bg-color);
}

.no-results {
    grid-column: 1 / -1;
    text-align: center;
    padding: 40px;
    color: var(--text-color);
    opacity: 0.5;
}

footer {
    padding: 80px 20px;
    position: relative;
    overflow: hidden;
    min-height: 15vh;
    display: flex;
    justify-content: center;
    align-items: flex-end;
    margin-top: 40px;
}

.footer-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('sources/black_paper.png');
    background-size: cover;
    opacity: 0.3;
    z-index: 0;
}

.footer-content {
    position: relative;
    z-index: 1;
    text-align: center;
    width: 100%;
    margin-bottom: 0;
}

.footer-logo {
    font-size: 28px;
    font-weight: bold;
    margin-bottom: 15px;
    color: var(--accent-color);
}

.footer-small-logo {
    position: absolute;
    top: 10vb;
    left: 30px;
    font-size: 18px;
    font-weight: bold;
}

.social-buttons {
    display: flex;
    justify-content: center;
    gap: 16px;
    margin-top: 20px;
    flex-wrap: wrap;
}

.social-button {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    background-color: var(--button-bg);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    position: relative;
    overflow: hidden;
}

.social-icon {
    width: 26px;
    height: 26px;
    object-fit: contain;
    transition: all 0.3s ease;
    filter: brightness(0) invert(0.3);
}

.social-button:hover {
    transform: translateY(-4px) scale(1.1);
    box-shadow: 0 7px 14px rgba(0, 0, 0, 0.15);
}

.social-button:hover .social-icon {
    filter: brightness(0) invert(1);
}

.youtube:hover { background-color: #FF0000; }
.twitch:hover { background-color: #9146FF; }
.telegram:hover { background-color: #28A8E9; }
.discord:hover { background-color: #5865F2; }
.youtube-vods:hover { background-color: #FF0000; }
.tiktok:hover { background-color: #000000; }

.social-button::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 5px;
    height: 5px;
    background: rgba(255, 255, 255, 0.4);
    opacity: 0;
    border-radius: 100%;
    transform: scale(1, 1) translate(-50%, -50%);
    transform-origin: 50% 50%;
}

.social-button:hover::after {
    animation: ripple 0.6s ease-out;
}

@keyframes ripple {
    0% { transform: scale(0, 0); opacity: 0.4; }
    100% { transform: scale(12, 12); opacity: 0; }
}

@media (max-width: 480px) {
    .social-buttons { gap: 12px; }
    .social-button { width: 46px; height: 46px; }
    .social-icon { width: 22px; height: 22px; }
}
.social-button.twitch:hover { background-color: #9146FF; }
.social-button.telegram:hover { background-color: #0088cc; }
.social-button.discord:hover { background-color: #5865F2; }
.social-button.youtube:hover { background-color: #FF0000; }
.social-button.tiktok:hover { background-color: #000000; }

.social-button::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    opacity: 0;
    transition: opacity 0.3s, transform 0.3s;
    transform: scale(0.8);
}

.social-button:hover::after {
    opacity: 1;
    transform: scale(1);
}

@media (max-width: 480px) {
    .social-buttons {
        gap: 10px;
    }
    
    .social-button {
        width: 44px;
        height: 44px;
    }
    
    .social-button img {
        width: 24px;
        height: 24px;
    }
}
@media (max-width: 480px) {
    .social-buttons {
        gap: 10px;
        max-width: 100%;
    }
    
    .social-button {
        width: 44px;
        height: 44px;
        font-size: 20px;
    }
}

@media (max-width: 768px) {
    header {
        flex-direction: column;
        gap: 15px;
        padding: 15px;
    }
    
    .header-buttons {
        width: 100%;
        justify-content: center;
    }
    
    .info-wrapper {
        flex-direction: column;
    }
    
    .info-image {
        width: 150px;
        height: 150px;
        margin-bottom: 20px;
    }
    
    .storage-controls {
        flex-direction: column;
        align-items: stretch;
    }
    
    .search-box {
        max-width: 100%;
    }
}

@media (max-width: 480px) {
    .storage-items {
        grid-template-columns: 1fr;
    }
    
    .footer-small-logo {
        position: static;
        margin-bottom: 15px;
    }
    
    .social-buttons {
        gap: 10px;
        max-width: 100%;
    }
    
    .social-button {
        width: 40px;
        height: 40px;
        font-size: 16px;
    }
}