/*
Theme Name: مؤسسة منتدى الألوان للدعاية والإعلان (Montada Printing)
Theme URI: https://montadaprinting.com
Author: مؤسسة منتدى الألوان للدعاية والإعلان
Author URI: https://montadaprinting.com
Description: ثيم ووردبريس متكامل وفائق السرعة لمؤسسة منتدى الألوان للدعاية والإعلان والطباعة الرقمية والأوفست في المملكة العربية السعودية. يعكس الهوية البصرية الرسمية، ويدعم القوائم الديناميكية، خيارات التخصيص الحية (Customizer)، متوافق 100% مع السيو (SEO)، محرري Gutenberg و Elementor، وكافة الأجهزة الذكية.
Version: 1.3.1
Tested up to: 6.7
Requires at least: 6.0
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: montada-theme
Domain Path: /languages
Tags: custom-background, custom-logo, custom-menu, featured-images, flexible-header, footer-widgets, full-width-template, rtl-language-support, theme-options, translation-ready, block-styles, wide-blocks
*/

/* ----------------------------------------------------
   WordPress Core Classes & Layout Helpers
   ---------------------------------------------------- */
.screen-reader-text {
  border: 0;
  clip: rect(1px, 1px, 1px, 1px);
  clip-path: inset(50%);
  height: 1px;
  margin: -1px;
  overflow: hidden;
  padding: 0;
  position: absolute;
  width: 1px;
  word-wrap: normal !important;
}

.screen-reader-text:focus {
  background-color: var(--white, #ffffff);
  border-radius: 4px;
  box-shadow: 0 0 2px 2px rgba(0, 0, 0, 0.6);
  clip: auto !important;
  clip-path: none;
  color: var(--dark-navy, #0b132b);
  display: block;
  font-size: 0.875rem;
  font-weight: 700;
  height: auto;
  right: 15px;
  line-height: normal;
  padding: 15px 23px 14px;
  text-decoration: none;
  top: 15px;
  width: auto;
  z-index: 100000;
}

.alignleft {
  float: right;
  margin: 0.5em 0 1.5em 1.5em;
}

.alignright {
  float: left;
  margin: 0.5em 1.5em 1.5em 0;
}

.aligncenter {
  clear: both;
  display: block;
  margin-left: auto;
  margin-right: auto;
  text-align: center;
}

.alignwide {
  margin-left: -40px;
  margin-right: -40px;
  max-width: calc(100% + 80px);
}

.alignfull {
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  max-width: 100vw;
  width: 100vw;
}

.wp-caption {
  margin-bottom: 1.5em;
  max-width: 100%;
}

.wp-caption img[class*="wp-image-"] {
  display: block;
  margin-left: auto;
  margin-right: auto;
}

.wp-caption-text {
  font-size: 0.85rem;
  color: var(--slate-500, #64748b);
  margin-top: 0.5em;
  text-align: center;
}

/* WordPress Pagination */
.pagination-wrap {
  margin: 50px 0 20px;
  display: flex;
  justify-content: center;
}

.pagination-wrap .nav-links {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}

.pagination-wrap .page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 42px;
  height: 42px;
  padding: 0 14px;
  border-radius: var(--radius-md, 14px);
  background: var(--white, #fff);
  border: 1.5px solid var(--slate-200, #e2e8f0);
  color: var(--slate-700, #334155);
  font-weight: 700;
  font-size: 0.95rem;
  text-decoration: none;
  transition: var(--transition, all 0.3s ease);
}

.pagination-wrap .page-numbers:hover,
.pagination-wrap .page-numbers.current {
  background: var(--primary, #0077b6);
  color: var(--white, #fff);
  border-color: var(--primary, #0077b6);
  box-shadow: 0 4px 12px rgba(0, 119, 182, 0.3);
}

/* Post and Blog Specific Layout */
.blog-layout-grid {
  display: grid;
  grid-template-columns: 2.2fr 1fr;
  gap: 40px;
  margin: 50px 0;
}

.posts-cards-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 28px;
}

.post-card {
  background: var(--white, #fff);
  border-radius: var(--radius-lg, 20px);
  overflow: hidden;
  border: 1px solid var(--slate-200, #e2e8f0);
  box-shadow: var(--shadow-sm, 0 2px 4px rgba(11, 19, 43, 0.05));
  transition: var(--transition, all 0.3s ease);
  display: flex;
  flex-direction: column;
}

.post-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg, 0 20px 35px -10px rgba(11, 19, 43, 0.12));
  border-color: var(--primary, #0077b6);
}

.post-card-thumb {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: var(--slate-800, #1e293b);
}

.post-card-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.post-card:hover .post-card-thumb img {
  transform: scale(1.08);
}

.post-card-body {
  padding: 24px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.post-meta-row {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 0.8rem;
  color: var(--slate-500, #64748b);
  margin-bottom: 12px;
}

.post-meta-row i {
  color: var(--accent-cyan, #00b4d8);
}

.post-card-title {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--dark-navy, #0b132b);
  margin-bottom: 12px;
  line-height: 1.45;
}

.post-card-title a:hover {
  color: var(--primary, #0077b6);
}

.post-card-excerpt {
  font-size: 0.92rem;
  color: var(--slate-600, #475569);
  line-height: 1.7;
  margin-bottom: 20px;
  flex-grow: 1;
}

.btn-read-more {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--primary, #0077b6);
  margin-top: auto;
}

.btn-read-more:hover {
  color: var(--primary-dark, #023e8a);
  gap: 12px;
}

/* Single Post Page */
.single-post-wrapper {
  background: var(--white, #fff);
  border-radius: var(--radius-lg, 20px);
  padding: 40px;
  border: 1px solid var(--slate-200, #e2e8f0);
  box-shadow: var(--shadow-sm, 0 2px 4px rgba(11, 19, 43, 0.05));
  margin: 40px 0;
}

.single-post-header {
  margin-bottom: 30px;
  border-bottom: 1px solid var(--slate-200, #e2e8f0);
  padding-bottom: 24px;
}

.single-post-title {
  font-size: 2.2rem;
  font-weight: 900;
  color: var(--dark-navy, #0b132b);
  margin-bottom: 16px;
  line-height: 1.35;
}

.single-post-thumb {
  border-radius: var(--radius-md, 14px);
  overflow: hidden;
  margin-bottom: 30px;
  max-height: 480px;
}

.single-post-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.single-post-content {
  font-size: 1.05rem;
  line-height: 1.85;
  color: var(--slate-700, #334155);
}

.single-post-content h2,
.single-post-content h3,
.single-post-content h4 {
  color: var(--dark-navy, #0b132b);
  font-weight: 800;
  margin: 30px 0 15px;
}

.single-post-content p {
  margin-bottom: 20px;
}

.single-post-content ul,
.single-post-content ol {
  margin: 0 24px 24px 0;
  list-style: disc;
}

.single-post-content li {
  margin-bottom: 8px;
}

/* Post Tags */
.post-tags-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 30px;
  padding-top: 20px;
  border-top: 1px solid var(--slate-100, #f1f5f9);
}

.post-tag-item {
  background: var(--slate-100, #f1f5f9);
  color: var(--slate-700, #334155);
  padding: 4px 14px;
  border-radius: var(--radius-full, 9999px);
  font-size: 0.82rem;
  font-weight: 700;
  border: 1px solid var(--slate-200, #e2e8f0);
}

.post-tag-item:hover {
  background: var(--primary, #0077b6);
  color: var(--white, #fff);
  border-color: var(--primary, #0077b6);
}

/* Sidebar Styling */
.theme-sidebar {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

@media (min-width: 1025px) {
  .single .theme-sidebar {
    position: sticky;
    top: 90px;
    z-index: 10;
  }
}

.widget-box {
  background: var(--white, #fff);
  border-radius: var(--radius-lg, 20px);
  padding: 24px;
  border: 1px solid var(--slate-200, #e2e8f0);
  box-shadow: var(--shadow-sm, 0 2px 4px rgba(11, 19, 43, 0.05));
  transition: var(--transition, all 0.3s ease);
}

.widget-box:hover {
  box-shadow: var(--shadow-md, 0 10px 25px -5px rgba(11, 19, 43, 0.08));
}

.widget-title {
  font-size: 1.12rem;
  font-weight: 800;
  color: var(--dark-navy, #0b132b);
  margin-bottom: 18px;
  position: relative;
  padding-bottom: 8px;
  display: flex;
  align-items: center;
}

.widget-title::after {
  content: '';
  position: absolute;
  bottom: 0;
  right: 0;
  width: 36px;
  height: 2.5px;
  background: var(--primary, #0077b6);
  border-radius: 2px;
}

.sidebar-post-item:hover {
  transform: translateX(-4px);
}

.sidebar-post-item:hover h5 {
  color: var(--primary, #0077b6) !important;
}

.sidebar-cat-pill:hover {
  background: var(--primary, #0077b6) !important;
  color: #ffffff !important;
  border-color: var(--primary, #0077b6) !important;
  transform: translateX(-4px);
}

.sidebar-cat-pill:hover span:last-child {
  background: rgba(255, 255, 255, 0.25) !important;
  color: #ffffff !important;
  border-color: transparent !important;
}

.search-form-custom .search-field {
  transition: var(--transition, all 0.3s ease);
}

.search-form-custom .search-field:focus {
  border-color: var(--primary, #0077b6);
  background-color: var(--white, #fff);
  box-shadow: 0 0 0 3px rgba(0, 119, 182, 0.15);
}

.search-form-custom .search-submit-btn:hover {
  background: var(--primary-dark, #023e8a);
  transform: scale(1.05);
}

.widget-box ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.widget-box li {
  margin-bottom: 12px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--slate-100, #f1f5f9);
  font-size: 0.92rem;
}

.widget-box li:last-child {
  margin-bottom: 0;
  padding-bottom: 0;
  border-bottom: none;
}

.widget-box a:not(.btn):not(.sidebar-post-item):not(.sidebar-cat-pill) {
  color: var(--slate-700, #334155);
  font-weight: 600;
}

.widget-box a:not(.btn):not(.sidebar-post-item):not(.sidebar-cat-pill):hover {
  color: var(--primary, #0077b6);
  padding-right: 4px;
}

/* Sidebar CTA Buttons - Explicit White Text */
.theme-sidebar .btn,
.widget-box .btn,
.theme-sidebar .btn-whatsapp,
.widget-box .btn-whatsapp,
.theme-sidebar .btn-outline-white,
.widget-box .btn-outline-white {
  color: #ffffff !important;
  text-decoration: none;
}

.theme-sidebar .btn:hover,
.widget-box .btn:hover {
  padding-right: 16px !important;
}

.theme-sidebar .btn-whatsapp,
.widget-box .btn-whatsapp {
  background: linear-gradient(135deg, #25d366, #128c7e) !important;
  color: #ffffff !important;
}

.theme-sidebar .btn-whatsapp *,
.widget-box .btn-whatsapp * {
  color: #ffffff !important;
}

.theme-sidebar .btn-whatsapp:hover,
.widget-box .btn-whatsapp:hover {
  background: linear-gradient(135deg, #22c55e, #0f766e) !important;
  color: #ffffff !important;
  transform: translateY(-2px);
}

.theme-sidebar .btn-outline-white,
.widget-box .btn-outline-white {
  background: rgba(255, 255, 255, 0.1) !important;
  color: #ffffff !important;
  border: 1.5px solid rgba(255, 255, 255, 0.3) !important;
}

.theme-sidebar .btn-outline-white *,
.widget-box .btn-outline-white * {
  color: #ffffff !important;
}

.theme-sidebar .btn-outline-white:hover,
.widget-box .btn-outline-white:hover {
  background: rgba(255, 255, 255, 0.22) !important;
  color: #ffffff !important;
  border-color: #ffffff !important;
  transform: translateY(-2px);
}

/* Comments Section */
.comments-area {
  margin-top: 40px;
  padding-top: 30px;
  border-top: 1.5px solid var(--slate-200, #e2e8f0);
}

.comments-title {
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--dark-navy, #0b132b);
  margin-bottom: 24px;
}

.comment-list {
  list-style: none;
  padding: 0;
  margin: 0 0 40px;
}

.comment {
  background: var(--slate-50, #f8fafc);
  border-radius: var(--radius-md, 14px);
  padding: 22px;
  border: 1px solid var(--slate-200, #e2e8f0);
  margin-bottom: 20px;
}

.comment-meta {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 12px;
}

.comment-author .fn {
  font-weight: 800;
  color: var(--dark-navy, #0b132b);
}

.comment-metadata a {
  font-size: 0.8rem;
  color: var(--slate-500, #64748b);
}

.comment-content {
  font-size: 0.95rem;
  color: var(--slate-700, #334155);
  line-height: 1.7;
}

.comment-reply-link {
  display: inline-block;
  margin-top: 10px;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--primary, #0077b6);
}

/* Comment Form */
.comment-respond {
  background: var(--slate-50, #f8fafc);
  padding: 30px;
  border-radius: var(--radius-lg, 20px);
  border: 1px solid var(--slate-200, #e2e8f0);
}

.comment-reply-title {
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--dark-navy, #0b132b);
  margin-bottom: 20px;
}

.comment-form p {
  margin-bottom: 16px;
}

.comment-form label {
  display: block;
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--slate-700, #334155);
  margin-bottom: 6px;
}

.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea {
  width: 100%;
  padding: 12px 16px;
  border: 1.5px solid var(--slate-200, #e2e8f0);
  border-radius: var(--radius-md, 14px);
  background: var(--white, #fff);
  font-family: inherit;
  font-size: 0.95rem;
}

.comment-form input[type="submit"] {
  background: linear-gradient(135deg, var(--primary, #0077b6), var(--primary-dark, #023e8a));
  color: var(--white, #fff);
  padding: 12px 28px;
  border-radius: var(--radius-md, 14px);
  font-weight: 800;
  font-size: 0.98rem;
  cursor: pointer;
  border: none;
  transition: var(--transition, all 0.3s ease);
}

.comment-form input[type="submit"]:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 119, 182, 0.45);
}

/* Responsive Overrides */
.archive-cards-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}

@media (max-width: 1024px) {
  .blog-layout-grid {
    grid-template-columns: 1fr;
  }
  .archive-cards-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }
}

@media (max-width: 768px) {
  .posts-cards-grid,
  .archive-cards-grid {
    grid-template-columns: 1fr;
  }
  .single-post-wrapper {
    padding: 24px 18px;
  }
  .single-post-title {
    font-size: 1.7rem;
  }
}
