/* assets/css/style.css */

/* --- Global Styles & Variables --- */
:root {
    --primary-color: #005A9C; /* A professional blue */
    --secondary-color: #f8f9fa; /* Light gray for backgrounds */
    --accent-color: #ffc107;   /* A warm yellow for accents */
    --text-color: #333;
    --heading-font: 'Inter', sans-serif;
    --body-font: 'Inter', sans-serif;
}

body {
    font-family: var(--body-font);
    color: var(--text-color);
    background-color: #f4f7f6;
    line-height: 1.6;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--heading-font);
    font-weight: 700;
    color: var(--primary-color);
}

.navbar-brand {
    color: var(--primary-color) !important;
}

.nav-link.active {
    font-weight: 600;
    color: var(--primary-color) !important;
}

footer a {
    text-decoration: none;
    transition: color 0.3s ease;
}

footer a:hover {
    color: var(--accent-color) !important;
}

/* --- Main Content & Card Styling --- */
main {
    min-height: 70vh;
}

.card {
    border: none;
    border-radius: 0.75rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
}

.card-header {
    background-color: var(--primary-color);
    color: white;
    font-weight: 600;
    border-top-left-radius: 0.75rem;
    border-top-right-radius: 0.75rem;
}

/* --- Form & Calculator Styles --- */
.calculator-form {
    background-color: #ffffff;
    padding: 2.5rem;
    border-radius: 0.75rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.form-label {
    font-weight: 600;
    color: #555;
}

.form-control, .form-select {
    border-radius: 0.5rem;
}

.form-control:focus, .form-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.25rem rgba(0, 90, 156, 0.25);
}

.btn-primary {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    font-weight: 600;
    padding: 0.75rem 1.5rem;
    border-radius: 0.5rem;
    transition: background-color 0.3s ease, border-color 0.3s ease;
}

.btn-primary:hover {
    background-color: #004a80;
    border-color: #004a80;
}

/* --- Results Box --- */
.result-box {
    background-color: #e9f5ff; /* Light blue background */
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
    padding: 2rem;
    margin-top: 2rem;
    border-radius: 0.75rem;
    text-align: center;
}

.result-box h3 {
    margin-top: 0;
    font-size: 1.2rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.result-box .result-amount {
    font-size: 2.5rem;
    font-weight: 700;
}

/* --- Placeholder for AdSense --- */
.adsense-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #e9ecef;
    min-height: 100px;
    margin: 1.5rem 0;
    text-align: center;
    color: #6c757d;
    border: 2px dashed #ced4da;
    border-radius: 0.5rem;
}

/* --- Article & Resource Styles --- */
.article-card {
    height: 100%;
}

.article-card a {
    text-decoration: none;
    color: inherit;
}

.article-content h1, .article-content h2, .article-content h3 {
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.article-content p {
    margin-bottom: 1rem;
}

/* --- Typography Overrides --- */
/* Override Bootstrap's justified text on .lead elements */
.lead {
    text-align: left;
}

/* --- Homepage Tool Card Icon --- */
.tool-card .icon {
    display: block;
    margin: 0 auto 1rem auto;
    width: 50px;
    height: 50px;
}

/* --- Smart Ad Container Rules --- */
/* Fallback for browsers that don't support :has() - hides the label */
ins.adsbygoogle[data-ad-status="unfilled"] + small,
ins.adsbygoogle:empty + small {
    display: none !important;
}

/* Main rule for modern browsers - hides the entire container */
.ad-container:has(ins.adsbygoogle[data-ad-status="unfilled"]),
.ad-container:has(ins.adsbygoogle:empty) {
    display: none !important;
}
