/* =========================================================
   Sankalp – light layout helpers (do not override legacy header)
   ========================================================= */

html, body {
  max-width: 100%;
  overflow-x: hidden;
}

/* Restore Bootstrap container widths if anything fluid broke them */
.container {
  margin-right: auto;
  margin-left: auto;
  padding-left: 15px;
  padding-right: 15px;
}

@media (min-width: 768px) {
  .container { width: 750px; }
}
@media (min-width: 992px) {
  .container { width: 970px; }
}
@media (min-width: 1200px) {
  .container { width: 1170px; }
}

.as-mainwrapper {
  width: 100% !important;
  max-width: 100% !important;
  float: none !important;
  overflow: hidden;
}

/* Keep absolute header overlay working like legacy (desktop) */
@media (min-width: 992px) {
  #as-header.as-absolute {
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    z-index: 99;
  }

  /* Desktop nav uses theme floats — do not force flex/table here */
  .as-menuwrapper {
    display: none;
  }
}

/* Readable body copy */
.as-title-text,
.as-title-text p,
.as-team-detail,
.as-team-detail p,
.as-main-content p {
  color: #444;
  line-height: 1.7;
  font-size: 15px;
}

.as-fancytitle h2 {
  line-height: 1.3;
}

/* Match legacy float text offset for 255px director photo */
.as-main-content .as-team-thumb ~ .as-team-detail {
  padding-left: 280px;
}

/* About director caption under photo (legacy look) */
.as-team-thumb .director-caption {
  display: block;
  width: 100%;
  float: left;
  background: #ececec;
  padding: 10px 12px;
  text-align: center;
  box-sizing: border-box;
}

.as-team-thumb .director-caption strong {
  display: block;
  color: #222;
  font-size: 15px;
}

.as-team-thumb .director-caption span {
  display: block;
  color: #777;
  font-size: 13px;
  font-weight: 400;
  margin-top: 2px;
}

.as-team-detail p {
  margin-bottom: 14px;
  text-align: justify;
}

/* Generic content images */
.as-main-content img {
  max-width: 100%;
  height: auto;
}

.center-photo {
  max-width: 100%;
  height: auto !important;
}

/* Forms full width in content */
.as-form input[type="text"],
.as-form input[type="email"],
.as-form textarea,
.myform input,
.myform textarea {
  max-width: 100%;
}

/* Footer CTA bar */
.as-action-style h2 {
  font-size: 22px;
  line-height: 1.4;
  margin: 0;
}

.as-action-style h2 a {
  color: inherit;
  text-decoration: underline;
}

/* Event list: HTML descriptions should read cleanly */
.event-list-wrap .event-desc {
  color: #444;
  font-size: 14px;
  line-height: 1.6;
}

.event-list-wrap .event-desc p {
  margin: 0 0 10px;
}

.event-list-wrap .event-item .as-team-thumb img,
.event-list-wrap .event-item .as-team-thumb video {
  width: 100%;
  max-width: 267px;
  height: auto;
  display: block;
}

/* Old age home member grid (legacy table look) */
.old-age-members-table > tbody > tr > th,
.old-age-members-table th {
  font-weight: normal;
  text-align: center;
  vertical-align: top;
  border: 1px solid #ddd;
  padding: 10px 6px;
}

.old-age-members-table img {
  display: block;
  margin: 0 auto 6px;
}

@media (max-width: 767px) {
  .old-age-members-table,
  .old-age-members-table tbody,
  .old-age-members-table tr,
  .old-age-members-table th {
    display: block;
    width: 100% !important;
  }

  .old-age-members-table th {
    margin-bottom: 12px;
  }
}

/* Hide leftover theme flame widget everywhere */
.ec-handle,
.ec-colorswitcher {
  display: none !important;
}

/* Reviews page */
.review-list {
  display: grid;
  gap: 14px;
  margin: 18px 0 28px;
}

.review-card {
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: 18px;
  align-items: start;
  border: 1px solid #e2e6ea;
  background: #fafbfc;
  padding: 14px;
}

.review-card__media {
  width: 160px;
  height: 160px;
  overflow: hidden;
  background: #e9eef2;
}

.review-card__media img,
.review-card__media video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.review-card__media.is-placeholder img {
  object-fit: contain;
  padding: 12px;
  background: #eef2f5;
}

.review-card__body {
  min-width: 0;
}

.review-card__body time {
  display: inline-block;
  font-size: 13px;
  color: #666;
  margin-bottom: 8px;
  border-bottom: 1px solid #b0b0b0;
  padding-bottom: 2px;
}

.review-card__body p {
  margin: 0 0 12px;
  color: #444;
  line-height: 1.55;
  font-size: 14px;
  white-space: pre-wrap;
}

.review-card__by {
  display: block;
  text-align: right;
  font-size: 13px;
  color: #555;
}

.review-empty {
  padding: 20px;
  border: 1px dashed #ccd3d9;
  color: #666;
}

.review-form-panel .as-form form p {
  margin: 0 0 12px;
}

.review-submit-form input[type="text"],
.review-submit-form input[type="email"],
.review-submit-form textarea {
  width: 100% !important;
  max-width: 100%;
  box-sizing: border-box;
}

.review-file-field label {
  display: block;
  font-size: 13px;
  color: #555;
  margin-bottom: 6px;
}

.review-file-field label span {
  color: #888;
  font-weight: normal;
}

.review-submit-form .hp-field {
  position: absolute;
  left: -10000px;
  height: 0;
  overflow: hidden;
}

@media (max-width: 767px) {
  .review-card {
    grid-template-columns: 1fr;
  }

  .review-card__media {
    width: 100%;
    height: 200px;
  }
}
