/*
Theme Name: L6I Blog
Theme URI: https://l6isolutions.com
Author: L6I Quality Solutions
Author URI: https://l6isolutions.com
Description: Custom dark theme for L6I Quality Solutions blog — Governance, Risk & Compliance insights.
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Tags: dark, blog, minimal, professional
Text Domain: l6i-blog
*/

/* ============================================================
   NUCLEAR RESET — Override all WP defaults
   ============================================================ */

*, *::before, *::after {
    box-sizing: border-box !important;
    margin: 0;
    padding: 0;
}

html {
    font-size: 16px !important;
    scroll-behavior: smooth;
    background-color: #020617 !important;
}

body,
body.home,
body.blog,
body.single,
body.page,
body.wp-theme-l6i-blog {
    background-color: #020617 !important; /* slate-950 */
    color: #cbd5e1 !important; /* slate-300 */
    font-family: Arial, Helvetica, sans-serif !important;
    line-height: 1.7 !important;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    color: #22d3ee !important; /* cyan-400 */
    text-decoration: none;
    transition: color 0.2s ease, opacity 0.2s ease;
}

a:hover {
    color: #67e8f9; /* cyan-300 */
    text-decoration: underline;
}

h1, h2, h3, h4, h5, h6 {
    color: #ffffff !important;
    line-height: 1.3;
    font-weight: 700;
}

p {
    margin-bottom: 1rem;
}

ul, ol {
    padding-left: 1.5rem;
    margin-bottom: 1rem;
}

li {
    margin-bottom: 0.25rem;
}

blockquote {
    border-left: 3px solid #22d3ee;
    padding-left: 1.25rem;
    margin: 1.5rem 0;
    color: #94a3b8 !important; /* slate-400 */
    font-style: italic;
}

code {
    background-color: #1e293b !important; /* slate-800 */
    color: #22d3ee !important;
    padding: 0.15em 0.4em;
    border-radius: 4px;
    font-size: 0.9em;
    font-family: 'Courier New', Courier, monospace;
}

pre {
    background-color: #1e293b !important;
    border: 1px solid #334155; /* slate-700 */
    border-radius: 8px;
    padding: 1.25rem;
    overflow-x: auto;
    margin-bottom: 1.5rem;
}

pre code {
    background: none;
    padding: 0;
    font-size: 0.875rem;
}

hr {
    border: none;
    border-top: 1px solid #334155; /* slate-700 */
    margin: 2rem 0;
}

/* ============================================================
   LAYOUT
   ============================================================ */

.site-wrapper {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.site-main {
    flex: 1;
    padding: 3rem 0;
}

.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

.container--narrow {
    max-width: 760px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* ============================================================
   HEADER / NAV
   ============================================================ */

.site-header {
    background-color: #0f172a !important; /* slate-900 */
    border-bottom: 1px solid #1e293b; /* slate-800 */
    position: sticky;
    top: 0;
    z-index: 100;
}

.site-header .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
}

.site-logo {
    font-size: 1.125rem;
    font-weight: 700;
    color: #ffffff !important;
    text-decoration: none;
    letter-spacing: -0.01em;
    white-space: nowrap;
}

.site-logo:hover {
    color: #22d3ee !important;
    text-decoration: none;
}

.site-logo span {
    color: #22d3ee !important;
}

.site-nav {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.site-nav ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.site-nav ul li {
    margin: 0;
}

.site-nav ul li a {
    color: #94a3b8 !important; /* slate-400 */
    text-decoration: none;
    padding: 0.4rem 0.85rem;
    border-radius: 6px;
    font-size: 0.9rem;
    font-weight: 500;
    transition: color 0.2s ease, background-color 0.2s ease;
    white-space: nowrap;
}

.site-nav ul li a:hover,
.site-nav ul li a.current {
    color: #22d3ee !important;
    background-color: rgba(34, 211, 238, 0.08);
    text-decoration: none;
}

/* ============================================================
   FOOTER
   ============================================================ */

.site-footer {
    background-color: #0f172a !important; /* slate-900 */
    border-top: 1px solid #1e293b; /* slate-800 */
    padding: 2.5rem 0;
    margin-top: auto;
}

.site-footer .container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    text-align: center;
}

.footer-copyright {
    color: #94a3b8 !important; /* slate-400 */
    font-size: 0.875rem;
}

.footer-tagline {
    color: #64748b; /* slate-500 */
    font-size: 0.8rem;
}

.footer-veteran {
    color: #94a3b8 !important;
    font-size: 0.8rem;
    margin-top: 0.25rem;
}

/* ============================================================
   BLOG LISTING — INDEX
   ============================================================ */

.blog-header {
    margin-bottom: 2.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid #1e293b;
}

.blog-header h1 {
    font-size: 2rem;
    color: #ffffff !important;
    margin-bottom: 0.5rem;
}

.blog-header p {
    color: #94a3b8 !important;
    font-size: 1rem;
    margin: 0;
}

.blog-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
    margin-bottom: 3rem;
}

/* Post Card */
.post-card {
    background-color: rgba(30, 41, 59, 0.5); /* slate-800/50 */
    border: 1px solid #334155; /* slate-700 */
    border-radius: 10px;
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.post-card:hover {
    border-color: #22d3ee !important;
    box-shadow: 0 0 0 1px rgba(34, 211, 238, 0.15), 0 4px 20px rgba(34, 211, 238, 0.08);
    transform: translateY(-2px);
}

.post-card__thumbnail {
    border-radius: 6px;
    overflow: hidden;
    margin-bottom: 0.25rem;
}

.post-card__thumbnail img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-radius: 6px;
    transition: opacity 0.2s ease;
}

.post-card:hover .post-card__thumbnail img {
    opacity: 0.9;
}

.post-card__meta {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.post-card__date {
    color: #64748b; /* slate-500 */
    font-size: 0.8rem;
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.post-card__categories {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.category-tag {
    background-color: rgba(34, 211, 238, 0.1);
    color: #22d3ee !important;
    border: 1px solid rgba(34, 211, 238, 0.25);
    padding: 0.15rem 0.6rem;
    border-radius: 20px;
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    white-space: nowrap;
    text-decoration: none;
    transition: background-color 0.2s ease;
}

.category-tag:hover {
    background-color: rgba(34, 211, 238, 0.2);
    color: #22d3ee !important;
    text-decoration: none;
}

.post-card__title {
    font-size: 1.15rem;
    font-weight: 700;
    line-height: 1.35;
    margin: 0;
}

.post-card__title a {
    color: #ffffff !important;
    text-decoration: none;
    transition: color 0.2s ease;
}

.post-card__title a:hover {
    color: #22d3ee !important;
    text-decoration: none;
}

.post-card__excerpt {
    color: #94a3b8 !important; /* slate-400 */
    font-size: 0.9rem;
    line-height: 1.6;
    flex: 1;
    margin: 0;
}

.post-card__footer {
    margin-top: auto;
    padding-top: 0.75rem;
    border-top: 1px solid #1e293b;
}

.read-more {
    color: #22d3ee !important;
    font-size: 0.875rem;
    font-weight: 600;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    transition: gap 0.2s ease, color 0.2s ease;
}

.read-more:hover {
    color: #67e8f9;
    gap: 0.5rem;
    text-decoration: none;
}

.read-more::after {
    content: '→';
}

/* No posts state */
.no-posts {
    grid-column: 1 / -1;
    text-align: center;
    padding: 4rem 2rem;
    color: #64748b;
}

.no-posts h2 {
    color: #94a3b8 !important;
    margin-bottom: 0.5rem;
}

/* ============================================================
   PAGINATION
   ============================================================ */

.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    padding-top: 2rem;
    border-top: 1px solid #1e293b;
}

.pagination .page-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 0 0.75rem;
    border-radius: 6px;
    background-color: #1e293b !important;
    border: 1px solid #334155;
    color: #94a3b8 !important;
    font-size: 0.875rem;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.2s ease;
}

.pagination .page-numbers:hover {
    border-color: #22d3ee !important;
    color: #22d3ee !important;
    background-color: rgba(34, 211, 238, 0.08);
    text-decoration: none;
}

.pagination .page-numbers.current {
    background-color: #22d3ee !important;
    border-color: #22d3ee !important;
    color: #020617;
    font-weight: 700;
}

.pagination .page-numbers.dots {
    border: none;
    background: none;
    color: #64748b;
    cursor: default;
}

/* ============================================================
   SINGLE POST / PAGE
   ============================================================ */

.post-hero {
    margin-bottom: 2.5rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid #1e293b;
}

.post-hero__title {
    font-size: 2.25rem;
    font-weight: 800;
    color: #ffffff !important;
    line-height: 1.2;
    margin-bottom: 1rem;
    letter-spacing: -0.02em;
}

.post-hero__meta {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
    color: #64748b;
    font-size: 0.875rem;
}

.post-hero__date {
    color: #64748b;
}

.post-hero__categories {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.post-hero__thumbnail {
    margin-top: 2rem;
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid #334155;
}

.post-hero__thumbnail img {
    width: 100%;
    max-height: 420px;
    object-fit: cover;
}

/* Post content typography */
.post-content {
    font-size: 1rem;
    line-height: 1.8;
    color: #cbd5e1 !important; /* slate-300 */
}

.post-content h1 {
    font-size: 2rem;
    margin: 2rem 0 1rem;
    color: #ffffff !important;
}

.post-content h2 {
    font-size: 1.6rem;
    margin: 2rem 0 0.75rem;
    color: #22d3ee !important; /* cyan-400 — per spec */
    padding-bottom: 0.5rem;
    border-bottom: 1px solid rgba(34, 211, 238, 0.2);
}

.post-content h3 {
    font-size: 1.3rem;
    margin: 1.75rem 0 0.6rem;
    color: #ffffff !important;
}

.post-content h4 {
    font-size: 1.1rem;
    margin: 1.5rem 0 0.5rem;
    color: #e2e8f0 !important;
}

.post-content h5,
.post-content h6 {
    font-size: 1rem;
    margin: 1.25rem 0 0.4rem;
    color: #cbd5e1 !important;
}

.post-content p {
    margin-bottom: 1.25rem;
}

.post-content ul,
.post-content ol {
    margin-bottom: 1.25rem;
    color: #cbd5e1 !important;
}

.post-content ul li::marker {
    color: #22d3ee !important;
}

.post-content a {
    color: #22d3ee !important;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.post-content a:hover {
    color: #67e8f9;
}

.post-content strong {
    color: #f1f5f9; /* slate-100 */
    font-weight: 700;
}

.post-content em {
    color: #cbd5e1 !important;
}

.post-content table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 1.5rem;
    font-size: 0.9rem;
}

.post-content table th {
    background-color: #1e293b !important;
    color: #22d3ee !important;
    padding: 0.75rem 1rem;
    text-align: left;
    border-bottom: 2px solid #334155;
    font-weight: 600;
}

.post-content table td {
    padding: 0.65rem 1rem;
    border-bottom: 1px solid #1e293b;
    color: #cbd5e1 !important;
}

.post-content table tr:hover td {
    background-color: rgba(30, 41, 59, 0.4);
}

.post-content img {
    border-radius: 8px;
    border: 1px solid #334155;
    margin: 1.5rem 0;
}

/* Post footer */
.post-footer {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid #1e293b;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: gap;
    gap: 1rem;
}

.back-to-blog {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    color: #94a3b8 !important;
    font-size: 0.875rem;
    text-decoration: none;
    padding: 0.5rem 1rem;
    border: 1px solid #334155;
    border-radius: 6px;
    background-color: rgba(30, 41, 59, 0.5);
    transition: all 0.2s ease;
}

.back-to-blog:hover {
    border-color: #22d3ee !important;
    color: #22d3ee !important;
    background-color: rgba(34, 211, 238, 0.08);
    text-decoration: none;
}

.back-to-blog::before {
    content: '←';
}

/* ============================================================
   404 PAGE
   ============================================================ */

.error-404 {
    text-align: center;
    padding: 6rem 1.5rem;
}

.error-404__code {
    font-size: 7rem;
    font-weight: 800;
    color: #22d3ee !important;
    line-height: 1;
    margin-bottom: 0.5rem;
    opacity: 0.8;
}

.error-404__title {
    font-size: 1.75rem;
    color: #ffffff !important;
    margin-bottom: 1rem;
}

.error-404__message {
    color: #64748b;
    font-size: 1rem;
    max-width: 400px;
    margin: 0 auto 2rem;
}

.error-404__actions {
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.65rem 1.4rem;
    border-radius: 6px;
    font-size: 0.9rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s ease;
    cursor: pointer;
    border: none;
}

.btn--primary {
    background-color: #22d3ee !important;
    color: #020617;
}

.btn--primary:hover {
    background-color: #67e8f9;
    color: #020617;
    text-decoration: none;
}

.btn--outline {
    background-color: transparent;
    border: 1px solid #334155;
    color: #94a3b8 !important;
}

.btn--outline:hover {
    border-color: #22d3ee !important;
    color: #22d3ee !important;
    background-color: rgba(34, 211, 238, 0.08);
    text-decoration: none;
}

/* ============================================================
   PAGE TEMPLATE
   ============================================================ */

.page-hero {
    margin-bottom: 2.5rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid #1e293b;
}

.page-hero__title {
    font-size: 2.25rem;
    font-weight: 800;
    color: #ffffff !important;
    line-height: 1.2;
    letter-spacing: -0.02em;
}

/* ============================================================
   WORDPRESS ALIGNMENT HELPERS
   ============================================================ */

.alignleft {
    float: left;
    margin: 0 1.5rem 1rem 0;
}

.alignright {
    float: right;
    margin: 0 0 1rem 1.5rem;
}

.aligncenter {
    display: block;
    margin: 1.5rem auto;
}

.wp-caption {
    max-width: 100%;
}

.wp-caption-text {
    color: #64748b;
    font-size: 0.8rem;
    text-align: center;
    margin-top: 0.4rem;
}

/* ============================================================
   RESPONSIVE
   ============================================================ */

@media (max-width: 768px) {
    .site-header .container {
        height: 56px;
    }

    .site-logo {
        font-size: 1rem;
    }

    .site-nav ul li a {
        padding: 0.35rem 0.6rem;
        font-size: 0.82rem;
    }

    .blog-header h1 {
        font-size: 1.5rem;
    }

    .blog-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .post-hero__title,
    .page-hero__title {
        font-size: 1.6rem;
    }

    .post-content h2 {
        font-size: 1.3rem;
    }

    .post-content h3 {
        font-size: 1.15rem;
    }

    .error-404__code {
        font-size: 5rem;
    }

    .error-404__title {
        font-size: 1.4rem;
    }

    .post-footer {
        flex-direction: column;
        align-items: flex-start;
    }
}

@media (max-width: 480px) {
    .site-main {
        padding: 2rem 0;
    }

    .container,
    .container--narrow {
        padding: 0 1rem;
    }

    .post-card {
        padding: 1.25rem;
    }

    .post-hero__meta {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }

    .pagination .page-numbers {
        min-width: 36px;
        height: 36px;
        font-size: 0.8rem;
    }

    .error-404__actions {
        flex-direction: column;
        align-items: center;
    }
}
