/*
Theme Name: CSM Theme
Theme URI: https://cyberschoolmanager.com
Author: Cybrain Software Solutions
Author URI: https://cybrain.in
Description: Custom WordPress theme for Cyber School Manager website
Version: 1.0
Text Domain: csm-theme
*/

/*
  NOTE: Do NOT add CSS here.
  All CSS goes in assets/css/main.css
  This file is only required by WordPress to recognize the theme.
*/

.page-content-body {
    padding: 70px 0 40px;
}

/* === CSM POPUP OVERLAY === */
.csm-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.65);
  z-index: 99999;
  align-items: center;
  justify-content: center;
}
.csm-overlay.csm-visible {
  display: flex;
}

/* === POPUP BOX === */
.csm-popup {
  display: flex;
  width: 920px;
  max-width: 95vw;
  max-height: 90vh;
  border-radius: 12px;
  overflow: hidden;
  position: relative;
  background: #fff;
}

/* === LEFT PANEL === */
.csm-left {
  width: 300px;
  min-width: 260px;
  background: linear-gradient(160deg, #03355d 0%, #1d97dd 100%);
  color: #fff;
  padding: 40px 28px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.csm-left h2 {
  font-size: 22px;
  font-weight: 700;
  line-height: 1.4;
  margin: 0 0 14px;
  color: #fff !important;
}
.csm-left p {
  font-size: 13.5px;
  line-height: 1.75;
  opacity: 0.92;
  margin: 0 0 22px;
  color: #fff !important;
}
.csm-left ul {
  list-style: none;
  padding: 0;
  margin: 0;
}
.csm-left ul li {
  font-size: 13.5px;
  font-weight: 600;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 10px;
  color: #fff;
}
.csm-tick {
  background: rgba(255,255,255,0.25);
  border-radius: 50%;
  width: 24px;
  height: 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  flex-shrink: 0;
  color: #fff;
}

/* === RIGHT PANEL === */
.csm-right {
  flex: 1;
  padding: 28px 28px 24px;
  overflow-y: auto;
  background: #fff;
}

/* === TABS === */
.csm-tabs {
  display: flex;
  border-bottom: 2px solid #e5e7eb;
  margin-bottom: 20px;
}
.csm-tab {
  background: none;
  border: none;
  border-bottom: 3px solid transparent;
  margin-bottom: -2px;
  padding: 10px 18px;
  font-size: 14px;
  font-weight: 600;
  color: #6b7280;
  cursor: pointer;
  transition: all 0.2s ease;
}
.csm-tab.active {
  color: #1a6fc4;
  border-bottom-color: #1a6fc4;
}
.csm-tab:hover {
  color: #1a6fc4;
}

/* === FORM SHOW/HIDE === */
.csm-form-wrap {
  display: none !important;
}
.csm-form-wrap.active {
  display: block !important;
}

/* =====================================================
   CF7 GRID LAYOUT FIX
   DevTools confirmed: CF7 renders <p> tags as direct
   children inside csm-row / csm-row-3 divs.
   We target <p> as grid children, NOT span or wrap.
   ===================================================== */

/* Strip ALL default p margins inside the form */
.csm-right .wpcf7-form p {
  margin: 0 !important;
  padding: 0 !important;
}

/* === FULL WIDTH FIELD === */
.csm-right .wpcf7-form p.csm-full,
.csm-right .wpcf7-form div.csm-full {
  display: block !important;
  width: 100% !important;
  margin-bottom: 10px !important;
}
.csm-right .wpcf7-form .csm-full .wpcf7-form-control-wrap {
  display: block !important;
  width: 100% !important;
}
.csm-right .wpcf7-form .csm-full input[type="text"],
.csm-right .wpcf7-form .csm-full input[type="email"],
.csm-right .wpcf7-form .csm-full input[type="tel"],
.csm-right .wpcf7-form .csm-full select,
.csm-right .wpcf7-form .csm-full textarea,
.csm-right .wpcf7-form .csm-full input[type="submit"] {
/*   width: 100% !important; */
  box-sizing: border-box !important;
}

/* === 2 COLUMN ROW — <p> are the grid children === */
.csm-right .wpcf7-form .csm-row {
  display: grid !important;
  grid-template-columns: 1fr 1fr !important;
  gap: 10px !important;
  margin-bottom: 10px !important;
  align-items: start;
}
/* <p> inside csm-row = direct grid child */
.csm-right .wpcf7-form .csm-row > p {
  display: block !important;
  width: 100% !important;
  min-width: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
}
/* span wrapper inside p */
.csm-right .wpcf7-form .csm-row > p > .wpcf7-form-control-wrap {
  display: block !important;
  width: 100% !important;
}

/* === 3 COLUMN ROW — <p> are the grid children === */
.csm-right .wpcf7-form .csm-row-3 {
  display: grid !important;
  grid-template-columns: 1fr 1fr 1fr !important;
  gap: 10px !important;
  margin-bottom: 10px !important;
  align-items: start;
}
.csm-right .wpcf7-form .csm-row-3 > p {
  display: block !important;
  width: 100% !important;
  min-width: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
}
.csm-right .wpcf7-form .csm-row-3 > p > .wpcf7-form-control-wrap {
  display: block !important;
  width: 100% !important;
}

/* === ALL INPUTS / SELECTS / TEXTAREA === */
.csm-right .wpcf7-form input[type="text"],
.csm-right .wpcf7-form input[type="email"],
.csm-right .wpcf7-form input[type="tel"],
.csm-right .wpcf7-form select,
.csm-right .wpcf7-form textarea {
  display: block !important;
  width: 100% !important;
  padding: 9px 12px !important;
  border: 1px solid #eaeaea !important;
  border-radius: 6px !important;
  font-size: 12px !important;
  box-sizing: border-box !important;
  background: #f9fafb !important;
  margin: 7px 0 !important;
  transition: border-color 0.2s;
/*   padding-left: 40px !important; */
}
input#cu-mobile-2:focus {
    padding-left: 40px !important;
}
/* .csm-right .wpcf7-form input[type="text"]:focus,
.csm-right .wpcf7-form input[type="email"]:focus,
.csm-right .wpcf7-form input[type="tel"]:focus,
.csm-right .wpcf7-form select:focus,
.csm-right .wpcf7-form textarea:focus {
  border-color: #1a6fc4 !important;
  outline: none !important;
  background: #fff !important;
} */
.csm-right .wpcf7-form input[type="text"]:focus,
.csm-right .wpcf7-form input[type="email"]:focus,
.csm-right .wpcf7-form input[type="tel"]:focus,
.csm-right .wpcf7-form select:focus,
.csm-right .wpcf7-form textarea:focus,
.csm-overlay .cu-input:focus,
.csm-overlay .cu-select:focus,
.csm-overlay .cu-textarea:focus {
  border: 2px solid #1a6fc4 !important;
  border-top: 2px solid #1a6fc4 !important;
  border-right: 2px solid #1a6fc4 !important;
  border-bottom: 2px solid #1a6fc4 !important;
  border-left: 2px solid #1a6fc4 !important;
  outline: none !important;
  background: #fff !important;
  box-shadow: none !important;
}

.csm-right .wpcf7-form textarea {
  min-height: 50px;
  resize: vertical;
}
.csm-right .wpcf7-form select {
  appearance: auto;
  -webkit-appearance: auto;
  cursor: pointer;
}

/* === SUBMIT BUTTON === */
.csm-right .wpcf7-form input[type="submit"] {
  display: block !important;
/*   width: 100%; */
  margin: 0px auto;
  background: #1a6fc4 !important;
  color: #fff !important;
  border: none !important;
  padding: 11px 28px !important;
  border-radius: 6px !important;
  font-size: 14px !important;
  font-weight: 700 !important;
  cursor: pointer !important;
  margin-top: 10px !important;
  transition: background 0.2s;
  box-sizing: border-box !important;
}
.csm-right .wpcf7-form input[type="submit"]:hover {
  background: #155a9e !important;
}

/* === CLOSE BUTTON === */
.csm-close {
  position: absolute;
  top: 10px;
  right: 14px;
  background: none;
  border: none;
  font-size: 28px;
  color: #9ca3af;
  cursor: pointer;
  line-height: 1;
  z-index: 100;
}
.csm-close:hover {
  color: #111;
}

/* === MOBILE === */
@media (max-width: 680px) {
  .csm-popup {
    flex-direction: column;
    max-height: 95vh;
    width: 100%;
  }
  .csm-left {
    width: 100%;
    min-width: unset;
    padding: 22px 18px;
  }
  .csm-left ul {
    display: none;
  }
  .csm-right {
    padding: 18px 14px;
  }
  .csm-right .wpcf7-form .csm-row,
  .csm-right .wpcf7-form .csm-row-3 {
    grid-template-columns: 1fr !important;
  }
}
.upload-box {
    margin: 18px 0;
}

.hidden-upload {
    display: none;
}

.upload-btn {
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;
    width: 100%;
    min-height: 35px;
    border: 1px dashed #0A6EBD;
    border-radius: 10px;
    background: #f7fbff;
    cursor: pointer;
    transition: .3s;
    text-align: center;
}

.upload-btn:hover {
    background: #eef7ff;
    border-color: #085a9b;
}

.upload-btn span {
    font-size: 14px;
    font-weight: 600;
    color: #0A6EBD;
}

.upload-btn small {
    margin-top: 6px;
    color: #777;
    font-size: 13px;
}
.csm-submit-wrap {
    text-align: center;
}

.csm-submit-wrap input[type="submit"] {
  width: auto;
  min-width: 200px;
  padding: 12px 36px;
}

.csm-right label.cu-label {
/*     display: none; */
}
.cu-form-panel .wpcf7 {
    padding: 30px;
}
 
@media (min-width: 320px) and (max-width: 768px) {
	.cu-hero-title {
   font-size: 30px;
	}
	.why-title {
    font-size: 26px;
	}
	.section h2 {
		font-size: 30px;
	}
}

@media (min-width: 320px) and (max-width: 1024px) {
	.nav-link::after {
    left: 6px;
    right: 230px;
    bottom: 4px;
    height: 1.5px;
	}
}
.wpcf7 form.sent .wpcf7-response-output
 {
    border-color: #46b450 !important;
    background: #46b450 !important;
    color: #ffffff !important;
}


.cu-field {
  position: relative;
}

.cu-field .cu-label,
.csm-right .cu-field .cu-label {
  display: flex !important;
  position: absolute;
  left: 15px;
  top: 13px;
  margin: 0;
  font-size: 13px;
  font-weight: 600;
  color: #aebacb;
  letter-spacing: 0;
  text-transform: none;
  background: transparent;
  padding: 0 4px;
  pointer-events: none;
  z-index: 2;
  transition: all 0.2s ease;
}

.cu-field .cu-input,
.cu-field .cu-select,
.cu-field .cu-textarea {
/*   padding-top: 17px;
  padding-bottom: 9px; */
}

.cu-field:has(.cu-input:focus) .cu-label,
.cu-field:has(.cu-input:not(:placeholder-shown)) .cu-label,
.cu-field:has(.cu-textarea:focus) .cu-label,
.cu-field:has(.cu-textarea:not(:placeholder-shown)) .cu-label,
.cu-field:has(.cu-select:focus) .cu-label {
  top: -9px;
  left: 10px;
  font-size: 11px;
  font-weight: 700;
  color: var(--blue);
  background: #fff;
  border-radius: 4px;
}

.cu-field:has(.cu-select) .cu-label {
/*   top: -9px;
  left: 10px;
  font-size: 11px;
  font-weight: 700;
  color: var(--blue);
  background: #fff; */
}
.cu-field:has(input.cu-input:focus) .cu-label,
.cu-field:has(input.cu-input:not(:placeholder-shown)) .cu-label,
.cu-field:has(.cu-textarea:focus) .cu-label,
.cu-field:has(.cu-textarea:not(:placeholder-shown)) .cu-label,
.cu-field:has(.cu-select:focus) .cu-label,
.cu-field:has(input.cu-input[readonly]) .cu-label {
  top: -9px;
  left: 10px;
  font-size: 11px;
  font-weight: 700;
  color: var(--blue);
  background: #fff;
  border-radius: 4px;
}

/* === SELECT FIELDS — placeholder-style === */
.cu-field select.cu-select,
.cu-field select.cu-input {
  color: transparent;
}

/* Filled or focus*/
.cu-field.cu-filled select.cu-select,
.cu-field.cu-filled select.cu-input,
.cu-field:has(select.cu-select:focus) select.cu-select,
.cu-field:has(select.cu-input:focus) select.cu-input {
  color: #1f2937 !important;
}

/* Label float up — filled or focused state */
.cu-field.cu-filled .cu-label,
.cu-field:has(select.cu-select:focus) .cu-label,
.cu-field:has(select.cu-input:focus) .cu-label {
  top: -9px;
  left: 10px;
  font-size: 11px;
  font-weight: 700;
  color: var(--blue);
  background: #fff;
  border-radius: 4px;
}

/* ===== FLOATING LABEL (works even with CF7's wpcf7-form-control-wrap span) ===== */

.cu-field {
  position: relative;
}

.cu-field .cu-label {
  display: flex !important;
  align-items: center;
  position: absolute;
  left: 15px;
  top: 13px;
  margin: 0;
  font-size: 13px;
  font-weight: 600;
  color: #aebacb;
  text-transform: none;
  letter-spacing: 0;
  background: transparent;
  padding: 0 4px;
  pointer-events: none;
  z-index: 2;
  transition: all 0.2s ease;
}

.cu-label-ico { display: none; }

.cu-field .cu-input,
.cu-field .cu-select,
.cu-field .cu-textarea {
/*   padding-top: 17px;
  padding-bottom: 9px; */
}

.cu-field:has(.cu-input:focus) .cu-label,
.cu-field:has(.cu-input:not(:placeholder-shown)) .cu-label,
.cu-field:has(.cu-textarea:focus) .cu-label,
.cu-field:has(.cu-textarea:not(:placeholder-shown)) .cu-label,
.cu-field:has(.cu-select:focus) .cu-label,
.cu-field:has(.cu-input[readonly]) .cu-label {
  top: -9px;
  left: 10px;
  font-size: 11px;
  font-weight: 700;
  color: var(--blue);
  background: #fff;
  border-radius: 4px;
}

/* ===== FLOATING LABEL (works even with CF7's wpcf7-form-control-wrap span) ===== */
.cu-field {
  position: relative;
}
.cu-field .cu-label {
  display: flex !important;
  align-items: center;
  position: absolute;
  left: 15px;
  top: 13px;
  margin: 0;
  font-size: 13px;
  font-weight: 600;
  color: #aebacb;
  text-transform: none;
  letter-spacing: 0;
  background: transparent;
  padding: 0 4px;
  pointer-events: none;
  z-index: 2;
  transition: all 0.2s ease;
}
.cu-label-ico { display: none; }
.cu-field .cu-input,
.cu-field .cu-select,
.cu-field .cu-textarea {
/*   padding-top: 17px;
  padding-bottom: 9px; */
}

/* ✅ FIXED: input. prefix add kiya taaki select isme match na ho */
.cu-field:has(input.cu-input:focus) .cu-label,
.cu-field:has(input.cu-input:not(:placeholder-shown)) .cu-label,
.cu-field:has(.cu-textarea:focus) .cu-label,
.cu-field:has(.cu-textarea:not(:placeholder-shown)) .cu-label,
.cu-field:has(input.cu-input[readonly]) .cu-label,
.cu-field.cu-filled .cu-label,
.cu-field:has(select:focus) .cu-label {
  top: -9px;
  left: 10px;
  font-size: 11px;
  font-weight: 700;
  color: var(--blue);
  background: #fff;
  border-radius: 4px;
}

/* ✅ NEW: Select fields ka text hide/show karo (placeholder look ke liye) */
.cu-field select.cu-select,
.cu-field select.cu-input {
  color: transparent;
}
.cu-field.cu-filled select.cu-select,
.cu-field.cu-filled select.cu-input,
.cu-field:has(select:focus) select {
  color: #1f2937 !important;
}

/* ===== REQUIRED ASTERISK — if focus invalid ===== */
.cu-req {
  color: var(--danger, #e0533d);
  margin-left: 3px;
  opacity: 0;
  transform: translateY(-2px);
  display: inline-block;
  transition: opacity 0.18s ease, transform 0.18s ease;
}
.cu-field:has(.cu-input:focus) .cu-req,
.cu-field:has(.cu-textarea:focus) .cu-req,
.cu-field:has(.cu-select:focus) .cu-req,
.cu-field:has(.wpcf7-not-valid) .cu-req {
  opacity: 1;
  transform: translateY(0);
}
.cu-field:has(.cu-textarea) .cu-label {
  max-width: calc(100% - 20px);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.cu-field .cu-textarea {
  padding-top: 20px;
}
.upload-hint {
  font-size: 12px;
  font-weight: 500;
  color: #8a97a8;
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  gap: 4px;
}
.upload-box .upload-btn-ui {
  position: relative;
  z-index: 1;
}
.upload-box .wpcf7-not-valid-tip {
  position: relative !important;
  z-index: 2;
  width: 100%;
  order: 3; 
}
.file-error-tip.wpcf7-not-valid-tip {
  display: block !important;
  position: static !important;
  margin: -5px 0 10px;
  font-size: 12px;
  color: #dc2626;
}
  #scrollTopBtn {
    display: none;
    position: fixed;
	left: 15px;
    bottom: 30px;
    right: 30px;
    z-index: 99;
    background-color: #007bff;
    color: white;
    border: none;
    outline: none;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    font-size: 20px;
    cursor: pointer;
    box-shadow: 0 2px 6px rgba(0,0,0,0.3);
    transition: background-color 0.3s;
  }
  #scrollTopBtn:hover {
    background-color: #0056b3;
  }
/* === +91 PREFIX — Mobile Field === */
.mobile-field {
  position: relative;
}
.mobile-field .wpcf7-form-control-wrap {
  position: relative;
  display: block;
  line-height: 0;
}
.mobile-field .wpcf7-form-control-wrap::before {
    content: "+91";
    position: absolute;
    left: 0px;
    top: 0;
    bottom: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 600;
    background: #1c94d9;
    color: #ffffff;
    padding: 0 7px 0 5px;
    border-radius: 5px 0 0 5px;
    z-index: 3;
    pointer-events: none;
    line-height: 1;
    box-sizing: border-box;
}
.mobile-field .cu-input,
.mobile-field input#cu-mobile[type="tel"] {
  padding-left: 40px !important;
  position: relative;
  z-index: 1;
  box-sizing: border-box !important;
}
.cu-field.mobile-field:has(.cu-input:placeholder-shown) label.cu-label {
  left: 52px !important;
  transition: none !important;
}
.cu-field.mobile-field:has(.cu-input:not(:placeholder-shown)) label.cu-label,
.cu-field.mobile-field:has(.cu-input:focus) label.cu-label {
  left: 10px !important;
}
.mobile-field .cu-label {
  z-index: 2;
  position: absolute;
}
.mobile-field .wpcf7-not-valid-tip {
  position: absolute !important;
  left: 0;
  top: 100%;
  margin-top: 9px !important;
  display: block;
  white-space: nowrap;
  z-index: 4;
}

.mobile-field .cu-label {
  z-index: 5 !important; 
}

.cu-field.mobile-field:has(.cu-input:focus) label.cu-label,
.cu-field.mobile-field:has(.cu-input:not(:placeholder-shown)) label.cu-label {
  top: -6px !important;
  left: 35px !important;
  background: #fff !important;
  font-size: 11px !important;
  font-weight: 700 !important;
  color: var(--blue) !important;
  border-radius: 4px !important;
}

/* City field — disabled until State select noty selected  */
#cu-city:disabled {
  background: #f1f3f5 !important;
  cursor: not-allowed !important;
  opacity: 0.6;
}