/* ========================================
   AIGIRI NANDINI - STOCK MARKET PAGE STYLES
   Live Dashboard with Real-time Data Display
   ======================================== */

/* CSS VARIABLES */
:root {
  --bg: #0a0e17;
  --card: #0f172a;
  --accent: #00d4aa;
  --accent-light: #00ffcc;
  --red: #ef4444;
  --green: #10b981;
  --gold: #f59e0b;
  --purple: #8b5cf6;
  --max-w: 1400px;
  font-family: 'Inter', system-ui, -apple-system, "Segoe UI", Roboto, 'Helvetica Neue', Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  padding: 0;
  background: linear-gradient(180deg, var(--bg), #05070d);
  color: #e6efe9;
}

.container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 16px 20px;
}

/* ========================================
   HERO BANNER
   ======================================== */
.image-banner {
  position: relative;
  width: 100%;
  height: 70vh;
  min-height: 450px;
  max-height: 700px;
  margin-bottom: 50px;
  overflow: hidden;
  border-radius: 0;
  box-shadow: 0 20px 60px rgba(0,0,0,0.6);
}

.banner-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  filter: brightness(0.5) blur(0.5px);
  transition: transform 0.5s ease;
}

.image-banner:hover .banner-image {
  transform: scale(1.02);
}

.video-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(0,0,0,0.7), rgba(0,212,170,0.2), rgba(0,0,0,0.8));
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 0 20px;
  z-index: 2;
}

.video-title {
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  font-weight: 900;
  color: #fff;
  text-shadow: 0 4px 20px rgba(0,0,0,0.9);
  margin-bottom: 20px;
  animation: fadeInUp 1s ease-out;
  line-height: 1.1;
}

.video-subtitle {
  font-size: clamp(1rem, 2.5vw, 1.5rem);
  color: rgba(255,255,255,0.95);
  font-weight: 400;
  max-width: 750px;
  margin-bottom: 35px;
  animation: fadeInUp 1s ease-out 0.2s both;
  line-height: 1.5;
}

.cta-buttons {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  justify-content: center;
  animation: fadeInUp 1s ease-out 0.4s both;
}

.btn-primary,
.btn-secondary {
  padding: 18px 36px;
  font-weight: 700;
  text-decoration: none;
  border-radius: 14px;
  font-size: 16px;
  transition: all 0.3s ease;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 58px;
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent), var(--accent-light));
  color: #03110a;
  box-shadow: 0 10px 30px rgba(0,212,170,0.4);
}

.btn-primary:hover {
  transform: translateY(-4px);
  box-shadow: 0 15px 40px rgba(0,212,170,0.6);
}

.btn-secondary {
  background: rgba(255,255,255,0.1);
  color: #fff;
  border: 2px solid rgba(255,255,255,0.3);
  backdrop-filter: blur(15px);
}

.btn-secondary:hover {
  background: rgba(255,255,255,0.2);
  border-color: rgba(255,255,255,0.5);
  transform: translateY(-4px);
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(40px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ========================================
   LIVE TICKERS
   ======================================== */
.live-tickers {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 30px;
  margin-bottom: 70px;
}

.ticker-section {
  background: rgba(15, 23, 42, 0.95);
  backdrop-filter: blur(25px);
  border: 1px solid rgba(0,212,170,0.2);
  border-radius: 24px;
  padding: 28px;
  overflow: hidden;
  box-shadow: 0 15px 40px rgba(0,0,0,0.4);
}

.ticker-title {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--accent);
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.ticker-emoji {
  font-size: 1.6rem;
}

.ticker-wrapper {
  display: flex;
  animation: tickerScroll 40s linear infinite;
  height: 70px;
  align-items: center;
}

.ticker-wrapper:hover {
  animation-play-state: paused;
}

.ticker-content {
  display: flex;
  align-items: center;
}

.ticker-item {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 0 35px;
  white-space: nowrap;
}

.stock-logo {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  object-fit: cover;
  flex-shrink: 0;
  box-shadow: 0 4px 12px rgba(0,0,0,0.3);
}

.stock-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  flex-shrink: 0;
  box-shadow: 0 4px 12px rgba(0,0,0,0.3);
}

.gold-icon {
  background: linear-gradient(135deg, var(--gold), #fbbf24);
}

.red-icon {
  background: linear-gradient(135deg, var(--red), #f87171);
}

.green-icon {
  background: linear-gradient(135deg, var(--green), #34d399);
}

.stock-name {
  font-weight: 600;
  color: #fff;
  min-width: 90px;
  font-size: 0.95rem;
}

.stock-price {
  font-size: 1.7rem;
  font-weight: 800;
  min-width: 110px;
  color: #fff;
}

.stock-change {
  padding: 6px 14px;
  border-radius: 18px;
  font-weight: 600;
  font-size: 0.9rem;
}

.change-up {
  background: rgba(16,185,129,0.2);
  color: var(--green);
  border: 1px solid rgba(16,185,129,0.3);
}

.change-down {
  background: rgba(239,68,68,0.2);
  color: var(--red);
  border: 1px solid rgba(239,68,68,0.3);
}

@keyframes tickerScroll {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(-50%);
  }
}

/* ========================================
   MARKET INDICES
   ======================================== */
.section-title-main {
  text-align: center;
  font-size: clamp(2.2rem, 5vw, 3.5rem);
  margin-bottom: 50px;
  background: linear-gradient(135deg, #fff, var(--accent));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-weight: 800;
}

.market-indices {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 28px;
  margin-bottom: 70px;
}

.index-card {
  background: rgba(255,255,255,0.05);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 24px;
  padding: 36px 28px;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  cursor: pointer;
  position: relative;
  overflow: hidden;
}

.index-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 50% 50%, rgba(0,212,170,0.1), transparent);
  opacity: 0;
  transition: opacity 0.4s ease;
}

.index-card:hover::before {
  opacity: 1;
}

.index-card:hover {
  transform: translateY(-12px);
  box-shadow: 0 30px 70px rgba(0,212,170,0.3);
  border-color: var(--accent);
}

.index-header {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 20px;
}

.index-icon {
  font-size: 2.8rem;
  width: 54px;
  height: 54px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 20px rgba(0,0,0,0.3);
}

.gold-bg {
  background: linear-gradient(135deg, var(--gold), #fbbf24);
}

.purple-bg {
  background: linear-gradient(135deg, var(--purple), #c084fc);
}

.red-bg {
  background: linear-gradient(135deg, var(--red), #f87171);
}

.amber-bg {
  background: linear-gradient(135deg, var(--gold), #fbbf24);
}

.index-name {
  font-size: 1.3rem;
  font-weight: 700;
  color: #fff;
}

.index-value {
  font-size: clamp(2.2rem, 4vw, 3rem);
  font-weight: 900;
  color: var(--accent);
  margin-bottom: 12px;
  line-height: 1.1;
}

.index-change {
  font-size: 1.1rem;
  font-weight: 600;
  padding: 8px 16px;
  border-radius: 20px;
  display: inline-block;
}

/* ========================================
   TOP GAINERS / LOSERS
   ======================================== */
.gainers-losers {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 35px;
  margin-bottom: 70px;
}

.gainers-section,
.losers-section {
  background: rgba(15, 23, 42, 0.95);
  border-radius: 24px;
  padding: 35px;
  border: 1px solid rgba(255,255,255,0.1);
  box-shadow: 0 15px 40px rgba(0,0,0,0.4);
}

.section-title {
  font-size: 1.6rem;
  font-weight: 800;
  color: #fff;
  margin-bottom: 28px;
  display: flex;
  align-items: center;
  gap: 14px;
}

.title-badge {
  padding: 10px 14px;
  border-radius: 14px;
  font-size: 1.2rem;
}

.green-badge {
  background: linear-gradient(135deg, var(--green), #34d399);
}

.red-badge {
  background: linear-gradient(135deg, var(--red), #f87171);
}

.stock-list {
  display: flex;
  flex-direction: column;
}

.stock-row {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 18px 0;
  border-bottom: 1px solid rgba(255,255,255,0.05);
  transition: all 0.3s ease;
}

.stock-row:last-child {
  border-bottom: none;
}

.stock-row:hover {
  background: rgba(255,255,255,0.05);
  padding-left: 12px;
  border-radius: 12px;
}

.stock-symbol {
  font-weight: 700;
  color: #fff;
  min-width: 110px;
  font-size: 0.95rem;
}

.stock-price-row {
  font-size: 1.5rem;
  font-weight: 700;
  color: #fff;
  flex: 1;
}

.stock-change-row {
  padding: 8px 14px;
  border-radius: 18px;
  font-weight: 600;
  font-size: 0.95rem;
  min-width: 80px;
  text-align: center;
}

/* ========================================
   COMMODITIES & FOREX
   ======================================== */
.commodities-forex {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 28px;
  margin-bottom: 70px;
}

.cf-card {
  background: rgba(255,255,255,0.05);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 24px;
  padding: 38px 32px;
  text-align: center;
  transition: all 0.4s ease;
  position: relative;
  overflow: hidden;
}

.cf-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 50% 50%, rgba(0,212,170,0.1), transparent);
  opacity: 0;
  transition: opacity 0.4s ease;
}

.cf-card:hover::before {
  opacity: 1;
}

.cf-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 25px 60px rgba(0,212,170,0.3);
  border-color: var(--accent);
}

.cf-icon {
  font-size: 4rem;
  margin-bottom: 24px;
}

.cf-title {
  font-size: 1.5rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 20px;
}

.cf-price {
  font-size: clamp(2rem, 4vw, 2.8rem);
  font-weight: 900;
  color: var(--accent);
  margin-bottom: 16px;
  line-height: 1.1;
}

/* ========================================
   NEWS TICKER
   ======================================== */
.news-ticker {
  background: linear-gradient(90deg, rgba(0,212,170,0.1), rgba(15,23,42,0.95), rgba(0,212,170,0.1));
  padding: 32px;
  border-radius: 24px;
  margin-bottom: 70px;
  overflow: hidden;
  border: 1px solid rgba(0,212,170,0.2);
  box-shadow: 0 15px 40px rgba(0,0,0,0.4);
}

.news-wrapper {
  display: flex;
  animation: newsScroll 50s linear infinite;
}

.news-wrapper:hover {
  animation-play-state: paused;
}

.news-content {
  display: flex;
}

.news-item {
  padding: 0 50px;
  min-width: max-content;
}

.news-title {
  font-size: 1.4rem;
  font-weight: 600;
  color: var(--accent);
  margin-bottom: 10px;
}

.news-desc {
  color: #94a3b8;
  font-size: 1rem;
  line-height: 1.5;
}

@keyframes newsScroll {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(-50%);
  }
}

/* ========================================
   RESPONSIVE BREAKPOINTS
   ======================================== */

/* Tablets (≤992px) */
@media (max-width: 992px) {
  .image-banner {
    height: 65vh;
    min-height: 420px;
  }
  
  .live-tickers {
    gap: 24px;
  }
  
  .ticker-section {
    padding: 24px;
  }
  
  .stock-price {
    font-size: 1.5rem;
  }
  
  .market-indices {
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 24px;
  }
  
  .gainers-losers {
    gap: 28px;
  }
}

/* Mobile (≤768px) */
@media (max-width: 768px) {
  .container {
    padding: 16px 16px;
  }
  
  .image-banner {
    height: 55vh;
    min-height: 380px;
    margin-bottom: 40px;
  }
  
  .cta-buttons {
    flex-direction: column;
    align-items: center;
    gap: 14px;
  }
  
  .btn-primary,
  .btn-secondary {
    width: 100%;
    max-width: 300px;
    justify-content: center;
  }
  
  .live-tickers {
    grid-template-columns: 1fr;
    gap: 20px;
    margin-bottom: 50px;
  }
  
  .ticker-section {
    padding: 20px;
  }
  
  .ticker-title {
    font-size: 1.2rem;
  }
  
  .ticker-item {
    gap: 14px;
    padding: 0 25px;
  }
  
  .stock-logo,
  .stock-icon {
    width: 38px;
    height: 38px;
  }
  
  .stock-name {
    min-width: 75px;
    font-size: 0.85rem;
  }
  
  .stock-price {
    font-size: 1.3rem;
    min-width: 90px;
  }
  
  .stock-change {
    font-size: 0.8rem;
    padding: 5px 10px;
  }
  
  .market-indices {
    grid-template-columns: 1fr;
    gap: 20px;
    margin-bottom: 50px;
  }
  
  .index-card {
    padding: 30px 24px;
  }
  
  .gainers-losers {
    grid-template-columns: 1fr;
    gap: 24px;
    margin-bottom: 50px;
  }
  
  .gainers-section,
  .losers-section {
    padding: 28px 24px;
  }
  
  .stock-row {
    gap: 14px;
    padding: 14px 0;
  }
  
  .stock-symbol {
    min-width: 90px;
    font-size: 0.9rem;
  }
  
  .stock-price-row {
    font-size: 1.3rem;
  }
  
  .stock-change-row {
    font-size: 0.85rem;
    min-width: 70px;
  }
  
  .commodities-forex {
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
    margin-bottom: 50px;
  }
  
  .cf-card {
    padding: 32px 24px;
  }
  
  .cf-icon {
    font-size: 3.2rem;
  }
  
  .news-ticker {
    padding: 24px 20px;
    margin-bottom: 50px;
  }
  
  .news-item {
    padding: 0 35px;
  }
  
  .news-title {
    font-size: 1.2rem;
  }
  
  .news-desc {
    font-size: 0.9rem;
  }
}

/* Small Mobile (≤600px) */
@media (max-width: 600px) {
  .image-banner {
    height: 50vh;
    min-height: 350px;
  }
  
  .ticker-wrapper {
    height: 60px;
  }
  
  .ticker-item {
    gap: 12px;
    padding: 0 20px;
  }
  
  .stock-logo,
  .stock-icon {
    width: 34px;
    height: 34px;
  }
  
  .stock-name {
    min-width: 65px;
    font-size: 0.8rem;
  }
  
  .stock-price {
    font-size: 1.1rem;
    min-width: 75px;
  }
  
  .index-value {
    font-size: 2rem;
  }
  
  .stock-symbol {
    min-width: 80px;
  }
  
  .stock-price-row {
    font-size: 1.15rem;
  }
  
  .cf-title {
    font-size: 1.3rem;
  }
  
  .news-item {
    padding: 0 25px;
  }
}

/* Extra Small Mobile (≤480px) */
@media (max-width: 480px) {
  .image-banner {
    min-height: 320px;
  }
  
  .btn-primary,
  .btn-secondary {
    padding: 16px 28px;
    font-size: 15px;
  }
  
  .ticker-section {
    padding: 18px;
  }
  
  .ticker-title {
    font-size: 1.1rem;
  }
  
  .ticker-item {
    padding: 0 18px;
  }
  
  .index-card {
    padding: 28px 20px;
  }
  
  .index-icon {
    width: 48px;
    height: 48px;
    font-size: 2.4rem;
  }
  
  .gainers-section,
  .losers-section {
    padding: 24px 20px;
  }
  
  .cf-card {
    padding: 28px 20px;
  }
}