/* ============================================================
   style.css - Îáùèå ñòèëè äëÿ âñåãî ñàéòà
   ============================================================ */

/* ÁÀÇÎÂÛÅ ÍÀÑÒÐÎÉÊÈ */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: #FFDEAC;
    background-attachment: fixed;
    background-position: center;
    font-family: "Comic Sans MS", "Comic Sans", cursive, sans-serif;
    color: #333;
    line-height: 1.6;
    min-height: 100vh;
}

a {
    text-decoration: none;
    color: #1a4b8c;
    transition: all 0.3s ease;
}

a:hover {
    color: #8B008B;
    text-decoration: underline;
}

a:visited {
    color: #8B4513;
}

/* ØÀÏÊÀ */
.header {
    background: rgba(139, 69, 19, 0.15);
    padding: 20px 30px;
    border-bottom: 3px solid #8B4513;
    text-align: center;
}

.header h1 {
    font-size: 28px;
    color: #1a4b8c;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.1);
}

.header .subtitle {
    color: #666;
    font-size: 16px;
    margin-top: 5px;
}

.header .subtitle a {
    color: #1a4b8c;
    font-weight: bold;
}

.header .subtitle a:hover {
    color: #8B008B;
}

/* ÁÎÊÎÂÎÅ ÌÅÍÞ */
.sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: 220px;
    height: 100vh;
    background: rgba(255, 222, 172, 0.95);
    border-right: 3px solid #8B4513;
    padding: 20px 15px;
    overflow-y: auto;
    z-index: 1000;
    box-shadow: 3px 0 15px rgba(0,0,0,0.1);
}

.sidebar::-webkit-scrollbar {
    width: 6px;
}

.sidebar::-webkit-scrollbar-track {
    background: rgba(139, 69, 19, 0.1);
}

.sidebar::-webkit-scrollbar-thumb {
    background: #8B4513;
    border-radius: 3px;
}

.sidebar .logo {
    text-align: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid rgba(139, 69, 19, 0.3);
}

.sidebar .logo img {
    max-width: 100%;
    height: auto;
}

.sidebar .nav-item {
    display: block;
    padding: 6px 8px;
    margin: 2px 0;
    color: #333;
    border-radius: 5px;
    transition: all 0.2s ease;
    font-size: 14px;
}

.sidebar .nav-item:hover {
    background: rgba(139, 69, 19, 0.15);
    color: #8B008B;
    text-decoration: none;
    padding-left: 15px;
}

.sidebar .nav-item img {
    max-width: 100%;
    height: auto;
    display: block;
}

.sidebar .nav-item.logo-item {
    padding: 0;
    background: none !important;
}

.sidebar .nav-item.logo-item:hover {
    padding: 0;
}

/* ÎÑÍÎÂÍÎÉ ÊÎÍÒÅÍÒ */
.main-content {
    margin-left: 240px;
    padding: 30px 40px;
    max-width: 1200px;
}

/* ÈÍÔÎÐÌÀÖÈÎÍÍÛÉ ÁËÎÊ */
.info-block {
    background: rgba(255, 255, 255, 0.5);
    padding: 20px 25px;
    border-radius: 10px;
    margin-bottom: 30px;
    border-left: 5px solid #1a4b8c;
}

.info-block p {
    font-size: 16px;
    color: #333;
    margin: 0;
    text-align: left;
}

.info-block .highlight {
    color: #1a4b8c;
    font-weight: bold;
}

/* ÇÀÃÎËÎÂÊÈ */
.section-title {
    font-size: 24px;
    color: #1a4b8c;
    text-align: center;
    margin: 30px 0 20px;
    padding-bottom: 10px;
    border-bottom: 3px double #8B4513;
}

.section-title u {
    text-decoration: none;
    border-bottom: 2px solid #1a4b8c;
}

/* ÑÏÈÑÎÊ ÑÝÌÏËÎÂ */
.sample-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.sample-item {
    background: rgba(255, 255, 255, 0.6);
    padding: 12px 18px;
    border-radius: 8px;
    border-left: 4px solid #8B4513;
    transition: all 0.3s ease;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 15px;
}

.sample-item:hover {
    background: rgba(255, 255, 255, 0.9);
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    transform: translateX(5px);
}

.sample-item .id {
    font-weight: bold;
    color: #1a4b8c;
    min-width: 80px;
    font-size: 15px;
}

.sample-item .lang {
    font-weight: bold;
    font-size: 13px;
    padding: 2px 8px;
    border-radius: 4px;
    background: rgba(0,0,0,0.05);
}

.sample-item .lang.ger { color: #2E7D32; }
.sample-item .lang.ital { color: #C62828; }
.sample-item .lang.fr { color: #0D47A1; }
.sample-item .lang.hindi { color: #4E342E; }
.sample-item .lang.china { color: #1A237E; }
.sample-item .lang.japan { color: #6A1B9A; }

.sample-item .gender {
    color: #9C27B0;
    font-weight: bold;
    font-size: 13px;
}

.sample-item .title {
    flex: 1;
    min-width: 150px;
    color: #333;
    font-size: 15px;
}

.sample-item .title .original {
    color: #666;
    font-size: 13px;
}

.sample-item audio {
    width: 100%;
    max-width: 300px;
    height: 32px;
    margin: 5px 0;
}

.sample-item .tag {
    font-size: 11px;
    padding: 1px 8px;
    border-radius: 10px;
    background: rgba(139, 69, 19, 0.15);
    color: #8B4513;
}

/* ÐÀÇÄÅËÈÒÅËÜ */
.divider {
    border: none;
    border-top: 3px double #8B4513;
    margin: 30px 0 20px;
    opacity: 0.4;
}

/* ÔÓÒÅÐ */
.footer {
    text-align: center;
    padding: 20px;
    margin-top: 30px;
    border-top: 2px solid rgba(139, 69, 19, 0.2);
    color: #666;
    font-size: 14px;
}

/* ÊÍÎÏÊÀ "ÍÀÂÅÐÕ" */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background: #8B4513;
    color: #fff;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    cursor: pointer;
    box-shadow: 0 2px 10px rgba(0,0,0,0.2);
    transition: all 0.3s ease;
    z-index: 999;
    border: none;
    opacity: 0;
    pointer-events: none;
}

.back-to-top.visible {
    opacity: 1;
    pointer-events: auto;
}

.back-to-top:hover {
    background: #5c2d0e;
    transform: scale(1.1);
}

/* ÀÄÀÏÒÈÂÍÎÑÒÜ */
@media (max-width: 992px) {
    .sidebar {
        width: 200px;
    }
    .main-content {
        margin-left: 215px;
        padding: 20px;
    }
    .sample-item audio {
        max-width: 100%;
    }
}

@media (max-width: 768px) {
    .sidebar {
        position: relative;
        width: 100%;
        height: auto;
        max-height: 250px;
        overflow-y: auto;
        border-right: none;
        border-bottom: 3px solid #8B4513;
        box-shadow: 0 3px 10px rgba(0,0,0,0.1);
        padding: 10px 15px;
    }

    .sidebar .logo {
        margin-bottom: 10px;
        padding-bottom: 10px;
    }

    .sidebar .nav-item {
        display: inline-block;
        padding: 4px 10px;
        margin: 2px 4px;
        font-size: 13px;
    }

    .sidebar .nav-item:hover {
        padding-left: 10px;
        padding-right: 10px;
    }

    .sidebar .nav-item.logo-item {
        display: block;
    }

    .main-content {
        margin-left: 0;
        padding: 15px;
    }

    .header h1 {
        font-size: 22px;
    }

    .section-title {
        font-size: 20px;
    }

    .sample-item {
        flex-direction: column;
        align-items: stretch;
        gap: 5px;
    }

    .sample-item .id {
        min-width: auto;
    }

    .sample-item .title {
        min-width: auto;
    }

    .sample-item audio {
        max-width: 100%;
    }

    .back-to-top {
        bottom: 20px;
        right: 20px;
        width: 40px;
        height: 40px;
        font-size: 18px;
    }

    .info-block {
        padding: 15px;
    }
}

@media (max-width: 480px) {
    .header {
        padding: 12px 15px;
    }

    .header h1 {
        font-size: 18px;
    }

    .main-content {
        padding: 10px;
    }

    .sample-item {
        padding: 8px 12px;
    }

    .sample-item .id {
        font-size: 13px;
    }

    .sample-item .title {
        font-size: 14px;
    }

    .sidebar .nav-item {
        font-size: 12px;
        padding: 3px 7px;
    }

    .info-block p {
        font-size: 14px;
    }
}

/* ÀÍÈÌÀÖÈß ÇÀÃÐÓÇÊÈ */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.sample-item {
    animation: fadeIn 0.4s ease forwards;
}

.sample-item:nth-child(1) { animation-delay: 0.02s; }
.sample-item:nth-child(2) { animation-delay: 0.04s; }
.sample-item:nth-child(3) { animation-delay: 0.06s; }
.sample-item:nth-child(4) { animation-delay: 0.08s; }
.sample-item:nth-child(5) { animation-delay: 0.10s; }