/* Styles for static pages like About, Contact, and Blog Posts */
.static-page-content {
    max-width: 800px;
    margin: 0 auto;
    line-height: 1.7;
}

.static-page-content h1 {
    font-size: 2.8rem;
    margin-bottom: 1rem;
}

.static-page-content h2 {
    font-size: 2rem;
    margin-top: 2.5rem;
    margin-bottom: 1rem;
    border-bottom: 2px solid #f1f3f5;
    padding-bottom: 0.5rem;
}

.static-page-content p {
    margin-bottom: 1.2rem;
    font-size: 1.1rem;
    color: #343a40;
}

.static-page-content ul {
    padding-left: 20px;
}

.static-page-content li {
    margin-bottom: 0.8rem;
    font-size: 1.1rem;
}

.post-meta {
    color: #6c757d;
    font-style: italic;
    margin-bottom: 1rem; /* Adjusted for card layout */
}

/* =================================================================
   NEW: Scoped Styles for the Main Blog Page Grid
   ================================================================= */

.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.blog-card {
    background: #fff;
    border: 1px solid #e9ecef;
    border-radius: 16px;
    padding: 2rem;
    display: flex;
    flex-direction: column;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.blog-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.08);
}

.blog-card h3 {
    font-size: 1.4rem;
    margin-top: 0;
    margin-bottom: 0.5rem;
}

.blog-card h3 a {
    text-decoration: none;
    color: #212529;
}

.blog-card h3 a:hover {
    color: #007bff;
}

.blog-card .excerpt {
    flex-grow: 1;
    color: #495057;
    font-size: 1rem;
    line-height: 1.6;
}

.blog-card .btn-read-more {
    margin-top: 1rem;
    font-weight: 600;
    color: #007bff;
    text-decoration: none;
}

/* =================================================================
   Blog Grid Styles
   ================================================================= */

.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.blog-card {
    background: #fff;
    border: 1px solid #e9ecef;
    border-radius: 16px;
    padding: 2rem;
    display: flex;
    flex-direction: column;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.blog-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.08);
}

.blog-card h3 {
    font-size: 1.4rem;
    margin-top: 0;
    margin-bottom: 0.5rem;
}

.blog-card h3 a {
    text-decoration: none;
    color: #212529;
}

.blog-card h3 a:hover {
    color: #007bff;
}

.blog-card .post-meta {
    font-size: 0.9rem;
    color: #6c757d;
    margin-bottom: 1rem;
}

.blog-card .excerpt {
    flex-grow: 1;
    color: #495057;
    font-size: 1rem;
    line-height: 1.6;
}

.blog-card .btn-read-more {
    margin-top: 1rem;
    font-weight: 600;
    color: #007bff;
    text-decoration: none;
}

/* =================================================================
   Contact Form Styles
   ================================================================= */

.contact-form {
    margin-top: 3rem;
    background: #fff;
    padding: 2.5rem;
    border-radius: 16px;
    border: 1px solid #e9ecef;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: #343a40;
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group textarea {
    width: 100%;
    padding: 0.8rem 1rem;
    border: 1px solid #ced4da;
    border-radius: 8px;
    font-size: 1rem;
    font-family: inherit;
    transition: border-color 0.3s, box-shadow 0.3s;
    box-sizing: border-box; /* <<< THIS IS THE FIX */
}


.form-group input[type="text"]:focus,
.form-group input[type="email"]:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #007bff;
    box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.25);
}

.form-group textarea {
    resize: vertical;
    min-height: 150px;
}

.contact-form .btn-primary {
    background-color: #007bff;
    color: #fff;
    padding: 0.8rem 2rem;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.3s;
}

.contact-form .btn-primary:hover {
    background-color: #0056b3;
}

.form-success-message {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
    padding: 1.5rem;
    border-radius: 8px;
    margin-top: 2rem;
    text-align: center;
    font-size: 1.1rem;
}

.form-error-message {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
    padding: 1rem;
    border-radius: 8px;
    margin-bottom: 1.5rem;
}

/* =================================================================
   UNIFIED TOOL PAGE STYLESHEET
   ================================================================= */

/* --- Tool Page Header --- */
.tool-header {
    background: #fff;
    padding: 3rem 1.5rem;
    text-align: center;
    border-bottom: 1px solid #e9ecef;
}
.tool-header h1 {
    font-size: 2.8rem;
    margin: 0 0 0.5rem 0;
    color: #141E30; /* Dark Blue from new theme */
}
.tool-header p {
    font-size: 1.1rem;
    color: #666;
    max-width: 700px;
    margin: 0 auto;
}

/* --- Main Tool Form Container --- */
.tool-form-container {
    background: #fff;
    padding: 2.5rem;
    border-radius: 16px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.07);
    max-width: 800px;
    margin: 2rem auto; /* Center the form container */
}

/* --- Form Elements --- */
.form-group {
    margin-bottom: 1.5rem;
}
.form-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 0.75rem;
    font-size: 1.1rem;
}
.form-group input[type="text"],
.form-group input[type="url"],
.form-group input[type="file"],
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 0.8rem 1rem;
    border: 1px solid #ced4da;
    border-radius: 8px;
    font-size: 1rem;
    font-family: inherit;
    box-sizing: border-box;
    transition: border-color 0.3s, box-shadow 0.3s;
}
.form-group input[type="file"] {
    padding: 0.5rem 1rem;
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #00BFA5; /* Teal focus color */
    box-shadow: 0 0 0 3px rgba(0, 191, 165, 0.25);
}

/* --- Buttons --- */
.btn-primary {
    background-color: #00BFA5; /* Teal Button */
    color: #fff;
    padding: 0.8rem 2rem;
    border: none;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: background-color 0.3s;
    display: inline-block;
    text-align: center;
}
.btn-primary:hover {
    background-color: #00A08A; /* Darker Teal */
}
.btn-primary[disabled] {
    background-color: #aaa;
    cursor: not-allowed;
}

/* --- Result & Message Boxes --- */
.result-container {
    margin-top: 2rem;
    padding: 2rem;
    border: 1px solid #e9ecef;
    border-radius: 16px;
    background-color: #f8f9fa;
}
.success-message {
    color: #155724;
    background-color: #d4edda;
    border: 1px solid #c3e6cb;
    padding: 1rem;
    border-radius: 8px;
    margin-bottom: 1.5rem;
}
.error-message {
    color: #721c24;
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
    padding: 1rem;
    border-radius: 8px;
    margin-bottom: 1.5rem;
}

/* =================================================
   SECONDARY BUTTON STYLE (This was missing)
   ================================================= */

.btn-secondary {
    background-color: #6c757d;
    color: #fff;
    padding: 0.8rem 2rem;
    border: none;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: background-color 0.3s;
    text-decoration: none;
    display: inline-block;
    text-align: center;
}

.btn-secondary:hover {
    background-color: #5a6268;
}

/* --- Site Footer (from original inline styles) --- */
.site-footer {
    background-color: #0d1b2a;
    color: #adb5bd;
    padding: 3rem 1.5rem;
    margin-top: 4rem;
    text-align: center;
}

/* THIS IS THE FIX: Ensures the copyright and nav are on separate lines */
.site-footer p,
.site-footer .footer-nav {
    width: 100%;
}

.footer-nav {
    margin-top: 1rem;
}

.footer-nav a {
    color: #ced4da;
    text-decoration: none;
    margin: 0 10px;
}
