/* Signward Developer — doc-specific styles layered on top of the landing theme. */

/* The fixed navbar uses position: fixed. Pages with a landing-style banner-area
   manage their own top spacing (box-table is vh-height), but regular doc pages
   need an explicit offset so the content isn't covered by the navbar. */
body.developer-site { background: #fff; }
body.developer-site .doc-shell { padding-top: 120px; }

/* Developer sub-brand badge in the navbar */
body.developer-site .sw-logo-text span {
    margin-left: 2px;
    font-size: 13px;
    letter-spacing: 0.3px;
    text-transform: uppercase;
}

/* Hero right-hand code window — sits next to the landing-style banner */
.dev-hero-code {
    background: #0f172a;
    color: #e2e8f0;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(15, 23, 42, 0.35);
    overflow: hidden;
    font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
}

.dev-hero-code-head {
    background: #1e293b;
    padding: 10px 14px;
    display: flex;
    align-items: center;
    gap: 8px;
    border-bottom: 1px solid #334155;
}

.dev-hero-code-head .dot {
    width: 11px;
    height: 11px;
    border-radius: 50%;
    display: inline-block;
}

.dev-hero-code-head .dot-r { background: #ef4444; }
.dev-hero-code-head .dot-y { background: #f59e0b; }
.dev-hero-code-head .dot-g { background: #22c55e; }

.dev-hero-code-head .dev-hero-code-file {
    margin-left: 10px;
    color: #94a3b8;
    font-size: 12px;
}

.dev-hero-code-body {
    margin: 0;
    padding: 18px 20px;
    font-size: 13px;
    line-height: 1.65;
    color: #e2e8f0;
    background: transparent;
    overflow-x: auto;
}

.dev-hero-code-body .c-kw { color: #c084fc; }
.dev-hero-code-body .c-fn { color: #60a5fa; }
.dev-hero-code-body .c-str { color: #86efac; }

/* 3-card grid (Start building / API reference / SDKs) */
.dev-cards {
    padding: 60px 0;
}

.dev-cards:last-of-type {
    padding-bottom: 100px;
}

.dev-card {
    display: block;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 28px;
    text-decoration: none !important;
    color: inherit !important;
    transition: box-shadow 0.15s ease, transform 0.15s ease;
    height: 100%;
}

.dev-card:hover {
    box-shadow: 0 10px 30px rgba(67, 97, 238, 0.12);
    transform: translateY(-2px);
    border-color: #a5b4fc;
}

.dev-card .card-icon {
    width: 44px;
    height: 44px;
    border-radius: 10px;
    background: #eef2ff;
    color: #4361ee;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    margin-bottom: 16px;
}

.dev-card h3 {
    font-size: 18px;
    font-weight: 600;
    margin: 0 0 8px;
    color: #1e293b;
}

.dev-card p {
    margin: 0 0 12px;
    color: #64748b;
    font-size: 14px;
    line-height: 1.55;
}

.dev-card .card-cta {
    font-size: 14px;
    color: #4361ee;
    font-weight: 500;
}

.dev-card .card-cta i {
    font-size: 12px;
    margin-left: 4px;
    transition: margin-left 0.15s ease;
}

.dev-card:hover .card-cta i { margin-left: 8px; }

/* 3-column doc layout: sidebar | main | toc */
.doc-shell {
    display: grid;
    grid-template-columns: 260px minmax(0, 1fr) 220px;
    gap: 48px;
    padding: 32px 0 80px;
    max-width: 1280px;
    margin: 0 auto;
}

@media (max-width: 1100px) {
    .doc-shell { grid-template-columns: 240px minmax(0, 1fr); }
    .doc-toc { display: none; }
}

@media (max-width: 768px) {
    .doc-shell { grid-template-columns: 1fr; padding: 16px; }
    .doc-sidebar { display: none; }
}

.doc-sidebar {
    border-right: 1px solid #e5e7eb;
    padding-right: 16px;
    font-size: 14px;
}

.doc-sidebar .section-title {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #64748b;
    margin: 18px 0 6px;
}

.doc-sidebar ul { list-style: none; padding: 0; margin: 0 0 12px; }
.doc-sidebar li { margin: 0; }

.doc-sidebar a {
    display: block;
    padding: 6px 10px;
    color: #334155;
    text-decoration: none;
    border-radius: 6px;
    line-height: 1.4;
}

.doc-sidebar a:hover { background: #f1f5f9; color: #1e293b; }
.doc-sidebar a.active { background: #eef2ff; color: #4361ee; font-weight: 500; }

.doc-sidebar .section-title-internal {
    color: #b45309;
    background: #fffbeb;
    padding: 6px 10px;
    border-left: 3px solid #f59e0b;
    border-radius: 0 4px 4px 0;
    margin-top: 20px;
}

.doc-internal-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #fffbeb;
    color: #b45309;
    border: 1px solid #fde68a;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
    margin-bottom: 16px;
}

.doc-internal-badge i { font-size: 11px; }

/* Main content */
.doc-main { min-width: 0; }
.doc-main h1 { font-size: 36px; font-weight: 700; margin: 0 0 8px; color: #1e293b; line-height: 1.2; }
.doc-main .doc-description { font-size: 16px; color: #64748b; margin-bottom: 32px; }
.doc-main h2 { font-size: 24px; font-weight: 600; margin: 36px 0 12px; color: #1e293b; padding-bottom: 6px; border-bottom: 1px solid #e5e7eb; }
.doc-main h3 { font-size: 18px; font-weight: 600; margin: 24px 0 10px; color: #1e293b; }
.doc-main p, .doc-main li { line-height: 1.7; color: #334155; }
.doc-main a { color: #4361ee; text-decoration: underline; text-decoration-color: #c7d2fe; }
.doc-main a:hover { text-decoration-color: #4361ee; }

.doc-main pre {
    background: #0f172a;
    color: #e2e8f0;
    padding: 18px 20px;
    border-radius: 8px;
    font-size: 13px;
    line-height: 1.6;
    overflow-x: auto;
    margin: 16px 0;
}

.doc-main code {
    background: #f1f5f9;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 13px;
    color: #be185d;
}

.doc-main pre code { background: transparent; padding: 0; color: inherit; }

.doc-main table {
    width: 100%;
    border-collapse: collapse;
    margin: 16px 0;
    font-size: 14px;
}

.doc-main th, .doc-main td {
    border: 1px solid #e5e7eb;
    padding: 10px 12px;
    text-align: left;
    vertical-align: top;
}

.doc-main th { background: #f8fafc; font-weight: 600; }

.doc-main blockquote {
    border-left: 4px solid #a5b4fc;
    background: #eef2ff;
    margin: 16px 0;
    padding: 12px 16px;
    color: #334155;
    border-radius: 0 6px 6px 0;
}

/* On-page TOC */
.doc-toc {
    font-size: 13px;
    position: sticky;
    top: 110px;
    align-self: start;
    max-height: calc(100vh - 130px);
    overflow-y: auto;
}

.doc-toc .toc-title {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #64748b;
    margin-bottom: 10px;
}

.doc-toc ul { list-style: none; padding: 0; margin: 0; border-left: 2px solid #e5e7eb; }
.doc-toc li { margin: 0; }
.doc-toc a {
    display: block;
    padding: 4px 12px;
    color: #64748b;
    text-decoration: none;
    line-height: 1.4;
    border-left: 2px solid transparent;
    margin-left: -2px;
}
.doc-toc a:hover { color: #1e293b; }
.doc-toc a.level-3 { padding-left: 24px; }
