/*
Theme Name: FX Demo
Template: twentytwentyfive
Description: Dark forex-broker child theme for the FX Demo Markets demo store.
Version: 1.0.3
Text Domain: fxdemo
*/

:root {
  --fx-bg: #0A1222;
  --fx-surface: #111C31;
  --fx-surface-2: #172540;
  --fx-border: #23324F;
  --fx-text: #D5DCE8;
  --fx-muted: #8C98AD;
  --fx-green: #16C784;
  --fx-blue: #3B82F6;
  --fx-red: #EA3943;
  --fx-gold: #F5B82E;
}

body { -webkit-font-smoothing: antialiased; }
.wp-site-blocks { padding-top: 0; }
main { margin-top: 0 !important; }

/* Header */
.fx-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(10, 18, 34, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--fx-border);
  padding: 0.9rem 1rem;
}
.fx-header-inner { gap: 1.5rem; }
.fx-logo { font-weight: 800; font-size: 1.25rem; letter-spacing: -0.02em; margin: 0; white-space: nowrap; }
.fx-logo a { color: #fff; text-decoration: none; display: inline-flex; align-items: center; gap: 0.55rem; }
.fx-logo a::before {
  content: ""; width: 28px; height: 28px; border-radius: 7px; flex: none;
  background:
    linear-gradient(var(--fx-green), var(--fx-green)) 6px 12px / 4px 10px no-repeat,
    linear-gradient(var(--fx-red), var(--fx-red)) 12px 6px / 4px 14px no-repeat,
    linear-gradient(var(--fx-green), var(--fx-green)) 18px 9px / 4px 12px no-repeat,
    var(--fx-surface-2);
}
.fx-nav { font-size: 0.95rem; font-weight: 600; margin-left: auto; }
.fx-nav a { color: var(--fx-text) !important; text-decoration: none; }
.fx-nav a:hover { color: var(--fx-green) !important; }
.fx-nav .wp-block-navigation__responsive-container.is-menu-open { background: var(--fx-bg) !important; }
.fx-header .wp-block-button__link { padding: 0.55rem 1rem; font-size: 0.92rem; }
.is-style-outline .wp-block-button__link,
.wp-block-button.is-style-outline > .wp-block-button__link {
  background: transparent; color: #fff; border: 1px solid var(--fx-border);
}
.is-style-outline .wp-block-button__link:hover { border-color: var(--fx-green); color: var(--fx-green); background: transparent; }
@media (max-width: 781px) { .fx-header-cta { display: none !important; } }

.fx-ticker { border-bottom: 1px solid var(--fx-border); background: var(--fx-surface); min-height: 46px; }

/* Sections */
.fx-section { padding: clamp(3.5rem, 7vw, 6rem) 1.25rem; }
.fx-section.alt { background: var(--fx-surface); border-top: 1px solid var(--fx-border); border-bottom: 1px solid var(--fx-border); }
.fx-eyebrow {
  display: inline-block; font-size: 0.8rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--fx-green); margin-bottom: 0.25rem;
}
.fx-lead { font-size: 1.15rem; color: var(--fx-muted); max-width: 640px; }
.fx-center { text-align: center; }
.fx-center .fx-lead { margin-left: auto; margin-right: auto; }
.fx-muted { color: var(--fx-muted); }
.fx-small { font-size: 0.875rem; }

/* Hero */
.fx-hero {
  padding: clamp(3.5rem, 8vw, 7rem) 1.25rem clamp(3rem, 6vw, 5rem);
  background:
    radial-gradient(900px 500px at 85% -10%, rgba(59,130,246,0.22), transparent 60%),
    radial-gradient(700px 420px at 0% 110%, rgba(22,199,132,0.16), transparent 60%),
    var(--fx-bg);
  border-bottom: 1px solid var(--fx-border);
}
.fx-hero h1 { font-size: clamp(2.4rem, 5vw, 3.9rem); margin-top: 0.4rem; }
.fx-hero h1 em { font-style: normal; color: var(--fx-green); }
.fx-chart-card {
  background: var(--fx-surface); border: 1px solid var(--fx-border); border-radius: 16px;
  padding: 0.75rem; box-shadow: 0 30px 80px -30px rgba(0,0,0,0.7); overflow: hidden;
}

.fx-page-hero {
  padding: clamp(3rem, 6vw, 5rem) 1.25rem clamp(2.5rem, 5vw, 4rem);
  background: radial-gradient(800px 400px at 90% -20%, rgba(59,130,246,0.18), transparent 60%), var(--fx-bg);
  border-bottom: 1px solid var(--fx-border);
}
.fx-page-hero h1 { font-size: clamp(2.1rem, 4.5vw, 3.2rem); margin: 0.3rem 0 0.6rem; }

/* Stats */
.fx-stats { gap: 1rem !important; margin-top: 2.5rem !important; }
.fx-stat { border-left: 2px solid var(--fx-green); padding-left: 1rem; }
.fx-stat-value { font-size: 1.9rem; font-weight: 800; color: #fff; margin: 0; line-height: 1.1; }
.fx-stat-label { font-size: 0.875rem; color: var(--fx-muted); margin: 0.2rem 0 0; }

/* Cards */
.fx-card {
  background: var(--fx-surface); border: 1px solid var(--fx-border); border-radius: 14px;
  padding: 1.6rem !important; height: 100%;
  transition: border-color 0.2s, transform 0.2s;
}
.fx-section.alt .fx-card { background: var(--fx-bg); }
.fx-card:hover { border-color: rgba(22,199,132,0.55); transform: translateY(-2px); }
.fx-card h3 { font-size: 1.25rem; margin: 0.6rem 0 0.4rem; }
.fx-card p { color: var(--fx-muted); margin: 0; font-size: 0.98rem; }
.fx-icon {
  width: 44px; height: 44px; border-radius: 10px; display: grid; place-items: center;
  background: rgba(22,199,132,0.12); color: var(--fx-green); font-size: 1.25rem; font-weight: 800; margin: 0;
}
.fx-grid { gap: 1.25rem !important; }
.fx-grid > .wp-block-column { display: flex; }
.fx-grid > .wp-block-column > .fx-card { width: 100%; }

/* Account cards */
.fx-plan { position: relative; display: flex; flex-direction: column; }
.fx-plan.featured { border-color: var(--fx-green); box-shadow: 0 0 0 1px var(--fx-green), 0 30px 60px -30px rgba(22,199,132,0.45); }
.fx-badge {
  display: inline-block; font-size: 0.72rem; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase;
  background: var(--fx-green); color: #05140D; border-radius: 999px; padding: 0.2rem 0.65rem; margin: 0;
}
.fx-price { font-size: 2.2rem; font-weight: 800; color: #fff; margin: 0.6rem 0 0 !important; }
.fx-price small { font-size: 0.95rem; color: var(--fx-muted); font-weight: 600; }
.fx-plan ul { list-style: none; padding: 0; margin: 1.2rem 0 1.5rem; flex: 1; }
.fx-plan li { padding: 0.45rem 0 0.45rem 1.6rem; position: relative; border-bottom: 1px dashed var(--fx-border); font-size: 0.95rem; }
.fx-plan li::before { content: "✓"; position: absolute; left: 0; color: var(--fx-green); font-weight: 800; }
.fx-plan .wp-block-buttons { margin-top: auto; }
.fx-plan .wp-block-button, .fx-plan .wp-block-button__link { width: 100%; text-align: center; }

/* Tables */
.fx-table { width: 100%; overflow-x: auto; border: 1px solid var(--fx-border); border-radius: 14px; background: var(--fx-surface); }
.fx-table table { width: 100%; border-collapse: collapse; min-width: 560px; font-size: 0.95rem; }
.fx-table th, .fx-table td { padding: 0.85rem 1rem; text-align: left; border-bottom: 1px solid var(--fx-border); }
.fx-table th { color: var(--fx-muted); font-weight: 700; font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.06em; background: var(--fx-surface-2); }
.fx-table tr:last-child td { border-bottom: 0; }
.fx-table td:first-child { color: #fff; font-weight: 700; }
.fx-up { color: var(--fx-green); font-weight: 700; }
.fx-down { color: var(--fx-red); font-weight: 700; }

/* Steps */
.fx-step-num {
  width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; margin: 0;
  border: 1px solid var(--fx-green); color: var(--fx-green); font-weight: 800;
}

/* CTA band */
.fx-cta {
  border-radius: 20px; padding: clamp(2rem, 5vw, 3.5rem) !important; text-align: center;
  background: linear-gradient(135deg, #0F3D2E 0%, #12284A 100%); border: 1px solid #1E4D47;
}
.fx-cta h2 { font-size: clamp(1.8rem, 3.5vw, 2.6rem); }

/* Widgets */
.fx-widget { border: 1px solid var(--fx-border); border-radius: 14px; overflow: hidden; background: var(--fx-surface); }
.tradingview-widget-copyright { font-size: 11px; padding: 4px 8px; color: var(--fx-muted); }
.tradingview-widget-copyright a { color: var(--fx-muted); }

/* Risk + footer */
.fx-footer { background: #070D19; border-top: 1px solid var(--fx-border); padding: 4rem 1.25rem 2rem; font-size: 0.95rem; }
.fx-footer h4 { font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.1em; color: var(--fx-muted); margin-bottom: 0.8rem; }
.fx-footer ul { list-style: none; padding: 0; margin: 0; }
.fx-footer li { margin: 0.45rem 0; }
.fx-footer a { color: var(--fx-text); text-decoration: none; }
.fx-footer a:hover { color: var(--fx-green); }
.fx-risk {
  margin-top: 2.5rem !important; padding: 1.1rem 1.25rem; border: 1px solid var(--fx-border); border-radius: 12px;
  font-size: 0.82rem; color: var(--fx-muted); background: var(--fx-surface);
}
.fx-risk strong { color: var(--fx-gold); }
.fx-copy { font-size: 0.82rem; color: var(--fx-muted); margin-top: 1.5rem !important; }

/* Posts */
.fx-post-card { background: var(--fx-surface); border: 1px solid var(--fx-border); border-radius: 14px; padding: 1.5rem; }
.wp-block-post-title a { color: #fff; text-decoration: none; }
.wp-block-post-title a:hover { color: var(--fx-green); }
.wp-block-post-date, .wp-block-post-terms { color: var(--fx-muted); font-size: 0.875rem; }
.entry-content h2, .wp-block-post-content h2 { margin-top: 2.2rem; }
blockquote.wp-block-quote { border-left: 3px solid var(--fx-green); padding-left: 1.2rem; color: #fff; }

/* WooCommerce on dark */
.wc-block-components-text-input input, .wc-block-components-textarea, .woocommerce input.input-text,
.woocommerce select, .wc-blocks-components-select__select, .woocommerce-input-wrapper input {
  background: var(--fx-surface) !important; color: #fff !important; border-color: var(--fx-border) !important;
}
.wc-block-components-text-input label, .wc-blocks-components-select__label { color: var(--fx-muted) !important; }
.wc-block-grid__product, .wc-block-product, li.product {
  background: var(--fx-surface); border: 1px solid var(--fx-border); border-radius: 14px; padding: 1rem !important;
}
.wc-block-components-product-price, .woocommerce-Price-amount { color: var(--fx-green); font-weight: 700; }
.wc-block-components-product-image img, .wp-block-woocommerce-product-image img { border-radius: 10px; }
.woocommerce-store-notice, p.demo_store { background: var(--fx-gold) !important; color: #1a1300 !important; }

/* Fixes */
html, body { overflow-x: clip; }
.fx-badge { align-self: flex-start; width: auto; }
.tradingview-widget-container, .tradingview-widget-container iframe { max-width: 100%; }
.wp-block-columns, .wp-block-column { min-width: 0; }
@media (max-width: 600px) {
  .fx-stat-value { font-size: 1.35rem; }
  .fx-stats { gap: 0.6rem !important; }
  .fx-stat { padding-left: 0.6rem; }
  .fx-hero h1 { font-size: 2.1rem; }
}
@media (max-width: 600px) {
  .fx-header { padding: 0.7rem 0.75rem; }
  .fx-header-inner { gap: 0.5rem !important; }
  .fx-logo { font-size: 1rem; }
  .fx-logo a::before { width: 24px; height: 24px; }
}
/* card paragraph overrides */
.fx-card p.fx-badge { color: #05140D; font-size: 0.72rem; }
.fx-card p.fx-price { color: #fff; font-size: 2.2rem; }
.fx-card p.fx-icon { color: var(--fx-green); font-size: 1.1rem; }
.fx-card p.fx-step-num { color: var(--fx-green); font-size: 1rem; }
.wp-block-post-terms.fx-eyebrow { display: block; }
