:root {
  --black: #050505;
  --ink: #0b0d0f;
  --panel: #111416;
  --panel-soft: #171b1e;
  --ivory: #fff8ee;
  --muted: #c6bbae;
  --line: rgba(255, 248, 238, 0.16);
  --orange: #ef7d2b;
  --orange-soft: #ffae68;
  --cyan: #5fc5e8;
  --danger: #ff7468;
  --good: #63d38a;
  --max: 1180px;
  --header: 72px;
  --serif: Georgia, "Times New Roman", serif;
  --sans: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html { color-scheme: dark; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--black) url("https://themeyvyn.com/wp-content/uploads/2025/07/peakpx-scaled.webp") center top / 900px auto fixed;
  color: var(--ivory);
  font-family: var(--sans);
  line-height: 1.55;
}
body::before {
  background: rgba(0, 0, 0, 0.5);
  content: "";
  inset: 0;
  pointer-events: none;
  position: fixed;
  z-index: -1;
}
img { display: block; max-width: 100%; }
a { color: inherit; }
button, input, textarea, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
h1, h2, h3, p { margin-top: 0; }
h1, h2, h3 { letter-spacing: 0; }
h1, h2 { font-family: var(--serif); }
h1 { font-size: clamp(3rem, 8vw, 7rem); line-height: 0.94; }
h2 { font-size: clamp(2rem, 4.5vw, 4rem); line-height: 1; }
h3 { line-height: 1.15; }

.skip-link { left: -999px; position: fixed; top: 8px; z-index: 1000; }
.skip-link:focus { background: var(--ivory); color: var(--black); left: 8px; padding: 10px 14px; }

.site-header {
  align-items: center;
  backdrop-filter: blur(14px);
  background: rgba(5, 5, 5, 0.9);
  border-bottom: 1px solid var(--line);
  display: flex;
  height: var(--header);
  justify-content: space-between;
  padding: 0 max(18px, calc((100vw - var(--max)) / 2));
  position: sticky;
  top: 0;
  z-index: 100;
}
.brand { flex: 0 0 auto; }
.brand img { height: 42px; object-fit: contain; width: 116px; }
.site-nav { align-items: center; display: flex; gap: 22px; }
.site-nav a {
  color: var(--muted);
  font-size: 0.79rem;
  font-weight: 800;
  text-decoration: none;
  text-transform: uppercase;
}
.site-nav a:hover, .site-nav a.is-active { color: var(--orange-soft); }
.nav-toggle { background: transparent; border: 1px solid var(--line); color: var(--ivory); display: none; padding: 9px 12px; }

/* Keep the active Formula theme navigation available on long replacement pages. */
#site-header {
  background: rgba(5, 5, 5, 0.96);
  position: sticky !important;
  top: 0 !important;
  z-index: 1000 !important;
}
.admin-bar #site-header { top: 32px !important; }
#site-header .sticky-menu.sticky-fixed {
  position: relative !important;
  top: auto !important;
  transform: none !important;
  width: 100% !important;
}

.band { margin: 0 auto; max-width: var(--max); padding: clamp(56px, 9vw, 110px) 22px; }
.eyebrow {
  color: var(--orange-soft);
  font-size: 0.76rem;
  font-weight: 900;
  letter-spacing: 0.14em;
  margin-bottom: 14px;
  text-transform: uppercase;
}
.section-heading { align-items: end; display: flex; gap: 26px; justify-content: space-between; margin-bottom: 32px; }
.section-heading p { color: var(--orange-soft); font-size: 0.76rem; font-weight: 900; letter-spacing: 0.14em; text-transform: uppercase; }
.section-heading h2 { max-width: 760px; }

.button {
  align-items: center;
  background: rgba(255, 248, 238, 0.06);
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--ivory);
  cursor: pointer;
  display: inline-flex;
  font-size: 0.78rem;
  font-weight: 900;
  justify-content: center;
  min-height: 46px;
  padding: 12px 17px;
  text-decoration: none;
  text-transform: uppercase;
  transition: background 160ms ease, border-color 160ms ease, color 160ms ease, transform 160ms ease;
}
.button:hover { border-color: var(--orange-soft); color: var(--orange-soft); transform: translateY(-2px); }
.button-primary { background: var(--ivory); border-color: var(--ivory); color: var(--black); }
.button-primary:hover { background: var(--orange); border-color: var(--orange); color: var(--black); }
.text-link { color: var(--orange-soft); display: inline-block; font-weight: 850; margin-top: 24px; text-underline-offset: 4px; }

.home-hero {
  align-items: center;
  background-image: linear-gradient(90deg, rgba(3, 4, 5, 0.98) 0%, rgba(3, 4, 5, 0.88) 38%, rgba(3, 4, 5, 0.2) 72%, rgba(3, 4, 5, 0.44) 100%), var(--hero-image);
  background-position: center, 78% center;
  background-size: cover;
  display: flex;
  min-height: calc(100svh - var(--header));
}
.home-hero-inner { margin: 0 auto; max-width: var(--max); padding: 52px 22px; width: 100%; }
.hero-logo { height: auto; margin-bottom: 20px; width: min(330px, 66vw); }
.home-hero h1 { max-width: 750px; }
.home-hero p:not(.eyebrow) { color: var(--muted); font-size: clamp(1.05rem, 2vw, 1.32rem); max-width: 560px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.manifesto { padding-bottom: 80px; padding-top: 80px; }
.manifesto h2 { max-width: 920px; }
.manifesto > p:last-child { color: var(--muted); font-size: 1.2rem; max-width: 680px; }
.latest { border-top: 1px solid var(--line); }
.home-studies { align-items: center; border-top: 1px solid var(--line); display: flex; gap: 28px; justify-content: space-between; }
.home-studies h2 { max-width: 750px; }

.album-grid { display: grid; gap: 28px 14px; grid-template-columns: repeat(5, minmax(0, 1fr)); }
.album-card { min-width: 0; }
.album-card-art { background: #111; display: block; overflow: hidden; position: relative; }
.album-card-art::after { border: 1px solid rgba(255,255,255,0.14); content: ""; inset: 0; pointer-events: none; position: absolute; }
.album-card img { aspect-ratio: 1; object-fit: cover; transition: filter 220ms ease, transform 220ms ease; width: 100%; }
.album-card:hover img { filter: brightness(1.08); transform: scale(1.025); }
.album-card > div { padding-top: 12px; }
.album-card p { color: var(--orange-soft); font-size: 0.67rem; font-weight: 900; margin-bottom: 5px; text-transform: uppercase; }
.album-card h3 { font-family: var(--serif); font-size: 1.18rem; margin: 0; }
.album-card h3 a { text-decoration: none; }

.music-hero { display: grid; gap: 44px; grid-template-columns: minmax(0, 1fr) minmax(360px, 0.8fr); min-height: calc(100svh - var(--header)); place-items: center stretch; }
.music-hero > div:first-child { align-self: center; }
.music-hero h1 { max-width: 720px; }
.music-hero > div:first-child > p:not(.eyebrow) { color: var(--muted); font-size: 1.15rem; max-width: 620px; }
.preference-sorter { background: rgba(11, 13, 15, 0.94); border: 1px solid var(--line); padding: 24px; }
.preference-sorter h2 { font-size: 2rem; }
.preference-sorter > p { color: var(--muted); }
.preference-sorter ol { display: grid; gap: 8px; list-style: none; margin: 18px 0; padding: 0; }
.preference-sorter li { align-items: center; background: var(--panel-soft); border: 1px solid var(--line); display: grid; gap: 10px; grid-template-columns: 34px 1fr auto auto; padding: 10px; }
.preference-sorter li.is-dragging { opacity: 0.55; }
.rank-number { align-items: center; background: var(--orange); border-radius: 50%; color: var(--black); display: flex; font-size: 0.74rem; font-weight: 900; height: 26px; justify-content: center; width: 26px; }
.preference-sorter strong, .preference-sorter small { display: block; }
.preference-sorter small { color: var(--muted); font-size: 0.73rem; }
.preference-sorter li button { background: transparent; border: 1px solid var(--line); color: var(--ivory); cursor: pointer; padding: 6px; }
#preference-status { color: var(--good); min-height: 1.4em; padding-top: 10px; }
.category-preview { border-top: 1px solid var(--line); }
.category-grid { display: grid; gap: 1px; grid-template-columns: repeat(3, 1fr); }
.category-grid article { background: rgba(17, 20, 22, 0.9); border: 1px solid var(--line); min-height: 210px; padding: 24px; }
.category-grid article p { color: var(--orange-soft); font-size: 0.75rem; font-weight: 900; text-transform: uppercase; }
.category-grid article h3 { font-family: var(--serif); font-size: 1.45rem; }
.category-grid article a { color: var(--cyan); font-size: 0.8rem; font-weight: 900; text-transform: uppercase; }

.library-head { padding-bottom: 34px; }
.library-head h1 { margin-bottom: 16px; }
.library-head > p:not(.eyebrow) { color: var(--muted); font-size: 1.1rem; }
.library-tools { background: rgba(11, 13, 15, 0.92); border-bottom: 1px solid var(--line); border-top: 1px solid var(--line); margin-top: 30px; padding: 18px 0; }
.library-tools label { display: block; font-size: 0.75rem; font-weight: 900; text-transform: uppercase; }
.library-primary-controls { display: grid; gap: 12px; grid-template-columns: minmax(260px, 1fr) minmax(210px, 0.42fr) minmax(190px, 0.36fr); width: 100%; }
.library-tools input, .library-tools select { background: var(--panel); border: 1px solid var(--line); color: var(--ivory); display: block; margin-top: 8px; min-height: 48px; padding: 13px; width: 100%; }
.library-results { padding-top: 20px; }
.result-count { color: var(--muted); font-size: 0.8rem; margin-bottom: 24px; text-transform: uppercase; }
.album-card[hidden] { display: none; }
.empty-state { border: 1px solid var(--line); color: var(--muted); padding: 50px; text-align: center; }

.album-hero { background-image: linear-gradient(90deg, rgba(5,5,5,0.98) 0%, rgba(5,5,5,0.86) 48%, rgba(5,5,5,0.48) 100%), var(--album-cover); background-position: center; background-size: cover; min-height: calc(100svh - var(--header)); position: relative; }
.album-hero::before { backdrop-filter: blur(20px); background: rgba(5,5,5,0.38); content: ""; inset: 0; position: absolute; }
.album-hero-inner { align-items: center; display: grid; gap: clamp(34px, 6vw, 82px); grid-template-columns: minmax(280px, 0.78fr) minmax(0, 1.22fr); margin: 0 auto; max-width: var(--max); min-height: calc(100svh - var(--header)); padding: 60px 22px; position: relative; z-index: 1; }
.album-cover { aspect-ratio: 1; box-shadow: 0 30px 90px rgba(0,0,0,0.56); object-fit: cover; width: min(100%, 510px); }
.album-intro h1 { font-size: clamp(3.4rem, 7vw, 7rem); }
.album-excerpt { color: var(--ivory); font-family: var(--serif); font-size: clamp(1.18rem, 2vw, 1.55rem); max-width: 700px; }
.category-links { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 24px; }
.category-links a { border: 1px solid var(--line); color: var(--muted); font-size: 0.72rem; font-weight: 900; padding: 7px 9px; text-decoration: none; text-transform: uppercase; }
.status-badge { background: var(--orange); color: var(--black); display: inline-block; margin-left: 8px; padding: 4px 7px; }
.album-story { background: rgba(5,5,5,0.87); }
.prose { font-family: var(--serif); font-size: clamp(1.05rem, 1.4vw, 1.2rem); margin: 0 auto; max-width: 780px; }
.prose h1, .prose h2, .prose h3, .prose h4 { color: var(--ivory); font-family: var(--serif); margin: 1.6em 0 0.5em; }
.prose p, .prose li { color: #e6ddd2; }
.prose blockquote { border-left: 3px solid var(--orange); color: var(--ivory); margin: 28px 0; padding-left: 18px; }
.listen-band { background: var(--ink); border-bottom: 1px solid var(--line); border-top: 1px solid var(--line); padding: 34px max(22px, calc((100vw - var(--max)) / 2)); }
.listen-band > p { color: var(--muted); font-size: 0.72rem; font-weight: 900; text-transform: uppercase; }
.service-buttons { display: flex; flex-wrap: wrap; gap: 10px; }
.service-button { align-items: center; background: #15191c; border: 1px solid rgba(255,255,255,0.16); border-radius: 6px; display: inline-flex; font-size: 0.78rem; font-weight: 900; gap: 9px; min-height: 46px; min-width: 142px; padding: 10px 14px; text-decoration: none; }
.service-button:hover { border-color: var(--service-color, var(--orange-soft)); }
.service-mark { background: var(--service-color, var(--ivory)); display: inline-block; height: 20px; mask: var(--service-icon) center / contain no-repeat; width: 20px; }
.service-spotify { --service-color: #1ed760; --service-icon: url("../brands/spotify.svg"); }
.service-apple { --service-color: #fa243c; --service-icon: url("../brands/applemusic.svg"); }
.service-pandora { --service-color: #3668ff; --service-icon: url("../brands/pandora.svg"); }
.service-youtube { --service-color: #ff0000; --service-icon: url("../brands/youtube.svg"); }
.service-ringtone { --service-color: var(--orange-soft); --service-icon: url("../brands/ringtone.svg"); }
.service-study .service-mark { mask: none; background: transparent; height: auto; width: auto; }
.service-study .service-mark::before { color: var(--cyan); content: "PDF"; font-size: 0.67rem; }
.featured-video { background: rgba(5,5,5,0.9); }
.video-frame { aspect-ratio: 16 / 9; background: #000; margin: 0 auto; max-width: 960px; }
.video-frame iframe { border: 0; height: 100%; width: 100%; }
.album-tags { border-top: 1px solid var(--line); }
.tag-list { display: flex; flex-wrap: wrap; gap: 7px; }
.tag-list span { background: var(--panel); border: 1px solid var(--line); color: var(--muted); font-size: 0.72rem; padding: 6px 9px; }

.study-hero { align-items: end; aspect-ratio: 1 / 1; background-color: #050505; background-image: linear-gradient(90deg, rgba(5,5,5,0.95), rgba(5,5,5,0.32)), var(--study-cover); background-position: center, center; background-repeat: no-repeat, no-repeat; background-size: 100% 100%, contain; display: flex; min-height: 0; padding: 70px max(22px, calc((100vw - var(--max)) / 2)); }
.study-hero > div { max-width: 760px; }
.study-hero p:not(.eyebrow) { font-family: var(--serif); font-size: 1.25rem; max-width: 650px; }
.study-card { align-items: center; border-top: 1px solid var(--line); display: grid; gap: clamp(28px, 6vw, 72px); grid-template-columns: minmax(240px, 0.72fr) minmax(0, 1.28fr); padding: 42px 0; }
.study-card[hidden] { display: none; }
.study-library-tools { border-bottom: 1px solid var(--line); border-top: 1px solid var(--line); display: grid; gap: 12px; grid-template-columns: minmax(260px, 1.2fr) minmax(170px, 0.65fr) minmax(170px, 0.65fr) minmax(180px, 0.55fr); padding: 18px 0; }
.study-library-tools label { font-size: 0.72rem; font-weight: 900; text-transform: uppercase; }
.study-library-tools input, .study-library-tools select { background: var(--panel); border: 1px solid var(--line); color: var(--ivory); display: block; margin-top: 7px; min-height: 46px; padding: 11px; width: 100%; }
.study-library > .result-count { margin: 18px 0 0; }
.study-topic-section { border-top: 1px solid var(--line); padding: 34px 0 12px; }
.study-topic-section[hidden] { display: none; }
.study-topic-heading { align-items: end; display: flex; gap: 18px; justify-content: space-between; margin-bottom: 8px; }
.study-topic-heading .eyebrow { margin: 0; }
.study-topic-heading h3 { font-size: clamp(1.8rem, 4vw, 3rem); margin: 0; }
.study-topic-grid .study-card:first-child { border-top: 0; }
.study-card img { aspect-ratio: 1; object-fit: cover; width: 100%; }
.study-card h2 { font-size: clamp(2rem, 4vw, 3.5rem); }
.study-card p:not(.eyebrow) { color: var(--muted); font-size: 1.1rem; max-width: 680px; }
.study-actions { align-items: center; display: flex; flex-wrap: wrap; gap: 18px; }
.study-actions .text-link { margin-top: 0; }
.pending-copy { color: var(--muted); font-size: 0.8rem; }
.meyvyn-page-bible-studies .button-primary {
  background: var(--orange) !important;
  border-color: var(--orange) !important;
  color: var(--black) !important;
}
.meyvyn-page-bible-studies .button-primary:hover {
  background: var(--ivory) !important;
  border-color: var(--ivory) !important;
  color: var(--black) !important;
}

.generic-hero, .about-hero { align-items: end; background-image: linear-gradient(90deg, rgba(5,5,5,0.96), rgba(5,5,5,0.45)), var(--page-image); background-position: center; background-size: cover; display: flex; min-height: 62svh; padding: 70px max(22px, calc((100vw - var(--max)) / 2)); }
.generic-hero > div, .about-hero > div { max-width: 840px; }
.generic-hero p:not(.eyebrow), .about-hero p:not(.eyebrow) { color: var(--muted); font-size: 1.2rem; max-width: 700px; }
.about-copy { display: grid; gap: 70px; grid-template-columns: minmax(0, 1.2fr) minmax(280px, 0.8fr); }
.about-copy aside { border-left: 2px solid var(--orange); padding-left: 28px; }
.about-copy aside h2 { font-size: clamp(2rem, 4vw, 3.6rem); }
.contact-hero { min-height: 54svh; }
.contact-hero p:not(.eyebrow) { color: var(--muted); font-size: 1.2rem; max-width: 650px; }
.contact-grid { border-top: 1px solid var(--line); display: grid; gap: 34px; grid-template-columns: repeat(2, 1fr); }
.contact-grid > div { border-bottom: 1px solid var(--line); padding-bottom: 24px; }
.contact-grid > div h2 { font-size: 1.3rem; }
.contact-grid form { display: grid; gap: 18px; grid-column: 1 / -1; max-width: 760px; }
.contact-grid label { font-size: 0.75rem; font-weight: 900; text-transform: uppercase; }
.contact-grid input, .contact-grid textarea { background: var(--panel); border: 1px solid var(--line); color: var(--ivory); display: block; margin-top: 7px; padding: 13px; width: 100%; }

.rx-shell { background: #f3ede1; color: #2c241e; max-width: 980px; min-height: calc(100svh - var(--header)); }
.rx-head { display: grid; gap: 18px; grid-template-columns: auto 1fr; }
.rx-head > span { color: #b43b2f; font-family: var(--serif); font-size: 5rem; font-weight: 800; line-height: 0.8; }
.rx-head h1 { color: #2c241e; font-size: clamp(3rem, 7vw, 6rem); }
.rx-head p:not(.eyebrow) { color: #6d6055; }
.rx-shell .eyebrow { color: #b43b2f; }
#rx-form { border-bottom: 1px solid rgba(44,36,30,0.18); border-top: 1px solid rgba(44,36,30,0.18); margin-top: 32px; padding: 28px 0; }
#rx-form label { font-size: 0.75rem; font-weight: 900; text-transform: uppercase; }
#rx-form textarea { background: transparent; border: 0; border-bottom: 1px solid rgba(44,36,30,0.2); color: #2c241e; display: block; font-family: var(--serif); font-size: 1.15rem; margin: 8px 0 20px; padding: 10px 0; resize: vertical; width: 100%; }
.rx-results { display: grid; gap: 1px; margin-top: 30px; }
.rx-result { align-items: center; background: rgba(255,255,255,0.46); display: grid; gap: 20px; grid-template-columns: 100px 1fr auto; padding: 14px; }
.rx-result img { aspect-ratio: 1; object-fit: cover; }
.rx-result h2 { color: #2c241e; font-size: 1.6rem; margin-bottom: 5px; }
.rx-result p { color: #6d6055; font-size: 0.88rem; margin: 0; }

.upload-page { background: #050505; }
.upload-page::before { display: none; }
.upload-app { min-height: calc(100svh - var(--header)); }
.upload-gate { align-items: center; display: flex; justify-content: center; min-height: calc(100svh - var(--header)); padding: 22px; }
.upload-gate form { border: 1px solid var(--line); max-width: 470px; padding: 28px; width: 100%; }
.upload-gate h1 { font-size: 3.4rem; }
.upload-gate label { display: block; font-size: 0.75rem; font-weight: 900; text-transform: uppercase; }
.upload-gate input { background: var(--panel); border: 1px solid var(--line); color: var(--ivory); display: block; margin: 8px 0 14px; padding: 12px; width: 100%; }
#upload-error { color: var(--danger); min-height: 1.4em; }
.upload-toolbar { align-items: end; background: rgba(5,5,5,0.97); border-bottom: 1px solid var(--line); display: flex; flex-wrap: wrap; gap: 9px; padding: 14px 18px; position: sticky; top: var(--header); z-index: 80; }
.upload-toolbar > div { margin-right: auto; }
.upload-toolbar h1 { font-size: 2rem; margin: 0; }
.upload-toolbar .eyebrow { margin-bottom: 3px; }
.upload-toolbar label { font-size: 0.68rem; font-weight: 900; text-transform: uppercase; }
.upload-toolbar input { background: var(--panel); border: 1px solid var(--line); color: var(--ivory); display: block; min-width: 260px; padding: 10px; }
.upload-summary { color: var(--muted); display: flex; font-size: 0.8rem; gap: 20px; justify-content: space-between; padding: 12px 18px; }
.upload-table-wrap { height: calc(100svh - 192px); overflow: auto; }
.upload-table { border-collapse: separate; border-spacing: 0; font-size: 0.78rem; min-width: 2600px; width: 100%; }
.upload-table th { background: #0d0f10; border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 4; }
.upload-table th button { background: transparent; border: 0; color: var(--orange-soft); cursor: pointer; font-size: 0.7rem; font-weight: 900; padding: 12px; text-transform: uppercase; width: 100%; }
.upload-table td { border-bottom: 1px solid var(--line); border-right: 1px solid var(--line); min-width: 170px; padding: 0; vertical-align: top; }
.upload-table td:first-child, .upload-table th:first-child { background: #0d0f10; left: 0; min-width: 112px; position: sticky; z-index: 3; }
.upload-table input, .upload-table textarea, .upload-table select { background: transparent; border: 0; border-bottom: 1px solid rgba(255,255,255,0.07); color: var(--ivory); min-height: 42px; padding: 9px; resize: vertical; width: 100%; }
.upload-table textarea { min-height: 80px; }
.upload-table select option { background: #171b1e; color: var(--ivory); }
.upload-table input:focus, .upload-table textarea:focus, .upload-table select:focus { background: #171b1e; outline: 1px solid var(--orange); }
.upload-state { align-items: center; display: flex; gap: 7px; padding: 9px; }
.upload-table .upload-state input { min-height: 0; width: auto; }
.upload-row-actions { display: grid; gap: 5px; padding: 7px; }
.upload-row-actions button { background: transparent; border: 1px solid var(--line); color: var(--ivory); cursor: pointer; padding: 7px; }
.upload-row-actions button:hover { border-color: var(--orange); color: var(--orange-soft); }
.upload-json { background: #090b0c; border: 1px solid var(--line); color: var(--good); display: block; margin: 14px 18px; min-height: 180px; padding: 12px; width: calc(100% - 36px); }

.site-footer { background: #020202; border-top: 1px solid var(--line); display: grid; gap: 50px; grid-template-columns: 1.2fr 0.8fr 1fr; padding: 60px max(22px, calc((100vw - var(--max)) / 2)); }
.footer-logo { height: auto; margin-bottom: 14px; width: 150px; }
.site-footer p, .site-footer a { color: var(--muted); font-size: 0.84rem; }
.site-footer h2 { font-family: var(--sans); font-size: 0.77rem; text-transform: uppercase; }
.site-footer nav { align-items: flex-start; display: flex; flex-direction: column; gap: 7px; }
.site-footer nav a { text-decoration: none; }
.site-footer .mission { color: var(--ivory); font-size: 1rem; font-weight: 800; }

.reveal { opacity: 0; transform: translateY(18px); transition: opacity 420ms ease, transform 420ms ease; }
.reveal.is-visible { opacity: 1; transform: translateY(0); }

@media (max-width: 920px) {
  .nav-toggle { display: inline-flex; }
  .site-nav { background: #070707; border-bottom: 1px solid var(--line); display: none; flex-direction: column; inset: var(--header) 0 auto; padding: 22px; position: fixed; }
  .site-nav.is-open { display: flex; }
  .music-hero, .album-hero-inner, .study-card, .about-copy { grid-template-columns: 1fr; }
  .album-hero-inner { align-content: center; }
  .album-cover { max-width: 440px; }
  .album-grid { grid-template-columns: repeat(3, 1fr); }
  .site-footer { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 640px) {
  :root { --header: 62px; }
  .site-header { padding: 0 14px; }
  .brand img { height: 36px; width: 98px; }
  .band { padding-left: 16px; padding-right: 16px; }
  .home-hero { background-position: center, 68% center; }
  .home-hero::before { background: rgba(0,0,0,0.18); }
  .home-hero h1 { font-size: clamp(3.2rem, 16vw, 5rem); }
  .section-heading, .home-studies { align-items: flex-start; flex-direction: column; }
  .album-grid { gap: 20px 10px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .library-primary-controls { gap: 6px; grid-template-columns: minmax(0, 1.2fr) minmax(0, 0.95fr) minmax(0, 0.85fr); }
  .library-primary-controls label { font-size: 0.58rem; min-width: 0; }
  .library-primary-controls input, .library-primary-controls select { font-size: 0.72rem; min-height: 42px; min-width: 0; padding: 8px 6px; }
  .album-card h3 { font-size: 1rem; }
  .category-grid { grid-template-columns: 1fr; }
  .music-hero { min-height: auto; padding-top: 54px; }
  .preference-sorter li { grid-template-columns: 30px 1fr; }
  .preference-sorter li button { grid-column: auto; }
  .album-hero-inner { gap: 28px; padding: 34px 16px 56px; }
  .album-cover { max-width: 100%; }
  .album-intro h1 { font-size: clamp(3rem, 16vw, 5rem); }
  .service-button { flex: 1 1 145px; }
  .study-card { padding: 28px 0; }
  .study-library-tools { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .study-library-tools input, .study-library-tools select { font-size: 0.72rem; min-width: 0; padding: 8px 6px; }
  .study-card img { max-width: 420px; }
  .contact-grid { grid-template-columns: 1fr; }
  .rx-result { grid-template-columns: 76px 1fr; }
  .rx-result .button { grid-column: 1 / -1; }
  .upload-toolbar { top: var(--header); }
  .upload-toolbar label, .upload-toolbar input { width: 100%; }
  .upload-toolbar input { min-width: 0; }
  .site-footer { grid-template-columns: 1fr; }
}

@media (max-width: 782px) {
  .admin-bar #site-header { top: 46px !important; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: 0.01ms !important; }
  .reveal { opacity: 1; transform: none; }
}

/* MeyVyn v1.0.21 stabilization
   Keep shortcode content sane, but only correct the Bible Studies featured-title rail. */
.elementor-location-header,
#site-header,
.site-header {
  z-index: 99999 !important;
}

.meyvyn-static-page {
  position: relative;
  z-index: 1;
}

/* Bible Studies featured hero: give dynamic titles a real column so they do not squeeze into a skinny stack. */
.meyvyn-page-bible-studies .study-hero > div {
  max-width: 680px;
  width: min(680px, 58vw);
}

.meyvyn-page-bible-studies .study-hero h1 {
  font-size: clamp(3rem, 5.8vw, 5.8rem);
  line-height: 0.98;
  max-width: 680px;
}

.meyvyn-page-bible-studies .study-hero p:not(.eyebrow) {
  max-width: 600px;
}

@media (max-width: 640px) {
  .meyvyn-page-bible-studies .study-hero {
    align-items: flex-start;
    aspect-ratio: auto !important;
    background-image: linear-gradient(180deg, rgba(5,5,5,0.9), rgba(5,5,5,0.72)), var(--study-cover) !important;
    background-position: center, center !important;
    background-size: cover, cover !important;
    display: flex;
    min-height: auto !important;
    overflow: visible;
    padding: 76px 20px 44px !important;
  }

  .meyvyn-page-bible-studies .study-hero > div {
    max-width: 100% !important;
    position: relative;
    width: 100% !important;
    z-index: 1;
  }

  .meyvyn-page-bible-studies .study-hero h1 {
    font-size: clamp(2.35rem, 11vw, 3.65rem) !important;
    line-height: 1.03 !important;
    max-width: 100% !important;
    overflow-wrap: normal;
    word-break: normal;
  }

  .meyvyn-page-bible-studies .study-hero p:not(.eyebrow) {
    font-size: 1.06rem !important;
    line-height: 1.55 !important;
    max-width: 100% !important;
  }

  .meyvyn-page-bible-studies .study-hero .study-actions {
    align-items: flex-start;
    display: flex;
    flex-wrap: wrap;
    gap: 12px 16px;
  }

  .meyvyn-page-bible-studies .study-hero .button-primary {
    flex: 1 1 100%;
    max-width: 330px;
  }
}

/* Rx Pad email field added in v1.0.20 */
#rx-form input[type="email"] {
  background: transparent;
  border: 0;
  border-bottom: 1px solid rgba(44,36,30,0.2);
  color: #2c241e;
  display: block;
  font-family: var(--serif);
  font-size: 1.05rem;
  margin: 8px 0 20px;
  padding: 10px 0;
  width: 100%;
}
.rx-email-status {
  color: #6d6055;
  font-size: 0.86rem;
  margin: 12px 0 0;
}

/* Bible study metadata helpers */
.study-meta-line {
  color: var(--cyan);
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  margin: -2px 0 12px;
  text-transform: uppercase;
}
.metadata-import {
  align-items: center;
  border: 1px dashed var(--line);
  color: var(--muted);
  cursor: pointer;
  display: inline-flex;
  font-size: 0.76rem;
  font-weight: 900;
  min-height: 46px;
  padding: 10px 14px;
  text-transform: uppercase;
}
.metadata-import input { display: none; }


.album-subtitle { color: var(--orange-soft); font-family: var(--serif); font-size: clamp(1.45rem, 3vw, 2.35rem); font-weight: 800; margin: -8px 0 12px; }
.album-source-line { color: var(--muted); font-size: 0.86rem; font-weight: 800; letter-spacing: 0.05em; text-transform: uppercase; }
.album-hero-actions { align-items: center; display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }
.meyvyn-study-guide-btn { align-items: center; background: var(--orange); border: 1px solid rgba(255,255,255,0.18); border-radius: 999px; box-shadow: 0 10px 24px rgba(0,0,0,0.28); color: #fff !important; display: inline-flex; font-weight: 900; gap: 8px; justify-content: center; letter-spacing: 0.02em; padding: 14px 22px; text-decoration: none !important; }
.meyvyn-study-guide-btn:hover { background: var(--orange-soft); color: var(--black) !important; transform: translateY(-1px); }
.study-guide-band { align-items: center; background: linear-gradient(135deg, rgba(210,98,25,0.18), rgba(255,255,255,0.04)); border-bottom: 1px solid var(--line); border-top: 1px solid var(--line); display: flex; gap: 24px; justify-content: space-between; }
.study-guide-band h2 { font-size: clamp(2rem, 5vw, 4rem); margin-bottom: 8px; }
.study-guide-band p:not(.eyebrow) { color: var(--muted); max-width: 760px; }
.album-resource-links { display: flex; flex-wrap: wrap; gap: 12px 18px; margin-top: 18px; }
.service-drive .service-mark { background: linear-gradient(135deg, #1fa463, #f4c542 50%, #4285f4); }
.service-study .service-mark { background: var(--orange); }
@media (max-width: 640px) {
  .album-hero-actions, .study-guide-band { align-items: stretch; flex-direction: column; }
  .meyvyn-study-guide-btn { width: 100%; }
}
