:root {
  --primary: #111;
  --accent: #bfa14a; /* elegant gold */
  --bg: #ffffff;
  --text: #333;
  --radius: 8px;
  --shadow: 0 4px 16px rgba(0,0,0,.08);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: "Source Sans Pro", 'SolaimanLipi', sans-serif;
  background: var(--bg);
  color: var(--text);
  scroll-behavior: smooth;
  padding-top: 70px; /* offset for fixed header */
  font-size: 1.05rem;       /* readability */
  line-height: 1.7;
}

/* Header */
header {
  position: fixed;
  top: 0; left: 0; right: 0;
  background: #fff;
  border-bottom: 1px solid #eee;
  z-index: 1000;
  padding: 14px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  display: flex; align-items: center; gap: 10px;
}
.logo span {
  font-family: "Libre Baskerville", 'SolaimanLipi', serif;
  font-size: 1.4rem;
  color: var(--primary);
}
.logo img {
  width: 32px;
  height: auto;
}

/* Desktop nav */
.nav-links {
  display: flex;
  align-items: center;
  gap: 24px;
}
.nav-links a {
  color: var(--primary);
  text-decoration: none;
  font-weight: 600;
  position: relative;
  transition: color .25s ease;
}
.nav-links a::after {
  content: "";
  position: absolute;
  left: 0; bottom: -6px;
  width: 0; height: 2px;
  background: var(--accent);
  transition: width .25s ease;
}
.nav-links a:hover { color: var(--accent); }
.nav-links a:hover::after { width: 100%; }

/* Language toggle pill */
.lang-toggle {
  border: 2px solid var(--accent);
  color: var(--accent);
  padding: 6px 14px;
  border-radius: 20px;
  font-weight: 700;
  text-decoration: none; /* no underline */
  transition: all .25s ease;
  position: relative;
}
.lang-toggle::after { display: none; } /* remove underline effect */
.lang-toggle:hover {
  background: var(--accent);
  color: #fff; /* text color change on hover */
}

/* Hamburger */
.menu-toggle {
  display: none;
  cursor: pointer;
  font-size: 1.6rem;
  color: var(--primary);
}

/* Overlay */
.overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.5);
  opacity: 0; visibility: hidden;
  transition: opacity .3s ease;
  z-index: 999;
}

/* Mobile nav panel */
@media (max-width: 768px) {
  .menu-toggle { display: block; }
  .nav-links {
    position: fixed;
    top: 0; right: -100%;
    height: 100%;
    width: 260px;
    background: #fff;
    flex-direction: column;
    padding: 80px 20px;
    gap: 20px;
    box-shadow: -4px 0 20px rgba(0,0,0,.1);
    transition: right .3s ease;
    z-index: 1001;
  }
  .nav-links.active { right: 0; }
  .overlay.active {
    opacity: 1; visibility: visible;
  }
  body.lock-scroll { overflow: hidden; }
}

/* Sections */
section {
  padding: 80px 20px; /* reduced whitespace */
  max-width: 1100px;
  margin: 0 auto;
  opacity: 0; transform: translateY(40px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}
section.visible { opacity: 1; transform: translateY(0); }
section p {
  font-size: 1.1rem;
  line-height: 1.8;
}

/* Hero */
.hero {
  min-height: calc(100vh - 70px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  position: relative;
  background-image: url('/images/hero_image.webp');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  color: #fff;
  padding: 40px 20px;
  overflow: hidden;
}
.hero::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.45);
  z-index: 0;
}
.hero h2,
.hero p,
.hero .btn {
  position: relative;
  z-index: 1;
}
.hero h2 {
  font-family: "Libre Baskerville", 'SolaimanLipi', serif;
  font-size: 3rem;
  margin-top: 380px;
  margin-bottom: 20px;
  color: #fff;
  text-shadow: 0 2px 6px rgba(0,0,0,0.6);
}

.hero p {
  font-size: 1.2rem;
  max-width: 700px;
  margin: 0 auto;
  color: #f0f0f0;
  text-shadow: 0 1px 4px rgba(0,0,0,0.5);
}

.btn {
  margin-top: 30px;
  padding: 12px 24px;
  border-radius: var(--radius);
  border: 2px solid var(--accent);
  background: rgba(255,255,255,0.1);
  color: var(--accent);
  font-weight: 600;
  text-decoration: none;
  transition: all .3s ease;
}
.btn:hover {
  background: var(--accent);
  color: #fff;
}

/* Language toggle switch */
.lang-switch {
  position: relative;
  display: inline-flex;
  border: 2px solid var(--accent);
  border-radius: 6px;
  overflow: hidden;
  width: 80px;
  height: 32px;
  font-weight: 700;
}

.lang-option {
  flex: 1;
  text-align: center;
  line-height: 28px;
  text-decoration: none;
  color: var(--accent);
  font-size: 0.9rem;
  z-index: 2;
  transition: color .25s ease;
}

.lang-option.active {
  color: #fff;
}

.lang-slider {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 50%;
  background: var(--accent);
  transition: left .3s ease;
  z-index: 1;
}

.lang-slider.en { left: 0; }
.lang-slider.bn { left: 50%; }


/* Works */
.works {
  display: grid;
  grid-template-columns: repeat(auto-fit,minmax(260px,1fr));
  gap: 28px;
}
.work {
  background: #fff;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 24px;
  text-align: center;
  transition: transform .3s ease;
}
.work:hover { transform: translateY(-6px); }
.work h3 {
  margin: 10px 0;
  color: var(--accent);
  border-left: none;
}
.work p {
  font-size: 1rem;
  line-height: 1.6;
  color: var(--text);
}

.work img {
  width: calc(100% - 12px);
  height: auto;
}

/* Published Books category headings */
section h3 {
  font-family: "Libre Baskerville", 'SolaimanLipi', serif;
  font-size: 1.4rem;
  margin-top: 30px;
  margin-bottom: 12px;
  color: var(--accent);
  border-left: 4px solid var(--accent);
  padding-left: 10px;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}
section h3.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Book list items */
section ul {
  list-style: none;
  padding-left: 0;
  margin-bottom: 20px;
}
section ul li {
  margin: 6px 0;
  line-height: 1.6;
  color: var(--text);
  padding-left: 18px;
  position: relative;
  opacity: 0;
  transform: translateY(15px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
section ul li::before {
  content: "•";
  position: absolute;
  left: 0;
  color: var(--accent);
  font-weight: bold;
}
section ul li.visible {
  opacity: 1;
  transform: translateY(0);
}


ol {
  text-indent: 10px;
  padding: 20px 0px 20px 50px;
  line-height: 2;
}

/* Default English numbering */
    ol.en {
      list-style-type: decimal; /* 1, 2, 3… */
    }

    /* Bengali numbering */
    ol.bn {
      list-style-type: bengali; /* ১, ২, ৩… */
    }

@media (max-width: 768px) {
  ol {
  padding: 20px 0px 20px 20px;
}
}

#cta-highlights {
  text-align: center;
  background: #f9f9f9;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  margin: 60px auto;
  max-width: 900px;
  padding: 40px 20px;
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

#cta-highlights.visible {
  opacity: 1;
  transform: translateY(0);
}

#cta-highlights h2 {
  color: var(--accent);
  margin-bottom: 12px;
}

#cta-highlights p {
  margin-bottom: 20px;
  color: var(--text);
}

#cta-highlights .btn {
  margin-top: 20px;
  padding: 12px 24px;
  border-radius: var(--radius);
  border: 2px solid var(--accent);
  background: rgba(255,255,255,0.1);
  color: var(--accent);
  font-weight: 600;
  text-decoration: none;
  transition: all .3s ease;
}

#cta-highlights .btn:hover {
  background: var(--accent);
  color: #fff;
}


/* Footer */
footer {
  background: #f9f9f9;
  padding: 40px 20px;
  margin-top: 60px;
  border-top: 1px solid #eee;
  color: var(--text);
}
.footer-container {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 30px;
  max-width: 1200px;
  margin: 0 auto;
  text-align: left;
}
.footer-module h3 {
  font-family: "Libre Baskerville", 'SolaimanLipi', serif;
  color: var(--accent);
  margin-bottom: 12px;
}
.footer-module ul { list-style: none; padding: 0; }
.footer-module li { margin: 6px 0; }
.footer-module a, .promo a { color: var(--text); text-decoration: none; }
.footer-module a:hover, .promo a:hover { color: var(--accent); }
.social-icons {
  display: flex;
  gap: 10px;
  margin-top: 10px;
}
.social-icons a {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 2px solid var(--accent);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  font-weight: bold;
  transition: background .25s, color .25s;
}
.social-icons a:hover {
  background: var(--accent);
  color: #fff;
}
.footer-bottom {
  text-align: center;
  margin-top: 30px;
  padding-top: 10px;
  border-top: 1px solid #ccc;
  font-size: 0.85rem;
  color: #555;
}

#about p, #style p {
  text-align: justify;
}

@media (max-width: 768px) {
  .footer-container {
    grid-template-columns: 1fr;
    text-align: center;
  }
  .social-icons {
    justify-content: center; /* center align on small screens */
  }
}

/* ===========================
   CONTACT PAGE STYLES
   =========================== */

/* Contact Section Layout */
.contact-section {
  display: grid;
  grid-template-columns: 1fr 1fr; /* two columns on desktop */
  gap: 40px;
  align-items: start;
  position: relative;
  margin-top: 40px;
}

/* Divider between columns (desktop only) */
.contact-section::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 1px;
  background: #eee;
}
@media (max-width: 768px) {
  .contact-section {
    grid-template-columns: 1fr; /* single column on mobile */
  }
  .contact-section::before {
    display: none; /* remove divider on mobile */
  }
}

/* Contact Form Card */
.contact-form {
  background: linear-gradient(180deg, #fff, #fdf8f0); /* subtle gold tint */
  padding: 40px;
  border-radius: var(--radius);
  box-shadow: 0 8px 24px rgba(0,0,0,.08), 0 2px 8px rgba(191,161,74,.15);
  max-width: 700px;
  margin: 0 auto;
  transition: transform .3s ease, box-shadow .3s ease;
}
.contact-form:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 28px rgba(0,0,0,.12), 0 4px 12px rgba(191,161,74,.25);
}
.contact-form h3 {
  font-family: "Source Sans Pro", 'SolaimanLipi', sans-serif;
  color: var(--accent);
  margin-bottom: 24px;
  text-align: center;
  display: inline-block;
  padding-bottom: 6px;
}

/* Inputs & Textarea */
.form-row input,
.form-row textarea {
  font-family: "Source Sans Pro", 'SolaimanLipi', sans-serif;
  width: 100%;
  padding: 14px;
  border: 1px solid #ddd;
  border-radius: var(--radius);
  font-size: 1rem;
  transition: border-color .3s ease, box-shadow .3s ease, transform .2s ease;
}
.form-row input:focus,
.form-row textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 4px rgba(191,161,74,0.25);
  outline: none;
  transform: scale(1.01);
}

/* Buttons */
.form-row button.btn {
  width: 100%;
  padding: 14px;
  font-size: 1.1rem;
  background: linear-gradient(90deg, #bfa14a, #d4b85c);
  color: #fff;
  border: none;
  border-radius: var(--radius);
  box-shadow: 0 6px 16px rgba(191,161,74,.25);
  transition: transform .2s ease, box-shadow .2s ease;
}
.form-row button.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(191,161,74,.35);
}

/* Captcha Row */
.captcha-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.captcha-row img {
  border: 1px solid #ddd;
  border-radius: 6px;
  height: 44px;
  box-shadow: 0 2px 6px rgba(0,0,0,.08);
}
.refresh-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border: 2px solid var(--accent);
  background: #fff;
  color: var(--accent);
  border-radius: 50%;
  cursor: pointer;
  transition: background .25s ease, color .25s ease, transform .3s ease;
}
.refresh-btn:hover {
  background: var(--accent);
  color: #fff;
  transform: rotate(90deg);
}
.refresh-btn .icon-spin {
  width: 18px;
  height: 18px;
  transition: transform .6s ease;
}
.refresh-btn:active .icon-spin {
  transform: rotate(360deg);
}

/* Feedback Messages */
.feedback,
.captcha-feedback {
  min-height: 24px;
  font-size: 0.9rem;
  margin-top: 6px;
  color: #666;
  transition: color .3s ease, opacity .3s ease;
}
.feedback.error,
.captcha-feedback.error { color: #d2302c; opacity: 0.9; }
.feedback.success,
.captcha-feedback.success { color: #22a06b; opacity: 0.9; }

/* Error/Success Input Borders */
input.error,
textarea.error {
  border-color: #d2302c !important;
  box-shadow: 0 0 0 3px rgba(210,48,44,0.12) !important;
  animation: shake .3s ease;
}
input.success,
textarea.success {
  border-color: #22a06b !important;
  box-shadow: 0 0 0 3px rgba(34,160,107,0.12) !important;
}
@keyframes shake {
  0%,100% { transform: translateX(0); }
  25% { transform: translateX(-4px); }
  75% { transform: translateX(4px); }
}

/* Submission Message */
#formMsg {
  min-height: 26px;
  text-align: center;
  font-size: 1rem;
  margin-top: 10px;
  color: #555;
  transition: opacity .3s ease;
}
#formMsg.error { color: #d2302c; }
#formMsg.success { color: #22a06b; }
#formMsg.sending {
  color: var(--accent);
  animation: pulse 1s infinite;
}
@keyframes pulse {
  0% { opacity:.4; }
  50% { opacity:1; }
  100% { opacity:.4; }
}

/* Contact Details Card */
.contact-details {
  background: #fff;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 24px;
  transition: transform .3s ease, box-shadow .3s ease;
}
.contact-details:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 20px rgba(0,0,0,.12), 0 4px 12px rgba(191,161,74,.25);
}
.contact-details p {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 12px 0;
  font-size: 1rem;
  color: var(--text);
}
.contact-details .icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  fill: var(--accent);
  color: var(--accent);
}

/* Map Container Card */
.map-container {
  background: #fff;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.map-container iframe {
  border: none;
  width: 100%;
  height: 600px;
  min-height: 400px;
  display: block;
}

#cnct {
  color: #dea60c;
}

/* STORY_VIEW*/

/* Book detail section */
.book-detail {
  max-width: 800px;
  margin: 100px auto 40px; /* offset for fixed header */
  text-align: center;
}
.book-detail .cover {
  max-width: 280px;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  margin-bottom: 20px;
}
.book-detail h2 {
  font-family: "Libre Baskerville", 'SolaimanLipi', serif;
  color: var(--accent);
  margin-bottom: 12px;
}
.book-detail p {
  font-size: 1.05rem;
  line-height: 1.8;
  color: var(--text);
}

/* Reader section */
.reader {
  max-width: 900px;
  margin: 60px auto;
  padding: 30px;
  background: #fff;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.reader p {
  margin-bottom: 1.2em;
  text-align: justify;
  font-size: 1.1rem;
  line-height: 1.9;
}

.visible {
  opacity: 1; 
  transform: translateY(0);
}

.works a {
  color: var(--primary);
  text-decoration: none;
  font-weight: 600;
  position: relative;
  transition: color .25s ease;
}
.works a::after {
  content: "";
  position: absolute;
  left: 0; bottom: -6px;
  width: 0; height: 2px;
  background: var(--accent);
  transition: width .25s ease;
}
.works a:hover { color: var(--accent); }
.works a:hover::after { width: 100%; }

/* Responsive fixes for hero + works */
@media (max-width: 768px) {
  .hero h2 {
    margin-top: 290px;   /* reduce offset */
    font-size: 1.5rem;     /* smaller heading */
  }
  .hero p {
    font-size: 0.8rem;
    max-width: 90%;
  }
  section {
    padding: 40px 16px;  /* tighter spacing */
  }
  .works {
    display: flex;       /* flex layout for mobile */
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
  }
  .work {
    width: 320px;        /* fixed card size */
    flex: 0 0 auto;
  }
  .work img {
    width: 100%;
    height: auto;
  }
}

#cta-highlights {
  text-align: center;
  background: #f9f9f9;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  margin: 60px auto;
  max-width: 900px;
}
#cta-highlights h2 {
  color: var(--accent);
  margin-bottom: 12px;
}
#cta-highlights p {
  margin-bottom: 20px;
  color: var(--text);
}

.clear-marker-btn {
  position: fixed;
  right:10px;
  top: 45%;
  margin: 20px 0;
  padding: 8px 16px;
  background-color: #000;
  color: #fff;
  border: none;
  width: 100px;
  height: 100px;
  border-radius: 50%;
  cursor: pointer;
  opacity: 0.6;
  box-shadow: 0px 0px 5px 5px rgb(66, 66, 65);
}
.clear-marker-btn:hover {
  background-color: #600;
  opacity: 0.9;
}

.resume-overlay {
  position: fixed;
  top: 100px;
  left: 50%;
  transform: translateX(-50%);
  background-color: rgb(0, 0, 0);
  padding: 8px 16px;
  border-radius: 5px;
  box-shadow: 0px 0px 0px 10px #b3b691;
  z-index: 9999;
  opacity: 0;
  transition: opacity 0.8s ease-in-out;
  font-size: 1.5rem;
  color: #fff;
  text-align: center;
}
.resume-overlay.show {
  opacity: 1;
}
.resume-overlay.hide {
  opacity: 0;
}