/*
Theme Name: chojapod
Theme URI: https://chorjapod.com
Author: ShsmROBi
Description: A vintage-modern WordPress theme for Bengali literature and culture.
Version: 1.0
Tags: bengali, literature, vintage, responsive, two-column
Text Domain: chorjapod
*/

@import url('https://fonts.googleapis.com/css2?family=Noto+Serif+Bengali&display=swap');
@import url("https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.0/css/all.min.css");


/* =Reset & Base
----------------------------------------------- */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Noto Serif Bengali', serif;
  background-color: #fdf8f0;
  color: #2e2e2e;
  line-height: 1.6;
  scroll-behavior: smooth;
}

a {
  color: #704214;
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

img {
  max-width: 100%;
  height: auto;
}

/* =Container
----------------------------------------------- */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 5px;
}

/* =Header
----------------------------------------------- */
.site-header {
  background-color: #efe6d9;
  padding: 5px 0;
  border-bottom: 1px solid #d1c4a5;
  text-align: center;
}

.site-header h1 {
  font-size: 2.5rem;
  color: #4b2e17;
}

.site-header p {
  font-size: 1.2rem;
  color: #7a5e42;
}


/* =Main Content Layout
----------------------------------------------- */
.site-content {
  background-color: #fff;
}

.site-content .content-sidebar-wrap {
  display: flex;
  gap: 2rem;
}

/* =Single Post Layout
----------------------------------------------- */
main.primary {
  flex: 3;
}

.sidebar {
  flex: 2;
  background-color: #fffaf4;
  padding: 1rem;
}

/* =Typography
----------------------------------------------- */
h1, h2, h3, h4 {
  color: #4b2e17;
}


/* =Widgets
----------------------------------------------- */
.widget {
  margin-bottom: 2rem;
}

.widget h3 {
  margin-bottom: 0.5rem;
  font-size: 1.2rem;
  color: #5c3e25;
}

/* =Footer
----------------------------------------------- */
.site-footer {
  background-color: #efe6d9;
  padding: 2rem 0;
  border-top: 1px solid #d1c4a5;
  text-align: center;
  color: #6c4d33;
  font-size: 0.95rem;
}

/* =Animations
----------------------------------------------- */
.fade-in {
  opacity: 0;
  transform: translateY(20px);
  animation: fadeIn 1s ease-out forwards;
}

/* Banner container */
.banner-image {
    position: relative;
    width: 100%;
    overflow: hidden;
    border-radius: 6px;
    margin-bottom: 2rem;
}

.banner-image img {
    width: 100%;
    height: auto;
    object-fit: cover;
}

/* Author image positioning inside banner */
.profile-header-info {
    position: absolute;
    bottom: 15px;
    left: 30px;
    display: flex;
    align-items: center;
    z-index: 10;
    width: 100px;;
}

.author-img {
    width: 120px;
    height: 120px;
    border: 4px solid white;
    object-fit: cover;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

/* Fallback icon if no author image */
.author-img.fallback {
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 48px;
    color: #aaa;
    background-color: #ddd;
    font-family: "Font Awesome 6 Free"; /* Load FA properly */
    font-weight: 900;
}



.profile-container {
    margin: 0 auto;
    padding: 3rem 1rem;
    background: #fdfaf4;
    font-family: 'Noto Serif Bengali', 'EB Garamond', serif;
    color: #2b1d0e;
    border: 1px solid #e5d6c5;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.profile-header-info h2 {
    font-size: 2rem;
    margin-bottom: 0.2rem;
    color: #462c14;
    border-bottom: 2px solid #d1bfa3;
    padding-bottom: 0.3rem;
}

.profile-header-info p {
    font-size: 1rem;
    color: #665444;
    font-family: 'Courier New', monospace;
}

h3 {
    font-size: 1rem;
    color: #40210f;
    border-left: 3px solid #aa8954;
    padding-left: 0.5rem;
}


.form-row {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
}

.form-group {
    flex: 1;
    min-width: 250px;
    margin-top: 3px;
    position: relative;
}

label {
    display: block;
    font-weight: bold;
    margin-bottom: 0.3rem;
    color: #3b2c1f;
}

.bengali-label {
    font-family: 'Noto Serif Bengali', serif;
    font-size: 1.1rem;
}

input[type="text"],
input[type="email"],
input[type="url"],
textarea {
    width: 100%;
    padding: 0.6rem;
    font-size: 1rem;
    border: 1px solid #d8cbb7;
    border-radius: 5px;
    background: #fffaf2;
    color: #2b1d0e;
    transition: border-color 0.3s ease;
}

input:disabled {
    background-color: #f1e9db;
    color: #7d6b5d;
}

textarea {
    resize: vertical;
}

input:focus,
textarea:focus {
    border-color: #aa8954;
    outline: none;
}
input[type="number"], select{
    padding: 0.6rem;
    font-size: 1rem;
    border: 1px solid #d8cbb7;
    border-radius: 5px;
    background: #fffaf2;
    color: #2b1d0e;
    transition: border-color 0.3s ease;
}


.form-message {
    font-size: 0.9rem;
    margin-top: 0.2rem;
    color: red;
}

.form-messages {
  padding: 1rem;
  margin-bottom: 1rem;
  border-radius: 0.5rem;
  text-align: left;
}

.form-messages.success {
  background: #e6ffed;
  color: #05630d;
  border: 1px solid #70d181;
}

.form-messages.errors {
  background: #ffe6e6;
  color: #900;
  border: 1px solid #e09;
}

.errors ul {
    margin: 0;
    padding-left: 1.2rem;
    margin-left:5px ;
}

.submit-btn {
    padding: 0.75rem 1.5rem;
    background-color: #6c4e2a;
    color: #fffaf2;
    font-size: 1rem;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    margin: 1rem 0;
    width: 100%;
}

.submit-btn:hover {
    background-color: #8b6238;
}
.upload-btn {
    background: #3b82f6;
    color: white;
    padding: 8px 14px;
    border-radius: 6px;
    font-size: 14px;
    cursor: pointer;
    transition: background 0.2s ease;
}
.upload-btn:hover {
    background: #2563eb;
}

.file-name {
    font-size: 14px;
    color: #555;
    font-style: italic;
}

.image-preview {
    display: block;
    margin-top: 8px;
    max-width: 100%;
    max-height: 150px;
    border-radius: 6px;
    object-fit: cover;
    border: 1px solid #ddd;
}


.container {
    display: flex;
    flex-wrap: wrap;
    width: 100%;
}

.content-body {
    flex: 0 0 60%;
    max-width: 60%;
}

.sidebar {
    max-width: 40%;
}

@media (max-width: 992px) {
    .content-body,
    .sidebar {
        flex: 0 0 100%;
        max-width: 100%;
    }
}

.tab-buttons {
  display: flex;
  margin:10px 0;
  gap: 1rem;
}
.tab-buttons button {
  background: #f4efe6;
  border: 1px solid #d2c7b8;
  padding: 0.5rem 1rem;
  cursor: pointer;
  font-size: 1rem;
  border-radius: 4px;
  transition: all 0.2s ease;
}
.tab-buttons button.active {
  background: #4b2e17;
  color: #fff;
}
.author-posts-grid {
  display: grid;
  grid-template-columns: repeat(1, 1fr);
  gap: 20px;
}

@media (min-width: 640px) {
  .author-posts-grid {
    grid-template-columns: repeat(2, 1fr); /* tablet */
  }
}

@media (min-width: 1024px) {
  .author-posts-grid {
    grid-template-columns: repeat(2, 1fr); /* desktop also 2 */
  }
}
.post-card {
  display: flex;
  border: 1px solid #ddd;
  background: #fdfcf9;
  border-radius: 6px;
  overflow: hidden;
  transition: transform 0.2s;
}
.post-card:hover { transform: translateY(-4px); }
.post-img {
  flex: 0 0 17%;
}
.post-img img {
  width: 55px;
  height: 70px;
  object-fit: cover;
}
.post-details {
  flex: 1;
  padding: 5px 10px;
}
.post-meta {
  font-size: 0.8rem;
  color: #555;
  margin-bottom: 0.2rem;
}
.post-meta span { margin-right: 0.5rem; }
.post-title {
  font-size: 1.1rem;
  font-weight: bold;
  margin-top: 0.3rem;
  line-height: 1.4;
}



.tab-buttons {
  display: flex;
  align-items: flex-end;   
  gap: 8px;                
  border-left: 2px solid #ccc;
  border-bottom: 2px solid #ccc;
  padding: 5px 10px;
}

.tab-buttons span {
  font-weight: bold;
  margin-right: 10px;
  align-self: flex-end;    
}

.tab-btn {
  background: none;
  border: none;
  padding: 6px 12px;
  cursor: pointer;
  border-radius: 4px 4px 0 0;
}

.tab-btn.active {
  background: #f4f4f4;
  border: 1px solid #ccc;
  border-bottom: none;
}


.chorjapod-excerpt {
    margin-bottom: 10px;
    font-family: Arial, sans-serif;
    line-height: 1.6;
  }

  .toggle-input {
    display: none;
  }

  .more-text {
    display: none;
  }

  .toggle-input:checked ~ p .more-text {
    display: inline;
  }

  .toggle-input:checked ~ p .dots {
    display: none;
  }
  
  .toggle-input:checked ~ p .toggle-label .read-less {
    display: inline;
  }
  .toggle-input:checked ~ p .toggle-label .read-more {
    display: none;
  }

  .toggle-label .read-less {
    display: none;
  }
  .toggle-label .read-more {
    display: inline;
  }
  
  .post-author{
      font-size: 0.9rem;
    margin-bottom: 1rem;
    color: #555;
  }

  .toggle-label {
    color: #704214;
    cursor: pointer;
    font-weight: bold;
    float: right;
    font-size: 15px;
    display: contents;
  }

  .toggle-label:hover {
    text-decoration: underline;
  }
  
 .notice img.puja-banner {
    width: 100%;
    height: auto;
    max-height: 300px;
    object-fit: contain;
    display: block;
border-radius: 10px;
    margin-bottom: 10px;
    animation: fadeInZoom 1.5s ease-out 1; /* 1 = run once */
}

@keyframes fadeInZoom {
    0% {
        opacity: 0;
        transform: scale(0.9);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}





/* ======= Layout ======= */
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 15px;
}

.site-logo img {
  max-width: 200px;
  height: auto;
}

.container {
  display: flex;
  gap: 2rem;
}
.container-top {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  padding: 0 15px;
  max-width: 1200px;
  margin: 0 auto;
}


.top-menu li a {
  padding: 8px 12px;
  display: block;
}

.top-menu li a:hover {
  color: #0073aa;
}

/* ======= Main Navigation ======= */
.menu-toggle-checkbox {
  display: none; /* hide checkbox */
}

.menu-toggle {
  display: none;
  font-size: 2rem;
  cursor: pointer;
  color: #4b2e17;
}

.main-navigation {
  flex-grow: 1;
}

.nav-menu {
  justify-content: flex-end;

}

.nav-menu li {
  position: relative;
}

.nav-menu a {
  display: block;
  padding: 0.5rem 1rem;
  font-weight: bold;
  color: #4b2e17;
  text-decoration: none;
  border-radius: 4px;
  transition: 0.3s;
}

.nav-menu a:hover,
.nav-menu li:hover > a {
  background-color: #b49a6e;
  color: #fff;
}

.nav-menu .current-menu-item > a,
.nav-menu .current_page_item > a {
  background-color: #704214;
  color: #fff;
  pointer-events: none;
}

/* ======= Submenu ======= */
.nav-menu .menu-item-has-children > a::after {
  content: " ▾";
  font-size: 0.8em;
}

.nav-menu .sub-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: -115px;
  background: #fff;
  list-style: none;
  padding: 0.5rem 0;
  min-width: 200px;
  border-radius: 4px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.1);
  z-index: 999;
}

.nav-menu li:hover > .sub-menu,
.nav-menu li:focus-within > .sub-menu {
  display: block;
}

.nav-menu .sub-menu li a {
  padding: 0.5rem 1rem;
  color: #4b2e17;
  white-space: nowrap;
}

.nav-menu .sub-menu li a:hover {
  background-color: #b49a6e;
  color: #fff;
}

/* ======= Responsive ======= */
@media (max-width: 768px) {
  .menu-toggle {
    display: block;
  }

  .main-navigation {
    display: none;
    width: 100%;
    margin-top: 1rem;
  }

  .menu-toggle-checkbox:checked ~ .main-navigation {
    display: flex;
    flex-direction: column;
  }

  .nav-menu {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
  }

  .nav-menu li,
  .nav-menu a {
    width: 100%;
  }

  .nav-menu .sub-menu {
    position: static;
    display: none;
    box-shadow: none;
    background-color: transparent;
    padding-left: 1rem;
  }

  /* Show sub-menu on parent focus */
  .nav-menu li.menu-item-has-children:focus-within > .sub-menu {
    display: flex;
    flex-direction: column;
  }

  .nav-menu .sub-menu a {
    font-weight: normal;
    padding: 0.4rem 1rem;
  }

  .container {
    display: block;
  }
}






.top-menu,
.footer-menu,
.nav-menu {
  list-style: none;
  display: flex;
  padding: 0;
  margin: 0;
}

.top-menu li,
.footer-menu li,
.nav-menu li {
  display: inline-block;
}

.top-menu a,
.footer-menu a,
.nav-menu a {
  text-decoration: none;
  font-weight: bold;
  color: #4b2e17;
}

.top-menu a:hover,
.footer-menu a:hover,
.nav-menu a:hover {
  color: #2a1d12;
}


.footer-navigation {
    margin-bottom: 1rem;
}

.footer-menu {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
}

.footer-menu li {
    display: inline-block;
}

.footer-menu a:hover {
    color: #fff;
    background-color: rgba(255, 255, 255, 0.1);
}


@media (max-width: 768px) {
    .form-row {
        flex-direction: column;
    }
    .profile-header-info{
        width: 70px;
    }
}

@keyframes fadeIn {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
