* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* Z-INDEX APPROACH: Hide banner (first line) with low z-index, keep dropdown (second line) with high z-index */

/* Google Translate Banner (first line) - COMPLETELY HIDE */
body > .goog-te-banner-frame,
body > .skiptranslate {
  z-index: 1 !important;
  position: relative !important;
  pointer-events: none !important;
  height: 0 !important;
  overflow: hidden !important;
  display: none !important;
}

/* Banner iframes - completely hidden */
body > .goog-te-banner-frame iframe,
body > .skiptranslate iframe {
  z-index: 1 !important;
  pointer-events: none !important;
  display: none !important;
}

/* Top Bar (second line) - HIGH z-index to cover banner */
.top-bar {
  position: relative;
  z-index: 1000 !important;
}

/* Google Translate Element in Top Bar - HIGH z-index */
#google_translate_element {
  position: relative;
  z-index: 1001 !important;
  display: inline-block;
  pointer-events: auto !important;
}

/* Google Translate Gadget - HIGH z-index */
#google_translate_element .goog-te-gadget {
  position: relative;
  z-index: 1002 !important;
  display: inline-block !important;
  pointer-events: auto !important;
}

/* Google Translate Dropdown Anchor - HIGH z-index */
#google_translate_element .goog-te-gadget a,
#google_translate_element a.VIpgJd-ZVi9od-xl07Ob-lTBxed {
  position: relative;
  z-index: 1003 !important;
  color: #000 !important;
  cursor: pointer !important;
  pointer-events: auto !important;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  background: #ffffff;
  color: #000000;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

/* Top Black Bar */
.top-bar {
  background: #000000;
  color: #ffffff;
  font-size: 12px;
  padding: 8px 0;
  border-bottom: 1px solid #333333;
  position: relative;
  z-index: 1000 !important;
}

.top-bar-container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.top-links {
  display: flex;
  gap: 24px;
  align-items: center;
}

.top-link {
  color: #ffffff;
  text-decoration: none;
  font-size: 12px;
}

.top-link:hover {
  text-decoration: underline;
}

.top-right {
  display: flex;
  align-items: center;
  gap: 12px;
  color: #cccccc;
  font-size: 12px;
  position: relative;
  z-index: 1000;
  pointer-events: auto;
}

/* Google Translate in header - MINIMAL styling, let it work naturally */
#google_translate_element {
  display: inline-block;
  margin-right: 12px;
  position: relative;
  z-index: 1000;
  pointer-events: auto;
}

/* Google Translate uses a custom dropdown (anchor tag), not a select element */
/* Style the dropdown anchor and gadget */
#google_translate_element .goog-te-gadget,
#google_translate_element .goog-te-gadget-simple {
  display: inline-block !important;
  visibility: visible !important;
  pointer-events: auto !important;
  z-index: 1000 !important;
  position: relative !important;
}

#google_translate_element .goog-te-gadget a,
#google_translate_element a.VIpgJd-ZVi9od-xl07Ob-lTBxed {
  display: inline-block !important;
  visibility: visible !important;
  opacity: 1 !important;
  pointer-events: auto !important;
  cursor: pointer !important;
  position: relative !important;
  z-index: 1001 !important;
  color: #000 !important;
  text-decoration: none !important;
}

/* Z-INDEX APPROACH: Hide banner (first line) with low z-index, keep dropdown (second line) with high z-index */

/* Google Translate Banner (first line) - COMPLETELY HIDE */
body > .goog-te-banner-frame,
body > .skiptranslate {
  z-index: 1 !important;
  position: relative !important;
  pointer-events: none !important;
  height: 0 !important;
  overflow: hidden !important;
  display: none !important;
}

/* Banner iframes - completely hidden */
body > .goog-te-banner-frame iframe,
body > .skiptranslate iframe {
  z-index: 1 !important;
  pointer-events: none !important;
  display: none !important;
}

/* Top Bar (second line) - HIGH z-index to cover banner */
.top-bar {
  position: relative;
  z-index: 1000 !important;
}

/* Google Translate Element in Top Bar - HIGH z-index */
#google_translate_element {
  position: relative;
  z-index: 1001 !important;
  display: inline-block;
  pointer-events: auto !important;
}

/* Google Translate Gadget - HIGH z-index */
#google_translate_element .goog-te-gadget {
  position: relative;
  z-index: 1002 !important;
  display: inline-block !important;
  pointer-events: auto !important;
}

/* Google Translate Dropdown Anchor - HIGH z-index */
#google_translate_element .goog-te-gadget a,
#google_translate_element a.VIpgJd-ZVi9od-xl07Ob-lTBxed {
  position: relative;
  z-index: 1003 !important;
  color: #000 !important;
  cursor: pointer !important;
  pointer-events: auto !important;
}

/* Custom Language Selector */
.custom-language-selector {
  background: transparent;
  color: #ffffff;
  border: 1px solid #ffffff;
  padding: 4px 12px;
  border-radius: 3px;
  font-size: 12px;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23ffffff' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 8px center;
  padding-right: 28px;
  z-index: 1001;
  position: relative;
}

.custom-language-selector:hover {
  background-color: #333333;
}

.custom-language-selector option {
  background: #000000;
  color: #ffffff;
}

/* Language Controls Wrapper */
.language-controls {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

/* Language Reset Button */
.custom-language-reset {
  padding: 4px 16px;
  border: 2px solid #ffffff;
  background: #cc0000;
  color: #ffffff;
  border-radius: 4px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.custom-language-reset:hover {
  background-color: #ff0000;
  transform: scale(1.05);
  box-shadow: 0 2px 8px rgba(255, 255, 255, 0.3);
}

/* CRITICAL: Dropdown Menu Iframe - HIGHEST z-index to be on top and clickable */
iframe[src*="translate.google.com"] {
  z-index: 99999 !important;
  position: absolute !important;
  pointer-events: auto !important;
  display: block !important;
  visibility: visible !important;
  opacity: 1 !important;
}

/* EXCEPTION: Banner iframes - already hidden above */

/* Also style select if it exists (for compatibility) */
#google_translate_element select.goog-te-combo {
  padding: 4px 8px;
  border: 1px solid #666;
  border-radius: 3px;
  background: #000;
  font-size: 12px;
  color: #fff;
  cursor: pointer;
  position: relative;
  z-index: 1001;
  pointer-events: auto;
  display: block;
  visibility: visible;
  opacity: 1;
}

/* Hide "Powered by" text and logo only */
#google_translate_element .goog-te-gadget span[style*="white-space:nowrap"],
#google_translate_element .VIpgJd-ZVi9od-l4eHX-hSRGPd,
#google_translate_element a[href*="translate.google.com"],
#google_translate_element .goog-te-gadget > span:not([id]),
#google_translate_element .goog-te-gadget > a,
#google_translate_element .goog-te-gadget img {
  display: none !important;
}

/* Make the Google Translate banner (first line) have lower z-index so second line covers it */
/* Make it non-interactive so clicks pass through to the selector below */
/* BUT: Only apply to the banner, NOT the dropdown menu iframe */
body > .goog-te-banner-frame,
body > .skiptranslate {
  z-index: 1 !important;
  position: relative;
  pointer-events: none !important;
}

/* CRITICAL: Don't block iframes here - let JavaScript distinguish between banner and dropdown */
/* JavaScript will handle making dropdown menu iframes clickable and banner iframes non-interactive */

/* But allow banner buttons to be clickable */
body > .goog-te-banner-frame a,
body > .goog-te-banner-frame button,
body > .skiptranslate a,
body > .skiptranslate button {
  pointer-events: auto !important;
}

/* Ensure the top bar (second line) is above the banner */
/* But make sure it doesn't block dropdown menus */
.top-bar {
  position: relative;
  z-index: 1000 !important;
  /* Don't block pointer events - let clicks pass through to dropdown menu */
  pointer-events: auto;
}

/* CRITICAL: Ensure top-bar doesn't block dropdown menu iframes */
.top-bar iframe[src*="translate"] {
  pointer-events: auto !important;
  z-index: 99999 !important;
}

#google_translate_element .goog-te-gadget > div[id*="targetLanguage"] {
  font-size: 12px !important;
}


#refresh-btn {
  background: transparent;
  color: #ffffff;
  border: 1px solid #ffffff;
  padding: 4px 12px;
  border-radius: 3px;
  font-size: 12px;
  cursor: pointer;
  transition: background 0.2s;
}

#refresh-btn:hover {
  background: #333333;
}

/* Custom Language Selector */
.language-selector-custom {
  display: inline-block;
  margin-left: 8px;
}

#language-select {
  background: transparent;
  color: #ffffff;
  border: 1px solid #ffffff;
  padding: 4px 12px;
  border-radius: 3px;
  font-size: 12px;
  cursor: pointer;
  transition: background 0.2s;
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23ffffff' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 8px center;
  padding-right: 28px;
  min-width: 100px;
}

#language-select:hover {
  background-color: #333333;
}

#language-select option {
  background: #000000;
  color: #ffffff;
}


/* Main Header */
.main-header {
  background: #000000;
  padding: 16px 0;
  border-bottom: 1px solid #333333;
}

.header-container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.main-logo {
  font-size: 32px;
  font-weight: 400;
  color: #ffffff;
  letter-spacing: -1px;
  margin: 0;
  font-family: "Times New Roman", Times, serif;
}

.header-actions {
  display: flex;
  gap: 12px;
  align-items: center;
}

.header-btn {
  background: transparent;
  color: #ffffff;
  border: 1px solid #ffffff;
  padding: 8px 16px;
  border-radius: 3px;
  font-size: 13px;
  cursor: pointer;
  transition: background 0.2s;
}

.header-btn:hover {
  background: #333333;
}

.header-btn.primary {
  background: #ffffff;
  color: #000000;
}

.header-btn.primary:hover {
  background: #cccccc;
}

/* Navigation Bar */
.main-nav {
  background: #ffffff;
  border-bottom: 1px solid #e0e0e0;
  padding: 0;
}


.nav-container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  gap: 24px;
  align-items: center;
  overflow-x: auto;
}

.nav-link {
  color: #000000;
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  padding: 12px 0;
  white-space: nowrap;
  border-bottom: 3px solid transparent;
  transition: border-color 0.2s;
}

.nav-link:hover {
  border-bottom-color: #000000;
}

.arrow {
  font-size: 10px;
  margin-left: 4px;
}

/* Market Ticker */
.market-ticker {
  background: #f5f5f5;
  border-bottom: 1px solid #e0e0e0;
  padding: 8px 0;
  overflow-x: auto;
}

.ticker-container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  gap: 16px;
}

.ticker-label {
  font-size: 12px;
  font-weight: 600;
  color: #666666;
  white-space: nowrap;
}

.ticker-items {
  display: flex;
  gap: 24px;
  align-items: center;
}

.ticker-item {
  font-size: 12px;
  font-weight: 500;
  padding: 4px 8px;
  border-radius: 3px;
  white-space: nowrap;
  background: #ffffff;
  color: #000000;
}

.ticker-item.up {
  background: #d4edda;
  color: #155724;
}

.ticker-item.down {
  background: #f8d7da;
  color: #721c24;
}

/* Main Content */
.main-wrapper {
  max-width: 1400px;
  margin: 0 auto;
  padding: 24px;
}

.content-container {
  display: flex;
  flex-direction: column;
  gap: 32px;
}

/* Daily Updates Banner */
.daily-updates-banner {
  background: #ffffff;
  color: #000000;
  padding: 24px 32px;
  border-radius: 8px;
  border: 1px solid #e0e0e0;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
  margin-bottom: 8px;
}

.daily-updates-content {
  display: flex;
  align-items: center;
  gap: 20px;
}

.daily-updates-icon {
  font-size: 48px;
  line-height: 1;
}

.daily-updates-text {
  flex: 1;
}

.daily-updates-title {
  font-size: 28px;
  font-weight: 700;
  margin: 0 0 8px 0;
  color: #000000;
}

.daily-updates-date {
  font-size: 20px;
  font-weight: 600;
  margin: 0 0 4px 0;
  color: #333333;
}

.daily-updates-subtitle {
  font-size: 14px;
  margin: 0;
  color: #666666;
}

/* Left Column - Featured Article */
.left-column {
  min-width: 0;
}

.featured-section {
  width: 100%;
  overflow: hidden;
  background: #ffffff;
}

.featured-article {
  margin-bottom: 32px;
  background: #ffffff;
  padding: 0;
}

.featured-image {
  width: 100%;
  height: auto;
  min-height: 300px;
  max-height: 500px;
  background: #f0f0f0;
  display: block;
  margin-bottom: 16px;
  border: 1px solid #e0e0e0;
  overflow: hidden;
}

.featured-image img {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  max-height: 500px;
}

.featured-title {
  font-size: 32px;
  font-weight: 700;
  line-height: 1.3;
  margin: 0 0 12px;
  color: #000000;
}

.featured-title a {
  color: #000000;
  text-decoration: none;
}

.featured-title a:hover {
  color: #000000;
  text-decoration: underline;
}

.featured-meta {
  font-size: 13px;
  color: #666666;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.featured-summary {
  font-size: 16px;
  line-height: 1.7;
  color: #333333;
  margin-bottom: 24px;
}

.featured-source {
  font-size: 12px;
  color: #999999;
  font-style: italic;
}

.featured-section-wrapper {
  width: 100%;
}

/* News Grid Section */
.news-grid-container {
  width: 100%;
  margin-top: 32px;
}

.news-grid-container .news-grid {
  grid-template-columns: repeat(3, 1fr);
}

/* Wealth News Section */
.wealth-news-container {
  width: 100%;
  margin-top: 48px;
  padding-top: 32px;
  border-top: 2px solid #000000;
}

.wealth-news-container .news-grid {
  grid-template-columns: repeat(4, 1fr);
}

/* Market Research Section */
.market-research-container {
  width: 100%;
  margin-top: 48px;
  padding-top: 32px;
  border-top: 2px solid #000000;
}

.market-research-container .news-grid {
  grid-template-columns: repeat(4, 1fr);
}

.section-title {
  font-size: 24px;
  font-weight: 700;
  color: #000000;
  margin: 0 0 24px;
  padding-bottom: 12px;
  border-bottom: 2px solid #000000;
}

.news-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr); /* Default: 3 columns, overridden by specific containers */
  gap: 24px;
}

.news-card {
  background: #ffffff;
  border: 1px solid #e0e0e0;
  transition: box-shadow 0.2s ease-in-out, border-color 0.2s ease-in-out;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  height: 100%;
  border-radius: 4px;
  overflow: hidden;
  position: relative;
}

.news-card:hover {
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.12);
  border-color: #999999;
  transform: translateY(-2px);
}

.news-card-image {
  width: 100%;
  height: 200px;
  background: #f0f0f0;
  overflow: hidden;
  flex-shrink: 0;
  display: block;
}

.news-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.news-card-content {
  padding: 24px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.news-card-title {
  font-size: 18px;
  font-weight: 700;
  line-height: 1.4;
  margin: 0 0 12px;
  color: #000000;
}

.news-card-title a {
  color: #000000;
  text-decoration: none;
}

.news-card-title a:hover {
  color: #000000;
  text-decoration: underline;
}

.news-card-meta {
  font-size: 12px;
  color: #666666;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.news-card-summary {
  font-size: 14px;
  line-height: 1.6;
  color: #333333;
  margin-bottom: 12px;
  flex-grow: 1;
}

.news-card-time {
  font-size: 11px;
  color: #999999;
  margin-top: auto;
}

.symbol-pill {
  display: inline-flex;
  align-items: center;
  padding: 3px 8px;
  border-radius: 3px;
  background: #e0e0e0;
  font-size: 11px;
  font-weight: 600;
  color: #1a1a1a;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Right Column - Latest News */
.right-column {
  min-width: 0;
}

.latest-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 2px solid #000000;
}

.latest-title {
  font-size: 20px;
  font-weight: 700;
  color: #000000;
  margin: 0;
}

.category-select {
  font-size: 12px;
  padding: 4px 8px;
  border: 1px solid #e0e0e0;
  background: #ffffff;
  cursor: pointer;
}

.latest-list {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.latest-item {
  padding: 16px 0;
  border-bottom: 1px solid #e0e0e0;
  cursor: pointer;
  transition: background 0.2s;
}

.latest-item:hover {
  background: #f5f5f5;
}

.latest-item:last-child {
  border-bottom: none;
}

.latest-time {
  font-size: 12px;
  color: #666666;
  font-weight: 600;
  margin-bottom: 6px;
}

.latest-item-title {
  font-size: 14px;
  font-weight: 500;
  line-height: 1.5;
  color: #000000;
  text-decoration: none;
  display: block;
}

.latest-item-title:hover {
  color: #000000;
  text-decoration: underline;
}

/* Loading State */
.loading {
  padding: 48px 0;
  text-align: center;
  color: #666666;
  font-size: 14px;
}

/* Error Messages */
.error-message {
  background: #fff3cd;
  border: 1px solid #ffc107;
  color: #856404;
  padding: 16px;
  border-radius: 4px;
  margin: 16px 0;
}

.error-message p {
  margin: 0;
}

/* Responsive */
@media (max-width: 1200px) {
  .news-grid-container .news-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
  }
  
  .wealth-news-container .news-grid,
  .market-research-container .news-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
  }
}

@media (max-width: 1024px) {
  .content-container {
    flex-direction: column;
  }
  
  .news-grid-container .news-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }
  
  .wealth-news-container .news-grid,
  .market-research-container .news-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }
}

@media (max-width: 768px) {
  .news-grid-container .news-grid,
  .wealth-news-container .news-grid,
  .market-research-container .news-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  
  .right-column {
    order: -1;
  }
  
  .latest-header {
    margin-top: 0;
  }
}

@media (max-width: 768px) {
  .top-bar-container,
  .header-container,
  .nav-container,
  .ticker-container,
  .main-wrapper {
    padding-left: 16px;
    padding-right: 16px;
  }
  
  .top-links {
    gap: 12px;
    font-size: 11px;
  }
  
  .nav-container {
    gap: 16px;
  }
  
  .main-logo {
    font-size: 24px;
  }
  
  .ticker-items {
    gap: 12px;
  }
  
  .featured-title {
    font-size: 24px;
  }
  
  .featured-image {
    min-height: 200px;
    max-height: 300px;
  }
  
  .featured-image img {
    max-height: 300px;
  }
}

/* Footer */
.footer {
  border-top: 1px solid #e0e0e0;
  margin-top: 64px;
  padding-top: 24px;
  padding-bottom: 24px;
  font-size: 12px;
  color: #666666;
  background: #ffffff;
}

.footer-container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
}

.footer-left {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.footer-right {
  display: flex;
  gap: 16px;
  align-items: center;
  flex-wrap: wrap;
}

.footer-link {
  color: #666666;
  text-decoration: none;
}

.footer-link:hover {
  text-decoration: underline;
  color: #000000;
}

@media (max-width: 768px) {
  .footer-container {
    flex-direction: column;
    align-items: flex-start;
  }
  
  .footer-left,
  .footer-right {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }
}

