/*
 Theme Name:   HBS Astra Child
 Theme URI:    https://healthnbeautystuff.com
 Description:  Custom child theme for Health N Beauty Stuff – based on Astra
 Author:       Health N Beauty Stuff
 Author URI:   https://healthnbeautystuff.com
 Template:     astra
 Version:      1.0.0
 License:      GNU General Public License v2 or later
 License URI:  https://www.gnu.org/licenses/gpl-2.0.html
 Text Domain:  hbs-astra-child
*/

/* ══════════════════════════════════════════════════════
   HOMEPAGE STYLES  (front-page.php)
   Exact copy from original HTML design — DO NOT MODIFY
   ══════════════════════════════════════════════════════ */

/* Standard box sizing */
*, *::before, *::after { box-sizing: border-box; }
/* Scope resets to avoid breaking Astra's default layout */
.hbs-nav, .hbs-footer, .hbs-hero, .hbs-categories, .hbs-latest, .hbs-tips, .hbs-newsletter { margin: 0; padding: 0; }

:root {
  --green:       #2d7a4f;
  --green-light: #e8f5ee;
  --green-mid:   #4a9e6b;
  --pink:        #e05a8a;
  --pink-light:  #fdeef4;
  --pink-mid:    #f0829e;
  --dark:        #1a1a1a;
  --muted:       #6b7280;
  --border:      #e5e7eb;
  --white:       #ffffff;
  --off-white:   #fafafa;
}

html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', sans-serif;
  color: var(--dark);
  background: var(--white);
  line-height: 1.6;
}

h1, h2, h3 { font-family: 'Playfair Display', serif; line-height: 1.25; }
a { text-decoration: none; color: inherit; }
img { display: block; max-width: 100%; height: auto; }

/* ── UTILITY ─────────────────────────────────────── */
.hbs-container { max-width: 1100px; margin: 0 auto; padding: 0 20px; width: 100%; }


.section-label {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 4px 12px;
  border-radius: 20px;
  margin-bottom: 12px;
}

.label-green { background: var(--green-light); color: var(--green); }
.label-pink  { background: var(--pink-light);  color: var(--pink);  }

/* ── TOP BAR ─────────────────────────────────────── */
.hbs-topbar {
  background: var(--green);
  color: #fff;
  font-size: 0.75rem;
  text-align: center;
  padding: 7px 20px;
  letter-spacing: 0.04em;
}
.hbs-topbar span { opacity: 0.85; }

/* ── NAV ─────────────────────────────────────────── */
.hbs-nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--white);
  border-bottom: 1px solid var(--border);
}

.hbs-nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 20px;
  height: 62px;
}

/* Logo */
.hbs-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
  transition: transform 0.2s;
}
.hbs-logo:hover { transform: scale(1.03); }

.hbs-logo-icon {
  width: 38px;
  height: 38px;
  background: var(--green);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.hbs-logo-icon svg { width: 22px; height: 22px; }

.hbs-logo-text { display: flex; flex-direction: column; line-height: 1.1; }

.hbs-logo-main {
  font-family: 'Playfair Display', serif;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--green);
}
.hbs-logo-main span { color: var(--pink); }

.hbs-logo-sub {
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}

/* Desktop nav links */
.hbs-nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
  list-style: none;
}

.hbs-nav-links a {
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--dark);
  padding: 6px 10px;
  border-radius: 6px;
  transition: background 0.18s, color 0.18s;
}

.hbs-nav-links a:hover { background: var(--green-light); color: var(--green); }

.hbs-nav-cta {
  background: var(--pink);
  color: #fff !important;
  padding: 7px 16px !important;
  border-radius: 20px !important;
  font-weight: 600 !important;
  font-size: 0.8rem !important;
  transition: opacity 0.2s !important;
}

.hbs-nav-cta:hover { background: var(--pink) !important; opacity: 0.88; }

/* Hamburger */
.hbs-hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 4px;
  background: none;
  border: none;
}

.hbs-hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--dark);
  border-radius: 2px;
  transition: all 0.25s;
}

/* Mobile menu */
.hbs-mobile-menu {
  display: none;
  flex-direction: column;
  background: var(--white);
  border-bottom: 1px solid var(--border);
  padding: 12px 20px 16px;
  gap: 4px;
}
.hbs-mobile-menu.open { display: flex; }

.hbs-mobile-menu a {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--dark);
  padding: 9px 10px;
  border-radius: 8px;
  transition: background 0.15s;
}
.hbs-mobile-menu a:hover { background: var(--green-light); color: var(--green); }

/* ── HERO ─────────────────────────────────────────── */
.hbs-hero {
  background: var(--off-white);
  padding: 72px 20px 64px;
  text-align: center;
  border-bottom: 1px solid var(--border);
}

.hbs-hero-eyebrow {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--pink);
  margin-bottom: 16px;
}

.hbs-hero h1 {
  font-size: clamp(2rem, 5vw, 3.2rem);
  color: var(--dark);
  max-width: 680px;
  margin: 0 auto 18px;
}

.hbs-hero h1 em {
  font-style: italic;
  color: var(--green);
}

.hbs-hero p {
  font-size: 1rem;
  color: var(--muted);
  max-width: 520px;
  margin: 0 auto 32px;
}

.hbs-hero-btns {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}

.hbs-btn-primary {
  background: var(--green);
  color: #fff;
  padding: 12px 28px;
  border-radius: 28px;
  font-size: 0.88rem;
  font-weight: 600;
  border: none;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s, opacity 0.2s;
  display: inline-block;
}
.hbs-btn-primary:hover {
  opacity: 0.92;
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(45,122,79,0.3);
}

.hbs-btn-outline {
  background: transparent;
  color: var(--pink);
  padding: 11px 28px;
  border-radius: 28px;
  font-size: 0.88rem;
  font-weight: 600;
  border: 2px solid var(--pink);
  cursor: pointer;
  transition: background 0.2s, color 0.2s, transform 0.2s, box-shadow 0.2s;
  display: inline-block;
}
.hbs-btn-outline:hover {
  background: var(--pink);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(224,90,138,0.3);
}

/* Hero stats */
.hbs-hero-stats {
  display: flex;
  justify-content: center;
  gap: 36px;
  margin-top: 48px;
  flex-wrap: wrap;
}

.hbs-stat {
  text-align: center;
  transition: transform 0.2s;
}
.hbs-stat:hover { transform: translateY(-4px); }

.hbs-stat-num {
  font-family: 'Playfair Display', serif;
  font-size: 1.7rem;
  font-weight: 700;
  color: var(--green);
}

.hbs-stat-label {
  font-size: 0.72rem;
  color: var(--muted);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-top: 2px;
}

/* ── CATEGORIES ──────────────────────────────────── */
.hbs-categories { padding: 64px 20px; }

.hbs-section-header { text-align: center; margin-bottom: 36px; }
.hbs-section-header h2 { font-size: clamp(1.5rem, 3vw, 2rem); color: var(--dark); margin-bottom: 8px; }
.hbs-section-header p { font-size: 0.9rem; color: var(--muted); }

.hbs-cat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 14px;
}

.hbs-cat-card {
  background: var(--white);
  border: 1.5px solid var(--border);
  border-radius: 14px;
  padding: 22px 14px;
  text-align: center;
  transition: border-color 0.2s, transform 0.2s, box-shadow 0.2s;
  cursor: pointer;
  display: block;
}

.hbs-cat-card:hover {
  border-color: var(--green);
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(45,122,79,0.1);
}

.hbs-cat-icon {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 12px;
  font-size: 1.3rem;
}

.hbs-cat-icon.g { background: var(--green-light); }
.hbs-cat-icon.p { background: var(--pink-light); }

.hbs-cat-card h3 { font-family: 'Inter', sans-serif; font-size: 0.82rem; font-weight: 600; color: var(--dark); }
.hbs-cat-card span { font-size: 0.7rem; color: var(--muted); }

/* ── LATEST POSTS ────────────────────────────────── */
.hbs-latest { background: var(--off-white); padding: 64px 20px; }

/* Featured post (big) */
.hbs-posts-layout {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 24px;
  align-items: start;
}

.hbs-post-featured {
  background: var(--white);
  border: 1.5px solid var(--border);
  border-radius: 16px;
  overflow: hidden;
  transition: box-shadow 0.2s;
  display: block;
}
.hbs-post-featured:hover { box-shadow: 0 10px 32px rgba(0,0,0,0.08); }

/* Image wrapper with aspect ratio */
.hbs-post-img-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: var(--green-light);
  overflow: hidden;
}

.hbs-post-img-wrap img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s;
}

.hbs-post-featured:hover .hbs-post-img-wrap img { transform: scale(1.03); }

/* Image placeholder */
.hbs-img-placeholder {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--green-light);
  font-size: 2.5rem;
}

.hbs-post-body { padding: 22px 24px 24px; }

.hbs-post-meta { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 10px; }

.hbs-post-cat {
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--pink);
  background: var(--pink-light);
  padding: 3px 10px;
  border-radius: 20px;
}

.hbs-post-cat-green {
  color: var(--green);
  background: var(--green-light);
}

.hbs-post-date { font-size: 0.72rem; color: var(--muted); }
.hbs-post-read { font-size: 0.72rem; color: var(--muted); }

.hbs-post-featured h3 { font-size: 1.3rem; color: var(--dark); margin-bottom: 10px; }
.hbs-post-featured p { font-size: 0.85rem; color: var(--muted); margin-bottom: 16px; line-height: 1.65; }

.hbs-read-link {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--green);
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.hbs-read-link:hover { text-decoration: underline; color: var(--green); }

/* Sidebar list posts */
.hbs-post-list { display: flex; flex-direction: column; gap: 14px; }

.hbs-post-list-item {
  background: var(--white);
  border: 1.5px solid var(--border);
  border-radius: 12px;
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  transition: box-shadow 0.2s, border-color 0.2s;
}

.hbs-post-list-item:hover { border-color: var(--green-mid); box-shadow: 0 4px 14px rgba(45,122,79,0.08); }
.hbs-post-list-item .hbs-post-cat { align-self: flex-start; }
.hbs-post-list-item h3 { font-size: 0.88rem; font-weight: 600; font-family: 'Inter', sans-serif; color: var(--dark); line-height: 1.4; }
.hbs-post-list-item .hbs-post-date { font-size: 0.7rem; color: var(--muted); }
.hbs-post-list-item .hbs-read-link { font-size: 0.78rem; }

.hbs-view-all-wrap { text-align: center; margin-top: 36px; }

/* ── WELLNESS TIPS ────────────────────────────────── */
.hbs-tips {
  padding: 64px 20px;
  background: linear-gradient(135deg, #e8f5ee 0%, #fdeef4 50%, #e8f5ee 100%);
  position: relative;
}

.hbs-tips-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 18px;
}

.hbs-tip-card {
  background: rgba(255,255,255,0.85);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1.5px solid rgba(255,255,255,0.6);
  border-radius: 16px;
  padding: 28px 22px 22px;
  transition: transform 0.25s, box-shadow 0.25s;
  position: relative;
}
.hbs-tip-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 32px rgba(0,0,0,0.1);
}

.hbs-tip-icon-wrap {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  margin-bottom: 16px;
}
.hbs-tip-green { background: var(--green-light); }
.hbs-tip-pink  { background: var(--pink-light); }

.hbs-tip-card h3 { font-family: 'Inter', sans-serif; font-size: 0.92rem; font-weight: 600; margin-bottom: 8px; color: var(--dark); }
.hbs-tip-card p { font-size: 0.8rem; color: var(--muted); line-height: 1.65; margin-bottom: 14px; }

.hbs-tip-tag {
  display: inline-block;
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 3px 10px;
  border-radius: 20px;
  background: rgba(45,122,79,0.08);
  color: var(--green);
}

.hbs-tip-card.green-accent { border-left: 3px solid var(--green); }
.hbs-tip-card.pink-accent  { border-left: 3px solid var(--pink); }
.hbs-tip-card.pink-accent .hbs-tip-tag { background: rgba(224,90,138,0.08); color: var(--pink); }

/* ── NEWSLETTER ──────────────────────────────────── */
.hbs-newsletter {
  background: var(--green);
  padding: 64px 20px;
  text-align: center;
}

.hbs-newsletter h2 { font-size: clamp(1.4rem, 3vw, 2rem); color: #fff; margin-bottom: 10px; }
.hbs-newsletter p { font-size: 0.9rem; color: rgba(255,255,255,0.82); max-width: 480px; margin: 0 auto 28px; }

.hbs-newsletter-form {
  display: flex;
  gap: 10px;
  max-width: 460px;
  margin: 0 auto;
  flex-wrap: wrap;
  justify-content: center;
}

.hbs-newsletter-form input {
  flex: 1;
  min-width: 220px;
  padding: 12px 18px;
  border-radius: 28px;
  border: none;
  font-family: 'Inter', sans-serif;
  font-size: 0.88rem;
  outline: none;
}

.hbs-newsletter-form button {
  background: var(--pink);
  color: #fff;
  border: none;
  padding: 12px 24px;
  border-radius: 28px;
  font-family: 'Inter', sans-serif;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  transition: opacity 0.2s;
}
.hbs-newsletter-form button:hover { opacity: 0.88; }

.hbs-newsletter-note { font-size: 0.72rem; color: rgba(255,255,255,0.6); margin-top: 12px; }

.hbs-newsletter-success {
  display: none;
  background: rgba(255,255,255,0.15);
  border: 1px solid rgba(255,255,255,0.3);
  border-radius: 12px;
  padding: 14px 24px;
  color: #fff;
  font-size: 0.9rem;
  max-width: 400px;
  margin: 0 auto;
}

/* ── FOOTER ──────────────────────────────────────── */
.hbs-footer {
  background: #111;
  color: rgba(255,255,255,0.75);
  padding: 48px 20px 24px;
}

.hbs-footer-grid {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1fr;
  gap: 36px;
  max-width: 1100px;
  margin: 0 auto 36px;
}

.hbs-footer-brand .hbs-logo-main { color: #fff; font-size: 1.1rem; }
.hbs-footer-brand .hbs-logo-main span { color: var(--pink-mid); }
.hbs-footer-brand p { font-size: 0.8rem; color: rgba(255,255,255,0.55); margin-top: 10px; line-height: 1.7; max-width: 280px; }

.hbs-footer-col h4 { font-family: 'Inter', sans-serif; font-size: 0.78rem; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: rgba(255,255,255,0.45); margin-bottom: 14px; }
.hbs-footer-col ul { list-style: none; display: flex; flex-direction: column; gap: 8px; }
.hbs-footer-col ul li a { font-size: 0.83rem; color: rgba(255,255,255,0.7); transition: color 0.15s, padding-left 0.15s; }
.hbs-footer-col ul li a:hover { color: var(--green-mid); padding-left: 4px; }

.hbs-footer-bottom {
  max-width: 1100px;
  margin: 0 auto;
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  font-size: 0.75rem;
  color: rgba(255,255,255,0.35);
}

.hbs-footer-bottom a { color: rgba(255,255,255,0.5); }
.hbs-footer-bottom a:hover { color: var(--pink-mid); }

/* ── RESPONSIVE ──────────────────────────────────── */
@media (max-width: 900px) {
  .hbs-posts-layout { grid-template-columns: 1fr; }
  .hbs-post-list { flex-direction: column; }
}

@media (max-width: 768px) {
  .hbs-nav-links { display: none; }
  .hbs-hamburger { display: flex; }
  .hbs-footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 520px) {
  .hbs-hero { padding: 52px 20px 44px; }
  .hbs-footer-grid { grid-template-columns: 1fr; }
  .hbs-hero-stats { gap: 24px; }
  .hbs-cat-grid { grid-template-columns: repeat(2, 1fr); }
  .hbs-tips-grid { grid-template-columns: 1fr; }
}

/* ── Astra Layout Compatibility ────────────────────────────── */

/* 
   The following selectors ensure that Astra's standard layout 
   settings (like Narrow Width) work with our custom header/footer.
   We avoid !important here so your Customizer settings take priority.
*/
.ast-narrow-container .site-content > .ast-container,
.ast-narrow-container .site-content .ast-container {
    margin: 0 auto;
    width: 100%;
}

/* Ensure single post content area is centered and takes full width of its container */
.single-post.ast-narrow-container #primary {
    width: 100%;
}

/* Add default padding for single post content so it doesn't hit the screen edges on mobile */
.single-post .site-content .ast-container {
    padding-left: 20px;
    padding-right: 20px;
}
