/**
 * ConfidenceTalk Page Content Styles
 * All colors reference CSS variables from the color theme system.
 * Falls back to light theme defaults (Metallic Bronze palette) when
 * the theme system is not active or CSS variables fail to load.
 *
 * NOTE: Some template files use inline style="color:#fff" which requires
 * !important in CSS to override. We use theme variable !important on the
 * page wrapper container so all children inherit proper contrast.
 *
 * @package ConfidenceTalk
 */

/* ============================================================
   RESPONSIVE FOUNDATION — fluid type tokens + breakpoints
   ============================================================
   BREAKPOINTS (single source of truth — CSS @media cannot read
   custom properties, so use these canonical values):
     bp-sm: 480px · bp-md: 768px · bp-lg: 1024px · bp-xl: 1280px
   FLUID TYPE SCALE — clamp() so headings scale smoothly between
   bp-sm and bp-lg without per-breakpoint overrides.
   (Duplicated in admin/css/gold-series.css :root for admin pages.) */
:root {
  --ct-fs-h1: clamp(26px, 2.4vw + 14px, 42px);
  --ct-fs-h2: clamp(20px, 1.6vw + 12px, 30px);
  --ct-fs-h3: clamp(15px, 0.8vw + 12px, 17px);
  --ct-fs-h4: clamp(15px, 0.7vw + 12px, 17px);
  --ct-fs-body: clamp(14px, 0.5vw + 12px, 16px);
  --ct-fs-small: clamp(12px, 0.3vw + 11px, 13px);
}

/* ============================================================
   PAGE SECTIONS & LAYOUT
   ============================================================ */
.ct-gold-series {
  min-height: 400px;
}

.ct-page-wrapper {
  max-width: 1200px;
  margin: 0 auto;
  padding: 8px 20px 40px;
}

.ct-page-section {
  padding: 40px 0;
  color: var(--color-text-secondary, #475569);
  background: transparent;
}

.ct-page-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
  background: transparent;
}

.ct-page-title {
  font-size: var(--ct-fs-h2);
  font-weight: 700;
  color: var(--color-text-heading, #1a202c);
  margin-bottom: 24px;
}

.ct-page-content {
  font-size: 15px;
  line-height: 1.7;
  color: var(--color-text-body, #1a202c);
}

.ct-page-content p {
  margin-bottom: 16px;
}

/* ============================================================
   BODY & PAGE WRAPPER — Dark background for white text.
   Templates use inline style="color:#fff" which renders correctly
   on a dark background. This ensures body always defaults to
   a dark color when theme variables fail to load.
   ============================================================ */
body.ct-plugin-page {
  background: var(--color-page-bg-gradient, #0f172a) !important;
  color: var(--color-text-on-page-bg, #ffffff) !important;
}

/* ============================================================
   METALLIC STEEL CARDS
   ============================================================ */
.ct-card {
  background: rgba(255, 255, 255, 0.03);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  border: 1px solid var(--color-border, rgba(0, 0, 0, 0.08));
  border-radius: 16px;
  padding: 24px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  transition: box-shadow 0.2s ease;
}

.ct-card:hover {
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}

.ct-card-icon {
  font-size: 48px;
  margin-bottom: 12px;
  display: block;
}

.ct-card-title {
  color: var(--color-text-heading, #1a202c);
  font-size: var(--ct-fs-h3);
  font-weight: 700;
  margin-bottom: 8px;
}

.ct-card-text {
  color: var(--color-text-body, #475569);
  font-size: 13px;
  line-height: 1.5;
  margin-bottom: 16px;
}

.ct-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 16px;
  padding: 20px 0;
}

.ct-card-grid-4 {
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
}

.ct-card-full {
  width: 100%;
}

.ct-card-bronze {
  border: 1px solid rgba(205, 133, 63, 0.3);
  background: linear-gradient(
    135deg,
    rgba(139, 69, 19, 0.15) 0%,
    rgba(160, 82, 45, 0.1) 50%,
    rgba(205, 133, 63, 0.15) 100%
  );
}

/* ============================================================
   SECTION HEADERS
   ============================================================ */
.ct-section-header {
  text-align: center;
  margin-bottom: 20px;
}

.ct-section-title {
  color: var(--color-text-heading, #1a202c);
  font-size: 24px;
  font-weight: 700;
  margin: 0;
}

/* ============================================================
   BUTTONS
   ============================================================ */
.ct-btn {
  display: inline-block;
  padding: 10px 20px;
  border-radius: 8px;
  border: 1px solid var(--color-border, rgba(0, 0, 0, 0.12));
  background: var(--color-card-bg, #ffffff);
  color: var(--color-text-body, #1a202c) !important;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.15s ease;
}
.ct-btn:hover {
  background: var(
    --bronze-metallic-gradient,
    linear-gradient(135deg, #8b4513, #a0522d, #cd853f)
  );
  border-color: rgba(205, 133, 63, 0.5);
  color: var(--color-text-on-dark, #fff) !important;
  text-decoration: none;
}

.ct-btn-primary {
  background: var(
    --bronze-metallic-gradient,
    linear-gradient(135deg, #8b4513, #a0522d, #cd853f)
  );
  border-color: rgba(205, 133, 63, 0.4);
}
.ct-btn-primary:hover {
  background: var(
    --bronze-metallic-gradient,
    linear-gradient(135deg, #a0522d, #cd853f, #daa520)
  );
  border-color: rgba(205, 133, 63, 0.6);
}

.ct-btn-sm {
  padding: 8px 16px;
  font-size: 12px;
}

.ct-btn-secondary {
  background: rgba(0, 0, 0, 0.04);
  border-color: rgba(0, 0, 0, 0.15);
}
.ct-btn-secondary:hover {
  background: rgba(0, 0, 0, 0.08);
  border-color: rgba(0, 0, 0, 0.25);
}

/* ============================================================
   TIER BADGES
   ============================================================ */
.ct-tier-badge {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.ct-tier-badge-1 {
  background: #ffd700;
  color: #1a202c;
}

.ct-tier-badge-2 {
  background: #a0aec0;
  color: #1a202c;
}

.ct-tier-badge-3 {
  background: #cd853f;
  color: #1a202c;
}

/* ============================================================
   HERO SECTION
   ============================================================ */
.ct-hero {
  text-align: center;
  padding: 80px 20px 60px;
  max-width: 800px;
  margin: 0 auto;
}

.ct-hero-with-bg {
  position: relative;
  max-width: 100%;
  padding: 0;
  margin: 0 0 24px 0;
  border-radius: 16px;
  overflow: hidden;
  min-height: 380px;
  display: flex;
  align-items: flex-end;
  justify-content: flex-start;
}

.ct-hero-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
}

.ct-hero-bg-slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 0.45s ease-in-out;
  z-index: 0;
}
.ct-hero-bg-slide.ct-active {
  opacity: 1;
  z-index: 1;
}

.ct-hero-bg-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center 10%;
  background-repeat: no-repeat;
  image-rendering: auto;
  -ms-interpolation-mode: nearest-neighbor;
  animation: ctKenBurns 12s ease-in-out infinite alternate;
}

/* Batch 2 LCP optimization: hero portraits are now <img> elements (not CSS
   backgrounds) so the LCP image can carry fetchpriority="high" + responsive
   srcset. object-fit mirrors the old background-size:cover look. */
img.ct-hero-bg-image {
  object-fit: cover;
  object-position: center 10%;
  display: block;
}

@keyframes ctKenBurns {
  0% {
    transform: scale(1);
  }
  100% {
    transform: scale(1.08);
  }
}

.ct-hero-slide-text {
  position: absolute;
  bottom: 20px;
  left: 24px;
  z-index: 2;
  max-width: 550px;
  text-align: left;
}

.ct-hero-name {
  font-size: 36px;
  font-weight: 800;
  color: #cd853f;
  margin: 0 0 4px 0;
  letter-spacing: -0.5px;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.6);
}
.ct-hero-era {
  color: rgba(255, 255, 255, 0.7);
  font-size: 14px;
  margin: 0 0 8px 0;
}
.ct-hero-quote {
  color: rgba(255, 255, 255, 0.85);
  font-size: 16px;
  font-style: italic;
  margin: 0 0 16px 0;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.5);
}

.ct-hero-buttons-bar {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.ct-hero-buttons-bar .ct-btn {
  font-size: 12px;
  padding: 7px 16px;
}

.ct-hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    180deg,
    rgba(15, 23, 42, 0) 0%,
    rgba(15, 23, 42, 0) 60%,
    rgba(15, 23, 42, 0.25) 80%,
    rgba(15, 23, 42, 0.5) 100%
  );
  z-index: 1;
}

.ct-hero-content {
  position: relative;
  z-index: 2;
  padding: 24px;
  max-width: 600px;
}
.ct-hero-content h1 {
  font-size: var(--ct-fs-h1);
  font-weight: 800;
  color: #fff;
  margin-bottom: 16px;
  letter-spacing: -0.5px;
}
.ct-hero-content p {
  color: rgba(255, 255, 255, 0.8);
  font-size: 14px;
  line-height: 1.5;
  margin-bottom: 16px;
}

.ct-hero-wave {
  position: absolute;
  bottom: 16px;
  right: 24px;
  display: flex;
  align-items: flex-end;
  gap: 4px;
  z-index: 2;
  pointer-events: none;
  width: auto;
  max-width: 68px;
}
.ct-hero-wave-bar {
  width: 6px;
  border-radius: 3px;
  background: linear-gradient(180deg, #cd853f 0%, #daa520 100%);
  animation: ctWaveAnim 1.5s ease-in-out infinite;
}
.ct-hero-wave-bar:nth-child(1) {
  height: 12px;
  animation-delay: 0s;
}
.ct-hero-wave-bar:nth-child(2) {
  height: 20px;
  animation-delay: 0.1s;
}
.ct-hero-wave-bar:nth-child(3) {
  height: 28px;
  animation-delay: 0.2s;
}
.ct-hero-wave-bar:nth-child(4) {
  height: 35px;
  animation-delay: 0.3s;
}
.ct-hero-wave-bar:nth-child(5) {
  height: 28px;
  animation-delay: 0.4s;
}
.ct-hero-wave-bar:nth-child(6) {
  height: 20px;
  animation-delay: 0.5s;
}
.ct-hero-wave-bar:nth-child(7) {
  height: 12px;
  animation-delay: 0.6s;
}

@keyframes ctWaveAnim {
  0%,
  100% {
    opacity: 1;
    transform: scaleY(1);
  }
  50% {
    opacity: 0.5;
    transform: scaleY(0.7);
  }
}

/* ============================================================
   FAMOUS PEOPLE CAROUSEL
   ============================================================ */
.ct-famous-carousel {
  position: relative;
  padding: 0 40px;
}

.ct-carousel-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid var(--color-border, rgba(0, 0, 0, 0.12));
  background: var(--color-card-bg, #ffffff);
  color: var(--color-text-body, #1a202c);
  font-size: 22px;
  cursor: pointer;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s ease;
}
.ct-carousel-nav:hover {
  background: var(
    --bronze-metallic-gradient,
    linear-gradient(135deg, #8b4513, #a0522d, #cd853f)
  );
  border-color: rgba(205, 133, 63, 0.5);
  color: #fff;
}

.ct-carousel-nav-prev {
  left: -8px;
}
.ct-carousel-nav-next {
  right: -8px;
}

.ct-famous-track {
  display: flex;
  gap: 16px;
  overflow-x: hidden;
  padding: 8px 0 16px;
  scrollbar-width: none;
  -ms-overflow-style: none;
}
.ct-famous-track::-webkit-scrollbar {
  display: none;
}

.ct-famous-card,
.ct-famous-track .ct-landscape-card {
  flex: 0 0 280px;
}

@media (max-width: 768px) {
  .ct-famous-track .ct-landscape-card {
    flex: 0 0 220px;
  }
}

@media (max-width: 480px) {
  .ct-famous-track .ct-landscape-card {
    flex: 0 0 180px;
  }
  .ct-famous-track {
    gap: 12px;
  }
}

.ct-famous-card {
  background: var(--color-card-bg, #ffffff);
  border: 1px solid var(--color-border, rgba(0, 0, 0, 0.08));
  border-radius: 16px;
  overflow: hidden;
  transition: box-shadow 0.2s ease;
  text-align: center;
}
.ct-famous-card:hover {
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}

.ct-famous-portrait {
  position: relative;
  width: 100%;
  height: 220px;
  background-size: cover;
  background-position: center top;
  background-repeat: no-repeat;
}

.ct-famous-portrait-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    180deg,
    rgba(0, 0, 0, 0.1) 0%,
    rgba(0, 0, 0, 0.4) 100%
  );
}

.ct-famous-tier {
  position: absolute;
  top: 8px;
  right: 8px;
  padding: 3px 10px;
  border-radius: 12px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  z-index: 2;
}

.ct-famous-info {
  padding: 12px;
}

.ct-famous-name {
  color: var(--color-text-heading, #1a202c);
  font-size: 15px;
  font-weight: 700;
  margin: 0 0 4px 0;
}

.ct-famous-era {
  color: var(--color-text-muted, #64748b);
  font-size: 11px;
}

/* ============================================================
   GALLERY TOOLBAR
   ============================================================ */
.ct-gallery-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.ct-gallery-search-wrap {
  position: relative;
  flex: 1;
  max-width: 320px;
}

.ct-gallery-search-wrap .ct-input {
  width: 100%;
  padding: 8px 12px 8px 36px;
  border-radius: 8px;
  border: 1px solid var(--color-border, rgba(0, 0, 0, 0.12));
  background: rgba(255, 255, 255, 0.8);
  color: var(--color-text-body, #1a202c);
  font-size: 13px;
  outline: none;
  box-sizing: border-box;
}
.ct-gallery-search-wrap .ct-input:focus {
  border-color: #cd853f;
}

.ct-gallery-search-icon {
  position: absolute;
  left: 10px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 14px;
  pointer-events: none;
  opacity: 0.5;
}

.ct-gallery-page-info {
  color: var(--color-text-muted, #64748b);
  font-size: 12px;
  white-space: nowrap;
}

/* ============================================================
   GALLERY PAGINATION
   ============================================================ */
.ct-gallery-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid var(--color-border, rgba(0, 0, 0, 0.06));
}

.ct-gallery-pg-btn {
  padding: 6px 16px;
  border-radius: 8px;
  border: 1px solid var(--color-border, rgba(0, 0, 0, 0.12));
  background: rgba(255, 255, 255, 0.8);
  color: var(--color-text-body, #475569);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
}
.ct-gallery-pg-btn:hover {
  background: var(--bronze-metallic-gradient);
  color: #fff;
}
.ct-gallery-pg-btn:disabled {
  opacity: 0.3;
  cursor: default;
}

.ct-gallery-pg-text {
  color: var(--color-text-muted, #64748b);
  font-size: 12px;
}

.ct-gallery-no-results {
  text-align: center;
  padding: 40px 20px;
}

/* ============================================================
   LANDSCAPE GRID
   ============================================================ */
.ct-famous-portrait-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  padding: 0 0 20px;
}

.ct-landscape-card {
  position: relative;
  border-radius: 10px;
  overflow: hidden;
  aspect-ratio: 4 / 3;
  min-height: 160px;
  background: var(--color-card-bg, #ffffff);
  border: 1px solid var(--color-border, rgba(0, 0, 0, 0.08));
}

.ct-landscape-card-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center 10%;
  background-repeat: no-repeat;
  animation: ctKenBurns 12s ease-in-out infinite alternate;
}

.ct-landscape-card-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    transparent 0%,
    rgba(0, 0, 0, 0.1) 30%,
    rgba(0, 0, 0, 0.5) 60%,
    rgba(0, 0, 0, 0.8) 100%
  );
  pointer-events: none;
}

.ct-landscape-card-btn {
  position: absolute;
  top: 8px;
  left: 8px;
  z-index: 3;
  font-size: 10px;
  padding: 4px 10px;
  cursor: pointer;
  border-radius: 6px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  background: rgba(0, 0, 0, 0.5);
  color: #fff !important;
  font-weight: 600;
  transition: background 0.15s ease;
}
.ct-landscape-card-btn:hover {
  background: var(
    --bronze-metallic-gradient,
    linear-gradient(135deg, #8b4513, #a0522d, #cd853f)
  );
  border-color: rgba(205, 133, 63, 0.5);
  color: #fff !important;
}

.ct-landscape-card-info {
  position: absolute;
  bottom: 10px;
  left: 12px;
  right: 12px;
  text-align: left;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  z-index: 2;
}

.ct-landscape-card-name {
  color: #cd853f;
  font-size: 14px;
  font-weight: 700;
  margin: 0 0 1px 0;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.7);
}

.ct-landscape-card-era {
  color: rgba(255, 255, 255, 0.65);
  font-size: 10px;
  display: block;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
  margin-bottom: 2px;
}

.ct-landscape-card-known {
  color: rgba(255, 255, 255, 0.45);
  font-size: 9px;
  line-height: 1.2;
  margin: 0;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
  max-height: 1.2em;
}

@media (max-width: 1024px) {
  .ct-famous-portrait-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 768px) {
  .ct-famous-portrait-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 480px) {
  .ct-famous-portrait-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
  }
  .ct-landscape-card {
    min-height: 130px;
  }
}

/* ============================================================
   FEATURE PANEL GRID
   ============================================================ */
.ct-feature-panel-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  padding: 0 0 20px;
}

.ct-feature-panel-card {
  background: var(--color-card-bg, #ffffff);
  border: 1px solid var(--color-border, rgba(0, 0, 0, 0.08));
  border-radius: 10px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  transition: box-shadow 0.2s ease;
}
.ct-feature-panel-card:hover {
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}

.ct-feature-panel-icon {
  font-size: 28px;
  margin-bottom: 8px;
}

.ct-feature-panel-body {
  flex: 1;
  margin-bottom: 10px;
}

.ct-feature-panel-title {
  color: #cd853f;
  font-size: 14px;
  font-weight: 700;
  margin: 0 0 4px 0;
}

.ct-feature-panel-desc {
  color: var(--color-text-body, #475569);
  font-size: 11px;
  line-height: 1.4;
  margin: 0;
}

.ct-feature-panel-link {
  font-size: 11px;
  color: #cd853f;
  text-decoration: none;
  font-weight: 600;
  align-self: flex-start;
}
.ct-feature-panel-link:hover {
  color: #daa520;
  text-decoration: underline;
}

@media (max-width: 1024px) {
  .ct-feature-panel-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 768px) {
  .ct-feature-panel-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 480px) {
  .ct-feature-panel-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }
}

/* ============================================================
   FAMOUS PEOPLE GALLERY
   ============================================================ */
.ct-famous-filter-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}

.ct-filter-buttons {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.ct-filter-btn {
  padding: 8px 16px;
  border-radius: 20px;
  border: 1px solid var(--color-border, rgba(0, 0, 0, 0.12));
  background: rgba(255, 255, 255, 0.8);
  color: var(--color-text-body, #475569);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
  white-space: nowrap;
}
.ct-filter-btn:hover {
  background: rgba(0, 0, 0, 0.05);
  color: var(--color-text-heading, #1a202c);
}
.ct-filter-active {
  background: var(
    --bronze-metallic-gradient,
    linear-gradient(135deg, #8b4513, #a0522d, #cd853f)
  );
  border-color: rgba(205, 133, 63, 0.5);
  color: #fff !important;
}

.ct-famous-search {
  position: relative;
  flex: 0 0 260px;
}
.ct-famous-search .ct-input {
  padding-right: 36px;
}

.ct-search-icon {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 16px;
  pointer-events: none;
  opacity: 0.6;
}

.ct-gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
  padding: 0 0 20px;
}

.ct-gallery-card {
  background: var(--color-card-bg, #ffffff);
  border: 1px solid var(--color-border, rgba(0, 0, 0, 0.08));
  border-radius: 16px;
  overflow: hidden;
  position: relative;
  transition:
    box-shadow 0.2s ease,
    transform 0.2s ease;
}
.ct-gallery-card:hover {
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
  transform: translateY(-2px);
}

.ct-gallery-card-portrait {
  width: 100%;
  height: 200px;
  background-size: cover;
  background-position: center top;
  background-repeat: no-repeat;
}

.ct-gallery-card-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 200px;
  background: linear-gradient(
    180deg,
    rgba(0, 0, 0, 0.05) 0%,
    rgba(0, 0, 0, 0.45) 100%
  );
  pointer-events: none;
}

.ct-gallery-card-content {
  padding: 16px;
  position: relative;
  z-index: 3;
}

.ct-gallery-card-name {
  color: var(--color-text-heading, #1a202c);
  font-size: 16px;
  font-weight: 700;
  margin: 0 0 6px 0;
}

.ct-gallery-card-meta {
  color: var(--color-text-muted, #64748b);
  font-size: 11px;
  line-height: 1.5;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.ct-gallery-card .ct-tier-badge {
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 4;
}

/* ============================================================
   MODAL SYSTEM
   ============================================================ */
.ct-modal {
  display: none;
  position: fixed;
  z-index: 9999;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
  align-items: center;
  justify-content: center;
  padding: 20px;
  box-sizing: border-box;
}

.ct-modal-content {
  background: var(--color-card-bg, #ffffff);
  border: 1px solid var(--color-border, rgba(0, 0, 0, 0.12));
  border-radius: 20px;
  max-width: 560px;
  width: 100%;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5);
  animation: ctModalIn 0.2s ease-out;
}

@keyframes ctModalIn {
  from {
    transform: scale(0.95);
    opacity: 0;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}

.ct-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  border-bottom: 1px solid var(--color-border, rgba(0, 0, 0, 0.06));
}
.ct-modal-header h3 {
  color: var(--color-text-heading, #1a202c);
  font-size: 18px;
  font-weight: 700;
  margin: 0;
}

.ct-modal-close {
  background: none;
  border: none;
  color: var(--color-text-muted, #64748b);
  font-size: 28px;
  cursor: pointer;
  padding: 0;
  line-height: 1;
  transition: color 0.15s ease;
}
.ct-modal-close:hover {
  color: var(--color-text-heading, #1a202c);
}

.ct-modal-body {
  padding: 24px;
  max-height: 60vh;
  overflow-y: auto;
}

.ct-modal-loading {
  text-align: center;
  color: var(--color-text-muted, #64748b);
  padding: 40px 20px;
}

/* ============================================================
   EMPTY STATE
   ============================================================ */
.ct-empty-state {
  text-align: center;
  padding: 60px 20px;
}
.ct-empty-icon {
  font-size: 48px;
  margin-bottom: 12px;
  display: block;
}
.ct-empty-state h3 {
  color: var(--color-text-heading, #1a202c);
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 8px;
}
.ct-empty-state p {
  color: var(--color-text-muted, #64748b);
  font-size: 13px;
}

/* ============================================================
   FEATURES PAGE
   ============================================================ */
.ct-features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 16px;
  padding: 20px 0;
}

.ct-feature-card {
  background: var(--color-card-bg, #ffffff);
  border: 1px solid var(--color-border, rgba(0, 0, 0, 0.08));
  border-radius: 16px;
  padding: 24px;
  transition: box-shadow 0.2s ease;
}
.ct-feature-card:hover {
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}

.ct-feature-icon {
  font-size: 48px;
  margin-bottom: 12px;
  display: block;
}

.ct-feature-title {
  color: var(--color-text-heading, #1a202c);
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 8px;
}

.ct-feature-desc {
  color: var(--color-text-body, #475569);
  font-size: 13px;
  line-height: 1.5;
}

/* ============================================================
   HOW IT WORKS PAGE
   ============================================================ */
.ct-steps-section {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  padding: 20px 0;
}

.ct-step-card {
  background: var(--color-card-bg, #ffffff);
  border: 1px solid var(--color-border, rgba(0, 0, 0, 0.08));
  border-radius: 16px;
  padding: 24px;
  position: relative;
  transition: box-shadow 0.2s ease;
}
.ct-step-card:hover {
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}

.ct-step-number {
  position: absolute;
  top: -10px;
  right: 16px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(
    --bronze-metallic-gradient,
    linear-gradient(135deg, #8b4513, #cd853f)
  );
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

.ct-step-icon {
  font-size: 48px;
  margin-bottom: 12px;
  display: block;
}

.ct-step-title {
  color: var(--color-text-heading, #1a202c);
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 8px;
}

.ct-step-desc {
  color: var(--color-text-body, #475569);
  font-size: 14px;
  line-height: 1.6;
}

/* ============================================================
   ABOUT PAGE
   ============================================================ */
.ct-about-section {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  gap: 16px;
  padding: 20px 0;
}

.ct-about-card {
  background: var(--color-card-bg, #ffffff);
  border: 1px solid var(--color-border, rgba(0, 0, 0, 0.08));
  border-radius: 16px;
  padding: 24px;
  transition: box-shadow 0.2s ease;
}
.ct-about-card:hover {
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}
.ct-about-card.ct-about-full {
  grid-column: 1 / -1;
}

.ct-about-card h3 {
  color: var(--color-text-heading, #1a202c);
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 12px;
}

.ct-about-card p {
  color: var(--color-text-body, #475569);
  font-size: 14px;
  line-height: 1.6;
  margin-bottom: 12px;
}

.ct-about-card ul {
  color: var(--color-text-body, #475569);
  font-size: 13px;
  line-height: 1.8;
  padding-left: 20px;
}

/* ============================================================
   PAGE HERO — Reusable centered hero for static pages
   ============================================================ */
.ct-page-hero {
  text-align: center;
  padding: 40px 20px 20px;
}
.ct-page-hero-icon {
  font-size: 52px;
  margin-bottom: 12px;
  display: block;
}
.ct-page-hero h1 {
  font-size: 32px;
  font-weight: 800;
  color: #fff;
  margin: 0 0 8px;
  letter-spacing: -0.5px;
}
.ct-page-hero-subtitle {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.6);
  margin: 0 0 8px;
  line-height: 1.5;
}
.ct-page-hero-date {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.35);
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* ============================================================
   FAQ PAGE
   ============================================================ */
.ct-faq-section {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
  gap: 16px;
  padding: 20px 0;
}

.ct-faq-item {
  border-bottom: 1px solid var(--color-border, rgba(0, 0, 0, 0.08));
  margin-bottom: 0;
}

.ct-faq-card {
  background: var(--color-card-bg, #ffffff);
  border: 1px solid var(--color-border, rgba(0, 0, 0, 0.08));
  border-radius: 16px;
  margin-bottom: 0;
  overflow: hidden;
  transition: box-shadow 0.2s ease;
}
.ct-faq-card:hover {
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}
.ct-faq-card-question {
  width: 100%;
  padding: 16px 24px;
  background: none;
  border: none;
  color: var(--color-text-heading, #1a202c);
  font-size: 14px;
  font-weight: 700;
  text-align: left;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  transition: background 0.15s ease;
  font-family: inherit;
}
.ct-faq-card-question:hover {
  background: rgba(0, 0, 0, 0.03);
}
.ct-faq-card-icon {
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  font-weight: 700;
  color: rgba(205, 133, 63, 1);
  transition: transform 0.25s ease;
}
.ct-faq-card-icon.ct-open {
  transform: rotate(45deg);
}
.ct-faq-card-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease, padding 0.3s ease;
  padding: 0 24px;
}
.ct-faq-card-answer.ct-open {
  max-height: 500px;
  padding: 0 24px 20px;
}
.ct-faq-card-answer p {
  color: var(--color-text-body, #475569);
  font-size: 14px;
  line-height: 1.7;
  margin: 0;
}

.ct-faq-question {
  width: 100%;
  padding: 16px 20px;
  background: none;
  border: none;
  color: var(--color-text-heading, #1a202c);
  font-size: 14px;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 12px;
}
.ct-faq-question:hover {
  background: rgba(0, 0, 0, 0.03);
}

.ct-faq-icon {
  font-size: 18px;
  color: #cd853f;
  font-weight: 700;
  width: 20px;
  text-align: center;
  flex-shrink: 0;
}

.ct-faq-answer {
  display: none;
  padding: 0 20px 16px 52px;
  color: var(--color-text-body, #475569);
  font-size: 13px;
  line-height: 1.6;
}
.ct-faq-answer.ct-open {
  display: block;
}
.ct-faq-answer p {
  margin: 0;
}

/* ============================================================
   FORM ELEMENTS — Shared across all CT pages
   Dark-theme defaults; CT_LiveColor enforces per-surface contrast.
   ============================================================ */
.ct-form-group {
  margin-bottom: 12px;
}

.ct-form-group label {
  display: block;
  color: var(--color-text-body, rgba(255, 255, 255, 0.7));
  font-size: 12px;
  font-weight: 600;
  margin-bottom: 4px;
}

.ct-input {
  width: 100%;
  padding: 10px 12px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.05);
  color: var(--color-text-body, #ffffff);
  font-size: 13px;
  outline: none;
  box-sizing: border-box;
}
.ct-input:focus {
  border-color: #cd853f;
}
.ct-input::placeholder {
  color: rgba(255, 255, 255, 0.35);
}

.ct-textarea {
  width: 100%;
  padding: 10px 12px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.05);
  color: var(--color-text-body, #ffffff);
  font-size: 13px;
  outline: none;
  min-height: 120px;
  font-family: inherit;
  box-sizing: border-box;
}
.ct-textarea:focus {
  border-color: #cd853f;
}
.ct-textarea::placeholder {
  color: rgba(255, 255, 255, 0.35);
}

/* ============================================================
   PRIVACY PAGE
   ============================================================ */
.ct-privacy-section {
  max-width: 800px;
  margin: 0 auto;
  padding: 20px 0;
}

.ct-privacy-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  padding: 0 0 20px;
}

@media (max-width: 768px) {
  .ct-privacy-grid {
    grid-template-columns: 1fr;
  }
}

.ct-privacy-card {
  background: var(--color-card-bg, #ffffff);
  border: 1px solid var(--color-border, rgba(0, 0, 0, 0.08));
  border-radius: 16px;
  padding: 24px;
  margin-bottom: 16px;
}

.ct-privacy-card h3 {
  color: var(--color-text-heading, #1a202c);
  font-size: var(--ct-fs-h4);
  font-weight: 700;
  margin-bottom: 8px;
}

.ct-privacy-card p {
  color: var(--color-text-body, #475569);
  font-size: 13px;
  line-height: 1.6;
  margin-bottom: 8px;
}

.ct-privacy-card ul {
  color: var(--color-text-body, #475569);
  font-size: 13px;
  line-height: 1.8;
  padding-left: 20px;
}

/* ============================================================
   TERMS PAGE
   ============================================================ */
.ct-terms-section {
  max-width: 800px;
  margin: 0 auto;
  padding: 20px 0;
}

.ct-terms-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  padding: 0 0 20px;
}

@media (max-width: 768px) {
  .ct-terms-grid {
    grid-template-columns: 1fr;
  }
}

.ct-terms-card {
  background: var(--color-card-bg, #ffffff);
  border: 1px solid var(--color-border, rgba(0, 0, 0, 0.08));
  border-radius: 16px;
  padding: 24px;
  margin-bottom: 16px;
}

.ct-terms-card h3 {
  color: var(--color-text-heading, #1a202c);
  font-size: var(--ct-fs-h4);
  font-weight: 700;
  margin-bottom: 8px;
}

.ct-terms-card p {
  color: var(--color-text-body, #475569);
  font-size: 13px;
  line-height: 1.6;
  margin-bottom: 8px;
}

.ct-terms-card ul {
  color: var(--color-text-body, #475569);
  font-size: 13px;
  line-height: 1.8;
  padding-left: 20px;
}

/* ============================================================
   PAGE HEADER
   ============================================================ */
.ct-page-header {
  margin-bottom: 24px;
}

.ct-breadcrumb {
  font-size: 12px;
  color: var(--color-text-muted, #64748b);
  margin-bottom: 8px;
}
.ct-breadcrumb a {
  color: #cd853f;
  text-decoration: none;
}
.ct-breadcrumb a:hover {
  color: #daa520;
  text-decoration: underline;
}
.ct-breadcrumb-sep {
  margin: 0 6px;
  color: var(--color-text-muted, #64748b);
}

.ct-page-subtitle {
  color: var(--color-text-muted, #64748b);
  font-size: 14px;
  margin-top: 4px;
}

/* ============================================================
   CARD HEADER / CARD BODY
   ============================================================ */
.ct-card-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--color-border, rgba(0, 0, 0, 0.06));
}
.ct-card-header h3 {
  color: var(--color-text-heading, #1a202c);
  font-size: var(--ct-fs-h3);
  font-weight: 700;
  margin: 0;
}

.ct-card-body {
  padding: 0;
}

/* ============================================================
   RESPONSIVE BREAKPOINTS
   ============================================================ */
@media (max-width: 768px) {
  .ct-page-wrapper {
    padding: 20px 16px;
  }
  .ct-hero h1 {
    font-size: 28px;
  }
  .ct-hero p {
    font-size: 15px;
  }
  .ct-hero-name {
    font-size: 26px;
  }
  .ct-hero-quote {
    font-size: 14px;
  }
  .ct-hero-slide-text {
    left: 16px;
    right: 16px;
    max-width: 100%;
  }
  .ct-features-grid {
    grid-template-columns: 1fr;
  }
  .ct-steps-section {
    grid-template-columns: 1fr;
  }
  .ct-faq-section {
    grid-template-columns: 1fr;
  }
  .ct-about-section {
    grid-template-columns: 1fr;
  }
  .ct-famous-filter-bar {
    flex-direction: column;
    align-items: stretch;
  }
  .ct-famous-search {
    flex: 1;
  }
  .ct-gallery-grid {
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  }
  .ct-famous-carousel {
    padding: 0 32px;
  }
  .ct-famous-card {
    flex: 0 0 160px;
  }
  .ct-famous-portrait {
    height: 140px;
  }
  .ct-contact-section {
    grid-template-columns: 1fr;
  }

  /* Inline-flex two-column hero variants (hero-split.php / hero-filestrip.php)
     must stack on small screens — inline styles need !important to override. */
  .ct-hero-split,
  .ct-hero-filestrip {
    flex-direction: column !important;
    gap: 14px !important;
    min-height: 0 !important;
  }

  .ct-hero-split > div,
  .ct-hero-filestrip > div {
    flex: 0 0 auto !important;
    width: 100% !important;
    min-height: 0 !important;
    border-radius: 16px !important;
  }

  .ct-hero-split > div:first-child,
  .ct-hero-filestrip > div:first-child {
    min-height: 200px !important;
  }

  .ct-hero-split > div:last-child,
  .ct-hero-filestrip > div:last-child {
    padding: 24px 20px !important;
  }

  .ct-hero-split h1,
  .ct-hero-filestrip h1 {
    font-size: 26px !important;
  }

  .ct-hero-split .ct-hero-buttons-bar,
  .ct-hero-filestrip .ct-hero-buttons-bar {
    flex-direction: column;
    align-items: stretch;
  }

  .ct-hero-split .ct-hero-buttons-bar .ct-btn,
  .ct-hero-filestrip .ct-hero-buttons-bar .ct-btn {
    width: 100%;
    text-align: center;
  }
}

@media (max-width: 480px) {
  .ct-page-wrapper {
    padding: 16px 12px;
  }

  /* Compact hero (page-home-landing): wrap so the CTA drops to its own row */
  .ct-hero-minimal {
    flex-wrap: wrap;
    gap: 10px 14px;
    padding: 14px 16px;
  }
  .ct-hero-minimal > .ct-btn {
    width: 100%;
    text-align: center;
  }
  .ct-hero h1 {
    font-size: 24px;
  }
  .ct-hero-name {
    font-size: 22px;
  }
  .ct-hero-wave {
    right: 12px;
    bottom: 10px;
  }
  .ct-hero-wave-bar {
    width: 4px;
  }
  .ct-gallery-grid {
    grid-template-columns: 1fr;
  }
  .ct-famous-card {
    flex: 0 0 140px;
  }
  .ct-carousel-nav {
    width: 30px;
    height: 30px;
    font-size: 18px;
  }
}

/* ============================================================
   CTA BANNER — Shared across all CT static pages
   ============================================================ */
.ct-cta-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 32px 24px;
  margin-top: 32px;
  background: linear-gradient(135deg, rgba(139, 69, 19, 0.12) 0%, rgba(205, 133, 63, 0.08) 100%);
  border: 1px solid rgba(205, 133, 63, 0.2);
  border-radius: 16px;
}
.ct-cta-banner-content h2 {
  color: #fff;
  font-size: 20px;
  font-weight: 700;
  margin: 0 0 4px;
}
.ct-cta-banner-content p {
  color: rgba(255, 255, 255, 0.6);
  font-size: 13px;
  margin: 0;
}
.ct-cta-banner .ct-btn {
  flex-shrink: 0;
  white-space: nowrap;
}

@media (max-width: 768px) {
  .ct-cta-banner {
    flex-direction: column;
    text-align: center;
    padding: 24px 16px;
  }
}

/* ============================================================
   CONTAINER QUERIES — MARKETING GRIDS & SECTIONS (Batch 7)
   Grids adapt to the page-wrapper column width. Thresholds mirror
   the viewport breakpoints (wrapper ≈ viewport − 2×padding), so
   phone/tablet behaviour is unchanged; narrow wrappers on wide
   screens collapse gracefully. Non-supporting browsers fall back
   to the @media rules above.
   ============================================================ */
.ct-page-wrapper {
  container-type: inline-size;
  container-name: ct-page;
}

@container ct-page (max-width: 736px) {
  /* Feature panels + famous portraits: 2 columns (mirrors ≤768px viewport) */
  .ct-feature-panel-grid,
  .ct-famous-portrait-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  /* Content sections: single column (mirrors ≤768px viewport) */
  .ct-features-grid,
  .ct-steps-section,
  .ct-faq-section,
  .ct-about-section,
  .ct-contact-section {
    grid-template-columns: 1fr;
  }
}

@container ct-page (min-width: 737px) and (max-width: 992px) {
  .ct-feature-panel-grid,
  .ct-famous-portrait-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}



/* ============================================================
   MOBILE TOUCH TARGETS (WCAG 2.2 / gold-series: >= 44px)
   Hero + page CTAs were 33px tall (12px font + 7px 16px padding).
   Bump to a 44px minimum tap target on phones and centre the label.
   Scoped to <=768px so desktop/tablet layouts are untouched.
   ============================================================ */
@media (max-width: 768px) {
  .ct-btn,
  .ct-btn-primary,
  .ct-btn-secondary,
  .ct-btn-sm {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    min-height: 44px;
  }
}


/* ============================================================
   CONTACT PAGE — collapse the inline 340px two-column grid on
   phones. The template sets grid-template-columns:340px 1fr via
   an inline style (line ~20 of page-contact.php), which cannot be
   fitted inside 390px and pushes the form off-screen (overflow to
   ~438px). A class + !important overrides the inline style on
   mobile only; desktop keeps the 2-column layout.
   ============================================================ */
@media (max-width: 768px) {
  .ct-contact-grid {
    grid-template-columns: 1fr !important;
    gap: 20px !important;
    padding: 0 0 24px !important;
  }
}
