/**
 * Guide Page Styles
 * Simple, clean styling for Racing Sparrow build guides
 */

/* =============================================================================
   Guide Hero Section
   ============================================================================= */

.guide-hero-section {
    background: #0D1237;
    border-bottom: 1px solid #e9ecef;
    padding: 4rem 0 3rem 0;
    margin-bottom: 0;
}

.guide-hero-section h1,
.guide-hero-section p {
    color: #FFF!important;
}

.guide-hero-section .container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

.guide-hero {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    min-height: 400px;
}

.guide-hero-content {
    order: 1;
}

.guide-hero-image {
    order: 2;
    position: relative;
}

.guide-hero-image img {
    width: 100%;
    height: auto;
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(43, 45, 108, 0.15);
    transition: transform 0.3s ease;
}

.guide-hero-image img:hover {
    transform: translateY(-4px);
}

/* When no hero image, center the content */
.guide-hero:not(:has(.guide-hero-image)) {
    grid-template-columns: 1fr;
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

.breadcrumbs {
    margin-bottom: 1rem;
    font-size: 0.9rem;
    color: #6c757d;
}

.breadcrumb-link {
    color: #007bff;
    /* text-decoration: none; */
}

.breadcrumb-link:hover {
    /* text-decoration: underline; */
    text-decoration: none;

}

.breadcrumb-separator {
    margin: 0 0.5rem;
}

.breadcrumb-current {
    color: #6c757d;
}

.guide-header {
    text-align: left;
}

/* When no hero image, center the header */
.guide-hero:not(:has(.guide-hero-image)) .guide-header {
    text-align: center;
}

.guide-breadcrumb {
    margin-bottom: 1rem;
}

.guide-breadcrumb .breadcrumb-link {
    display: inline-flex;
    align-items: center;
    color: #dfeeff;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    padding: 0.375rem 0.75rem;
    border-radius: 0.25rem;
    transition: all 0.2s ease;
    /* background: #95BC3D; */
    background: rgba(0, 123, 255, 0.2);
}

.guide-breadcrumb .breadcrumb-link:hover {
    background: rgba(0, 123, 255, 0.2);
    transform: translateX(-2px);
}

.guide-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: #2B2D6C;
    margin: 0 0 1rem 0;
    line-height: 1.2;
}

.guide-version {
    font-size: 0.875rem;
    color: #6c757d;
    margin: -0.5rem 0 1rem 0;
    font-weight: 400;
    opacity: 0.8;
}

.guide-subtitle {
    font-size: 1.25rem;
    color: #6c757d;
    margin: 0 0 1.5rem 0;
    font-weight: 300;
}

.guide-recommended-spec {
    font-size: 1rem;
    background: #296f8e;
    color: #FFF;
    margin: 0 0 1rem 0;
    padding: 0.75rem 1.5rem;
    border-radius: 0.5rem;
    display: inline-block;
}

.guide-standalone-note {
    font-size: 0.95rem;
    color: #6c757d;
    /* font-style: italic; */
    margin-top: 1.5rem;
}

/* =============================================================================
   Sticky Guide Toolbar
   ============================================================================= */

.guide-toolbar {
    position: sticky;
    top: 0;
    background: #ffffff;
    border-bottom: 2px solid #007bff;
    z-index: 100;
    padding: 0.75rem 0;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.guide-toolbar .container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

.guide-toolbar-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.guide-toolbar-left,
.guide-toolbar-right {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.guide-toolbar-link {
    color: #007bff;
    /* text-decoration: none; */
    font-weight: 500;
    padding: 0.25rem 0.5rem;
    border-radius: 0.25rem;
    transition: background-color 0.2s;
}

.guide-toolbar-link:hover {
    background: #f8f9fa;
    text-decoration: none;
}

.guide-toolbar-button {
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    color: #495057;
    padding: 0.25rem 0.75rem;
    border-radius: 0.25rem;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.2s;
}

.guide-toolbar-button:hover {
    background: #e9ecef;
    border-color: #adb5bd;
}

/* =============================================================================
   Body Layout
   ============================================================================= */

.guide-body {
    padding: 2rem 0;
}

.guide-body .container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

.guide-layout {
    display: grid;
    gap: 2rem;
    grid-template-columns: 1fr;
    align-items: start; /* Important for sticky positioning */
}

/* Desktop two-column layout */
@media (min-width: 992px) {
    .guide-layout {
        grid-template-columns: 1fr 1fr;
    }
}

/* =============================================================================
   Main Content Column
   ============================================================================= */

.guide-main {
    min-width: 0; /* Prevent grid overflow */
}

.guide-contents-section {
    background: #f8f9fa;
    padding: 1.5rem;
    border-radius: 0.5rem;
    border-left: 4px solid #007bff;
    margin-bottom: 2rem;
}

.guide-contents-section h2 {
    font-size: 1.25rem;
    color: #2B2D6C;
    margin: 0 0 1rem 0;
}

.guide-contents-list {
    margin: 0;
    padding-left: 1.5rem;
    list-style: none;
}

.guide-contents-list li {
    margin-bottom: 0.5rem;
}

.guide-contents-main {
    list-style-type: none;
}

.guide-contents-sub {
    font-size: 0.9rem;
    color: #6c757d;
    position: relative;
    left: 16px;
}

.guide-contents-link {
    color: #2B2D6C;
    /* text-decoration: none; */
}

.guide-contents-link:hover {
    text-decoration: none;
    /* text-decoration: underline; */
}

.guide-content {
    max-width: 800px;
    line-height: 1.7;
}

/* Build Step Styles */
.guide-step {
    margin-bottom: 3rem;
    scroll-margin-top: 100px; /* Account for sticky toolbar */
}

.guide-step:last-child {
    margin-bottom: 1rem;
}

.guide-step-heading {
    margin-top: 0;
    margin-bottom: 0.25rem;
    line-height: 1.3;
    color: #212529;
    border-bottom: 2px solid #e9ecef;
    padding-bottom: 0.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}

.guide-step-title {
    flex: 1;
}

.guide-step-optional {
    font-size: 0.8em;
    color: #6c757d;
    font-weight: 400;
    font-style: italic;
}

.guide-video-jump {
    background: #ff0000;
    color: white;
    border: none;
    padding: 0.25rem 0.75rem;
    border-radius: 0.25rem;
    font-size: 0.8em;
    cursor: pointer;
    font-weight: 500;
    white-space: nowrap;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.guide-video-jump:hover {
    background: #cc0000;
    transform: translateY(-1px);
}

.guide-step-content {
    margin-bottom: 2rem;
}

/* Heading sizes for different levels */
.guide-step h2 { font-size: 1.75rem; }
.guide-step h3 { font-size: 1.5rem; }
.guide-step h4 { font-size: 1.25rem; }

/* Content within steps */
.guide-step-content h1,
.guide-step-content h2,
.guide-step-content h3,
.guide-step-content h4,
.guide-step-content h5,
.guide-step-content h6 {
    margin-top: 1.5rem;
    margin-bottom: 1rem;
    line-height: 1.3;
    color: #212529;
}

.guide-step-content h1 { font-size: 1.5rem; }
.guide-step-content h2 { font-size: 1.35rem; }
.guide-step-content h3 { font-size: 1.2rem; }
.guide-step-content h4 { font-size: 1.1rem; }
.guide-step-content h5 { font-size: 1.05rem; }
.guide-step-content h6 { font-size: 1rem; }

.guide-step-content p {
    margin-bottom: 1.1rem;
}

.guide-step-content ul,
.guide-step-content ol {
    margin-bottom: 1.5rem;
    padding-left: 2rem;
}

.guide-step-content li {
    margin-bottom: 0.5rem;
}

.guide-step-content blockquote {
    border-left: 4px solid #007bff;
    padding-left: 1.5rem;
    margin: 1.5rem 0;
    font-style: italic;
    color: #6c757d;
}

.guide-step-content code {
    background: #f8f9fa;
    padding: 0.2rem 0.4rem;
    border-radius: 0.25rem;
    font-size: 0.9em;
    color: #e83e8c;
}

.guide-step-content pre {
    background: #f8f9fa;
    padding: 1rem;
    border-radius: 0.5rem;
    overflow-x: auto;
    margin-bottom: 1.5rem;
}

.guide-step-content img {
    max-width: 100%;
    height: auto;
    border-radius: 0.5rem;
    margin: 1rem 0;
}

/* Build Step Images */
.guide-step-images {
    margin: 0;
    display: grid;
    gap: 1.5rem;
}

/* Single image - full width */
.guide-step-images:has(.guide-step-image:only-child) {
    grid-template-columns: 1fr;
}

/* Two images - side by side */
.guide-step-images:has(.guide-step-image:nth-child(2):last-child) {
    grid-template-columns: 1fr 1fr;
}

/* Three images - flexible layout */
.guide-step-images:has(.guide-step-image:nth-child(3)) {
    grid-template-columns: 1fr 1fr;
}

.guide-step-images:has(.guide-step-image:nth-child(3)) .guide-step-image:nth-child(3) {
    grid-column: 1 / -1;
    max-width: 50%;
    justify-self: center;
}

.guide-step-image {
    background: #f8f9fa;
    border-radius: 0.5rem;
    overflow: hidden;
    border: 1px solid #e9ecef;
    transition: all 0.2s ease;
}

.guide-step-image:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.guide-step-image img {
    width: 100%;
    height: auto;
    display: block;
    margin: 0;
    border-radius: 0;
}

.guide-step-image-caption {
    padding: 0.75rem 1rem;
    font-size: 0.9rem;
    color: #6c757d;
    background: #ffffff;
    border-top: 1px solid #e9ecef;
    font-style: italic;
}

/* Mobile responsive images */
@media (max-width: 767.98px) {
    .guide-step-images {
        grid-template-columns: 1fr !important;
        gap: 1rem;
    }
    
    .guide-step-images:has(.guide-step-image:nth-child(3)) .guide-step-image:nth-child(3) {
        grid-column: auto;
        max-width: none;
        justify-self: auto;
    }
    
    .guide-step-image-caption {
        padding: 0.5rem 0.75rem;
        font-size: 0.85rem;
    }
}

/* Print styles for images */
@media print {
    .guide-step-images {
        grid-template-columns: 1fr !important;
        gap: 1rem;
        break-inside: avoid;
    }
    
    .guide-step-image {
        break-inside: avoid;
        box-shadow: none;
        border: 1px solid #333;
    }
    
    .guide-step-image img {
        max-height: 300px;
        object-fit: contain;
    }
}

/* No steps message */
.guide-no-steps {
    text-align: center;
    padding: 3rem 2rem;
    background: #f8f9fa;
    border-radius: 0.5rem;
    color: #6c757d;
}

.guide-no-steps h2 {
    color: #495057;
    margin-bottom: 1rem;
}

/* Additional Information Section */
.guide-additional-info {
    margin-top: 3rem;
    padding: 2rem;
    background: #f8f9fa;
    border-radius: 0.5rem;
    border-left: 4px solid #007bff;
    max-width: 800px;
}

.guide-additional-info h1,
.guide-additional-info h2,
.guide-additional-info h3,
.guide-additional-info h4,
.guide-additional-info h5,
.guide-additional-info h6 {
    color: #2B2D6C;
    margin-top: 1.5rem;
    margin-bottom: 1rem;
}

.guide-additional-info h1:first-child,
.guide-additional-info h2:first-child,
.guide-additional-info h3:first-child,
.guide-additional-info h4:first-child,
.guide-additional-info h5:first-child,
.guide-additional-info h6:first-child {
    margin-top: 0;
}

.guide-additional-info p {
    margin-bottom: 1.5rem;
    line-height: 1.7;
}

.guide-additional-info ul,
.guide-additional-info ol {
    margin-bottom: 1.5rem;
    padding-left: 2rem;
}

.guide-additional-info li {
    margin-bottom: 0.5rem;
    line-height: 1.6;
}

.guide-additional-info strong {
    color: #2B2D6C;
}

.guide-additional-info code {
    background: #e9ecef;
    padding: 0.2rem 0.4rem;
    border-radius: 0.25rem;
    font-size: 0.9em;
    color: #495057;
}

.guide-additional-info blockquote {
    border-left: 4px solid #007bff;
    padding-left: 1.5rem;
    margin: 1.5rem 0;
    font-style: italic;
    color: #6c757d;
}

.guide-additional-info table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 1.5rem;
}

.guide-additional-info table th,
.guide-additional-info table td {
    padding: 0.75rem;
    text-align: left;
    border-bottom: 1px solid #dee2e6;
}

.guide-additional-info table th {
    background-color: #e9ecef;
    font-weight: 600;
    color: #2B2D6C;
}

/* =============================================================================
   Sidebar (Supplementary Panel)
   ============================================================================= */

.guide-sidebar {
    background: #f8f9fa;
    border-radius: 0.5rem;
    padding: 1.5rem;
    height: fit-content;
}

/* Sticky sidebar on desktop only */
@media (min-width: 992px) {
    .guide-sidebar {
        position: -webkit-sticky;
        position: sticky;
        top: calc(60px + 1rem); /* Account for sticky toolbar height + margin */
        max-height: calc(100vh - 80px); /* Prevent sidebar from being too tall */
        overflow-y: auto; /* Allow scrolling if content is too long */
    }
}

.guide-sidebar h2 {
    font-size: 1.25rem;
    color: #2B2D6C;
    margin: 0 0 1.5rem 0;
    border-bottom: 2px solid #2B2D6C;
    padding-bottom: 0.5rem;
}

.guide-sidebar-section {
    margin-bottom: 2rem;
}

.guide-sidebar-section:last-child {
    margin-bottom: 0;
}

.guide-sidebar-section h3 {
    font-size: 1.1rem;
    color: #495057;
    margin: 0 0 1rem 0;
}

/* Video Player */
.guide-video-container {
    background: #000;
    border-radius: 0.25rem;
    overflow: hidden;
    margin-bottom: 1rem;
    position: relative;
    aspect-ratio: 16/9;
}

.guide-video-container iframe,
.guide-video-container #youtube-player {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.guide-file-link {
    margin-bottom: 1rem;
}

/* Plan Images (sailplans/boat plans) */
.guide-plan-image {
    background: #ffffff;
    border: 1px solid #e9ecef;
    border-radius: 0.5rem;
    overflow: hidden;
    margin-bottom: 1rem;
    transition: all 0.2s ease;
}

.guide-plan-image:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.guide-plan-image img {
    width: 100%;
    height: auto;
    display: block;
    cursor: pointer;
    max-height: 500px; /* Prevent very tall portrait images from dominating */
    object-fit: contain; /* Maintain aspect ratio */
}

.guide-plan-image-caption {
    padding: 0.75rem 1rem;
    font-size: 0.9rem;
    color: #6c757d;
    background: #f8f9fa;
    border-top: 1px solid #e9ecef;
    /* font-style: italic; */
}

.guide-download-link {
    display: inline-block;
    background: #007bff;
    color: white;
    /* text-decoration: none; */
    padding: 0.5rem 1rem;
    border-radius: 0.25rem;
    font-weight: 500;
    transition: background-color 0.2s;
}

.guide-download-link:hover {
    background: #0056b3;
    color: white;
    text-decoration: none;
}

.guide-pdf-embed {
    border: 1px solid #dee2e6;
    border-radius: 0.25rem;
    overflow: hidden;
}

.guide-pdf-embed object {
    display: block;
}

/* =============================================================================
   Mobile Responsive
   ============================================================================= */

@media (max-width: 991.98px) {
    .guide-hero {
        grid-template-columns: 1fr;
        gap: 2rem;
        text-align: center;
    }
    
    .guide-hero-content {
        order: 2;
    }
    
    .guide-hero-image {
        order: 1;
    }
    
    .guide-header {
        text-align: center;
    }
    
    .guide-title {
        font-size: 2rem;
    }
    
    .guide-recommended-spec {
        display: block;
        text-align: center;
    }
    
    .guide-toolbar-content {
        justify-content: center;
        text-align: center;
    }
    
    .guide-toolbar-left,
    .guide-toolbar-right {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .guide-sidebar {
        order: 1; /* Sidebar appears above main content on mobile */
    }
    
    .guide-main {
        order: 2;
    }
}

@media (max-width: 767.98px) {
    .guide-hero-section {
        padding: 2rem 0 1.5rem 0;
    }
    
    .guide-hero {
        gap: 1.5rem;
        min-height: auto;
    }
    
    .guide-title {
        font-size: 1.75rem;
    }
    
    .guide-toolbar {
        padding: 0.5rem 0;
    }
    
    .guide-body {
        padding: 1.5rem 0;
    }
    
    .guide-layout {
        gap: 1.5rem;
    }
    
    .guide-contents-section {
        padding: 1rem;
    }
    
    .guide-sidebar {
        padding: 0;
    }
    
    .guide-step-heading {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
    
    .guide-video-jump {
        align-self: flex-start;
    }
    
    /* .guide-video-container {
        height: 200px;
        aspect-ratio: auto;
    } */
}

/* =============================================================================
   Print Styles
   ============================================================================= */

@media print {
    .guide-toolbar,
    .guide-sidebar,
    .breadcrumbs {
        display: none !important;
    }
    
    .guide-intro-panel {
        background: none;
        border: none;
        padding: 1rem 0;
    }
    
    .guide-body {
        padding: 0;
    }
    
    .guide-layout {
        display: block;
    }
    
    .guide-main {
        max-width: none;
    }
    
    .guide-content {
        max-width: none;
    }
    
    .guide-content h1,
    .guide-content h2,
    .guide-content h3 {
        break-after: avoid;
        page-break-after: avoid;
    }
    
    .guide-contents-section {
        background: none;
        border: 1px solid #dee2e6;
        page-break-inside: avoid;
    }
    
    .guide-contents-link {
        color: #212529;
    }
    
    .guide-contents-link::after {
        content: " (page " target-counter(attr(href), page) ")";
        font-size: 0.8em;
        color: #6c757d;
    }
}

/* =============================================================================
   Tabs for Supplementary Content
   ============================================================================= */

.guide-tabs {
    background: #ffffff;
    border-radius: 0.5rem;
    overflow: hidden;
    border: 1px solid #e9ecef;
}

.guide-tab-buttons {
    display: flex;
    background: #f8f9fa;
    border-bottom: 1px solid #e9ecef;
}

.guide-tab-button {
    flex: 1;
    background: none;
    border: none;
    padding: 0.75rem 0.2rem;
    font-size: 0.9rem;
    color: #6c757d;
    cursor: pointer;
    transition: all 0.2s;
    position: relative;
}

.guide-tab-button:hover {
    background: #e9ecef;
    color: #495057;
}

.guide-tab-button.active {
    background: #ffffff;
    color: #007bff;
    border-bottom: 2px solid #007bff;
}

.guide-tab-button:disabled {
    background: #f8f9fa;
    color: #adb5bd;
    border-color: #e9ecef;
    cursor: not-allowed;
    opacity: 0.6;
}

.guide-tab-button:disabled.active {
    background: #ffffff;
    color: #adb5bd;
    border-bottom: 2px solid #e9ecef;
}

.guide-tab-button:disabled:hover {
    background: #f8f9fa;
    color: #adb5bd;
}

.guide-empty-state {
    text-align: center;
    padding: 2rem 1rem;
    color: #6c757d;
}

.guide-empty-state p {
    margin-bottom: 0.5rem;
}

.guide-empty-state small {
    font-size: 0.85rem;
    color: #adb5bd;
}

.guide-tab-content {
    background: #ffffff;
}

.guide-tab-panel {
    display: none;
    padding: 1rem;
}

.guide-tab-panel.active {
    display: block;
}

.guide-tab-intro {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 0.375rem;
    padding: 1rem 1.25rem;
    margin-bottom: 1.5rem;
    color: #495057;
    line-height: 1.6;
}

.guide-tab-intro h1,
.guide-tab-intro h2,
.guide-tab-intro h3,
.guide-tab-intro h4,
.guide-tab-intro h5,
.guide-tab-intro h6 {
    color: #2B2D6C;
    margin-top: 0;
    margin-bottom: 0.75rem;
}

.guide-tab-intro p {
    margin-bottom: 1rem;
}

.guide-tab-intro p:last-child {
    margin-bottom: 0;
}

.guide-tab-intro ul,
.guide-tab-intro ol {
    margin-bottom: 1rem;
    padding-left: 1.5rem;
}

.guide-tab-intro li {
    margin-bottom: 0.25rem;
}

.guide-tab-intro strong {
    color: #2B2D6C;
}

/* Adjust video container within tabs */
.guide-tab-panel .guide-video-container {
    margin-bottom: 0;
}

/* Adjust plan images within tabs */
.guide-tab-panel .guide-plan-image {
    margin-bottom: 0;
}

/* =============================================================================
   Image Modal for Step Images
   ============================================================================= */

.guide-image-modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    animation: fadeIn 0.3s;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.guide-image-modal-content {
    position: relative;
    margin: auto;
    padding: 10px;
    width: 98%;
    max-width: 1200px;
    height: 98%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.guide-image-modal-close {
    position: absolute;
    top: 10px;
    right: 25px;
    color: #ffffff;
    font-size: 35px;
    font-weight: bold;
    cursor: pointer;
    z-index: 1001;
    transition: color 0.3s;
}

.guide-image-modal-close:hover {
    color: #ccc;
}

.guide-image-modal img {
    max-width: 100%;
    max-height: 80%;
    object-fit: contain;
    border-radius: 0.5rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.guide-image-modal-caption {
    color: #ffffff;
    text-align: center;
    padding: 15px 0;
    font-size: 1.1rem;
    margin-top: 10px;
}

/* Scroll to Top Button */
.scroll-to-top-btn {
    position: fixed;
    bottom: 30px;
    left: 30px;
    width: 50px;
    height: 50px;
    background: #95BC3D;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transform: scale(0.8);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1000;
    color: white;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.scroll-to-top-btn.visible {
    opacity: 1;
    visibility: visible;
    transform: scale(1);
}

.scroll-to-top-btn:hover {
    background: rgba(0, 0, 0, 0.8);
    transform: scale(1.05);
    box-shadow: 0 6px 25px rgba(0, 0, 0, 0.25);
}

.scroll-to-top-btn svg {
    position: relative;
    top: 2px;
    width: 33px;
    height: 33px;
    fill: currentColor;
}

/* Image Carousel Styles */
.guide-carousel {
    position: relative;
    width: 100%;
    overflow: hidden;
}

.guide-carousel-container {
    position: relative;
    width: 100%;
    overflow: hidden;
    border-radius: 0.5rem;
}

.guide-carousel-track {
    display: flex;
    transition: transform 0.3s ease;
    width: 100%;
}

.guide-carousel-slide {
    flex: 0 0 100%;
    width: 100%;
}

.guide-carousel-slide img {
    max-width: 400px;
    max-height: 600px;
    width: 100%;
    height: auto;
    display: block;
    margin: 0 auto;
    border-radius: 0.5rem;
    object-fit: contain;
}

.guide-carousel-caption {
    text-align: center;
    padding: 0.75rem 1rem;
    font-size: 0.9rem;
    color: #6c757d;
    background: #f8f9fa;
    margin-top: 0.5rem;
    margin-bottom: 2rem;
    border-radius: 0.25rem;
    font-style: italic;
    border: 1px solid #e9ecef;
}

.guide-carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
    transition: all 0.2s ease;
}

.guide-carousel-btn:hover {
    background: rgba(0, 0, 0, 0.7);
    transform: translateY(-50%) scale(1.1);
}

.guide-carousel-prev {
    left: 10px;
}

.guide-carousel-next {
    right: 10px;
}

.guide-carousel-dots {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 15px;
}

.guide-carousel-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.3);
    cursor: pointer;
    transition: all 0.2s ease;
}

.guide-carousel-dot.active,
.guide-carousel-dot:hover {
    background: #007bff;
    transform: scale(1.2);
}

/* Hide navigation for single images */
.guide-carousel[data-single="true"] .guide-carousel-btn,
.guide-carousel[data-single="true"] .guide-carousel-dots {
    display: none;
}

/* Materials List Styling */
.guide-materials-list {
    padding: 1rem 0 3rem;
}

/* Material heading separators */
.guide-material-heading {
    margin: 2rem 0 0.75rem 0;
    padding-bottom: 0.5rem;
    /* border-bottom: 2px solid #2B2D6C; */
}

.guide-material-heading:first-child {
    margin-top: 0;
}

.guide-material-heading-text {
    font-size: 1.1rem;
    font-weight: 600;
    color: #2B2D6C;
    margin: 0;
    /* text-transform: uppercase; */
    letter-spacing: 0.5px;
}

/* Material items */
.guide-material-item {
    margin-bottom: 0.5rem;
    padding: 0.25rem 0;
    transition: all 0.2s ease;
}

.guide-material-item.completed {
    opacity: 0.6;
}

.guide-material-item.completed .guide-material-label {
    text-decoration: line-through;
    color: #6c757d;
}

.guide-material-header {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    min-width: 0; /* Prevent flex item overflow */
}

.guide-material-checkbox {
    display: flex;
    align-items: center;
    cursor: pointer;
    margin-top: 0.1rem;
    flex-shrink: 0;
}

.guide-material-checkbox input[type="checkbox"] {
    opacity: 0;
    position: absolute;
    width: auto;
}

.checkbox-custom {
    width: 18px;
    height: 18px;
    border: 2px solid #2B2D6C;
    border-radius: 3px;
    display: inline-block;
    position: relative;
    transition: all 0.2s ease;
}

.guide-material-checkbox input[type="checkbox"]:checked + .checkbox-custom {
    background: #2B2D6C;
    border-color: #2B2D6C;
}

.guide-material-checkbox input[type="checkbox"]:checked + .checkbox-custom:after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 12px;
    font-weight: bold;
}

.guide-material-label {
    font-size: 0.95rem;
    color: #2B2D6C;
    font-weight: 500;
    line-height: 1.3;
    flex: 1;
    min-width: 0; /* Allow text to wrap and prevent overflow */
    word-break: break-word;
}

.guide-material-link {
    color: #007bff;
    font-weight: 400;
    transition: color 0.2s ease;
}

.guide-material-link:hover {
    color: #0056b3;
    text-decoration: none;
    /* text-decoration: underline; */
}

/* Printed Parts List Styling */
.guide-printed-parts-list {
    padding: 0 0 3rem 0;
}

/* Printed part heading separators */
.guide-printed-part-heading {
    margin: 2.5rem 0 0.75rem 0;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid #2B2D6C;
}

.guide-printed-part-heading:first-child {
    margin-top: 0;
}

.guide-printed-part-heading-text {
    font-size: 1.1rem;
    font-weight: 600;
    color: #2B2D6C;
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Printed part items */
.guide-printed-part-item {
    margin-bottom: 0.5rem;
    padding: 0.25rem 0;
    transition: all 0.2s ease;
}

.guide-printed-part-item.completed {
    opacity: 0.6;
}

.guide-printed-part-item.completed .guide-printed-part-label {
    text-decoration: line-through;
    color: #6c757d;
}

.guide-printed-part-header {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    min-width: 0; /* Prevent flex item overflow */
}

.guide-printed-part-checkbox {
    display: flex;
    align-items: center;
    cursor: pointer;
    margin-top: 0.1rem;
    flex-shrink: 0;
}

.guide-printed-part-checkbox input[type="checkbox"] {
    opacity: 0;
    position: absolute;
    width: auto;
}

.guide-printed-part-checkbox .checkbox-custom {
    width: 18px;
    height: 18px;
    border: 2px solid #2B2D6C;
    border-radius: 3px;
    display: inline-block;
    position: relative;
    transition: all 0.2s ease;
}

.guide-printed-part-checkbox input[type="checkbox"]:checked + .checkbox-custom {
    background: #2B2D6C;
    border-color: #2B2D6C;
}

.guide-printed-part-checkbox input[type="checkbox"]:checked + .checkbox-custom:after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 12px;
    font-weight: bold;
}

.guide-printed-part-label {
    font-size: 0.95rem;
    color: #2B2D6C;
    font-weight: 500;
    line-height: 1.3;
    flex: 1;
    min-width: 0; /* Allow text to wrap and prevent overflow */
    word-break: break-word;
}

.guide-part-image-btn {
    background: none;
    border: 1px solid #007bff;
    color: #007bff;
    border-radius: 4px;
    padding: 4px 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-left: 0.5rem;
    flex-shrink: 0;
}

.guide-part-image-btn:hover {
    background: #007bff;
    color: white;
    transform: scale(1.05);
}

.guide-part-image-btn svg {
    width: 14px;
    height: 14px;
}

/* =============================================================================
   Guide Step Printed Parts
   ============================================================================= */

.guide-step-parts {
    margin: 1rem 0 0.5rem 0;
}

.guide-step-parts .parts-heading {
    margin: 0 0 0.5rem 0;
    font-size: 0.9rem;
    font-weight: 600;
    color: #333;
}

.guide-step-parts .parts-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.guide-step-parts .part-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0;
    margin: 0;
}

.guide-step-parts .part-details {
    flex: 1;
}

.guide-step-parts .part-code {
    display: block;
    color: #678426;
    font-size: 0.95rem;
    font-weight: 500;
}

.guide-step-parts .part-settings {
    display: block;
    color: #666;
    font-size: 0.8rem;
    margin-top: 0.25rem;
}

.guide-step-parts .guide-part-image-btn {
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    /* width: 32px; */
    /* height: 32px; */
    display: flex;
    align-items: center;
    justify-content: center;
    margin-left: 0.5rem;
    flex-shrink: 0;
    cursor: pointer;
    transition: all 0.2s ease;
}

.guide-step-parts .guide-part-image-btn:hover {
    background: #007bff;
    color: white;
    transform: scale(1.05);
}

.guide-step-parts .guide-part-image-btn svg {
    width: 14px;
    height: 14px;
}

/* =============================================================================
   Guide Step Materials
   ============================================================================= */

.guide-step-materials {
    margin: 0.5rem 0 0.5rem 0;
}

.guide-step-materials .materials-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.guide-step-materials .material-item {
    display: flex;
    align-items: center;
    padding: 0;
    margin: 0;
}

.guide-step-materials .material-details {
    flex: 1;
}

.guide-step-materials .material-title {
    display: block;
    color: #007bff;
    font-size: 0.95rem;
    font-weight: 400;
}