/* Urdu Blogs Page - Rishton Ki Mehak */

body {
    font-family: 'Noto Nastaliq Urdu', 'Jameel Noori Nastaleeq', serif;
    background-color: #fafafa;
    margin: 0;
    direction: rtl;
    text-align: right;
}

.blogs-header {
    text-align: center;
    background: #585ccc;
    color: white;
    padding: 10px; /* slightly reduced padding */
}

.blogs-header h1 {
    font-size: 24px; /* was 32px */
    margin-bottom: 4px;
}

.blogs-header .tagline {
    font-size: 14px; /* was 18px */
    opacity: 0.9;
}

/* Blog Container */

/* === Layout === */
.blogs-layout {
    display: flex;
    flex-direction: row-reverse; /* sidebar on right (for Urdu RTL layout) */
    gap: 30px;
    max-width: 1200px;
    margin: 40px auto;
    padding: 0 20px;
}

/* === Sidebar === */
.blogs-sidebar {
    width: 250px;
    background-color: #f5f5f5;
    padding: 20px;
    border-radius: 10px;
    height: fit-content;
    position: sticky;
    top: 20px;
    box-shadow: 0 0 8px rgba(0,0,0,0.1);
}

.blogs-sidebar h3 {
    color: #000f64;
    font-size: 20px;
    margin-bottom: 15px;
    text-align: center;
}

.blogs-sidebar ul {
    list-style: none;
    padding: 0;
}

.blogs-sidebar ul li {
    margin: 10px 0;
}

.blogs-sidebar ul li a {
    color: #333;
    text-decoration: none;
    transition: color 0.3s;
}

.blogs-sidebar ul li a:hover {
    color: #006400;
}

/* === Blog List === */
.blogs-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 25px;
}

/* Each blog as a row */
.blogs-card {
    display: flex;
    flex-direction: row-reverse; /* image on right for Urdu */
    align-items: flex-start;
    gap: 20px;
    background: #fff;
    border-radius: 12px;
    padding: 15px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.05);
}

.blogs-image {
    width: 220px;
    height: 150px;
    object-fit: cover;
    border-radius: 10px;
}

.blogs-body {
    flex: 1;
    text-align: right;
}

.blogs-title {
    font-size: 22px;
    color: #006400;
    margin-bottom: 10px;
}

.blogs-text {
    font-size: 16px;
    color: #333;
    line-height: 1.8;
    margin-bottom: 10px;
}


.blogs-date {
    display: block;
    font-size: 12px;
    color: gray;
    margin-top: 5px;
}

/* === Responsive === */
@media (max-width: 900px) {
    .blogs-layout {
        flex-direction: column;
    }

    .blogs-sidebar {
        width: 100%;
        position: relative;
    }

    .blogs-card {
        flex-direction: column;
        text-align: center;
    }

    .blogs-image {
        width: 100%;
        height: auto;
    }
}



/* Blog Detail Page */
.blogs-detail {
    max-width: 800px;
    margin: 40px auto; /* centers and adds top/bottom spacing */
    padding: 25px;
    background: #fdfdfd;
    border-radius: 12px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    direction: rtl; /* Urdu text direction */
    font-family: 'Noto Nastaliq Urdu', serif;
}

.blogs-detail-image {
    display: block;
    width: 80%;         /* or try 70%, 60%, etc. */
    max-width: 600px;   /* never go beyond this */
    height: auto;
    margin: 0 auto 20px auto;
    border-radius: 10px;
}

.blogs-detail-title {
    text-align: center;
    font-size: 28px;
    color: #006400;
    margin-bottom: 20px;
}

.blogs-detail-text {
    font-size: 18px;
    line-height: 2;
    color: #333;
    text-align: justify;
    margin-bottom: 25px;
}

.blogs-date {
    display: block;
    text-align: left;
    color: gray;
    font-size: 14px;
    margin-top: 10px;
}

.blogs-btn {
    display: inline-block;
    padding: 10px 18px;
    background-color: #006400;
    color: white;
    border-radius: 6px;
    text-decoration: none;
    font-size: 16px;
    transition: background-color 0.3s ease;
}

.blogs-btn:hover {
    background-color: #008000;
}

.blogs-back {
    text-align: center;
    margin-top: 30px;
}

.blogs-edit {
    text-align: right;
    margin-top: 10px;
}
.blogs-edit a {
    font-size: 16px;
    color: #006400;
    text-decoration: none;
}

/* Footer */
.blogs-footer {
  background-color: #f8f8f8;       /* Soft background */
  color: #333;                     /* Text color */
  text-align: center;              /* Center text horizontally */
  padding: 20px 10px;              /* Balanced inner spacing */
  font-size: 15px;                 /* Readable text size */
  border-top: 1px solid #ddd;      /* Subtle top border */
  direction: rtl;                  /* Urdu text direction */
  font-family: 'Noto Nastaliq Urdu', 'Jameel Noori Nastaleeq', serif;
  display: flex;                   /* Enable flexbox for centering */
  justify-content: center;         /* Horizontal centering */
  align-items: center;             /* Vertical centering */
  flex-direction: column;          /* Stack text nicely */
  text-align: center;              /* Ensure text stays centered */
}

.blogs-footer p {
  margin: 0;
  line-height: 1.8;
}

.blogs-footer strong {
  color: #007b8a;
  font-weight: bold;
}

.blogs-footer a {
  color: #007b8a;
  text-decoration: none;
  transition: color 0.3s ease;
}

.blogs-footer a:hover {
  color: #005f68;
}


/* Container */
.add-blog-container {
  direction: rtl;
  font-family: 'Noto Nastaliq Urdu', 'Jameel Noori Nastaleeq', serif;
  max-width: 650px;
  margin: 40px auto;
  padding: 30px 35px;
  background: #ffffff;
  border-radius: 16px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  transition: all 0.3s ease;
}

.add-blog-container:hover {
  transform: translateY(-3px);
}

/* Heading */
.add-blog-container h2 {
  text-align: center;
  margin-bottom: 25px;
  color: #1a1a1a;
  font-size: 28px;
  font-weight: 600;
}

/* Form fields */
.blog-form p {
  margin-bottom: 18px;
}

.blog-form label {
  display: block;
  margin-bottom: 6px;
  font-weight: bold;
  color: #333;
}

.blog-form input[type="text"],
.blog-form input[type="file"],
.blog-form textarea,
.blog-form select {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid #ccc;
  border-radius: 8px;
  font-size: 16px;
  background-color: #fafafa;
  box-sizing: border-box;
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.blog-form input:focus,
.blog-form textarea:focus,
.blog-form select:focus {
  outline: none;
  border-color: #007b8a;
  box-shadow: 0 0 6px rgba(0, 123, 138, 0.3);
  background-color: #fff;
}

/* File upload styling (optional) */
.blog-form input[type="file"] {
  border: 1px dashed #aaa;
  background-color: #f9f9f9;
  cursor: pointer;
}

.blog-form input[type="file"]:hover {
  border-color: #007b8a;
}

/* Responsive */
@media (max-width: 600px) {
  .add-blog-container {
    padding: 20px;
  }

  .add-blog-container h2 {
    font-size: 22px;
  }
}


/* Apply Urdu font and RTL to everything inside Urdu sections */
.urdu, 
.urdu * {
  font-family: 'Noto Nastaliq Urdu', 'Jameel Noori Nastaleeq', serif !important;
  direction: rtl;
  text-align: right;
}

/* Ensure inputs, textareas, and selects follow Urdu styling */
.urdu input[type="text"],
.urdu input[type="file"],
.urdu input[type="email"],
.urdu input[type="password"],
.urdu textarea,
.urdu select {
  font-family: 'Noto Nastaliq Urdu', 'Jameel Noori Nastaleeq', serif !important;
  direction: rtl;
  text-align: right;
  font-size: 16px;
}

/* Style the placeholder text to match Urdu font */
.urdu ::placeholder {
  font-family: 'Noto Nastaliq Urdu', 'Jameel Noori Nastaleeq', serif !important;
  direction: rtl;
  text-align: right;
  opacity: 0.7;
}
