/*
Theme Name: RestivaLab
Theme URI: https://restivalab.com
Description: Custom Kadence child theme for RestivaLab — better sleep and pain relief. Calm teal-to-blue branding with a clean wellness editorial tone.
Author: RestivaLab
Author URI: https://restivalab.com
Template: kadence
Version: 1.2.1
License: GPL v2 or later
Text Domain: restiva-child
*/

/* =====================================================
   CSS CUSTOM PROPERTIES — RestivaLab Brand
   ===================================================== */
:root {
    --pnhq-teal: #28B8C2;
    --pnhq-teal-hover: #159EAF;
    --pnhq-teal-light: #E8FAFC;
    --pnhq-teal-lighter: #F4FDFF;
    --pnhq-coral: #0D4CC9;
    --pnhq-coral-hover: #083DAB;
    --pnhq-coral-light: #EAF0FF;
    --pnhq-dark: #253446;
    --pnhq-dark-soft: #3F5065;
    --pnhq-cream: #F6F8FC;
    --pnhq-cream-dark: #E8EEF7;
    --pnhq-white: #FFFFFF;
    --pnhq-gold: #7FDCE2;
    --pnhq-gold-dark: #5EC3CC;
    --pnhq-purple: #4C78FF;
    --pnhq-green: #34B7A0;
    --pnhq-green-light: #E7F8F4;
    --pnhq-cat-dogs: #28B8C2;
    --pnhq-cat-cats: #0D4CC9;
    --pnhq-cat-fish: #3D86FF;
    --pnhq-cat-birds: #6ACAD2;
    --pnhq-cat-reptiles: #2F6BDE;
    --pnhq-cat-small: #2FA7B5;
    --pnhq-font-heading: 'DM Sans', -apple-system, BlinkMacSystemFont, sans-serif;
    --pnhq-font-body: 'DM Sans', -apple-system, BlinkMacSystemFont, sans-serif;
    --pnhq-radius: 12px;
    --pnhq-radius-sm: 8px;
    --pnhq-radius-lg: 16px;
    --pnhq-radius-xl: 20px;
}

/* =====================================================
   GLOBAL TYPOGRAPHY
   ===================================================== */
body {
    font-family: var(--pnhq-font-body);
    color: var(--pnhq-dark);
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--pnhq-font-heading);
    color: var(--pnhq-dark);
    font-weight: 700;
}

a {
    color: var(--pnhq-teal);
    transition: color 0.2s ease;
}
a:hover {
    color: var(--pnhq-coral);
}

/* =====================================================
   HEADER OVERRIDES
   ===================================================== */
.site-header {
    background: var(--pnhq-dark) !important;
    border-bottom: 3px solid var(--pnhq-teal);
}

.site-header .site-title,
.site-header .site-title a {
    color: var(--pnhq-white) !important;
    font-weight: 700;
    font-size: 24px;
    text-decoration: none;
}

/* Make "Nerd" in the title coral via JS — fallback pure CSS approach */
.header-navigation .menu > li > a {
    color: rgba(255,255,255,0.85) !important;
    font-weight: 500;
    font-size: 15px;
    letter-spacing: 0.3px;
    transition: color 0.2s;
}
.header-navigation .menu > li > a:hover,
.header-navigation .menu > li.current-menu-item > a {
    color: var(--pnhq-coral) !important;
}

/* Mobile menu */
.mobile-toggle-open-container .menu-toggle-icon {
    color: var(--pnhq-white);
}

/* =====================================================
   HERO / HOMEPAGE
   ===================================================== */
.pnhq-hero {
    background: linear-gradient(135deg, var(--pnhq-dark) 0%, var(--pnhq-teal-hover) 100%);
    padding: 80px 0 60px;
    text-align: center;
    position: relative;
    overflow: hidden;
}
.pnhq-hero::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 500px;
    height: 500px;
    background: var(--pnhq-coral);
    opacity: 0.06;
    border-radius: 50%;
}
.pnhq-hero h1 {
    color: var(--pnhq-white);
    font-size: clamp(32px, 5vw, 52px);
    line-height: 1.2;
    margin-bottom: 16px;
}
.pnhq-hero h1 .pnhq-highlight {
    color: var(--pnhq-coral);
}
.pnhq-hero p {
    color: rgba(255,255,255,0.75);
    font-size: 18px;
    max-width: 600px;
    margin: 0 auto 32px;
}
.pnhq-hero-search {
    max-width: 500px;
    margin: 0 auto;
    position: relative;
}
.pnhq-hero-search input {
    width: 100%;
    padding: 16px 60px 16px 24px;
    border: 2px solid rgba(255,255,255,0.2);
    border-radius: 50px;
    background: rgba(255,255,255,0.1);
    color: white;
    font-size: 16px;
    backdrop-filter: blur(10px);
}
.pnhq-hero-search input::placeholder { color: rgba(255,255,255,0.5); }
.pnhq-hero-search button {
    position: absolute;
    right: 6px;
    top: 6px;
    bottom: 6px;
    padding: 0 20px;
    background: var(--pnhq-coral);
    color: white;
    border: none;
    border-radius: 50px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}
.pnhq-hero-search button:hover { background: var(--pnhq-coral-hover); }

/* =====================================================
   CATEGORY PILLS / PET TYPE NAV
   ===================================================== */
.pnhq-pet-nav {
    display: flex;
    justify-content: center;
    gap: 12px;
    padding: 30px 20px;
    flex-wrap: wrap;
}
.pnhq-pet-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    border-radius: 50px;
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    transition: transform 0.2s, box-shadow 0.2s;
    color: white;
    letter-spacing: 0.3px;
}
.pnhq-pet-pill:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0,0,0,0.2);
    color: white;
}
.pnhq-pet-pill.dogs    { background: #1B7A6E; }
.pnhq-pet-pill.cats    { background: #6B3FA0; }
.pnhq-pet-pill.fish    { background: #1976D2; }
.pnhq-pet-pill.birds   { background: #D4850A; color: white; }
.pnhq-pet-pill.reptiles{ background: #C44B27; }
.pnhq-pet-pill.small   { background: #2E7D32; }

/* =====================================================
   ARTICLE CARDS (Archive / Homepage Grid)
   ===================================================== */
.pnhq-card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 24px;
    padding: 24px 0;
}

.pnhq-article-card {
    background: var(--pnhq-white);
    border-radius: var(--pnhq-radius-lg);
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
}
.pnhq-article-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.12);
    color: inherit;
}

.pnhq-card-image {
    aspect-ratio: 16/10;
    overflow: hidden;
    position: relative;
}
.pnhq-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}
.pnhq-article-card:hover .pnhq-card-image img {
    transform: scale(1.05);
}

.pnhq-card-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: white;
}

.pnhq-card-body {
    padding: 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
}
.pnhq-card-meta {
    font-size: 12px;
    color: #888;
    margin-bottom: 8px;
    display: flex;
    gap: 12px;
}
.pnhq-card-title {
    font-size: 18px;
    font-weight: 700;
    color: var(--pnhq-dark);
    margin: 0 0 8px;
    line-height: 1.35;
}
.pnhq-card-excerpt {
    font-size: 14px;
    color: #666;
    line-height: 1.6;
    flex: 1;
}
.pnhq-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 20px;
    border-top: 1px solid #f0f0f0;
    font-size: 13px;
}
.pnhq-card-readmore {
    color: var(--pnhq-coral);
    font-weight: 600;
    text-decoration: none;
}
.pnhq-card-readtime {
    color: #999;
}

/* =====================================================
   SINGLE ARTICLE STYLES
   ===================================================== */
.single-post .entry-content {
    font-size: 17px;
    line-height: 1.8;
    color: #333;
}
.single-post .entry-content h2 {
    font-size: 26px;
    margin-top: 48px;
    margin-bottom: 16px;
    padding-bottom: 8px;
    border-bottom: 3px solid var(--pnhq-teal-light);
    color: var(--pnhq-dark);
}
.single-post .entry-content h3 {
    font-size: 20px;
    margin-top: 32px;
    color: var(--pnhq-teal);
}
.single-post .entry-content p {
    margin-bottom: 20px;
}
.single-post .entry-content ul,
.single-post .entry-content ol {
    margin-bottom: 20px;
    padding-left: 24px;
}
.single-post .entry-content li {
    margin-bottom: 8px;
    line-height: 1.7;
}
.single-post .entry-content strong {
    color: var(--pnhq-dark);
}

/* Article header */
.pnhq-single-header {
    text-align: center;
    padding: 48px 0 32px;
}
.pnhq-single-header .entry-title {
    font-size: clamp(28px, 4vw, 40px);
    line-height: 1.25;
    max-width: 800px;
    margin: 0 auto 16px;
}
.pnhq-single-meta {
    display: flex;
    justify-content: center;
    gap: 20px;
    font-size: 14px;
    color: #888;
    flex-wrap: wrap;
}
.pnhq-single-meta span {
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

/* Breadcrumbs */
.pnhq-breadcrumbs {
    font-size: 13px;
    padding: 12px 0;
    color: #999;
}
.pnhq-breadcrumbs a {
    color: var(--pnhq-teal);
    text-decoration: none;
}
.pnhq-breadcrumbs a:hover { text-decoration: underline; }

/* =====================================================
   SIDEBAR WIDGETS
   ===================================================== */
.pnhq-sidebar-widget {
    background: var(--pnhq-white);
    border-radius: var(--pnhq-radius);
    padding: 24px;
    margin-bottom: 24px;
    border: 1px solid #eee;
}
.pnhq-sidebar-widget h3 {
    font-size: 16px;
    margin: 0 0 16px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--pnhq-teal-light);
}

/* Popular Posts Widget */
.pnhq-popular-post {
    display: flex;
    gap: 12px;
    padding: 10px 0;
    border-bottom: 1px solid #f0f0f0;
}
.pnhq-popular-post:last-child { border-bottom: none; }
.pnhq-popular-post img {
    width: 80px;
    height: 60px;
    object-fit: cover;
    border-radius: var(--pnhq-radius-sm);
    flex-shrink: 0;
}
.pnhq-popular-post-title {
    font-size: 14px;
    font-weight: 600;
    line-height: 1.3;
}
.pnhq-popular-post-title a { 
    color: var(--pnhq-dark); 
    text-decoration: none;
}
.pnhq-popular-post-title a:hover { color: var(--pnhq-coral); }

/* =====================================================
   FOOTER
   ===================================================== */
.site-footer {
    background: var(--pnhq-dark) !important;
    color: rgba(255,255,255,0.7);
}
.site-footer a {
    color: var(--pnhq-teal-light);
}
.site-footer a:hover {
    color: var(--pnhq-coral);
}
.pnhq-footer-tagline {
    text-align: center;
    padding: 20px 0 0;
    font-size: 13px;
    color: rgba(255,255,255,0.4);
    border-top: 1px solid rgba(255,255,255,0.08);
    margin-top: 20px;
}

/* =====================================================
   BUTTONS
   ===================================================== */
.pnhq-btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 28px;
    background: var(--pnhq-coral);
    color: white;
    border: none;
    border-radius: 50px;
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: background 0.2s, transform 0.2s;
}
.pnhq-btn-primary:hover {
    background: var(--pnhq-coral-hover);
    transform: translateY(-1px);
    color: white;
}
.pnhq-btn-secondary {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 24px;
    background: transparent;
    color: var(--pnhq-teal);
    border: 2px solid var(--pnhq-teal);
    border-radius: 50px;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s;
}
.pnhq-btn-secondary:hover {
    background: var(--pnhq-teal);
    color: white;
}

/* =====================================================
   AFFILIATE DISCLOSURE BAR
   ===================================================== */
.pnhq-affiliate-disclosure {
    background: var(--pnhq-cream);
    border: 1px solid var(--pnhq-cream-dark);
    border-radius: var(--pnhq-radius-sm);
    padding: 12px 20px;
    margin: 16px 0 24px;
    font-size: 13px;
    color: #666;
    line-height: 1.5;
}
.pnhq-affiliate-disclosure strong {
    color: var(--pnhq-dark);
}

/* =====================================================
   NEWSLETTER / CTA SECTION
   ===================================================== */
.pnhq-newsletter-cta {
    background: linear-gradient(135deg, var(--pnhq-teal), var(--pnhq-dark));
    border-radius: var(--pnhq-radius-xl);
    padding: 48px;
    text-align: center;
    margin: 48px 0;
    color: white;
}
.pnhq-newsletter-cta h2 {
    color: white;
    font-size: 28px;
    margin: 0 0 8px;
}
.pnhq-newsletter-cta p {
    color: rgba(255,255,255,0.75);
    margin: 0 0 24px;
}
.pnhq-newsletter-form {
    display: flex;
    max-width: 480px;
    margin: 0 auto;
    gap: 8px;
}
.pnhq-newsletter-form input[type="email"] {
    flex: 1;
    padding: 14px 20px;
    border: 2px solid rgba(255,255,255,0.2);
    border-radius: 50px;
    background: rgba(255,255,255,0.1);
    color: white;
    font-size: 15px;
}
.pnhq-newsletter-form input::placeholder { color: rgba(255,255,255,0.5); }

/* =====================================================
   KADENCE OVERRIDES — Full Width Content
   ===================================================== */

/* Force full-width layout on pages using shortcodes */
.home .site-container .site-inner-wrap,
.page .site-container .site-inner-wrap {
    display: block;
}
.home .content-wrap,
.page .content-wrap {
    max-width: 100%;
    width: 100%;
    float: none;
}
.home #primary,
.page #primary {
    width: 100%;
    max-width: 100%;
    float: none;
}
/* Hide sidebar on homepage */
.home #secondary,
.home .widget-area {
    display: none;
}

/* Single post content width */
.single-post .entry-content-wrap {
    max-width: 820px;
    margin: 0 auto;
}

/* Hero needs to break out of content container */
.pnhq-hero {
    margin-left: calc(-50vw + 50%);
    margin-right: calc(-50vw + 50%);
    width: 100vw;
}

/* Pet nav centered and full width */
.pnhq-pet-nav {
    max-width: 1200px;
    margin: 0 auto;
    padding: 30px 20px;
}

/* Card grid centered */
.pnhq-card-grid {
    max-width: 1200px;
    margin: 0 auto;
    padding: 24px 20px;
}

/* Newsletter centered */
.pnhq-newsletter-cta {
    max-width: 1000px;
    margin: 48px auto;
}

.wp-site-blocks .alignfull {
    max-width: none;
}

/* Kadence button overrides */
.wp-block-button__link,
.kb-button {
    border-radius: 50px !important;
}
.wp-block-button__link:not(.has-background) {
    background: var(--pnhq-coral) !important;
}
.wp-block-button__link:hover {
    background: var(--pnhq-coral-hover) !important;
}

/* =====================================================
   SCROLL TO TOP BUTTON
   ===================================================== */
.pnhq-scroll-top {
    position: fixed;
    bottom: 24px;
    right: 24px;
    width: 48px;
    height: 48px;
    background: var(--pnhq-teal);
    color: white;
    border: none;
    border-radius: 50%;
    font-size: 20px;
    cursor: pointer;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.3s, transform 0.3s, background 0.2s;
    z-index: 999;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}
.pnhq-scroll-top.visible {
    opacity: 1;
    transform: translateY(0);
}
.pnhq-scroll-top:hover {
    background: var(--pnhq-coral);
}

/* =====================================================
   READING PROGRESS BAR
   ===================================================== */
.pnhq-reading-progress {
    position: fixed;
    top: 0;
    left: 0;
    height: 3px;
    background: var(--pnhq-coral);
    z-index: 9999;
    transition: width 0.1s linear;
}

/* =====================================================
   RESPONSIVE
   ===================================================== */
@media (max-width: 768px) {
    .pnhq-hero { padding: 48px 20px 40px; }
    .pnhq-card-grid { grid-template-columns: 1fr; gap: 16px; }
    .pnhq-pet-nav { gap: 8px; }
    .pnhq-pet-pill { padding: 8px 14px; font-size: 12px; }
    .pnhq-newsletter-cta { padding: 32px 20px; }
    .pnhq-newsletter-form { flex-direction: column; }
    .single-post .entry-content { font-size: 16px; }
    .single-post .entry-content h2 { font-size: 22px; }
}

/* =====================================================
   HIDE POST TAGS & FIX NAV
   ===================================================== */
/* Hide the #tag display on single posts */
.single-post .post-tags,
.single-post .entry-tags,
.single-post .tags-links,
.single-post .entry-meta .tag-links,
.single-post .wp-block-post-terms,
.single-post .entry-footer .cat-links + .tags-links,
.single-post footer.entry-footer .tags-links {
    display: none !important;
}
/* Kadence-specific tag selectors */
.single-post .entry-content-wrap .post-tags,
.single-post .entry-content-wrap .entry-tags,
.single-post .kadence-entry-tag-wrap {
    display: none !important;
}


/* Hide theme-generated post navigation / similar posts on single articles */
.single-post .post-navigation,
.single-post nav.post-navigation,
.single-post .navigation.post-navigation,
.single-post .post-navigation-wrap,
.single-post .entry-related,
.single-post .similar-posts,
.single-post .related-posts,
.single-post .kadence-related-posts,
.single-post .kt-related-posts {
  display: none !important;
}




/* =====================================================
   SINGLE POST READING WIDTH v1.1.1
   The body_class filter in functions.php forces
   content-style-unboxed, so Kadence handles the layout.
   This just caps the reading width for comfort.
   ===================================================== */
.single-post .content-container.site-container {
    max-width: 1100px;
}
.single-post .entry-content {
    font-size: 17px;
    line-height: 1.7;
}
