/**
 * FX Currency Hub Core — combined frontend styles
 */

/* -------------------------------------------------------------------------- */
/* Market icons ([fxch_market_icons])                                           */
/* -------------------------------------------------------------------------- */

.fxch-market-icons {
    display: inline-flex !important;
    align-items: center !important;
    gap: 0 !important;
}

.fxch-market-icon {
    width: 36px !important;
    height: 36px !important;
    border-radius: 50% !important;
    object-fit: cover !important;
    display: block !important;
    background: #fff !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.fxch-market-admin-notice {
    margin: 0 0 12px;
    padding: 10px 12px;
    background: #fff3cd;
    border: 1px solid #ffc107;
    border-radius: 4px;
    color: #664d03;
    font-size: 14px;
    line-height: 1.4;
}

/* -------------------------------------------------------------------------- */
/* Change percent badge ([fxch_market_change_percent])                        */
/* -------------------------------------------------------------------------- */

.fxch-market-change-percent {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 16px;
    border-radius: 8px;
    font-size: 18px;
    font-weight: 700;
    line-height: 1;
}

.fxch-market-change-percent.fxch-change-positive {
    background: #eafaf1;
    color: #00a651;
}

.fxch-market-change-percent.fxch-change-negative {
    background: #fdeaea;
    color: #ef233c;
}

.fxch-market-change-percent.fxch-change-neutral {
    background: #f2f2f2;
    color: #777;
}

.fxch-market-icon:first-child {
    position: relative !important;
    z-index: 2 !important;
}

.fxch-market-icon + .fxch-market-icon {
    margin-left: -8px !important;
    position: relative !important;
    z-index: 1 !important;
}

/* -------------------------------------------------------------------------- */
/* Quote actions ([fxch_market_quotes])                                         */
/* -------------------------------------------------------------------------- */

.quote-actions {
    display: flex;
    align-items: center;
    gap: 14px;
    width: 100%;
    max-width: 420px;
    font-family: Poppins, sans-serif;
}

.quote-btn {
    position: relative;
    flex: 1;
    min-height: 54px;
    border: 0;
    border-radius: 8px;
    padding: 9px 38px 9px 14px;
    color: #fff;
    text-align: left;
    cursor: pointer;
    transition: transform 0.15s ease, filter 0.15s ease;
}

a.quote-btn {
    display: block;
    text-decoration: none;
    color: #fff;
}

.quote-btn:hover {
    filter: brightness(1.05);
}

.quote-btn:active {
    transform: translateY(1px);
}

.quote-buy {
    background: #58c52c;
}

.quote-sell {
    background: #ef2525;
}

.quote-label {
    display: block;
    font-size: 12px;
    font-weight: 700;
    line-height: 1.1;
    margin-bottom: 5px;
}

.quote-price {
    display: block;
    font-size: 14px;
    font-weight: 700;
    line-height: 1;
}

.quote-icon {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 0;
}

.quote-icon svg {
    width: 1.2rem;
    height: 1.2rem;
}

.spread-box {
    min-width: 54px;
    text-align: center;
    color: #72747a;
    font-size: 11px;
    line-height: 1.4;
    background: #f5f5f5;
    padding: 8px;
    border-radius: 8px;
}

.spread-label {
    display: block;
    opacity: 0.75;
}

.spread-value {
    display: block;
    margin-top: 3px;
    color: #000;
    font-size: 13px;
    font-weight: 700;
}

@media (max-width: 420px) {
    .quote-actions {
        gap: 8px;
    }

    .quote-btn {
        padding-right: 30px;
    }

    .quote-icon {
        right: 10px;
    }

    .spread-box {
        min-width: 42px;
    }
}

/* -------------------------------------------------------------------------- */
/* Page Hidden H1([fxch_market_chart])                                           */
/* -------------------------------------------------------------------------- */

.source-only {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip-path: inset(50%) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

/* -------------------------------------------------------------------------- */
/* Market chart ([fxch_market_chart])                                           */
/* -------------------------------------------------------------------------- */

.fxch-market-chart-card {
    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.08), 0 0 0 1px rgba(0, 0, 0, 0.04);
    padding: 24px 24px 20px;
    width: 100%;
}

.fxch-market-chart-card .fxch-chart-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 4px;
}

.fxch-market-chart-card .fxch-chart-header-left {
    display: flex;
    align-items: center;
    gap: 10px;
}

.fxch-market-chart-card .fxch-price-badge {
    background: #1e293b;
    color: #ffffff;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.3px;
    padding: 5px 11px;
    border-radius: 20px;
    white-space: nowrap;
}

.fxch-market-chart-card .fxch-change-badge {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 13px;
    font-weight: 600;
    padding: 5px 11px;
    border-radius: 20px;
    white-space: nowrap;
    transition: background 0.3s, color 0.3s;
}

.fxch-market-chart-card .fxch-change-badge.negative {
    background: #fee2e2;
    color: #dc2626;
}

.fxch-market-chart-card .fxch-change-badge.positive {
    background: #dcfce7;
    color: #16a34a;
}

.fxch-market-chart-card .fxch-change-arrow {
    font-size: 11px;
    line-height: 1;
}

.fxch-market-chart-card .fxch-pair-label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    font-weight: 600;
    color: #475569;
}

.fxch-market-chart-card .fxch-pair-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #2563eb;
    flex-shrink: 0;
}

.fxch-market-chart-card .fxch-chart-body {
    position: relative;
    height: 300px;
    width: calc(100% + 16px);
    margin: 0 -8px;
}

.fxch-market-chart-card .fxch-chart-skeleton {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 14px;
    background: #fff;
    z-index: 2;
}

.fxch-market-chart-card .fxch-chart-skeleton.hidden {
    display: none;
}

.fxch-market-chart-card .fxch-chart-skeleton.is-error .fxch-spinner-ring {
    display: none;
}

.fxch-market-chart-card .fxch-spinner-ring {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 3px solid #e2e8f0;
    border-top-color: #2563eb;
    animation: fxch-chart-spin 0.75s linear infinite;
}

.fxch-market-chart-card .fxch-spinner-label {
    font-size: 12px;
    font-weight: 500;
    color: #94a3b8;
    letter-spacing: 0.3px;
    text-align: center;
    padding: 0 16px;
}

.fxch-market-chart-card .fxch-chart-skeleton.is-error .fxch-spinner-label {
    color: #dc2626;
}

@keyframes fxch-chart-spin {
    to {
        transform: rotate(360deg);
    }
}

.fxch-market-chart-card .fxch-chart-wrapper {
    position: absolute;
    inset: 0;
    z-index: 1;
}

@keyframes fxch-chart-reveal-up {
    from {
        clip-path: inset(100% 0 0 0);
    }
    to {
        clip-path: inset(0% 0 0 0);
    }
}

.fxch-market-chart-card .fxch-chart-reveal-up {
    animation: fxch-chart-reveal-up 1.1s cubic-bezier(0.4, 0.7, 0.5, 1) both;
}

.fxch-market-chart-card .fxch-chart-mount,
.fxch-market-chart-card .fxch-chart-mount .apexcharts-canvas {
    width: 100% !important;
    height: 300px !important;
}

.fxch-market-chart-card .fxch-timeframe-bar {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 4px;
    margin-top: 16px;
    background: #f1f5f9;
    border-radius: 12px;
    padding: 4px;
}

.fxch-market-chart-card .fxch-tf-btn {
    flex: 1 1 auto;
    min-width: 44px;
    max-width: 72px;
    padding: 8px 0;
    border: none;
    background: transparent;
    border-radius: 9px;
    font-size: 13px;
    font-weight: 500;
    color: #64748b;
    cursor: pointer;
    transition: background 0.18s, color 0.18s, box-shadow 0.18s;
    letter-spacing: 0.2px;
}

.fxch-market-chart-card .fxch-tf-btn:hover:not(.active) {
    background: rgba(37, 99, 235, 0.08);
    color: #2563eb;
}

.fxch-market-chart-card .fxch-tf-btn.active {
    background: #ffffff;
    color: #1e293b;
    font-weight: 600;
    box-shadow: 0 1px 6px rgba(0, 0, 0, 0.1);
}

/* -------------------------------------------------------------------------- */
/* Oscillators table ([fxch_market_oscillators_table])                         */
/* -------------------------------------------------------------------------- */

.fxch-technical-table-section {
    font-family: Poppins, sans-serif;
    width: 100%;
}

.fxch-technical-table-title {
    font-size: 17px;
    font-weight: 600;
    color: #000;
    margin: 0 0 16px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.fxch-technical-table-title span {
    font-size: 22px;
    line-height: 1;
}

.fxch-indicator-table {
    width: 100%;
    border-collapse: collapse;
    background: #fff;
}

.fxch-indicator-table th,
.fxch-indicator-table td {
    border-bottom: 1px solid #eeeeee;
    padding: 12px 0;
    font-size: 14px;
    line-height: 1.4;
}

.fxch-indicator-table th {
    font-weight: 400;
    color: #666;
    text-align: left;
}

.fxch-indicator-table td {
    color: #000;
    font-weight: 400;
}

.fxch-indicator-table th:nth-child(2),
.fxch-indicator-table td:nth-child(2) {
    text-align: right;
    width: 160px;
}

.fxch-indicator-table th:nth-child(3),
.fxch-indicator-table td:nth-child(3) {
    text-align: right;
    width: 120px;
}

.fxch-signal.buy {
    color: #0057ff;
}

.fxch-signal.sell {
    color: #ff1f1f;
}

.fxch-signal.neutral {
    color: #666;
}

@media (max-width: 768px) {
    .fxch-indicator-table th,
    .fxch-indicator-table td {
        font-size: 13px;
        padding: 10px 0;
    }

    .fxch-indicator-table th:nth-child(2),
    .fxch-indicator-table td:nth-child(2) {
        width: 100px;
    }

    .fxch-indicator-table th:nth-child(3),
    .fxch-indicator-table td:nth-child(3) {
        width: 80px;
    }
}

/* -------------------------------------------------------------------------- */
/* Trading conditions ([fxch_market_trading_conditions])                        */
/* -------------------------------------------------------------------------- */

.trading-conditions {
    font-family: Poppins, sans-serif;
}

.conditions-table {
    width: 100%;
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid #e5e5e5;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.condition-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    border-bottom: 1px solid #e5e5e5;
}

.condition-row:last-child {
    border-bottom: none;
}

.condition-label {
    background: #f5f5f5;
    padding: 18px 24px;
    font-size: 15px;
    font-weight: 600;
    color: #444;
}

.condition-value {
    background: #fff;
    padding: 18px 24px;
    font-size: 15px;
    font-weight: 600;
    color: #000;
    font-family: Poppins, sans-serif;
    white-space: nowrap;
}

.fxch-conditions-tab-nav {
    display: flex;
    gap: 8px;
    margin-bottom: 18px;
    flex-wrap: wrap;
}

.fxch-conditions-tab {
    border: 1px solid #e5e5e5;
    background: #f5f5f5;
    color: #111;
    padding: 10px 18px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
}

.fxch-conditions-tab.is-active {
    background: #111;
    color: #fff;
    border-color: #111;
}

.fxch-conditions-panel {
    display: none;
}

.fxch-conditions-panel.is-active {
    display: block;
}

.fxch-conditions-session-table {
    margin-top: 22px;
}

@media (max-width: 600px) {
    .condition-row {
        grid-template-columns: 1fr;
    }

    .condition-label {
        padding: 14px 18px 6px;
    }

    .condition-value {
        padding: 6px 18px 14px;
        white-space: normal;
    }
}

.fx-tabs-container {
  display: flex;
  width: 100%;
  gap: 24px;
  align-items: center;
  border-bottom: 1px solid #e5e5e5;
}

.fx-tabs-container a,
.fx-tabs-container .elementor-button {
  background: transparent !important;
  color: #000 !important;
  padding: 14px 0 10px 0 !important;
  border: none !important;
  border-bottom: 2px solid transparent !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  text-decoration: none !important;
  font-size: 15px;
  font-weight: 600;
  margin-bottom: -1px;
}

.fx-tabs-container a:hover,
.fx-tabs-container .elementor-button:hover {
  border-bottom-color: #999 !important;
}

.fx-tabs-container a.active,
.fx-tabs-container .elementor-button.active {
  border-bottom-color: #000 !important;
}

.fxch-forecast-card {
  background: #f2f2f2;
  border-radius: 16px;
  padding: 28px;
  margin-bottom: 28px;
}

.fxch-forecast-card-title {
  margin: 0 0 8px;
  font-size: 22px;
  font-weight: 700;
}

.fxch-forecast-card-title a {
  color: #00a8d7;
  text-decoration: none;
}

.fxch-forecast-card-meta {
  font-size: 13px;
  color: #777;
  margin-bottom: 18px;
}

.fxch-forecast-card-content {
  font-size: 16px;
  line-height: 1.7;
  color: #555;
}

.fxch-forecast-load-more {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 140px;
  padding: 12px 20px;
  border: 0;
  border-radius: 10px;
  background: #00a8d7;
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
  transition: background 0.2s ease, opacity 0.2s ease;
}

.fxch-forecast-load-more:hover {
  background: #0094bf;
}

.fxch-forecast-load-more:disabled {
  opacity: 0.65;
  cursor: not-allowed;
}

.fxch-latest-forecast-cards {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.fxch-latest-forecast-card {
  background: #f2f2f2;
  border-radius: 16px;
  padding: 16px 20px;
  display: flex;
  align-items: center;
  gap: 16px;
}

.fxch-latest-forecast-card img {
    width: 72px !important;
    height: 72px !important;
    border-radius: 14px !important;
    object-fit: cover !important;
}

.fxch-latest-forecast-card-title {
  margin: 0;
  font-size: 20px;
  font-weight: 600;
  line-height: 1.3;
}

.fxch-latest-forecast-card-title a {
  color: #00a8d7;
  text-decoration: none;
}

.fxch-latest-forecast-card-title a:hover {
  text-decoration: underline;
}

@media (max-width: 600px) {
  .fxch-latest-forecast-card {
    padding: 20px;
  }

  .fxch-latest-forecast-card-title {
    font-size: 18px;
  }
}

/* -------------------------------------------------------------------------- */
/* TradingView technical analysis widgets                                     */
/* -------------------------------------------------------------------------- */

.fxch-tradingview-widget-wrap {
  width: 100%;
}

.fxch-tradingview-widget {
  position: relative;
  width: 100%;
  overflow: hidden;
}

.fxch-tradingview-widget .tradingview-widget-container__widget {
  width: 100%;
}

/* TradingView floating logo sits inside the iframe; cover it from the parent. */
.fxch-tradingview-widget::after {
  content: '';
  position: absolute;
  right: 0;
  bottom: 0;
  width: 56px;
  height: 56px;
  background: #fff;
  z-index: 2;
  pointer-events: auto;
}

/* -------------------------------------------------------------------------- */
/* Market conditions button ([fxch_market_conditions_button])                 */
/* -------------------------------------------------------------------------- */

.fxch-market-conditions-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: #d9d9d9;
  color: #111;
  font-size: 15px;
  font-weight: 600;
  text-decoration: none;
  border-radius: 4px;
  padding: 12px 28px;
  min-height: 44px;
}

.fxch-market-conditions-btn:hover {
  background: #cfcfcf;
  color: #111;
  text-decoration: none;
}

.fxch-market-conditions-icon {
  line-height: 1;
}

