/* Common styles for all help pages */
body { font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif; font-size: clamp(12px, 1.78vw, 16px); line-height: 1.6; color: #333; }
h1 { color: #2c5282; border-bottom: 2px solid #2c5282; padding-bottom: 10px; }
h2 { color: #2d3748; margin-top: 20px; }
h3 { color: #4a5568; margin-top: 15px; }
p { margin: 10px 0; }
ul { margin: 10px 0 10px 20px; }
li { margin: 5px 0; }
code { background-color: #edf2f7; padding: 2px 6px; border-radius: 3px; font-family: Consolas, monospace; font-weight: bold; }

/* Callout boxes */
.highlight { background-color: #ebf8ff; padding: 15px; border-radius: 5px; margin: 15px 0; }
.info { background-color: #ebf8ff; padding: 15px; border-left: 4px solid #4299e1; margin: 15px 0; }

/* Speech bubble styles for troubleshooting */
.problem { 
    background-color: #f0f0f0; 
    padding: 12px 16px; 
    border-radius: 18px 18px 18px 4px; 
    margin: 15px 40px 8px 0; 
    position: relative;
    box-shadow: 0 1px 2px rgba(0,0,0,0.1);
}
.solution { 
    background-color: #0084ff; 
    color: white; 
    padding: 12px 16px; 
    border-radius: 18px 18px 4px 18px; 
    margin: 8px 0 15px 40px; 
    position: relative;
    box-shadow: 0 1px 2px rgba(0,0,0,0.1);
}
.solution strong { color: white; }
.solution code { background-color: rgba(255,255,255,0.2); color: white; }

/* Step boxes */
.step { background-color: #f7fafc; padding: 15px; border-left: 4px solid #4299e1; margin: 15px 0; }

/* Tip and note boxes */
.tip { background-color: #f0fff4; padding: 15px; border-left: 4px solid #48bb78; margin: 15px 0; }
.note { background-color: #fefcbf; padding: 15px; border-left: 4px solid #ecc94b; margin: 15px 0; }
.warning { background-color: #fff5f5; padding: 15px; border-left: 4px solid #e53e3e; margin: 15px 0; }

/* Tables */
table { border-collapse: collapse; width: 100%; margin: 15px 0; }
th, td { border: 1px solid #e2e8f0; padding: 10px; text-align: left; }
th { background-color: #2c5282; color: white; }
tr:nth-child(even) { background-color: #f7fafc; }
tr:hover { background-color: #ebf8ff; }

/* Keyboard keys */
kbd { background-color: #edf2f7; border: 1px solid #cbd5e0; border-radius: 4px; padding: 3px 8px; 
      font-family: Consolas, monospace; font-size: 0.9em; box-shadow: 0 1px 2px rgba(0,0,0,0.1); }

/* Ordered lists */
ol { margin: 10px 0 10px 20px; }

/* Images - prevent scaling beyond natural size to avoid pixelation */
img { 
    max-width: 100%; 
    height: auto; 
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
}

/* ── Table of Contents sidebar ── */
.toc-layout {
    display: flex;
    min-height: 100vh;
}

.toc-sidebar {
    width: 220px;
    min-width: 220px;
    background: #f7fafc;
    border-right: 1px solid #e2e8f0;
    padding: 18px 14px;
    box-sizing: border-box;
    position: sticky;
    top: 0;
    height: 100vh;
    overflow-y: auto;
}

.toc-home {
    display: block;
    font-weight: 700;
    font-size: 15px;
    color: #2c5282;
    text-decoration: none;
    padding: 6px 8px;
    border-radius: 4px;
    margin-bottom: 10px;
}
.toc-home:hover { background: #ebf8ff; }

.toc-heading {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #718096;
    margin: 14px 0 4px 8px;
}

.toc-list {
    list-style: none;
    margin: 0;
    padding: 0;
}
.toc-list li { margin: 0; }

.toc-link {
    display: block;
    padding: 4px 8px;
    color: #4a5568;
    text-decoration: none;
    font-size: 13px;
    border-radius: 4px;
    line-height: 1.4;
}
.toc-link:hover { background: #ebf8ff; color: #2c5282; }

.toc-active {
    background: #ebf8ff;
    color: #2c5282 !important;
    font-weight: 600;
}

.toc-content {
    flex: 1;
    min-width: 0;
    padding: 0 24px 40px 24px;
}
