/* === SUPER SIMPLE, EASY-TO-READ THEME === */
:root {
  --bg: #f9f9fb;
  --primary: #222;
  --accent: #0078d7;
  --border: #e3e7ed;
}
body {
  background: linear-gradient(135deg, #f9f9fb 0%, #eaf3ff 100%);
  color: var(--primary);
  font-family: 'Segoe UI', 'Roboto', Arial, sans-serif;
  margin: 0;
  min-height: 100vh;
}
header {
  background: #fff;
  border-bottom: 2px solid #00b6e6;
  box-shadow: 0 2px 12px #0001;
  padding: 0.5em 0;
}
header, footer {
  background: #fff;
  color: var(--primary);
  text-align: center;
  padding: 1.2rem 0;
  border-bottom: 1px solid var(--border);
  font-size: 1.1rem;
  letter-spacing: 0.5px;
}
footer {
  border-top: 1px solid var(--border);
  border-bottom: none;
  margin-top: 2rem;
}
.header-flex {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2vw;
}
.logo img {
  height: 54px;
  width: 54px;
  vertical-align: middle;
}
/* --- Modern Navigation Tabs --- */
.main-nav {
  display: flex;
  gap: 2.2em;
}
.nav-link {
  font-family: 'Segoe UI', 'Roboto', Arial, sans-serif;
  font-size: 1.18em;
  font-weight: 600;
  color: #00b6e6;
  letter-spacing: 0.02em;
  text-decoration: none;
  padding: 0.4em 1.2em;
  border-radius: 6px;
  transition: background 0.18s, color 0.18s;
  background: transparent;
  box-shadow: none;
}
.nav-link:hover, .nav-link:focus {
  background: #e6f7fb;
  color: #0072ff;
}
.nav-link.nav-home.active, .nav-link.nav-historical.active, .nav-link.nav-news.active {
  background: #00b6e6;
  color: #fff;
  box-shadow: 0 2px 8px #0001;
}
@media (max-width: 600px) {
  .main-nav {
    flex-direction: column;
    gap: 0.5rem;
    padding: 0.4em 0.5em;
  }
  .nav-link {
    width: 100%;
    text-align: left;
  }
}
main {
  max-width: 900px;
  margin: 2.5rem auto 0 auto;
  padding: 0 1rem;
}
.main-flex-row {
  display: flex;
  gap: 2.5rem;
  align-items: flex-start;
  justify-content: flex-start;
  margin: 2.5rem 0 2rem 0;
}
.main-images-col {
  display: flex;
  flex-direction: column;
  gap: 2.2rem;
  align-items: center;
  min-width: 120px;
}
.main-content-col {
  flex: 2 1 0;
  min-width: 420px;
  max-width: 900px;
  margin: 0 auto;
  background: #fff;
  border-radius: 1.7rem;
  box-shadow: 0 4px 24px 0 rgba(43,124,255,0.10), 0 2px 8px 0 rgba(0,0,0,0.04);
  padding: 2.2rem 2.2rem 1.7rem 2.2rem;
  margin-bottom: 1.5rem;
  transition: box-shadow 0.18s, transform 0.18s;
}
.main-content-col:hover {
  box-shadow: 0 8px 32px 0 rgba(43,124,255,0.13), 0 4px 16px 0 rgba(0,0,0,0.06);
  transform: translateY(-2px) scale(1.01);
}
section {
  background: none;
  border: none;
  border-radius: 0;
  box-shadow: none;
  padding: 0;
  margin-bottom: 2.5rem;
}
.converter, .metals-converter-card {
  margin-bottom: 2.2rem;
}
.converter h1, .metals-converter-card h2 {
  font-size: 1.35em;
  font-weight: 700;
  margin-bottom: 1.1em;
  color: var(--accent, #2b7cff);
  letter-spacing: 0.01em;
}
/* Consistent heading style for all converter headings */
.converter h1,
.crypto-heading {
  color: var(--accent, #2b7cff) !important;
  font-size: 1.25em;
  font-weight: 700;
  margin-bottom: 0.7em;
  letter-spacing: 0.01em;
  display: block;
}
.form-group {
  margin-bottom: 1.1em;
}
.modern-currency-row {
  display: flex;
  gap: 0.7em;
  align-items: center;
}
.modern-amount-input, .modern-currency-select {
  font-size: 1.08em;
  padding: 0.7em 1em;
  border-radius: 1.1em;
  border: 1.5px solid #d0e2ff;
  background: #f8fbff;
  outline: none;
  transition: border 0.16s, box-shadow 0.16s;
  box-shadow: 0 1px 4px 0 rgba(43,124,255,0.04);
  min-width: 90px;
}
.modern-amount-input:focus, .modern-currency-select:focus {
  border-color: #0078d7;
  box-shadow: 0 0 0 2px #eaf3ff;
}
.modern-currency-select {
  min-width: 140px;
  max-width: 220px;
}
.swap-btn.modern-swap-btn {
  font-size: 1.3em;
  background: linear-gradient(135deg, #eaf3ff 0%, #f8fbff 100%);
  border-radius: 50%;
  width: 2.1em;
  height: 2.1em;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  border: 1.5px solid #d0e2ff;
  color: #0078d7;
  transition: background 0.15s, border 0.15s, color 0.15s;
}
.swap-btn.modern-swap-btn:hover {
  background: #d0e2ff;
  border-color: #0078d7;
  color: #0056b3;
}
.result {
  font-size: 1.13em;
  font-weight: 600;
  color: #1a2a3a;
  margin-top: 1.2em;
  background: #f8fbff;
  border-radius: 1em;
  padding: 0.8em 1.1em;
  box-shadow: 0 1px 4px 0 rgba(43,124,255,0.06);
  border: 1.5px solid #e3e8f0;
}
.hero-banner, .metals-banner {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}
.image-overlay-wrap {
  position: relative;
  width: 90px;
  height: 90px;
  border-radius: 1.7rem;
  overflow: hidden;
  box-shadow: 0 2px 12px 0 rgba(0,0,0,0.08);
  background: #f6faff;
}
.image-blue-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, rgba(43,124,255,0.08) 0%, rgba(43,124,255,0.13) 100%);
  pointer-events: none;
}
/* --- News Page Alignment Fixes --- */
.main-flex-row {
  display: flex;
  gap: 2.5rem;
  align-items: flex-start;
  justify-content: flex-start;
  margin: 2.5rem 0 2rem 0;
}
.main-content-col {
  flex: 1 1 350px;
  max-width: 480px;
  background: #fff;
  border-radius: 1.7rem;
  box-shadow: 0 4px 24px 0 rgba(43,124,255,0.10), 0 2px 8px 0 rgba(0,0,0,0.04);
  padding: 2.2rem 2.2rem 1.7rem 2.2rem;
  margin-bottom: 1.5rem;
  min-width: 320px;
  transition: box-shadow 0.18s, transform 0.18s;
}
.news-section, .metals-news-section, .crypto-news-section {
  margin-bottom: 2.8rem;
}
.collapsible-heading {
  cursor: pointer;
  margin-bottom: 0.7em;
  font-weight: 700;
  letter-spacing: 0.01em;
  display: block;
}
.collapsible-content {
  width: 100%;
  margin-bottom: 1.2em;
}
.news-list-cards {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  margin: 1.5rem 0 0 0;
  padding: 0;
  list-style: none;
  align-items: flex-start;
  justify-content: flex-start;
}
.news-card {
  background: var(--card-bg, #fff);
  border-radius: 1.1rem;
  box-shadow: 0 2px 12px 0 rgba(0,0,0,0.07), 0 1.5px 4px 0 rgba(0,0,0,0.04);
  padding: 1.2rem 1.5rem 1.1rem 1.5rem;
  min-width: 260px;
  max-width: 340px;
  flex: 1 1 260px;
  display: flex;
  flex-direction: column;
  transition: box-shadow 0.18s, transform 0.18s;
  border: 1.5px solid #e3e8f0;
}
/* --- Consistent News Headers --- */
.news-section h1,
.metals-news-section h2,
.crypto-news-section h2,
.collapsible-heading {
  color: var(--accent, #2b7cff) !important;
  font-size: 1.25em !important;
  font-weight: 700;
  margin-bottom: 0.7em;
  letter-spacing: 0.01em;
  cursor: pointer;
  display: block;
}
@media (max-width: 700px) {
  main {
    max-width: 100%;
    padding: 0 0.5rem;
  }
  .header-flex {
    flex-direction: column;
    gap: 0.5em;
    padding: 0 1vw;
  }
  .main-nav {
    gap: 1em;
  }
  .logo img {
    height: 40px;
    width: 40px;
  }
}
@media (max-width: 900px) {
  .main-flex-row {
    flex-direction: column;
    gap: 1.5rem;
  }
  .main-content-col {
    max-width: 100%;
    padding: 1.2rem 1.1rem 1.1rem 1.1rem;
  }
  .main-images-col {
    flex-direction: row;
    gap: 1.2rem;
    margin-bottom: 1.2rem;
  }
}
@media (max-width: 1100px) {
  .main-flex-row {
    flex-direction: column;
    gap: 1.5rem;
  }
  .main-content-col {
    max-width: 100%;
    min-width: 0;
    padding: 1.2rem 1.1rem 1.1rem 1.1rem;
  }
  .news-list-cards {
    flex-direction: column;
    gap: 1rem;
  }
}

/* Add a little more spacing between sections */
section + section {
  margin-top: 2.5rem;
}

/* Slightly rounder images for a friendlier look */
.image-overlay-wrap {
  border-radius: 1.7rem;
}
.main-content-col canvas, .converter canvas, .topconversion-modal canvas, .topconversion-card canvas {
  width: 100% !important;
  max-width: 860px !important;
  min-width: 320px;
  height: 260px !important;
  margin: 0 auto;
  display: block;
}

/* === SlimSelect Custom Styling === */
.ss-main {
    max-width: 100% !important;
    min-height: 40px !important;
}

.ss-single-selected {
    padding: 8px 12px !important;
    border: 1px solid #ddd !important;
    border-radius: 8px !important;
    background: #fff !important;
    color: #333 !important;
    font-size: 14px !important;
    line-height: 1.4 !important;
    min-height: 38px !important;
    display: flex !important;
    align-items: center !important;
}

.ss-single-selected:hover {
    border-color: #0078d7 !important;
}

.ss-content {
    border: 1px solid #ddd !important;
    border-radius: 8px !important;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15) !important;
    max-height: 300px !important;
    z-index: 9999 !important;
}

.ss-search input {
    padding: 8px 12px !important;
    border: 1px solid #ddd !important;
    border-radius: 6px !important;
    font-size: 14px !important;
}

.ss-option {
    padding: 8px 12px !important;
    font-size: 14px !important;
    line-height: 1.4 !important;
    cursor: pointer !important;
}

.ss-option:hover, .ss-option.ss-highlighted {
    background: #f0f8ff !important;
    color: #0078d7 !important;
}

.ss-option.ss-selected {
    background: #0078d7 !important;
    color: white !important;
}

/* Fix arrow positioning */
.ss-arrow {
    right: 12px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
}

/* Ensure dropdowns don't break layout */
.converter-flex .ss-main,
.crypto-converter .ss-main,
.metals-converter .ss-main {
    flex: 1 !important;
    max-width: 200px !important;
}

/* Mobile responsive */
@media (max-width: 768px) {
    .ss-content {
        max-height: 250px !important;
    }
    
    .converter-flex .ss-main,
    .crypto-converter .ss-main,
    .metals-converter .ss-main {
        max-width: 100% !important;
    }
}
