/**
 * Dịch Ngôn Ngữ WAT - Styles
 * Version: 1.0.0
 */

/* ============================================
   Ẩn Google Translate bar mặc định
   ============================================ */
.goog-te-banner-frame,
.skiptranslate,
#goog-gt-tt,
.goog-te-balloon-frame,
div#goog-gt- {
    display: none !important;
}

body {
    top: 0 !important;
}

/* Ẩn tooltip của Google Translate */
.goog-text-highlight {
    background-color: transparent !important;
    box-shadow: none !important;
}

/* ============================================
   Widget Container
   ============================================ */
.dich-nn-wat-widget {
    display: inline-block;
    position: relative;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
    font-size: 14px;
    z-index: 9999;
}

/* ============================================
   Current Language Selector
   ============================================ */
.dich-nn-wat-selector {
    position: relative;
}

.dich-nn-wat-current {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 10px;
    background: #ffffff;
    border: 1px solid #ddd;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.dich-nn-wat-current:hover {
    border-color: #bbb;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.dich-nn-wat-flag {
    display: block;
    border-radius: 2px;
    object-fit: cover;
}

.dich-nn-wat-arrow {
    font-size: 8px;
    color: #666;
    transition: transform 0.2s ease;
    margin-left: 2px;
    line-height: 1;
}

.dich-nn-wat-widget.open .dich-nn-wat-arrow {
    transform: rotate(180deg);
}

/* ============================================
   Dropdown Menu
   ============================================ */
.dich-nn-wat-dropdown {
    position: absolute;
    top: calc(100% + 4px);
    right: 0;
    left: auto;
    min-width: 160px;
    background: #ffffff;
    border: 1px solid #ddd;
    border-radius: 6px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.2s ease;
    z-index: 10000;
    overflow: hidden;
}

.dich-nn-wat-widget.open .dich-nn-wat-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

/* ============================================
   Dropdown Options
   ============================================ */
.dich-nn-wat-option {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    color: #333;
    text-decoration: none;
    transition: background-color 0.15s ease;
    border-bottom: 1px solid #f0f0f0;
}

.dich-nn-wat-option:last-child {
    border-bottom: none;
}

.dich-nn-wat-option:hover {
    background-color: #f5f5f5;
    color: #333;
    text-decoration: none;
}

.dich-nn-wat-option.active {
    background-color: #e8f4fc;
    font-weight: 600;
}

.dich-nn-wat-option span {
    white-space: nowrap;
}

/* ============================================
   Responsive
   ============================================ */
@media screen and (max-width: 768px) {
    .dich-nn-wat-widget {
        position: static;
    }
    
    .dich-nn-wat-selector {
        position: relative;
    }
    
    .dich-nn-wat-dropdown {
        right: 0;
        left: auto;
        min-width: 150px;
        max-width: calc(100vw - 20px);
    }
}

@media screen and (max-width: 480px) {
    .dich-nn-wat-current {
        padding: 6px 10px;
    }
    
    .dich-nn-wat-dropdown {
        min-width: 140px;
    }
    
    .dich-nn-wat-option {
        padding: 8px 12px;
        font-size: 13px;
    }
    
    .dich-nn-wat-option span {
        max-width: 100px;
        overflow: hidden;
        text-overflow: ellipsis;
    }
}
