/* =====================================================================
   ORDO - Blog CSS (self-contained, brand arancione)
   File: /css/blog.css  — usato da /blog/index.php e /blog/post.php
   ===================================================================== */
:root {
    --orange: #FF6B00;
    --orange-dark: #E55A00;
    --orange-light: #FFF7ED;
    --ink: #1A1A2E;
    --ink-soft: #4B5563;
    --muted: #6B7280;
    --line: #E5E7EB;
    --bg: #FFFFFF;
    --bg-soft: #FAFAFA;
    --radius: 14px;
    --radius-lg: 20px;
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.06);
    --shadow-md: 0 4px 16px rgba(0,0,0,0.08);
    --shadow-lg: 0 12px 40px rgba(0,0,0,0.12);
}
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    color: var(--ink);
    line-height: 1.6;
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
.container { max-width: 1180px; margin: 0 auto; padding: 0 24px; }

/* ===== HEADER ===== */
.header {
    background: rgba(255,255,255,0.92);
    backdrop-filter: saturate(180%) blur(10px);
    border-bottom: 1px solid var(--line);
    position: sticky; top: 0; z-index: 100;
}
.header-content { display: flex; align-items: center; justify-content: space-between; padding: 14px 0; gap: 20px; }
.logo img { height: 38px; width: auto; }
.logo-text { font-weight: 900; font-size: 22px; letter-spacing: -0.5px; }
.logo-text span { color: var(--orange); }
.nav-menu { display: flex; gap: 22px; align-items: center; font-size: 15px; font-weight: 500; }
.nav-menu a { color: var(--ink-soft); transition: color .2s; }
.nav-menu a:hover { color: var(--orange); }
.nav-menu .btn-login {
    background: var(--orange); color: #fff; padding: 8px 18px; border-radius: 10px; font-weight: 600;
}
.nav-menu .btn-login:hover { background: var(--orange-dark); color: #fff; }
.lang-switch { display: flex; gap: 4px; margin-left: 4px; }
.lang-switch a { font-size: 12px; font-weight: 700; text-transform: uppercase; padding: 4px 8px; border-radius: 6px; color: var(--muted); }
.lang-switch a.active { background: var(--orange-light); color: var(--orange); }

/* ===== INDEX HERO ===== */
.blog-hero { padding: 60px 0 20px; text-align: center; }
.blog-hero h1 { font-size: 2.4rem; font-weight: 900; letter-spacing: -1px; margin-bottom: 14px; }
.blog-hero p { color: var(--muted); font-size: 1.1rem; max-width: 640px; margin: 0 auto; }

/* ===== CARD GRID ===== */
.section { padding: 40px 0 80px; }
.features-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 28px; }
.feature-card {
    background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius-lg);
    overflow: hidden; display: flex; flex-direction: column; transition: transform .25s, box-shadow .25s;
}
.feature-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.feature-card .thumb { height: 190px; overflow: hidden; background: var(--bg-soft); }
.feature-card .thumb img { width: 100%; height: 100%; object-fit: cover; }
.card-body { padding: 22px; display: flex; flex-direction: column; flex-grow: 1; }
.badge-categoria {
    align-self: flex-start; background: var(--orange-light); color: var(--orange);
    padding: 4px 10px; border-radius: 6px; font-size: 0.72rem; font-weight: 700;
    text-transform: uppercase; letter-spacing: .04em; margin-bottom: 12px;
}
.post-meta { font-size: 0.82rem; color: var(--muted); margin-bottom: 10px; }
.card-body h3 { font-size: 1.2rem; line-height: 1.35; margin-bottom: 12px; }
.card-body p { font-size: 0.95rem; color: var(--ink-soft); margin-bottom: 20px; }

.btn-google-style {
    color: var(--orange); font-weight: 600; font-size: 0.95rem;
    display: inline-flex; align-items: center; gap: 6px; margin-top: auto; transition: gap .2s;
}
.btn-google-style:hover { gap: 11px; }
a.btn-google-style { color: var(--orange); }

.empty-state { text-align: center; color: var(--muted); padding: 80px 0; font-size: 1.1rem; }

/* ===== POST SINGOLO ===== */
.blog-container { max-width: 820px; margin: 0 auto; padding: 0 24px; }
.post-single { }
.post-header { text-align: center; margin-bottom: 40px; border-bottom: 1px solid var(--line); padding-bottom: 34px; }
.post-header .badge {
    display: inline-block; background: var(--orange-light); color: var(--orange);
    padding: 5px 12px; border-radius: 8px; font-size: 0.75rem; font-weight: 700; text-transform: uppercase; margin-bottom: 16px;
}
.post-single h1 { font-size: 2.3rem; font-weight: 900; line-height: 1.2; letter-spacing: -0.8px; margin-bottom: 16px; }
.post-header .post-meta { justify-content: center; }
.post-featured-image { display: flex; justify-content: center; margin-bottom: 46px; }
.post-featured-image img { max-height: 380px; width: 100%; object-fit: cover; border-radius: var(--radius-lg); box-shadow: var(--shadow-lg); }

.post-body { color: #2b3444; font-size: 1.12rem; }
.post-body h2, .post-body h3, .post-body h4 { color: var(--ink); margin-top: 52px; margin-bottom: 20px; line-height: 1.3; }
.post-body h2 { font-size: 1.7rem; font-weight: 800; }
.post-body h3 { font-size: 1.35rem; font-weight: 700; }
.post-body p { margin-bottom: 26px; line-height: 1.8; }
.post-body ul, .post-body ol { margin-bottom: 30px; padding-left: 24px; }
.post-body li { margin-bottom: 12px; line-height: 1.65; }
.post-body strong { color: var(--ink); font-weight: 700; }
.post-featured-image + .post-body p:first-of-type { margin-top: 6px; }

/* Note box (E-E-A-T) */
.post-body .note-box {
    background: var(--bg-soft); border-left: 4px solid var(--orange); padding: 18px 22px;
    border-radius: 10px; margin: 36px 0; font-size: 0.98rem; color: var(--ink-soft);
}
.post-body .note-box p { margin: 0; }

/* CTA box */
.post-body .cta-box {
    background: linear-gradient(135deg, #FFF7ED, #FFEEDD); border: 1px solid #FED7AA;
    padding: 32px; border-radius: var(--radius-lg); margin: 46px 0; box-shadow: var(--shadow-sm);
}
.post-body .cta-box h3, .post-body .cta-box h4 { color: var(--orange-dark) !important; margin-top: 0 !important; font-size: 1.35rem; }
.post-body .cta-box .btn-google-style {
    background: var(--orange); color: #fff; padding: 12px 22px; border-radius: 12px; margin-top: 12px;
}
.post-body .cta-box .btn-google-style:hover { background: var(--orange-dark); gap: 11px; }

/* ===== SHARE BAR ===== */
.share-bar { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; margin-top: 45px; padding-top: 28px; border-top: 1px solid var(--line); }
.share-bar__label { font-weight: 700; color: var(--ink); margin-right: 4px; }
.share-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 16px; border: none; border-radius: 10px; color: #fff; font-size: 15px; font-weight: 600; cursor: pointer; transition: opacity .2s, transform .2s; }
.share-btn:hover { opacity: .9; transform: translateY(-2px); }
.share-btn--wa { background: #25d366; }
.share-btn--fb { background: #1877f2; }
.share-btn--li { background: #0a66c2; }
.share-btn--x { background: #000; }
.share-btn--copy { background: #475569; }
@media (max-width: 600px) { .share-btn { flex: 1 1 calc(50% - 10px); } .share-bar__label { flex-basis: 100%; margin-bottom: 4px; } }

/* ===== RELATED ===== */
.related-posts { margin-top: 50px; padding-top: 30px; border-top: 1px solid var(--line); }
.related-posts h3 { margin-bottom: 22px; font-size: 1.3rem; }
.related-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 20px; }
.related-card { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; height: 100%; transition: transform .25s, box-shadow .25s; }
.related-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.related-card img { width: 100%; height: 140px; object-fit: cover; }
.related-card .rc-body { padding: 14px; }
.related-card .rc-cat { font-size: 11px; text-transform: uppercase; color: var(--orange); font-weight: 700; }
.related-card h4 { margin-top: 6px; font-size: 15px; line-height: 1.4; }

/* ===== FOOTER CTA ===== */
.blog-cta-footer { background: var(--ink); color: #fff; text-align: center; padding: 56px 24px; margin-top: 40px; }
.blog-cta-footer h2 { font-size: 1.7rem; font-weight: 800; margin-bottom: 10px; }
.blog-cta-footer p { color: #cbd5e1; margin-bottom: 22px; }
.blog-cta-footer a { display: inline-block; background: var(--orange); color: #fff; padding: 14px 30px; border-radius: 12px; font-weight: 700; }
.blog-cta-footer a:hover { background: var(--orange-dark); }
.footer { background: var(--bg-soft); border-top: 1px solid var(--line); text-align: center; padding: 26px; color: var(--muted); font-size: 0.9rem; }

.back-link { margin-top: 50px; padding-top: 26px; border-top: 1px solid var(--line); }

@media (max-width: 640px) {
    .blog-hero h1 { font-size: 1.9rem; }
    .post-single h1 { font-size: 1.75rem; }
    .nav-menu { gap: 14px; font-size: 14px; }
    .nav-menu .nav-hide { display: none; }
}
