
:root {
    --primary-color: #1a5f7a;
    --secondary-color: #2d7d9a;
    --accent-color: #4ecdc4;
    --success-color: #28a745;
    --danger-color: #dc3545;
    --warning-color: #ffc107;
    --text-color: #e0e0e0;
    --text-muted: #a0a0a0;
    --bg-color: #0d1117;
    --card-bg: #161b22;
    --border-color: #30363d;
}

[data-theme="light"] {
    --text-color: #1a1a2e;
    --text-muted: #666;
    --bg-color: #f5f5f5;
    --card-bg: #ffffff;
    --border-color: #e0e0e0;
}

* {
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', -apple-system, BlinkMacSystemFont, sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    line-height: 1.7;
    margin: 0;
    padding: 0;
}

.guide-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 40px 20px;
}

.guide-header {
    text-align: center;
    margin-bottom: 50px;
    padding-bottom: 30px;
    border-bottom: 2px solid var(--primary-color);
}

.guide-header h1 {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 15px;
}

.guide-header .subtitle {
    font-size: 1.2rem;
    color: var(--text-muted);
}

.guide-header .ai-badge {
    display: inline-block;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    color: white;
    padding: 8px 20px;
    border-radius: 20px;
    font-size: 0.9rem;
    margin-top: 15px;
}

/* Table of Contents */
.toc {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 30px;
    margin-bottom: 50px;
}

.toc h2 {
    color: var(--primary-color);
    margin-top: 0;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--border-color);
}

.toc-list {
    list-style: none;
    padding: 0;
    margin: 0;
    columns: 2;
    column-gap: 40px;
}

@media (max-width: 768px) {
    .toc-list {
        columns: 1;
    }
}

.toc-list li {
    margin: 10px 0;
    break-inside: avoid;
}

.toc-list a {
    color: var(--text-color);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    border-radius: 6px;
    transition: all 0.2s;
}

.toc-list a:hover {
    background: var(--primary-color);
    color: white;
}

.toc-number {
    background: var(--primary-color);
    color: white;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    font-weight: bold;
    flex-shrink: 0;
}

/* Sections */
.section {
    margin-bottom: 60px;
}

.section h2 {
    color: var(--primary-color);
    font-size: 1.8rem;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--border-color);
}

.section h3 {
    color: var(--secondary-color);
    font-size: 1.4rem;
    margin-top: 35px;
    margin-bottom: 15px;
}

.section h4 {
    color: var(--accent-color);
    font-size: 1.15rem;
    margin-top: 25px;
    margin-bottom: 10px;
}

.section p {
    margin-bottom: 15px;
}

/* Info Boxes */
.info-box {
    background: var(--card-bg);
    border-left: 4px solid var(--primary-color);
    padding: 20px;
    margin: 20px 0;
    border-radius: 0 8px 8px 0;
}

.info-box.tip {
    border-left-color: var(--success-color);
}

.info-box.warning {
    border-left-color: var(--warning-color);
}

.info-box.example {
    border-left-color: var(--accent-color);
    background: rgba(78, 205, 196, 0.1);
}

.info-box h5 {
    margin: 0 0 10px 0;
    color: var(--primary-color);
    font-size: 1rem;
}

.info-box.tip h5 { color: var(--success-color); }
.info-box.warning h5 { color: var(--warning-color); }
.info-box.example h5 { color: var(--accent-color); }

/* Tables */
.data-table {
    width: 100%;
    border-collapse: collapse;
    margin: 20px 0;
    background: var(--card-bg);
    border-radius: 8px;
    overflow: hidden;
}

.data-table th,
.data-table td {
    padding: 14px 16px;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

.data-table th {
    background: var(--primary-color);
    color: white;
    font-weight: 600;
}

.data-table tr:hover {
    background: rgba(26, 95, 122, 0.1);
}

.data-table code {
    background: rgba(26, 95, 122, 0.2);
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 0.9em;
}

/* Signal Colors */
.bullish { color: var(--success-color); font-weight: 600; }
.bearish { color: var(--danger-color); font-weight: 600; }
.neutral { color: var(--warning-color); font-weight: 600; }

/* Data Point Cards */
.data-point-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    margin: 25px 0;
}

.data-point-card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    padding: 20px;
}

.data-point-card h5 {
    color: var(--accent-color);
    margin: 0 0 12px 0;
    font-size: 1rem;
    display: flex;
    align-items: center;
    gap: 8px;
}

.data-point-card p {
    margin: 0;
    font-size: 0.95rem;
    color: var(--text-muted);
}

.data-point-card .values {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid var(--border-color);
    font-size: 0.9rem;
}

.data-point-card .values span {
    display: inline-block;
    background: rgba(26, 95, 122, 0.2);
    padding: 3px 8px;
    border-radius: 4px;
    margin: 3px 3px 3px 0;
}

/* AI Section Highlight */
.ai-section {
    background: linear-gradient(135deg, rgba(26, 95, 122, 0.1), rgba(78, 205, 196, 0.1));
    border: 1px solid var(--accent-color);
    border-radius: 12px;
    padding: 30px;
    margin: 30px 0;
}

.ai-section h3 {
    display: flex;
    align-items: center;
    gap: 10px;
}

.ai-section h3::before {
    content: "🤖";
}

/* Lists */
ul, ol {
    margin: 15px 0;
    padding-left: 25px;
}

li {
    margin: 8px 0;
}

/* Code/Technical */
.formula {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    padding: 15px 20px;
    border-radius: 8px;
    font-family: 'Consolas', 'Monaco', monospace;
    overflow-x: auto;
    margin: 15px 0;
}

/* Timeframe Grid */
.timeframe-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 10px;
    margin: 20px 0;
}

@media (max-width: 768px) {
    .timeframe-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.timeframe-item {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    padding: 15px;
    border-radius: 8px;
    text-align: center;
}

.timeframe-item .tf-label {
    font-size: 1.2rem;
    font-weight: bold;
    color: var(--primary-color);
}

.timeframe-item .tf-desc {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-top: 5px;
}

/* Back to Top */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background: var(--primary-color);
    color: white;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    font-size: 1.5rem;
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
    transition: transform 0.3s;
}

.back-to-top:hover {
    transform: translateY(-5px);
}

/* Print Styles */
@media print {
    .back-to-top, .toc { display: none; }
    .section { page-break-inside: avoid; }
}

/* Referral Section */
.referral-section {
    background: linear-gradient(135deg, rgba(255, 193, 7, 0.1), rgba(26, 95, 122, 0.1));
    border: 1px solid var(--warning-color);
    border-radius: 12px;
    padding: 25px;
    margin: 30px 0;
}

.referral-section h3 {
    color: var(--warning-color);
    margin-top: 0;
    display: flex;
    align-items: center;
    gap: 10px;
}

.referral-section ul {
    list-style: none;
    padding: 0;
    margin: 15px 0 0 0;
}

.referral-section li {
    margin: 10px 0;
    padding-left: 0;
}

.referral-section a {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--text-color);
    text-decoration: none;
    padding: 10px 15px;
    background: rgba(26, 95, 122, 0.1);
    border-radius: 8px;
    transition: all 0.2s;
}

.referral-section a:hover {
    background: var(--primary-color);
    color: white;
    transform: translateX(5px);
}

/* Internal Links Section */
.internal-links-section {
    background: linear-gradient(135deg, rgba(78, 205, 196, 0.1), rgba(26, 95, 122, 0.1));
    border: 1px solid var(--accent-color);
    border-radius: 12px;
    padding: 25px;
    margin: 30px 0;
}

.internal-links-section h3 {
    color: var(--accent-color);
    margin-top: 0;
    margin-bottom: 20px;
    text-align: center;
}

.links-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
}

@media (max-width: 768px) {
    .links-grid {
        grid-template-columns: 1fr;
    }
}

.coin-link {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    text-decoration: none;
    color: var(--text-color);
    transition: all 0.3s ease;
}

.coin-link:hover {
    background: var(--primary-color);
    border-color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.coin-symbol {
    font-weight: bold;
    font-size: 1.2rem;
    background: rgba(78, 205, 196, 0.2);
    color: var(--accent-color);
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    flex-shrink: 0;
}

.coin-name {
    flex-grow: 1;
    font-size: 0.95rem;
}

/* Add specific colors for popular coins */
.coin-link[href*="/coin/BTC"] .coin-symbol {
    background: rgba(247, 147, 26, 0.2);
    color: #f7931a;
}

.coin-link[href*="/coin/ETH"] .coin-symbol {
    background: rgba(98, 126, 234, 0.2);
    color: #627eea;
}

.coin-link[href*="/coin/BNB"] .coin-symbol {
    background: rgba(243, 186, 47, 0.2);
    color: #f3ba2f;
}

.coin-link[href*="/coin/SOL"] .coin-symbol {
    background: rgba(0, 0, 0, 0.2);
    color: #000;
}

.coin-link[href*="/coin/XRP"] .coin-symbol {
    background: rgba(0, 162, 232, 0.2);
    color: #00a2e8;
}

.coin-link[href*="/coin/DOGE"] .coin-symbol {
    background: rgba(194, 177, 110, 0.2);
    color: #c2b16e;
}