/* General Reset */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

h3 {
  font-size: 24px !important;
}

/* Grid Layouts */
.grid-3-columns,
.grid-4-columns,
.grid-1-column {
  display: grid;
  gap: 20px;
  margin-bottom: 20px;
}

.grid-3-columns {
  grid-template-columns: repeat(3, 1fr);
}

.grid-4-columns {
  grid-template-columns: repeat(4, 1fr);
  border-top: solid 1px black;
  border-bottom: solid 1px black;
}

.grid-1-column {
  grid-template-columns: 1fr;
  border-top: solid 1px black;
  border-bottom: solid 1px black;
}

/* Add borders between columns */
.grid-3-columns article:not(:last-child),
.grid-4-columns article:not(:last-child),
.grid-3-columns-uj article:not(:last-child) {
  border-right: 1px solid black; /* Black divider between columns */
  padding-right: 20px;
}

.grid-3-columns article {
  padding-left: 20px;
}

.grid-4-columns article {
  padding-left: 20px;
}

.giphy-embed {
  pointer-events: none; /* Disables interactions with the iframe */
}

/* Override any hover effect applied globally */
.giphy-embed:hover {
  transform: none;
  transition: none;
}
body {
  font-family: "Inter", sans-serif;
  background-color: rgb(255, 255, 255);
  color: #083f62;
  overflow-x: hidden;
}
p {
  font-size: small;
}
/* Navbar */
.navbar {
  background-color: #0092bc;
  padding: 20px 20px;
}
.navbar-bottom {
  display: flex;
  justify-content: center; /* This centers the content horizontally */
  padding: 10px 0;
  font-size: 30px;
  position: sticky; /* Make the navbar sticky */
  top: 0; /* Stick the navbar to the top when scrolling */
  z-index: 50; /* Ensure it stays on top of other content */
  background-color: #0092bc; /* Ensure background color stays during scrolling */
}

.navbar-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
}
.navbar-right {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 20px; /* Space between icons */
}

.navbar-right a img {
  width: 60px;
  height: 60px;
  margin-left: 10px;
}

.navbar-left {
  flex-grow: 1;
}
.nav-menu {
  display: flex;
  gap: 20px;
  text-align: center;
}

.nav-link {
  padding: 10px 20px;
  text-decoration: none;
  display: inline-block;
}

/* Style the divider between the buttons */
.divider {
  display: inline-block;
  width: 1px; /* Vertical line width */
  height: 50px; /* Height of the divider */
  background-color: #000000; /* Divider color */
  margin: 0 15px; /* Space around the divider */
}

.white {
  color: white;
}

.green {
  color: #2bff00;
}
.blue {
  color: #1010f7;
}

/* Grid Layouts for Different Sections */
.grid-3-columns,
.grid-4-columns,
.grid-1-column {
  display: grid;
  gap: 20px;
  margin: 20px;
}

.grid-3-columns {
  grid-template-columns: repeat(3, 1fr); /* 3 equal columns */
}

.grid-4-columns {
  grid-template-columns: repeat(4, 1fr); /* 4 equal columns */
}

.grid-1-column {
  grid-template-columns: 1fr; /* 1 full-width column */
}

article {
  background-color: #ffffff;
  padding: 20px;
}

/* Footer */
footer {
  background-color: #0092bc;
  color: white;
  padding: 15px;
  text-align: center;
  margin-top: 40px;
}

/* Responsive Design */
@media (max-width: 768px) {
  .grid-3-columns,
  .grid-4-columns,
  .grid-1-column {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 1024px) {
  .grid-3-columns-uj {
    grid-template-columns: 1fr 1fr; /* Two columns, first is full width, second splits */
  }

  .grid-3-columns-uj article:nth-child(1) {
    grid-column: span 1; /* First article spans across two columns */
  }
}

/* Ticker container styling */
.ticker-container {
  width: 100%;
  overflow: hidden;
  padding: 10px 0;
  box-sizing: border-box;
  white-space: nowrap;
  position: relative;
}

/* Ticker movement */
.ticker {
  display: inline-block;
  white-space: nowrap;
  animation: ticker-move 20s linear infinite;
}

.ticker-item {
  display: inline-block;
  background-color: #0092bc;
  border: 1px solid #222;
  padding: 10px 20px;
  margin-right: 5px;
  color: white;
  font-family: "Inter", sans-serif;
  min-width: 200px;
  text-align: center;
}

.company-name {
  font-weight: bold;
  margin-right: 10px;
}

.up {
  color: #00ff00;
}

.down {
  color: #ff0000;
}

/* Animation - Adjusted to ensure smoother, faster start */
@keyframes ticker-move {
  0% {
    transform: translateX(100%);
  }
  100% {
    transform: translateX(-100%);
  }
}

/* Faster animation for mobile devices */
@media (max-width: 768px) {
  .ticker {
    animation: ticker-move 20s linear infinite; /* Faster on mobile */
  }
  .navbar-top {
    display: flex;
    flex-direction: column; /* Stack elements vertically */
    justify-content: center;
    align-items: center;
    text-align: center;
  }

  .navbar-left {
    margin-bottom: 15px; /* Adds space between title and icons */
  }

  .navbar-left h1 {
    font-size: 28px; /* Larger title for mobile view */
    font-weight: bold;
    color: white;
    text-transform: uppercase;
  }

  .navbar-right {
    display: flex;
    justify-content: center; /* Center the icons */
    flex-wrap: wrap; /* Wrap icons if there are too many */
    gap: 10px; /* Space between icons */
  }

  .navbar-right a img {
    width: 50px; /* Larger icons on mobile view */
    height: 50px;
  }
  .nav-link {
    padding: 10px 0px;
    text-decoration: none;
    display: inline-block;
  }
  .nav-menu {
    gap: 0px;
    font-size: 24px;
  }
}

.grid-3-columns-uj {
  display: grid;
  grid-template-columns: 50% 25% 25%;
}

/* Responsive Layout for Small Screens (Mobiles) */
@media (max-width: 768px) {
  .navbar {
    background-color: #0092bc;
    padding: 20px 20px;
  }
  .grid-3-columns-uj {
    grid-template-columns: 1fr; /* Single column for all articles */
  }
}

@media (max-width: 768px) {
  /* Adjust animation speed for mobile */
  .ticker {
    animation: ticker-move-mobile 15s linear infinite;
  }

  @keyframes ticker-move-mobile {
    0% {
      transform: translateX(
        100vw
      ); /* Start from the edge of the mobile viewport */
    }
    100% {
      transform: translateX(-100%); /* Move to the left off-screen */
    }
  }
  .imglogo {
    width: 100px !important;
    padding-top: 0px !important;
  }
  .disclaimer {
    font-size: 0.3em !important; /* Smaller font size for mobile */
    padding: 8px 0; /* Adjust padding as needed */
  }
}

/* Desktop view adjustments */
@media (min-width: 769px) {
  .navbar-top {
    display: flex;
    justify-content: center; /* Center everything in the navbar */
    align-items: center;
    position: relative;
  }

  .navbar-left {
    position: absolute;
    left: 20px; /* Keep the title on the left */
  }

  .navbar-right {
    display: flex;
    justify-content: center; /* Keep the icons centered */
  }
}
