/**
 * DailySkillGuide.com - Core Design System & Stylesheet
 * Brand: Daily Skill Guide ("Learn Skills. Build Your Future.")
 */

:root {
    --primary: #2563eb;
    --primary-hover: #1d4ed8;
    --primary-light: #eff6ff;
    --dark: #0f172a;
    --dark-muted: #334155;
    --gray-bg: #f8fafc;
    --gray-border: #e2e8f0;
    --text-main: #1e293b;
    --text-muted: #64748b;
    --accent: #10b981;
    --warning: #f59e0b;
    --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 16px;
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.06), 0 1px 2px rgba(0,0,0,0.04);
    --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.07), 0 2px 4px -2px rgba(0,0,0,0.05);
    --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.08), 0 4px 6px -4px rgba(0,0,0,0.04);
}

body {
    font-family: var(--font-sans);
    color: var(--text-main);
    background-color: #ffffff;
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    color: var(--dark);
    font-weight: 700;
    line-height: 1.3;
}

a {
    color: var(--primary);
    text-decoration: none;
    transition: color 0.2s ease;
}
a:hover {
    color: var(--primary-hover);
}

/* Header & Navbar */
.site-header {
    background: #ffffff;
    border-bottom: 1px solid var(--gray-border);
    position: sticky;
    top: 0;
    z-index: 1020;
    box-shadow: 0 1px 2px rgba(0,0,0,0.03);
}

.brand-logo {
    font-size: 1.45rem;
    font-weight: 800;
    color: var(--dark);
    letter-spacing: -0.5px;
    display: inline-flex;
    align-items: center;
}
.brand-logo span {
    color: var(--primary);
}

.nav-link {
    font-weight: 500;
    color: var(--dark-muted) !important;
    padding: 0.5rem 0.9rem !important;
    font-size: 0.95rem;
    transition: color 0.15s ease;
}
.nav-link:hover, .nav-link.active {
    color: var(--primary) !important;
}

/* Hero Section */
.hero-section {
    background: linear-gradient(180deg, #f8fafc 0%, #ffffff 100%);
    border-bottom: 1px solid var(--gray-border);
    padding: 4.5rem 0 3.5rem 0;
}
.hero-badge {
    display: inline-flex;
    align-items: center;
    background: var(--primary-light);
    color: var(--primary);
    padding: 0.35rem 0.85rem;
    border-radius: 999px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 1.25rem;
    border: 1px solid #dbeafe;
}
.hero-title {
    font-size: 2.85rem;
    font-weight: 800;
    letter-spacing: -1px;
    line-height: 1.2;
    margin-bottom: 1.25rem;
}
.hero-subtitle {
    font-size: 1.15rem;
    color: var(--text-muted);
    max-width: 650px;
    margin-bottom: 2rem;
}

/* Cards & Articles */
.article-card {
    background: #ffffff;
    border: 1px solid var(--gray-border);
    border-radius: var(--radius-md);
    overflow: hidden;
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
    display: flex;
    flex-direction: column;
    height: 100%;
}
.article-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: #cbd5e1;
}
.article-card .card-thumb-wrap {
    position: relative;
    padding-top: 56.25%; /* 16:9 Aspect Ratio */
    overflow: hidden;
    background: #f1f5f9;
}
.article-card .card-thumb {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}
.article-card:hover .card-thumb {
    transform: scale(1.03);
}
.article-card .card-body {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}
.category-badge {
    display: inline-block;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--primary);
    background: var(--primary-light);
    padding: 0.25rem 0.6rem;
    border-radius: var(--radius-sm);
    margin-bottom: 0.75rem;
}
.article-card .card-title {
    font-size: 1.18rem;
    font-weight: 700;
    line-height: 1.4;
    margin-bottom: 0.75rem;
    color: var(--dark);
}
.article-card .card-title a {
    color: inherit;
}
.article-card .card-title a:hover {
    color: var(--primary);
}
.article-card .card-excerpt {
    font-size: 0.92rem;
    color: var(--text-muted);
    margin-bottom: 1.25rem;
    flex-grow: 1;
}
.article-meta {
    font-size: 0.82rem;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding-top: 1rem;
    border-top: 1px solid var(--gray-border);
}

/* Category Grid */
.category-card {
    background: #ffffff;
    border: 1px solid var(--gray-border);
    border-radius: var(--radius-md);
    padding: 1.5rem;
    transition: all 0.2s ease;
    display: block;
    color: var(--dark);
    height: 100%;
}
.category-card:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
    color: var(--primary);
}
.category-icon {
    width: 48px;
    height: 48px;
    background: var(--primary-light);
    color: var(--primary);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    margin-bottom: 1rem;
}

/* Affiliate Product Cards */
.affiliate-card {
    background: #ffffff;
    border: 1px solid var(--gray-border);
    border-radius: var(--radius-md);
    padding: 1.5rem;
    box-shadow: var(--shadow-sm);
    transition: box-shadow 0.2s ease;
}
.affiliate-card:hover {
    box-shadow: var(--shadow-md);
}
.affiliate-badge {
    background: #fef3c7;
    color: #92400e;
    font-weight: 700;
    font-size: 0.75rem;
    padding: 0.25rem 0.6rem;
    border-radius: var(--radius-sm);
    text-transform: uppercase;
}
.affiliate-rating {
    color: #f59e0b;
    font-size: 0.9rem;
    font-weight: 600;
}

/* Single Article Styles */
.article-header {
    margin-bottom: 2rem;
}
.article-header h1 {
    font-size: 2.5rem;
    font-weight: 800;
    line-height: 1.25;
    margin-bottom: 1rem;
}
.article-main-thumb {
    width: 100%;
    border-radius: var(--radius-md);
    margin-bottom: 2rem;
    box-shadow: var(--shadow-sm);
    max-height: 480px;
    object-fit: cover;
}

/* Table of Contents */
.toc-box {
    background: #f8fafc;
    border: 1px solid var(--gray-border);
    border-radius: var(--radius-md);
    padding: 1.5rem;
    margin: 2rem 0;
}
.toc-box .toc-title {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.toc-list {
    list-style: none;
    padding-left: 0;
    margin-bottom: 0;
}
.toc-list li {
    margin-bottom: 0.5rem;
    font-size: 0.95rem;
}
.toc-list li.toc-level-3 {
    padding-left: 1.25rem;
}
.toc-list a {
    color: var(--dark-muted);
}
.toc-list a:hover {
    color: var(--primary);
    text-decoration: underline;
}

/* Article Prose */
.article-content {
    font-size: 1.12rem;
    line-height: 1.8;
    color: #334155;
}
.article-content h2 {
    font-size: 1.85rem;
    font-weight: 800;
    margin-top: 2.75rem;
    margin-bottom: 1rem;
    padding-top: 0.5rem;
    border-bottom: 1px solid var(--gray-border);
    padding-bottom: 0.5rem;
}
.article-content h3 {
    font-size: 1.45rem;
    font-weight: 700;
    margin-top: 2rem;
    margin-bottom: 0.85rem;
}
.article-content p {
    margin-bottom: 1.5rem;
}
.article-content ul, .article-content ol {
    margin-bottom: 1.75rem;
    padding-left: 1.75rem;
}
.article-content li {
    margin-bottom: 0.5rem;
}
.article-content blockquote {
    border-left: 4px solid var(--primary);
    background: #f8fafc;
    padding: 1rem 1.5rem;
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
    font-style: italic;
    margin: 2rem 0;
    color: #475569;
}
.article-content pre {
    background: #0f172a;
    color: #f8fafc;
    padding: 1.25rem;
    border-radius: var(--radius-md);
    overflow-x: auto;
    margin: 1.75rem 0;
    font-size: 0.95rem;
}
.article-content code {
    font-family: SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    font-size: 0.9em;
}
.article-content p code, .article-content li code {
    background: #f1f5f9;
    color: #d946ef;
    padding: 0.2rem 0.4rem;
    border-radius: 4px;
    font-weight: 600;
}

/* Author Box */
.author-card {
    background: #f8fafc;
    border: 1px solid var(--gray-border);
    border-radius: var(--radius-md);
    padding: 2rem;
    margin: 3rem 0;
}

/* Ad Placement Containers */
.dsg-ad-slot {
    margin: 2rem auto;
    text-align: center;
    position: relative;
    overflow: hidden;
}
.dsg-ad-placeholder {
    background: #f8fafc;
    border: 1px dashed #cbd5e1;
    border-radius: var(--radius-sm);
    padding: 1.5rem;
    color: #94a3b8;
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Newsletter Box */
.newsletter-card {
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
    color: #ffffff;
    border-radius: var(--radius-lg);
    padding: 3.5rem 2.5rem;
    margin: 4rem 0 2rem 0;
}
.newsletter-card h3 {
    color: #ffffff;
    font-weight: 800;
}
.newsletter-card p {
    color: #94a3b8;
}

/* Footer */
.site-footer {
    background: #0f172a;
    color: #94a3b8;
    padding: 4.5rem 0 2rem 0;
    font-size: 0.92rem;
    margin-top: 5rem;
}
.site-footer h6 {
    color: #ffffff;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-size: 0.85rem;
    margin-bottom: 1.25rem;
}
.site-footer a {
    color: #94a3b8;
}
.site-footer a:hover {
    color: #ffffff;
}
.site-footer ul {
    list-style: none;
    padding-left: 0;
}
.site-footer ul li {
    margin-bottom: 0.65rem;
}
.footer-bottom {
    border-top: 1px solid #1e293b;
    padding-top: 2rem;
    margin-top: 3.5rem;
}

/* Back to Top */
#back-to-top {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 1000;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--primary);
    color: #fff;
    border: none;
    display: none;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-md);
    cursor: pointer;
    transition: all 0.2s ease;
}
#back-to-top:hover {
    background: var(--primary-hover);
    transform: translateY(-2px);
}

@media (max-width: 768px) {
    .hero-title { font-size: 2.1rem; }
    .article-header h1 { font-size: 1.85rem; }
    .newsletter-card { padding: 2rem 1.5rem; }
}
