/* Chat Widget Styles */
.chat-widget {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 1000;
}
.video-responsive {
  position: relative;
  padding-bottom: 56.25%; /* 16:9 */
  padding-top: 25px;
  height: 0;
}

.video-responsive iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}
/* Estilo para modo embebido */
.chat-widget.embed {
    position: static !important;
    width: 100%;
    max-width: 100%;
    margin: 2rem 0;
}

.chat-widget.embed .chat-window {
    position: static !important;
    box-shadow: none;
    width: 100% !important;
    height: 70vh !important;
    max-width: 100%;
    border-radius: 12px;
    overflow: hidden;
}

/* Oculta el botón de cerrar solo en modo embed */
.chat-widget.embed .close-button {
    display: none !important;
}

/* Botón flotante */
.chat-button {
    width: 60px;
    height: 60px;
    border-radius: 50%!important;
    background-color: transparent!important;
    border: none;
    color: white;
    font-size: 24px;
    cursor: pointer;
     /*box-shadow: 0 4px 20px rgba(132, 189, 0, 0.4);*/
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
	padding:0!important;
}

.chat-button:hover {
    transform: scale(1.1);
    /*box-shadow: 0 6px 30px rgba(132, 189, 0, 0.6);*/
    background-color: transparent!important;
}

/* Ventana de chat */
.chat-window {
    position: absolute;
    bottom: 80px;
    right: 0;
    width: 350px;
    height: 450px;
    background: #FFFFFF;
    border-radius: 16px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    display: none;
    flex-direction: column;
    overflow: hidden;
    animation: slideUp 0.3s ease-out;
}

.chat-window.show {
    display: flex;
}
.chat-info{
	padding: 10px 24px;
}
.chat-info p{
	font-size:10px;
}
@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Encabezado */
.chat-header {
    background-color: #84BD00; /* Verde primario */
    color: white;
    padding: 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.chat-title {
    font-weight: 600;
    font-size: 18px;
}

.close-button {
    background: none;
    border: none;
    color: white;
    font-size: 20px;
    cursor: pointer;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.2s;
}

.close-button:hover {
    background-color: rgba(255, 255, 255, 0.2);
}

/* Área de mensajes */
.chat-messages {
    flex: 1;
    padding: 16px;
    overflow-y: auto;
    background: #F9F9F9;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.message {
    max-width: 80%;
    padding: 12px 16px;
    border-radius: 18px;
    font-size: 14px;
    line-height: 1.4;
    word-wrap: break-word;
	text-align: left;
}

.message.user {
    background-color: #84BD00;
    color: white;
    align-self: flex-end;
    border-bottom-right-radius: 6px;
}

.message.bot {
    background: #FFFFFF;
    color: #24272A;
    align-self: flex-start;
    border: 1px solid #E5E7EB;
    border-bottom-left-radius: 6px;
}

/* Markdown styles */
.message.bot p {
    margin: 0.5em 0;
}
.message.bot p:first-child {
    margin-top: 0;
}
.message.bot p:last-child {
    margin-bottom: 0;
}
.message.bot strong {
    font-weight: 600;
}
.message.bot em {
    font-style: italic;
}
.message.bot ul,
.message.bot ol {
    margin: 0.5em 0;
    padding-left: 1.5em;
}
.message.bot li {
    margin: 0.25em 0;
}
.message.bot code {
    background: #F3F4F6;
    padding: 0.125em 0.25em;
    border-radius: 4px;
    font-size: 0.9em;
    font-family: monospace;
}
.message.bot pre {
    background: #F3F4F6;
    padding: 0.75em;
    border-radius: 8px;
    overflow-x: auto;
    margin: 0.5em 0;
}
.message.bot pre code {
    background: none;
    padding: 0;
}
.message.bot a {
    color: #FF4D00; /* Secundario */
    text-decoration: underline;
}
.message.bot blockquote {
    border-left: 3px solid #F2A900; /* Acento institucional */
    padding-left: 1em;
    margin: 0.5em 0;
    color: #555A5C;
}

/* Indicador de escritura */
.typing-indicator {
    display: none;
    align-self: flex-start;
    background: #FFFFFF;
    border: 1px solid #E5E7EB;
    padding: 12px 16px;
    border-radius: 18px;
    border-bottom-left-radius: 6px;
}

.typing-indicator.show {
    display: block;
}

.typing-dots {
    display: flex;
    gap: 4px;
}

.typing-dots span {
    width: 8px;
    height: 8px;
    background: #555A5C;
    border-radius: 50%;
    animation: typing 1.5s infinite;
}

.typing-dots span:nth-child(2) {
    animation-delay: 0.2s;
}
.typing-dots span:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes typing {
    0%, 60%, 100% {
        transform: translateY(0);
        opacity: 0.4;
    }
    30% {
        transform: translateY(-10px);
        opacity: 1;
    }
}

/* Área de entrada */
.chat-input {
    padding: 16px;
    background: #FFFFFF;
    border-top: 1px solid #E5E7EB;
    display: flex;
    gap: 8px;
}

.input-field {
    flex: 1;
    padding: 12px 16px;
    border: 1px solid #D1D5DB;
    border-radius: 24px;
    font-size: 14px;
    outline: none;
    transition: border-color 0.2s;
    color: #24272A;
    background-color: #F9F9F9;
}

.input-field:focus {
    border-color: #84BD00;
    background-color: #FFFFFF;
}

/* Botón de enviar */
.send-button {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background-color: #F2A900; /* Acento */
    border: none;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.send-button:hover:not(:disabled) {
    transform: scale(1.05);
}

.send-button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Mobile responsive */
@media (max-width: 480px) {
    .chat-widget {
        bottom: 15px;
        right: 15px;
    }

    .chat-window {
        width: calc(100vw - 30px);
        height: 70vh;
        bottom: 90px;
        right: -15px;
    }
}

/* Estilo login-content */
.chat-widget .login-content {
    padding: 24px;
    background-color: #FFFFFF;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(36, 39, 42, 0.05);
    font-family: "Inter", sans-serif;
    color: #24272A;
    text-align: left;
}

.chat-widget .login-content h3 {
    font-size: 20px;
    color: #24272A;
    font-weight: 600;
    margin-bottom: 12px;
}

.chat-widget .login-content p {
    font-size: 14px;
    color: #555A5C;
    margin-bottom: 16px;
    line-height: 1.6;
}

.chat-widget .login-content input.input-field {
    margin-bottom: 12px;
    border: 1px solid #F2A900;
    background-color: #F9F9F9;
    border-radius: 8px;
    padding: 12px 16px;
    font-size: 14px;
    width: 100%;
    color: #24272A;
    transition: border-color 0.2s ease, background-color 0.2s;
}

.chat-widget .login-content input.input-field:focus {
    border-color: #84BD00;
    background-color: #FFFFFF;
    outline: none;
}

.chat-widget .login-content .login-button {
    padding: 14px;
    border: none;
    border-radius: 8px;
    background-color: #84BD00; /* Verde primario */
    color: #FFFFFF;
    font-weight: 600;
    font-size: 15px;
    cursor: pointer;
    transition: background 0.2s, transform 0.1s ease-in-out;
    width: 100%;
}
.input-error {
    color: #FF4D00;
    font-size: 12px;
    margin-top: 4px;
}

.faq-accordion details {
  margin-bottom: 10px;
  border: 1px solid #ccc;
  padding: 8px;
  border-radius: 4px;
}
.faq-accordion summary {
  font-weight: bold;
  cursor: pointer;
}