.mcj-section {
  --mcj-ink: #123e40;
  --mcj-body: #46615b;
  --mcj-action: #00665d;
  --mcj-paper: #fffefa;
  --mcj-line: #c5d4ca;
  --mcj-mist: #dcebe1;
  color: var(--mcj-ink);
  padding-block: clamp(58px, 6vw, 96px);
}
.mcj-section [hidden] { display: none !important }
.mcj-section :where(h2,h3,p,dl,dt,dd,fieldset,legend) { margin: 0 }
.mcj-section :where(button,input,select) { font: inherit; color: inherit }
.mcj-section :is(a,button,input,select):focus-visible,
.mcj-summary p:focus-visible { outline: 3px solid #00776b; outline-offset: 3px }
.mcj-heading { margin-block-end: clamp(22px,3vw,38px) }
.mcj-heading h2, .mcj-dialog h2 {
  font-size: clamp(32px,4vw,56px);
  letter-spacing: -.04em;
  line-height: 1.24;
  font-weight: 600;
}
.mcj-heading h2:lang(ar), .mcj-dialog h2:lang(ar) { letter-spacing: normal; line-height: 1.5 }
.mcj-heading p { margin-block-start: 8px; color: var(--mcj-body); font-size: clamp(16px,1.4vw,19px); line-height: 1.7 }
.mcj-toolbar { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px 20px }
.mcj-search {
  display: flex; align-items: center; gap: 10px;
  min-height: 48px; flex: 1 1 255px; max-width: 400px;
  padding-inline: 15px; background: var(--mcj-paper); border: 1px solid var(--mcj-line); border-radius: 10px;
}
.mcj-search:focus-within { outline: 2px solid var(--mcj-action); outline-offset: 1px }
.mcj-search .mcj-icon { width: 19px; height: 19px }
.mcj-search input { flex: 1; min-width: 0; width: 100%; height: 44px; border: none; background: transparent; outline: none !important; font-size: 15px }
.mcj-search input::placeholder { color: var(--mcj-body); opacity: 1 }
.mcj-filters { display: flex; align-items: center; flex-wrap: wrap; gap: 6px }
.mcj-filters button {
  min-height: 44px; border-radius: 50px; padding: 5px clamp(9px,1.4vw,18px);
  border: 1px solid var(--mcj-line); background: transparent; color: var(--mcj-ink); font-size: 14px; line-height: 1.4;
}
.mcj-filters button[aria-pressed="true"] { background: var(--mcj-ink); color: #fff; border-color: var(--mcj-ink) }
.mcj-count { font-size: 13px; line-height: 1.6; color: var(--mcj-body); margin: 12px 0 }
.mcj-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: clamp(12px,1.5vw,20px) }
.mcj-card {
  position: relative; display: flex; flex-direction: column; align-items: flex-start;
  padding: clamp(19px,2.1vw,30px); border: 1px solid var(--mcj-line);
  border-radius: 16px; background: var(--mcj-paper); min-width: 0;
}
.mcj-card-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; width: 100% }
.mcj-tile, .mcj-summary-icon {
  display: inline-grid; place-items: center; width: 46px; height: 46px; border-radius: 14px;
  background: var(--mcj-mist); color: var(--mcj-action);
}
.mcj-icon { display: block; flex: none }
.mcj-group-name { color: var(--mcj-body); font-size: 13px }
.mcj-card h3 { margin: 18px 0 5px; color: var(--mcj-ink); font-size: clamp(21px,2vw,27px); font-weight: 600; line-height: 1.45 }
.mcj-card p, .mcj-dialog p { color: var(--mcj-body); font-size: 15px; line-height: 1.7; margin-bottom: 12px }
.mcj-detail-trigger, .mcj-primary {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 44px; font-weight: 600; cursor: pointer;
}
.mcj-detail-trigger { margin-top: auto; background: transparent; border: 0; color: var(--mcj-action); padding: 5px 0; font-size: 14px }
.mcj-detail-trigger:hover { text-decoration: underline; text-underline-offset: 4px }
.mcj-primary { padding: 10px 18px; background: var(--mcj-action); border: 1px solid var(--mcj-action); color: white; border-radius: 8px; font-size: 15px }
.mcj-primary:hover { background: var(--mcj-ink) }
.mcj-icon-arrow { width: 18px; height: 18px }
[dir="rtl"] .mcj-icon-arrow { transform: scaleX(-1) }
.mcj-empty { padding: 30px; border: 1px dashed var(--mcj-line); border-radius: 12px; text-align: center }
.mcj-dialog {
  color: var(--mcj-ink); background: var(--mcj-paper); border: 1px solid var(--mcj-line); border-radius: 20px;
  width: min(470px, calc(100% - 32px)); max-height: calc(100dvh - 32px); margin: auto; padding: 0; overflow: auto;
}
.mcj-dialog::backdrop { background: rgb(13 41 39 / 62%) }
.mcj-dialog-inner { padding: clamp(22px,4vw,34px) }
.mcj-close { display: grid; place-items: center; width: 44px; height: 44px; border: 1px solid var(--mcj-line); background: transparent; border-radius: 50% }
.mcj-dialog h2 { font-size: clamp(26px,4vw,34px); margin: 18px 0 6px }
.mcj-dialog h3 { font-size: 17px; margin-top: 20px }
.mcj-dialog ul { padding-inline-start: 20px; margin: 10px 0 26px; line-height: 1.9 }
.mcj-dialog li::marker { color: var(--mcj-action) }
.mcj-schedule { display: grid; grid-template-columns: minmax(0, 1.56fr) minmax(260px, 1fr); gap: clamp(16px, 2vw, 28px); align-items: stretch }
.mcj-form, .mcj-summary { border-radius: 18px; padding: clamp(20px, 3vw, 40px); border: 1px solid var(--mcj-line); min-width: 0 }
.mcj-form { display: grid; gap: 24px; background: var(--mcj-paper) }
.mcj-form fieldset { border: 0; padding: 0; min-width: 0 }
.mcj-field label, .mcj-form legend { display: block; font-size: 16px; font-weight: 650; line-height: 1.5; margin-block-end: 9px; padding: 0 }
.mcj-field select { width: 100%; min-height: 46px; padding: 7px 12px; border: 1px solid var(--mcj-line); border-radius: 8px; background: #fff }
.mcj-form [aria-invalid="true"] { border-color: #a74635 }
.mcj-form .mcj-error { color: #8c3026; font-size: 14px; line-height: 1.5; margin-block-start: 7px }
.mcj-days, .mcj-times { display: grid; grid-template-columns: repeat(7,minmax(0,1fr)); gap: 6px }
.mcj-times { grid-template-columns: repeat(4,minmax(0,1fr)) }
.mcj-days label, .mcj-times label { position: relative; min-width: 0; cursor: pointer }
.mcj-days label>span, .mcj-times label>span {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 2px; padding: 8px 2px; min-height: 44px; border: 1px solid var(--mcj-line); border-radius: 8px;
  background: transparent; color: var(--mcj-ink); line-height: 1.45; text-align: center;
}
.mcj-days small { font-size: 12px }
.mcj-days b { font-size: 14px; font-weight: 600 }
.mcj-times label>span { font-size: 14px }
.mcj-sr, .mcj-days input, .mcj-times input { position: absolute; width: 1px; height: 1px; overflow: hidden; padding: 0; margin: -1px; white-space: nowrap; clip-path: inset(50%); border: 0 }
.mcj-form input:checked + span { background: var(--mcj-mist); border: 2px solid var(--mcj-action); padding: 7px 1px; font-weight: 650 }
.mcj-form input:focus-visible + span { outline: 3px solid #00776b; outline-offset: 2px }
.mcj-form .mcj-primary { justify-self: start }
.mcj-summary { background: var(--mcj-ink); color: #fffefa; border-color: var(--mcj-ink); display: flex; flex-direction: column; align-items: start }
.mcj-summary-icon { background: #e6efa7; color: var(--mcj-ink) }
.mcj-summary h3 { font-size: clamp(24px,2.5vw,34px); line-height: 1.4; margin-block: 14px 20px; color: inherit }
.mcj-summary dl { width: 100%; margin-block-end: 24px }
.mcj-summary dl div { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding-block: 12px; border-block-start: 1px solid #547471 }
.mcj-summary dt { font-size: 14px; color: #cadbd3 }
.mcj-summary dd { text-align: end; font-weight: 550; line-height: 1.55 }
.mcj-summary .mcj-note { font-size: 14px; color: #dcebe1; line-height: 1.8; margin-block-start: auto }
#mcj-confirm:not(:empty) { color: #f5ffc1; font-size: 15px; line-height: 1.7; margin-block-start: 16px; padding-block-start: 14px; border-block-start: 1px solid #547471 }
@media (max-width: 980px) {
  .mcj-days { grid-template-columns: repeat(4,minmax(0,1fr)) }
}
@media (max-width: 780px) {
  .mcj-grid { grid-template-columns: repeat(2,minmax(0,1fr)) }
  .mcj-schedule { grid-template-columns: 1fr }
  .mcj-search { max-width: none }
  .mcj-days { grid-template-columns: repeat(7,minmax(0,1fr)) }
}
@media (max-width: 560px) {
  .mcj-toolbar { display: grid }
  .mcj-grid { grid-template-columns: 1fr }
  .mcj-card { padding: 18px 20px }
  .mcj-card h3 { margin-block-start: 12px }
  .mcj-days { grid-template-columns: repeat(4,minmax(0,1fr)) }
  .mcj-times { grid-template-columns: repeat(2,minmax(0,1fr)) }
}
@media (forced-colors: active) {
  .mcj-form input:checked + span, .mcj-filters button[aria-pressed="true"] { outline: 2px solid Highlight }
}
