/*
 * bottom-nav.css — Reorganização Ergonómica do Feed MyTube
 * Monocromático, sem poluição de cores, ícones nítidos e limpos.
 */

/* =============================================
   VARIÁVEIS DE ALTURA DA BARRA INFERIOR
   ============================================= */
:root {
    --safe-bottom: env(safe-area-inset-bottom, 0px);
    --bottom-nav-height: 48px;
    --bottom-nav-total: calc(var(--bottom-nav-height) + var(--safe-bottom));
}

/* =============================================
   BOTTOM NAVIGATION — Barra inferior fixa
   ============================================= */
.bottom-nav {
    font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    position: fixed;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: 520px;
    height: var(--bottom-nav-height);
    padding-bottom: var(--safe-bottom);
    display: flex;
    align-items: center;
    justify-content: space-around;
    background: #000000;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 0;
    z-index: 99;
    box-sizing: border-box;
}

.bottom-nav-item {
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255, 255, 255, 0.5);
    text-decoration: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    width: 48px;
    height: 48px;
    transition: color 0.2s ease, transform 0.15s ease;
    position: relative;
    -webkit-tap-highlight-color: transparent;
}

.bottom-nav-item:hover,
.bottom-nav-item.active {
    color: #ffffff;
}

.bottom-nav-item.active .nav-icon {
    stroke: #ffffff;
}

/* Ícones SVG da barra inferior — GARANTIR VISIBILIDADE */
.bottom-nav-item .nav-icon {
    width: 24px;
    height: 24px;
    display: block !important;
    stroke: currentColor;
    stroke-width: 2;
    transition: transform 0.2s ease, filter 0.2s ease;
    filter: drop-shadow(0 1px 3px rgba(0, 0, 0, 0.8));
}

/* Ícones FontAwesome (caso algum item use) */
.bottom-nav-item i {
    font-size: 22px;
    display: block !important;
    filter: drop-shadow(0 1px 3px rgba(0, 0, 0, 0.8));
}

/* Esconder legendas de texto — estilo Instagram Reels */
.bottom-nav-item span.nav-label {
    display: none !important;
}

/* Badge de não lidas no Chat */
.bottom-nav-item .nav-badge {
    position: absolute;
    top: 6px;
    right: 8px;
    min-width: 15px;
    height: 15px;
    background: #ff3b5c;
    border-radius: 9px;
    font-size: 9px;
    font-weight: 700;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 3px;
    border: 2px solid #000;
    line-height: 1;
}

/* Wrapper do Perfil */
.bottom-nav-profile-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Foto de perfil no item de Perfil */
.bottom-nav-profile-pic {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    object-fit: cover;
    border: 1.5px solid rgba(255, 255, 255, 0.5);
    display: block !important;
    transition: border-color 0.2s ease, transform 0.2s ease;
}

/* Item ativo — foto com anel branco puro */
.bottom-nav-item.active .bottom-nav-profile-pic {
    border-color: #ffffff;
    box-shadow: 0 0 0 1.5px #ffffff;
    transform: scale(1.08);
}

/* Dot de notificação sobre o ícone de perfil */
.nav-notif-dot {
    position: absolute;
    top: -1px;
    right: -1px;
    width: 8px;
    height: 8px;
    background: #ff3b5c;
    border-radius: 50%;
    border: 1.5px solid #000;
    display: none;
}

/* =============================================
   LIMPAR O TOPO — Remover botões de navegação
   ============================================= */

/* No feed, o header só mostra Logo + Som */
.tiktok-header .header-actions {
    display: none !important;
}

.tiktok-header.header-profile-mode .header-actions {
    display: flex !important;
}

.tiktok-logo {
    pointer-events: auto !important;
}

/* =============================================
   AJUSTAR BOTÕES DE AÇÃO — Subir acima do menu
   ============================================= */
.action-buttons {
    bottom: calc(var(--bottom-nav-total) + 70px) !important;
}

.video-info-overlay {
    padding-bottom: calc(var(--bottom-nav-total) + 12px) !important;
    padding-right: 72px !important;
}

.video-info-overlay > *:last-child,
.video-author-row:last-child {
    margin-bottom: 0 !important;
}

.progress-container {
    bottom: var(--bottom-nav-total) !important;
}

/* Garantir visibilidade consistente da linha do tempo sobre qualquer vídeo */
.progress-track {
    background: rgba(255, 255, 255, 0.35) !important;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.85) !important;
}

/* =============================================
   SOMBRAS FORTES NOS ÍCONES DE AÇÃO LATERAIS
   ============================================= */
.action-btn svg {
    filter: drop-shadow(0 1px 4px rgba(0, 0, 0, 0.9))
            drop-shadow(0 0 8px rgba(0, 0, 0, 0.6)) !important;
}

.action-btn.liked svg.icon-heart {
    filter: drop-shadow(0 0 8px rgba(255, 48, 64, 0.5))
            drop-shadow(0 1px 3px rgba(0, 0, 0, 0.8)) !important;
}

.action-count,
.like-count {
    text-shadow:
        0 1px 0 #000,
        0 0 6px rgba(0, 0, 0, 0.9),
        0 2px 8px rgba(0, 0, 0, 0.8) !important;
}

/* Botão Seguir — ocultar da coluna lateral */
.action-buttons .follow-btn {
    display: none !important;
}

.follow-btn-inline {
    pointer-events: auto;
}

/* =============================================
   VÍDEOS HORIZONTAIS (ESTILO TIKTOK — GRAVAÇÕES DE PC / GAMEPLAY)
   ============================================= */
.video-item.video-is-horizontal .video-player video {
    object-fit: contain !important;
    background: #000;
}

/* =============================================
   MODAL DE MAIS OPÇÕES — BOTTOM SHEET UNIVERSAL
   ============================================= */

/* Ocultar o antigo popup balão que ficava a flutuar ao lado do botão 3 pontos */
.more-menu {
    display: none !important;
}

.more-options-overlay {
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    -webkit-backdrop-filter: blur(8px);
    backdrop-filter: blur(8px);
    z-index: 10000;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.more-options-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.more-options-sheet {
    width: 100%;
    max-width: 500px;
    background: #171717;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 24px 24px 0 0;
    padding: 12px 18px calc(18px + env(safe-area-inset-bottom, 0px));
    transform: translateY(100%);
    transition: transform 0.28s cubic-bezier(0.32, 0.72, 0, 1);
    box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.7);
    box-sizing: border-box;
    max-height: 90vh;
    overflow-y: auto;
}

.more-options-overlay.active .more-options-sheet {
    transform: translateY(0);
}

.sheet-handle-bar {
    width: 36px;
    height: 4px;
    background: #525252;
    border-radius: 9999px;
    margin: 4px auto 14px;
}

.more-options-header {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 4px 12px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.more-options-title {
    font-size: 15px;
    font-weight: 700;
    color: #ffffff;
}

.more-options-close-btn {
    background: rgba(255, 255, 255, 0.06);
    border: none;
    color: rgba(255, 255, 255, 0.6);
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 12px;
    transition: all 0.2s ease;
}

.more-options-close-btn:hover {
    background: rgba(255, 255, 255, 0.18);
    color: #ffffff;
}

.more-options-list {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin: 10px 0;
}

.more-option-item {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    padding: 12px 14px;
    background: transparent;
    border: none;
    border-radius: 12px;
    color: #f5f5f5;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    text-align: left;
    transition: background 0.15s ease, color 0.15s ease;
    font-family: inherit;
    -webkit-tap-highlight-color: transparent;
}

.more-option-item:hover,
.more-option-item:active {
    background: rgba(255, 255, 255, 0.1);
    transform: scale(0.99);
}

.more-option-item svg,
.more-option-item i {
    width: 18px;
    height: 18px;
    font-size: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: rgba(255, 255, 255, 0.8);
}

.more-option-item.danger {
    color: #ff4d4d;
    background: rgba(255, 77, 77, 0.06);
    border-color: rgba(255, 77, 77, 0.12);
}

.more-option-item.danger svg,
.more-option-item.danger i {
    color: #ff4d4d;
}

.more-option-item.danger:hover,
.more-option-item.danger:active {
    background: rgba(255, 77, 77, 0.15);
}

.more-options-cancel-btn {
    width: 100%;
    padding: 12px;
    background: #262626;
    border: none;
    border-radius: 12px;
    color: #e5e5e5;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.15s ease, color 0.15s ease;
    font-family: inherit;
    margin-top: 6px;
}

.more-options-cancel-btn:hover,
.more-options-cancel-btn:active {
    background: #333333;
    color: #ffffff;
}

/* =============================================
   SUB-VIEWS DENTRO DA MORE-OPTIONS-SHEET
   ============================================= */
.more-options-view {
    display: none;
    width: 100%;
}

.more-options-view.active {
    display: block;
}

@keyframes sheetSlideLeft {
    from {
        opacity: 0;
        transform: translateX(20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes sheetSlideRight {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.more-options-view.slide-in-left {
    animation: sheetSlideLeft 0.22s cubic-bezier(0.32, 0.72, 0, 1);
}

.more-options-view.slide-in-right {
    animation: sheetSlideRight 0.22s cubic-bezier(0.32, 0.72, 0, 1);
}

/* Header de Sub-View com Botão Voltar */
.more-options-header.report-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 0 12px;
}

.more-options-back-btn {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: none;
    background: rgba(255, 255, 255, 0.06);
    color: rgba(255, 255, 255, 0.85);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.15s ease;
}

.more-options-back-btn:hover,
.more-options-back-btn:active {
    background: rgba(255, 255, 255, 0.15);
    color: #ffffff;
    transform: scale(1.05);
}

.more-options-header-spacer {
    width: 32px;
    height: 32px;
}

.report-view-subtitle {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.5);
    margin: 4px 2px 14px;
    text-align: left;
}

/* Lista de Motivos */
.report-reasons-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-bottom: 12px;
}

.report-reason-row {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 11px 14px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 12px;
    cursor: pointer;
    transition: background 0.15s ease, border-color 0.15s ease, transform 0.1s ease;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
}

.report-reason-row:hover {
    background: rgba(255, 255, 255, 0.06);
}

.report-reason-row:active {
    transform: scale(0.99);
}

.report-reason-row.selected,
.report-reason-row:has(input:checked) {
    background: rgba(59, 130, 246, 0.08);
    border-color: rgba(59, 130, 246, 0.35);
}

.report-reason-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

.report-reason-icon-wrap {
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255, 255, 255, 0.65);
    flex-shrink: 0;
    transition: color 0.15s ease, transform 0.15s ease;
}

.report-reason-svg {
    width: 20px;
    height: 20px;
    display: block;
}

.report-reason-row:hover .report-reason-icon-wrap {
    color: rgba(255, 255, 255, 0.95);
}

.report-reason-row.selected .report-reason-icon-wrap,
.report-reason-row:has(input:checked) .report-reason-icon-wrap {
    color: #3b82f6;
    transform: scale(1.08);
}

.report-reason-text {
    font-size: 13.5px;
    font-weight: 500;
    color: #ffffff;
    line-height: 1.3;
}

/* Esconder radio nativo */
.report-reason-row input[type="radio"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
    pointer-events: none;
}

/* Indicador customizado elegante */
.report-radio-custom {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.25);
    transition: all 0.2s cubic-bezier(0.32, 0.72, 0, 1);
    flex-shrink: 0;
    box-sizing: border-box;
}

.report-reason-row input[type="radio"]:checked ~ .report-radio-custom,
.report-reason-row.selected .report-radio-custom {
    border-color: #3b82f6;
    background: #3b82f6;
    box-shadow: inset 0 0 0 3.5px #171717;
}

/* Grupo de Ações */
.report-actions-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-top: 14px;
}

.report-submit-action-btn {
    width: 100%;
    padding: 13px;
    border: none;
    border-radius: 12px;
    font-size: 14.5px;
    font-weight: 700;
    font-family: inherit;
    transition: all 0.2s cubic-bezier(0.32, 0.72, 0, 1);
    display: flex;
    align-items: center;
    justify-content: center;
}

.report-submit-action-btn:disabled {
    background: rgba(255, 255, 255, 0.08);
    color: rgba(255, 255, 255, 0.3);
    cursor: not-allowed;
    box-shadow: none;
}

.report-submit-action-btn:not(:disabled) {
    background: #ef4444;
    color: #ffffff;
    cursor: pointer;
    box-shadow: 0 4px 16px rgba(239, 68, 68, 0.35);
}

.report-submit-action-btn:not(:disabled):hover {
    background: #dc2626;
}

.report-submit-action-btn:not(:disabled):active {
    transform: scale(0.98);
}

.report-cancel-btn {
    margin-top: 0;
}

/* =============================================
   MODAL DE PARTILHA — BOTTOM SHEET UNIVERSAL
   ============================================= */

.share-modal-overlay {
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    -webkit-backdrop-filter: blur(8px);
    backdrop-filter: blur(8px);
    z-index: 10000;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.share-modal-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.share-modal-sheet {
    width: 100%;
    max-width: 500px;
    background: #171717;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 24px 24px 0 0;
    padding: 12px 18px calc(18px + env(safe-area-inset-bottom, 0px));
    transform: translateY(100%);
    transition: transform 0.28s cubic-bezier(0.32, 0.72, 0, 1);
    box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.7);
    box-sizing: border-box;
    max-height: 85vh;
    overflow-y: auto;
}

.share-modal-overlay.active .share-modal-sheet {
    transform: translateY(0);
}

.share-sheet-header {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 4px 14px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    margin-bottom: 18px;
}

.share-sheet-title {
    font-size: 15px;
    font-weight: 700;
    color: #ffffff;
    letter-spacing: -0.2px;
}

.share-targets-scroll {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    overflow-x: auto;
    padding: 4px 2px 18px;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
}

.share-targets-scroll::-webkit-scrollbar {
    display: none;
}

.share-target-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    min-width: 58px;
    outline: none;
    -webkit-tap-highlight-color: transparent;
    font-family: inherit;
    transition: transform 0.15s ease;
    flex-shrink: 0;
}

.share-target-item:active {
    transform: scale(0.92);
}

.share-target-icon {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    color: #ffffff;
    transition: transform 0.2s, filter 0.2s;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.35);
}

.share-target-icon.whatsapp {
    background: #25D366;
}

.share-target-icon.facebook {
    background: #1877F2;
}

.share-target-icon.chat {
    background: #2563eb;
}

.share-target-icon.copy,
.share-target-icon.native {
    background: #262626;
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: #f3f4f6;
}

.share-target-label {
    font-size: 11.5px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.85);
    text-align: center;
    white-space: nowrap;
    line-height: 1.2;
}

.share-link-preview-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #212121;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    padding: 8px 12px;
    margin-top: 4px;
    margin-bottom: 14px;
    gap: 10px;
}

.share-link-url {
    font-size: 12.5px;
    color: rgba(255, 255, 255, 0.6);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-family: monospace, system-ui, -apple-system;
    direction: ltr;
    text-align: left;
    flex: 1;
}

.share-link-btn {
    background: #2563eb;
    color: #ffffff;
    border: none;
    border-radius: 8px;
    padding: 7px 14px;
    font-size: 12.5px;
    font-weight: 600;
    cursor: pointer;
    flex-shrink: 0;
    transition: background 0.15s, transform 0.1s;
    font-family: inherit;
}

.share-link-btn:hover {
    background: #1d4ed8;
}

.share-link-btn:active {
    transform: scale(0.96);
}

/* =============================================
   DESKTOP: Mantém o mesmo layout do celular
   ============================================= */
@media (min-width: 769px) {
    .bottom-nav {
    font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
        display: flex !important;
    }

    .tiktok-header .header-actions {
        display: none !important;
    }

    .action-buttons {
        bottom: calc(var(--bottom-nav-total) + 40px) !important;
    }

    .video-info-overlay {
        padding-bottom: calc(var(--bottom-nav-total) + 12px) !important;
        padding-right: 72px !important;
    }

    .progress-container {
        bottom: var(--bottom-nav-total) !important;
}

/* Garantir visibilidade consistente da linha do tempo sobre qualquer vídeo */
.progress-track {
    background: rgba(255, 255, 255, 0.35) !important;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.85) !important;
    }
}

/* =============================================
   MOBILE: Ajustes finos responsivos
   ============================================= */
@media (max-width: 768px) {
    .action-buttons {
        bottom: calc(var(--bottom-nav-total) + 65px) !important;
    }
}

@media (max-width: 480px) {
    .action-buttons {
        bottom: calc(var(--bottom-nav-total) + 50px) !important;
    }
}


/* =============================================
   ADAPTAÇÃO UNIVERSAL PARA PÁGINAS COM SCROLL
   ============================================= */
body:not(.video-feed-page):not(.tiktok-body):not(.splash-active) {
    padding-bottom: calc(var(--bottom-nav-total) + 20px) !important;
}

body.video-feed-page,
body.tiktok-body {
    height: 100vh !important;
    height: 100dvh !important;
    overflow: hidden !important;
    padding-bottom: 0 !important;
}

/* No chat, quando uma conversa está aberta no mobile, esconder a barra inferior para dar espaço ao teclado */
@media (max-width: 768px) {
    body.in-conversation .bottom-nav,
    .chat-sidebar.hidden ~ .bottom-nav,
    .chat-sidebar.hidden + .bottom-nav {
    font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
        display: none !important;
    }
}

/* =============================================
   CONTROLO DE ÁUDIO — OPÇÃO 3 (MINIMALISMO TOTAL)
   ============================================= */

/* No Mobile: Sem botão flutuante permanente, áudio controlado pelo volume do telemóvel */
@media (max-width: 768px) {
    .video-controls,
    .audio-toggle {
        display: none !important;
    }
}

/* No Desktop: O botão surge no canto superior direito apenas em hover */
@media (min-width: 769px) {
    .video-controls {
        position: absolute !important;
        top: 15px !important;
        right: 15px !important;
        left: auto !important;
        z-index: 20 !important;
    }

    .audio-toggle {
        opacity: 0 !important;
        transform: scale(0.85) !important;
        pointer-events: none !important;
        transition: opacity 0.25s ease, transform 0.25s ease, background 0.2s ease !important;
    }

    .video-player:hover .audio-toggle {
        opacity: 1 !important;
        transform: scale(1) !important;
        pointer-events: auto !important;
    }
}


/* ================================================================
   MODAL DE PESQUISA UNIVERSAL
   Carregado aqui porque o bottom_nav.css está em todas as páginas
   ================================================================ */

.search-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.95);
    z-index: 10000;
    display: none;
    flex-direction: column;
}

.search-modal.active {
    display: flex;
}

.search-modal-content {
    width: 100%;
    max-width: 600px;
    margin: 0 auto;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.search-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: #111;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.search-input-wrapper {
    flex: 1;
    display: flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 0 12px;
    gap: 10px;
}

.search-input-wrapper .search-icon {
    color: rgba(255, 255, 255, 0.5);
    font-size: 14px;
}

.search-input-wrapper input {
    flex: 1;
    background: transparent;
    border: none;
    outline: none;
    color: white;
    font-size: 15px;
    padding: 10px 0;
}

.search-input-wrapper input::placeholder {
    color: rgba(255, 255, 255, 0.4);
}

.search-clear {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
}

.search-cancel {
    background: transparent;
    border: none;
    color: white;
    font-size: 14px;
    cursor: pointer;
    padding: 8px;
    white-space: nowrap;
}

.search-cancel:hover {
    opacity: 0.8;
}

.search-results {
    flex: 1;
    overflow-y: auto;
    padding: 16px;
}

.search-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 200px;
    color: rgba(255, 255, 255, 0.4);
    gap: 12px;
}

.search-placeholder i {
    font-size: 48px;
}

.search-placeholder p {
    font-size: 14px;
}

/* Resultados da pesquisa */
.search-section {
    margin-bottom: 24px;
}

.search-section-title {
    font-size: 12px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.5);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 12px;
    padding-left: 4px;
}

.search-result-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.2s;
}

.search-result-item:hover {
    background: rgba(255, 255, 255, 0.1);
}

.search-result-hashtag {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    padding: 10px;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.2s;
}

.search-result-hashtag:hover {
    background: rgba(255, 255, 255, 0.1);
}

.search-result-hashtag-name {
    font-size: 14px;
    font-weight: 600;
    color: #dbeafe;
}

.search-result-hashtag-meta {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.55);
}

.search-result-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    object-fit: cover;
}

.search-result-info {
    flex: 1;
    min-width: 0;
}

.search-result-name {
    font-weight: 600;
    font-size: 14px;
    color: white;
    display: flex;
    align-items: center;
    gap: 5px;
}

.search-result-meta {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.5);
    margin-top: 2px;
}

.search-result-video {
    display: flex;
    gap: 12px;
    padding: 10px;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.2s;
}

.search-result-video:hover {
    background: rgba(255, 255, 255, 0.1);
}

.search-result-thumbnail {
    width: 80px;
    height: 100px;
    border-radius: 6px;
    object-fit: cover;
    background: #222;
}

.search-result-video-info {
    flex: 1;
    min-width: 0;
}

.search-result-video-title {
    font-weight: 600;
    font-size: 14px;
    color: white;
    margin-bottom: 4px;
    display: -webkit-box;
    line-clamp: 2;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.search-result-video-author {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.6);
    margin-bottom: 4px;
}

.search-result-video-stats {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.4);
}

.search-loading {
    display: flex;
    justify-content: center;
    padding: 40px;
}

.search-no-results {
    text-align: center;
    padding: 40px;
    color: rgba(255, 255, 255, 0.5);
}

.search-no-results i {
    font-size: 48px;
    margin-bottom: 12px;
    display: block;
}

/* ========== HISTÓRICO DE PESQUISA ========== */
.search-history-container {
    animation: fadeInHistory 0.2s ease-out;
}

@keyframes fadeInHistory {
    from { opacity: 0; transform: translateY(6px); }
    to   { opacity: 1; transform: translateY(0); }
}

.search-history-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 8px;
    padding: 0 4px;
}

.search-history-label {
    font-size: 12px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.45);
    text-transform: uppercase;
    letter-spacing: 0.6px;
}

.search-history-clear-all {
    background: transparent;
    border: none;
    color: #60a5fa;
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    padding: 4px 8px;
    border-radius: 6px;
    transition: background 0.18s, color 0.18s;
}

.search-history-clear-all:hover {
    background: rgba(96, 165, 250, 0.12);
    color: #93c5fd;
}

.search-history-list {
    display: flex;
    flex-direction: column;
    gap: 2px;
    margin-bottom: 24px;
}

.search-history-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px;
    border-radius: 10px;
    cursor: pointer;
    transition: background 0.18s;
    position: relative;
    animation: slideInHistoryItem 0.18s ease-out both;
}

@keyframes slideInHistoryItem {
    from { opacity: 0; transform: translateX(-8px); }
    to   { opacity: 1; transform: translateX(0); }
}

.search-history-item:nth-child(1) { animation-delay: 0ms; }
.search-history-item:nth-child(2) { animation-delay: 30ms; }
.search-history-item:nth-child(3) { animation-delay: 60ms; }
.search-history-item:nth-child(4) { animation-delay: 90ms; }
.search-history-item:nth-child(5) { animation-delay: 120ms; }
.search-history-item:nth-child(6) { animation-delay: 150ms; }
.search-history-item:nth-child(7) { animation-delay: 180ms; }
.search-history-item:nth-child(8) { animation-delay: 210ms; }

.search-history-item:hover {
    background: rgba(255, 255, 255, 0.07);
}

.search-history-item:active {
    background: rgba(255, 255, 255, 0.12);
}

.search-history-icon {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.07);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: rgba(255, 255, 255, 0.4);
    font-size: 14px;
    transition: background 0.18s, color 0.18s;
}

.search-history-item:hover .search-history-icon {
    background: rgba(96, 165, 250, 0.15);
    color: #60a5fa;
}

.search-history-text {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.search-history-query {
    font-size: 14px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.9);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.search-history-time {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.3);
}

.search-history-remove {
    background: transparent;
    border: none;
    color: rgba(255, 255, 255, 0.25);
    font-size: 12px;
    cursor: pointer;
    padding: 6px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    opacity: 0;
    transition: opacity 0.15s, background 0.18s, color 0.18s;
}

.search-history-item:hover .search-history-remove {
    opacity: 1;
}

.search-history-remove:hover {
    background: rgba(239, 68, 68, 0.15);
    color: #f87171;
}

.search-history-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 48px 20px;
    color: rgba(255, 255, 255, 0.3);
    gap: 10px;
    text-align: center;
}

.search-history-empty i {
    font-size: 40px;
    opacity: 0.4;
}

.search-history-empty p {
    font-size: 13px;
    margin: 0;
}

@media (max-width: 768px) {
    .search-modal-content {
        max-width: 100%;
    }

    .search-header {
        padding: 10px 12px;
    }

    .search-history-remove {
        opacity: 1;
    }
}
