/* Learn Page Styles */
.learn-page .header {
    position: sticky;
    top: 1rem;
    z-index: 100;
}
.learn-page .logo {
    text-decoration: none;
    color: inherit;
}
.learn-content {
    max-width: 900px;
    margin: 0 auto;
    padding: 2rem;
}
.hero-section {
    text-align: center;
    padding: 3rem 1rem;
    margin-bottom: 2rem;
}
.hero-section h1 {
    font-size: 3rem;
    font-weight: 700;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 0.5rem;
}
.hero-section .subtitle {
    font-size: 1.25rem;
    color: var(--text-secondary);
}
/* Table of Contents */
.toc {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 1.5rem;
    margin-bottom: 3rem;
    position: sticky;
    top: 100px;
}
@media (max-width: 1200px) {
    .toc { position: static; }
}
.toc h3 {
    margin-bottom: 1rem;
    font-size: 1rem;
}
.toc ul {
    list-style: none;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 0.5rem;
}
.toc a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    padding: 0.4rem 0.75rem;
    border-radius: var(--radius-sm);
    display: block;
    transition: var(--transition);
}
.toc a:hover {
    background: var(--bg-card-hover);
    color: var(--accent-primary);
}
/* Articles */
.learn-article {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 2rem;
    margin-bottom: 2rem;
}
.learn-article h2 {
    font-size: 1.75rem;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
}
.article-content p {
    margin-bottom: 1rem;
    line-height: 1.8;
    color: var(--text-secondary);
}
.article-content strong {
    color: var(--text-primary);
}
/* Info/Fact/Example Boxes */
.info-box, .fact-box, .example-box, .history-box {
    background: var(--bg-card);
    border-radius: var(--radius-md);
    padding: 1.25rem;
    margin: 1.5rem 0;
    border-left: 4px solid var(--accent-primary);
}
.info-box h4, .fact-box h4, .example-box h4, .history-box h4 {
    margin-bottom: 0.75rem;
    color: var(--accent-primary);
    font-size: 1rem;
}
.info-box ul, .fact-box ul {
    list-style: none;
    margin-top: 0.5rem;
}
.info-box li, .fact-box li {
    padding: 0.25rem 0;
    color: var(--text-secondary);
}
.history-box {
    border-left-color: var(--accent-secondary);
    background: rgba(167,139,250,0.05);
}
.history-box h4 { color: var(--accent-secondary); }
.example-box {
    border-left-color: var(--success);
    background: rgba(52,211,153,0.05);
}
.example-box h4 { color: var(--success); }
/* Callouts */
.callout {
    display: flex;
    gap: 1rem;
    padding: 1rem;
    border-radius: var(--radius-md);
    margin: 1.5rem 0;
}
.callout-icon { font-size: 1.5rem; flex-shrink: 0; }
.callout p { margin: 0; color: var(--text-secondary); }
.callout.warning {
    background: rgba(251,191,36,0.1);
    border: 1px solid rgba(251,191,36,0.3);
}
.callout.success {
    background: rgba(52,211,153,0.1);
    border: 1px solid rgba(52,211,153,0.3);
}
.callout.info {
    background: rgba(96,165,250,0.1);
    border: 1px solid rgba(96,165,250,0.3);
}
/* Formula Display */
.formula-display {
    background: var(--bg-card);
    border-radius: var(--radius-md);
    padding: 1.5rem;
    margin: 1.5rem 0;
    border: 1px solid var(--border-color);
}
.formula-display h4 {
    margin-bottom: 1rem;
    color: var(--accent-primary);
}
.formula-math {
    font-family: 'JetBrains Mono', monospace;
    font-size: 1.1rem;
    color: var(--text-primary);
    line-height: 2;
    padding: 1rem;
    background: var(--bg-primary);
    border-radius: var(--radius-sm);
}
.formula-math p { margin-bottom: 0.25rem; }
.formula-legend {
    margin-top: 1rem;
    font-size: 0.9rem;
    color: var(--text-secondary);
}
.formula-legend ul { list-style: none; margin-top: 0.5rem; }
.formula-legend li { padding: 0.2rem 0; }
.formula-note {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-top: 0.75rem;
    font-style: italic;
}
/* Code Block */
.code-block {
    margin: 1.5rem 0;
}
.code-block h4 {
    margin-bottom: 0.75rem;
    font-size: 0.9rem;
    color: var(--text-secondary);
}
.code-block pre {
    background: #1e1e2e;
    border-radius: var(--radius-md);
    padding: 1.25rem;
    overflow-x: auto;
}
.code-block code {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.85rem;
    color: #cdd6f4;
    line-height: 1.6;
}
/* Comparison Grid */
.comparison-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin: 1.5rem 0;
}
.comparison-card {
    background: var(--bg-card);
    border-radius: var(--radius-md);
    padding: 1.5rem;
    border: 1px solid var(--border-color);
}
.comparison-card h4 {
    margin-bottom: 0.75rem;
    font-size: 1.1rem;
}
.comparison-card p {
    font-size: 0.9rem;
    margin-bottom: 1rem;
}
.pros-cons {
    list-style: none;
    font-size: 0.85rem;
}
.pros-cons li {
    padding: 0.3rem 0;
}
.pros-cons .pro { color: var(--success); }
.pros-cons .con { color: var(--error); }
/* Comparison Table */
.comparison-table {
    margin: 1.5rem 0;
    overflow-x: auto;
}
.comparison-table h4 {
    margin-bottom: 1rem;
}
.comparison-table table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}
.comparison-table th,
.comparison-table td {
    padding: 0.75rem 1rem;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}
.comparison-table th {
    background: var(--bg-card);
    font-weight: 600;
    color: var(--text-primary);
}
.comparison-table td {
    color: var(--text-secondary);
}
.comparison-table tr:hover td {
    background: var(--bg-card);
}
/* Method Comparison Cards */
.method-comparison {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1rem;
    margin: 1.5rem 0;
}
.method-card {
    background: var(--bg-card);
    border-radius: var(--radius-md);
    padding: 1.25rem;
    border: 1px solid var(--border-color);
    position: relative;
}
.method-card.recommended {
    border-color: var(--accent-primary);
    background: rgba(96,165,250,0.05);
}
.method-badge {
    position: absolute;
    top: -10px;
    right: 1rem;
    background: var(--accent-gradient);
    color: white;
    font-size: 0.7rem;
    font-weight: 600;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    text-transform: uppercase;
}
.method-card h4 {
    margin-bottom: 0.5rem;
    font-size: 1rem;
}
.method-card p {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-bottom: 0.75rem;
}
.method-stats {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}
.method-stats .stat {
    font-size: 0.8rem;
    color: var(--text-muted);
}
/* Bearing Diagram */
.bearing-diagram {
    display: flex;
    justify-content: center;
    margin: 2rem 0;
}
.compass-rose {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    background: var(--bg-card);
    border: 3px solid var(--border-color);
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}
.compass-rose .direction {
    position: absolute;
    font-weight: 700;
    text-align: center;
    font-size: 0.9rem;
    color: var(--text-secondary);
}
.compass-rose .n { top: 15px; color: var(--error); }
.compass-rose .e { right: 15px; }
.compass-rose .s { bottom: 15px; }
.compass-rose .w { left: 15px; }
/* Use Cases */
.use-cases {
    background: var(--bg-card);
    border-radius: var(--radius-md);
    padding: 1.25rem;
    margin: 1.5rem 0;
}
.use-cases h4 {
    margin-bottom: 0.75rem;
    color: var(--success);
}
.use-cases ul {
    list-style: none;
}
.use-cases li {
    padding: 0.3rem 0;
    color: var(--text-secondary);
    font-size: 0.9rem;
}
.use-cases li::before {
    content: "• ";
    color: var(--success);
}
/* References */
.reference-list {
    list-style: none;
}
.reference-list li {
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--border-color);
}
.reference-list li:last-child {
    border-bottom: none;
}
.reference-list a {
    color: var(--accent-primary);
    text-decoration: none;
    font-weight: 500;
}
.reference-list a:hover {
    text-decoration: underline;
}
.ref-author {
    display: block;
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-top: 0.25rem;
}
/* Responsive */
@media (max-width: 768px) {
    .learn-page .header {
        position: relative;
        top: 0;
    }
    .learn-content {
        padding: 1rem;
    }
    .hero-section {
        padding: 2rem 1rem;
    }
    .hero-section h1 { font-size: 2rem; }
    .learn-article { padding: 1.5rem 1rem; }
    .learn-article h2 { font-size: 1.4rem; }
    .toc ul {
        grid-template-columns: 1fr;
    }
}
