/*
Theme Name: CIOFF Modern (M+, Europeana & This.Design Hybrid)
Theme URI: https://cioff.ro
Author: Senior Full-Stack WordPress Developer & UI/UX Architect
Description: Temă WordPress arhitecturală pentru CIOFF® România – Partener Oficial UNESCO. Combină headerul și hero-ul compresibil M+ Museum cu secțiunile de carduri interactive This.Design (clip-path reveal, morphing pills, + action badge, Grid/List switcher) și pagini de articol Split-Stage multi-card cu scroll invizibil.
Version: 4.0.0
Requires at least: 6.0
Tested up to: 6.7
Requires PHP: 7.4
License: GPL v2 or later
Text Domain: cioff-modern
*/

/* ==========================================================================
   1. DESIGN TOKENS (WHITE GALLERY CANVAS + THIS.DESIGN & M+ TOKENS)
   ========================================================================== */
:root {
  --eu-canvas: #F8F9FA;
  --eu-surface: #FFFFFF;
  --eu-border: #EAECEF;
  --eu-border-hover: #CBD5E1;

  --mplus-charcoal: #141413;
  --eu-ink: #111827;
  --eu-ink-secondary: #374151;
  --eu-muted: #4B5563;
  --eu-meta: #6B7280;

  --accent: #991B1B;
  --accent-hover: #7F1D1D;
  --accent-light: #FEF2F2;
  --eu-blue: #004494;
  --eu-blue-hover: #003370;
  --eu-blue-light: #EFF6FF;

  --pill-bg: #F3F4F6;
  --pill-text: #1F2937;

  --font-serif: 'Newsreader', Georgia, Cambria, serif;
  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

  --eu-max-width: 1440px;
  --eu-story-width: 760px;
  --eu-wide-width: 1120px;

  --shadow-card: 0 2px 8px rgba(17, 24, 39, 0.04);
  --shadow-card-hover: 0 18px 38px -10px rgba(17, 24, 39, 0.12), 0 6px 16px -4px rgba(17, 24, 39, 0.06);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-td: cubic-bezier(0.76, 0, 0.24, 1);

  --hero-progress: 0;
  --td-drawer-h: 132px;
}

/* ==========================================================================
   2. RESET & BASE TYPOGRAPHY
   ========================================================================== */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  margin: 0;
  padding: 0;
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.65;
  color: var(--eu-ink);
  background-color: #FFFFFF;
  overflow-x: hidden;
}

img,
video,
svg {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s ease, background-color 0.2s ease, border-color 0.2s ease, opacity 0.2s ease;
}

h1, h2, h3, h4, h5, h6 {
  margin-top: 0;
  color: var(--eu-ink);
  font-weight: 700;
  line-height: 1.16;
  letter-spacing: -0.025em;
}

.eu-container {
  width: 100%;
  max-width: var(--eu-max-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: 24px;
  padding-right: 24px;
}

.eu-story-container {
  width: 100%;
  max-width: var(--eu-story-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: 24px;
  padding-right: 24px;
}

.eu-wide-container {
  width: 100%;
  max-width: var(--eu-wide-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: 24px;
  padding-right: 24px;
}

/* Invisible Scrollbar Utility */
.td-invisible-scroll,
.td-invisible-reel,
.td-split-text-pane {
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.td-invisible-scroll::-webkit-scrollbar,
.td-invisible-reel::-webkit-scrollbar,
.td-split-text-pane::-webkit-scrollbar {
  display: none;
  width: 0;
  height: 0;
}

/* ==========================================================================
   3. ARCHITECTURAL HEADER (<header id="site-header">) + INLINE SEARCH LINE
   ========================================================================== */
#site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  width: 100%;
  transition: background-color 0.3s ease-out, border-color 0.3s ease-out, box-shadow 0.3s ease-out, backdrop-filter 0.3s ease-out;
}

body.admin-bar #site-header {
  top: 32px;
}

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

/* Reading Progress Hairline at Top of Header */
.td-reading-progress {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: transparent;
  z-index: 1010;
  pointer-events: none;
}

.td-reading-progress__bar {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--accent), var(--eu-blue));
  transition: width 0.12s linear;
}

/* State 1: At Top Over Video */
#site-header.is-over-video {
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.72) 0%, rgba(0, 0, 0, 0.35) 68%, rgba(0, 0, 0, 0) 100%);
  color: #FFFFFF;
  border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

/* State 2: On Scroll > 60px or Interior Pages */
#site-header.is-scrolled,
body:not(.home):not(.front-page) #site-header {
  background-color: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  color: var(--mplus-charcoal);
  border-bottom: 1px solid #E5E7EB;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
}

/* Utility Top Bar */
.mplus-utility-bar {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border-bottom: 1px solid rgba(255, 255, 255, 0.14);
  transition: max-height 0.3s ease-out, opacity 0.25s ease-out, padding 0.3s ease-out;
  max-height: 38px;
  overflow: hidden;
}

#site-header.is-scrolled .mplus-utility-bar {
  max-height: 0;
  opacity: 0;
  border-bottom-color: transparent;
}

body:not(.home):not(.front-page) #site-header:not(.is-scrolled-deep) .mplus-utility-bar {
  max-height: 34px;
  opacity: 1;
  background-color: var(--mplus-charcoal);
  color: #FFFFFF;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.mplus-utility-bar__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 34px;
  gap: 1rem;
}

.mplus-affiliation {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.mplus-affiliation__dot {
  width: 6px;
  height: 6px;
  border-radius: 9999px;
  background-color: #EF4444;
  display: inline-block;
  flex-shrink: 0;
}

.mplus-utility-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-shrink: 0;
}

.mplus-utility-link {
  font-size: 0.7rem;
  opacity: 0.85;
}

.mplus-utility-link:hover {
  opacity: 1;
  text-decoration: underline;
}

.mplus-lang-switcher {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.72rem;
  font-weight: 700;
}

.mplus-lang-switcher .is-inactive {
  opacity: 0.55;
}

/* Main Header Bar */
.mplus-main-bar {
  height: 78px;
  transition: height 0.3s ease-out;
  display: flex;
  align-items: center;
}

#site-header.is-scrolled .mplus-main-bar {
  height: 68px;
}

.mplus-main-bar__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
  height: 100%;
}

/* Left Group: Official Wix Logo + Desktop Inline Search Line */
.mplus-header-left {
  display: flex;
  align-items: center;
  gap: 1.35rem;
  flex: 1;
  min-width: 0;
}

.mplus-brand {
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
}

.mplus-brand__logo-wrap {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background-color: #FFFFFF;
  padding: 4px 10px;
  border-radius: 10px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  border: 1px solid rgba(229, 231, 235, 0.85);
  transition: transform 0.25s ease, padding 0.25s ease;
}

.mplus-brand:hover .mplus-brand__logo-wrap {
  transform: translateY(-1px);
}

.mplus-brand__logo {
  height: 48px;
  width: auto;
  object-fit: contain;
  transition: height 0.3s ease-out;
}

#site-header.is-scrolled .mplus-brand__logo {
  height: 40px;
}

/* Desktop Inline Search Line (Left Space Next to Logo — No Modal!) */
.mplus-inline-search {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  width: 100%;
  max-width: 280px;
  height: 38px;
  padding: 0 0.75rem;
  border-radius: 9999px;
  background-color: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.32);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  transition: max-width 0.3s var(--ease-out), background-color 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.mplus-inline-search:focus-within {
  max-width: 340px;
}

#site-header.is-over-video .mplus-inline-search {
  color: #FFFFFF;
}

#site-header.is-scrolled .mplus-inline-search,
body:not(.home):not(.front-page) #site-header .mplus-inline-search {
  background-color: #F3F4F6;
  border: 1px solid #E5E7EB;
  color: var(--mplus-charcoal);
}

#site-header.is-scrolled .mplus-inline-search:focus-within,
body:not(.home):not(.front-page) #site-header .mplus-inline-search:focus-within {
  background-color: #FFFFFF;
  border-color: var(--eu-blue);
  box-shadow: 0 0 0 3px rgba(0, 68, 148, 0.12);
}

.mplus-inline-search__icon {
  flex-shrink: 0;
  opacity: 0.75;
}

.mplus-inline-search__input {
  width: 100%;
  border: none;
  background: transparent;
  color: inherit;
  font-family: var(--font-sans);
  font-size: 0.82rem;
  font-weight: 500;
  outline: none;
  padding: 0;
}

#site-header.is-over-video .mplus-inline-search__input::placeholder {
  color: rgba(255, 255, 255, 0.78);
}

#site-header.is-scrolled .mplus-inline-search__input::placeholder,
body:not(.home):not(.front-page) #site-header .mplus-inline-search__input::placeholder {
  color: #6B7280;
}

.mplus-inline-search__submit {
  background: none;
  border: none;
  color: inherit;
  font-size: 0.85rem;
  font-weight: 700;
  opacity: 0.65;
  cursor: pointer;
  padding: 0 0.2rem;
  line-height: 1;
}

.mplus-inline-search__submit:hover {
  opacity: 1;
}

/* Right Group: Navigation */
.mplus-header-right {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-shrink: 0;
}

.mplus-nav {
  display: flex;
  align-items: center;
}

.mplus-nav__list,
.mplus-nav ul.menu {
  display: flex;
  align-items: center;
  gap: 0.15rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.mplus-nav__list > li,
.mplus-nav ul.menu > li {
  position: static;
}

.mplus-main-bar__inner {
  position: relative;
}

.mplus-nav__list > li > a,
.mplus-nav ul.menu > li > a {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.5rem 0.82rem;
  font-size: 0.86rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  border-radius: 8px;
  color: inherit;
  white-space: nowrap;
}

.td-nav-caret {
  font-size: 0.72em;
  opacity: 0.75;
  transition: transform 0.25s ease;
}

.mplus-nav li:hover > a .td-nav-caret {
  transform: rotate(180deg);
}

#site-header.is-over-video .mplus-nav__list > li > a:hover,
#site-header.is-over-video .mplus-nav ul.menu > li > a:hover {
  background-color: rgba(255, 255, 255, 0.15);
  color: #FFFFFF;
}

#site-header.is-scrolled .mplus-nav__list > li > a:hover,
#site-header.is-scrolled .mplus-nav ul.menu > li > a:hover,
body:not(.home):not(.front-page) #site-header .mplus-nav__list > li > a:hover,
body:not(.home):not(.front-page) #site-header .mplus-nav ul.menu > li > a:hover {
  background-color: #F3F4F6;
  color: var(--accent);
}

/* ==========================================================================
   3B. ARCHITECTURAL 3-ZONE MEGA-MENU (.td-megamenu)
   Zone 1: Large Photo Hero Card | Zone 2: Menu Link Cards | Zone 3: 2 Article Cards
   ========================================================================== */
.td-megamenu {
  position: absolute;
  top: calc(100% + 4px);
  left: 24px;
  right: 24px;
  background-color: #FFFFFF;
  color: var(--mplus-charcoal);
  border: 1px solid #E5E7EB;
  border-radius: 20px;
  box-shadow: 0 28px 65px -12px rgba(17, 24, 39, 0.24), 0 8px 20px -6px rgba(17, 24, 39, 0.08);
  padding: 1.35rem;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(10px);
  transition: opacity 0.26s var(--ease-out), transform 0.26s var(--ease-out), visibility 0.26s ease;
  z-index: 1250;
}

/* Invisible hover bridge so moving cursor from nav link to mega-menu never drops hover */
.td-megamenu::before {
  content: "";
  position: absolute;
  top: -18px;
  left: 0;
  right: 0;
  height: 18px;
}

.mplus-nav li.has-td-megamenu:hover > .td-megamenu,
.mplus-nav li.has-td-megamenu:focus-within > .td-megamenu {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0);
}

.td-megamenu__inner {
  display: grid;
  grid-template-columns: 320px 1.35fr 1fr;
  gap: 1.35rem;
  align-items: stretch;
}

/* Zone 1: Large Feature Photo Card */
.td-megamenu__hero {
  position: relative;
  border-radius: 15px;
  overflow: hidden;
  min-height: 290px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 1.35rem;
  background-color: #141413;
  color: #FFFFFF;
  text-decoration: none;
}

.td-megamenu__hero img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.55s var(--ease-td);
}

.td-megamenu__hero:hover img {
  transform: scale(1.07);
}

.td-megamenu__hero-scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(20, 20, 19, 0.15) 0%, rgba(20, 20, 19, 0.9) 100%);
  z-index: 1;
}

.td-megamenu__hero-content {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.45rem;
}

.td-megamenu__hero-title {
  font-family: var(--font-sans);
  font-size: 1.18rem;
  font-weight: 800;
  color: #FFFFFF;
  margin: 0.15rem 0 0;
  line-height: 1.25;
}

.td-megamenu__hero-desc {
  font-size: 0.78rem;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.82);
  margin: 0;
}

.td-megamenu__hero-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin-top: 0.4rem;
  padding: 0.42rem 0.9rem;
  border-radius: 9999px;
  background-color: #FFFFFF;
  color: var(--mplus-charcoal);
  font-size: 0.75rem;
  font-weight: 800;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.td-megamenu__hero:hover .td-megamenu__hero-btn {
  background-color: var(--accent);
  color: #FFFFFF;
}

/* Zone 2: Menu Link Cards */
.td-megamenu__menu-col,
.td-megamenu__articles-col {
  display: flex;
  flex-direction: column;
}

.td-megamenu__col-header {
  font-size: 0.7rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  color: var(--eu-muted);
  padding-bottom: 0.55rem;
  margin-bottom: 0.75rem;
  border-bottom: 1px solid var(--eu-border);
}

.td-megamenu__cards-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.65rem;
  flex: 1;
}

.td-megamenu__link-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 0.8rem 0.95rem;
  border-radius: 12px;
  background-color: #F8F9FA;
  border: 1px solid #EAECEF;
  color: var(--eu-ink);
  text-decoration: none;
  transition: all 0.22s ease;
}

.td-megamenu__link-card:hover {
  background-color: #FFFFFF;
  border-color: var(--eu-blue);
  box-shadow: 0 8px 20px rgba(0, 68, 148, 0.08);
  transform: translateY(-2px);
}

.td-megamenu__link-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.35rem;
}

.td-megamenu__link-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.1rem 0.45rem;
  border-radius: 5px;
  background-color: #E5E7EB;
  color: var(--mplus-charcoal);
  font-size: 0.66rem;
  font-weight: 800;
}

.td-megamenu__link-card:hover .td-megamenu__link-badge {
  background-color: var(--accent);
  color: #FFFFFF;
}

.td-megamenu__link-arrow {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--eu-muted);
  transition: transform 0.2s ease, color 0.2s ease;
}

.td-megamenu__link-card:hover .td-megamenu__link-arrow {
  transform: translateX(3px);
  color: var(--accent);
}

.td-megamenu__link-title {
  display: block;
  font-size: 0.86rem;
  font-weight: 800;
  color: var(--eu-ink);
  margin-bottom: 0.15rem;
  line-height: 1.25;
}

.td-megamenu__link-desc {
  display: block;
  font-size: 0.73rem;
  color: var(--eu-muted);
  line-height: 1.35;
}

/* Zone 3: 2 Dynamic Article Cards */
.td-megamenu__articles-list {
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
  flex: 1;
}

.td-megamenu__article-card {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.65rem;
  border-radius: 12px;
  background-color: #F8F9FA;
  border: 1px solid #EAECEF;
  text-decoration: none;
  color: var(--eu-ink);
  flex: 1;
  transition: all 0.22s ease;
}

.td-megamenu__article-card:hover {
  background-color: #FFFFFF;
  border-color: var(--accent);
  box-shadow: 0 10px 24px rgba(153, 27, 27, 0.08);
  transform: translateY(-2px);
}

.td-megamenu__article-thumb {
  width: 96px;
  height: 76px;
  border-radius: 9px;
  overflow: hidden;
  flex-shrink: 0;
  background-color: #141413;
}

.td-megamenu__article-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.td-megamenu__article-card:hover .td-megamenu__article-thumb img {
  transform: scale(1.08);
}

.td-megamenu__article-body {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  min-width: 0;
}

.td-megamenu__article-meta {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  flex-wrap: wrap;
}

.td-megamenu__article-meta .td-morph-pill {
  height: 20px;
  padding: 0 0.45rem;
  font-size: 0.62rem;
}

.td-megamenu__article-date {
  font-size: 0.68rem;
  color: var(--eu-meta);
  font-weight: 600;
}

.td-megamenu__article-title {
  font-size: 0.83rem;
  font-weight: 800;
  line-height: 1.3;
  color: var(--eu-ink);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.td-megamenu__article-card:hover .td-megamenu__article-title {
  color: var(--accent);
}

/* Mobile Toggle Button */
.mplus-icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 9999px;
  border: 1px solid currentColor;
  background: transparent;
  color: inherit;
  cursor: pointer;
}

.mplus-mobile-toggle {
  display: none;
}

/* Tier 3: Mobile Sub-Header Search Line Extension (Visible on Mobile/Tablet <= 960px) */
.mplus-mobile-search-ext {
  display: none;
  width: 100%;
  padding: 0.45rem 0;
  border-top: 1px solid rgba(255, 255, 255, 0.16);
  background-color: rgba(20, 20, 19, 0.55);
  backdrop-filter: blur(10px);
}

#site-header.is-scrolled .mplus-mobile-search-ext,
body:not(.home):not(.front-page) #site-header .mplus-mobile-search-ext {
  background-color: #F8F9FA;
  border-top: 1px solid #E5E7EB;
  color: var(--mplus-charcoal);
}

.mplus-mobile-search-ext__form {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  width: 100%;
  background-color: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 8px;
  padding: 0.35rem 0.65rem;
}

#site-header.is-scrolled .mplus-mobile-search-ext__form,
body:not(.home):not(.front-page) #site-header .mplus-mobile-search-ext__form {
  background-color: #FFFFFF;
  border: 1px solid #D1D5DB;
}

.mplus-mobile-search-ext__icon {
  flex-shrink: 0;
  opacity: 0.7;
}

.mplus-mobile-search-ext__input {
  flex: 1;
  border: none;
  background: transparent;
  color: inherit;
  font-family: var(--font-sans);
  font-size: 0.85rem;
  outline: none;
}

#site-header.is-over-video .mplus-mobile-search-ext__input::placeholder {
  color: rgba(255, 255, 255, 0.8);
}

.mplus-mobile-search-ext__btn {
  background-color: var(--accent);
  color: #FFFFFF;
  border: none;
  border-radius: 6px;
  padding: 0.3rem 0.7rem;
  font-size: 0.75rem;
  font-weight: 700;
  cursor: pointer;
}

/* Non-homepage top offset */
body:not(.home):not(.front-page) {
  padding-top: 112px;
}

/* ==========================================================================
   4. THE COMPRESSING VIDEO HERO (<section id="hero-stage">)
   ========================================================================== */
#hero-stage {
  position: relative;
  width: 100%;
  padding-top: calc(var(--hero-progress, 0) * 28px);
  padding-bottom: 16px;
  background-color: #FFFFFF;
}

.hero-stage__frame {
  position: relative;
  width: 100%;
  max-width: calc(100vw - (var(--hero-progress, 0) * (100vw - 1440px)));
  height: calc(92vh - (var(--hero-progress, 0) * 14vh));
  min-height: 540px;
  max-height: 920px;
  margin-left: auto;
  margin-right: auto;
  border-radius: calc(var(--hero-progress, 0) * 18px);
  overflow: hidden;
  background-color: var(--mplus-charcoal);
  box-shadow: 0 20px 50px rgba(17, 24, 39, calc(var(--hero-progress, 0) * 0.14));
  will-change: max-width, height, border-radius;
}

@media (max-width: 1480px) {
  .hero-stage__frame {
    max-width: calc(100vw - (var(--hero-progress, 0) * 48px));
  }
}

.hero-stage__media,
.hero-stage__video,
.hero-stage__poster {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.hero-stage__scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(20, 20, 19, 0.36) 0%,
    rgba(20, 20, 19, 0.14) 42%,
    rgba(20, 20, 19, 0.86) 100%
  );
  z-index: 1;
}

.hero-stage__overlay {
  position: relative;
  z-index: 2;
  width: 100%;
  height: 100%;
  max-width: var(--eu-max-width);
  margin: 0 auto;
  padding: clamp(2rem, 5vw, 4.25rem);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}

.hero-stage__content {
  max-width: 840px;
  color: #FFFFFF;
}

.hero-stage__headline {
  font-family: var(--font-sans);
  font-size: clamp(2.2rem, 4.4vw, 3.85rem);
  font-weight: 800;
  color: #FFFFFF;
  line-height: 1.07;
  letter-spacing: -0.03em;
  margin-bottom: 1.1rem;
}

.hero-stage__subheadline {
  font-size: clamp(1rem, 1.3vw, 1.18rem);
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.88);
  max-width: 680px;
  margin-bottom: 1.85rem;
}

.hero-stage__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.85rem;
}

.mplus-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.82rem 1.55rem;
  font-size: 0.88rem;
  font-weight: 700;
  border-radius: 9999px;
  cursor: pointer;
  transition: all 0.25s ease;
  text-decoration: none;
}

.mplus-btn--primary {
  background-color: #FFFFFF;
  color: var(--mplus-charcoal);
  border: 1px solid #FFFFFF;
}

.mplus-btn--primary:hover {
  background-color: var(--accent);
  border-color: var(--accent);
  color: #FFFFFF;
}

.mplus-btn--glass {
  background-color: rgba(255, 255, 255, 0.14);
  backdrop-filter: blur(8px);
  color: #FFFFFF;
  border: 1px solid rgba(255, 255, 255, 0.35);
}

.mplus-btn--glass:hover {
  background-color: rgba(255, 255, 255, 0.26);
  color: #FFFFFF;
}

.mplus-btn--blue {
  background-color: var(--eu-blue);
  color: #FFFFFF;
  border: 1px solid var(--eu-blue);
}

.mplus-btn--blue:hover {
  background-color: var(--accent);
  border-color: var(--accent);
  color: #FFFFFF;
}

.hero-stage__video-control {
  position: absolute;
  right: clamp(1.5rem, 4vw, 3.5rem);
  bottom: clamp(1.5rem, 4vw, 3.5rem);
  z-index: 3;
  background: rgba(20, 20, 19, 0.68);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.28);
  color: #FFFFFF;
  border-radius: 9999px;
  padding: 0.45rem 0.95rem;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: pointer;
}

/* ==========================================================================
   5. THIS.DESIGN MORPHING PILLS, SUBBAR & SECTION ARCHITECTURE (ON WHITE)
   ========================================================================== */
.td-home-canvas {
  background-color: #FFFFFF;
}

/* Morphing Pills (this.design Vl signature: rounded-md -> hover:rounded-2xl duration-500) */
.td-morph-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.38rem;
  height: 30px;
  padding: 0 0.78rem;
  font-size: 0.73rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  border-radius: 7px;
  background-color: #F3F4F6;
  color: #1F2937;
  white-space: nowrap;
  transition: border-radius 0.45s var(--ease-out), background-color 0.3s ease, color 0.3s ease, transform 0.25s ease;
}

.td-morph-pill:hover {
  border-radius: 18px;
}

.td-morph-pill--flag {
  background-color: var(--accent);
  color: #FFFFFF;
}

.td-morph-pill--blue {
  background-color: var(--eu-blue);
  color: #FFFFFF;
}

.td-morph-pill--index {
  background-color: rgba(20, 20, 19, 0.78);
  color: #FFFFFF;
  backdrop-filter: blur(6px);
  font-family: monospace;
  font-size: 0.72rem;
}

.td-morph-pill--muted {
  background-color: #F3F4F6;
  color: #4B5563;
}

.td-morph-pill__star {
  flex-shrink: 0;
  color: #FBBF24;
}

/* Sticky Section Jump & View Mode Bar */
.td-sticky-subbar {
  position: sticky;
  top: 68px;
  z-index: 90;
  background-color: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-top: 1px solid var(--eu-border);
  border-bottom: 1px solid var(--eu-border);
  padding: 0.65rem 0;
}

.td-sticky-subbar__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.td-sticky-subbar__jumps {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  overflow-x: auto;
  scrollbar-width: none;
}

.td-sticky-subbar__jumps::-webkit-scrollbar {
  display: none;
}

.td-jump-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.42rem 0.9rem;
  border-radius: 9999px;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--eu-ink-secondary);
  background-color: #F3F4F6;
  border: 1px solid transparent;
  white-space: nowrap;
  transition: all 0.22s ease;
}

.td-jump-pill:hover,
.td-jump-pill.is-active {
  background-color: var(--mplus-charcoal);
  color: #FFFFFF;
}

.td-jump-pill__num {
  font-size: 0.7rem;
  opacity: 0.65;
  font-weight: 800;
}

.td-jump-pill__count {
  font-size: 0.68rem;
  padding: 0.1rem 0.45rem;
  border-radius: 9999px;
  background-color: rgba(255, 255, 255, 0.18);
}

/* This.Design 9-Dot Grid / List View Switcher */
.td-view-switcher {
  display: inline-flex;
  align-items: center;
  background-color: #F3F4F6;
  padding: 3px;
  border-radius: 9999px;
  border: 1px solid var(--eu-border);
}

.td-view-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.38rem 0.85rem;
  border-radius: 9999px;
  border: none;
  background: transparent;
  color: var(--eu-muted);
  font-family: var(--font-sans);
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.22s ease;
}

.td-view-btn.is-active {
  background-color: var(--mplus-charcoal);
  color: #FFFFFF;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.14);
}

.td-dots-icon {
  display: grid;
  grid-template-columns: repeat(3, 3px);
  grid-template-rows: repeat(3, 3px);
  gap: 2px;
}

.td-dots-icon i {
  display: block;
  width: 3px;
  height: 3px;
  border-radius: 1px;
  background-color: currentColor;
}

.td-lines-icon {
  display: flex;
  flex-direction: column;
  gap: 2.5px;
  width: 13px;
}

.td-lines-icon i {
  display: block;
  width: 100%;
  height: 2px;
  background-color: currentColor;
  border-radius: 1px;
}

/* Section Wrappers */
.td-section {
  padding: 4.5rem 0;
  background-color: #FFFFFF;
  border-bottom: 1px solid var(--eu-border);
}

.td-section--alt {
  background-color: #F8F9FA;
}

.td-section__head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1.5rem;
  flex-wrap: wrap;
  margin-bottom: 2.25rem;
}

.td-section__eyebrow-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-bottom: 0.65rem;
}

.td-section__index {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 30px;
  padding: 0 0.7rem;
  border-radius: 7px;
  background-color: var(--mplus-charcoal);
  color: #FFFFFF;
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.td-section__title {
  font-family: var(--font-sans);
  font-size: clamp(1.85rem, 3vw, 2.65rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--eu-ink);
  margin: 0 0 0.35rem;
}

.td-section__desc {
  font-size: 0.98rem;
  color: var(--eu-muted);
  max-width: 680px;
  margin: 0;
}

.td-pill-cta {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.65rem 1.25rem;
  border-radius: 9999px;
  background-color: var(--mplus-charcoal);
  color: #FFFFFF;
  font-size: 0.84rem;
  font-weight: 700;
  transition: all 0.25s ease;
}

.td-pill-cta:hover {
  background-color: var(--accent);
  color: #FFFFFF;
  transform: translateY(-2px);
}

/* ==========================================================================
   6. THIS.DESIGN INTERACTIVE CARDS (.td-card: CLIP-PATH REVEAL + "+" ACTION)
   ========================================================================== */
.td-cards-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.td-cards-grid--3 {
  grid-template-columns: repeat(3, 1fr);
}

/* Individual This.Design Card on White Theme */
.td-card {
  position: relative;
  border-radius: 16px;
  background-color: #FFFFFF;
  border: 1px solid #E5E7EB;
  overflow: hidden;
  box-shadow: var(--shadow-card);
  transition: border-color 0.35s ease, box-shadow 0.35s ease, transform 0.35s ease;
}

.td-card.aspect-3-4 {
  aspect-ratio: 3 / 4.05;
}

.td-card.aspect-4-5 {
  aspect-ratio: 4 / 4.85;
}

.td-card:hover {
  border-color: #CBD5E1;
  box-shadow: var(--shadow-card-hover);
}

.td-card__link {
  position: relative;
  display: block;
  width: 100%;
  height: 100%;
  color: var(--eu-ink);
  text-decoration: none;
}

/* Top-Left Badges */
.td-card__top-badges {
  position: absolute;
  top: 12px;
  left: 12px;
  right: 60px;
  z-index: 4;
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  pointer-events: none;
}

/* Top-Right "+" Rotating Circle Button (this.design Mc signature) */
.td-card__plus {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 4;
  width: 40px;
  height: 40px;
  border-radius: 9999px;
  background-color: rgba(20, 20, 19, 0.86);
  backdrop-filter: blur(6px);
  border: 1px solid rgba(255, 255, 255, 0.22);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 0;
  transition: transform 0.45s var(--ease-td), background-color 0.3s ease;
}

.td-card:hover .td-card__plus,
.td-visual-card:hover .td-card__plus,
.td-media-bento-item:hover .td-card__plus {
  transform: scale(1.08) rotate(90deg);
  background-color: var(--accent);
}

.td-card__plus-bar {
  position: absolute;
  width: 16px;
  height: 2px;
  background-color: #FFFFFF;
  border-radius: 1px;
}

.td-card__plus-bar--vert {
  transform: rotate(90deg);
}

/* Clip-Path Image Container (Shrinks from bottom on hover just like this.design Zt!) */
.td-card__media-clip {
  position: absolute;
  inset: 0;
  z-index: 2;
  background-color: #141413;
  clip-path: inset(0px 0px 0px 0px round 15px);
  transition: clip-path 0.52s var(--ease-td);
  overflow: hidden;
}

.td-card:hover .td-card__media-clip {
  clip-path: inset(0px 0px var(--td-drawer-h, 134px) 0px round 15px);
}

.td-card__media-clip img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.55s var(--ease-td);
}

.td-card__media-clip.is-logo-fallback {
  background: radial-gradient(circle at center, #FFFFFF 0%, #F1F5F9 100%);
}

.td-card__media-clip.is-logo-fallback img {
  object-fit: contain;
  padding: 2.75rem;
}

.td-card:hover .td-card__media-clip img {
  transform: scale(1.08);
}

/* Resting Title Overlay (Visible before hover, fades smoothly on hover) */
.td-card__resting-gradient {
  position: absolute;
  inset: auto 0 0 0;
  padding: 3rem 1.15rem 1.15rem;
  background: linear-gradient(180deg, rgba(17, 24, 39, 0) 0%, rgba(17, 24, 39, 0.88) 100%);
  color: #FFFFFF;
  transition: opacity 0.35s ease, transform 0.35s ease;
}

.td-card:hover .td-card__resting-gradient {
  opacity: 0;
  transform: translateY(-10px);
}

.td-card__resting-date {
  display: block;
  font-size: 0.72rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.78);
  margin-bottom: 0.25rem;
}

.td-card__resting-title {
  font-family: var(--font-sans);
  font-size: 1.05rem;
  font-weight: 700;
  line-height: 1.3;
  color: #FFFFFF;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Bottom Reveal Drawer (this.design Jl signature: revealed under clipped image on white surface) */
.td-card__drawer {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: var(--td-drawer-h, 134px);
  padding: 12px 14px 14px;
  background-color: #FFFFFF;
  z-index: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transform: translateY(30%);
  opacity: 0;
  transition: transform 0.52s var(--ease-td), opacity 0.45s ease;
}

.td-card:hover .td-card__drawer {
  transform: translateY(0);
  opacity: 1;
}

.td-card__drawer-pills {
  display: flex;
  align-items: center;
  gap: 5px;
  overflow: hidden;
  flex-wrap: nowrap;
}

.td-card__drawer-pills .td-morph-pill {
  height: 24px;
  padding: 0 0.55rem;
  font-size: 0.68rem;
}

.td-card__drawer-Grant {
  font-size: 0.92rem;
  line-height: 1.32;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.td-card__title-main {
  font-weight: 800;
  color: var(--eu-ink);
}

.td-card__arrow {
  color: var(--accent);
  font-weight: 700;
  margin: 0 0.25rem;
}

.td-card__tagline {
  color: var(--eu-muted);
  font-weight: 500;
  font-size: 0.84rem;
}

/* ==========================================================================
   6B. THIS.DESIGN LIST VIEW MODE (.td-cards-grid.is-list-view)
   ========================================================================== */
.td-cards-grid.is-list-view {
  grid-template-columns: 1fr;
  gap: 12px;
}

.td-cards-grid.is-list-view .td-card {
  aspect-ratio: auto !important;
  height: auto;
  padding: 12px;
  border-radius: 14px;
}

.td-cards-grid.is-list-view .td-card__link {
  display: flex;
  align-items: center;
  gap: 1.35rem;
}

.td-cards-grid.is-list-view .td-card__top-badges {
  display: none;
}

.td-cards-grid.is-list-view .td-card__media-clip {
  position: relative;
  width: 214px;
  height: 120px;
  flex-shrink: 0;
  border-radius: 10px;
  clip-path: none !important;
}

.td-cards-grid.is-list-view .td-card__resting-gradient {
  display: none;
}

.td-cards-grid.is-list-view .td-card__drawer {
  position: relative;
  height: auto;
  padding: 0;
  opacity: 1;
  transform: none;
  flex: 1;
  gap: 0.55rem;
}

.td-cards-grid.is-list-view .td-card__drawer-Grant {
  font-size: 1.15rem;
  -webkit-line-clamp: 2;
}

/* ==========================================================================
   7. HORIZONTAL INVISIBLE-SCROLL REEL (.td-invisible-reel)
   ========================================================================== */
.td-invisible-reel {
  display: flex;
  gap: 20px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding: 4px 2px 12px;
  cursor: grab;
  user-select: none;
}

.td-invisible-reel.is-dragging {
  cursor: grabbing;
  scroll-snap-type: none;
}

.td-invisible-reel__item {
  flex: 0 0 320px;
  scroll-snap-align: start;
}

.td-invisible-reel__item--compact {
  flex: 0 0 265px;
}

.td-reel-nav-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 9999px;
  border: 1px solid var(--eu-border);
  background-color: #FFFFFF;
  color: var(--eu-ink);
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.td-reel-nav-btn:hover {
  background-color: var(--mplus-charcoal);
  border-color: var(--mplus-charcoal);
  color: #FFFFFF;
}

/* ==========================================================================
   8. HOMEPAGE ASYMMETRIC BENTO MULTI-CARD SHOWCASE (.td-bento-showcase)
   ========================================================================== */
.td-bento-showcase {
  display: grid;
  grid-template-columns: 1.25fr 1fr;
  grid-template-rows: auto auto;
  gap: 22px;
}

.td-bento-card {
  border-radius: 18px;
  padding: clamp(1.5rem, 3vw, 2.35rem);
  display: flex;
  flex-direction: column;
  gap: 1.1rem;
  border: 1px solid var(--eu-border);
  box-shadow: var(--shadow-card);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.td-bento-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-card-hover);
}

.td-bento-card--tall {
  grid-row: span 2;
}

.td-bento-card--dark {
  background-color: var(--mplus-charcoal);
  color: #FFFFFF;
  border-color: #27272A;
}

.td-bento-card--white {
  background-color: #FFFFFF;
  color: var(--eu-ink);
}

.td-bento-card--accent {
  background: linear-gradient(135deg, #991B1B 0%, #004494 100%);
  color: #FFFFFF;
  border: none;
}

.td-bento-card__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.td-bento-card__logo {
  background-color: #FFFFFF;
  padding: 5px 10px;
  border-radius: 10px;
  height: 46px;
  width: auto;
  object-fit: contain;
}

.td-bento-card__title {
  font-family: var(--font-sans);
  font-size: clamp(1.35rem, 2.2vw, 1.85rem);
  font-weight: 800;
  color: inherit;
  margin: 0;
}

.td-bento-card__text {
  font-size: 0.95rem;
  line-height: 1.65;
  color: rgba(255, 255, 255, 0.84);
  margin: 0 0 0.5rem;
}

.td-bento-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  padding: 1.1rem 0;
  border-top: 1px solid rgba(255, 255, 255, 0.14);
  border-bottom: 1px solid rgba(255, 255, 255, 0.14);
}

.td-bento-stat strong {
  display: block;
  font-size: 1.6rem;
  font-weight: 800;
  color: #FFFFFF;
}

.td-bento-stat span {
  font-size: 0.76rem;
  color: rgba(255, 255, 255, 0.7);
}

.td-bento-card__actions {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-top: auto;
}

/* ==========================================================================
   9. SINGLE ARTICLE & PAGE: SPLIT-STAGE MULTI-CARD WORKBENCH + INVISIBLE SCROLL
   ========================================================================== */
.td-single-canvas {
  background-color: #F8F9FA;
  min-height: 100vh;
}

/* Top Architectural Command Bar */
.td-article-commandbar {
  position: sticky;
  top: 68px;
  z-index: 95;
  background-color: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--eu-border);
  padding: 0.6rem 0;
}

.td-article-commandbar__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.td-article-commandbar__left {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  min-width: 0;
}

/* This.Design Circular Back Button */
.td-back-circle {
  width: 42px;
  height: 42px;
  border-radius: 9999px;
  background-color: var(--mplus-charcoal);
  color: #FFFFFF;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: transform 0.25s ease, background-color 0.25s ease;
}

.td-back-circle:hover {
  background-color: var(--accent);
  color: #FFFFFF;
  transform: translateX(-3px);
}

.td-command-breadcrumbs {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--eu-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.td-command-breadcrumbs a {
  color: var(--eu-blue);
}

.td-command-breadcrumbs__current {
  color: var(--eu-ink);
  font-weight: 700;
  overflow: hidden;
  text-overflow: ellipsis;
}

.td-article-commandbar__right {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.td-reading-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.35rem 0.75rem;
  border-radius: 9999px;
  background-color: #F3F4F6;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--eu-ink);
}

.td-reading-pill__dot {
  width: 7px;
  height: 7px;
  border-radius: 9999px;
  background-color: #10B981;
}

.td-font-controls {
  display: inline-flex;
  align-items: center;
  background-color: #F3F4F6;
  border-radius: 9999px;
  padding: 2px;
}

.td-tool-btn {
  border: 1px solid var(--eu-border);
  background-color: #FFFFFF;
  color: var(--eu-ink);
  font-family: var(--font-sans);
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.35rem 0.7rem;
  border-radius: 9999px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.td-font-controls .td-tool-btn {
  border: none;
  background: transparent;
  padding: 0.3rem 0.55rem;
}

.td-tool-btn:hover {
  background-color: var(--mplus-charcoal);
  color: #FFFFFF;
}

/* Split-Stage Section & Grid */
.td-split-stage-section {
  padding: 2rem 0 4rem;
}

.td-split-stage {
  display: grid;
  grid-template-columns: minmax(420px, 47%) minmax(0, 53%);
  gap: 26px;
  align-items: start;
}

.td-split-stage.is-expanded {
  grid-template-columns: 1fr;
  max-width: 960px;
  margin: 0 auto;
}

/* LEFT COLUMN: STICKY NARRATIVE & TEXT DECK WITH INVISIBLE SCROLL */
.td-split-text-pane {
  position: sticky;
  top: 132px;
  max-height: calc(100vh - 150px);
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 18px;
  padding-right: 2px;
  scroll-behavior: smooth;
}

.td-split-stage.is-expanded .td-split-text-pane {
  position: static;
  max-height: none;
  overflow-y: visible;
}

/* Subtle Vertical Reading Progress Rail on Left Edge of Text Deck */
.td-pane-scroll-rail {
  position: sticky;
  top: 0;
  left: 0;
  width: 100%;
  height: 3px;
  background-color: rgba(0, 0, 0, 0.05);
  border-radius: 9999px;
  overflow: hidden;
  z-index: 10;
  flex-shrink: 0;
}

.td-pane-scroll-rail__fill {
  width: 0%;
  height: 100%;
  background: linear-gradient(90deg, var(--accent), var(--eu-blue));
  transition: width 0.1s linear;
}

/* Stacked Cards inside the Left Text Deck */
.td-deck-card {
  background-color: #FFFFFF;
  border: 1px solid var(--eu-border);
  border-radius: 18px;
  padding: clamp(1.5rem, 2.6vw, 2.25rem);
  box-shadow: var(--shadow-card);
}

.td-deck-card__pills {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  flex-wrap: wrap;
  margin-bottom: 1rem;
}

.td-deck-card__title {
  font-family: var(--font-serif);
  font-size: clamp(1.75rem, 2.6vw, 2.45rem);
  line-height: 1.15;
  color: var(--eu-ink);
  margin: 0 0 1.25rem;
}

.td-deck-card__author-bar {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding-top: 1rem;
  border-top: 1px solid var(--eu-border);
  flex-wrap: wrap;
}

.td-deck-card__logo {
  height: 38px;
  width: auto;
  object-fit: contain;
  background: #F8F9FA;
  padding: 4px 8px;
  border-radius: 8px;
  border: 1px solid var(--eu-border);
}

.td-deck-card__author-meta {
  display: flex;
  flex-direction: column;
  font-size: 0.8rem;
  line-height: 1.35;
  flex: 1;
}

.td-deck-card__author-meta span {
  color: var(--eu-muted);
  font-size: 0.74rem;
}

.td-scroll-hint-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.3rem 0.7rem;
  border-radius: 9999px;
  background-color: var(--eu-blue-light);
  color: var(--eu-blue);
  font-size: 0.72rem;
  font-weight: 700;
  animation: tdPulse 2.2s infinite ease-in-out;
}

@keyframes tdPulse {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(3px); }
}

.td-reader-chapters {
  padding: 0.9rem 1.1rem;
  border-radius: 12px;
  background-color: #F8F9FA;
  border: 1px solid var(--eu-border);
  margin-bottom: 1.5rem;
}

.td-reader-chapters__label {
  display: block;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--eu-muted);
  margin-bottom: 0.5rem;
}

.td-reader-chapters__list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

/* Drop-cap & Refined Story Reader Typography */
.td-entry-content {
  font-size: 1.04rem;
  line-height: 1.82;
  color: var(--eu-ink);
  transition: font-size 0.2s ease;
}

.td-entry-content > p:first-of-type::first-letter {
  float: left;
  font-family: var(--font-serif);
  font-size: 3.35rem;
  line-height: 0.86;
  padding-top: 4px;
  padding-right: 10px;
  padding-bottom: 2px;
  color: var(--accent);
  font-weight: 700;
}

.td-deck-card__share-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

/* ==========================================================================
   9B. RIGHT COLUMN: MULTI-CARD VISUAL BENTO & MEDIA STREAM (.td-split-cards-pane)
   ========================================================================== */
.td-split-cards-pane {
  display: flex;
  flex-direction: column;
  gap: 22px;
  min-width: 0;
}

/* Visual Card A: Hero Visual Card */
.td-visual-card {
  position: relative;
  border-radius: 18px;
  overflow: hidden;
  background-color: var(--mplus-charcoal);
  border: 1px solid var(--eu-border);
  box-shadow: var(--shadow-card);
}

.td-visual-card__badges {
  position: absolute;
  top: 14px;
  left: 14px;
  z-index: 3;
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.td-visual-card__media {
  position: relative;
  aspect-ratio: 16 / 11;
  overflow: hidden;
  background-color: #141413;
}

.td-visual-card.is-logo-stage .td-visual-card__media {
  background: radial-gradient(circle at center, #FFFFFF 0%, #E2E8F0 100%);
}

.td-visual-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  cursor: zoom-in;
  transition: transform 0.55s var(--ease-td);
}

.td-visual-card.is-logo-stage .td-visual-card__media img {
  object-fit: contain;
  padding: 3rem;
}

.td-visual-card:hover .td-visual-card__media img {
  transform: scale(1.05);
}

.td-visual-card__caption-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.85rem 1.25rem;
  background-color: #FFFFFF;
  color: var(--eu-ink-secondary);
  font-size: 0.82rem;
  font-weight: 600;
  border-top: 1px solid var(--eu-border);
}

.td-visual-card__zoom-hint {
  color: var(--eu-blue);
  font-size: 0.76rem;
  font-weight: 700;
  white-space: nowrap;
}

/* Visual Card B: Video Card */
.td-visual-card--video {
  background-color: #141413;
  padding: 1.15rem;
}

.td-visual-card__header-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.85rem;
}

.td-visual-card__video-frame {
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: 12px;
  overflow: hidden;
}

.td-visual-card__video-frame iframe {
  width: 100%;
  height: 100%;
  border: 0;
  margin: 0;
}

/* Visual Card C: Multi-Image Bento Grid */
.td-bento-gallery-block {
  background-color: #FFFFFF;
  border: 1px solid var(--eu-border);
  border-radius: 18px;
  padding: 1.35rem;
  box-shadow: var(--shadow-card);
}

.td-bento-gallery-block__head {
  margin-bottom: 1rem;
}

.td-bento-gallery-block__title {
  font-size: 1.1rem;
  margin: 0.45rem 0 0;
}

.td-media-bento-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

.td-media-bento-item {
  position: relative;
  margin: 0;
  border-radius: 14px;
  overflow: hidden;
  aspect-ratio: 4 / 3.4;
  background-color: #141413;
  border: 1px solid var(--eu-border);
}

.td-media-bento-item--featured {
  grid-column: span 2;
  aspect-ratio: 16 / 9;
}

.td-media-bento-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  cursor: zoom-in;
  transition: transform 0.5s var(--ease-td);
}

.td-media-bento-item:hover img {
  transform: scale(1.06);
}

.td-media-bento-item__num {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 3;
  background: rgba(20, 20, 19, 0.78);
  color: #FFFFFF;
  font-size: 0.7rem;
  font-weight: 800;
  padding: 0.2rem 0.55rem;
  border-radius: 6px;
}

.td-media-bento-item__cap {
  position: absolute;
  inset: auto 0 0 0;
  padding: 1.5rem 0.85rem 0.65rem;
  background: linear-gradient(180deg, transparent, rgba(0, 0, 0, 0.82));
  color: #FFFFFF;
  font-size: 0.76rem;
  pointer-events: none;
}

/* Visual Card D: Horizontal Invisible-Scroll Reel Card */
.td-reel-card {
  background-color: #FFFFFF;
  border: 1px solid var(--eu-border);
  border-radius: 18px;
  padding: 1.35rem;
  box-shadow: var(--shadow-card);
}

.td-reel-card__head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}

.td-reel-card__title {
  font-size: 1.1rem;
  margin: 0.45rem 0 0;
}

.td-photo-reel-card {
  position: relative;
  flex: 0 0 240px;
  aspect-ratio: 4 / 3;
  border-radius: 12px;
  overflow: hidden;
  scroll-snap-align: start;
  background: #141413;
}

.td-photo-reel-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  cursor: zoom-in;
  transition: transform 0.4s ease;
}

.td-photo-reel-card:hover img {
  transform: scale(1.06);
}

.td-photo-reel-card__badge {
  position: absolute;
  bottom: 8px;
  right: 8px;
  background: rgba(20, 20, 19, 0.8);
  color: #FFFFFF;
  font-size: 0.68rem;
  font-weight: 700;
  padding: 0.2rem 0.5rem;
  border-radius: 9999px;
}

/* Visual Card E: 2-Column Institutional & Next/Prev Pair */
.td-article-bento-pair {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px;
}

.td-adj-links {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.td-adj-tile {
  display: block;
  padding: 0.75rem 0.95rem;
  border-radius: 12px;
  background-color: #F8F9FA;
  border: 1px solid var(--eu-border);
  transition: all 0.2s ease;
}

.td-adj-tile:hover {
  border-color: var(--eu-blue);
  background-color: var(--eu-blue-light);
}

.td-adj-tile__dir {
  display: block;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--accent);
  margin-bottom: 0.15rem;
}

.td-adj-tile__title {
  display: block;
  font-size: 0.86rem;
  color: var(--eu-ink);
  line-height: 1.3;
}

.td-adj-tile--all {
  text-align: center;
  font-size: 0.82rem;
  color: var(--eu-blue);
}

/* ==========================================================================
   10. SHARED ENTRY CONTENT, FILTER BAR, PARTNERS & FOOTER
   ========================================================================== */
.eu-filter-bar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 2rem;
}

.eu-filter-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.48rem 1rem;
  border-radius: 8px;
  font-size: 0.8125rem;
  font-weight: 700;
  background-color: #F3F4F6;
  border: 1px solid var(--eu-border);
  color: var(--eu-ink-secondary);
  cursor: pointer;
  text-decoration: none;
  transition: border-radius 0.4s var(--ease-out), background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.eu-filter-btn:hover {
  border-radius: 20px;
  border-color: var(--mplus-charcoal);
  color: var(--mplus-charcoal);
}

.eu-filter-btn.is-active {
  background-color: var(--mplus-charcoal);
  border-color: var(--mplus-charcoal);
  color: #FFFFFF;
  border-radius: 20px;
}

.entry-content h1,
.entry-content h2,
.entry-content h3,
.entry-content h4 {
  font-family: var(--font-serif);
  margin-top: 2rem;
  margin-bottom: 0.75rem;
  color: var(--eu-ink);
}

.entry-content h2 {
  font-size: 1.55rem;
  padding-bottom: 0.4rem;
  border-bottom: 1px solid var(--eu-border);
}

.entry-content p {
  margin-bottom: 1.25rem;
}

.entry-content a {
  color: var(--eu-blue);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.entry-content blockquote,
.entry-content .wp-block-quote {
  margin: 1.75rem 0;
  padding: 1.15rem 1.4rem;
  border-left: 4px solid var(--accent);
  background-color: var(--eu-canvas);
  border-radius: 0 10px 10px 0;
  font-family: var(--font-serif);
  font-size: 1.12rem;
  font-style: italic;
}

.entry-content figure img,
.entry-content .wp-block-image img {
  border-radius: 12px;
  border: 1px solid var(--eu-border);
  cursor: zoom-in;
}

.entry-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.5rem 0;
  font-size: 0.9rem;
}

.entry-content table th,
.entry-content table td {
  padding: 0.75rem 0.9rem;
  border: 1px solid var(--eu-border);
  text-align: left;
}

.eu-board-list {
  list-style: none;
  padding: 0;
  margin: 0.5rem 0 1.25rem;
  display: grid;
  gap: 0.6rem;
}

.eu-board-list li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 0.55rem;
  border-bottom: 1px solid var(--eu-border);
  font-size: 0.88rem;
}

.eu-partners-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}

.eu-partner-card {
  background-color: #FFFFFF;
  border: 1px solid var(--eu-border);
  border-radius: 14px;
  padding: 1.15rem;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 96px;
  transition: border-color 0.25s ease, box-shadow 0.25s ease, transform 0.25s ease;
}

.eu-partner-card:hover {
  border-color: #CBD5E1;
  box-shadow: var(--shadow-card-hover);
  transform: translateY(-2px);
}

.eu-partner-card img {
  max-height: 52px;
  width: auto;
  object-fit: contain;
}

.eu-story-surface {
  background-color: #FFFFFF;
  border: 1px solid var(--eu-border);
  border-radius: 16px;
  padding: 2.5rem;
  box-shadow: var(--shadow-card);
}

/* Pagination */
.eu-pagination .nav-links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 3rem;
}

.eu-pagination .page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  height: 40px;
  padding: 0 0.75rem;
  border-radius: 10px;
  border: 1px solid var(--eu-border);
  background: #FFFFFF;
  color: var(--eu-ink);
  font-weight: 700;
  font-size: 0.85rem;
}

.eu-pagination .page-numbers.current,
.eu-pagination .page-numbers:hover {
  background: var(--mplus-charcoal);
  border-color: var(--mplus-charcoal);
  color: #FFFFFF;
}

/* Footer */
.mplus-footer {
  background-color: var(--mplus-charcoal);
  color: rgba(255, 255, 255, 0.82);
  padding-top: 4.25rem;
  font-size: 0.9rem;
  border-top: 4px solid var(--accent);
}

.mplus-footer__grid {
  display: grid;
  grid-template-columns: 1.35fr 1fr 1fr 1.25fr;
  gap: 2.5rem;
  padding-bottom: 3rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.mplus-footer__heading {
  color: #FFFFFF;
  font-family: var(--font-sans);
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 1.15rem;
}

.mplus-footer__list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0.6rem;
}

.mplus-footer__list a {
  color: rgba(255, 255, 255, 0.72);
}

.mplus-footer__list a:hover {
  color: #FFFFFF;
}

.mplus-footer__bottom {
  padding: 1.5rem 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.55);
}

/* ==========================================================================
   11. RESPONSIVE BREAKPOINTS
   ========================================================================== */
@media (max-width: 1200px) {
  .td-cards-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  .td-split-stage {
    grid-template-columns: 1fr 1fr;
  }
  .td-megamenu__inner {
    grid-template-columns: 260px 1.2fr 1fr;
    gap: 1rem;
  }
}

@media (max-width: 960px) {
  /* Hide desktop inline search, show Mobile Sub-Header Search Line Extension */
  .mplus-inline-search {
    display: none;
  }
  .mplus-mobile-search-ext {
    display: block;
  }
  .mplus-mobile-toggle {
    display: inline-flex;
  }
  .mplus-nav {
    position: fixed;
    top: 112px;
    left: 0;
    right: 0;
    background: #FFFFFF;
    color: var(--mplus-charcoal);
    border-bottom: 1px solid var(--eu-border);
    box-shadow: var(--shadow-card-hover);
    padding: 1.25rem 1.5rem;
    display: none;
    flex-direction: column;
    align-items: stretch;
    max-height: calc(100vh - 112px);
    overflow-y: auto;
    z-index: 1200;
  }
  .mplus-nav.is-open {
    display: flex;
  }
  .mplus-nav__list,
  .mplus-nav ul.menu {
    flex-direction: column;
    align-items: stretch;
    gap: 0.5rem;
  }
  .mplus-nav__list > li > a,
  .mplus-nav ul.menu > li > a {
    color: var(--mplus-charcoal) !important;
    font-size: 1rem;
    padding: 0.6rem 0.75rem;
    background: #F8F9FA;
    justify-content: space-between;
  }
  .td-megamenu {
    position: static;
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: none;
    box-shadow: none;
    border: 1px solid var(--eu-border);
    margin-top: 0.45rem;
    padding: 0.85rem;
  }
  .td-megamenu__inner {
    grid-template-columns: 1fr;
    gap: 0.85rem;
  }
  .td-megamenu__hero {
    min-height: 160px;
  }
  .td-megamenu__cards-grid {
    grid-template-columns: 1fr;
  }
  body:not(.home):not(.front-page) {
    padding-top: 148px;
  }
  .td-sticky-subbar,
  .td-article-commandbar {
    top: 114px;
  }
  .td-split-stage,
  .td-bento-showcase {
    grid-template-columns: 1fr;
  }
  .td-split-text-pane {
    position: static;
    max-height: none;
    overflow-y: visible;
  }
  .td-cards-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .mplus-footer__grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 640px) {
  .mplus-utility-bar {
    display: none;
  }
  body:not(.home):not(.front-page) {
    padding-top: 118px;
  }
  .td-cards-grid,
  .td-article-bento-pair,
  .td-media-bento-grid,
  .eu-partners-strip,
  .mplus-footer__grid {
    grid-template-columns: 1fr;
  }
  .td-media-bento-item--featured {
    grid-column: span 1;
  }
  .td-cards-grid.is-list-view .td-card__link {
    flex-direction: column;
    align-items: stretch;
  }
  .td-cards-grid.is-list-view .td-card__media-clip {
    width: 100%;
    height: 180px;
  }
}
