/*
Theme Name: Duomen Blog
Theme URI: https://duomen.ro
Description: Tema WordPress custom pentru Duomen — blog integrat cu landing page. SEO complet.
Version: 1.0.0
Author: Zdrovit Romania
Author URI: https://zdrovital.ro
Text Domain: duomen
Requires at least: 6.0
Requires PHP: 7.4
License: Proprietary
*/

:root {
  --dm-primary:     #3c467b;
  --dm-secondary:   #8acdb9;
  --dm-dark:        #0c2133;
  --dm-mint:        #94d1bb;
  --dm-navy:        #35386c;
  --dm-red:         #e33b1a;
  --dm-blue-20:     #4597c9;
  --dm-blue-80:     #073f70;
  --dm-blue-90:     #141552;
  --dm-white:       #ffffff;
  --dm-bg-light:    #f4f7f6;
  --dm-text:        #212529;
  --dm-text-muted:  #5a6a7e;
  --dm-font-body:   "Raleway", sans-serif;
  --dm-font-heading:"Open Sans", sans-serif;
  --dm-max-width:   1280px;
  --dm-radius:      6px;
}

.blog-page { font-family: var(--dm-font-body); font-weight: 500; color: var(--dm-text); line-height: 1.6; }
.blog-page *, .blog-page *::before, .blog-page *::after { box-sizing: border-box; }
.blog-page img { max-width: 100%; height: auto; }
.blog-page a { color: var(--dm-primary); text-decoration: none; transition: color 0.3s; }
.blog-page a:hover { color: var(--dm-red); }

/* ---------- Blog Navbar ---------- */
.blog-navbar { background: var(--dm-white); box-shadow: 0 2px 8px rgba(0,0,0,0.08); position: sticky; top: 0; z-index: 1000; }
.blog-navbar .navbar-inner { max-width: var(--dm-max-width); margin: 0 auto; padding: 0 20px; display: flex; align-items: center; justify-content: space-between; height: 64px; }
.blog-navbar .navbar-logo img, .blog-navbar .navbar-logo .custom-logo { height: 44px; width: auto; }
.blog-navbar .navbar-links { list-style: none; margin: 0; padding: 0; display: flex; gap: 4px; }
.blog-navbar .navbar-links a {
  display: block; padding: 8px 14px; font-family: var(--dm-font-heading); font-weight: 600; font-size: 0.88em;
  color: var(--dm-dark); text-transform: uppercase; text-decoration: none; border-radius: var(--dm-radius); transition: background 0.3s, color 0.3s;
}
.blog-navbar .navbar-links a:hover { background: var(--dm-secondary); color: var(--dm-dark); }
.blog-navbar .navbar-links a.active { background: var(--dm-primary); color: var(--dm-white); }

.blog-navbar .nav-toggle { display: none; background: none; border: 2px solid rgba(12,33,51,0.3); border-radius: 4px; cursor: pointer; padding: 8px; }
.blog-navbar .nav-toggle span { display: block; width: 24px; height: 2px; background: var(--dm-dark); margin: 5px 0; transition: 0.3s; }

@media (max-width: 768px) {
  .blog-navbar .nav-toggle { display: block; }
  .blog-navbar .navbar-links { display: none; flex-direction: column; position: absolute; top: 64px; left: 0; right: 0; background: var(--dm-white); box-shadow: 0 4px 12px rgba(0,0,0,0.1); padding: 12px 0; }
  .blog-navbar .navbar-links.open { display: flex; }
  .blog-navbar .navbar-links a { padding: 12px 20px; border-radius: 0; }
}

.blog-container { max-width: var(--dm-max-width); margin: 0 auto; padding: 0 20px; }

/* ---------- Blog Hero ---------- */
.blog-hero { background: linear-gradient(135deg, var(--dm-primary) 0%, var(--dm-navy) 100%); padding: 48px 0 40px; margin-bottom: 40px; }
.blog-hero h1 { font-family: var(--dm-font-heading); font-weight: 700; font-size: 2.2em; color: var(--dm-white); margin: 0; line-height: 1.2; }
.blog-hero .blog-description { font-size: 1.05em; color: rgba(255,255,255,0.7); margin-top: 8px; }

.breadcrumbs { padding: 16px 0 8px; font-size: 0.88em; color: #888; }
.breadcrumbs a { color: var(--dm-primary); }
.breadcrumbs .sep { margin: 0 6px; color: #bbb; }

/* ---------- Blog Grid ---------- */
.blog-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; margin-bottom: 48px; }
@media (max-width: 991px) { .blog-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .blog-grid { grid-template-columns: 1fr; } }

.blog-card { background: var(--dm-white); border-radius: var(--dm-radius); overflow: hidden; box-shadow: 0 2px 12px rgba(0,0,0,0.06); transition: transform 0.25s, box-shadow 0.25s; display: flex; flex-direction: column; }
.blog-card:hover { transform: translateY(-4px); box-shadow: 0 8px 24px rgba(0,0,0,0.1); }
.blog-card .card-thumb { width: 100%; aspect-ratio: 16/10; object-fit: cover; display: block; }
.blog-card .card-body { padding: 20px; flex: 1; display: flex; flex-direction: column; }
.blog-card .card-category { display: inline-block; font-weight: 600; font-size: 0.75em; text-transform: uppercase; color: var(--dm-red); margin-bottom: 8px; }
.blog-card .card-title { font-family: var(--dm-font-heading); font-weight: 600; font-size: 1.15em; line-height: 1.35; margin: 0 0 10px; }
.blog-card .card-title a { color: var(--dm-text); }
.blog-card .card-title a:hover { color: var(--dm-primary); }
.blog-card .card-excerpt { font-size: 0.92em; color: var(--dm-text-muted); line-height: 1.55; margin-bottom: 16px; flex: 1; }
.blog-card .card-meta { font-size: 0.8em; color: #999; display: flex; gap: 16px; margin-top: auto; padding-top: 12px; border-top: 1px solid #f0f0f0; }

/* ---------- Pagination ---------- */
.blog-pagination { display: flex; justify-content: center; align-items: center; gap: 6px; padding: 24px 0 56px; }
.blog-pagination a, .blog-pagination span { display: inline-flex; align-items: center; justify-content: center; min-width: 40px; height: 40px; padding: 0 12px; border-radius: var(--dm-radius); font-weight: 500; font-size: 0.95em; text-decoration: none; transition: background 0.2s, color 0.2s; }
.blog-pagination a { background: var(--dm-bg-light); color: var(--dm-text); }
.blog-pagination a:hover { background: var(--dm-primary); color: var(--dm-white); }
.blog-pagination span.current { background: var(--dm-primary); color: var(--dm-white); }

/* ---------- Single Article ---------- */
.article-header { padding: 48px 0 32px; }
.article-header h1 { font-family: var(--dm-font-heading); font-weight: 700; font-size: 2.2em; line-height: 1.25; color: var(--dm-text); margin: 0 0 16px; }
.article-meta { display: flex; flex-wrap: wrap; gap: 20px; font-size: 0.88em; color: #888; margin-bottom: 24px; }
.article-meta .meta-item { display: flex; align-items: center; gap: 5px; }
.article-featured-img { width: 100%; border-radius: var(--dm-radius); margin-bottom: 32px; aspect-ratio: 21/9; object-fit: cover; }

.toc-wrapper { background: #eef6f2; border-left: 4px solid var(--dm-secondary); border-radius: 0 6px 6px 0; padding: 24px 28px; margin-bottom: 36px; }
.toc-wrapper .toc-title { font-family: var(--dm-font-heading); font-weight: 600; font-size: 1.1em; margin: 0 0 12px; color: var(--dm-text); }
.toc-wrapper ol { margin: 0; padding-left: 20px; }
.toc-wrapper li { margin-bottom: 6px; line-height: 1.5; }
.toc-wrapper li a { color: var(--dm-text); border-bottom: 1px dashed #ccc; }
.toc-wrapper li a:hover { color: var(--dm-primary); border-color: var(--dm-primary); }
.toc-wrapper ol ol { margin-top: 6px; }

.article-content { max-width: 820px; font-size: 1.05em; line-height: 1.75; }
.article-content h2 { font-family: var(--dm-font-heading); font-weight: 700; font-size: 1.6em; color: var(--dm-primary); margin: 48px 0 16px; padding-top: 16px; }
.article-content h3 { font-family: var(--dm-font-heading); font-weight: 600; font-size: 1.25em; color: var(--dm-text); margin: 36px 0 12px; }
.article-content p { margin: 0 0 20px; }
.article-content ul, .article-content ol { margin: 0 0 24px; padding-left: 24px; }
.article-content li { margin-bottom: 8px; }
.article-content img { border-radius: var(--dm-radius); margin: 16px 0; }
.article-content blockquote { border-left: 4px solid var(--dm-secondary); margin: 28px 0; padding: 16px 24px; background: #eef6f2; border-radius: 0 6px 6px 0; font-style: italic; color: #555; }
.article-content a { color: var(--dm-primary); text-decoration: underline; text-underline-offset: 2px; }
.article-content a:hover { color: var(--dm-red); }

.related-section { background: var(--dm-bg-light); padding: 48px 0; margin-top: 56px; }
.related-section .section-title { font-family: var(--dm-font-heading); font-weight: 700; font-size: 1.5em; margin: 0 0 28px; }
.related-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
@media (max-width: 991px) { .related-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .related-grid { grid-template-columns: 1fr; } }

.blog-footer .footer-address { background: var(--dm-primary); color: var(--dm-white); padding: 32px 0; text-align: center; line-height: 1.5; }
.blog-footer .footer-address p { margin-bottom: 0; }
.blog-footer .footer-copyright { background: var(--dm-dark); color: rgba(255,255,255,0.7); padding: 16px 0; font-size: 0.85em; }
.blog-footer .footer-copyright-inner { max-width: var(--dm-max-width); margin: 0 auto; padding: 0 20px; display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 8px 24px; }
.blog-footer .footer-copyright a { color: rgba(255,255,255,0.7); text-decoration: none; }
.blog-footer .footer-copyright a:hover { color: var(--dm-secondary); }

.page-404 { text-align: center; padding: 80px 20px; }
.page-404 h1 { font-family: var(--dm-font-heading); font-weight: 700; font-size: 5em; color: var(--dm-primary); margin: 0; }
.page-404 p { font-size: 1.2em; color: var(--dm-text-muted); margin: 16px 0 32px; }
.page-404 .btn-home { display: inline-block; padding: 12px 32px; background: var(--dm-primary); color: var(--dm-white); font-weight: 600; border-radius: 2em; text-decoration: none; }
.page-404 .btn-home:hover { background: var(--dm-navy); }
.no-posts { text-align: center; padding: 60px 20px; color: var(--dm-text-muted); }
