/* ───────── SM Translate – Language Switcher ───────── */

/* Container */
.smt-switcher {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 99999;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, sans-serif;
}

/* Toggle button */
.smt-switcher-toggle {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 10px 16px;
    font-size: 14px;
    line-height: 1.4;
    color: #fff;
    background: #1d2327;
    border: none;
    border-radius: 50px;
    cursor: pointer;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.18);
    transition: background 0.2s, box-shadow 0.2s, transform 0.15s;
}

.smt-switcher-toggle:hover {
    background: #2c3338;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.24);
    transform: translateY(-1px);
}

.smt-switcher-toggle:focus {
    outline: 2px solid #2271b1;
    outline-offset: 2px;
}

.smt-switcher-icon {
    font-size: 18px;
}

.smt-switcher-current {
    font-weight: 500;
}

/* Dropdown */
.smt-switcher-dropdown {
    list-style: none;
    margin: 0;
    padding: 6px 0;
    position: absolute;
    bottom: 100%;
    right: 0;
    min-width: 180px;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px);
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
    margin-bottom: 8px;
}

.smt-switcher-open .smt-switcher-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.smt-switcher-dropdown li {
    margin: 0;
    padding: 0;
}

.smt-switcher-dropdown a {
    display: block;
    padding: 10px 18px;
    color: #1d2327;
    text-decoration: none;
    font-size: 14px;
    transition: background 0.15s;
}

.smt-switcher-dropdown a:hover {
    background: #f0f0f1;
}

.smt-switcher-dropdown .smt-switcher-active a {
    font-weight: 600;
    color: #2271b1;
    background: #e8f0fe;
}

/* ───────── Mobile (≤ 600px) ───────── */
@media (max-width: 600px) {
    .smt-switcher {
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        z-index: 99999;
    }

    .smt-switcher-toggle {
        width: 100%;
        border-radius: 0;
        justify-content: center;
        padding: 14px 20px;
        font-size: 15px;
        box-shadow: 0 -2px 12px rgba(0, 0, 0, 0.1);
    }

    .smt-switcher-dropdown {
        bottom: 100%;
        left: 0;
        right: 0;
        border-radius: 12px 12px 0 0;
        margin-bottom: 0;
    }

    .smt-switcher-dropdown a {
        padding: 14px 20px;
        font-size: 16px;
        text-align: center;
    }
}

/* ───── Language index page styles ───── */
.smt-index-page {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px 0;
}

.smt-index-post {
    display: flex;
    gap: 20px;
    margin-bottom: 28px;
    padding-bottom: 28px;
    border-bottom: 1px solid #e5e7eb;
}

.smt-index-post:last-child {
    border-bottom: none;
}

.smt-index-post-image {
    flex-shrink: 0;
    width: 160px;
}

.smt-index-post-image img {
    width: 100%;
    height: 120px;
    object-fit: cover;
    border-radius: 8px;
}

.smt-index-post-content {
    flex: 1;
    min-width: 0;
}

.smt-index-post-title {
    margin: 0 0 4px;
    font-size: 18px;
    line-height: 1.4;
}

.smt-index-post-title a {
    color: inherit;
    text-decoration: none;
}

.smt-index-post-title a:hover {
    text-decoration: underline;
}

.smt-index-post-date {
    display: block;
    margin-bottom: 8px;
    font-size: 13px;
    color: #6b7280;
}

.smt-index-post-excerpt {
    margin: 0 0 8px;
    font-size: 14px;
    color: #4b5563;
    line-height: 1.6;
}

.smt-index-read-more {
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
}

@media (max-width: 600px) {
    .smt-index-post {
        flex-direction: column;
        gap: 12px;
    }

    .smt-index-post-image {
        width: 100%;
    }

    .smt-index-post-image img {
        height: 180px;
    }
}