html {
    scroll-behavior: smooth;
}

:root {
    --bg-main: #f9fafb;
    --bg-card: #ffffff;
    --text-main: #1f2937;
    --text-muted: #4b5563;
    --accent: #4f46e5;
    --accent-hover: #4338ca;
    --accent-light: #e0e7ff;
    --border: #e5e7eb;
    --font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    background-color: var(--bg-main);
    font-family: var(--font-family);
    color: var(--text-main);
    line-height: 1.625;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Hero fold iframe styling */
.hero-section {
    width: 100%;
    height: 100dvh;
    min-height: 100vh;
    background-color: #ffffff;
    border-bottom: 1px solid var(--border);
}

.hero-section iframe {
    display: block;
    width: 100%;
    height: 100%;
    border: none;
}

/* Main content layout grid */
.layout-container {
    display: grid;
    grid-template-columns: minmax(0, 760px) 280px;
    gap: 60px;
    max-width: 1100px;
    margin: 0 auto;
    padding: 60px 24px;
}

/* Responsive styles */
@media (max-width: 1024px) {
    .layout-container {
        grid-template-columns: 1fr;
        gap: 0;
        padding: 40px 24px;
    }
    .sidebar-column {
        display: none;
    }
}

@media (max-width: 640px) {
    .layout-container {
        padding: 30px 16px;
    }
}

/* Article content styling */
.article-title {
    font-size: clamp(2rem, 5vw, 3rem);
    font-weight: 700;
    line-height: 1.15;
    letter-spacing: -0.025em;
    color: #111827;
    margin-bottom: 8px;
}

.subtitle {
    font-size: 1.25rem;
    font-weight: 500;
    color: var(--text-muted);
    line-height: 1.5;
    margin-bottom: 32px;
}

.page-meta {
    font-size: 0.85rem;
    color: #888;
    margin-top: -0.5rem;
    margin-bottom: 1.5rem;
}

.intro-paragraph {
    font-size: 1.25rem;
    color: var(--text-muted);
    line-height: 1.6;
    margin-bottom: 20px;
}

h2 {
    font-size: 1.75rem;
    font-weight: 600;
    color: #111827;
    margin-top: 56px;
    margin-bottom: 16px;
    letter-spacing: -0.02em;
}

h3 {
    font-size: 1.25rem;
    font-weight: 600;
    color: #111827;
    margin-top: 40px;
    margin-bottom: 12px;
    letter-spacing: -0.01em;
}

p {
    font-size: 1.0625rem;
    color: var(--text-main);
    margin-bottom: 20px;
}

ul, ol {
    margin-bottom: 24px;
    padding-left: 24px;
}

li {
    margin-bottom: 8px;
    font-size: 1.0625rem;
}

li strong {
    color: #111827;
}

/* Case study styling */
.case-study {
    background-color: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 24px 28px;
    margin: 28px 0;
}

.case-study p:last-child, .case-study ul:last-child {
    margin-bottom: 0;
}

/* Image block styling */
.article-image {
    margin: 36px 0;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.article-image img {
    display: block;
    width: 100%;
    height: auto;
    max-width: 100%;
    border-radius: 12px;
    border: 1px solid var(--border);
}

.article-image figcaption {
    margin-top: 12px;
    font-size: 0.875rem;
    color: var(--text-muted);
    text-align: center;
    line-height: 1.4;
    max-width: 90%;
}

.section-divider {
    border: none;
    border-top: 1px solid var(--border);
    margin: 50px 0;
}

/* Chat CTA Card Styles */
.chat-widget-card {
    background-color: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 24px;
    margin: 32px 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.02);
}

.widget-text {
    font-size: 1.0625rem;
    font-weight: 500;
    color: var(--text-main);
    margin-bottom: 0;
    line-height: 1.5;
}

.widget-btn {
    background-color: var(--accent);
    color: #ffffff;
    font-size: 0.9375rem;
    font-weight: 600;
    border: none;
    border-radius: 8px;
    padding: 12px 20px;
    cursor: pointer;
    white-space: nowrap;
    transition: background-color 0.2s, transform 0.1s;
}

.widget-btn:hover {
    background-color: var(--accent-hover);
}

.widget-btn:active {
    transform: scale(0.98);
}

@media (max-width: 640px) {
    .chat-widget-card {
        flex-direction: column;
        align-items: stretch;
        text-align: center;
        padding: 20px;
    }
    .widget-btn {
        width: 100%;
    }
}

/* FAQ Accordion Styling */
details.faq-item {
    border-bottom: 1px solid var(--border);
    padding: 18px 0;
    transition: padding 0.2s ease;
}

details.faq-item:last-of-type {
    border-bottom: none;
}

details.faq-item[open] {
    padding-bottom: 24px;
}

summary.faq-question {
    font-size: 1.125rem;
    font-weight: 600;
    color: #111827;
    margin-bottom: 0;
    cursor: pointer;
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    user-select: none;
    outline: none;
}

summary.faq-question::-webkit-details-marker {
    display: none;
}

.faq-arrow {
    display: block;
    width: 20px;
    height: 20px;
    position: relative;
    flex-shrink: 0;
}

.faq-arrow::before,
.faq-arrow::after {
    content: '';
    position: absolute;
    background-color: var(--text-muted);
    transition: transform 0.25s ease, background-color 0.25s ease;
}

.faq-arrow::before {
    top: 9px;
    left: 4px;
    width: 12px;
    height: 2px;
}

.faq-arrow::after {
    top: 4px;
    left: 9px;
    width: 2px;
    height: 12px;
}

details[open] summary.faq-question {
    margin-bottom: 12px;
}

details[open] .faq-arrow::after {
    transform: rotate(90deg);
    opacity: 0;
}

details[open] .faq-arrow::before {
    transform: rotate(180deg);
    background-color: var(--accent);
}

.faq-answer {
    font-size: 1.0625rem;
    color: var(--text-muted);
    line-height: 1.6;
    margin-bottom: 0;
}

/* Sidebar outliner styles */
.sidebar-column {
    position: relative;
}

.outliner-nav {
    position: sticky;
    top: 40px;
    max-height: calc(100vh - 80px);
    overflow-y: auto;
    padding-left: 4px;
}

.outliner-title {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    margin-bottom: 16px;
}

.outliner-list {
    list-style: none;
    padding-left: 0;
}

.outliner-list li {
    margin-bottom: 8px;
}

.outliner-link {
    display: block;
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.9375rem;
    padding: 4px 12px;
    border-left: 2px solid transparent;
    transition: color 0.15s ease, border-color 0.15s ease;
}

.h2-link {
    font-weight: 500;
}

.outliner-link:hover {
    color: var(--text-main);
}

/* Scrollspy active states */
.outliner-link.active {
    color: var(--accent);
    border-left-color: var(--accent);
    font-weight: 600;
    background-color: var(--accent-light);
    border-top-right-radius: 4px;
    border-bottom-right-radius: 4px;
}

/* FAQ Section full-width style */
.faq-section {
    background-color: var(--bg-card);
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
    padding: 80px 24px;
}

.faq-container {
    max-width: 760px;
    margin: 0 auto;
}

.faq-section-title {
    font-size: 2rem;
    font-weight: 700;
    color: #111827;
    margin-bottom: 40px;
    text-align: left;
    letter-spacing: -0.025em;
}

.faq-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* Site footer style */
.site-footer {
    background-color: #111827;
    color: #e5e7eb;
    padding: 48px 24px;
    font-size: 0.875rem;
}

.site-footer p {
    color: #e5e7eb;
    font-size: 0.875rem;
    margin-bottom: 0;
}

.footer-container {
    max-width: 1100px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
}

.footer-copyright {
    margin-bottom: 0;
}

.footer-links {
    margin-bottom: 0;
}

.footer-links a {
    color: #e5e7eb;
    text-decoration: none;
    transition: color 0.15s ease;
}

.footer-links a:hover {
    color: #ffffff;
}

@media (max-width: 640px) {
    .faq-section {
        padding: 50px 16px;
    }
    .footer-container {
        flex-direction: column;
        text-align: center;
        gap: 12px;
    }
}
