*, *::before, *::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
  background: #f3ead4;
}

.learn-product-shell {
  display: flex;
  min-height: 100vh;
  width: 100%;
  color: var(--ink);
  background: var(--cream);
  font-family: "EB Garamond", Georgia, serif;
  font-size: 16px;
}

.learn-product-sidebar {
  position: sticky;
  top: 0;
  flex: 0 0 292px;
  width: 292px;
  height: 100vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: linear-gradient(180deg, #061522 0%, #0b2130 62%, #061522 100%);
  color: #f6f1e8;
  border-right: 1px solid rgba(200, 162, 74, 0.24);
}

.learn-product-sidebar-scroll {
  flex: 1;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: rgba(200, 162, 74, 0.38) rgba(246, 241, 232, 0.04);
}

.learn-product-brand {
  position: relative;
  display: grid;
  justify-items: center;
  gap: 0.75rem;
  padding: 1.8rem 1.35rem 1.35rem;
  border-bottom: 1px solid rgba(200, 162, 74, 0.16);
  text-align: center;
}

.learn-product-brand::before {
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  width: 230px;
  height: 140px;
  transform: translateX(-50%);
  background: radial-gradient(ellipse at top, rgba(200, 162, 74, 0.13), transparent 70%);
  pointer-events: none;
}

.learn-product-brand-mark,
.learn-product-brand-copy,
.learn-product-profile,
.learn-product-label,
.learn-product-nav {
  position: relative;
  z-index: 1;
}

.learn-product-brand-mark {
  width: 76px;
  height: 76px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(200, 162, 74, 0.32);
  border-radius: 10px;
  background: rgba(200, 162, 74, 0.12);
  text-decoration: none;
}

.learn-product-brand-mark img {
  width: 68px;
  height: 68px;
  object-fit: contain;
}

.learn-product-brand-copy strong {
  display: block;
  color: #c8a24a;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 3rem;
  font-weight: 500;
  line-height: 0.9;
  letter-spacing: 0.08em;
}

.learn-product-brand-copy span {
  display: block;
  margin-top: 0.45rem;
  color: rgba(246, 241, 232, 0.78);
  font-family: "DM Sans", system-ui, sans-serif;
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.learn-product-back {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  margin: 1.2rem 1rem 0.85rem;
  padding: 0.88rem 1rem;
  border: 1px solid rgba(200, 162, 74, 0.28);
  border-radius: 15px;
  background: rgba(246, 241, 232, 0.075);
  color: #f6f1e8;
  text-align: center;
  text-decoration: none;
  font-family: "DM Sans", system-ui, sans-serif;
  font-size: 0.96rem;
  font-weight: 800;
}

.learn-product-back span {
  width: 1.75rem;
  height: 1.75rem;
  display: inline-grid;
  place-items: center;
  border-radius: 999px;
  background: rgba(200, 162, 74, 0.18);
  color: #c8a24a;
}

.learn-product-back:hover {
  border-color: rgba(200, 162, 74, 0.48);
  background: rgba(246, 241, 232, 0.11);
}

.learn-product-profile {
  padding: 1.05rem 1.25rem;
  border-bottom: 1px solid rgba(200, 162, 74, 0.13);
}

.learn-product-profile strong {
  display: block;
  color: #f6f1e8;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 1.42rem;
  font-weight: 600;
}

.learn-product-profile span {
  display: block;
  margin-top: 0.2rem;
  color: rgba(246, 241, 232, 0.72);
  font-family: "DM Sans", system-ui, sans-serif;
  font-size: 0.86rem;
}

.learn-product-label {
  width: fit-content;
  margin: 1rem 1.25rem 0.45rem;
  padding: 0.28rem 0.72rem;
  border: 1px solid rgba(200, 162, 74, 0.34);
  border-radius: 999px;
  color: #c8a24a;
  background: rgba(200, 162, 74, 0.1);
  font-family: "DM Sans", system-ui, sans-serif;
  font-size: 0.66rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.learn-product-nav {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  padding: 0.35rem 0.9rem 1.2rem;
}

.learn-product-nav a {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  min-height: 48px;
  padding: 0.72rem 0.9rem;
  border: 1px solid transparent;
  border-radius: 14px;
  color: rgba(246, 241, 232, 0.82);
  text-decoration: none;
  font-family: "DM Sans", system-ui, sans-serif;
  font-size: 0.98rem;
  font-weight: 750;
  transition: background 0.16s ease, border-color 0.16s ease, color 0.16s ease;
}

.learn-product-nav a:hover,
.learn-product-nav a.is-active {
  color: #f6f1e8;
  background: rgba(246, 241, 232, 0.09);
  border-color: rgba(200, 162, 74, 0.36);
}

.learn-product-nav-icon {
  width: 1.45rem;
  color: #c8a24a;
  text-align: center;
  font-size: 1.1rem;
  flex: 0 0 auto;
}

.learn-product-sidebar-signoff {
  display: grid;
  justify-items: center;
  gap: 0.75rem;
  padding: 1.45rem 1.25rem 1.8rem;
  border-top: 1px solid rgba(200, 162, 74, 0.16);
  text-align: center;
  color: rgba(246, 241, 232, 0.84);
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 1.18rem;
  font-style: italic;
}

.learn-product-sidebar-signoff img {
  width: 42px;
  height: 42px;
  object-fit: contain;
  opacity: 0.84;
}

.learn-product-main {
  flex: 1;
  min-width: 0;
  height: 100vh;
  overflow: auto;
  display: flex;
  flex-direction: column;
}

.learn-product-topbar {
  position: sticky;
  top: 0;
  z-index: 60;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  min-height: 70px;
  padding: 0.72rem clamp(0.9rem, 2.5vw, 1.8rem);
  border-bottom: 1px solid rgba(201, 162, 91, 0.38);
  background:
    radial-gradient(circle at 84% 0%, rgba(201, 162, 91, 0.2), transparent 22rem),
    linear-gradient(135deg, #061522 0%, #0a2035 62%, #101d22 100%);
  box-shadow: 0 10px 28px rgba(6, 21, 34, 0.16);
  color: #fffdf8;
  backdrop-filter: blur(10px);
}

.learn-menu-button {
  display: none;
}

.learn-mobile-brand {
  display: inline-flex;
  min-width: 0;
  align-items: center;
  gap: 0.65rem;
  color: #fffdf8;
  text-decoration: none;
}

.learn-mobile-brand img {
  width: 2.35rem;
  height: 2.35rem;
  flex: 0 0 auto;
  object-fit: contain;
}

.learn-mobile-brand span {
  display: grid;
  gap: 0.12rem;
  min-width: 0;
}

.learn-mobile-brand strong {
  display: block;
  color: #fffdf8;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: clamp(1.55rem, 4vw, 2.05rem);
  font-weight: 600;
  letter-spacing: 0.12em;
  line-height: 0.86;
}

.learn-mobile-brand small {
  display: block;
  color: rgba(246, 241, 232, 0.74);
  font-family: "DM Sans", system-ui, sans-serif;
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  line-height: 1;
  text-transform: uppercase;
}

.learn-page-title-utility {
  display: none;
}

.learn-utility-actions {
  margin-left: auto;
}

.learn-utility-actions > div:first-child span:last-child,
.learn-utility-actions a span span,
.learn-utility-actions a span span + span {
  color: #fffdf8 !important;
}

.learn-quick-action {
  display: inline-flex;
  min-height: 2.75rem;
  min-width: 9rem;
  align-items: center;
  justify-content: center;
  border: 1px solid transparent;
  border-radius: 10px;
  background: #c8a24a;
  color: #061522 !important;
  font-family: "DM Sans", system-ui, sans-serif;
  font-size: 0.9rem;
  font-weight: 900;
  text-decoration: none;
}

.learn-account-utility {
  display: flex;
  align-items: center;
  gap: 11px;
  color: inherit;
  text-decoration: none;
}

.learn-account-utility-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #fffdf8;
  border: 2px solid rgba(201, 162, 91, 0.45);
  color: #0a2035;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 20px;
  font-weight: 700;
  box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.12);
}

.learn-product-content {
  flex: 1;
  padding: 26px 30px 10px;
}

.learn-page-intro {
  position: relative;
  display: grid;
  gap: 0.72rem;
  margin-bottom: 1.35rem;
  padding: clamp(1.15rem, 2.4vw, 1.55rem);
  overflow: hidden;
  border: 1px solid rgba(181, 148, 47, 0.32);
  border-radius: 16px;
  background:
    radial-gradient(circle at 90% 0%, rgba(201, 162, 39, 0.16), transparent 18rem),
    linear-gradient(135deg, rgba(255, 250, 240, 0.92), rgba(248, 240, 221, 0.84));
  box-shadow: 0 1px 3px rgba(20, 40, 70, 0.05);
}

.learn-page-intro::after {
  content: "✥";
  position: absolute;
  right: clamp(1rem, 3vw, 2rem);
  top: 50%;
  color: rgba(181, 148, 47, 0.12);
  font-size: clamp(5rem, 12vw, 9rem);
  line-height: 1;
  transform: translateY(-50%);
  pointer-events: none;
}

.learn-page-intro-heading {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 1rem;
  min-width: 0;
}

.learn-page-intro-icon {
  width: clamp(3.4rem, 6vw, 4.35rem);
  height: clamp(3.4rem, 6vw, 4.35rem);
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  border: 1px solid rgba(181, 148, 47, 0.45);
  border-radius: 15px;
  background:
    linear-gradient(180deg, rgba(253, 249, 239, 0.86), rgba(241, 230, 201, 0.78));
  color: #b5942f;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.48);
}

.learn-page-intro-icon svg {
  width: 66%;
  height: 66%;
}

.learn-page-intro-kicker {
  color: #b5942f;
  font-family: "DM Sans", system-ui, sans-serif;
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.learn-page-intro h1 {
  margin: 0.08rem 0 0;
  color: #1b2c45;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: clamp(2.35rem, 5vw, 3.45rem);
  font-weight: 600;
  line-height: 0.95;
}

.learn-page-intro-description,
.learn-page-intro-quote {
  position: relative;
  z-index: 1;
}

.learn-page-intro-description {
  max-width: 58rem;
  margin: 0;
  color: #33405a;
  font-size: clamp(1rem, 1.4vw, 1.08rem);
  line-height: 1.48;
}

.learn-page-intro-quote {
  display: flex;
  align-items: flex-start;
  gap: 0.7rem;
  max-width: 62rem;
  margin-top: 0.15rem;
  padding-top: 0.75rem;
  border-top: 1px solid rgba(181, 148, 47, 0.24);
}

.learn-page-intro-quote > span {
  color: rgba(181, 148, 47, 0.58);
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 2.2rem;
  line-height: 0.8;
}

.learn-page-intro-quote p {
  margin: 0;
  color: #1b2c45;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: clamp(1.18rem, 2vw, 1.38rem);
  font-style: italic;
  line-height: 1.32;
}

.learn-page-intro-quote strong {
  display: inline-block;
  margin-left: 0.45rem;
  color: #b5942f;
  font-family: "DM Sans", system-ui, sans-serif;
  font-size: 0.72rem;
  font-style: normal;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  white-space: nowrap;
}

.learn-sidebar-scrim {
  display: none;
}

.learn-product-tabbar {
  display: none;
}

.learn-today-art-panel {
  flex: none;
  width: 160px;
  min-height: 146px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: #fffaf0;
  overflow: hidden;
  display: flex;
  align-items: stretch;
  justify-content: center;
  box-shadow: 0 12px 30px rgba(18, 38, 67, 0.1);
}

.learn-today-art-panel img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.learn-today-main {
  flex: 1 1 360px;
  min-width: 320px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.learn-today-meta-grid {
  display: grid;
  grid-template-columns: minmax(150px, 0.9fr) minmax(170px, 1fr);
  gap: 14px;
  margin-top: 12px;
  align-items: start;
}

.learn-today-readings {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  min-width: 0;
}

.learn-today-readings > div {
  min-width: 0;
}

.learn-today-hymns {
  flex: 0 1 330px;
  min-width: 240px;
  max-width: 360px;
  border-left: 1px solid var(--line);
  padding-left: 22px;
}

.learn-setup-progress-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(160px, 1fr));
  gap: 12px;
  margin-top: 14px;
}

.learn-setup-step {
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--paper2);
  padding: 12px;
  text-align: left;
  color: var(--ink);
  font: inherit;
  cursor: pointer;
  transition: transform 0.16s ease, box-shadow 0.16s ease, border-color 0.16s ease, background 0.16s ease;
}

.learn-setup-step:hover,
.learn-setup-step:focus-visible {
  transform: translateY(-1px);
  border-color: rgba(181, 148, 47, 0.56);
  box-shadow: 0 10px 24px rgba(18, 38, 67, 0.12);
  outline: none;
}

.learn-setup-step small {
  color: var(--gold);
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

.learn-setup-step strong {
  display: block;
  margin: 5px 0;
}

.learn-setup-step span {
  display: block;
  color: var(--muted);
  line-height: 1.35;
}

.learn-setup-step.is-complete {
  background: linear-gradient(135deg, rgba(49, 95, 59, 0.16), rgba(253, 249, 239, 0.92));
  border-color: rgba(49, 95, 59, 0.34);
}

.learn-setup-step.is-active,
.learn-setup-step.is-needed {
  background: #fbf2dd;
  border-color: rgba(181, 148, 47, 0.4);
}

.learn-setup-anchor {
  display: block;
  scroll-margin-top: 112px;
}

.learn-setup-focus + section,
.learn-setup-focus + article,
.learn-setup-focus + div {
  animation: learnSetupFocus 1.35s ease;
}

@keyframes learnSetupFocus {
  0% {
    box-shadow: 0 0 0 0 rgba(181, 148, 47, 0);
  }
  25% {
    box-shadow: 0 0 0 5px rgba(181, 148, 47, 0.2);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(181, 148, 47, 0);
  }
}

@media (max-width: 920px) {
  .learn-product-shell {
    display: block;
    min-height: 100vh;
    padding-bottom: calc(78px + env(safe-area-inset-bottom));
  }

  .learn-product-sidebar {
    position: fixed;
    z-index: 80;
    inset: 0 auto 0 0;
    width: min(86vw, 320px);
    transform: translateX(-104%);
    transition: transform 0.22s ease;
    box-shadow: 18px 0 42px rgba(6, 21, 34, 0.28);
  }

  .learn-menu-open .learn-product-sidebar {
    transform: translateX(0);
  }

  .learn-sidebar-scrim {
    position: fixed;
    z-index: 70;
    inset: 0;
    display: block;
    background: rgba(6, 21, 34, 0.46);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.18s ease;
  }

  .learn-menu-open .learn-sidebar-scrim {
    opacity: 1;
    pointer-events: auto;
  }

  .learn-product-main {
    height: auto;
    min-height: 100vh;
    overflow: visible;
  }

  .learn-product-topbar {
    min-height: 64px;
    padding: 0.62rem 0.82rem;
    overflow: hidden;
  }

  .learn-product-topbar > div:last-child {
    margin-left: auto;
    gap: 0.7rem !important;
  }

  .learn-product-topbar > div:last-child > div:first-child,
  .learn-product-topbar > div:last-child > span,
  .learn-product-topbar > div:last-child > button,
  .learn-product-topbar .learn-quick-action {
    display: none !important;
  }

  .learn-product-topbar a {
    color: inherit;
  }

  .learn-menu-button {
    width: 42px;
    height: 42px;
    display: inline-flex;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    border: 1px solid rgba(200, 162, 74, 0.36);
    border-radius: 11px;
    background: rgba(246, 241, 232, 0.08);
    color: #f6f1e8;
  }

  .learn-menu-button span {
    width: 18px;
    height: 2px;
    margin: 0 auto;
    border-radius: 999px;
    background: currentColor;
  }

  .learn-mobile-brand {
    gap: 0.5rem;
  }

  .learn-mobile-brand img {
    width: 33px;
    height: 33px;
    object-fit: contain;
  }

  .learn-mobile-brand strong {
    font-size: 1.55rem;
  }

  .learn-mobile-brand small {
    display: none;
  }

  .learn-page-title-utility {
    display: none;
  }

  .learn-account-utility {
    max-width: 46px;
    gap: 0;
  }

  .learn-account-utility > span:not(.learn-account-utility-avatar) {
    display: none !important;
  }

  .learn-account-utility-avatar {
    width: 38px;
    height: 38px;
    font-size: 18px;
  }

  .learn-product-content {
    padding: 1rem 0.82rem 1.5rem;
    overflow-x: clip;
  }

  .learn-page-intro {
    gap: 0.65rem;
    margin-bottom: 1rem;
    padding: 1rem;
    border-radius: 14px;
  }

  .learn-page-intro::after {
    right: 0.6rem;
    top: 0.8rem;
    font-size: 4.5rem;
    transform: none;
  }

  .learn-page-intro-heading {
    align-items: flex-start;
    gap: 0.78rem;
  }

  .learn-page-intro-icon {
    width: 3.1rem;
    height: 3.1rem;
    border-radius: 13px;
  }

  .learn-page-intro h1 {
    font-size: clamp(2.1rem, 12vw, 2.65rem);
  }

  .learn-page-intro-description {
    font-size: 0.98rem;
  }

  .learn-page-intro-quote p {
    font-size: 1.08rem;
  }

  .learn-product-content [style*="grid-template-columns"],
  .learn-product-content [style*="display:grid"] {
    grid-template-columns: 1fr !important;
  }

  .learn-product-content [style*="display:flex"] {
    max-width: 100%;
    flex-wrap: wrap !important;
  }

  .learn-product-content [style*="width:108px"],
  .learn-product-content [style*="width:130px"] {
    width: 100% !important;
    height: auto !important;
    min-height: 88px !important;
  }

  .learn-product-content [style*="font-size:38px"],
  .learn-product-content [style*="font-size:34px"] {
    font-size: 2rem !important;
  }

  .learn-product-content input,
  .learn-product-content select,
  .learn-product-content textarea,
  .learn-product-content button {
    max-width: 100%;
  }

  .learn-product-content [data-setup-row] {
    grid-template-columns: 1fr !important;
    align-items: stretch !important;
  }

.learn-product-content [data-setup-row] > span:first-child {
  justify-self: start;
}

.learn-product-tabbar {
    position: fixed;
    z-index: 65;
    left: 0;
    right: 0;
    bottom: 0;
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    min-height: calc(72px + env(safe-area-inset-bottom));
    padding: 0.42rem 0.45rem calc(0.42rem + env(safe-area-inset-bottom));
    border-top: 1px solid rgba(200, 162, 74, 0.22);
    background: rgba(253, 251, 247, 0.96);
    box-shadow: 0 -12px 28px rgba(6, 21, 34, 0.12);
    backdrop-filter: blur(16px);
  }

  .learn-product-tabbar a {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.2rem;
    min-width: 0;
    border-radius: 13px;
    color: rgba(6, 21, 34, 0.7);
    text-decoration: none;
    font-family: "DM Sans", system-ui, sans-serif;
    font-size: 0.68rem;
    font-weight: 800;
  }

  .learn-product-tabbar a.is-active {
    color: #061522;
    background: rgba(200, 162, 74, 0.14);
  }

  .learn-product-tabbar svg {
    width: 21px;
    height: 21px;
    stroke: currentColor;
    fill: none;
    stroke-width: 1.9;
    stroke-linecap: round;
    stroke-linejoin: round;
  }

  .learn-setup-progress-grid {
    grid-template-columns: 1fr;
  }

  .learn-today-art-panel {
    width: 100%;
    min-height: 190px;
  }

  .learn-today-main {
    flex-basis: 100%;
  }

  .learn-today-meta-grid,
  .learn-today-readings {
    grid-template-columns: 1fr;
  }

  .learn-today-hymns {
    flex-basis: 100%;
    max-width: none;
    border-left: 0;
    border-top: 1px solid var(--line);
    padding-left: 0;
    padding-top: 18px;
  }
}
