/* ============================================
   TSB 5.0 - Tools / Calculator Pages
   Tokens imported via tokens.css
   ============================================ */

@import url('../../assets/tokens.css');

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

body {
    font-family: 'Instrument Sans', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg-void);
    color: var(--text-primary);
    min-height: 100vh;
    overflow-x: hidden;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

.bg-glow {
    position: fixed;
    top: -200px;
    left: 50%;
    transform: translateX(-50%);
    width: 800px;
    height: 600px;
    background: radial-gradient(ellipse, rgba(77, 171, 154, 0.06) 0%, transparent 70%);
    pointer-events: none;
    z-index: 0;
}

.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 24px;
    position: relative;
    z-index: 1;
}

/* Tools index uses wider container */
.container-wide {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 24px;
    position: relative;
    z-index: 1;
}

/* ============================================
   Header
   ============================================ */
.page-header {
    text-align: center;
    padding: 48px 0 40px;
}

.page-header .logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 24px;
    text-decoration: none;
    color: var(--text-primary);
}

.logo-icon {
    width: 32px;
    height: 32px;
    background: var(--accent);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
}

.logo-icon svg { width: 18px; height: 18px; color: #fff; }

.logo-text {
    font-size: 18px;
    font-weight: 600;
}

h1 {
    font-size: clamp(28px, 5vw, 38px);
    font-weight: 700;
    margin-bottom: 16px;
    letter-spacing: -0.02em;
}

.page-header p {
    font-size: 17px;
    color: var(--text-secondary);
    max-width: 560px;
    margin: 0 auto;
}

/* ============================================
   Calculator Card
   ============================================ */
.calc-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    padding: var(--space-8);
    margin-bottom: 48px;
}

.calc-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    margin-bottom: 24px;
}

@media (max-width: 600px) {
    .calc-grid { grid-template-columns: 1fr; }
}

/* ============================================
   Inputs
   ============================================ */
.input-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.input-group label {
    font-size: 13px;
    font-weight: 500;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 6px;
}

.input-group label i {
    width: 14px;
    height: 14px;
    color: var(--text-muted);
}

.input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.input-wrapper input {
    width: 100%;
    padding: 14px 16px;
    padding-right: 50px;
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    border-radius: 10px;
    color: var(--text-primary);
    font-size: 16px;
    font-family: 'DM Mono', monospace;
    transition: border-color var(--duration-normal);
}

.input-wrapper input:focus {
    outline: none;
    border-color: var(--accent);
}

.input-suffix {
    position: absolute;
    right: 14px;
    color: var(--text-muted);
    font-size: 13px;
    font-weight: 500;
}

.input-group select {
    width: 100%;
    padding: 14px 16px;
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    border-radius: 10px;
    color: var(--text-primary);
    font-size: 15px;
    font-family: inherit;
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%236b6b75' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
}

.input-group select:focus {
    outline: none;
    border-color: var(--accent);
}

/* ============================================
   Prop Firm Calculator — form classes
   ============================================ */
.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 20px;
}

@media (max-width: 500px) {
    .form-grid { grid-template-columns: 1fr; }
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.form-label {
    font-size: 13px;
    font-weight: 500;
    color: var(--text-secondary);
}

.form-label .hint {
    color: var(--text-muted);
    font-weight: 400;
}

.form-input {
    width: 100%;
    padding: 12px 14px;
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    border-radius: 10px;
    color: var(--text-primary);
    font-size: 15px;
    font-family: 'DM Mono', monospace;
    transition: border-color var(--duration-normal);
}

.form-input:focus {
    outline: none;
    border-color: var(--accent);
}

.form-input::placeholder {
    color: var(--text-muted);
}

.form-select {
    width: 100%;
    padding: 12px 14px;
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    border-radius: 10px;
    color: var(--text-primary);
    font-size: 15px;
    font-family: inherit;
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%236b6b75' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
}

.form-select:focus {
    outline: none;
    border-color: var(--accent);
}

.btn-calculate {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 14px 24px;
    background: var(--accent);
    color: #fff;
    border: none;
    border-radius: 10px;
    font-size: 15px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: opacity 0.2s;
}

.btn-calculate:hover {
    opacity: 0.88;
}

.btn-calculate i {
    width: 18px;
    height: 18px;
}

/* ============================================
   Results
   ============================================ */
.results {
    background: linear-gradient(135deg, rgba(77, 171, 154, 0.1) 0%, rgba(77, 171, 154, 0.02) 100%);
    border: 1px solid rgba(77, 171, 154, 0.2);
    border-radius: var(--radius-md);
    padding: 24px;
}

.results-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 20px;
    padding-bottom: 16px;
    border-bottom: 1px solid rgba(77, 171, 154, 0.15);
}

.results-header i {
    width: 20px;
    height: 20px;
    color: var(--accent);
}

.results-header span {
    font-weight: 600;
    color: var(--text-primary);
}

.results-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

@media (max-width: 500px) {
    .results-grid { grid-template-columns: 1fr; }
}

.result-item {
    text-align: center;
}

.result-label {
    font-size: 12px;
    color: var(--text-tertiary);
    margin-bottom: 4px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.result-value {
    font-size: 24px;
    font-weight: 700;
    font-family: 'DM Mono', monospace;
    color: var(--accent);
}

.result-value.highlight {
    font-size: 28px;
}

.result-sub {
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 2px;
}

/* ============================================
   Lot Breakdown
   ============================================ */
.lot-breakdown {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid rgba(255,255,255,0.06);
}

.lot-breakdown-title {
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-tertiary);
    margin-bottom: 12px;
}

.lot-breakdown-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
}

@media (max-width: 500px) {
    .lot-breakdown-grid { grid-template-columns: repeat(2, 1fr); }
}

.lot-item {
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: var(--radius-sm);
    padding: 10px 12px;
    text-align: center;
}

.lot-type {
    font-size: 11px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-bottom: 4px;
}

.lot-value {
    font-size: 16px;
    font-weight: 700;
    font-family: 'DM Mono', monospace;
    color: var(--text-primary);
}

/* ============================================
   Risk Indicator
   ============================================ */
.risk-indicator {
    margin-top: 20px;
    padding: 12px 16px;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 13px;
}

.risk-indicator i { width: 16px; height: 16px; }

.risk-low {
    background: var(--green-bg);
    border: 1px solid var(--green-border);
    color: var(--green);
}

.risk-medium {
    background: rgba(251, 191, 36, 0.1);
    border: 1px solid rgba(251, 191, 36, 0.2);
    color: var(--warn-light);
}

.risk-high {
    background: var(--red-bg);
    border: 1px solid var(--red-border);
    color: var(--red);
}

/* ============================================
   Content Sections
   ============================================ */
.content-section {
    margin-bottom: 48px;
}

.content-section h2 {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 16px;
    color: var(--text-primary);
}

.content-section h3 {
    font-size: 18px;
    font-weight: 600;
    margin: 24px 0 12px;
    color: var(--text-primary);
}

.content-section p {
    color: var(--text-secondary);
    margin-bottom: 16px;
}

.content-section ul, .content-section ol {
    color: var(--text-secondary);
    margin-left: 24px;
    margin-bottom: 16px;
}

.content-section li {
    margin-bottom: 8px;
}

.formula-box {
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    border-radius: 10px;
    padding: 20px;
    margin: 20px 0;
    font-family: 'DM Mono', monospace;
    text-align: center;
}

.formula-box .formula {
    font-size: 16px;
    color: var(--accent);
    margin-bottom: 12px;
}

.formula-box .formula-desc {
    font-size: 13px;
    color: var(--text-muted);
    font-family: 'Instrument Sans', sans-serif;
}

/* ============================================
   Example Box
   ============================================ */
.example-box {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    padding: 24px;
    margin: 24px 0;
}

.example-box h4 {
    font-size: 14px;
    font-weight: 600;
    color: var(--accent);
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.example-box h4 i {
    width: 16px;
    height: 16px;
}

.example-steps {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.example-step {
    display: flex;
    align-items: baseline;
    gap: 12px;
    font-size: 14px;
}

.example-step .step-num {
    width: 20px;
    height: 20px;
    background: var(--bg-secondary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 600;
    color: var(--text-muted);
    flex-shrink: 0;
}

.example-step .step-text {
    color: var(--text-secondary);
}

.example-step .step-text strong {
    color: var(--text-primary);
}

.example-result {
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid var(--glass-border);
    font-family: 'DM Mono', monospace;
    color: var(--accent);
    font-size: 15px;
}

/* ============================================
   FAQ
   ============================================ */
.faq-section {
    margin-bottom: 48px;
}

.faq-item {
    border-bottom: 1px solid var(--glass-border);
    padding: 20px 0;
}

.faq-item:first-child {
    border-top: 1px solid var(--glass-border);
}

.faq-question {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 8px;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.faq-question i {
    width: 18px;
    height: 18px;
    color: var(--text-muted);
    transition: transform var(--duration-normal);
}

.faq-item.open .faq-question i {
    transform: rotate(180deg);
}

.faq-answer {
    color: var(--text-secondary);
    font-size: 15px;
    line-height: 1.7;
    display: none;
}

.faq-item.open .faq-answer {
    display: block;
}

/* ============================================
   Related Tools
   ============================================ */
.related-tools {
    margin-bottom: 48px;
}

.related-tools h2 {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 20px;
}

.tools-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}

@media (max-width: 500px) {
    .tools-grid { grid-template-columns: 1fr; }
}

.tool-link {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px 20px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    text-decoration: none;
    transition: all var(--duration-normal);
}

.tool-link:hover {
    border-color: var(--glass-border-hover);
    transform: translateY(-2px);
}

.tool-link-icon {
    width: 40px;
    height: 40px;
    background: var(--accent-subtle);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.tool-link-icon i {
    width: 20px;
    height: 20px;
    color: var(--accent);
}

.tool-link-text h3 {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 2px;
}

.tool-link-text p {
    font-size: 12px;
    color: var(--text-muted);
}

/* ============================================
   CTA Section
   ============================================ */
.cta-section {
    background: linear-gradient(135deg, var(--glass-bg) 0%, var(--bg-secondary) 100%);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    padding: 40px;
    text-align: center;
    margin-bottom: 48px;
}

.cta-section h2 {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 12px;
}

.cta-section p {
    color: var(--text-secondary);
    margin-bottom: 24px;
    max-width: 480px;
    margin-left: auto;
    margin-right: auto;
}

.cta-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 28px;
    background: var(--accent);
    color: #fff;
    font-size: 15px;
    font-weight: 600;
    border-radius: 10px;
    text-decoration: none;
    transition: all var(--duration-normal);
}

.cta-btn:hover {
    background: var(--accent-secondary);
    transform: translateY(-2px);
}

.cta-btn i {
    width: 18px;
    height: 18px;
}

/* Alias */
.btn-cta {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 28px;
    background: var(--accent);
    color: #fff;
    font-size: 15px;
    font-weight: 600;
    border-radius: 10px;
    text-decoration: none;
    transition: all var(--duration-normal);
}

.btn-cta:hover {
    background: var(--accent-secondary);
    transform: translateY(-2px);
}

.btn-cta i {
    width: 18px;
    height: 18px;
}

/* ============================================
   Related Tools
   ============================================ */
.related-tools {
    margin: 48px 0 32px;
}

.related-tools h2 {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 16px;
    letter-spacing: -0.01em;
}

.tool-link {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px 18px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    text-decoration: none;
    transition: background 0.15s, border-color 0.15s, transform 0.15s;
}

.tool-link:hover {
    background: var(--glass-bg-hover);
    border-color: var(--glass-border-hover);
    transform: translateY(-1px);
}

.tool-link-icon {
    width: 38px;
    height: 38px;
    background: var(--accent-subtle);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: var(--accent);
}

.tool-link-icon i { width: 18px; height: 18px; }

.tool-link-text h3 {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 2px;
}

.tool-link-text p {
    font-size: 12px;
    color: var(--text-muted);
}

/* ============================================
   Prop Firm Calculator — Results
   ============================================ */

.results-section { display: none; margin-bottom: 32px; }
.results-section.visible { display: block; }

.results-title {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 24px;
}

.results-title i { width: 20px; height: 20px; }

.sim-summary {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1px;
    background: var(--glass-border);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    overflow: hidden;
    margin-bottom: 24px;
}

.sim-summary > div {
    background: var(--glass-bg);
    padding: 20px;
    text-align: center;
}

.sim-stat-label {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-muted);
    margin-bottom: 8px;
}

.sim-stat-value {
    font-size: 22px;
    font-weight: 700;
    font-family: 'DM Mono', monospace;
    color: var(--text-primary);
}

.firm-result {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    padding: 24px;
    margin-bottom: 12px;
}

.firm-result.pass { border-color: var(--green-border); background: var(--green-bg); }
.firm-result.fail { border-color: var(--red-border); background: var(--red-bg); }

.firm-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.firm-name { font-size: 16px; font-weight: 700; color: var(--text-primary); }

.firm-verdict {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    padding: 4px 12px;
    border-radius: 100px;
}

.firm-verdict.pass     { background: var(--green-bg);  color: var(--green);  border: 1px solid var(--green-border); }
.firm-verdict.fail     { background: var(--red-bg);    color: var(--red);    border: 1px solid var(--red-border); }
.firm-verdict.marginal { background: var(--amber-bg);  color: var(--amber);  border: 1px solid rgba(245,158,11,0.25); }

.firm-checks { display: flex; flex-direction: column; gap: 8px; }

.firm-check {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 13px;
    padding: 8px 12px;
    background: rgba(0,0,0,0.15);
    border-radius: var(--radius-sm);
}

.firm-check-label {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-secondary);
}

.firm-check-icon { width: 14px; height: 14px; flex-shrink: 0; }

.firm-check-value { font-family: 'DM Mono', monospace; font-size: 12px; font-weight: 500; }
.firm-check-value.ok  { color: var(--green); }
.firm-check-value.bad { color: var(--red); }

.disclaimer {
    font-size: 13px;
    color: var(--text-muted);
    text-align: center;
    padding: 20px;
    line-height: 1.6;
}

@media (max-width: 500px) {
    .sim-summary { grid-template-columns: 1fr; }
}

/* ============================================
   Trading Psychology Quiz
   ============================================ */

/* Progress */
#quizProgress {
    margin-bottom: 32px;
}

.progress-label {
    display: flex;
    justify-content: space-between;
    font-size: 13px;
    color: var(--text-muted);
    margin-bottom: 8px;
}

.progress-bar {
    height: 4px;
    background: var(--glass-border);
    border-radius: 100px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: var(--accent);
    border-radius: 100px;
    transition: width 0.4s var(--ease-out);
    width: 0%;
}

/* Quiz card — one question at a time */
.quiz-card {
    display: none;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    padding: 32px;
    margin-bottom: 24px;
    animation: fadeSlideIn 0.25s var(--ease-out);
}

.quiz-card.active { display: block; }

@keyframes fadeSlideIn {
    from { opacity: 0; transform: translateY(10px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* Letter prefix on answer buttons */
.answer-btn .letter {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    background: rgba(255,255,255,0.06);
    border-radius: 6px;
    font-size: 11px;
    font-weight: 700;
    color: var(--text-muted);
    flex-shrink: 0;
    margin-right: 10px;
    transition: background 0.15s, color 0.15s;
}

.answer-btn:hover .letter {
    background: var(--accent-subtle);
    color: var(--accent);
}

/* Question */
.question-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    padding: 32px;
    margin-bottom: 24px;
}

.question-number {
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--accent);
    margin-bottom: 12px;
}

.question-text {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
    line-height: 1.4;
    margin-bottom: 24px;
    letter-spacing: -0.01em;
}

.answers {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.answer-btn {
    width: 100%;
    padding: 14px 18px;
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-size: 14px;
    font-family: inherit;
    text-align: left;
    cursor: pointer;
    transition: background 0.15s, border-color 0.15s, transform 0.15s;
    line-height: 1.4;
}

.answer-btn:hover {
    background: var(--glass-bg-hover);
    border-color: var(--accent);
    transform: translateX(4px);
}

.answer-btn.selected {
    background: var(--accent-subtle);
    border-color: var(--accent);
    color: var(--text-primary);
}

/* Email gate */
.email-gate {
    display: none;
}

.email-gate.active {
    display: block;
}

.email-gate-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    padding: 48px 40px;
    text-align: center;
    max-width: 480px;
    margin: 0 auto;
}

.email-gate-icon {
    width: 56px;
    height: 56px;
    background: var(--accent-subtle);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    color: var(--accent);
}

.email-gate-card h2 {
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 10px;
}

.email-gate-card p {
    font-size: 15px;
    color: var(--text-secondary);
    margin-bottom: 24px;
    line-height: 1.6;
}

.email-form {
    display: flex;
    gap: 10px;
    margin-bottom: 14px;
}

.email-input {
    flex: 1;
    padding: 12px 14px;
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-size: 14px;
    font-family: inherit;
}

.email-input:focus {
    outline: none;
    border-color: var(--accent);
}

.email-input::placeholder { color: var(--text-muted); }

.email-submit {
    padding: 12px 20px;
    background: var(--accent);
    color: #fff;
    border: none;
    border-radius: var(--radius-md);
    font-size: 14px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    white-space: nowrap;
    transition: opacity 0.2s;
}

.email-submit:hover { opacity: 0.88; }

.skip-link {
    font-size: 13px;
    color: var(--text-muted);
    cursor: pointer;
    text-decoration: underline;
    text-underline-offset: 3px;
    transition: color 0.2s;
}

.skip-link:hover { color: var(--text-secondary); }

/* Results */
.result-section {
    display: none;
}

.result-section.active {
    display: block;
}

.result-card {
    background: linear-gradient(135deg, rgba(77,171,154,0.08) 0%, rgba(77,171,154,0.02) 100%);
    border: 1px solid rgba(77,171,154,0.25);
    border-radius: var(--radius-xl);
    padding: 40px;
    text-align: center;
    margin-bottom: 24px;
}

.result-emoji {
    font-size: 48px;
    margin-bottom: 16px;
    line-height: 1;
}

.result-type-label {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--accent);
    margin-bottom: 8px;
}

.result-type-name {
    font-size: 28px;
    font-weight: 700;
    letter-spacing: -0.02em;
    margin-bottom: 16px;
}

.result-description {
    font-size: 15px;
    color: var(--text-secondary);
    line-height: 1.7;
    max-width: 520px;
    margin: 0 auto 24px;
}

.share-row {
    display: flex;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
}

.share-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 9px 16px;
    background: rgba(255,255,255,0.06);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    font-size: 13px;
    font-weight: 500;
    font-family: inherit;
    cursor: pointer;
    transition: background 0.15s, border-color 0.15s;
}

.share-btn:hover {
    background: rgba(255,255,255,0.1);
    border-color: var(--glass-border-hover);
    color: var(--text-primary);
}

/* Scores */
.scores-section {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    padding: 28px;
    margin-bottom: 16px;
}

.scores-title {
    font-size: 13px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-muted);
    margin-bottom: 20px;
}

.score-bar-row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.score-bar-label {
    font-size: 13px;
    color: var(--text-secondary);
    width: 130px;
    flex-shrink: 0;
}

.score-bar-track {
    flex: 1;
    height: 6px;
    background: var(--glass-border);
    border-radius: 100px;
    overflow: hidden;
}

.score-bar-fill {
    height: 100%;
    border-radius: 100px;
    transition: width 0.6s var(--ease-out);
}

.score-bar-fill.revenge  { background: var(--red); }
.score-bar-fill.overtrader { background: var(--amber); }
.score-bar-fill.fomo     { background: #fb923c; }
.score-bar-fill.disciplined { background: var(--green); }
.score-bar-fill.fearful  { background: var(--blue); }

.score-bar-pct {
    font-size: 12px;
    color: var(--text-muted);
    font-family: 'DM Mono', monospace;
    width: 34px;
    text-align: right;
    flex-shrink: 0;
}

/* Traits */
.traits-section {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    padding: 28px;
    margin-bottom: 16px;
}

.traits-title {
    font-size: 13px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-muted);
    margin-bottom: 16px;
}

.traits-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

@media (max-width: 500px) {
    .traits-grid { grid-template-columns: 1fr; }
    .email-form { flex-direction: column; }
}

.trait-item {
    padding: 12px 14px;
    border-radius: var(--radius-sm);
    border: 1px solid;
}

.trait-item.strength {
    background: var(--green-bg);
    border-color: var(--green-border);
}

.trait-item.weakness {
    background: var(--red-bg);
    border-color: var(--red-border);
}

.trait-label {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 4px;
}

.trait-item.strength .trait-label { color: var(--green); }
.trait-item.weakness .trait-label { color: var(--red); }

.trait-value {
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.4;
}

/* Tips */
.tips-section {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    padding: 28px;
    margin-bottom: 24px;
}

.tips-title {
    font-size: 13px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-muted);
    margin-bottom: 16px;
}

.tip-item {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    padding: 12px 0;
    border-bottom: 1px solid var(--glass-border);
}

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

.tip-num {
    width: 22px;
    height: 22px;
    background: var(--accent-subtle);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 700;
    color: var(--accent);
    flex-shrink: 0;
    margin-top: 1px;
}

/* Purple accent for quiz header */
.purple {
    color: var(--accent-purple);
}

/* ambient-glow (quiz uses this too) */
.ambient-glow {
    position: fixed;
    top: -300px;
    right: -200px;
    width: 600px;
    height: 600px;
    background: radial-gradient(ellipse, rgba(168, 85, 247, 0.06) 0%, transparent 70%);
    pointer-events: none;
    z-index: 0;
}

/* ============================================
   Footer
   ============================================ */
.footer {
    text-align: center;
    padding: var(--space-8) 0;
    border-top: 1px solid var(--glass-border);
    color: var(--text-muted);
    font-size: 13px;
}

.footer a {
    color: var(--text-secondary);
    text-decoration: none;
}

.footer a:hover {
    color: var(--accent);
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 24px;
    margin-top: 12px;
}

/* ============================================
   Tools Index Grid (for index.php)
   ============================================ */
.tools-index-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
    margin-bottom: 48px;
}

.tool-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    padding: 24px;
    text-decoration: none;
    transition: all var(--duration-normal);
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.tool-card:hover {
    border-color: var(--glass-border-hover);
    transform: translateY(-2px);
    box-shadow: var(--shadow-sm);
}

.tool-card-icon {
    width: 44px;
    height: 44px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
}

.tool-card-icon i {
    width: 22px;
    height: 22px;
}

.tool-card h3 {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
}

.tool-card p {
    font-size: 13px;
    color: var(--text-muted);
    line-height: 1.5;
}

/* Page footer (used by tools) */
.page-footer {
    text-align: center;
    padding: 32px 0 48px;
    border-top: 1px solid var(--glass-border);
    font-size: 13px;
    color: var(--text-muted);
    margin-top: 48px;
}

.page-footer a {
    color: var(--accent);
    text-decoration: none;
}

.page-footer a:hover {
    text-decoration: underline;
}

/* ============================================
   Risk/Reward Calculator
   ============================================ */

/* Trade type toggle */
.trade-type-toggle {
    display: flex;
    gap: 8px;
    margin-bottom: 28px;
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    padding: 4px;
}

.trade-type-btn {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 16px;
    background: transparent;
    border: none;
    border-radius: calc(var(--radius-md) - 4px);
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: background 0.15s, color 0.15s;
}

.trade-type-btn i { width: 16px; height: 16px; }

.trade-type-btn.active {
    background: var(--glass-bg);
    color: var(--text-primary);
    box-shadow: var(--shadow-sm);
}

.trade-type-btn.long.active { color: var(--green); }
.trade-type-btn.short.active { color: var(--red); }

/* RR Display — big ratio */
.results-main {
    display: flex;
    justify-content: center;
    padding: 28px 0 20px;
}

.rr-display {
    text-align: center;
}

.rr-label {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text-muted);
    margin-bottom: 8px;
}

.rr-value {
    font-size: 52px;
    font-weight: 700;
    font-family: 'DM Mono', monospace;
    letter-spacing: -0.03em;
    color: var(--text-primary);
    line-height: 1;
    margin-bottom: 10px;
}

.rr-verdict {
    display: inline-block;
    padding: 4px 14px;
    border-radius: 100px;
    font-size: 13px;
    font-weight: 600;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    color: var(--text-secondary);
}

.rr-verdict.good {
    background: var(--green-bg);
    border-color: var(--green-border);
    color: var(--green);
}

.rr-verdict.bad {
    background: var(--red-bg);
    border-color: var(--red-border);
    color: var(--red);
}

.rr-verdict.warn {
    background: var(--amber-bg);
    border-color: rgba(245,158,11,0.25);
    color: var(--amber);
}

/* Detail items */
.results-details {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1px;
    background: var(--glass-border);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    overflow: hidden;
    margin-bottom: 20px;
}

.detail-item {
    background: var(--glass-bg);
    padding: 16px 18px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.detail-item .label {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-muted);
}

.detail-item .value {
    font-size: 18px;
    font-weight: 700;
    font-family: 'DM Mono', monospace;
    color: var(--text-primary);
}

.detail-item .value.risk  { color: var(--red); }
.detail-item .value.reward { color: var(--green); }

/* Visual bar */
.rr-visual {
    margin-top: 4px;
}

.rr-bar-container {
    position: relative;
    height: 12px;
    border-radius: 100px;
    overflow: hidden;
    background: var(--bg-secondary);
    display: flex;
}

.rr-bar-risk {
    height: 100%;
    background: var(--red);
    transition: width 0.4s var(--ease-out);
    border-radius: 100px 0 0 100px;
}

.rr-bar-reward {
    height: 100%;
    background: var(--green);
    transition: width 0.4s var(--ease-out);
    border-radius: 0 100px 100px 0;
}

.rr-bar-entry {
    position: absolute;
    top: -2px;
    width: 3px;
    height: calc(100% + 4px);
    background: #fff;
    border-radius: 2px;
    transform: translateX(-50%);
    box-shadow: 0 0 4px rgba(0,0,0,0.5);
    transition: left 0.4s var(--ease-out);
}

.rr-bar-labels {
    display: flex;
    justify-content: space-between;
    margin-top: 8px;
    font-size: 11px;
    color: var(--text-muted);
    font-family: 'DM Mono', monospace;
}

/* Winrate table */
.winrate-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
    margin-top: 16px;
    border-radius: var(--radius-md);
    overflow: hidden;
    border: 1px solid var(--glass-border);
}

.winrate-table thead th {
    padding: 12px 16px;
    background: var(--bg-secondary);
    color: var(--text-muted);
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    text-align: left;
    border-bottom: 1px solid var(--glass-border);
}

.winrate-table tbody td {
    padding: 12px 16px;
    color: var(--text-secondary);
    border-bottom: 1px solid var(--glass-border);
    font-family: 'DM Mono', monospace;
}

.winrate-table tbody tr:last-child td { border-bottom: none; }

.winrate-table tbody tr:nth-child(even) td {
    background: var(--glass-bg);
}

.winrate-table tbody tr:hover td {
    background: var(--glass-bg-hover);
    color: var(--text-primary);
}

@media (max-width: 500px) {
    .results-details { grid-template-columns: 1fr; }
    .rr-value { font-size: 40px; }
    .trade-type-toggle { flex-direction: row; }
}

/* ============================================
   Tabs (Break-Even, Fibonacci, Pivot, etc.)
   ============================================ */
.tabs {
    display: flex;
    gap: 4px;
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    padding: 4px;
    margin-bottom: 28px;
}

.tab-btn {
    flex: 1;
    padding: 9px 12px;
    background: transparent;
    border: none;
    border-radius: calc(var(--radius-md) - 4px);
    color: var(--text-secondary);
    font-size: 13px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: background 0.15s, color 0.15s;
    white-space: nowrap;
}

.tab-btn.active {
    background: var(--glass-bg);
    color: var(--text-primary);
    box-shadow: var(--shadow-sm);
}

.tab-content { display: none; }
.tab-content.active { display: block; }

/* Method tabs (Pivot calculator) */
.method-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 24px;
}

.method-tab {
    padding: 7px 16px;
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    border-radius: 100px;
    color: var(--text-secondary);
    font-size: 13px;
    font-weight: 500;
    font-family: inherit;
    cursor: pointer;
    transition: background 0.15s, border-color 0.15s, color 0.15s;
}

.method-tab.active {
    background: var(--accent-subtle);
    border-color: var(--accent);
    color: var(--accent);
}

/* Results tabs (Fibonacci) */
.results-tabs {
    display: flex;
    gap: 4px;
    margin-bottom: 20px;
}

.results-tab {
    padding: 7px 18px;
    background: transparent;
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    font-size: 13px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.15s;
}

.results-tab.active {
    background: var(--accent-subtle);
    border-color: var(--accent);
    color: var(--accent);
}

.levels-container { display: none; }
.levels-container.active { display: block; }

/* ============================================
   Break-Even Display
   ============================================ */
.be-display {
    text-align: center;
    padding: 28px 0 20px;
}

.be-label {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text-muted);
    margin-bottom: 8px;
}

.be-value {
    font-size: 48px;
    font-weight: 700;
    font-family: 'DM Mono', monospace;
    color: var(--text-primary);
    letter-spacing: -0.03em;
    line-height: 1;
    margin-bottom: 10px;
}

.be-subtitle {
    font-size: 13px;
    color: var(--text-muted);
}

/* Shared table style (be-table, lots-table, pip-table-grid style, info-table, etc.) */
.be-table,
.lots-table,
.info-table,
.example-table,
.reference-table,
.comparison-table,
.leverage-table,
.levels-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
    margin-top: 16px;
    border-radius: var(--radius-md);
    overflow: hidden;
    border: 1px solid var(--glass-border);
}

.be-table thead th,
.lots-table thead th,
.info-table thead th,
.example-table thead th,
.reference-table thead th,
.comparison-table thead th,
.leverage-table thead th,
.levels-table thead th {
    padding: 11px 14px;
    background: var(--bg-secondary);
    color: var(--text-muted);
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    text-align: left;
    border-bottom: 1px solid var(--glass-border);
}

.be-table tbody td,
.lots-table tbody td,
.info-table tbody td,
.example-table tbody td,
.reference-table tbody td,
.comparison-table tbody td,
.leverage-table tbody td,
.levels-table tbody td {
    padding: 11px 14px;
    color: var(--text-secondary);
    border-bottom: 1px solid var(--glass-border);
    font-family: 'DM Mono', monospace;
    font-size: 13px;
}

.be-table tbody tr:last-child td,
.lots-table tbody tr:last-child td,
.info-table tbody tr:last-child td,
.example-table tbody tr:last-child td,
.reference-table tbody tr:last-child td,
.comparison-table tbody tr:last-child td,
.leverage-table tbody tr:last-child td,
.levels-table tbody tr:last-child td { border-bottom: none; }

.be-table tbody tr:nth-child(even) td,
.lots-table tbody tr:nth-child(even) td,
.info-table tbody tr:nth-child(even) td,
.example-table tbody tr:nth-child(even) td,
.reference-table tbody tr:nth-child(even) td,
.comparison-table tbody tr:nth-child(even) td,
.leverage-table tbody tr:nth-child(even) td,
.levels-table tbody tr:nth-child(even) td { background: var(--glass-bg); }

/* Highlighted row (pivot support/resistance) */
.levels-table .highlight td { color: var(--accent); font-weight: 600; background: var(--accent-subtle); }
.levels-table .resistance td { color: var(--red); }
.levels-table .support td { color: var(--green); }
.levels-table .pivot td { color: var(--accent); font-weight: 700; }

/* ============================================
   Compound Calculator — Chart & Milestones
   ============================================ */
.chart-container {
    margin-top: 24px;
}

.chart-title {
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-muted);
    margin-bottom: 12px;
}

.chart {
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    padding: 16px;
    overflow: hidden;
}

.chart-bars {
    display: flex;
    align-items: flex-end;
    gap: 4px;
    height: 120px;
}

.chart-bar-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    height: 100%;
    justify-content: flex-end;
    gap: 4px;
}

.chart-bar {
    width: 100%;
    background: var(--accent);
    border-radius: 3px 3px 0 0;
    transition: height 0.5s var(--ease-out);
    min-height: 4px;
    opacity: 0.85;
}

.chart-bar-value {
    font-size: 9px;
    color: var(--text-muted);
    font-family: 'DM Mono', monospace;
    white-space: nowrap;
}

.chart-bar-label {
    font-size: 9px;
    color: var(--text-muted);
    text-align: center;
}

.milestones {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 16px;
}

.milestone {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-sm);
}

.milestone-icon {
    width: 32px;
    height: 32px;
    background: var(--accent-subtle);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent);
    flex-shrink: 0;
    font-size: 16px;
}

.milestone-text { flex: 1; }

.milestone-label {
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 2px;
}

.milestone-value {
    font-size: 15px;
    font-weight: 700;
    font-family: 'DM Mono', monospace;
    color: var(--green);
}

.warning-box {
    background: var(--amber-bg);
    border: 1px solid rgba(245, 158, 11, 0.25);
    border-radius: var(--radius-md);
    padding: 16px 20px;
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.6;
    margin: 16px 0;
}

/* ============================================
   Crypto Profit Calculator
   ============================================ */
.crypto-select {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
    margin-bottom: 24px;
}

.crypto-btn {
    padding: 7px 18px;
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    border-radius: 100px;
    color: var(--text-secondary);
    font-size: 13px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.15s;
}

.crypto-btn.active {
    background: var(--accent-subtle);
    border-color: var(--accent);
    color: var(--accent);
}

.calc-section-title {
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    color: var(--text-muted);
    margin-bottom: 14px;
    margin-top: 20px;
}

.divider {
    height: 1px;
    background: var(--glass-border);
    margin: 20px 0;
}

/* Crypto result cards grid */
.result-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    padding: 20px;
    text-align: center;
}

.result-card.profit { border-color: var(--green-border); }
.result-card.loss   { border-color: var(--red-border); }

.result-value.profit { color: var(--green); }
.result-value.loss   { color: var(--red); }

.investment-value,
.exit-value {
    font-size: 24px;
    font-weight: 700;
    font-family: 'DM Mono', monospace;
    color: var(--text-primary);
}

.investment-sub,
.exit-sub {
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 4px;
}

.summary-box {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    padding: 20px;
    margin-top: 20px;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid var(--glass-border);
    font-size: 14px;
}

.summary-row:last-child { border-bottom: none; }
.summary-row.total { font-weight: 700; padding-top: 12px; }

.summary-label { color: var(--text-secondary); }
.summary-value { font-family: 'DM Mono', monospace; color: var(--text-primary); font-weight: 600; }
.summary-value.profit { color: var(--green); }
.summary-value.loss   { color: var(--red); }

/* Info sections (used in crypto, currency, etc.) */
.info-section {
    margin: 32px 0;
}

.info-section h2 {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 16px;
    letter-spacing: -0.01em;
}

.crypto-cards {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 12px;
    margin: 16px 0;
}

.crypto-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    padding: 16px;
    display: flex;
    gap: 12px;
    align-items: flex-start;
}

.crypto-card-icon {
    font-size: 24px;
    line-height: 1;
    flex-shrink: 0;
}

.crypto-card-info h3 {
    font-size: 14px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.crypto-card-info p {
    font-size: 12px;
    color: var(--text-muted);
    line-height: 1.4;
}

.tips-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin: 16px 0;
}

.tips-list li {
    padding: 12px 16px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-sm);
    font-size: 14px;
    color: var(--text-secondary);
    list-style: none;
    line-height: 1.5;
}

/* ============================================
   Currency Converter
   ============================================ */
.converter-layout {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.currency-row {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 12px;
    align-items: end;
}

.currency-input-wrapper {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.currency-input-wrapper input,
.currency-input-wrapper select {
    padding: 11px 14px;
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-size: 14px;
    font-family: inherit;
    outline: none;
    transition: border-color 0.15s;
}

.currency-input-wrapper input:focus,
.currency-input-wrapper select:focus { border-color: var(--accent); }

.swap-btn-container {
    display: flex;
    align-items: center;
    padding-bottom: 2px;
}

.swap-btn {
    width: 38px;
    height: 38px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s;
}

.swap-btn:hover {
    background: var(--accent-subtle);
    border-color: var(--accent);
    color: var(--accent);
}

.swap-btn i { width: 16px; height: 16px; }

.result-box {
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    padding: 20px;
    text-align: center;
}

.result-rate {
    font-size: 28px;
    font-weight: 700;
    font-family: 'DM Mono', monospace;
    color: var(--text-primary);
    margin-bottom: 6px;
}

.result-inverse {
    font-size: 12px;
    color: var(--text-muted);
}

.quick-amounts {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 8px;
}

.quick-btn {
    padding: 5px 14px;
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    border-radius: 100px;
    color: var(--text-secondary);
    font-size: 13px;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.15s;
}

.quick-btn:hover, .quick-btn.active {
    background: var(--accent-subtle);
    border-color: var(--accent);
    color: var(--accent);
}

.popular-pairs {
    margin-top: 16px;
}

.popular-pairs h3 {
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    color: var(--text-muted);
    margin-bottom: 10px;
}

.pairs-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 8px;
}

.pair-btn {
    padding: 10px 12px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-sm);
    cursor: pointer;
    text-align: left;
    transition: all 0.15s;
    font-family: inherit;
}

.pair-btn:hover {
    background: var(--glass-bg-hover);
    border-color: var(--accent);
}

.pair-name {
    font-size: 13px;
    font-weight: 700;
    color: var(--text-primary);
    font-family: 'DM Mono', monospace;
}

.pair-rate {
    font-size: 11px;
    color: var(--text-muted);
    margin-top: 2px;
}

.rate-note {
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 10px;
    font-style: italic;
}

.currency-groups {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin: 16px 0;
}

@media (max-width: 640px) {
    .currency-groups {
        grid-template-columns: 1fr;
    }
}

.currency-group {
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    padding: 16px;
}

.currency-group h4 {
    font-size: 13px;
    font-weight: 600;
    color: var(--accent);
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.currency-group h3 {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.currency-group ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.currency-group ul li {
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.4;
}

.currency-group p {
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.6;
}

.sessions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 10px;
    margin: 16px 0;
}

.session-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    padding: 16px;
}

.session-name {
    font-size: 14px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.session-time {
    font-size: 12px;
    color: var(--text-muted);
    font-family: 'DM Mono', monospace;
}

@media (max-width: 560px) {
    .currency-row { grid-template-columns: 1fr; }
    .swap-btn-container { justify-content: center; }
}

/* ============================================
   Drawdown Calculator
   ============================================ */
.recovery-display {
    text-align: center;
    padding: 24px 0 16px;
}

.recovery-label {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text-muted);
    margin-bottom: 8px;
}

.recovery-value {
    font-size: 52px;
    font-weight: 700;
    font-family: 'DM Mono', monospace;
    color: var(--red);
    letter-spacing: -0.03em;
    line-height: 1;
    margin-bottom: 8px;
}

.recovery-value.safe   { color: var(--green); }
.recovery-value.warn   { color: var(--amber); }
.recovery-value.danger { color: var(--red); }

.recovery-subtitle {
    font-size: 13px;
    color: var(--text-muted);
}

.drawdown-visual {
    margin-top: 20px;
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    padding: 20px;
}

.visual-title {
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-muted);
    margin-bottom: 16px;
}

.visual-bars {
    display: flex;
    align-items: flex-end;
    gap: 12px;
    height: 130px;
}

.visual-bar {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
    justify-content: flex-end;
}

.bar {
    width: 100%;
    border-radius: 4px 4px 0 0;
    transition: height 0.5s var(--ease-out);
    min-height: 4px;
}

.bar.bar-peak    { background: var(--text-muted); height: 100px; }
.bar.bar-current { background: var(--red); height: 5px; }
.bar.bar-recovery { background: var(--green); height: 100px; }

.bar-label {
    font-size: 11px;
    color: var(--text-muted);
    text-align: center;
}

.bar-value {
    font-size: 12px;
    font-weight: 700;
    font-family: 'DM Mono', monospace;
    color: var(--text-primary);
    text-align: center;
}

.visual-arrow {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    gap: 4px;
    color: var(--text-muted);
    font-size: 12px;
    padding-bottom: 30px;
    flex-shrink: 0;
}

/* ============================================
   Fibonacci Calculator
   ============================================ */
.trend-toggle {
    display: flex;
    gap: 8px;
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    padding: 4px;
    margin-bottom: 20px;
}

.trend-btn {
    flex: 1;
    padding: 9px 12px;
    background: transparent;
    border: none;
    border-radius: calc(var(--radius-md) - 4px);
    color: var(--text-secondary);
    font-size: 13px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.15s;
}

.trend-btn.active {
    background: var(--glass-bg);
    color: var(--accent);
    box-shadow: var(--shadow-sm);
}

.fib-sequence {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin: 12px 0;
}

.fib-number {
    padding: 4px 10px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-sm);
    font-size: 13px;
    font-family: 'DM Mono', monospace;
    color: var(--text-muted);
}

.fib-number.golden {
    background: var(--amber-bg);
    border-color: rgba(245, 158, 11, 0.3);
    color: var(--amber);
    font-weight: 600;
}

.levels-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 10px;
    margin: 12px 0;
}

.level-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    padding: 14px;
    text-align: center;
}

.level-pct {
    font-size: 18px;
    font-weight: 700;
    font-family: 'DM Mono', monospace;
    color: var(--accent);
    margin-bottom: 4px;
}

.level-desc {
    font-size: 12px;
    color: var(--text-muted);
    line-height: 1.4;
}

/* ============================================
   Kelly Criterion
   ============================================ */
.kelly-display {
    text-align: center;
    padding: 24px 0 16px;
}

.kelly-label {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text-muted);
    margin-bottom: 8px;
}

.kelly-value {
    font-size: 52px;
    font-weight: 700;
    font-family: 'DM Mono', monospace;
    color: var(--green);
    letter-spacing: -0.03em;
    line-height: 1;
    margin-bottom: 10px;
}

.kelly-value.negative { color: var(--red); }

.kelly-subtitle {
    font-size: 13px;
    color: var(--text-muted);
    margin-bottom: 20px;
}

.kelly-variants {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    margin-top: 4px;
}

.kelly-variant {
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    padding: 14px;
    text-align: center;
}

.variant-label {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-muted);
    margin-bottom: 6px;
}

.variant-value {
    font-size: 20px;
    font-weight: 700;
    font-family: 'DM Mono', monospace;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.variant-risk {
    font-size: 12px;
    color: var(--text-muted);
}

.edge-indicator {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    border-radius: var(--radius-md);
    font-size: 14px;
    font-weight: 600;
    margin-top: 16px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    color: var(--text-secondary);
}

.edge-indicator.positive {
    background: var(--green-bg);
    border-color: var(--green-border);
    color: var(--green);
}

.edge-indicator.negative {
    background: var(--red-bg);
    border-color: var(--red-border);
    color: var(--red);
}

/* ============================================
   Margin Calculator
   ============================================ */
.margin-meter {
    margin-top: 20px;
}

.meter-label {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 8px;
}

.meter-bar {
    height: 10px;
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    border-radius: 100px;
    overflow: hidden;
    margin-bottom: 6px;
}

.meter-fill {
    height: 100%;
    border-radius: 100px;
    transition: width 0.5s var(--ease-out), background 0.3s;
    background: var(--green);
}

.meter-fill.safe    { background: var(--green); }
.meter-fill.warning { background: var(--amber); }
.meter-fill.danger  { background: var(--red); }

.meter-zones {
    display: flex;
    justify-content: space-between;
    font-size: 11px;
    color: var(--text-muted);
}

.margin-warning {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    border-radius: var(--radius-md);
    font-size: 13px;
    font-weight: 600;
    margin-top: 16px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    color: var(--text-secondary);
}

.margin-warning.safe    { background: var(--green-bg); border-color: var(--green-border); color: var(--green); }
.margin-warning.warning { background: var(--amber-bg); border-color: rgba(245,158,11,0.25); color: var(--amber); }
.margin-warning.danger  { background: var(--red-bg);   border-color: var(--red-border);   color: var(--red); }

.example-calc {
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    padding: 16px 20px;
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 2;
    font-family: 'DM Mono', monospace;
    margin: 12px 0;
}

/* ============================================
   Pivot Point Calculator
   ============================================ */
.pivot-visual {
    margin-top: 8px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.pivot-row {
    display: grid;
    grid-template-columns: 60px 1fr 100px;
    gap: 12px;
    align-items: center;
}

.pivot-label {
    font-size: 12px;
    font-weight: 700;
    font-family: 'DM Mono', monospace;
    color: var(--text-muted);
}

.pivot-label.resistance { color: var(--red); }
.pivot-label.support    { color: var(--green); }
.pivot-label.pivot      { color: var(--accent); }

.pivot-bar-container {
    height: 6px;
    background: var(--bg-secondary);
    border-radius: 100px;
    overflow: hidden;
}

.pivot-bar {
    height: 100%;
    border-radius: 100px;
    transition: width 0.4s var(--ease-out);
}

.pivot-bar.resistance { background: var(--red); }
.pivot-bar.support    { background: var(--green); }
.pivot-bar.pivot      { background: var(--accent); }

.pivot-price {
    font-size: 13px;
    font-family: 'DM Mono', monospace;
    color: var(--text-primary);
    font-weight: 600;
    text-align: right;
}

.method-cards {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 12px;
    margin: 16px 0;
}

.method-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    padding: 16px;
}

.method-card h3 {
    font-size: 14px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 6px;
}

.method-card p {
    font-size: 12px;
    color: var(--text-muted);
    line-height: 1.5;
}

/* ============================================
   Profit Calculator — result-icon, profit-display
   ============================================ */
.result-icon {
    width: 36px;
    height: 36px;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.result-icon i { width: 18px; height: 18px; }

.results.profit .result-icon { background: var(--green-bg); color: var(--green); }
.results.loss   .result-icon { background: var(--red-bg);   color: var(--red); }

.profit-display {
    text-align: center;
    padding: 24px 0 16px;
}

.profit-label {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text-muted);
    margin-bottom: 8px;
}

.profit-value {
    font-size: 48px;
    font-weight: 700;
    font-family: 'DM Mono', monospace;
    color: var(--green);
    letter-spacing: -0.03em;
    line-height: 1;
    margin-bottom: 8px;
    transition: color 0.3s;
}

.results.loss .profit-value { color: var(--red); }

.profit-pips {
    font-size: 14px;
    color: var(--text-muted);
}

/* ============================================
   Pip Calculator — pip-table
   ============================================ */
.pip-table {
    margin-top: 20px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    padding: 16px;
}

.pip-table-title {
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-muted);
    margin-bottom: 12px;
}

.pip-table-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
}

.pip-table-item {
    text-align: center;
    padding: 10px;
    background: var(--bg-secondary);
    border-radius: var(--radius-sm);
}

/* ============================================
   30-Day Audit
   ============================================ */
.subtitle {
    font-size: 16px;
    color: var(--text-secondary);
    max-width: 540px;
    margin: 0 auto 24px;
    line-height: 1.6;
}

.preview-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    padding: 28px;
    margin-bottom: 24px;
}

.preview-title {
    font-size: 14px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    color: var(--accent);
    margin-bottom: 16px;
}

.week-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.week-item {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 14px;
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-sm);
}

.week-num {
    width: 28px;
    height: 28px;
    background: var(--accent-subtle);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 700;
    color: var(--accent);
    flex-shrink: 0;
}

.week-info h3 {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 3px;
}

.week-info p {
    font-size: 12px;
    color: var(--text-muted);
    line-height: 1.4;
}

.features {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 10px;
    margin-bottom: 28px;
}

.feature {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-sm);
    font-size: 13px;
    color: var(--text-secondary);
}

.feature i { width: 16px; height: 16px; color: var(--accent); flex-shrink: 0; }

.gate-section {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    padding: 36px;
    text-align: center;
    margin-bottom: 24px;
}

.gate-section h2 {
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 10px;
}

.gate-section p {
    color: var(--text-secondary);
    font-size: 15px;
    margin-bottom: 20px;
}

.btn-download {
    padding: 13px 28px;
    background: var(--accent);
    color: #fff;
    border: none;
    border-radius: var(--radius-md);
    font-size: 15px;
    font-weight: 700;
    font-family: inherit;
    cursor: pointer;
    transition: opacity 0.2s, transform 0.2s;
}

.btn-download:hover { opacity: 0.88; transform: translateY(-1px); }

.email-note {
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 10px;
}

.success-msg {
    display: none;
    padding: 14px 20px;
    background: var(--green-bg);
    border: 1px solid var(--green-border);
    border-radius: var(--radius-md);
    color: var(--green);
    font-weight: 600;
    font-size: 14px;
    margin-top: 14px;
}

.success-msg.visible { display: block; }

.social-proof {
    text-align: center;
    font-size: 13px;
    color: var(--text-muted);
    margin-bottom: 24px;
}

.cta-banner {
    background: linear-gradient(135deg, rgba(77,171,154,0.08) 0%, rgba(77,171,154,0.02) 100%);
    border: 1px solid rgba(77,171,154,0.25);
    border-radius: var(--radius-lg);
    padding: 32px;
    text-align: center;
    margin-bottom: 48px;
}

.cta-banner h3 {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 8px;
}

.cta-banner p {
    font-size: 14px;
    color: var(--text-secondary);
    margin-bottom: 20px;
}

.btn-pro {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    background: var(--accent);
    color: #fff;
    border: none;
    border-radius: var(--radius-md);
    font-size: 14px;
    font-weight: 700;
    font-family: inherit;
    cursor: pointer;
    text-decoration: none;
    transition: opacity 0.2s, transform 0.2s;
}

.btn-pro:hover { opacity: 0.88; transform: translateY(-1px); }

/* ============================================
   Remove Worst Trades
   ============================================ */
.upload-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    padding: 32px;
    margin-bottom: 24px;
}

.upload-card-title {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.upload-card-desc {
    font-size: 14px;
    color: var(--text-secondary);
    margin-bottom: 24px;
    line-height: 1.6;
}

.drop-zone {
    border: 2px dashed var(--glass-border);
    border-radius: var(--radius-md);
    padding: 40px;
    text-align: center;
    cursor: pointer;
    transition: border-color 0.15s, background 0.15s;
    position: relative;
}

.drop-zone:hover,
.drop-zone.dragover {
    border-color: var(--accent);
    background: var(--accent-subtle);
}

.drop-zone input[type="file"] {
    position: absolute;
    inset: 0;
    opacity: 0;
    cursor: pointer;
    width: 100%;
    height: 100%;
}

.drop-zone-icon {
    width: 48px;
    height: 48px;
    background: var(--accent-subtle);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 14px;
    color: var(--accent);
}

.drop-zone-icon i { width: 22px; height: 22px; }

.drop-zone-text {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.drop-zone-hint {
    font-size: 13px;
    color: var(--text-muted);
}

.mapping-section {
    display: none;
    margin-top: 24px;
}

.mapping-section.visible { display: block; }

.file-info {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-sm);
    margin-bottom: 16px;
}

.file-info-left {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 14px;
    color: var(--text-primary);
    font-weight: 500;
}

.file-info-reset {
    font-size: 13px;
    color: var(--text-muted);
    cursor: pointer;
    background: none;
    border: none;
    font-family: inherit;
    transition: color 0.15s;
}

.file-info-reset:hover { color: var(--red); }

.preview-table {
    width: 100%;
    overflow-x: auto;
    margin-bottom: 20px;
}

.preview-table table {
    width: 100%;
    border-collapse: collapse;
    font-size: 12px;
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-sm);
    overflow: hidden;
}

.preview-table th {
    padding: 8px 12px;
    background: var(--bg-secondary);
    color: var(--text-muted);
    font-weight: 600;
    text-align: left;
    border-bottom: 1px solid var(--glass-border);
}

.preview-table td {
    padding: 7px 12px;
    color: var(--text-secondary);
    border-bottom: 1px solid var(--glass-border);
    font-family: 'DM Mono', monospace;
}

.mapping-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 12px;
    margin-bottom: 20px;
}

.mapping-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.mapping-label {
    font-size: 12px;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.mapping-label .required {
    color: var(--accent);
    margin-left: 3px;
}

.mapping-select {
    padding: 9px 12px;
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-size: 13px;
    font-family: inherit;
    outline: none;
    transition: border-color 0.15s;
}

.mapping-select:focus { border-color: var(--accent); }

.slider-section {
    margin-bottom: 20px;
}

.slider-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.slider-label {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
}

.slider-value {
    font-size: 14px;
    font-weight: 700;
    font-family: 'DM Mono', monospace;
    color: var(--accent);
}

.slider-input {
    width: 100%;
    accent-color: var(--accent);
    cursor: pointer;
    height: 6px;
}

.btn-analyze {
    width: 100%;
    padding: 14px;
    background: var(--accent);
    color: #fff;
    border: none;
    border-radius: var(--radius-md);
    font-size: 15px;
    font-weight: 700;
    font-family: inherit;
    cursor: pointer;
    transition: opacity 0.2s, transform 0.15s;
}

.btn-analyze:hover { opacity: 0.88; transform: translateY(-1px); }

/* Results */
.impact-banner {
    background: linear-gradient(135deg, rgba(34,197,94,0.08) 0%, rgba(34,197,94,0.02) 100%);
    border: 1px solid var(--green-border);
    border-radius: var(--radius-lg);
    padding: 32px;
    text-align: center;
    margin-bottom: 24px;
}

.impact-banner.negative {
    background: linear-gradient(135deg, rgba(239,68,68,0.08) 0%, rgba(239,68,68,0.02) 100%);
    border-color: var(--red-border);
}

.impact-headline {
    font-size: 14px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text-muted);
    margin-bottom: 8px;
}

.impact-number {
    font-size: 52px;
    font-weight: 700;
    font-family: 'DM Mono', monospace;
    color: var(--green);
    letter-spacing: -0.03em;
    line-height: 1;
    margin-bottom: 8px;
}

.impact-banner.negative .impact-number { color: var(--red); }

.impact-sub {
    font-size: 14px;
    color: var(--text-muted);
}

.comparison-grid {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 12px;
    align-items: center;
    margin-bottom: 24px;
}

.comparison-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    padding: 20px;
}

.comparison-card.before { border-color: var(--red-border); }
.comparison-card.after  { border-color: var(--green-border); }

.comparison-card-label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 12px;
}

.comparison-card-label i,
.comparison-card-label svg {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
}

.comparison-card.before .comparison-card-label { color: var(--red); }
.comparison-card.after  .comparison-card-label { color: var(--green); }

.comparison-arrow {
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    font-size: 20px;
}

.comparison-arrow i { width: 22px; height: 22px; }

.stat-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 6px 0;
    border-bottom: 1px solid var(--glass-border);
    font-size: 13px;
}

.stat-row:last-child { border-bottom: none; }
.stat-label { color: var(--text-muted); }
.stat-value { font-family: 'DM Mono', monospace; font-weight: 600; color: var(--text-primary); }

.removed-trades {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    padding: 20px;
    margin-bottom: 24px;
}

.removed-trades-title {
    font-size: 14px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.removed-trade-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 12px;
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-sm);
    margin-bottom: 8px;
}

.removed-trade-item:last-child { margin-bottom: 0; }

.removed-trade-info {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 13px;
    color: var(--text-secondary);
}

.removed-trade-rank {
    width: 22px;
    height: 22px;
    background: var(--red-bg);
    border: 1px solid var(--red-border);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 700;
    color: var(--red);
    flex-shrink: 0;
}

.removed-trade-pnl {
    font-family: 'DM Mono', monospace;
    font-weight: 700;
    color: var(--red);
    font-size: 14px;
}

@media (max-width: 600px) {
    .comparison-grid { grid-template-columns: 1fr; }
    .comparison-arrow { transform: rotate(90deg); }
    .kelly-variants { grid-template-columns: 1fr; }
    .pivot-row { grid-template-columns: 50px 1fr 80px; }
}

/* ============================================
   Info Section (h2 with icon inside)
   ============================================ */
.info-section h2 {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 22px;
    font-weight: 700;
    letter-spacing: -0.01em;
    margin-bottom: 16px;
    color: var(--text-primary);
}

.info-section h2 i { width: 22px; height: 22px; color: var(--accent); flex-shrink: 0; }

.info-section h3 {
    font-size: 16px;
    font-weight: 700;
    color: var(--text-primary);
    margin: 24px 0 10px;
}

.info-section p {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.7;
}

/* formula-box code lines */
.formula-box code {
    display: block;
    font-family: 'DM Mono', monospace;
    font-size: 13px;
    color: var(--accent);
    line-height: 2;
}

/* ============================================
   Crypto results-grid (3-col card grid)
   ============================================ */
.results-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin: 20px 0;
}

.result-label {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    color: var(--text-muted);
    margin-bottom: 6px;
}

.result-value {
    font-size: 22px;
    font-weight: 700;
    font-family: 'DM Mono', monospace;
    color: var(--text-primary);
    line-height: 1.2;
}

.result-sub {
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 4px;
}

@media (max-width: 560px) {
    .results-grid { grid-template-columns: 1fr; }
}

/* ============================================
   Level table cell classes (JS-generated)
   ============================================ */
.level-name {
    font-family: 'DM Mono', monospace;
    font-weight: 700;
    font-size: 13px;
    color: var(--text-primary);
}

.level-name.golden     { color: var(--amber); }
.level-name.resistance { color: var(--red); }
.level-name.support    { color: var(--green); }
.level-name.pivot      { color: var(--accent); }
.level-name.target     { color: var(--accent); }
.level-name.base       { color: var(--text-muted); }

.level-price {
    font-family: 'DM Mono', monospace;
    font-size: 13px;
    color: var(--text-primary);
    font-weight: 600;
}

.level-distance {
    font-family: 'DM Mono', monospace;
    font-size: 12px;
    color: var(--text-muted);
}

.level-type {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 100px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.level-type.resistance { background: var(--red-bg);   color: var(--red);   border: 1px solid var(--red-border); }
.level-type.support    { background: var(--green-bg); color: var(--green); border: 1px solid var(--green-border); }
.level-type.pivot      { background: var(--accent-subtle); color: var(--accent); border: 1px solid rgba(77,171,154,0.25); }
.level-type.target     { background: var(--amber-bg); color: var(--amber); border: 1px solid rgba(245,158,11,0.25); }
.level-type.base       { background: var(--glass-bg); color: var(--text-muted); border: 1px solid var(--glass-border); }

/* ============================================
   calc-section-title with icon
   ============================================ */
.calc-section-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    color: var(--text-muted);
    margin-bottom: 14px;
    margin-top: 20px;
}

.calc-section-title i { width: 16px; height: 16px; color: var(--accent); }

/* ============================================
   results-header flex (icon + h3 + tabs)
   ============================================ */
.results-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.results-header h3 {
    font-size: 16px;
    font-weight: 700;
    color: var(--text-primary);
    flex: 1;
    margin: 0;
}

.results-header i { width: 20px; height: 20px; color: var(--accent); flex-shrink: 0; }

/* ============================================
   tips-list with icon+span layout
   ============================================ */
.tips-list li {
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.tips-list li i { width: 18px; height: 18px; color: var(--green); flex-shrink: 0; margin-top: 2px; }
.tips-list li span { font-size: 14px; color: var(--text-secondary); line-height: 1.5; }

/* ============================================
   method-card / crypto-card h3/h4 fix
   ============================================ */
.method-card h3,
.method-card h4 {
    font-size: 14px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 6px;
}

.crypto-card-info h3,
.crypto-card-info h4 {
    font-size: 14px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 4px;
}

/* ============================================
   related-tools h2 (some files use h2 not h3)
   ============================================ */
.related-tools h2 {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 16px;
    letter-spacing: -0.01em;
}
