/* ==========================================================================
   Simodi — WordPress & Elementor compatibility
   Keeps the Simodi design identical inside Elementor's wrappers, and styles
   regular WordPress pages, posts and the blog index in the same look.
   ========================================================================== */

/* Fixed nav sits below the WordPress admin bar when logged in */
.admin-bar .nav { top: 32px; }
@media (max-width: 782px) { .admin-bar .nav { top: 46px; } }
/* On phones the admin bar scrolls away, so the nav moves up once the page scrolls */
@media (max-width: 600px) { .admin-bar .nav.is-scrolled { top: 0; } }

/* Elementor rows that hold Simodi sections: full width, no padding, no gaps */
.elementor-section.simodi-row > .elementor-container { max-width: none; }
.elementor-section.simodi-row > .elementor-container > .elementor-column > .elementor-widget-wrap { padding: 0; }
.elementor-widget[class*="elementor-widget-simodi-"] { margin: 0; margin-block-end: 0; }
.elementor-widget[class*="elementor-widget-simodi-"] > .elementor-widget-container { margin: 0; padding: 0; }

/* Elementor resets image height inside .elementor; restore Simodi image sizing */
.elementor .product__img img,
.elementor .post__img img { height: 100%; }
.elementor .logo-strip__list img { height: var(--h, 44px); max-width: 160px; }
.elementor .compare__logo { height: 22px; }
@media (max-width: 700px) {
  .elementor .logo-strip__list img { height: calc(var(--h, 44px) * 0.75); max-width: 120px; }
}

/* Four-column feature grid (Our Values): steps down on smaller screens */
.lines.lines--4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 920px) { .lines.lines--4 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .lines.lines--4 { grid-template-columns: 1fr; } }

/* Elementor editor: show animated content straight away while editing */
.elementor-editor-active .reveal,
.elementor-editor-active .flow__phone,
.elementor-editor-active .flow__label { opacity: 1 !important; transform: none; translate: none !important; }

/* ---------- Regular pages, posts and the blog index ---------- */

.simodi-page { padding: 168px 0 112px; }
.simodi-page__narrow { max-width: 840px; }
.simodi-page__head { display: grid; gap: 16px; margin-bottom: 40px; }
.simodi-page__head h1 { font-size: clamp(36px, 5vw, 60px); }
.simodi-page__thumb { margin-bottom: 40px; border-radius: var(--radius-lg); overflow: hidden; }
.simodi-page__thumb img { width: 100%; height: auto; }

.entry-content { color: var(--muted); font-size: 17px; line-height: 1.75; }
.entry-content > * + * { margin-top: 1.1em; }
.entry-content h2, .entry-content h3, .entry-content h4 { color: var(--text); margin-top: 1.8em; }
.entry-content h2 { font-size: clamp(26px, 3vw, 36px); }
.entry-content h3 { font-size: 22px; }
.entry-content a { color: var(--gold); text-decoration: underline; text-underline-offset: 3px; }
.entry-content ul, .entry-content ol { padding-left: 1.3em; }
.entry-content blockquote { margin: 1.6em 0; padding-left: 20px; border-left: 2px solid var(--accent); color: var(--text); }
.entry-content img { border-radius: var(--radius); height: auto; }
.entry-content strong { color: var(--text); }
.entry-content figure { margin-left: 0; margin-right: 0; overflow-x: auto; }
.entry-content table { width: 100%; border-collapse: collapse; font-size: 15px; }
.entry-content th, .entry-content td { padding: 12px 14px; border: 1px solid var(--line-2); text-align: left; vertical-align: top; }
.entry-content th { color: var(--text); font-weight: 600; }

.simodi-pagination { margin-top: 48px; }
.simodi-pagination .nav-links { display: flex; gap: 8px; flex-wrap: wrap; }
.simodi-pagination .page-numbers {
  display: inline-grid;
  place-items: center;
  min-width: 42px;
  height: 42px;
  padding: 0 14px;
  border-radius: 999px;
  border: 1px solid var(--line-2);
  color: var(--muted);
  font-size: 14px;
}
.simodi-pagination .page-numbers.current,
.simodi-pagination .page-numbers:hover { background: var(--gold-solid); border-color: var(--gold-solid); color: var(--on-gold); }

/* WordPress core helper classes */
.screen-reader-text { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.alignleft { float: left; margin: 0 1.5em 1em 0; }
.alignright { float: right; margin: 0 0 1em 1.5em; }
.aligncenter { display: block; margin-left: auto; margin-right: auto; }
.wp-caption-text { font-size: 13px; color: var(--dim); margin-top: 8px; }

/* Comments */
.comments-area { margin-top: 64px; padding-top: 40px; border-top: 1px solid var(--line); color: var(--muted); }
.comments-area input[type="text"],
.comments-area input[type="email"],
.comments-area input[type="url"],
.comments-area textarea {
  width: 100%;
  padding: 12px 16px;
  border-radius: 12px;
  border: 1px solid var(--line-2);
  background: var(--surface);
  color: var(--text);
}
.comments-area .submit { height: 48px; padding: 0 22px; border-radius: 999px; border: 0; background: var(--gold-solid); color: var(--on-gold); font-weight: 600; cursor: pointer; }

/* ---------- Contact form messages ---------- */
.form__status.is-error { color: #f87171; }
.simodi-light .form__status.is-error { color: #b42318; }

/* ---------- Social icons (footer and contact section) ---------- */
.social-icons { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 6px; }
.social-icons__item {
  display: inline-grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid var(--gold);
  color: var(--gold);
  transition: background 0.2s ease, color 0.2s ease;
}
a.social-icons__item:hover { background: var(--gold-solid); border-color: var(--gold-solid); color: var(--on-gold); }
.social-icons svg { width: 19px; height: 19px; }

/* ---------- Live gold price (menu bar) ---------- */
.gold-price {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  height: 40px;
  padding: 0 14px;
  border-radius: 999px;
  border: 1px solid var(--line-2);
  background: rgb(var(--ink-rgb) / 0.03);
  color: var(--text);
  font-size: 12.5px;
  font-weight: 600;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.gold-price__dot { width: 6px; height: 6px; flex: none; border-radius: 50%; background: var(--dim); }
.gold-price.is-live .gold-price__dot { background: #4ade80; box-shadow: 0 0 0 3px rgba(74, 222, 128, 0.18); animation: pulse 1.8s ease-in-out infinite; }
.gold-price__label { font-size: 11px; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); }
.gold-price__value { color: var(--gold); }
.gold-price__arrow { width: 8px; font-size: 9px; line-height: 1; }
.gold-price__arrow.is-up { color: #4ade80; }
.gold-price__arrow.is-down { color: #f87171; }
.simodi-light .gold-price__arrow.is-up { color: #2f7a43; }
.simodi-light .gold-price__arrow.is-down { color: #b42318; }
.gold-price__unit { font-weight: 500; color: var(--muted); }

/* ---------- Dark / light toggle ---------- */
.theme-toggle {
  display: inline-grid;
  place-items: center;
  flex: none;
  width: 40px;
  height: 40px;
  padding: 0;
  border-radius: 50%;
  border: 1px solid var(--line-2);
  background: transparent;
  color: var(--text);
  cursor: pointer;
  transition: border-color 0.2s ease, color 0.2s ease;
}
.theme-toggle:hover { border-color: var(--gold); color: var(--gold); }
.theme-toggle svg { width: 17px; height: 17px; }
.simodi-dark .theme-toggle__moon,
.simodi-light .theme-toggle__sun { display: none; }
/* no colour transitions while the stylesheets swap */
.simodi-switching *, .simodi-switching *::before, .simodi-switching *::after { transition: none !important; }

/* ---------- Logo: fixed size in every browser ---------- */
/* Safari and some others let a crowded flex bar squeeze the logo out of shape. */
.nav__logo { flex: none; display: inline-flex; align-items: center; }
.nav__logo img,
.footer__brand img { flex: none; width: auto; max-width: none; height: 34px; aspect-ratio: auto 480 / 149; object-fit: contain; }
.footer__brand img { height: 36px; }

/* ---------- Menu bar spacing with the price and toggle ---------- */
.nav__links a { white-space: nowrap; }
.nav__extras { display: none; }
/* Wide screens: a little more room so the full price pill fits */
@media (min-width: 1400px) { .nav .nav__inner { max-width: 1320px; } }
@media (max-width: 1399px) { .nav .gold-price__label { display: none; } }
@media (max-width: 1260px) { .nav__links a { padding: 8px 10px; } }
/* Below 1120px the links move into the menu button, so the bar never crowds */
@media (max-width: 1120px) {
  .nav__links { display: none; }
  .nav__toggle { display: inline-flex; }
  .nav.is-open .nav__links {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    position: absolute;
    top: 76px;
    left: 0;
    right: 0;
    padding: 12px var(--gutter) 24px;
    border-bottom: 1px solid var(--line);
    gap: 2px;
  }
  .simodi-dark .nav.is-open .nav__links { background: rgba(11, 10, 9, 0.97); }
  .simodi-light .nav.is-open .nav__links { background: rgba(247, 243, 236, 0.98); }
  .nav.is-open .nav__links a { padding: 14px 12px; font-size: 16px; border-radius: 12px; }
  .nav .gold-price__label { display: inline; }
}
/* Phones: the price and toggle sit at the bottom of the open menu */
@media (max-width: 640px) {
  .nav__cta .gold-price,
  .nav__cta .theme-toggle { display: none; }
  .nav.is-open .nav__extras {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-top: 8px;
    padding: 16px 12px 4px;
    border-top: 1px solid var(--line);
  }
}

/* ---------- Hero video overlay strength (Elementor: Hero → Video) ---------- */
.simodi-dark .hero__bg::after {
  background:
    radial-gradient(ellipse 75% 70% at 50% 50%, rgba(11, 10, 9, 0) 35%, rgba(11, 10, 9, calc(0.55 * var(--hero-overlay-dark, 1))) 100%),
    radial-gradient(ellipse 45% 35% at 50% 48%, rgba(11, 10, 9, calc(0.3 * var(--hero-overlay-dark, 1))) 0%, rgba(11, 10, 9, 0) 100%),
    linear-gradient(180deg,
      rgba(11, 10, 9, calc(0.6 * var(--hero-overlay-dark, 1))) 0%,
      rgba(11, 10, 9, calc(0.32 * var(--hero-overlay-dark, 1))) 45%,
      rgba(11, 10, 9, calc(0.82 * var(--hero-overlay-dark, 1))) 90%,
      var(--bg) 100%);
}
.simodi-light .hero__bg::after {
  background:
    radial-gradient(ellipse 75% 70% at 50% 50%, rgba(247, 243, 236, 0) 35%, rgba(247, 243, 236, calc(0.6 * var(--hero-overlay-light, 0.55))) 100%),
    radial-gradient(ellipse 45% 35% at 50% 48%, rgba(247, 243, 236, calc(0.35 * var(--hero-overlay-light, 0.55))) 0%, rgba(247, 243, 236, 0) 100%),
    linear-gradient(180deg,
      rgba(247, 243, 236, calc(0.85 * var(--hero-overlay-light, 0.55))) 0%,
      rgba(247, 243, 236, calc(0.6 * var(--hero-overlay-light, 0.55))) 45%,
      rgba(247, 243, 236, calc(0.9 * var(--hero-overlay-light, 0.55))) 90%,
      var(--bg) 100%);
}

/* Platform card chart colour follows the active scheme */
:root { --spark-color: #d6c4a2; }
.simodi-light { --spark-color: #7a6245; }
