/* ==========================================================================
   MoneyTool.io — Learning Center Article
   What is Business Finance
   ========================================================================== */

/* --------------------------------------------------------------------------
   ARTICLE META ROW (in hero)
   -------------------------------------------------------------------------- */
.article-meta-row {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-top: 20px;
}

.article-meta-item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.9rem;
    color: #475569;
}

.article-meta-item b {
    color: #0d6e6e;
    font-weight: 700;
}

/* --------------------------------------------------------------------------
   ARTICLE HERO — Centered layout
   -------------------------------------------------------------------------- */
.article-hero .learning-category-hero-inner {
    max-width: 860px;
    margin: 0 auto;
    text-align: center;
}

.article-hero .learning-category-hero-lead {
    margin-left: auto;
    margin-right: auto;
}

.article-hero .article-meta-row {
    justify-content: center;
}

/* --------------------------------------------------------------------------
   ARTICLE BODY LAYOUT (TOC + content)
   -------------------------------------------------------------------------- */
.article-body-section {
    padding: 48px 0 64px;
    background: #ffffff;
}

.article-body-grid {
    display: grid;
    grid-template-columns: 260px 1fr;
    gap: 48px;
    align-items: start;
}

/* --------------------------------------------------------------------------
   TABLE OF CONTENTS
   -------------------------------------------------------------------------- */
.article-toc {
    position: sticky;
    top: 90px;
    padding: 20px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
}

.article-toc-title {
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #64748b;
    margin: 0 0 14px;
}

.article-toc-list {
    list-style: none;
    margin: 0;
    padding: 0;
    counter-reset: toc;
}

.article-toc-list li {
    counter-increment: toc;
    margin-bottom: 8px;
}

.article-toc-list li a {
    display: flex;
    gap: 8px;
    font-size: 0.85rem;
    line-height: 1.5;
    color: #1e293b;
    text-decoration: none;
    transition: color 0.2s;
}

.article-toc-list li a::before {
    content: counter(toc) ".";
    color: #0d6e6e;
    font-weight: 600;
    flex-shrink: 0;
}

.article-toc-list li a:hover {
    color: #0d6e6e;
    text-decoration: underline;
}

/* --------------------------------------------------------------------------
   ARTICLE CONTENT
   -------------------------------------------------------------------------- */
.article-content {
    min-width: 0;
}

.article-section {
    margin-bottom: 48px;
    scroll-margin-top: 90px;
}

.article-section h2 {
    font-size: 1.6rem;
    font-weight: 700;
    line-height: 1.3;
    color: #0f172a;
    margin: 0 0 18px;
    padding-bottom: 10px;
    border-bottom: 2px solid #e2e8f0;
    letter-spacing: -0.01em;
}

.article-section h3 {
    font-size: 1.15rem;
    font-weight: 600;
    color: #0f172a;
    margin: 26px 0 12px;
}

.article-section p {
    font-size: 1rem;
    line-height: 1.75;
    color: #1e293b;
    margin: 0 0 16px;
}

.article-section a {
    color: #0a5555;
    text-decoration: underline;
    text-decoration-color: rgba(13, 110, 110, 0.4);
    text-underline-offset: 3px;
    transition: color 0.2s, text-decoration-color 0.2s;
}

.article-section a:hover {
    color: #0d6e6e;
    text-decoration-color: #0d6e6e;
}

.article-section ul,
.article-section ol {
    margin: 0 0 20px;
    padding-left: 24px;
}

.article-section li {
    font-size: 1rem;
    line-height: 1.7;
    color: #1e293b;
    margin-bottom: 8px;
}

/* --------------------------------------------------------------------------
   CALLOUTS
   -------------------------------------------------------------------------- */
.article-callout {
    padding: 16px 20px;
    margin: 22px 0;
    border-radius: 8px;
    font-size: 0.95rem;
    line-height: 1.65;
    color: #1e293b;
}

.article-callout strong {
    display: block;
    margin-bottom: 6px;
}

.article-callout ul {
    margin: 8px 0 0;
    padding-left: 20px;
}

.article-callout li {
    margin-bottom: 4px;
    font-size: 0.95rem;
}

.article-callout-info {
    background: #eff6ff;
    border-left: 4px solid #3b82f6;
}

.article-callout-tip {
    background: #f0fdf4;
    border-left: 4px solid #22c55e;
}

.article-callout-action {
    background: #fffbeb;
    border-left: 4px solid #f59e0b;
}

.article-callout-tool {
    background: #e6f4f4;
    border-left: 4px solid #0d6e6e;
}

/* --------------------------------------------------------------------------
   TABLES — dark teal header with white text
   -------------------------------------------------------------------------- */
.article-table-wrap {
    width: 100%;
    overflow-x: auto;
    margin: 22px 0;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    -webkit-overflow-scrolling: touch;
}

.article-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.92rem;
    min-width: 520px;
}

.article-table thead {
    background: #0d6e6e;
}

.article-table th {
    text-align: left;
    padding: 12px 16px;
    font-weight: 600;
    font-size: 0.82rem;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    color: #ffffff;
    background: transparent;
    border-bottom: 2px solid #0a5555;
}

.article-table td {
    padding: 12px 16px;
    color: #1e293b;
    line-height: 1.55;
    border-bottom: 1px solid #e2e8f0;
    vertical-align: top;
}

.article-table tbody tr:last-child td {
    border-bottom: none;
}

.article-table tbody tr:hover {
    background: #f8fafc;
}

.article-table-total td {
    background: #e6f4f4;
    color: #0a5555;
    font-weight: 700;
}

/* --------------------------------------------------------------------------
   TOOL CARDS
   -------------------------------------------------------------------------- */
.article-tool-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px;
    margin: 22px 0;
}

.article-tool-card {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 18px;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    text-decoration: none;
    transition: transform 0.2s, box-shadow 0.2s, border-color 0.2s;
}

.article-tool-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 18px rgba(15, 23, 42, 0.08);
    border-color: #0d6e6e;
    text-decoration: none;
}

.article-tool-icon {
    font-size: 1.6rem;
    line-height: 1;
    flex-shrink: 0;
}

.article-tool-card h3 {
    font-size: 0.98rem;
    font-weight: 600;
    color: #0f172a;
    margin: 0 0 4px;
}

.article-tool-card p {
    font-size: 0.83rem;
    color: #64748b;
    line-height: 1.5;
    margin: 0;
}

.article-tool-card b {
    margin-left: auto;
    color: #0d6e6e;
    font-size: 1.1rem;
    flex-shrink: 0;
}

/* --------------------------------------------------------------------------
   RELATED GUIDES
   -------------------------------------------------------------------------- */
.article-related-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px;
    margin: 22px 0;
}

.article-related-card {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 18px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    text-decoration: none;
    transition: background 0.2s, border-color 0.2s, transform 0.2s;
}

.article-related-card:hover {
    background: #ffffff;
    border-color: #0d6e6e;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.06);
    text-decoration: none;
}

.article-related-tag {
    display: inline-block;
    align-self: flex-start;
    padding: 3px 10px;
    background: #e6f4f4;
    color: #0a5555;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-radius: 100px;
}

.article-related-card h3 {
    font-size: 0.98rem;
    font-weight: 600;
    color: #0f172a;
    margin: 0;
    line-height: 1.4;
}

.article-related-card p {
    font-size: 0.83rem;
    color: #64748b;
    line-height: 1.5;
    margin: 0;
}

/* --------------------------------------------------------------------------
   RESOURCE LIST
   -------------------------------------------------------------------------- */
.article-resource-list {
    list-style: none;
    padding-left: 0;
    margin: 18px 0;
}

.article-resource-list li {
    padding: 14px 0;
    border-bottom: 1px solid #e2e8f0;
    font-size: 0.95rem;
    line-height: 1.6;
}

.article-resource-list li:last-child {
    border-bottom: none;
}

/* --------------------------------------------------------------------------
   FAQ
   -------------------------------------------------------------------------- */
.article-faq {
    border-top: 1px solid #e2e8f0;
}

.article-faq-item {
    border-bottom: 1px solid #e2e8f0;
}

.article-faq-item summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 18px 0;
    font-size: 1rem;
    font-weight: 600;
    color: #0f172a;
    cursor: pointer;
    list-style: none;
    transition: color 0.2s;
}

.article-faq-item summary::-webkit-details-marker {
    display: none;
}

.article-faq-item summary span {
    color: #0d6e6e;
    font-size: 1.4rem;
    font-weight: 400;
    line-height: 1;
    flex-shrink: 0;
    transition: transform 0.2s;
}

.article-faq-item[open] summary span {
    transform: rotate(45deg);
}

.article-faq-item summary:hover {
    color: #0d6e6e;
}

.article-faq-answer {
    padding: 0 0 18px;
}

.article-faq-answer p {
    font-size: 0.95rem;
    line-height: 1.7;
    color: #475569;
    margin: 0;
}

/* --------------------------------------------------------------------------
   LEGAL / DISCLAIMER
   -------------------------------------------------------------------------- */
.article-legal-section {
    margin-top: 48px;
    padding: 24px;
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
}

.article-legal-section h2 {
    font-size: 1rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #64748b;
    margin: 0 0 12px;
    padding: 0;
    border: none;
}

.article-legal-section p {
    font-size: 0.85rem;
    line-height: 1.65;
    color: #475569;
    margin: 0 0 10px;
}

.article-legal-section p:last-child {
    margin-bottom: 0;
}

/* --------------------------------------------------------------------------
   RESPONSIVE
   -------------------------------------------------------------------------- */
@media (max-width: 992px) {
    .article-body-grid {
        grid-template-columns: 1fr;
        gap: 32px;
    }

    .article-toc {
        position: static;
    }
}

@media (max-width: 768px) {
    .article-body-section {
        padding: 32px 0 48px;
    }

    .article-section h2 {
        font-size: 1.3rem;
    }

    .article-section h3 {
        font-size: 1.05rem;
    }

    .article-meta-row {
        gap: 12px;
    }

    .article-meta-item {
        font-size: 0.82rem;
    }

    .article-tool-grid,
    .article-related-grid {
        grid-template-columns: 1fr;
    }

    .article-table th,
    .article-table td {
        padding: 10px 12px;
        font-size: 0.85rem;
    }

    .article-faq-item summary {
        font-size: 0.95rem;
        padding: 14px 0;
    }
}

@media (max-width: 480px) {
    .article-section {
        margin-bottom: 36px;
    }

    .article-callout {
        padding: 14px 16px;
        font-size: 0.9rem;
    }
}

/* --------------------------------------------------------------------------
   PRINT
   -------------------------------------------------------------------------- */
@media print {
    .article-toc,
    .article-tool-grid,
    .article-related-grid {
        display: none;
    }

    .article-section a {
        color: #1e293b;
        text-decoration: none;
    }

    .article-faq-item {
        page-break-inside: avoid;
    }

    .article-faq-answer {
        display: block !important;
    }
}