/* GLOBAL SETTINGS */
* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { width: 100%; height: 100%; font-family: 'Tajawal', sans-serif; display: flex; flex-direction: column; overflow: hidden; background-color: #ffffff; }

/* MODAL */
.modal-overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0, 0, 0, 0.9); display: none; align-items: center; justify-content: center; z-index: 1000; }
.modal-content { background: white; padding: 25px; border-radius: 20px; width: 90%; max-width: 450px; text-align: center; border: 2px solid #c5a059; }
.modal-divider { margin: 15px 0; border: 0; border-top: 1px solid #ddd; }
.full-width-btn { width: 100%; margin-top: 20px; padding: 12px; border-radius: 10px; font-weight: bold; cursor: pointer; border: none; }

/* HEADER - GOLD TITLE */
.top-bar { background-color: #004d26; border-bottom: 2px solid #c5a059; padding: 15px; display: flex; flex-direction: column; align-items: center; flex-shrink: 0; }
#app-title { color: #c5a059; font-size: 1.3rem; margin-bottom: 12px; font-weight: 700; }
.header-nav { display: flex; width: 100%; max-width: 480px; gap: 10px; }
.nav-btn { flex: 1; height: 45px; border-radius: 8px; font-weight: bold; border: 2px solid #c5a059; color: white; background: transparent; display: flex; align-items: center; justify-content: center; text-decoration: none; }
.gold-fill { background-color: #c5a059 !important; color: #004d26 !important; }

/* CHAT BUBBLES */
#chat-window { flex: 1; overflow-y: auto; padding: 20px; background: #f4f4f4; display: flex; flex-direction: column; gap: 15px; }
.message { max-width: 85%; padding: 12px 16px; border-radius: 18px; font-size: 15px; line-height: 1.5; }
.user { align-self: flex-start; background: #004d26; color: white; border-bottom-left-radius: 4px; }
.assistant { align-self: flex-end; background: white; color: #333; border: 1.5px solid #c5a059; border-bottom-right-radius: 4px; }

/* TYPING INDICATOR */
.typing { display: flex; gap: 4px; padding: 12px; background: white; border: 1.5px solid #c5a059; border-radius: 18px; width: fit-content; align-self: flex-end; }
.dot { width: 8px; height: 8px; background: #c5a059; border-radius: 50%; animation: bounce 1.4s infinite; }
@keyframes bounce { 0%, 80%, 100% { transform: scale(0); } 40% { transform: scale(1.0); } }

/* FOOTER - GOLD DISCLAIMER */
.bottom-bar { background-color: #004d26; border-top: 2px solid #c5a059; padding: 12px 10px; flex-shrink: 0; }
.prompt-container { display: flex; align-items: center; justify-content: space-between; gap: 10px; max-width: 800px; margin: 0 auto; }
.input-wrapper { flex: 1; background: white; border-radius: 25px; padding: 0 15px; }
#user-input { width: 100%; height: 48px; border: none; outline: none; font-size: 16px; }
.pill-btn { height: 48px; min-width: 85px; border-radius: 25px; font-weight: bold; cursor: pointer; border: none; display: flex; align-items: center; justify-content: center; }
.gold-outline { background: transparent; border: 2px solid #c5a059; color: #c5a059; }
.disclaimer-footer { text-align: center; font-size: 10px; color: #c5a059; margin-top: 8px; font-weight: bold; }

/* RTL/LTR FIX */
html[dir="ltr"] .user { align-self: flex-end; }
html[dir="ltr"] .assistant { align-self: flex-start; }