/* =========================================================
   BLOG PAGES (listing + single)
   Shared header/footer styles come from basestyle.css.
   ========================================================= */

.blog-page {
    --blog-teal: #269797;
    --blog-teal-dark: #0C3131;
    --blog-orange: #FE572A;
    --blog-text: #1d1d1d;
    --blog-muted: #5f5f5f;
    --blog-border: #dcdcdc;
    background: #ffffff;
    color: var(--blog-text);
}

.blog-container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 16px;
}

/* ---------- Buttons ---------- */
.blog-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 20px;
    color: #ffffff;
    background: var(--blog-orange);
    border: 0;
    border-radius: 50px;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.2;
    text-decoration: none;
    transition: background-color 0.25s ease;
}

.blog-btn:hover {
    color: #ffffff;
    background: #064241;
}

/* ---------- Hero ---------- */
.blog-hero {
    position: relative;
    padding: 64px 0 60px;
    background: #050c0d url('./images/Book-demo/book-demo-hero.png') no-repeat center / cover;
    text-align: center;
}

.blog-hero-badge {
    display: inline-block;
    margin-bottom: 18px;
    padding: 9px 20px;
    color: #ffffff;
    background: linear-gradient(180deg, var(--blog-teal) 0%, #105555 100%);
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 50px;
    font-size: 14px;
    font-weight: 500;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.blog-hero h1 {
    max-width: 680px;
    margin: 0 auto 22px;
    color: #ffffff;
    font-size: 32px;
    font-weight: 600;
    line-height: 1.25;
}

.blog-single-hero {
    padding: 84px 0;
}

.blog-single-hero h1 {
    max-width: 800px;
    margin-bottom: 0;
    font-size: 30px;
}

.blog-search {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    max-width: 540px;
    margin: 0 auto;
}

.blog-search input {
    flex: 1;
    min-width: 0;
    height: 44px;
    padding: 0 20px;
    color: var(--blog-text);
    background: #ffffff;
    border: 0;
    border-radius: 50px;
    font-size: 14px;
    outline: none;
}

.blog-search input::placeholder {
    color: #8a8a8a;
}

.blog-search .blog-btn {
    height: 44px;
    padding: 0 26px;
    font-size: 14px;
}

/* ---------- Listing ---------- */
.blog-listing {
    padding: 48px 0 60px;
}

.blog-featured {
    display: grid;
    grid-template-columns: 50% 50%;
    align-items: center;
    margin-bottom: 60px;
    overflow: hidden;
    background: linear-gradient(135deg, var(--blog-teal) 0%, var(--blog-teal-dark) 100%);
    border-left: 4px solid var(--blog-orange);
    border-radius: 18px;
}

.blog-featured-media {
    display: block;
}

/* Keep the full 16:9 featured image visible instead of cropping it. */
.blog-featured-media img {
    display: block;
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    border-radius: 18px;
}

.blog-featured-body {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    padding: 32px 40px;
    color: #ffffff;
}

.blog-featured-badge {
    margin-bottom: 18px;
    padding: 8px 18px;
    color: var(--blog-text);
    background: #ffffff;
    border-radius: 50px;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.3px;
    text-transform: uppercase;
}

.blog-featured-body h2 {
    max-width: 440px;
    margin: 0 0 14px;
    font-size: 26px;
    font-weight: 600;
    line-height: 1.3;
}

.blog-featured-body h2 a {
    color: inherit;
    text-decoration: none;
}

.blog-featured-body p {
    max-width: 510px;
    margin: 0 0 18px;
    color: rgba(255, 255, 255, 0.85);
    font-size: 14px;
    line-height: 1.5;
}

.blog-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 50px 22px;
}

.blog-card-media {
    display: block;
    height: 216px;
    overflow: hidden;
    border-top: 5px solid var(--blog-teal);
    border-radius: 8px;
}

.blog-card-media img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.blog-card:hover .blog-card-media img {
    transform: scale(1.04);
}

.blog-card h3 {
    max-width: 320px;
    margin: 16px 0 10px;
    font-size: 19px;
    font-weight: 600;
    line-height: 1.3;
}

.blog-card h3 a {
    color: var(--blog-text);
    text-decoration: none;
}

.blog-card h3 a:hover {
    color: var(--blog-teal);
}

.blog-card p {
    margin: 0 0 12px;
    color: var(--blog-muted);
    font-size: 13px;
    line-height: 1.55;
}

.blog-meta {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 14px;
    color: var(--blog-text);
    font-size: 12px;
}

.blog-meta i {
    margin-right: 4px;
}

.blog-meta .blog-read-time {
    color: var(--blog-teal);
}

.blog-pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-top: 56px;
    padding: 0;
    list-style: none;
}

.blog-pagination a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    color: var(--blog-text);
    background: #ffffff;
    border: 1px solid var(--blog-border);
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
}

.blog-pagination a:hover {
    border-color: var(--blog-teal);
}

.blog-pagination a.active {
    color: #ffffff;
    background: linear-gradient(180deg, var(--blog-teal) 0%, var(--blog-teal-dark) 100%);
    border-color: transparent;
}

/* Shown when a post has no image */
.blog-image-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    min-height: inherit;
    background: linear-gradient(135deg, var(--blog-teal) 0%, var(--blog-teal-dark) 100%);
    border-radius: inherit;
}

.blog-image-placeholder img {
    width: 45%;
    max-width: 180px;
    height: auto !important;
    object-fit: contain !important;
    border: 0 !important;
    opacity: 0.9;
}

.blog-featured-media .blog-image-placeholder {
    min-height: 290px;
    border-radius: 18px;
}

.blog-recent-item .blog-image-placeholder {
    flex-shrink: 0;
    width: 120px;
    height: 84px;
    border-top: 4px solid var(--blog-teal);
    border-radius: 6px;
}

.blog-results-note {
    margin: 0 0 28px;
    color: var(--blog-muted);
    font-size: 15px;
}

.blog-results-note a {
    margin-left: 8px;
    color: var(--blog-teal);
}

.blog-empty {
    padding: 60px 20px;
    text-align: center;
}

.blog-empty h2 {
    margin: 0 0 8px;
    font-size: 24px;
    font-weight: 600;
}

.blog-empty p {
    margin: 0;
    color: var(--blog-muted);
}

/* ---------- Single ---------- */
.blog-single-meta {
    display: flex;
    justify-content: center;
    gap: 22px;
    margin-top: 18px;
    color: rgba(255, 255, 255, 0.85);
    font-size: 14px;
}

.blog-single-meta i {
    margin-right: 6px;
}

.blog-article-content > :first-child {
    margin-top: 0;
}

.blog-article h3 {
    margin: 28px 0 14px;
    color: var(--blog-text);
    font-size: 18px;
    font-weight: 600;
}

.blog-article ol {
    margin: 0 0 16px;
    padding-left: 40px;
}

.blog-article a {
    color: var(--blog-teal);
}

.blog-article img {
    max-width: 100%;
    height: auto;
}

.blog-article blockquote {
    margin: 24px 0;
    padding: 16px 22px;
    color: var(--blog-text);
    background: #f3fafa;
    border-left: 4px solid var(--blog-teal);
    border-radius: 0 8px 8px 0;
}

.blog-takeaways {
    margin-bottom: 36px;
    padding: 22px 26px;
    background: #f3fafa;
    border: 1px solid var(--blog-teal);
    border-radius: 12px;
}

.blog-takeaways h3 {
    margin-top: 0;
}

.blog-takeaways ul {
    margin-bottom: 0;
    padding-left: 20px;
}

.blog-faqs,
.blog-sources {
    margin-top: 48px;
}

.blog-faq {
    margin-bottom: 12px;
    border: 1px solid var(--blog-border);
    border-radius: 10px;
}

.blog-faq summary {
    padding: 14px 18px;
    color: var(--blog-text);
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
}

.blog-faq[open] summary {
    border-bottom: 1px solid var(--blog-border);
}

.blog-faq > div {
    padding: 14px 18px;
}

.blog-faq > div > :last-child {
    margin-bottom: 0;
}

.blog-sources ol {
    padding-left: 20px;
}
.blog-single {
    padding: 60px 0 100px;
}

.blog-single-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 342px;
    gap: 22px;
    align-items: start;
}

.blog-article-image {
    margin-bottom: 40px;
    overflow: hidden;
    border-left: 4px solid var(--blog-orange);
    border-radius: 18px;
}

.blog-article-image img {
    display: block;
    width: 100%;
    height: 360px;
    object-fit: cover;
}

.blog-article {
    color: var(--blog-text);
    font-size: 14px;
    line-height: 1.5;
}

.blog-article h2 {
    display: flex;
    align-items: center;
    gap: 14px;
    margin: 0 0 22px;
    color: var(--blog-text);
    font-size: 22px;
    font-weight: 600;
    scroll-margin-top: 110px;
}

.blog-article * + h2 {
    margin-top: 56px;
}

.blog-heading-num,
.blog-toc-num {
    display: inline-flex;
    flex-shrink: 0;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    background: linear-gradient(180deg, var(--blog-teal) 0%, var(--blog-teal-dark) 100%);
    border-radius: 50%;
    font-weight: 600;
}

.blog-heading-num {
    width: 36px;
    height: 36px;
    font-size: 16px;
}

.blog-article p {
    margin: 0 0 16px;
}

.blog-article strong {
    color: var(--blog-text);
}

.blog-article ul {
    margin: 0 0 16px;
    padding-left: 40px;
}

.blog-article li {
    margin-bottom: 2px;
}

.blog-article-figure {
    margin: 28px 0;
    text-align: center;
}

.blog-article-figure img {
    max-width: 100%;
    height: auto;
}

.blog-table-wrap {
    margin: 20px 0;
    overflow-x: auto;
}

.blog-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
    text-align: center;
}

.blog-table th {
    padding: 14px 18px;
    color: #ffffff;
    background: #4a4a4a;
    font-weight: 600;
}

.blog-table th:first-child {
    width: 35%;
    background: #2b2b2b;
}

.blog-table td {
    padding: 22px 26px;
    border: 1px solid #e6e6e6;
}

.blog-table td:first-child {
    color: var(--blog-text);
    font-weight: 600;
}

.blog-table tbody tr:nth-child(even) td {
    background: #f6f6f6;
}

/* ---------- Sidebar ---------- */
.blog-sidebar {
    display: flex;
    flex-direction: column;
    gap: 22px;
}

/* Desktop: sidebar spans the article height so the demo form can stick
   below the 90px navbar until the end of the article. The heading always stays
   visible; on short screens the form is compacted, and scrolls inside itself
   as a last resort, so the submit button stays reachable. */
@media (min-width: 992px) {
    .blog-sidebar {
        align-self: stretch;
    }

    .blog-sidebar .blog-demo-form {
        position: sticky;
        top: 105px;
        max-height: calc(100vh - 120px);
        overflow-y: auto;
    }
}

@media (min-width: 992px) and (max-height: 860px) {
    .blog-sidebar .blog-demo-form {
        padding: 18px 22px 20px;
    }

    .blog-sidebar .blog-demo-form h3 {
        margin-bottom: 12px;
        font-size: 24px;
    }

    .blog-sidebar .blog-form-group {
        margin-bottom: 11px;
    }

    .blog-sidebar .blog-form-group label {
        margin-bottom: 5px;
        font-size: 14px;
    }

    .blog-sidebar .blog-form-group input,
    .blog-sidebar .blog-form-group select,
    .blog-sidebar .blog-form-group textarea {
        padding-top: 8px;
        padding-bottom: 8px;
    }

    .blog-sidebar .blog-form-group textarea {
        min-height: 60px;
    }

    .blog-sidebar .blog-form-submit {
        min-height: 46px;
        margin-top: 2px;
    }
}

@media (min-width: 992px) and (max-height: 740px) {
    .blog-sidebar .blog-demo-form {
        padding: 14px 20px 16px;
    }

    .blog-sidebar .blog-demo-form h3 {
        margin-bottom: 8px;
        font-size: 21px;
    }

    .blog-sidebar .blog-form-group {
        margin-bottom: 7px;
    }

    .blog-sidebar .blog-form-group label {
        margin-bottom: 3px;
        font-size: 13px;
    }

    .blog-sidebar .blog-form-group input,
    .blog-sidebar .blog-form-group select,
    .blog-sidebar .blog-form-group textarea {
        padding-top: 6px;
        padding-bottom: 6px;
        border-width: 2px;
    }

    .blog-sidebar .blog-form-group textarea {
        min-height: 46px;
    }

    .blog-sidebar .blog-form-submit {
        min-height: 40px;
    }
}

.blog-sidebar h3 {
    margin: 0 0 14px;
    color: #3a3a3a;
    font-size: 20px;
    font-weight: 600;
}

.blog-toc {
    overflow: hidden;
    border: 1px solid var(--blog-teal);
    border-radius: 12px;
}

.blog-toc-toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 14px 20px;
    color: #ffffff;
    background: linear-gradient(180deg, var(--blog-teal) 0%, var(--blog-teal-dark) 100%);
    border: 0;
    border-radius: 0 0 12px 12px;
    font-size: 16px;
    font-weight: 500;
    text-align: left;
}

.blog-toc-toggle i {
    transition: transform 0.25s ease;
}

.blog-toc.is-collapsed .blog-toc-toggle i {
    transform: rotate(180deg);
}

.blog-toc ol {
    margin: 0;
    padding: 14px 20px 18px;
    list-style: none;
}

.blog-toc.is-collapsed ol {
    display: none;
}

.blog-toc li + li {
    margin-top: 12px;
}

.blog-toc a {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--blog-text);
    font-size: 14px;
    text-decoration: none;
}

.blog-toc a:hover {
    color: var(--blog-teal);
}

.blog-toc-num {
    width: 22px;
    height: 22px;
    font-size: 11px;
}

.blog-recent-list {
    display: flex;
    flex-direction: column;
    gap: 22px;
}

.blog-recent-item {
    display: flex;
    align-items: center;
    gap: 18px;
    color: var(--blog-text);
    text-decoration: none;
}

.blog-recent-item img {
    flex-shrink: 0;
    width: 120px;
    height: 84px;
    object-fit: cover;
    border-top: 4px solid var(--blog-teal);
    border-radius: 6px;
}

.blog-recent-item span {
    font-size: 13px;
    font-weight: 600;
    line-height: 1.3;
}

.blog-recent-item:hover span {
    color: var(--blog-teal);
}

.blog-modules {
    margin: 0;
    padding: 0;
    overflow: hidden;
    list-style: none;
    border: 1px solid #9a9a9a;
    border-radius: 12px;
    box-shadow: 0 3px 0 rgba(0, 0, 0, 0.25);
}

.blog-modules li + li {
    border-top: 1px solid #9a9a9a;
}

.blog-modules a {
    display: block;
    padding: 14px 16px;
    color: #0f6f6f;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
}

.blog-modules a:hover {
    color: #ffffff;
    background: var(--blog-teal);
}

/* Book a demo form */
.blog-demo-form {
    padding: 28px 26px 30px;
    color: #ffffff;
    background:
        repeating-linear-gradient(135deg, rgba(255, 255, 255, 0.025) 0 2px, transparent 2px 14px),
        #1f1f1f;
    border-radius: 16px;
}

.blog-demo-form h3 {
    margin: 0 0 22px;
    color: #ffffff;
    font-size: 28px;
    font-weight: 700;
    text-align: center;
}

.blog-form-group {
    margin-bottom: 18px;
}

.blog-form-group label {
    display: block;
    margin-bottom: 8px;
    font-size: 15px;
    font-weight: 600;
}

.blog-form-group input,
.blog-form-group select,
.blog-form-group textarea {
    display: block;
    width: 100%;
    padding: 12px 14px;
    color: var(--blog-text);
    background: #ffffff;
    border: 3px solid #2bb3b0;
    border-radius: 8px;
    font-size: 13px;
    outline: none;
}

.blog-form-group input::placeholder,
.blog-form-group textarea::placeholder {
    color: #9a9a9a;
}

.blog-form-group select {
    appearance: none;
    padding-right: 36px;
    background: #ffffff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M0 0h12L6 8z' fill='%23000'/%3E%3C/svg%3E") no-repeat right 14px center;
}

.blog-form-group textarea {
    min-height: 92px;
    resize: vertical;
}

.blog-phone-field {
    position: relative;
}

.blog-phone-field svg {
    position: absolute;
    top: 50%;
    left: 16px;
    width: 26px;
    height: 17px;
    transform: translateY(-50%);
}

.blog-phone-field input {
    padding-left: 54px;
}

.blog-form-submit {
    width: 100%;
    min-height: 54px;
    margin-top: 6px;
    color: #ffffff;
    background: linear-gradient(180deg, #FE572A 0%, #e8451a 100%);
    border: 0;
    border-radius: 50px;
    box-shadow: 0 3px 0 rgba(0, 0, 0, 0.3);
    font-size: 16px;
    font-weight: 600;
    transition: background 0.25s ease;
}

.blog-form-submit:hover {
    background: #064241;
}

.blog-form-submit:disabled {
    opacity: 0.7;
    cursor: wait;
}

.blog-form-message {
    margin-bottom: 12px;
    padding: 10px 12px;
    color: #ffffff;
    background: rgba(254, 87, 42, 0.2);
    border: 1px solid #FE572A;
    border-radius: 8px;
    font-size: 13px;
}

/* ---------- CTA (matches modules page) ---------- */
.blog-page .request-workflow {
    position: relative;
    overflow: hidden;
    padding: 82px 0;
    background: url('./images/Modules/module-demo.png') center / cover no-repeat;
}

.blog-page .request-workflow-content {
    text-align: center;
}

.blog-page .request-workflow-content h2 {
    max-width: 560px;
    margin: 0 auto 32px;
    color: #ffffff;
    font-size: 36px;
    font-weight: 700;
    line-height: 1.12;
    letter-spacing: -0.5px;
    text-transform: capitalize;
}

.blog-page .request-workflow-content h2 em {
    font-style: italic;
    font-weight: 500;
}

.blog-page .workflow-audit-box {
    width: 100%;
    max-width: 895px;
    margin: 0 auto;
    padding: 50px 64px 52px;
    background-color: rgba(4, 48, 48, 0.7);
    border-radius: 18px;
}

.blog-page .workflow-audit-box p {
    margin: 0 0 29px;
    color: #ffffff;
    font-size: 21px;
    line-height: 1.3;
}

.blog-page .workflow-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    width: 100%;
    min-height: 57px;
    padding: 15px 28px;
    color: #ffffff;
    background: #FE572A;
    border-radius: 51px;
    box-shadow: 0 3px 0 rgba(0, 0, 0, 0.25);
    font-size: 18px;
    font-weight: 700;
    line-height: 1;
    text-decoration: none;
    transition: all 0.25s ease;
}

.blog-page .workflow-btn:hover {
    color: #ffffff;
    background-color: #064241;
}

/* ---------- Responsive ---------- */
@media (max-width: 991px) {
    .blog-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 40px 20px;
    }

    .blog-featured-body {
        padding: 28px 28px;
    }

    .blog-single-layout {
        grid-template-columns: minmax(0, 1fr);
    }

    .blog-sidebar {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        align-items: start;
    }
}

@media (max-width: 767px) {
    .blog-hero {
        padding: 48px 0 44px;
    }

    .blog-hero h1,
    .blog-single-hero h1 {
        font-size: 24px;
    }

    .blog-single-hero {
        padding: 56px 0;
    }

    .blog-search .blog-btn {
        padding: 0 18px;
    }

    .blog-listing {
        padding: 32px 0 48px;
    }

    .blog-featured {
        grid-template-columns: 1fr;
        margin-bottom: 40px;
    }

    .blog-featured-media img {
        height: auto;
    }

    .blog-featured-body {
        padding: 24px 20px 28px;
    }

    .blog-featured-body h2 {
        font-size: 21px;
    }

    .blog-grid {
        grid-template-columns: 1fr;
        gap: 36px;
    }

    .blog-card-media {
        height: 200px;
    }

    .blog-pagination {
        margin-top: 40px;
    }

    .blog-single {
        padding: 36px 0 60px;
    }

    .blog-article-image img {
        height: 220px;
    }

    .blog-article h2 {
        font-size: 19px;
    }

    .blog-article * + h2 {
        margin-top: 40px;
    }

    .blog-article ul {
        padding-left: 22px;
    }

    .blog-table td {
        padding: 14px 12px;
    }

    .blog-sidebar {
        display: flex;
    }

    .blog-page .request-workflow {
        padding: 56px 0;
    }

    .blog-page .request-workflow-content h2 {
        font-size: 26px;
    }

    .blog-page .request-workflow-content h2 br {
        display: none;
    }

    .blog-page .workflow-audit-box {
        padding: 28px 20px;
    }

    .blog-page .workflow-audit-box p {
        font-size: 16px;
    }

    .blog-page .workflow-btn {
        min-height: 50px;
        padding: 14px 16px;
        font-size: 15px;
    }
}
