/* ============================================================
   TRADUCTION.CSS — PRO V4.3
   Mise en page premium + compatibilité clavier horizontal
============================================================ */

/* ============================================================
   1) PAGE — Structure générale
============================================================ */

#translateBox {
    width: 100%;
    min-height: 160px;
    padding: 14px;
    margin-bottom: 20px;

    background: rgba(255,255,255,0.12);
    border: 1px solid rgba(255,255,255,0.25);
    border-radius: 14px;
    backdrop-filter: blur(12px);

    font-size: 24px;
    color: #fff;
    font-family: "Nohadra", "Assyrian", sans-serif;

    resize: none;
}

/* Direction automatique */
#translateBox.rtl {
    direction: rtl;
    text-align: right;
}

#translateBox.ltr {
    direction: ltr;
    text-align: left;
}

/* ============================================================
   2) BOUTONS — Traduire / Effacer / Lire / Stop / Micro
============================================================ */

.action-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: center;
    margin-bottom: 20px;
}

.action-buttons button {
    background: rgba(255,255,255,0.12);
    border: 1px solid rgba(255,255,255,0.25);
    border-radius: 12px;

    padding: 10px 18px;
    font-size: 18px;
    color: #fff;
    cursor: pointer;
    transition: 0.25s ease;
}

.action-buttons button:hover {
    background: rgba(255,255,255,0.25);
    transform: translateY(-3px);
}

.action-buttons button:active {
    transform: scale(0.92);
}

/* ============================================================
   3) CLAVIER SOURETH — Horizontal PRO V4.3
============================================================ */

#soureth-keyboard {
    margin-top: 20px;
}

/* Le layout horizontal est géré par keyboard.css PRO V4.3 */

/* ============================================================
   4) AUTO-TRADUCTION + HISTORIQUE
============================================================ */

#autoToggleBtn {
    background: rgba(255,255,255,0.12);
    border: 1px solid rgba(255,255,255,0.25);
    border-radius: 10px;
    padding: 8px 14px;
    color: #fff;
    cursor: pointer;
    transition: 0.25s ease;
}

#autoToggleBtn:hover {
    background: rgba(255,255,255,0.25);
}

#history {
    margin-top: 20px;
    padding: 10px;
    background: rgba(255,255,255,0.08);
    border-radius: 12px;
    max-height: 260px;
    overflow-y: auto;
}

.history-item {
    background: rgba(255,255,255,0.12);
    padding: 10px;
    border-radius: 10px;
    margin-bottom: 10px;
    color: #fff;
}

.history-item small {
    opacity: 0.7;
}

/* ============================================================
   5) FIX — Empêche style.css de casser la mise en page
============================================================ */

#translateBox,
.action-buttons button {
    order: initial !important;
}
