/* ===============================================
   Delta Robot Documentation Styles
   =============================================== */

/* Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #2563eb;
    --secondary-color: #8b5cf6;
    --success-color: #10b981;
    --warning-color: #f59e0b;
    --error-color: #ef4444;
    --bg-color: #ffffff;
    --text-color: #1f2937;
    --border-color: #e5e7eb;
    --code-bg: #1e293b;
    --code-text: #e2e8f0;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: #f9fafb;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Navigation */
.docs-nav {
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    color: white;
    padding: 20px 0;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.docs-nav .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-brand {
    color: white;
    text-decoration: none;
    font-size: 14px;
    opacity: 0.9;
    transition: opacity 0.3s;
}

.nav-brand:hover {
    opacity: 1;
}

.docs-nav h1 {
    font-size: 24px;
    font-weight: 600;
}

/* Hero Section */
.docs-hero {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 60px 20px;
    text-align: center;
}

.docs-hero h1 {
    font-size: 42px;
    font-weight: 700;
    margin-bottom: 15px;
}

.hero-subtitle {
    font-size: 18px;
    opacity: 0.95;
}

/* Documentation Content */
.docs-content {
    padding: 40px 20px;
}

/* Learning Paths */
.learning-paths {
    margin-bottom: 60px;
}

.learning-paths h2 {
    font-size: 32px;
    margin-bottom: 30px;
    text-align: center;
}

.paths-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.path-card {
    background: white;
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    transition: transform 0.3s, box-shadow 0.3s;
}

.path-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.12);
}

.path-card h3 {
    font-size: 22px;
    margin-bottom: 20px;
    color: var(--primary-color);
}

.path-card ol {
    margin-left: 20px;
}

.path-card li {
    margin-bottom: 10px;
}

/* Documentation Grid */
.docs-grid {
    margin-bottom: 60px;
}

.docs-grid h2 {
    font-size: 32px;
    margin-bottom: 30px;
    text-align: center;
}

.doc-cards {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 25px;
}

.doc-card {
    background: white;
    padding: 30px;
    border-radius: 12px;
    text-decoration: none;
    color: var(--text-color);
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    transition: all 0.3s;
    display: flex;
    flex-direction: column;
}

.doc-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.15);
}

.card-icon {
    font-size: 48px;
    margin-bottom: 15px;
}

.doc-card h3 {
    font-size: 20px;
    margin-bottom: 10px;
    color: var(--primary-color);
    min-height: 50px;
    line-height: 1.3;
}

.doc-card p {
    font-size: 14px;
    color: #6b7280;
    flex-grow: 1;
}

.card-time {
    display: block;
    margin-top: 15px;
    font-size: 13px;
    color: #9ca3af;
}

/* Quick Links */
.quick-links {
    margin-bottom: 60px;
}

.quick-links h2 {
    font-size: 32px;
    margin-bottom: 30px;
    text-align: center;
}

.links-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.quick-link {
    background: white;
    padding: 20px 30px;
    border-radius: 8px;
    text-decoration: none;
    color: var(--text-color);
    display: flex;
    align-items: center;
    gap: 15px;
    transition: all 0.3s;
}

.quick-link:hover {
    background: var(--primary-color);
    color: white;
}

.link-icon {
    font-size: 28px;
}

/* Documentation Page Layout */
.docs-page {
    display: grid;
    grid-template-columns: 250px 1fr;
    gap: 40px;
    padding: 40px 20px;
    max-width: 1200px;
    margin: 0 auto;
}

/* Sidebar */
.sidebar {
    background: white;
    padding: 25px;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    height: fit-content;
    position: sticky;
    top: 20px;
}

.sidebar h3 {
    font-size: 18px;
    margin-bottom: 15px;
    color: var(--primary-color);
}

.sidebar ul {
    list-style: none;
}

.sidebar li {
    margin-bottom: 10px;
}

.sidebar a {
    color: #6b7280;
    text-decoration: none;
    transition: color 0.3s;
}

.sidebar a:hover {
    color: var(--primary-color);
}

/* Main Content */
.content {
    background: white;
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.content h1 {
    font-size: 36px;
    margin-bottom: 15px;
    color: var(--primary-color);
    line-height: 1.3;
}

.lead {
    font-size: 18px;
    color: #6b7280;
    margin-bottom: 30px;
    line-height: 1.5;
}

.content h2 {
    font-size: 28px;
    margin: 40px 0 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--border-color);
    line-height: 1.3;
}

.content h3 {
    font-size: 22px;
    margin: 30px 0 15px;
    line-height: 1.3;
}

.content h4 {
    font-size: 18px;
    margin: 20px 0 10px;
    line-height: 1.3;
}

.content p {
    margin-bottom: 15px;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.content ul, .content ol {
    margin-left: 30px;
    margin-bottom: 20px;
}

.content li {
    margin-bottom: 8px;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

/* Info Boxes */
.info-box, .warning-box, .success-box, .help-box {
    padding: 20px;
    border-radius: 8px;
    margin: 25px 0;
    border-left: 4px solid;
}

.info-box {
    background: #eff6ff;
    border-color: var(--primary-color);
}

.warning-box {
    background: #fffbeb;
    border-color: var(--warning-color);
}

.success-box {
    background: #f0fdf4;
    border-color: var(--success-color);
}

.help-box {
    background: #faf5ff;
    border-color: var(--secondary-color);
}

/* Code Blocks */
.code-block {
    margin: 20px 0;
    border-radius: 8px;
    overflow: hidden;
}

.code-block pre {
    background: var(--code-bg);
    color: var(--code-text);
    padding: 20px;
    overflow-x: auto;
    margin: 0;
    font-family: 'Consolas', 'Monaco', monospace;
    font-size: 14px;
    line-height: 1.5;
}

code {
    background: #f3f4f6;
    padding: 2px 6px;
    border-radius: 4px;
    font-family: 'Consolas', 'Monaco', monospace;
    font-size: 0.9em;
    color: #e11d48;
}

pre code {
    background: transparent;
    padding: 0;
    color: inherit;
}

/* Tables */
table {
    width: 100%;
    border-collapse: collapse;
    margin: 25px 0;
    background: white;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

thead {
    background: var(--primary-color);
    color: white;
}

th, td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
    min-width: 80px;
    word-wrap: break-word;
}

tbody tr:hover {
    background: #f9fafb;
}

/* Images */
.placeholder-image {
    margin: 25px 0;
    text-align: center;
}

.placeholder-image img {
    max-width: 100%;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.placeholder-image.large img {
    cursor: pointer;
}

.caption {
    margin-top: 10px;
    font-size: 14px;
    color: #6b7280;
    font-style: italic;
}

/* Two Column Layout */
.two-column {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin: 20px 0;
}

/* Steps */
.step {
    margin: 30px 0;
    padding: 20px;
    background: #f9fafb;
    border-radius: 8px;
    border-left: 4px solid var(--primary-color);
}

.step h3 {
    margin-top: 0;
}

/* Checklist */
.checklist {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.checklist label {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
}

.checklist input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

/* FAQ Items */
.faq-item {
    margin: 30px 0;
    padding: 25px;
    background: white;
    border-radius: 8px;
    border: 1px solid var(--border-color);
}

.faq-item h3 {
    margin-top: 0;
    margin-bottom: 15px;
}

.problem, .causes, .solutions {
    margin: 15px 0;
}

.problem strong, .causes strong, .solutions strong {
    color: var(--primary-color);
}

/* Project Cards */
.project {
    margin: 50px 0;
    padding: 30px;
    background: #f9fafb;
    border-radius: 12px;
}

.project-meta {
    display: flex;
    gap: 15px;
    margin: 15px 0;
    flex-wrap: wrap;
}

.badge {
    display: inline-block;
    padding: 5px 12px;
    background: var(--primary-color);
    color: white;
    border-radius: 20px;
    font-size: 13px;
}

/* Next Section */
.next-section {
    margin: 50px 0;
    padding: 30px;
    text-align: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 12px;
}

.next-section h3 {
    margin-top: 0;
}

.btn-large {
    display: inline-block;
    padding: 12px 30px;
    background: white;
    color: var(--primary-color);
    text-decoration: none;
    border-radius: 8px;
    font-weight: 600;
    transition: transform 0.3s;
}

.btn-large:hover {
    transform: scale(1.05);
}

.next-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.next-card {
    background: white;
    padding: 20px;
    border-radius: 8px;
    text-decoration: none;
    color: var(--text-color);
    transition: transform 0.3s;
}

.next-card:hover {
    transform: translateY(-5px);
}

.next-card h3 {
    margin: 0 0 10px;
    color: var(--primary-color);
}

/* Footer */
.docs-footer {
    background: #1f2937;
    color: white;
    padding: 30px 20px;
    text-align: center;
    margin-top: 60px;
}

.docs-footer a {
    color: #60a5fa;
    text-decoration: none;
}

.docs-footer a:hover {
    text-decoration: underline;
}

.docs-footer p {
    margin: 10px 0;
}

/* Responsive Design */
@media (max-width: 768px) {
    .docs-page {
        grid-template-columns: 1fr;
    }
    
    .sidebar {
        position: static;
    }
    
    .content {
        padding: 20px;
    }
    
    .docs-hero h1 {
        font-size: 32px;
    }
    
    .two-column {
        grid-template-columns: 1fr;
    }
    
    .doc-cards {
        grid-template-columns: 1fr;
    }
    
    .paths-grid {
        grid-template-columns: 1fr;
    }
    
    table {
        font-size: 14px;
    }
    
    th, td {
        padding: 8px 10px;
    }
}

/* Print Styles */
@media print {
    .docs-nav, .sidebar, .docs-footer {
        display: none;
    }
    
    .content {
        box-shadow: none;
        padding: 0;
    }
    
    .code-block pre {
        border: 1px solid #ddd;
    }
}
