/* ==========================================================================
   OKIDIA Documentation Portal Stylesheet (docs.css)
   Clean, modern 2-column documentation layout for educators and IT admins
   ========================================================================== */

.docs-wrapper {
    display: flex;
    max-width: 1400px;
    margin: 0 auto;
    padding: 2rem 1.5rem 4rem;
    gap: 3rem;
    position: relative;
}

/* --------------------------------------------------------------------------
   Sidebar Navigation
   -------------------------------------------------------------------------- */
.docs-sidebar {
    width: 280px;
    flex-shrink: 0;
    position: sticky;
    top: 90px;
    height: calc(100vh - 110px);
    overflow-y: auto;
    padding-right: 1rem;
    scrollbar-width: thin;
    scrollbar-color: var(--border-color) transparent;
}

.docs-sidebar::-webkit-scrollbar {
    width: 5px;
}
.docs-sidebar::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 4px;
}

.docs-search {
    margin-bottom: 1.5rem;
    position: relative;
}

.docs-search-input {
    width: 100%;
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    padding: 0.65rem 1rem 0.65rem 2.4rem;
    border-radius: var(--radius-md);
    font-size: 0.88rem;
    font-family: inherit;
    transition: var(--transition-fast);
}

.docs-search-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}

.docs-search-icon {
    position: absolute;
    left: 0.8rem;
    top: 50%;
    transform: translateY(-50%);
    width: 16px;
    height: 16px;
    opacity: 0.5;
    pointer-events: none;
}

.docs-nav-group {
    margin-bottom: 1.75rem;
}

.docs-nav-title {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text-tertiary);
    margin-bottom: 0.6rem;
    padding-left: 0.5rem;
}

.docs-nav-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.docs-nav-item {
    margin-bottom: 0.2rem;
}

.docs-nav-link {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.45rem 0.75rem;
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    border-radius: var(--radius-sm);
    transition: var(--transition-fast);
    line-height: 1.35;
}

.docs-nav-link:hover {
    color: var(--text-primary);
    background: var(--bg-surface-elevated);
}

.docs-nav-link.active {
    color: var(--primary);
    background: rgba(37, 99, 235, 0.08);
    font-weight: 600;
}

.docs-nav-link img {
    width: 16px;
    height: 16px;
    opacity: 0.75;
    transition: var(--transition-fast);
}

.docs-nav-link.active img,
.docs-nav-link:hover img {
    opacity: 1;
}

/* --------------------------------------------------------------------------
   Main Content Area
   -------------------------------------------------------------------------- */
.docs-content {
    flex: 1;
    min-width: 0;
    max-width: 900px;
}

.docs-breadcrumb {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.85rem;
    color: var(--text-tertiary);
    margin-bottom: 1.25rem;
}

.docs-breadcrumb a {
    color: var(--text-secondary);
    text-decoration: none;
}

.docs-breadcrumb a:hover {
    color: var(--primary);
}

.docs-section {
    margin-bottom: 3.5rem;
    scroll-margin-top: 100px;
}

.docs-section h1 {
    font-size: 2.25rem;
    font-weight: 800;
    letter-spacing: -0.025em;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.docs-section h2 {
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    margin-top: 2rem;
    margin-bottom: 0.75rem;
    color: var(--text-primary);
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--border-color);
}

.docs-section h3 {
    font-size: 1.2rem;
    font-weight: 600;
    margin-top: 1.5rem;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.docs-section p {
    color: var(--text-secondary);
    font-size: 1rem;
    line-height: 1.7;
    margin-bottom: 1.25rem;
}

.docs-section ul, 
.docs-section ol {
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 1.25rem;
    padding-left: 1.5rem;
}

.docs-section li {
    margin-bottom: 0.4rem;
}

/* --------------------------------------------------------------------------
   Callouts & Notes (Info / Tip / Warning / Key Concept)
   -------------------------------------------------------------------------- */
.docs-callout {
    border-radius: var(--radius-md);
    padding: 1rem 1.25rem;
    margin: 1.5rem 0;
    border-left: 4px solid var(--primary);
    background: var(--bg-surface-elevated);
    display: flex;
    gap: 1rem;
    align-items: flex-start;
}

.docs-callout-icon {
    width: 22px;
    height: 22px;
    flex-shrink: 0;
    margin-top: 2px;
}

.docs-callout-content {
    flex: 1;
    font-size: 0.95rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

.docs-callout-content strong {
    color: var(--text-primary);
    display: block;
    margin-bottom: 0.25rem;
}

.docs-callout-tip {
    border-left-color: var(--secondary);
    background: rgba(16, 185, 129, 0.08);
}

.docs-callout-warning {
    border-left-color: #f59e0b;
    background: rgba(245, 158, 11, 0.08);
}

.docs-callout-info {
    border-left-color: var(--primary);
    background: rgba(37, 99, 235, 0.08);
}

/* --------------------------------------------------------------------------
   Step-by-Step Guide
   -------------------------------------------------------------------------- */
.step-list {
    margin: 2rem 0;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.step-card {
    display: flex;
    gap: 1.25rem;
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    transition: var(--transition-normal);
}

.step-card:hover {
    border-color: rgba(37, 99, 235, 0.3);
    box-shadow: 0 4px 12px var(--shadow-color);
}

.step-number {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: rgba(37, 99, 235, 0.12);
    color: var(--primary);
    font-weight: 700;
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.step-body {
    flex: 1;
}

.step-body h4 {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.step-body p {
    margin-bottom: 0.75rem;
    font-size: 0.95rem;
}

/* --------------------------------------------------------------------------
   Code Snippets & Terminal Commands
   -------------------------------------------------------------------------- */
.code-box {
    background: #0f172a;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-md);
    margin: 1rem 0 1.5rem;
    overflow: hidden;
    font-family: var(--font-mono);
}

.code-box-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.5rem 1rem;
    background: #1e293b;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    font-size: 0.78rem;
    color: #94a3b8;
}

.code-box-lang {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
}

.code-copy-btn {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #cbd5e1;
    font-size: 0.75rem;
    padding: 0.25rem 0.6rem;
    border-radius: 4px;
    cursor: pointer;
    transition: var(--transition-fast);
}

.code-copy-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
}

.code-box pre {
    margin: 0;
    padding: 1rem;
    overflow-x: auto;
    color: #f1f5f9;
    font-size: 0.88rem;
    line-height: 1.6;
}

/* Inline code */
:not(pre) > code {
    background: var(--bg-surface-elevated);
    color: var(--primary);
    padding: 0.2rem 0.4rem;
    border-radius: 4px;
    font-family: var(--font-mono);
    font-size: 0.85em;
    border: 1px solid var(--border-color);
}

/* --------------------------------------------------------------------------
   Interactive / Screenshot Placeholder Frames
   -------------------------------------------------------------------------- */
.ui-mockup-frame {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    overflow: hidden;
    margin: 1.5rem 0 2rem;
    box-shadow: 0 8px 24px var(--shadow-color);
}

.ui-mockup-topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.6rem 1rem;
    background: var(--bg-surface-elevated);
    border-bottom: 1px solid var(--border-color);
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-secondary);
}

.ui-mockup-dots {
    display: flex;
    gap: 6px;
}

.ui-mockup-dots span {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--border-color);
}

.ui-mockup-dots span:nth-child(1) { background: #ef4444; }
.ui-mockup-dots span:nth-child(2) { background: #f59e0b; }
.ui-mockup-dots span:nth-child(3) { background: #10b981; }

.ui-mockup-content {
    padding: 1.5rem;
    background: var(--bg-surface);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 220px;
    text-align: center;
    position: relative;
}

.ui-mockup-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
    color: var(--text-secondary);
}

.ui-mockup-placeholder img {
    width: 48px;
    height: 48px;
    opacity: 0.8;
}

.ui-mockup-placeholder .mockup-title {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-primary);
}

.ui-mockup-placeholder .mockup-desc {
    font-size: 0.88rem;
    max-width: 460px;
    color: var(--text-secondary);
}

.ui-mockup-caption {
    font-size: 0.8rem;
    color: var(--text-tertiary);
    text-align: center;
    margin-top: 0.5rem;
}

/* --------------------------------------------------------------------------
   FAQ Accordion
   -------------------------------------------------------------------------- */
.faq-accordion {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin: 1.5rem 0;
}

.faq-item {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    overflow: hidden;
    transition: var(--transition-fast);
}

.faq-header {
    padding: 1rem 1.25rem;
    font-weight: 600;
    font-size: 0.98rem;
    color: var(--text-primary);
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    user-select: none;
}

.faq-header:hover {
    background: var(--bg-surface-elevated);
}

.faq-chevron {
    width: 16px;
    height: 16px;
    transition: transform var(--transition-fast);
}

.faq-item.open .faq-chevron {
    transform: rotate(180deg);
}

.faq-body {
    padding: 0 1.25rem 1.25rem;
    color: var(--text-secondary);
    font-size: 0.92rem;
    line-height: 1.65;
    display: none;
    border-top: 1px solid var(--border-color);
    margin-top: 0.5rem;
    padding-top: 1rem;
}

.faq-item.open .faq-body {
    display: block;
}

/* --------------------------------------------------------------------------
   Mobile Responsiveness
   -------------------------------------------------------------------------- */
@media (max-width: 900px) {
    .docs-wrapper {
        flex-direction: column;
        padding-top: 1rem;
    }
    .docs-sidebar {
        width: 100%;
        position: static;
        height: auto;
        border-bottom: 1px solid var(--border-color);
        padding-bottom: 1.5rem;
        margin-bottom: 1.5rem;
    }
}
