/* ===========================
   EMIRATES INVESTMENT BANK
   STYLE — Dark Premium Edition (Bright Text)
   =========================== */

/* GLOBAL RESET */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
}
body {
  font-family: "Poppins", sans-serif;
  color: #fff;
  background-color: #0f0f13;
  overflow-x: hidden;
}

/* COLOR VARIABLES */
.text-gold { color: #cda434 !important; }
.text-purple { color: #cda434 !important; }

.btn-gold {
  background-color: #cda434;
  color: #0f0f13;
  border: none;
  transition: all 0.3s ease;
}
.btn-gold:hover {
  background-color: #e5c65a;
  color: #000;
}

.btn-outline-gold {
  border: 2px solid #cda434;
  color: #cda434;
  background: transparent;
  transition: all 0.3s ease;
}
.btn-outline-gold:hover {
  background-color: #cda434;
  color: #0f0f13;
}

/* NAVBAR */
.navbar-white {
  background: #100422df;
  box-shadow: 0 2px 20px rgba(255,252,252,0.652);
}
.navbar .nav-link {
  color: #f8f8f8;
  font-weight: 500;
  transition: color 0.3s ease;
}
.navbar .nav-link:hover {
  color: #cda434;
}
.navbar .dropdown-menu {
  background: #1d1d27;
  border-radius: 10px;
  border: none;
  box-shadow: 0 6px 25px rgba(0,0,0,0.6);
}

@media (max-width: 991px) {
  .navbar .dropdown-menu {
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: all 0.4s ease;
  }

  .navbar .dropdown-menu.show {
    max-height: 500px; /* adjust if needed */
    opacity: 1;
  }
}


/* FIXED BOTTOM BAR */
.fixed-bottom-bar {
  background: #191922;
  border-top: 1px solid rgba(255,255,255,0.08);
  padding: 12px 0;
  position: fixed;
  bottom: 0;
  width: 100%;
  z-index: 1050;
  transition: transform 0.3s ease;
}
.fixed-bottom-bar.hidden {
  transform: translateY(100%);
}

/* HERO SECTION */
.hero-wrap {
  position: relative;
  height: 90vh;
  display: flex;
  align-items: center;
  color: #fff;
  overflow: hidden;
}
.hero-bg {
  position: absolute;
  top: 0; left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(0.80);
  z-index: 1;
}
.hero-overlay {
  position: absolute;
  top: 0; left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(180deg, rgba(0,0,0,0.6) 0%, rgba(20,20,30,0.7) 100%);
  z-index: 2;
}
.hero-content {
  position: relative;
  z-index: 3;
}

/* MID SECTION */
.mid-section {
  background: #0e031d;
  color: #fff;
}
.image-frame {
  position: relative;
  border-radius: 20px;
  overflow: hidden;
}
.image-frame img {
  width: 100%;
  border-radius: 20px;
  transition: transform 0.5s ease;
}
.image-frame:hover img {
  transform: scale(1.05);
}
.image-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom right, rgba(205,164,52,0.15), rgba(75,0,130,0.25));
}

/* CARDS SECTION */
.cards-gradient-bg {
  background: #0e031d;
}
.card {
  background: #1e1e27;
  border-radius: 15px;
  color: #fff;
  transition: all 0.3s ease;
}
.card .shine {
  position: absolute;
  top: 0;
  left: -75%;
  width: 50%;
  height: 100%;
  background: linear-gradient(120deg, transparent, rgba(255,255,255,0.15), transparent);
  transform: skewX(-25deg);
}
.card:hover .shine {
  animation: shine 1.2s forwards;
}
@keyframes shine {
  100% { left: 125%; }
}
.hover-shadow:hover {
  box-shadow: 0 12px 25px rgba(0,0,0,0.5);
}

/* SCROLLING CARDS */
.scrolling-cards {
  scrollbar-width: thin;
  scrollbar-color: #cda434 #1c1c24;
}
.scrolling-cards::-webkit-scrollbar {
  height: 8px;
}
.scrolling-cards::-webkit-scrollbar-thumb {
  background: #cda434;
  border-radius: 10px;
}

.loan-card, .trade-card {
  background: #0e031d;
  min-width: 260px;
  box-shadow: 0 5px 15px rgba(0,0,0,0.3);
  border: 1px solid rgba(255,255,255,0.05);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  color: #fff;
}
.loan-card:hover, .trade-card:hover {
   background: rgba(205, 164, 52, 0.1);
  transform: translateY(-5px);
  border-color: #cda434;
  box-shadow: 0 4px 15px rgba(205, 164, 52, 0.25);
}



/* LIVE MARKET TICKER */
.ticker-wrap {
  position: sticky;
  top: 78px; 
  width: 100%;
  overflow: hidden;
  background: #fffbea; 
  border-bottom: 2px solid #d4af37; /* gold accent */
  color: #111;
  z-index: 999;
  padding: 0.3rem 0;
}

/* Push ticker down only on mobile */
@media (max-width: 768px) {
  .ticker-wrap {
    top: 107px !important; /* moves it further down */
  }
}

.ticker {
  display: inline-block;
  white-space: nowrap;
  animation: ticker-scroll 60s linear infinite;
}

.ticker-item {
  display: inline-block;
  margin: 0 2rem;
  font-size: 0.95rem;
  font-weight: 500;
}

.price {
  font-weight: 600;
}

.change.up {
  color: #16a34a; /* green for positive */
}

.change.down {
  color: #dc2626; /* red for negative */
}

@keyframes ticker-scroll {
  0% {
    transform: translateX(0%);
  }
  100% {
    transform: translateX(-50%);
  }
}


/* --- CTA SECTION REFINEMENT --- */
.cta-section {
  background: linear-gradient(135deg, #280755, #1c0e2e);
  position: relative;
  z-index: 1;
  padding-bottom: 90px; /* adds safe space above fixed buttons */
}

/* Column headings */
.cta-section h5 {
  color: #fff;
  font-weight: 600;
  letter-spacing: 0.3px;
}

/* Footer links */
.footer-link {
  color: rgba(255, 255, 255, 0.85);
  text-decoration: none;
  display: block;
  margin-bottom: 6px;
  transition: color 0.3s ease, transform 0.2s ease;
}

.footer-link:hover {
  color: #cda434; /* gold hover */
  transform: translateX(4px);
}

/* Footer bottom text */
.cta-section .text-white-70 {
  color: rgba(255, 255, 255, 0.7);
}

/* Ensure the floating buttons don't overlap */
.fixed-buttons {
  z-index: 9999;
}

footer, .cta-section {
  padding-bottom: 120px !important; /* ensures full visibility of footer text */
}


/* ===================================================
   EMIRATES INVESTMENT BANK — LUXURY MODAL THEME
   Covers: Signup, Verification & Account Created Modals
   =================================================== */

/* === BASE MODAL STYLE (shared by all modals) === */
.luxury-modal,
.verify-modal,
.account-created-modal {
  background: rgba(162, 162, 163, 0.221);
  border: 1px solid rgba(212, 175, 55, 0.35);
  border-radius: 16px;
  color: #d4af37;
  backdrop-filter: blur(12px);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.6);
  animation: fadeInScale 0.35s ease-out;
  padding: 1rem 1.5rem;
}

/* === GOLD & TEXT === */
.text-gold {
  color: #d4af37 !important;
}

h5.text-gold,
h4.text-gold {
  letter-spacing: 0.5px;
  text-shadow: 0 0 8px rgba(212, 175, 55, 0.3);
}

/* === BUTTONS === */
.btn-gold {
  background: linear-gradient(45deg, #d4af37, #f7d774);
  color: #000;
  font-weight: 600;
  border: none;
  border-radius: 8px;
  transition: all 0.25s ease;
}

.btn-gold:hover {
  background: linear-gradient(45deg, #e1bf53, #fce089);
  transform: translateY(-1px);
  box-shadow: 0 0 10px rgba(212, 175, 55, 0.4);
}

/* === INPUTS === */
.luxury-modal .form-control,
.luxury-modal .form-select,
.verify-modal .form-control,
.verify-modal .form-select {
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  transition: all 0.25s ease;
}

.luxury-modal .form-control:focus,
.luxury-modal .form-select:focus,
.verify-modal .form-control:focus,
.verify-modal .form-select:focus {
  border-color: #d4af37;
  box-shadow: 0 0 5px #d4af37;
  background: rgba(255, 255, 255, 0.12);
  outline: none;
}

/* === PLACEHOLDERS === */
.luxury-modal ::placeholder,
.verify-modal ::placeholder {
  color: rgb(255, 255, 255);
}

/* === VERIFICATION CODE INPUTS === */
.verify-input {
  width: 48px;
  height: 52px;
  font-size: 1.4rem;
  font-weight: 600;
  text-align: center;
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 10px;
  background: rgba(162, 162, 163, 0.221);
  color: #fff;
  outline: none;
  transition: all 0.25s ease;
}

.verify-input:focus {
  border-color: #d4af37;
  box-shadow: 0 0 8px rgba(212, 175, 55, 0.5);
  background: rgba(162, 162, 163, 0.221);
}

/* === ACCOUNT CREATED MODAL === */
.account-created-modal {
  text-align: center;
  padding: 2rem 1.5rem;
}

.account-created-modal h5 {
  color: #d4af37;
  font-weight: 700;
  font-size: 1.4rem;
}

.account-created-modal p {
  color: rgba(255, 255, 255, 0.85);
}

.account-created-modal #createdAccountNumber {
  font-size: 1.7rem;
  font-weight: 700;
  color: #d4af37;
  letter-spacing: 2px;
  margin: 12px 0;
  text-shadow: 0 0 8px rgba(212, 175, 55, 0.3);
}

.account-created-modal .btn-gold {
  margin-top: 1rem;
  padding: 0.6rem 1.5rem;
  font-size: 1.05rem;
}

/* === ANIMATIONS === */
@keyframes fadeInScale {
  from {
    opacity: 0;
    transform: scale(0.9) translateY(20px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}



/* CHATBOT */
.chatbot-button {
  position: fixed;
  bottom: 90px;
  right: 20px;
  background: #4b0082;
  color: #fff;
  width: 55px;
  height: 55px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
  transition: background 0.3s ease, transform 0.2s ease;
  z-index: 2000;
}
.chatbot-button:hover {
  background: #cda434;
  transform: scale(1.1);
}

.chatbot-window {
  position: fixed;
  bottom: 150px;
  right: 20px;
  width: 320px;
  height: 400px;
  background: #191922;
  backdrop-filter: blur(12px);
  border-radius: 12px;
  box-shadow: 0 4px 25px rgba(0, 0, 0, 0.6);
  overflow: hidden;
  z-index: 2100;
  display: flex;
  flex-direction: column;
}

.chatbot-header {
  font-weight: 600;
  color: #fff;
  background: linear-gradient(90deg, #4b0082, #6f42c1);
}

.chatbot-body {
  flex: 1;
  overflow-y: auto;
  font-size: 0.9rem;
  color: #fff;
  padding: 10px;
}

/* Chat message styles */
.chatbot-body .user-msg,
.chatbot-body .bot-msg {
  margin: 5px 0;
  padding: 8px 10px;
  border-radius: 10px;
  max-width: 80%;
  word-wrap: break-word;
}

.chatbot-body .user-msg {
  background: #4b0082;
  align-self: flex-end;
  margin-left: auto;
}

.chatbot-body .bot-msg {
  background: #333;
  align-self: flex-start;
  margin-right: auto;
}

.chatbot-input {
  background: #1e1e27;
  border-top: 1px solid #333;
}

.chatbot-input input {
  font-size: 0.9rem;
  background: #1e1e27;
  color: #fff;
  border: 1px solid #333;
}

.chatbot-input button {
  width: 45px;
  border-radius: 50%;
}

/* --- Chatbot toggle animation --- */
.chatbot-window {
  opacity: 0;
  transform: translateY(40px);
  pointer-events: none;
  transition: all 0.3s ease;
}

.chatbot-window.active {
  opacity: 1;
  transform: translateY(0);
  pointer-events: aLL;
}

/* smooth toggle that plays nicely with Bootstrap's .d-none */
.chatbot-window {
  /* start hidden if d-none is present; these set the animated state */
  opacity: 0;
  transform: translateY(18px) scale(0.995);
  transition: opacity 280ms cubic-bezier(.2,.9,.3,1), transform 280ms cubic-bezier(.2,.9,.3,1);
  pointer-events: none; /* prevent interaction while "hidden" state */
}

/* visible/active state */
.chatbot-window.is-open {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}

/* when completely hidden by d-none, it won't occupy layout */
.chatbot-window.d-none {
  /* keep same behavior — d-none will set display:none!important */
}

/* small drop shadow/glow while open for polish (optional) */
.chatbot-window.is-open {
  box-shadow: 0 14px 40px rgba(16,4,34,0.55), 0 0 20px rgba(205,164,52,0.06);
  border-radius: 12px;
}


/* RESPONSIVE */
@media (max-width: 768px) {
  .hero-wrap { height: auto; padding: 120px 0 80px; text-align: center; }
  .navbar-brand { font-size: 1.2rem; }
  .fixed-bottom-bar .btn { font-size: 1rem; }
}

/* LUXURY LOAN CARDS */
.luxury-card {
  background-size: cover;
  background-position: center;
  min-width: 280px;
  height: 250px;
  display: flex;
  align-items: flex-end;
  position: relative;
  overflow: hidden;
  transition: transform 0.5s ease, box-shadow 0.4s ease;
  border: none;
  color: #fff;
}
.luxury-card .overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(75, 0, 130, 0.45) 0%, rgba(0, 0, 0, 0.85) 100%);
  transition: background 0.4s ease;
  z-index: 1;
}
.luxury-card:hover {
   background: rgba(205, 164, 52, 0.1);
  transform: translateY(-5px);
  border-color: #cda434;
  box-shadow: 0 4px 15px rgba(205, 164, 52, 0.25);
}

.luxury-card:hover .overlay {
  background: linear-gradient(180deg, rgba(75, 0, 130, 0.25) 0%, rgba(0, 0, 0, 0.7) 100%);
}
.luxury-card .position-relative {
  z-index: 2;
}

/* consistency */
.text-white-70 { color: #fff; }
.btn-signup-lg { background: linear-gradient(135deg,#4b0082,#cda434); color:#fff; border:none; border-radius:.75rem; padding:.75rem; }
.btn-signup-lg:hover { opacity:.95; transform: translateY(-2px); }

.modal-content.text-center { color:#fff; }
.btn-close-white { filter: invert(1); }
/* === BRIGHTEN LIGHT TEXT TO WHITE === */
.text-white-70,
.text-muted,
.mid-section p,
.card p,
.card small,
.loan-card p,
.trade-card p,
footer,
footer p,
footer span {
  color: #fff !important;
}

/* === MAKE CREDIT CARD SECTION TEXT WHITE === */
.luxury-card,
.luxury-card p,
.luxury-card h5,
.luxury-card h4,
.luxury-card .position-relative {
  color: #fff !important;
}

/* === Navbar Dropdown Text Fix === */
.navbar .dropdown-menu .dropdown-item {
  color: #f5f5f5 !important;  /* bright white for visibility */
  font-weight: 500;
  transition: color 0.3s ease, background 0.3s ease;
}

.navbar .dropdown-menu .dropdown-item:hover,
.navbar .dropdown-menu .dropdown-item:focus {
  color: #cda434 !important;  /* elegant gold accent */
  background-color: rgba(255, 255, 255, 0.05);  /* subtle hover background */
}

/* === MOBILE NAVBAR (Majestic Animated Version) === */
@media (max-width: 991px) {
  .mobile-nav {
    position: absolute;
    top: 70px;
    left: 0;
    width: 100%;
    background: rgba(16, 4, 34, 0.96);
    backdrop-filter: blur(8px);
    border-radius: 0 0 18px 18px;
    transform: translateY(-120%);
    transition: transform 0.6s cubic-bezier(0.23, 1, 0.32, 1.2);
    z-index: 1049;
    overflow: hidden;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.4);
  }

  .mobile-nav.active {
    transform: translateY(0);
  }

  .mobile-nav ul {
    list-style: none;
    margin: 0;
    padding: 10px 0;
  }

  .mobile-nav .nav-item {
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  }

  .mobile-nav .nav-link {
    display: block;
    color: #f8f8f8;
    padding: 12px 20px;
    text-decoration: none;
    font-size: 17px;
    font-weight: 500;
    opacity: 0;
    transform: translateY(-10px);
    animation: fadeSlideIn 0.4s ease forwards;
  }

  /* make each link animate sequentially */
  .mobile-nav.active .nav-link:nth-child(1) { animation-delay: 0.05s; }
  .mobile-nav.active .nav-link:nth-child(2) { animation-delay: 0.1s; }
  .mobile-nav.active .nav-link:nth-child(3) { animation-delay: 0.15s; }
  .mobile-nav.active .nav-link:nth-child(4) { animation-delay: 0.2s; }
  .mobile-nav.active .nav-link:nth-child(5) { animation-delay: 0.25s; }

  @keyframes fadeSlideIn {
    to {
      opacity: 1;
      transform: translateY(0);
    }
  }

  /* Dropdown animation */
  .mobile-nav .dropdown-menu {
    background: rgba(16, 4, 34, 0.96);
    border: none;
    box-shadow: inset 0 2px 15px rgba(255, 255, 255, 0.05);
    padding-left: 25px;
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transform: translateY(-15px);
    transition: all 0.6s cubic-bezier(0.23, 1, 0.32, 1.2);
  }

  .mobile-nav .dropdown-menu.active {
    max-height: 300px;
    opacity: 1;
    transform: translateY(0);
  }

  .mobile-nav .dropdown-item {
    color: #f5f5f5;
    font-weight: 500;
    padding: 8px 0;
    opacity: 0;
    transform: translateY(10px);
    transition: all 0.4s ease;
  }

  .mobile-nav .dropdown-menu.active .dropdown-item {
    opacity: 1;
    transform: translateY(0);
  }

  .mobile-nav .dropdown-item:hover {
    color: #cda434;
    background: none;
  }
}


/* --- LATEST NEWS SECTION (Refined, Modal-Safe) --- */
.latest-news-section {
  background: #0e031d;
  color: #fff;
  position: relative;
  padding: 80px 0;
  overflow: hidden;
  /* removed z-index to avoid modal blocking */
}

.latest-news-section::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: radial-gradient(circle at top right, rgba(205,164,52,0.08), transparent 60%);
  pointer-events: none; /* ensures it doesn't block clicks */
}

.latest-news-section .section-title {
  text-align: center;
  font-weight: 700;
  font-size: 2rem;
  margin-bottom: 3rem;
  color: #cda434;
  text-shadow: 0 0 8px rgba(205,164,52,0.25);
}

/* --- NEWS CARDS --- */
.news-card {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.4);
  transition: all 0.35s ease;
  cursor: pointer;
  overflow: hidden;
  position: relative;
}

.news-card:hover {
  background: rgba(205, 164, 52, 0.08);
  transform: translateY(-6px);
  border-color: #cda434;
  box-shadow: 0 10px 35px rgba(205, 164, 52, 0.25);
}

/* --- NEWS IMAGE --- */
.news-img {
  height: 220px;
  overflow: hidden;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.news-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease;
}

.news-card:hover .news-img img {
  transform: scale(1.1);
}

/* --- CONTENT --- */
.news-card .card-body {
  padding: 1.5rem;
}

.news-card h5 {
  font-size: 1.25rem;
  font-weight: 600;
  color: #fff;
  margin-bottom: 0.5rem;
}

.news-meta {
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.7);
  margin-bottom: 0.75rem;
  display: flex;
  align-items: center;
  gap: 6px;
}

.news-card p {
  color: rgba(255, 255, 255, 0.85);
  margin-bottom: 1rem;
}

/* --- READ MORE BUTTON --- */
.btn-read-more {
  background: transparent;
  border: 1px solid #cda434;
  color: #cda434;
  border-radius: 8px;
  padding: 6px 14px;
  font-size: 0.9rem;
  transition: all 0.3s ease;
}

.btn-read-more:hover {
  background: #cda434;
  color: #0f0f13;
}

/* --- RESPONSIVE --- */
@media (max-width: 768px) {
  .news-img {
    height: 180px;
  }
  .latest-news-section {
    padding: 60px 0;
  }
}

.footer-link:hover {
  color: #ffd966;
}

.footer-dropdown {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease, opacity 0.3s ease;
  opacity: 0;
  margin-top: 4px;
  font-size: 0.85rem;
}

.footer-dropdown a {
  color: #fff;
  text-decoration: underline;
}

.footer-dropdown.show {
  max-height: 50px; /* enough for one line */
  opacity: 1;
}
