/* Shared adjustments from the third review. */
.gradebook-modal .record-canvas.is-turning .record-base .record-page-content {
  visibility: visible;
}

.record-book .record-leaf {
  animation-duration: .82s;
  animation-timing-function: cubic-bezier(.41,.08,.24,.99);
}

.record-book .record-leaf-face {
  background-color: #f6edd6;
}

@media (min-width: 901px) and (min-height: 501px) {
  .record-book.is-fitted [data-single-page="false"] .record-leaf {
    top: 0;
    width: 50%;
    height: 100%;
  }

  .record-book.is-fitted [data-single-page="false"] .record-leaf-face {
    border-radius: 0;
    background-size: 200% 100%;
  }

  .record-book.is-fitted [data-single-page="false"] .record-leaf-face.left { background-position: left center; }
  .record-book.is-fitted [data-single-page="false"] .record-leaf-face.right { background-position: right center; }
  .record-book.is-fitted [data-single-page="false"] .record-leaf-face .record-page-content { top: 8.5%; }
  .record-book.is-fitted [data-single-page="false"] .record-leaf-face.left .record-page-content { left: 12.58%; }
  .record-book.is-fitted [data-single-page="false"] .record-leaf-face.right .record-page-content { left: 8.13%; }
}

#root.mm-system a.mm-faculty-visit {
  display: inline-flex;
  margin-top: 16px;
  color: var(--mm-ink, #2d2117);
}

#root.mm-system #more-moments .fp-more-gallery {
  display: block;
  border-top: 1px solid var(--mm-line);
  padding-top: clamp(20px, 2.4vw, 32px);
}

#root.mm-system #more-moments .fp-more-gallery[open] > .fp-photo-strip {
  margin-top: clamp(20px, 2.4vw, 32px) !important;
}

#root.mm-system figure.mm-winter-photo-r34 {
  overflow: visible !important;
  clip-path: none !important;
}

#root.mm-system .mm-winter-photo-r34 > figcaption {
  display: block;
  position: static;
  padding: 8px 6px 0;
  text-indent: 0;
  clip-path: none !important;
}

#root.mm-system .mm-schools-r34 #request [data-mm-request-copy] > .p-section-head {
  display: block !important;
}

#root.mm-system .mm-schools-r34 #request [data-mm-request-copy] > .p-section-head > p {
  margin: 14px 0 0 !important;
  justify-self: start;
  text-align: left;
}

#root.mm-system #world-films .mf-film-grid {
  row-gap: clamp(32px, 4vw, 56px);
}

#root.mm-system #world-films .mf-film-card {
  display: grid;
  grid-template-rows: 1fr auto;
  gap: 16px;
}

#root.mm-system #world-films .mf-film-card-copy h3 { margin: 0 0 6px; }
#root.mm-system #world-films .mf-film-card-copy p { margin: 0; }

#root.mm-system .mm-legend-r34 #morning .mf-photo-triplet {
  margin-top: clamp(24px, 3vw, 44px);
}

#root.mm-system .mm-legend-r34 :is(#worlds, #wand) > .mf-story {
  column-gap: clamp(34px, 5vw, 72px);
  row-gap: 24px;
}

#root.mm-system .mm-legend-r34 #cta > .container {
  display: grid;
  justify-items: center;
  gap: 24px;
}

#root.mm-system .mm-legend-r34 #cta .mf-heading {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) !important;
  justify-items: center;
  gap: 12px;
  width: min(100%, 750px);
  margin: 0 auto;
  text-align: center;
}

#root.mm-system .mm-legend-r34 #cta :is(.home-kicker, h2, .mf-heading > p) {
  margin-inline: auto !important;
  text-align: center !important;
}

#root.mm-system .mm-legend-r34 #cta .home-kicker { justify-content: center; }

#root.mm-system .mm-article-immersive-r38 .source-copy p {
  font-weight: 400;
}

#root.mm-system #opening-report {
  padding-block: clamp(32px, 5vw, 72px);
}

#root.mm-system .mm-afisha-r38 .mf-hero .mf-actions .mf-button-outline {
  color: #fffaf0;
  border-color: #fffaf0a8;
}

#root.mm-system .mm-afisha-r38 .mf-hero .mf-actions .mf-button-outline:is(:hover, :focus-visible) {
  color: #2d2117;
  background: #fffaf0;
}

/* Contacts */
#root.mm-system .mm-contacts-r38 .mm-contact-section {
  padding-block: clamp(40px, 5.4vw, 80px);
}

#root.mm-system .mm-contacts-r38 .mm-contact-grid {
  display: grid;
  grid-template-columns: minmax(0, .88fr) minmax(0, 1.12fr);
  align-items: start;
  gap: clamp(24px, 4vw, 64px);
}

#root.mm-system .mm-contacts-r38 :is(.mm-contact-grid, #transport, #estate-entrance) :is(.mf-heading, .home-section-head) {
  display: block !important;
  margin: 0;
}

#root.mm-system .mm-contacts-r38 :is(.mf-heading, .home-section-head) > p:not(.home-kicker) {
  margin: 14px 0 0 !important;
}

#root.mm-system .mm-contacts-r38 .mm-contact-actions,
#root.mm-system .mm-contacts-r38 .mm-contact-location {
  display: grid;
  gap: 18px;
  justify-items: start;
  min-width: 0;
}

#root.mm-system .mm-contacts-r38 .mf-contact-lines {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 24px;
  margin: 0;
}

#root.mm-system .mm-contacts-r38 .mf-contact-map {
  display: grid;
  width: 100%;
  gap: 9px;
  margin: 0;
}

#root.mm-system .mm-contacts-r38 .mf-contact-map img {
  width: 100%;
  aspect-ratio: 2 / 1;
  height: auto;
  object-fit: cover;
}

#root.mm-system .mm-contacts-r38 #transport .mf-three-notes { margin-top: 24px; }
#root.mm-system .mm-contacts-r38 #estate-entrance .home-section-head { margin-bottom: 24px; }
#root.mm-system .mm-contacts-r38 #request .mf-form { width: 100%; margin: 0; }

/* Gift kit and the dedicated recipient preview. */
#root.mm-system #gift-story .mm-gift-story-r38 {
  display: grid;
  grid-template: none;
  gap: clamp(24px, 3vw, 40px);
}

#root.mm-system #gift-story .mm-gift-gallery-r38 {
  grid-area: auto;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-template-areas: "kit certificates" "kit overview" "caption caption";
  align-items: start;
  gap: 12px clamp(16px, 2vw, 28px);
  margin: 0;
}

#root.mm-system #gift-story .mm-gift-gallery-r38 > .mm-gift-gallery-grid { grid-area: kit; }

#root.mm-system #gift-story .mm-gift-gallery-r38 > .mm-gift-certificate-grid {
  grid-area: certificates;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-content: start;
  margin: 0;
}

#root.mm-system #gift-story .mm-gift-gallery-r38 .mm-gift-gallery-grid > a:first-child { aspect-ratio: 1513 / 1040; }
#root.mm-system #gift-story .mm-gift-gallery-r38 .mm-gift-gallery-grid > a:not(:first-child) { aspect-ratio: 1.72; }
#root.mm-system #gift-story .mm-gift-gallery-r38 > figcaption { grid-area: caption; margin: 0; }

#root.mm-system #gift-story .mm-gift-gallery-r38 > .mm-gift-story-personal {
  grid-area: overview;
  min-width: 0;
}

#root.mm-system #gift-story .mm-gift-story-r38 .mm-r28-kit { margin: 10px 0 0; }
#root.mm-system #gift-story .mm-gift-story-r38 .cc-lead { margin: 0; }

#root.mm-system #gift-story .mm-gift-preview-r38 {
  display: grid;
  grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr);
  align-items: center;
  gap: clamp(20px, 4.5vw, 64px);
  border: 1px solid #cfb57f;
  border-radius: var(--mm-photo-radius, 20px);
  padding: clamp(18px, 3.4vw, 46px);
  background: radial-gradient(ellipse at 92% 15%, #efdeb6, transparent 70%), #fbf4e4;
}

#root.mm-system #gift-story .mm-gift-preview-r38 .mm-gift-personal-title {
  padding: 0;
  margin: 0 0 20px;
  font: 400 clamp(26px, 3vw, 42px)/1.12 var(--mm-display, Georgia);
}

#root.mm-system #gift-story .mm-gift-preview-r38 label { display: block; }
#root.mm-system #gift-story .mm-gift-preview-r38 #certificate-preview-help { margin: 12px 0 0; }
#root.mm-system #gift-story .mm-gift-story-r38 > .mm-gift-continue { grid-area: auto; }

@media (max-width: 760px) {
  #root.mm-system .mm-contacts-r38 .mm-contact-grid,
  #root.mm-system #gift-story .mm-gift-gallery-r38,
  #root.mm-system #gift-story .mm-gift-preview-r38 { grid-template-columns: minmax(0, 1fr); }

  #root.mm-system #gift-story .mm-gift-gallery-r38 {
    grid-template-areas: "kit" "certificates" "overview" "caption";
  }
  #root.mm-system #gift-story .mm-gift-preview-r38 .mm-gift-personal-title { margin-bottom: 14px; }
}
