/* Studio Magazine styles and animation enhancements */

/* Smooth transitions */
html {
  scroll-behavior: smooth;
}

body, .smart-head, .navigation, .main-wrap, .main-footer {
  transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}

/* Crypto Marquee Ticker at the top */
.crypto-ticker-wrap {
  width: 100%;
  background: #0c1524;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  overflow: hidden;
  user-select: none;
  font-family: var(--title-font, "Inter", sans-serif);
  font-size: 13px;
  position: relative;
  z-index: 100;
}

.s-light .crypto-ticker-wrap {
  background: #f8fafc;
  border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

.crypto-ticker-container {
  display: flex;
  align-items: center;
  height: 40px;
}

.crypto-ticker-label {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #e89b2d;
  color: #fff;
  font-weight: 700;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0 16px;
  height: 100%;
  white-space: nowrap;
  flex-shrink: 0;
  z-index: 2;
}

.crypto-ticker-label .pulse-dot {
  width: 8px;
  height: 8px;
  background-color: #fff;
  border-radius: 50%;
  display: inline-block;
  animation: pulse-dot 1.8s infinite;
}

@keyframes pulse-dot {
  0% { transform: scale(0.9); opacity: 0.7; }
  50% { transform: scale(1.3); opacity: 1; }
  100% { transform: scale(0.9); opacity: 0.7; }
}

.crypto-ticker-track {
  display: flex;
  white-space: nowrap;
  animation: ticker-slide 38s linear infinite;
  will-change: transform;
}

.crypto-ticker-wrap:hover .crypto-ticker-track {
  animation-play-state: paused;
}

@keyframes ticker-slide {
  0% { transform: translate3d(0, 0, 0); }
  100% { transform: translate3d(-50%, 0, 0); }
}

.crypto-item {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0 20px;
  color: #e2e8f0;
  border-right: 1px solid rgba(255, 255, 255, 0.06);
  cursor: pointer;
  transition: opacity 0.2s;
}

.s-light .crypto-item {
  color: #1e293b;
  border-right: 1px solid rgba(0, 0, 0, 0.06);
}

.crypto-item:hover {
  opacity: 0.85;
}

.crypto-item .crypto-symbol {
  font-weight: 700;
  color: #fff;
}

.s-light .crypto-item .crypto-symbol {
  color: #0f172a;
}

.crypto-item .crypto-price {
  font-weight: 600;
}

.crypto-badge {
  display: inline-flex;
  align-items: center;
  font-size: 11px;
  font-weight: 600;
  padding: 2px 6px;
  border-radius: 4px;
}

.crypto-badge.up {
  color: #10b981;
  background: rgba(16, 185, 129, 0.12);
}

.crypto-badge.down {
  color: #ef4444;
  background: rgba(239, 68, 68, 0.12);
}

/* Template Switcher Demo Nav Banner */
.demo-template-nav {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background: #152844;
  color: #fff;
  border-radius: 30px;
  padding: 8px 18px;
  box-shadow: 0 10px 25px -5px rgba(0,0,0,0.5), 0 0 0 1px rgba(255,255,255,0.15);
  z-index: 9999;
  font-family: var(--title-font, "Inter", sans-serif);
  font-size: 13px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 12px;
  backdrop-filter: blur(8px);
}

.demo-template-nav .badge-tag {
  background: #e89b2d;
  color: #000;
  font-weight: 800;
  font-size: 10px;
  text-transform: uppercase;
  padding: 3px 8px;
  border-radius: 12px;
}

.demo-template-nav select {
  background: #111c2d;
  color: #fff;
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: 6px;
  padding: 4px 10px;
  font-size: 12px;
  cursor: pointer;
  outline: none;
}

/* Animations for dropdowns and mega menus */
.navigation .menu > li > .sub-menu,
.navigation .menu > li > .mega-menu {
  display: block;
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: opacity 0.25s cubic-bezier(0.16, 1, 0.3, 1), transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.25s;
  pointer-events: none;
}

.navigation .menu > li:hover > .sub-menu,
.navigation .menu > li:hover > .mega-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  pointer-events: auto;
}

/* Nested flyout dropdown animations */
.navigation .menu li li > .sub-menu {
  display: block;
  opacity: 0;
  visibility: hidden;
  transform: translateX(10px);
  transition: opacity 0.25s cubic-bezier(0.16, 1, 0.3, 1), transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.25s;
  pointer-events: none;
}

.navigation .menu li li:hover > .sub-menu {
  opacity: 1;
  visibility: visible;
  transform: translateX(0);
  pointer-events: auto;
}

/* Mega menu post hover effects */
.mega-menu article {
  transition: transform 0.2s ease;
}

.mega-menu article:hover {
  transform: translateY(-2px);
}

.mega-menu article .img {
  transition: transform 0.35s ease;
}

.mega-menu article:hover .img {
  transform: scale(1.04);
}

/* Image zoom effect on hover for post cards */
.post-card .img,
.grid-post .img,
.list-post .img,
.featured-post .img {
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

article:hover .img {
  transform: scale(1.04);
}

/* Sticky Header slide-down animation */
.smart-head-main.is-sticky {
  position: fixed !important;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 999;
  box-shadow: 0 4px 20px rgba(0,0,0,0.18);
  animation: sticky-slide-down 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes sticky-slide-down {
  from {
    transform: translateY(-100%);
  }
  to {
    transform: translateY(0);
  }
}

/* Off-canvas active state */
body.off-canvas-active {
  overflow: hidden;
}

body.off-canvas-active .off-canvas-backdrop {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

body.off-canvas-active .off-canvas {
  transform: translate3d(0, 0, 0) !important;
  visibility: visible !important;
}

.off-canvas-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(3px);
  z-index: 9998;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.35s ease, visibility 0.35s ease;
  pointer-events: none;
}

/* Search Modal enhancements */
.search-modal-custom {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(17, 28, 45, 0.95);
  backdrop-filter: blur(10px);
  z-index: 10002;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.search-modal-custom.is-open {
  opacity: 1;
  visibility: visible;
}

.search-modal-custom .modal-dialog {
  width: 100%;
  max-width: 680px;
  padding: 30px;
  position: relative;
  transform: translateY(-20px);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.search-modal-custom.is-open .modal-dialog {
  transform: translateY(0);
}

.search-modal-custom .close-btn {
  position: absolute;
  top: -40px;
  right: 30px;
  color: #fff;
  font-size: 32px;
  cursor: pointer;
  line-height: 1;
  opacity: 0.8;
  transition: opacity 0.2s;
}

.search-modal-custom .close-btn:hover {
  opacity: 1;
}

/* Review score box styling */
.review-score-box {
  background: #152844;
  border-radius: 8px;
  padding: 30px;
  margin: 35px 0;
  border: 1px solid rgba(255,255,255,0.08);
}

.s-light .review-score-box {
  background: #f8fafc;
  border: 1px solid rgba(0,0,0,0.08);
}

.review-score-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(255,255,255,0.1);
  padding-bottom: 20px;
  margin-bottom: 25px;
}

.review-badge-circle {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: #e89b2d;
  color: #fff;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  box-shadow: 0 4px 15px rgba(232, 155, 45, 0.4);
}

.review-badge-circle .score-num {
  font-size: 26px;
  line-height: 1;
}

.review-badge-circle .score-max {
  font-size: 11px;
  opacity: 0.85;
}

.review-bars {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-bottom: 30px;
}

.review-bar-item .bar-label-wrap {
  display: flex;
  justify-content: space-between;
  margin-bottom: 6px;
  font-weight: 600;
  font-size: 14px;
}

.review-bar-bg {
  width: 100%;
  height: 8px;
  background: rgba(255,255,255,0.1);
  border-radius: 4px;
  overflow: hidden;
}

.s-light .review-bar-bg {
  background: rgba(0,0,0,0.1);
}

.review-bar-fill {
  height: 100%;
  background: #e89b2d;
  border-radius: 4px;
  transition: width 1s ease-in-out;
}

.pros-cons-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

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

.pros-card, .cons-card {
  padding: 20px;
  border-radius: 6px;
}

.pros-card {
  background: rgba(16, 185, 129, 0.08);
  border: 1px solid rgba(16, 185, 129, 0.2);
}

.cons-card {
  background: rgba(239, 68, 68, 0.08);
  border: 1px solid rgba(239, 68, 68, 0.2);
}

.pros-card h4 {
  color: #10b981;
  margin-bottom: 15px;
  font-size: 16px;
}

.cons-card h4 {
  color: #ef4444;
  margin-bottom: 15px;
  font-size: 16px;
}

.pros-card ul, .cons-card ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.pros-card li, .cons-card li {
  position: relative;
  padding-left: 24px;
  margin-bottom: 10px;
  font-size: 14px;
}

.pros-card li:before {
  content: "✓";
  position: absolute;
  left: 0;
  color: #10b981;
  font-weight: bold;
}

.cons-card li:before {
  content: "✕";
  position: absolute;
  left: 0;
  color: #ef4444;
  font-weight: bold;
}

/* Ensure background images are always 100% visible and crisp */
.img.bg-cover,
.lazyload,
.lazyloading,
.lazyloaded {
  opacity: 1 !important;
  background-size: cover !important;
  background-position: center center !important;
  display: block;
}

/* Scheme Switcher button styling */
.scheme-switcher {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  position: relative;
  width: 36px;
  height: 36px;
  margin-right: 14px;
  cursor: pointer;
  z-index: 10;
}

.scheme-switcher .toggle {
  color: #ffffff !important;
  display: flex !important;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  text-decoration: none;
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
}

.scheme-switcher .toggle:hover {
  color: #e89b2d !important;
}

/* In dark mode: show toggle-light button (sun) */
html.s-dark .scheme-switcher .toggle-light,
html.site-s-dark .scheme-switcher .toggle-light {
  display: flex !important;
  position: relative !important;
  opacity: 1 !important;
  transform: none !important;
  pointer-events: auto !important;
}

html.s-dark .scheme-switcher .toggle-dark,
html.site-s-dark .scheme-switcher .toggle-dark {
  display: none !important;
  pointer-events: none !important;
}

/* In light mode: show toggle-dark button (moon) */
html.s-light .scheme-switcher .toggle-dark,
html.site-s-light .scheme-switcher .toggle-dark {
  display: flex !important;
  position: relative !important;
  opacity: 1 !important;
  transform: none !important;
  pointer-events: auto !important;
}

html.s-light .scheme-switcher .toggle-light,
html.site-s-light .scheme-switcher .toggle-light {
  display: none !important;
  pointer-events: none !important;
}

/* ==========================================================================
   WHITE CONTENT BACKGROUND
   ========================================================================== */

/* Body defaults to crisp white background */
body,
body.s-light,
body.site-s-light {
  background-color: #ffffff !important;
  color: #444444;
}

/* Explicitly ensure the article & main content area has a clean white background in default/light mode */
html:not(.s-dark) .main,
html:not(.s-dark) .main-content,
html:not(.s-dark) .the-post,
html:not(.s-dark) .post-wrap,
html:not(.s-dark) .post-content-wrap,
html:not(.s-dark) .post-content,
html.s-light .main,
html.s-light .main-content,
html.s-light .the-post,
html.s-light .post-wrap,
html.s-light .post-content-wrap,
html.s-light .post-content {
  background-color: #ffffff;
}

/* Breadcrumbs bar background in light mode */
html:not(.s-dark) .breadcrumbs,
html.s-light .breadcrumbs {
  background-color: #ffffff;
  color: #64748b;
}

/* In default/light mode: article text & headings contrast */
html:not(.s-dark) .post-content,
html:not(.s-dark) .post-content p,
html.s-light .post-content,
html.s-light .post-content p {
  color: #333333;
}

html:not(.s-dark) .main-content h1,
html:not(.s-dark) .main-content h2,
html:not(.s-dark) .main-content h3,
html:not(.s-dark) .main-content h4,
html:not(.s-dark) .the-post .post-title,
html.s-light .main-content h1,
html.s-light .main-content h2,
html.s-light .main-content h3,
html.s-light .main-content h4,
html.s-light .the-post .post-title {
  color: #111111;
}

/* Only when dark mode is explicitly active on html: dark navy background */
html.s-dark body,
html.site-s-dark body {
  background-color: #111c2d !important;
  color: #cbd5e1;
}

html.s-dark .main,
html.s-dark .the-post,
html.s-dark .post-wrap,
html.s-dark .post-content-wrap,
html.s-dark .post-content {
  background-color: transparent;
}

/* ==========================================================================
   HIGH CONTRAST & LEGIBILITY ENHANCEMENTS (Fixes text blending into background)
   ========================================================================== */

/* 1. Gutenberg Callout Blocks & Light Groups in Dark Mode */
.s-dark .has-very-light-gray-background-color,
.site-s-dark .has-very-light-gray-background-color,
.s-dark .wp-block-group.has-very-light-gray-background-color,
.site-s-dark .wp-block-group.has-very-light-gray-background-color,
.s-dark .wp-block-group.has-background,
.site-s-dark .wp-block-group.has-background {
  background-color: #15263d !important;
  color: #f1f5f9 !important;
  border: 1px solid rgba(255, 255, 255, 0.12) !important;
  border-left: 4px solid var(--c-main, #e89b2d) !important;
  border-radius: 6px;
  padding: 1.5em 2em !important;
}

.s-dark .has-very-light-gray-background-color *,
.site-s-dark .has-very-light-gray-background-color *,
.s-dark .wp-block-group.has-very-light-gray-background-color *,
.site-s-dark .wp-block-group.has-very-light-gray-background-color *,
.s-dark .wp-block-group.has-background * {
  color: #f1f5f9 !important;
}

.s-dark .has-very-light-gray-background-color strong,
.site-s-dark .has-very-light-gray-background-color strong,
.s-dark .wp-block-group.has-very-light-gray-background-color strong {
  color: #ffffff !important;
  font-weight: 700 !important;
}

.s-dark .has-very-light-gray-background-color a,
.site-s-dark .has-very-light-gray-background-color a {
  color: #fbbf24 !important;
  text-decoration: underline;
}

.s-light .has-very-light-gray-background-color,
.site-s-light .has-very-light-gray-background-color,
.wp-block-group.has-very-light-gray-background-color {
  background-color: #f1f5f9;
  color: #1e293b;
  border-left: 4px solid var(--c-main, #e89b2d);
}

.s-light .has-very-light-gray-background-color *,
.site-s-light .has-very-light-gray-background-color * {
  color: #1e293b;
}

/* 2. Review Box & Rating Criteria in Dark Mode */
.s-dark .review-box,
.site-s-dark .review-box {
  background: rgba(255, 255, 255, 0.04) !important;
  border-left: 3px solid var(--c-main, #e89b2d) !important;
}

.s-dark .review-box .criteria .label,
.site-s-dark .review-box .criteria .label {
  color: #e2e8f0 !important;
  font-weight: 500;
}

.s-dark .review-box .criteria .rating,
.site-s-dark .review-box .criteria .rating,
.review-box .criteria strong.rating,
.review-box .main-stars span strong.rating,
.s-dark .review-box .main-stars span strong,
.site-s-dark .review-box .main-stars span strong {
  color: #ffffff !important;
  font-weight: 700 !important;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.8);
}

.s-dark .review-box .summary,
.s-dark .review-box .summary p,
.site-s-dark .review-box .summary p {
  color: #cbd5e1 !important;
  line-height: 1.7;
}

.s-dark .review-box .overall .verdict,
.site-s-dark .review-box .overall .verdict {
  color: #ffffff !important;
}

.s-dark .review-box .overall .number,
.site-s-dark .review-box .overall .number {
  color: #ffffff !important;
}

/* 3. Pullquotes, Blockquotes & Citations */
.s-dark .wp-block-pullquote blockquote p,
.site-s-dark .wp-block-pullquote blockquote p,
.s-dark blockquote p,
.site-s-dark blockquote p {
  color: #f8fafc !important;
}

.s-dark .wp-block-pullquote cite,
.site-s-dark .wp-block-pullquote cite,
.s-dark blockquote cite,
.site-s-dark blockquote cite {
  color: #94a3b8 !important;
  font-weight: 600 !important;
  font-style: normal;
}

.s-dark figcaption,
.site-s-dark figcaption {
  color: #94a3b8 !important;
}

/* 4. Breadcrumbs */
.s-dark .breadcrumbs,
.site-s-dark .breadcrumbs,
.s-dark .breadcrumbs a,
.site-s-dark .breadcrumbs a {
  color: #94a3b8 !important;
}

.s-dark .breadcrumbs a:hover,
.site-s-dark .breadcrumbs a:hover {
  color: #e89b2d !important;
}

.s-dark .breadcrumbs .current,
.site-s-dark .breadcrumbs .current {
  color: #e2e8f0 !important;
  font-weight: 500;
}

.s-dark .breadcrumbs .delim,
.site-s-dark .breadcrumbs .delim {
  color: #64748b !important;
}

/* 5. Post Meta & Subtext */
.s-dark .post-meta,
.site-s-dark .post-meta {
  color: #94a3b8 !important;
}

.s-dark .post-meta a:not(.category),
.site-s-dark .post-meta a:not(.category) {
  color: #cbd5e1 !important;
}

.s-dark .post-meta a:not(.category):hover,
.site-s-dark .post-meta a:not(.category):hover {
  color: #e89b2d !important;
}

.s-dark .post-meta .date,
.site-s-dark .post-meta .date,
.s-dark .post-meta .read-time,
.site-s-dark .post-meta .read-time,
.s-dark .post-meta .updated-on,
.site-s-dark .post-meta .updated-on {
  color: #94a3b8 !important;
}

/* 6. Post Excerpts & Article Text */
.s-dark .excerpt,
.site-s-dark .excerpt,
.s-dark .post-excerpt,
.site-s-dark .post-excerpt {
  color: #cbd5e1 !important;
}

.s-dark .post-content p,
.site-s-dark .post-content p {
  color: #e2e8f0;
}

/* 7. Lower Footer & Copyright */
.s-dark .lower-footer,
.site-s-dark .lower-footer,
.s-dark .lower-footer .copyright,
.site-s-dark .lower-footer .copyright,
.s-dark .lower-footer a,
.site-s-dark .lower-footer a {
  color: #94a3b8 !important;
}

.s-dark .lower-footer a:hover,
.site-s-dark .lower-footer a:hover {
  color: #e89b2d !important;
}

/* 8. Category Badges - Enhanced Readability */
.cat-labels a,
.cat-labels .category,
.s-dark .cat-labels a,
.s-dark .cat-labels .category,
.site-s-dark .cat-labels a,
.site-s-dark .cat-labels .category,
.s-dark .post-meta .cat-labels a,
.site-s-dark .post-meta .cat-labels a,
.post-meta .cat-labels a,
.post-meta .cat-labels .category {
  color: #ffffff !important;
  font-weight: 700 !important;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
  letter-spacing: 0.04em;
}

/* 9. Form Inputs & Textareas */
.s-dark input[type="text"],
.s-dark input[type="search"],
.s-dark input[type="email"],
.s-dark input[type="url"],
.s-dark input[type="tel"],
.s-dark textarea,
.s-dark select,
.site-s-dark input[type="text"],
.site-s-dark input[type="search"],
.site-s-dark input[type="email"],
.site-s-dark input[type="url"],
.site-s-dark input[type="tel"],
.site-s-dark textarea,
.site-s-dark select {
  color: #ffffff !important;
  background-color: #142135 !important;
  border-color: rgba(255, 255, 255, 0.2) !important;
}

.s-dark input::placeholder,
.s-dark textarea::placeholder,
.site-s-dark input::placeholder,
.site-s-dark textarea::placeholder {
  color: #94a3b8 !important;
  opacity: 1 !important;
}

.s-light input[type="text"],
.s-light input[type="search"],
.s-light input[type="email"],
.s-light input[type="url"],
.s-light input[type="tel"],
.s-light textarea,
.s-light select,
.site-s-light input[type="text"],
.site-s-light input[type="search"],
.site-s-light input[type="email"],
.site-s-light input[type="url"],
.site-s-light input[type="tel"],
.site-s-light textarea,
.site-s-light select {
  color: #0f172a !important;
  background-color: #ffffff !important;
  border-color: #cbd5e1 !important;
}

.s-light input::placeholder,
.s-light textarea::placeholder,
.site-s-light input::placeholder,
.site-s-light textarea::placeholder {
  color: #64748b !important;
  opacity: 1 !important;
}

/* 10. Comments Section Contrast */
.s-dark .comments-area,
.site-s-dark .comments-area {
  color: #e2e8f0;
}

.s-dark .comments-area .comment-content,
.site-s-dark .comments-area .comment-content {
  color: #e2e8f0 !important;
}

.s-dark .comments-area .comment-author,
.site-s-dark .comments-area .comment-author,
.s-dark .comments-area .comment-author a,
.site-s-dark .comments-area .comment-author a {
  color: #f8fafc !important;
  font-weight: 600;
}

.s-dark .comments-area .comment-metadata,
.site-s-dark .comments-area .comment-metadata,
.s-dark .comments-area .comment-metadata time,
.site-s-dark .comments-area .comment-metadata time {
  color: #94a3b8 !important;
}

.s-dark .comments-area .reply a,
.site-s-dark .comments-area .reply a {
  color: #e89b2d !important;
  font-weight: 600;
}

/* 11. Author Box Contrast */
.s-dark .post-author-box,
.site-s-dark .post-author-box {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.s-dark .post-author-box .box-title,
.site-s-dark .post-author-box .box-title {
  color: #f8fafc !important;
}

.s-dark .post-author-box .author-bio,
.site-s-dark .post-author-box .author-bio {
  color: #cbd5e1 !important;
}

