/*
Theme Name: GeneratePress Child - Al Muslim Hindi
Template: generatepress
Version: 1.0
*/

/* ==========================================================================
   1. COLOR VARIABLES - saara design isi se control hota hai
   ========================================================================== */
:root {
  --ap-bg: #FAF6EE;          /* cream background */
  --ap-ink: #16302B;         /* dark teal - header, headings */
  --ap-ink-dark: #0F241F;    /* darkest teal - footer */
  --ap-gold: #C9A24B;        /* accent gold */
  --ap-gold-dark: #8A6B2E;   /* dark gold for text on light bg */
  --ap-border: #E5DCC3;      /* soft border/divider */
  --ap-card-tint: #EDE3D0;   /* card/badge background */
  --ap-text: #3A3528;        /* body text */
  --ap-text-muted: #A39C87;  /* dates, meta text */
}

/* ==========================================================================
   2. GLOBAL / TYPOGRAPHY
   ========================================================================== */
body {
  background: var(--ap-bg) !important;
  color: var(--ap-text);
  font-family: 'Inter', 'Noto Sans Devanagari', sans-serif;
}

h1, h2, h3, h4,
.entry-title,
.entry-title a {
  font-family: 'Amiri', 'Noto Sans Devanagari', serif;
  color: var(--ap-ink) !important;
  font-weight: 700;
}

p, li, .entry-content {
  font-family: 'Noto Sans Devanagari', 'Inter', sans-serif;
  line-height: 1.95;
  font-size: 15px;
}

a {
  color: var(--ap-gold-dark);
}
a:hover {
  color: var(--ap-ink);
}

/* ==========================================================================
   3. HEADER / NAVIGATION
   ========================================================================== */
.site-header,
#site-navigation,
.main-navigation {
  background: var(--ap-ink) !important;
}

.main-navigation .main-nav ul li a {
  color: #D8CFB8 !important;
  font-size: 14px;
  font-weight: 500;
}
.main-navigation .main-nav ul li a:hover {
  color: var(--ap-gold) !important;
}

.site-logo .site-title a,
.site-title a {
  color: var(--ap-bg) !important;
  font-family: 'Amiri', serif;
  font-weight: 700;
}

/* thin geometric divider strip under header - optional decorative element */
.site-header::after {
  content: "";
  display: block;
  height: 6px;
  background: var(--ap-ink-dark);
  background-image: repeating-linear-gradient(
    -45deg,
    var(--ap-gold) 0px, var(--ap-gold) 2px,
    transparent 2px, transparent 14px
  );
  opacity: 0.5;
}

/* ==========================================================================
   4. FEATURED IMAGE / HERO (single post banner)
   ========================================================================== */
.single .featured-image,
.single .post-image {
  position: relative;
  border-radius: 0 0 12px 12px;
  overflow: hidden;
}
.single .featured-image img {
  width: 100%;
  height: 320px;
  object-fit: cover;
}
.single .featured-image::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(15,36,31,0.85), rgba(15,36,31,0.1));
}

/* category badge - add class "ap-badge" to your category link via GP hook if needed */
.ap-badge,
.entry-meta .cat-links a {
  display: inline-block;
  background: var(--ap-card-tint);
  color: var(--ap-gold-dark) !important;
  font-size: 11px;
  font-weight: 600;
  padding: 4px 12px;
  border-radius: 20px;
  letter-spacing: 0.3px;
  text-decoration: none;
}

/* ==========================================================================
   5. HADITH / QUOTE BLOCK - apply to blockquote automatically
   ========================================================================== */
.entry-content blockquote {
  position: relative;
  background: #FFFFFF;
  border: 1px solid var(--ap-border);
  border-left: none;
  border-radius: 10px;
  padding: 24px 26px;
  margin: 24px 0;
  text-align: center;
}
.entry-content blockquote p {
  font-style: italic;
  color: var(--ap-ink);
  font-size: 15.5px;
  margin-bottom: 8px;
}
.entry-content blockquote cite {
  font-size: 12px;
  color: var(--ap-gold-dark);
  font-weight: 500;
  font-style: normal;
}
/* manuscript-style corner brackets */
.entry-content blockquote::before,
.entry-content blockquote::after {
  content: "";
  position: absolute;
  width: 18px;
  height: 18px;
  border: 2px solid var(--ap-gold);
  opacity: 0.55;
}
.entry-content blockquote::before {
  top: 8px; left: 8px;
  border-right: none; border-bottom: none;
}
.entry-content blockquote::after {
  bottom: 8px; right: 8px;
  border-left: none; border-top: none;
}

/* ==========================================================================
   6. POST CARDS / RELATED POSTS GRID
   ========================================================================== */
.related-posts,
.jp-relatedposts,
.post-grid {
  display: grid !important;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}

.related-posts .card,
.jp-relatedposts-post,
.post-grid .card {
  background: #FFFFFF;
  border: 1px solid var(--ap-border);
  border-radius: 10px;
  overflow: hidden;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.related-posts .card:hover,
.jp-relatedposts-post:hover,
.post-grid .card:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 18px rgba(22,48,43,0.10);
}

.related-posts .card img,
.jp-relatedposts-post img,
.post-grid .card img {
  width: 100%;
  height: 140px;
  object-fit: cover;
}

.related-posts .card .card-content,
.post-grid .card .card-content {
  padding: 14px;
}

.related-posts .card h3,
.post-grid .card h3 {
  font-family: 'Noto Sans Devanagari', sans-serif;
  font-size: 14px;
  font-weight: 500;
  color: var(--ap-ink) !important;
  line-height: 1.6;
  margin: 0 0 8px;
}

.related-posts .card .date,
.post-grid .card .date {
  font-size: 11px;
  color: var(--ap-text-muted);
}

/* ==========================================================================
   7. COMMENT FORM
   ========================================================================== */
#commentform input[type="text"],
#commentform input[type="email"],
#commentform input[type="url"],
#commentform textarea {
  background: #FFFFFF;
  border: 1px solid var(--ap-border);
  border-radius: 8px;
  padding: 10px 14px;
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  width: 100%;
  margin-bottom: 12px;
}
#commentform input:focus,
#commentform textarea:focus {
  outline: none;
  border-color: var(--ap-gold);
}
#commentform .submit,
#commentform input[type="submit"] {
  background: var(--ap-ink) !important;
  color: var(--ap-bg) !important;
  border: none;
  border-radius: 8px;
  padding: 10px 24px;
  font-weight: 500;
  cursor: pointer;
}
#commentform .submit:hover,
#commentform input[type="submit"]:hover {
  background: var(--ap-gold-dark) !important;
}

/* ==========================================================================
   8. FOOTER
   ========================================================================== */
.site-footer,
#footer {
  background: var(--ap-ink-dark) !important;
  padding: 20px 0;
}
.site-footer a,
#footer a {
  color: #8FA39C !important;
  font-size: 13px;
}
.site-footer a:hover,
#footer a:hover {
  color: var(--ap-gold) !important;
}

/* ==========================================================================
   8b. LOGO FIX - icon aur text overlap na ho
   ========================================================================== */
.site-logo {
  display: flex !important;
  align-items: center;
  gap: 8px;
}
.site-logo img {
  max-height: 32px;
  width: auto;
}
.site-logo .site-title,
.site-logo .site-title a {
  font-size: 18px !important;
  white-space: nowrap;
}
.site-logo .site-description {
  display: none; /* tagline hata di taaki overlap na ho, agar chahiye to ye line hata dena */
}

/* ==========================================================================
   8c. HOMEPAGE / BLOG LISTING - GeneratePress ka default post loop
   Fix: body class guess karne ki bajaye seedha .inside-article target kiya
   (ye hamesha present hoti hai, chahe blog/archive/category/single page ho)
   ========================================================================== */
.inside-article {
  background: #FFFFFF !important;
  border: 1px solid var(--ap-border) !important;
  border-radius: 12px !important;
  padding: 22px 24px !important;
}

article {
  margin-bottom: 18px !important;
  border: none !important; /* GP ka default border hata diya, card ka border upar wala use hoga */
}

/* single post page pe extra card border na chahiye (already featured image wala frame hai),
   isliye single post ke .inside-article se border/shadow hata rahe hain */
.single .inside-article {
  border: none !important;
  padding: 0 !important;
  background: transparent !important;
}

/* ==========================================================================
   8d. SIDEBAR / WIDGET AREA - related posts jaisi grid cheezein
   sidebar ke andar aane par 1 column mein sikud jaye, warna text squeeze hota hai
   ========================================================================== */
.widget-area .related-posts,
.widget-area .jp-relatedposts,
.widget-area .post-grid,
.sidebar .related-posts,
.sidebar .jp-relatedposts,
.sidebar .post-grid,
#right-sidebar .related-posts,
#right-sidebar .jp-relatedposts,
#right-sidebar .post-grid {
  grid-template-columns: 1fr !important;
}

.widget-area .jp-relatedposts-post,
.sidebar .jp-relatedposts-post,
#right-sidebar .jp-relatedposts-post {
  display: flex !important;
  align-items: center;
  gap: 10px;
  padding: 10px !important;
}
.widget-area .jp-relatedposts-post img,
.sidebar .jp-relatedposts-post img,
#right-sidebar .jp-relatedposts-post img {
  width: 60px !important;
  height: 60px !important;
  flex-shrink: 0;
  border-radius: 8px;
}
.widget-area .jp-relatedposts-post h3,
.sidebar .jp-relatedposts-post h3,
#right-sidebar .jp-relatedposts-post h3 {
  font-size: 13px !important;
  margin: 0 !important;
}

/* safety net: agar wo widget "Latest Posts" ka Gutenberg block hai (columns wala) na ki jetpack */
.widget-area .wp-block-latest-posts.is-grid,
.sidebar .wp-block-latest-posts.is-grid,
#right-sidebar .wp-block-latest-posts.is-grid {
  grid-template-columns: 1fr !important;
  gap: 12px !important;
}
.widget-area .wp-block-latest-posts__post-title,
.sidebar .wp-block-latest-posts__post-title {
  font-size: 13px !important;
  line-height: 1.5 !important;
}

/* agar featured image hai to left-right layout, GP class: post-image / featured-image */
.blog article.post .featured-image,
.archive article.post .featured-image {
  border-radius: 8px;
  overflow: hidden;
  margin-bottom: 14px;
}
.blog article.post .featured-image img,
.archive article.post .featured-image img {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.blog .entry-title,
.archive .entry-title {
  font-size: 21px !important;
  margin-bottom: 10px !important;
}

.blog .entry-summary,
.archive .entry-summary,
.entry-content p {
  color: var(--ap-text);
  font-size: 14.5px;
}

/* "Read More" button ko badge/pill jaisa banaya */
.blog a.read-more,
.archive a.read-more,
a.more-link {
  display: inline-block;
  background: var(--ap-ink) !important;
  color: var(--ap-bg) !important;
  font-size: 12.5px !important;
  font-weight: 500;
  padding: 8px 18px;
  border-radius: 20px;
  text-decoration: none !important;
  margin-top: 8px;
}
.blog a.read-more:hover,
.archive a.read-more:hover,
a.more-link:hover {
  background: var(--ap-gold-dark) !important;
}

/* remove GP's default horizontal divider lines between posts since cards handle separation */
.blog article.post + article.post,
.archive article.post + article.post {
  border-top: none !important;
}

/* ==========================================================================
   9. RESPONSIVE
   ========================================================================== */
@media (max-width: 768px) {
  .single .featured-image img { height: 200px; }
  h1, .entry-title { font-size: 22px !important; }
}