/* =========================================================
Brochure download modal (資料ダウンロード), Inquiry modal お問い合わせはこちら
Used with js/modal.js
========================================================= */

.u-mt-30 {
  margin-top: 30px;
}

body.bd-modal-open {
  overflow: hidden;
}

.bd-modal {
  display: none;
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 10000;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.bd-modal.is-open {
  display: block;
}

.bd-modal__overlay {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  background: rgba(0, 0, 0, 0.65);
}

.bd-modal__dialog {
  position: relative;
  width: 1000px;
  max-width: calc(100% - 20px);
  margin: 40px auto;
  padding: 50px 30px;
  box-sizing: border-box;
  background: #fff;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
  text-align: left;
  animation: bdModalIn 0.25s ease-out;
}

.bd-modal__dialog .logo a {
  margin: 0 auto 30px auto;
  display: block;
  float: none;
}

@keyframes bdModalIn {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.bd-modal__close {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 40px;
  height: 40px;
  padding: 0;
  border: 0;
  background: #1c3455;
  color: #fff;
  font-size: 30px;
  font-family: math;
  line-height: 30px;
  text-align: center;
  cursor: pointer;
  z-index: 2;
}

.bd-modal__close:hover {
  background: #fa7d05;
}

/* --- steps --- */
.bd-step {
  display: none;
}

.bd-step.is-active {
  display: block;
}

/* --- step bar (shared by brochure & inquiry modals) ---
   Same look as #crumbs-brochure in crumbs.css, but as a class
   so it can be used in more than one modal on the page. */
.bd-crumbs {
  display: block;
  width: 100%;
  margin: 0;
  text-align: left;
}

/* .school-details is fixed to 640px in styles.css -> full width in modal */
.bd-modal .school-details {
  width: auto;
}

.bd-crumbs ul {
  display: flex;
  width: 100%;
  margin: 0 0 30px 0;
  padding: 0;
  list-style: none;
}

/* each step takes an equal share of the full width */
.bd-crumbs ul li {
  display: block;
  flex: 1 1 0;
  min-width: 0;
}

.bd-crumbs ul li a {
  display: block;
  position: relative;
  box-sizing: border-box;
  height: 80px;
  margin: 0 10px 0 0;
  padding: 0 20px 0 60px;
  /* center text vertically & horizontally */
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  line-height: 1.3;
  white-space: nowrap;
  background: #fa7d05;
  color: #fff;
  font-size: 18px;
  text-align: center;
  text-decoration: none;
}

.bd-crumbs ul li a:after {
  content: "";
  position: absolute;
  right: -40px;
  top: 0;
  z-index: 1;
  border-top: 40px solid transparent;
  border-bottom: 40px solid transparent;
  border-left: 40px solid #fa7d05;
}

.bd-crumbs ul li a:before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  border-top: 40px solid transparent;
  border-bottom: 40px solid transparent;
  border-left: 40px solid #fff;
}

.bd-crumbs ul li:first-child a:before,
.bd-crumbs ul li:last-child a:after {
  display: none;
}

.bd-crumbs ul li:first-child a {
  padding-left: 20px;
}

.bd-crumbs ul li:last-child a {
  margin-right: 0;
}

.bd-crumbs ul li a:hover,
.bd-crumbs ul li a.pageactive {
  background: #ff3e00;
}

.bd-crumbs ul li a:hover:after,
.bd-crumbs ul li a.pageactive:after {
  border-left-color: #ff3e00;
}

.bd-crumbs ul li a.header {
  background: #1a3050;
}

.bd-crumbs ul li a.header:after {
  border-left-color: #1a3050;
}

.bd-crumbs ul li a.header span {
  color: #fff;
  font-size: 12px;
}

.bd-modal .bd-clearfix:after {
  content: "";
  display: table;
  clear: both;
}

/* form rows inside modal */
.bd-modal .dc_form_contact_light {
  overflow: hidden;
}

.bd-modal .block.input {
  width: 560px;
}

/* --- step 2: confirm table --- */
.bd-confirm {
  width: 100%;
  margin: 10px 0 30px;
  border-collapse: collapse;
  font-size: 14px;
}

.bd-confirm th,
.bd-confirm td {
  padding: 14px 16px;
  border-bottom: 1px solid #ddd;
  vertical-align: top;
  color: #000;
}

.bd-confirm th {
  width: 300px;
  background: #f5f5f5;
  font-weight: bold;
  text-align: right;
}

.bd-confirm td {
  white-space: pre-wrap;
  word-break: break-word;
}

.bd-actions {
  text-align: center;
  margin-bottom: 20px;
}

.bd-actions .form-btn {
  margin: 0 10px !important;
}

.bd-btn-back {
  background: #888 !important;
}

.bd-error {
  display: none;
  margin: 0 0 20px;
  padding: 10px 16px;
  background: #fdecea;
  border: 1px solid #e00;
  color: #c00;
  font-size: 14px;
  white-space: pre-line; /* one validation message per line */
}

.bd-error.is-visible {
  display: block;
}

/* step 3 */
.bd-modal .brochure-details ul {
  margin-bottom: 30px;
}

/* =========================================================
   Inquiry modal (お問い合わせ)
   ========================================================= */
.bd-modal .question {
  margin: 10px 0 0;
}

.bd-complete {
  padding: 60px 20px;
  text-align: center;
}

.bd-complete h3 {
  font-size: 22px;
  font-weight: bold;
  color: #fb7804;
}

/* Modal trigger buttons (<button> instead of <a>): remove browser defaults */
.button-download-top button,
.button-mail-top button,
.button-download-bottom button,
.button-mail-bottom button {
  padding: 0;
  border: 0;
  overflow: hidden;
  font: inherit;
  cursor: pointer;
}

/* Honeypot field for bots (name="bd_hp_check"): kept off-screen, not display:none */
.bd-hp {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}
