/*
Theme Name: Nakshathraphalam
Theme URI: https://nakshathraphalam.com
Author: Nakshathraphalam Team
Author URI: https://nakshathraphalam.com
Description: A premium, mobile-first WordPress theme for Nakshathraphalam.com — a Malayalam astrology and horoscope portal covering daily nakshatra phalam, rashi phalam, weekly/monthly/yearly predictions and jyothisha articles. Elegant Kerala-inspired design in deep royal blue and gold, built for speed, SEO (Rank Math ready) and Elementor/Gutenberg compatibility.
Version: 1.1.0
Requires at least: 6.0
Requires PHP: 7.4
Text Domain: nakshathraphalam
Tags: blog, news, one-column, two-columns, right-sidebar, custom-menu, custom-logo, featured-images, full-width-template, theme-options, translation-ready, block-styles, wide-blocks
*/

/* =========================================================
   1. DESIGN TOKENS
   ========================================================= */
:root{
  --np-navy:        #0a1a4d;
  --np-navy-deep:   #071336;
  --np-navy-soft:   #13275f;
  --np-maroon:        #4a1420;
  --np-maroon-deep:   #2c0b13;
  --np-maroon-light:  #6e1f30;
  --np-gold:        #c9a227;
  --np-gold-light:  #e8c877;
  --np-gold-pale:   #f6ecd0;
  --np-cream:       #faf6ec;
  --np-white:       #ffffff;
  --np-ink:         #201c12;
  --np-text:        #2b2a26;
  --np-text-muted:  #6b6558;
  --np-border:      #e7ddc4;
  --np-success:     #4c7a4c;
  --np-radius:      10px;
  --np-radius-lg:   16px;
  --np-shadow:      0 2px 10px rgba(10,26,77,0.08);
  --np-shadow-md:   0 6px 24px rgba(10,26,77,0.12);
  --np-container:   1200px;
  --np-font-mal:    "Noto Sans Malayalam", "Manjari", "Baloo Chettan 2", sans-serif;
  --np-font-en:     "Poppins", "Segoe UI", sans-serif;
  --np-font-serif:  "Playfair Display", "Noto Serif Malayalam", serif;
}

/* =========================================================
   2. RESET & BASE
   ========================================================= */
*, *::before, *::after{ box-sizing: border-box; }
html{ scroll-behavior: smooth; }
body{
  margin:0;
  background: var(--np-cream);
  color: var(--np-text);
  font-family: var(--np-font-mal);
  font-size: 16px;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
}
img{ max-width:100%; height:auto; display:block; }
a{ color: var(--np-navy); text-decoration:none; transition: color .15s ease; }
a:hover{ color: var(--np-gold); }
ul{ margin:0; padding:0; list-style:none; }
button{ font-family:inherit; cursor:pointer; }
.screen-reader-text{
  position:absolute !important;
  width:1px; height:1px; overflow:hidden;
  clip:rect(1px,1px,1px,1px); white-space:nowrap;
}
.skip-link{
  position:absolute; left:-999px; top:0; background:var(--np-navy);
  color:#fff; padding:10px 18px; z-index:10000; border-radius:0 0 8px 0;
}
.skip-link:focus{ left:0; }

h1,h2,h3,h4{
  font-family: var(--np-font-serif);
  color: var(--np-navy);
  line-height:1.3;
  margin:0 0 .6em;
  font-weight:700;
}
p{ margin:0 0 1em; }

.container{
  max-width: var(--np-container);
  margin:0 auto;
  padding: 0 20px;
}
.np-section{ padding: 56px 0; }
.np-section--tight{ padding: 36px 0; }
.np-section--navy{ background: linear-gradient(180deg, var(--np-navy) 0%, var(--np-navy-deep) 100%); color:#f3efe0; }
.np-section--navy h2, .np-section--navy h3{ color: var(--np-gold-light); }
.np-section--cream{ background: var(--np-white); }

.np-eyebrow{
  display:inline-block;
  font-family: var(--np-font-en);
  font-size:12px;
  letter-spacing: 2px;
  text-transform:uppercase;
  color: var(--np-gold);
  font-weight:600;
  margin-bottom:8px;
}
.np-section-head{ text-align:center; max-width:640px; margin:0 auto 36px; }
.np-section-head h2{ font-size: clamp(24px,4vw,32px); margin-bottom:.3em; }
.np-section-head p{ color: var(--np-text-muted); margin:0; }
.np-section--navy .np-section-head p{ color: rgba(243,239,224,.75); }

.np-kerala-divider{
  width:120px; height:14px; margin:0 auto 18px;
  background-image: repeating-linear-gradient(90deg, var(--np-gold) 0 8px, transparent 8px 16px);
  opacity:.7;
}

/* Traditional subtle motif border (used on section wrappers) */
.np-motif-border{
  border-top:1px solid var(--np-border);
  border-bottom:1px solid var(--np-border);
  position:relative;
}
.np-motif-border::before{
  content:"";
  position:absolute; top:-1px; left:0; right:0; height:4px;
  background: repeating-linear-gradient(90deg, var(--np-gold) 0 10px, transparent 10px 20px);
}

/* =========================================================
   3. BUTTONS
   ========================================================= */
.np-btn{
  display:inline-flex; align-items:center; gap:8px;
  padding: 13px 30px;
  background: var(--np-gold);
  color: var(--np-navy-deep);
  font-family: var(--np-font-en);
  font-weight:600; font-size:15px;
  border-radius: 999px;
  border: 1px solid var(--np-gold);
  transition: all .2s ease;
}
.np-btn:hover{ background: var(--np-navy); color:var(--np-gold-light); border-color: var(--np-navy); }
.np-btn--outline{
  background:transparent; color: var(--np-gold-light); border:1px solid var(--np-gold-light);
}
.np-btn--outline:hover{ background: var(--np-gold-light); color: var(--np-navy-deep); }
.np-btn--sm{ padding:8px 18px; font-size:13px; }

/* =========================================================
   4. HEADER
   ========================================================= */
.np-topbar{
  background: var(--np-navy-deep);
  color: rgba(255,255,255,.8);
  font-family: var(--np-font-en);
  font-size: 12.5px;
}
.np-topbar .container{
  display:flex; align-items:center; justify-content:space-between;
  padding-top:6px; padding-bottom:6px;
}
.np-topbar a{ color: rgba(255,255,255,.8); }
.np-topbar a:hover{ color: var(--np-gold-light); }
.np-topbar__date{ opacity:.8; }
.np-topbar__social a{ margin-inline-start:12px; font-size:14px; }

.site-header{
  background: var(--np-navy-deep);
  border-bottom: 1px solid rgba(232,200,119,.2);
  position: sticky; top:0; z-index: 500;
  box-shadow: 0 2px 14px rgba(0,0,0,.25);
}
.site-header__inner{
  display:flex; align-items:center; justify-content:space-between;
  padding: 12px 0;
  gap: 20px;
}
.site-logo{
  display:flex; align-items:center; gap:10px;
  font-family: var(--np-font-serif);
}
.site-logo img{ height:52px; width:auto; }
.site-logo__text{ display:flex; flex-direction:column; line-height:1.15; }
.site-logo__mal{ font-size:22px; font-weight:700; color: var(--np-gold-light); }
.site-logo__en{ font-family: var(--np-font-en); font-size:11px; letter-spacing:2px; color: var(--np-gold); text-transform:uppercase; }

.np-header-actions{ display:flex; align-items:center; gap:14px; }
.np-icon-btn{
  width:40px; height:40px; border-radius:50%;
  display:flex; align-items:center; justify-content:center;
  background: rgba(255,255,255,.06); border:1px solid rgba(232,200,119,.3);
  color: var(--np-gold-light); font-size:16px;
}
.np-icon-btn:hover{ background: var(--np-gold); color: var(--np-navy-deep); border-color: var(--np-gold); }

/* Primary nav */
.main-navigation{ background: var(--np-navy-soft); border-top: 1px solid rgba(0,0,0,.15); }
.main-navigation .container{ display:flex; align-items:center; justify-content:space-between; }
.primary-menu{
  display:flex; flex-wrap:wrap; align-items:center;
}
.primary-menu > li{ position:relative; }
.primary-menu > li > a{
  display:block; padding: 15px 16px;
  color: #eee7cf; font-size:15px; font-weight:500;
  border-bottom: 3px solid transparent;
}
.primary-menu > li > a:hover,
.primary-menu > li.current-menu-item > a{
  color: var(--np-gold-light);
  border-bottom-color: var(--np-gold);
}
.primary-menu .sub-menu{
  display:none; position:absolute; top:100%; left:0; min-width:220px;
  background: var(--np-white); box-shadow: var(--np-shadow-md); border-radius: 0 0 8px 8px;
  padding:8px 0; z-index:100;
}
.primary-menu li:hover > .sub-menu{ display:block; }
.primary-menu .sub-menu a{ padding:10px 18px; display:block; color: var(--np-navy); font-size:14px; }
.primary-menu .sub-menu a:hover{ background: var(--np-cream); color: var(--np-gold); }

.menu-toggle{
  display:none; background:transparent; border:1px solid rgba(255,255,255,.3);
  color:#fff; padding:10px 14px; border-radius:6px; font-size:20px;
}

/* =========================================================
   5. HERO
   ========================================================= */
.np-hero{
  position:relative;
  background: radial-gradient(circle at 30% 30%, var(--np-maroon-light), var(--np-maroon-deep) 70%);
  color:#fff;
  overflow:hidden;
  padding: 70px 0;
}
.np-hero::before{
  content:"";
  position:absolute; inset:0;
  background-image:
    radial-gradient(2px 2px at 10% 20%, rgba(232,200,119,.6) 0, transparent 60%),
    radial-gradient(2px 2px at 80% 15%, rgba(232,200,119,.5) 0, transparent 60%),
    radial-gradient(2px 2px at 60% 70%, rgba(232,200,119,.4) 0, transparent 60%),
    radial-gradient(2px 2px at 30% 80%, rgba(232,200,119,.5) 0, transparent 60%),
    radial-gradient(2px 2px at 90% 60%, rgba(232,200,119,.4) 0, transparent 60%);
  pointer-events:none;
}
.np-hero__inner{
  position:relative; z-index:2;
  display:grid; grid-template-columns: 1.1fr .9fr; gap:40px; align-items:center;
}
.np-hero__eyebrow{
  font-family: var(--np-font-en); letter-spacing:2px; text-transform:uppercase;
  font-size:13px; color: var(--np-gold-light); font-weight:600; margin-bottom:14px; display:block;
}
.np-hero h1{
  color:#fff; font-size: clamp(30px, 5vw, 48px); margin-bottom:16px;
}
.np-hero p.np-hero__subtitle{
  color: rgba(255,255,255,.82); font-size:18px; max-width:520px; margin-bottom:26px;
}
.np-hero__emblem{
  width:100%; max-width:360px; margin:0 auto;
  filter: drop-shadow(0 10px 30px rgba(0,0,0,.35));
}
.np-hero__date-pill{
  display:inline-flex; align-items:center; gap:8px;
  background: rgba(255,255,255,.08); border:1px solid rgba(232,200,119,.4);
  color: var(--np-gold-light); padding:8px 16px; border-radius:999px;
  font-family: var(--np-font-en); font-size:13px; margin-bottom:18px;
}

/* =========================================================
   6. NAKSHATRA & RASHI CARD GRIDS
   ========================================================= */
.np-grid{
  display:grid; gap:18px;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
}
.np-grid--rashi{ grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); }

.np-star-card{
  background: var(--np-white);
  border: 1px solid var(--np-border);
  border-radius: var(--np-radius);
  padding: 20px 14px;
  text-align:center;
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.np-star-card:hover{
  transform: translateY(-4px);
  box-shadow: var(--np-shadow-md);
  border-color: var(--np-gold);
}
.np-star-card__icon{
  width:52px; height:52px; margin:0 auto 12px;
  border-radius:50%;
  background: linear-gradient(145deg, var(--np-gold-pale), var(--np-gold-light));
  display:flex; align-items:center; justify-content:center;
  color: var(--np-navy-deep); font-size:22px;
}
.np-star-card__name{
  font-family: var(--np-font-mal); font-weight:700; font-size:16px;
  color: var(--np-navy); margin-bottom:4px;
}
.np-star-card__meta{ font-size:12px; color: var(--np-text-muted); font-family: var(--np-font-en); }
.np-star-card__link{ position:absolute; inset:0; }
.np-star-card{ position:relative; }

.np-grid-more{ text-align:center; margin-top:28px; }

/* =========================================================
   7. ARTICLES / BLOG GRID
   ========================================================= */
.np-article-grid{
  display:grid; gap:26px;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
}
.np-article-card{
  background:#fff; border:1px solid var(--np-border); border-radius: var(--np-radius-lg);
  overflow:hidden; display:flex; flex-direction:column;
  transition: box-shadow .18s ease, transform .18s ease;
}
.np-article-card:hover{ box-shadow: var(--np-shadow-md); transform: translateY(-3px); }
.np-article-card__thumb{ aspect-ratio:16/10; overflow:hidden; background:var(--np-gold-pale); }
.np-article-card__thumb img{ width:100%; height:100%; object-fit:cover; }
.np-article-card__body{ padding: 18px 20px 22px; flex:1; display:flex; flex-direction:column; }
.np-article-card__cat{
  display:inline-block; align-self:flex-start;
  background: var(--np-gold-pale); color: var(--np-navy-deep);
  font-family: var(--np-font-en); font-size:11px; font-weight:600; letter-spacing:.5px;
  text-transform:uppercase; padding:4px 12px; border-radius:999px; margin-bottom:10px;
}
.np-article-card__title{ font-size:19px; margin-bottom:10px; }
.np-article-card__title a{ color: var(--np-navy); }
.np-article-card__excerpt{ color: var(--np-text-muted); font-size:14.5px; margin-bottom:16px; flex:1; }
.np-article-card__meta{
  font-family: var(--np-font-en); font-size:12.5px; color: var(--np-text-muted);
  display:flex; align-items:center; justify-content:space-between; margin-bottom:12px;
}

/* =========================================================
   8. YOUTUBE / VIDEO SECTION
   ========================================================= */
.np-video-grid{
  display:grid; gap:22px;
  grid-template-columns: repeat(auto-fill, minmax(260px,1fr));
}
.np-video-card{
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(232,200,119,.25);
  border-radius: var(--np-radius-lg);
  overflow:hidden;
}
.np-video-card__frame{ aspect-ratio:16/9; background:#000; }
.np-video-card__frame iframe{ width:100%; height:100%; border:0; }
.np-video-card__title{ padding:14px 16px; font-family: var(--np-font-mal); font-size:15px; color:#f3efe0; }

/* =========================================================
   9. SOCIAL FOLLOW SECTION
   ========================================================= */
.np-social-row{ display:flex; flex-wrap:wrap; gap:14px; justify-content:center; }
.np-social-btn{
  display:flex; align-items:center; gap:10px;
  padding:12px 24px; border-radius:999px;
  font-family: var(--np-font-en); font-weight:600; font-size:14px;
  border:1px solid var(--np-border); background:#fff; color: var(--np-navy);
}
.np-social-btn i{ font-size:18px; }
.np-social-btn--fb:hover{ background:#1877f2; color:#fff; border-color:#1877f2; }
.np-social-btn--ig:hover{ background:#d6249f; color:#fff; border-color:#d6249f; }
.np-social-btn--yt:hover{ background:#ff0000; color:#fff; border-color:#ff0000; }
.np-social-btn--wa:hover{ background:#25d366; color:#fff; border-color:#25d366; }

/* =========================================================
   10. NEWSLETTER
   ========================================================= */
.np-newsletter{
  background: var(--np-gold-pale);
  border-radius: var(--np-radius-lg);
  padding: 36px 30px;
  text-align:center;
}
.np-newsletter h3{ margin-bottom:6px; }
.np-newsletter p{ color: var(--np-text-muted); margin-bottom:20px; }
.np-newsletter-form{
  display:flex; gap:10px; max-width:460px; margin:0 auto; flex-wrap:wrap;
}
.np-newsletter-form input[type=email]{
  flex:1; min-width:200px; padding:13px 16px; border-radius:999px;
  border:1px solid var(--np-border); font-family: var(--np-font-mal); font-size:14px;
}
.np-newsletter-form button{ white-space:nowrap; }

/* =========================================================
   11. AD SLOTS
   ========================================================= */
.np-ad-slot{
  background: repeating-linear-gradient(45deg,#f1ede0,#f1ede0 10px,#ece6d4 10px,#ece6d4 20px);
  border: 1px dashed var(--np-border);
  border-radius: var(--np-radius);
  display:flex; align-items:center; justify-content:center;
  color: var(--np-text-muted); font-family: var(--np-font-en); font-size:12px;
  min-height:100px; margin: 30px 0;
}
.np-ad-slot--leaderboard{ min-height:90px; }
.np-ad-slot--sidebar{ min-height:250px; }

/* =========================================================
   12. SINGLE ARTICLE LAYOUT
   ========================================================= */
.np-breadcrumb{
  font-family: var(--np-font-en); font-size:13px; color: var(--np-text-muted);
  padding: 14px 0;
}
.np-breadcrumb a{ color: var(--np-text-muted); }
.np-breadcrumb a:hover{ color: var(--np-gold); }
.np-breadcrumb .sep{ margin:0 6px; opacity:.5; }

.np-single-layout{ display:grid; grid-template-columns: 2fr 1fr; gap:40px; align-items:start; }
.np-single-content{ background:#fff; border:1px solid var(--np-border); border-radius: var(--np-radius-lg); padding: 30px 34px; }
.np-single-content .np-article-card__cat{ margin-bottom:14px; }
.np-single-content h1{ font-size: clamp(24px,3.4vw,34px); }
.np-single-meta{
  display:flex; flex-wrap:wrap; gap:16px; color: var(--np-text-muted);
  font-family: var(--np-font-en); font-size:13px; border-bottom:1px solid var(--np-border);
  padding-bottom:18px; margin-bottom:22px;
}
.np-single-content .np-featured-img{ border-radius: var(--np-radius); overflow:hidden; margin-bottom:24px; }
.np-single-content article, .np-single-content .entry-content{ font-size:17px; line-height:1.9; }
.np-single-content .entry-content h2{ font-size:22px; margin-top:1.6em; }
.np-single-content .entry-content h3{ font-size:19px; margin-top:1.3em; }
.np-single-content .entry-content blockquote{
  border-inline-start: 4px solid var(--np-gold); margin:1.6em 0; padding: 6px 20px;
  background: var(--np-cream); font-family: var(--np-font-serif); font-style:italic;
  color: var(--np-navy);
}
.np-tags{ margin-top:26px; display:flex; flex-wrap:wrap; gap:8px; }
.np-tags a{
  background: var(--np-cream); border:1px solid var(--np-border); border-radius:999px;
  padding:6px 14px; font-size:12.5px; font-family: var(--np-font-en);
}
.np-share-row{ display:flex; gap:10px; margin-top:20px; }

.np-sidebar .widget{
  background:#fff; border:1px solid var(--np-border); border-radius: var(--np-radius-lg);
  padding:22px; margin-bottom:24px;
}
.np-sidebar .widget-title{
  font-family: var(--np-font-serif); font-size:18px; color: var(--np-navy);
  margin-bottom:16px; padding-bottom:10px; border-bottom:2px solid var(--np-gold-pale);
}
.np-sidebar ul li{ padding:8px 0; border-bottom:1px dashed var(--np-border); font-size:14.5px; }
.np-sidebar ul li:last-child{ border-bottom:0; }

/* =========================================================
   13. FOOTER
   ========================================================= */
.site-footer{ background: var(--np-navy-deep); color: rgba(243,239,224,.82); }
.site-footer a{ color: rgba(243,239,224,.82); }
.site-footer a:hover{ color: var(--np-gold-light); }
.footer-grid{
  display:grid; grid-template-columns: 1.4fr 1fr 1fr 1.1fr; gap:36px;
  padding: 54px 0 34px;
}
.footer-grid h4{ color: var(--np-gold-light); font-size:16px; margin-bottom:16px; }
.footer-about p{ font-size:14px; line-height:1.8; opacity:.85; }
.footer-logo{ display:flex; align-items:center; gap:10px; margin-bottom:14px; }
.footer-logo span{ font-family: var(--np-font-serif); font-size:20px; color:#fff; font-weight:700; }
.footer-grid ul li{ padding:6px 0; font-size:14px; }
.footer-social{ display:flex; gap:10px; margin-top:14px; }
.footer-social a{
  width:36px; height:36px; border-radius:50%; border:1px solid rgba(232,200,119,.4);
  display:flex; align-items:center; justify-content:center;
}
.footer-bottom{
  border-top:1px solid rgba(255,255,255,.1);
  padding: 18px 0; font-size:13px;
  display:flex; flex-wrap:wrap; gap:10px; align-items:center; justify-content:space-between;
}
.footer-bottom-links{ display:flex; gap:16px; flex-wrap:wrap; }

/* =========================================================
   14. SEARCH FORM
   ========================================================= */
.search-form{ display:flex; gap:8px; }
.search-form input[type=search]{
  flex:1; padding:12px 16px; border-radius:999px; border:1px solid var(--np-border);
  font-family: var(--np-font-mal);
}
.search-form button{
  background: var(--np-navy); color:#fff; border:0; border-radius:50%;
  width:44px; height:44px;
}
.np-search-overlay{
  position:fixed; inset:0; background:rgba(7,19,54,.92); z-index:2000;
  display:none; align-items:flex-start; justify-content:center; padding-top:14vh;
}
.np-search-overlay.is-active{ display:flex; }
.np-search-overlay .search-form{ width:min(560px,90vw); }
.np-search-overlay input[type=search]{ padding:16px 20px; font-size:18px; }
.np-search-close{
  position:absolute; top:24px; right:28px; color:#fff; font-size:26px; background:none; border:0;
}

/* =========================================================
   15. UTILITIES / RESPONSIVE
   ========================================================= */
.np-visually-hidden{ position:absolute; width:1px; height:1px; overflow:hidden; clip:rect(0 0 0 0); }

@media (max-width: 960px){
  .np-hero__inner{ grid-template-columns:1fr; text-align:center; }
  .np-hero__emblem{ order:-1; max-width:220px; }
  .np-single-layout{ grid-template-columns:1fr; }
  .footer-grid{ grid-template-columns: 1fr 1fr; }
}

@media (max-width: 720px){
  .np-topbar{ display:none; }
  .menu-toggle{ display:inline-flex; align-items:center; gap:8px; }
  .primary-menu{
    display:none; flex-direction:column; width:100%;
    position:absolute; top:100%; left:0; background: var(--np-navy-deep);
    box-shadow: var(--np-shadow-md);
  }
  .primary-menu.is-open{ display:flex; }
  .primary-menu > li{ width:100%; }
  .primary-menu > li > a{ border-bottom:1px solid rgba(255,255,255,.08); }
  .primary-menu .sub-menu{ position:static; box-shadow:none; background:rgba(255,255,255,.03); display:none; }
  .primary-menu li.is-open > .sub-menu{ display:block; }
  .main-navigation .container{ position:relative; flex-wrap:wrap; padding-top:8px; padding-bottom:8px; }
  .footer-grid{ grid-template-columns: 1fr; padding: 40px 0 20px; }
  .site-logo img{ height:40px; }
  .site-logo__mal{ font-size:18px; }
  .np-section{ padding: 38px 0; }
  .np-hero{ padding: 44px 0; }
}
