/*
Theme Name: ExploreCity
Theme URI: https://explorecity.local/
Description: ExploreCity landing child theme for Twenty Twenty-Four.
Author: ExploreCity
Template: twentytwentyfour
Version: 1.0.0
Text Domain: explorecity
*/


/* =============================================================
   Quest Istanbul — landing page styles

   How to use on WordPress:
   1. Upload this file (style.css) and your hero photo (background-image.jpg)
      into your active theme folder, e.g. /wp-content/themes/<theme>/
      or into a child theme. Alternatively put them under the
      Uploads folder and adjust the path below.
   2. Enqueue the stylesheet from functions.php:
        wp_enqueue_style(
          'quest-istanbul',
          get_stylesheet_directory_uri() . '/style.css'
        );
      Or simply paste the markup from index.html into a "Custom HTML"
      block on a page and add the <link> tag to the page head.
   3. Replace the file `background-image.jpg` (referenced below in `.hero`)
      with your own photo. Same file name = no CSS edits needed.
   4. Font Awesome and Google Fonts are loaded from CDNs in
      index.html, no extra setup required.
   ============================================================= */

/* ---------- Reset & base ---------- */

*,
*::before,
*::after {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html,
body {
  margin: 0;
  padding: 0;
  scroll-behavior: smooth;
}

body {
  font-family: 'Manrope', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  font-size: 1rem;
  line-height: 1.5;
  color: var(--text-dark);
  background: var(--bg-light);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  padding-top: var(--header-height);
}

/* Fixed header is taller than --header-height (padding + logo lines); inner pages rely on body offset only — add a bit of slack so titles do not tuck under it. Hero on .home unchanged (negative hero margin stays matched to --header-height). */
body:not(.home) {
  padding-top: calc(var(--header-height) + clamp(0.3125rem, 1vw, 0.75rem));
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

body a,
body a:hover {
  text-decoration: none;
}

h1, h2, h3, h4 {
  margin: 0;
  font-weight: 800;
  line-height: 1.1;
}

p {
  margin: 0;
}

/* ---------- Design tokens ---------- */

:root {
  --header-height: 4rem;
  --accent: #F9E14C;
  --accent-hover: #ffe96b;
  --bg-dark: #0e0e0e;
  --card-bg: rgba(20, 20, 20, 0.78);
  --card-border: rgba(255, 255, 255, 0.06);
  --dark-btn: #1c1c1c;
  --dark-btn-hover: #2a2a2a;
  --text: #ffffff;
  --text-muted: rgba(255, 255, 255, 0.72);
  --text-dim: rgba(255, 255, 255, 0.55);

  /* Light section tokens */
  --bg-light: #ededed;
  --bg-light-soft: #f6f6f6;
  --card-light-bg: #ffffff;
  --card-light-border: rgba(0, 0, 0, 0.06);
  --text-dark: #1a1a1a;
  --text-dark-muted: #4a4a4a;
  --text-dark-dim: #888888;
  --shadow-light: 0 0.375rem 1.125rem rgba(0, 0, 0, 0.06);

  --radius-lg: 1.125rem;
  --radius-md: 0.875rem;
  /* Fully rounded ends; large rem avoids px while staying finite */
  --radius-pill: 50rem;
  --shadow-card: 0 1.125rem 2.5rem rgba(0, 0, 0, 0.35);
  --container: 77.5rem;
  --gutter: 2rem;
}

@media (max-width: 720px) {
  :root {
    --header-height: 3.5rem;
  }
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.625rem;
  padding: 1rem 1.625rem;
  border: 0;
  border-radius: var(--radius-pill);
  font-family: inherit;
  font-weight: 800;
  font-size: 0.8125rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background-color .2s ease, transform .15s ease, box-shadow .2s ease;
  white-space: nowrap;
}

.btn:hover {
  transform: translateY(-0.0625rem);
}

.btn-primary {
  background: var(--accent);
  color: #111;
  box-shadow: 0 0.5rem 1.375rem rgba(249, 225, 76, 0.25);
}

.btn-primary:hover {
  background: var(--accent-hover);
}

.btn-dark {
  background: var(--dark-btn);
  color: #fff;
}

.btn-dark:hover {
  background: var(--dark-btn-hover);
}

.btn-sm {
  padding: 0.75rem 1.375rem;
  font-size: 0.75rem;
}

.btn-hero {
  padding-left: 3rem;
  padding-right: 3rem;
  min-width: 250px;
  justify-content: center;
}

/* ---------- Header ---------- */

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  padding: 1rem var(--gutter);
  background: rgba(14, 14, 14, 0.8);
  -webkit-backdrop-filter: blur(0.75rem);
  backdrop-filter: blur(0.75rem);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  transition: background-color 0.3s ease, padding 0.3s ease;
  width: 100%;
}

.site-header-container {
  display: flex;
  align-items: center;
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  gap: 2rem;
  position: relative;
}

.nav-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 0.3125rem;
  width: 2.75rem;
  height: 2.75rem;
  margin-left: auto;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 0.5rem;
  background: rgba(255, 255, 255, 0.06);
  color: #fff;
  cursor: pointer;
  transition: background-color 0.2s ease, border-color 0.2s ease;
  -webkit-tap-highlight-color: transparent;
}

.nav-toggle:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.35);
}

.nav-toggle-bar {
  display: block;
  width: 1.125rem;
  height: 0.125rem;
  border-radius: 0.0625rem;
  background: currentColor;
  transition: transform 0.25s ease, opacity 0.2s ease;
}

.site-header.nav-open .nav-toggle-bar:nth-child(1) {
  transform: translateY(0.4375rem) rotate(45deg);
}

.site-header.nav-open .nav-toggle-bar:nth-child(2) {
  opacity: 0;
}

.site-header.nav-open .nav-toggle-bar:nth-child(3) {
  transform: translateY(-0.4375rem) rotate(-45deg);
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 0.625rem;
  color: #fff;
  font-weight: 800;
  letter-spacing: 0.08em;
  flex-shrink: 0;
}

.logo-icon {
  width: 1.625rem;
  height: auto;
}

.logo-text {
  font-size: 0.875rem;
  line-height: 1;
  display: inline-flex;
  flex-direction: column;
  gap: 0.125rem;
}

.logo-text-secondary {
  font-weight: 800;
  letter-spacing: 0.18em;
}

.main-nav {
  display: flex;
  gap: 2.25rem;
  margin-left: 1.5rem;
  flex: 1;
}

.main-nav a {
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #fff;
  transition: color .2s ease, opacity .2s ease;
}

.main-nav a:hover {
  color: var(--accent);
  opacity: 1;
}

.nav-author-link {
  font-style: italic;
  text-transform: uppercase !important;
}

.auth {
  display: flex;
  align-items: center;
  gap: 1.375rem;
}

.login-link {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #fff;
}

.login-link:hover {
  color: var(--accent);
}

/* ---------- Hero ---------- */

.hero {
  position: relative;
  min-height: 100vh;
  margin-top: calc(-1 * var(--header-height));
  padding: 7.5rem var(--gutter) 7.5rem;
  /* Layers (top → bottom):
     1) vertical fade to light bg at the very bottom — bridges the dark hero
        into the light content section that follows
     2) clear "window" at centre (people stay bright); edges use 35% black overlay
     3) hero photo */
  background-image:
    radial-gradient(
      ellipse 52% 58% at 50% 50%,
      rgba(0, 0, 0, 0) 0%,
      rgba(0, 0, 0, 0) 40%,
      rgba(0, 0, 0, 0.35) 72%,
      rgba(0, 0, 0, 0.35) 100%
    ),
    url('background-image.jpg');
  background-size: contain;
  background-position: center;
  background-repeat: no-repeat;
  background-color: #1d1d1d; /* fallback while photo is missing */
  overflow: hidden;
}

.hero-inner {
  position: relative;
  max-width: var(--container);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 16rem;
  gap: 2.5rem;
  align-items: start;
  min-height: 60vh;
}

.hero-content {
  max-width: 38.75rem;
  padding-top: 2.5rem;
}

.hero-title {
  font-size: clamp(2.375rem, 5vw, 4rem);
  font-weight: 800;
  letter-spacing: -0.01em;
  text-transform: uppercase;
  color: #fff;
  text-shadow: 
    0 0.125rem 0.375rem rgba(0, 0, 0, 0.8),
    0 0 1.5rem rgba(0, 0, 0, 0.6),
    0 0 3rem rgba(0, 0, 0, 0.4);
}

.hero-lead {
  margin-top: 1.375rem;
  font-size: 1.125rem;
  line-height: 1.55;
  color: #fff;
  max-width: 32.5rem;
  font-weight: 600;
  text-shadow: 
    0 0.0625rem 0.25rem rgba(0, 0, 0, 0.9),
    0 0 1.25rem rgba(0, 0, 0, 0.7);
}

.cta-buttons {
  margin-top: 2.25rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.875rem;
}

/* ---------- Live Progress Map ---------- */

.progress-map {
  margin-top: 2.5rem;
  background: var(--card-bg);
  -webkit-backdrop-filter: blur(0.625rem);
  backdrop-filter: blur(0.625rem);
  border: 1px solid var(--card-border);
  border-radius: var(--radius-md);
  padding: 0.875rem 1rem;
  color: #fff;
  box-shadow: var(--shadow-card);
  width: 100%;
  max-width: 16rem;
  justify-self: end;
}

.progress-map-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.5rem;
}

.progress-map-title {
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  color: rgba(255, 255, 255, 0.92);
}

.progress-map-dots {
  color: var(--accent);
  font-size: 0.875rem;
}

.map-mock {
  position: relative;
  height: 17rem;
  border-radius: 0.625rem;
  overflow: hidden;
  background: url('map_square.png') center / cover no-repeat;
}

.map-pin {
  position: absolute;
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
}

.map-pin > i {
  color: var(--accent);
  font-size: 1.125rem;
  filter: drop-shadow(0 0.125rem 0.25rem rgba(0, 0, 0, 0.6));
}

.map-pin-label {
  background: #fff;
  color: #111;
  font-size: 0.625rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  padding: 0.1875rem 0.5rem;
  border-radius: 0.25rem;
  white-space: nowrap;
  box-shadow: 0 0.125rem 0.375rem rgba(0, 0, 0, 0.4);
}

.map-pin--1 { top: 16.32%; left: 36.67%; }
.map-pin--2 { top: 81.58%; left: 9.70%; }
.map-pin--3 { top: 63.36%; left: 52.26%; }

.progress-map-foot {
  margin-top: 0.625rem;
  padding-top: 0.625rem;
  border-top: 1px solid rgba(255, 255, 255, 0.07);
  display: flex;
  flex-direction: column;
  gap: 0.125rem;
}

.progress-map-label {
  font-size: 0.6875rem;
  color: var(--text-dim);
  letter-spacing: 0.06em;
}

.progress-map-quest {
  font-size: 0.875rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  color: #fff;
}

.progress-map-percent {
  font-size: 0.6875rem;
  color: var(--text-muted);
}

/* ---------- Feature cards ---------- */

.feature-cards {
  position: relative;
  z-index: 2;
  max-width: var(--container);
  margin: 3.75rem auto 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.125rem;
}

.card {
  background: var(--card-bg);
  -webkit-backdrop-filter: blur(0.625rem);
  backdrop-filter: blur(0.625rem);
  border: 1px solid var(--card-border);
  border-radius: var(--radius-md);
  padding: 1.375rem 1.5rem 1.5rem;
  color: #fff;
  box-shadow: var(--shadow-card);
  transition: transform .25s ease, border-color .25s ease;
}

.card:hover {
  transform: translateY(-0.1875rem);
  border-color: rgba(249, 225, 76, 0.35);
}

.card-icons {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 0.875rem;
}

.card-icon-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.375rem;
  height: 2.375rem;
  border-radius: 0.5rem;
  background: rgba(255, 255, 255, 0.04);
  color: var(--accent);
  font-size: 1.125rem;
}

.card-title {
  font-size: 1.0625rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: 0.375rem;
}

.card-text {
  font-size: 0.8125rem;
  line-height: 1.55;
  color: var(--text-muted);
}

/* =============================================================
   Light content section (after the dark hero)
   ============================================================= */

.content-light {
  background: var(--bg-light);
  color: var(--text-dark);
  position: relative;
  z-index: 10;
}

.hero + .content-light,
.hero + main.content-light {
  /* −1px: плотнее к герою, без субпиксельной щели на части зумов */
  margin-top: calc(-3.75rem - 1px);
}

.content-light::before {
  content: "";
  position: absolute;
  /* +1px вверх / +2px к высоте: перекрытие клипа и фона при дробном DPR */
  top: calc(-0.8125rem - 1px);
  left: 0;
  width: 100%;
  height: calc(0.8125rem + 2px);
  transform: translateZ(0);
  background-color: var(--bg-light);
  /* Высота 0.8125rem (10 * 1.3), частота в 2 раза меньше (шаг 2.5%) */
  clip-path: polygon(
    0% 100%, 0% 0%, 1.25% 100%, 2.5% 0%, 3.75% 100%, 5% 0%, 6.25% 100%, 7.5% 0%, 8.75% 100%, 10% 0%, 
    11.25% 100%, 12.5% 0%, 13.75% 100%, 15% 0%, 16.25% 100%, 17.5% 0%, 18.75% 100%, 20% 0%, 
    21.25% 100%, 22.5% 0%, 23.75% 100%, 25% 0%, 26.25% 100%, 27.5% 0%, 28.75% 100%, 30% 0%, 
    31.25% 100%, 32.5% 0%, 33.75% 100%, 35% 0%, 36.25% 100%, 37.5% 0%, 38.75% 100%, 40% 0%, 
    41.25% 100%, 42.5% 0%, 43.75% 100%, 45% 0%, 46.25% 100%, 47.5% 0%, 48.75% 100%, 50% 0%, 
    51.25% 100%, 52.5% 0%, 53.75% 100%, 55% 0%, 56.25% 100%, 57.5% 0%, 58.75% 100%, 60% 0%, 
    61.25% 100%, 62.5% 0%, 63.75% 100%, 65% 0%, 66.25% 100%, 67.5% 0%, 68.75% 100%, 70% 0%, 
    71.25% 100%, 72.5% 0%, 73.75% 100%, 75% 0%, 76.25% 100%, 77.5% 0%, 78.75% 100%, 80% 0%, 
    81.25% 100%, 82.5% 0%, 83.75% 100%, 85% 0%, 86.25% 100%, 87.5% 0%, 88.75% 100%, 90% 0%, 
    91.25% 100%, 92.5% 0%, 93.75% 100%, 95% 0%, 96.25% 100%, 97.5% 0%, 98.75% 100%, 100% 0%, 
    100% 100%
  );
}

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

/* Shared section heading */

.section-title {
  font-size: clamp(1.625rem, 3vw, 2.25rem);
  font-weight: 800;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--text-dark);
  line-height: 1.05;
}

.section-title--accent {
  color: var(--text-dark);
}

.section-title .accent-word,
.accent-word {
  color: var(--text-dark);
}

.section-heading-row {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  margin-bottom: 2.25rem;
}

.section-rule {
  flex: 1;
  height: 0.0625rem;
  background: var(--text-dark);
  opacity: 0.85;
}

/* ---------- The Quest Experience ---------- */

.quest-experience {
  padding: 5.625rem 0 4.375rem;
}

.experience-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
  gap: 3.75rem;
  align-items: center;
}

.experience-text .section-title {
  margin-bottom: 1.125rem;
}

.experience-lead {
  font-size: 1rem;
  line-height: 1.6;
  color: var(--text-dark-muted);
  max-width: 35rem;
}

.inline-icon {
  color: var(--text-dark);
  font-size: 0.875rem;
  margin: 0 0.125rem;
  vertical-align: -0.0625rem;
}

/* Riddle stack: two cards, one peeking behind the front one */

.riddle-stack {
  position: relative;
  justify-self: end;
  width: 100%;
  max-width: 26.25rem;
  height: 12.5rem;
}

.riddle-card {
  position: absolute;
  inset: 0;
  background: #1a1a1a;
  border: 0.09375rem solid #333;
  border-radius: 0.875rem;
  padding: 1.375rem 1.5rem;
  box-shadow: 0 0.625rem 1.875rem rgba(0, 0, 0, 0.18);
}

.riddle-card--front {
  transform: rotate(-3deg);
  z-index: 2;
  display: flex;
  align-items: center;
}

.riddle-card--back {
  transform: rotate(6deg) translate(1.75rem, 0.875rem);
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
}

.riddle-text {
  font-size: 1rem;
  line-height: 1.5;
  color: #ffffff;
  margin: 0;
}

.riddle-label {
  color: var(--accent);
  font-weight: 800;
  letter-spacing: 0.04em;
  margin-right: 0.25rem;
}

.riddle-key {
  color: var(--accent);
  font-size: 3.5rem;
  transform: rotate(35deg);
  filter: drop-shadow(0 0.25rem 0.5rem rgba(0, 0, 0, 0.4));
}

.riddle-card-tag {
  position: absolute;
  right: 0.625rem;
  bottom: 0.875rem;
  font-size: 0.5625rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  color: rgba(255, 255, 255, 0.55);
  writing-mode: vertical-rl;
  transform: rotate(180deg);
}

/* ---------- How It Works ---------- */

.how-it-works {
  padding: 3.125rem 0 5.625rem;
}

.steps-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-bottom: 1.75rem;
}

.step-card {
  background: var(--card-light-bg);
  border: 1px solid var(--card-light-border);
  border-radius: var(--radius-md);
  padding: 2.25rem 1.5rem 1.625rem;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.375rem;
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
  box-shadow: var(--shadow-light);
}

.step-card:hover {
  transform: translateY(-0.1875rem);
  border-color: var(--accent);
  box-shadow: 0 0.625rem 1.5rem rgba(0, 0, 0, 0.08);
}

.step-icon {
  font-size: 1.875rem;
  color: var(--text-dark);
  opacity: 0.85;
}

.step-title {
  font-size: 0.875rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-dark);
}

.steps-progress {
  position: relative;
  height: 0.0625rem;
  background: var(--text-dark);
  opacity: 0.85;
  margin: 0 8%;
}

.steps-progress-dot {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0.875rem;
  height: 0.875rem;
  background: var(--text-dark);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  box-shadow: 0 0 0 0.25rem rgba(0, 0, 0, 0.05);
}

/* ---------- Popular Quests ---------- */

.inside-quest {
  position: relative;
  padding: 1.875rem 0 3.125rem;
}

.inside-quest .section-title {
  margin-bottom: 2.25rem;
  text-align: center;
}

.popular-quests-query .wp-block-post-template,
.quests-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-bottom: 2.5rem;
  padding: 0;
  list-style: none;
}

.popular-quests-query .wp-block-post {
  margin: 0;
  display: flex;
}

.quest-item {
  background: var(--card-light-bg);
  border: 1px solid var(--card-light-border);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-light);
  transition: transform .25s ease, box-shadow .25s ease;
  display: flex;
  flex-direction: column;
  width: 100%;
}

.quest-item:hover {
  transform: translateY(-0.3125rem);
  box-shadow: 0 0.75rem 1.75rem rgba(0, 0, 0, 0.1);
}

.quest-img {
  width: 100%;
  aspect-ratio: 16 / 10;
  background-size: cover;
  background-position: center;
  background-color: #b8b8b8;
  position: relative;
  display: block;
  margin: 0;
  overflow: hidden;
}

.quest-img a,
.quest-img img {
  display: block;
  width: 100%;
  height: 100%;
}

.quest-img img {
  object-fit: cover;
}

/* WooCommerce / Tours page consistency */
.wc-block-components-product-image,
.wp-block-woocommerce-product-image {
  aspect-ratio: 16 / 10 !important;
  overflow: hidden !important;
  margin: 0 !important;
  padding: 0 !important;
  border: none !important;
  border-radius: var(--radius-md) var(--radius-md) 0 0 !important;
}

.wc-block-product {
  padding: 0 !important;
  border: 1px solid var(--card-light-border) !important;
  border-radius: var(--radius-md) !important;
  background: var(--card-light-bg) !important;
  overflow: hidden !important;
  display: flex !important;
  flex-direction: column !important;
}

.wc-block-components-product-image > a,
.wp-block-woocommerce-product-image > a {
  display: block !important;
  width: 100% !important;
  height: 100% !important;
  overflow: hidden !important;
  margin: 0 !important;
  padding: 0 !important;
}

.wc-block-components-product-image img,
.wp-block-woocommerce-product-image img,
.woocommerce ul.products li.product a img,
.woocommerce-page ul.products li.product a img,
.woocommerce ul.products li.product .woocommerce-loop-product__link img {
  aspect-ratio: 16 / 10 !important;
  object-fit: cover !important;
  width: 100% !important;
  height: 100% !important;
  display: block !important;
  margin: 0 !important;
  padding: 0 !important;
  border: none !important;
}

.quest-img--1 { background-image: linear-gradient(135deg, #6e7a85 0%, #3a4a55 100%); }
.quest-img--2 { background-image: linear-gradient(135deg, #8a7e6c 0%, #4d4438 100%); }
.quest-img--3 { background-image: linear-gradient(135deg, #2a2a2a 0%, #1a1a1a 100%); }

.quest-tag {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  background: var(--accent);
  color: #111;
  font-size: 0.625rem;
  font-weight: 800;
  padding: 0.25rem 0.5rem;
  border-radius: 0.25rem;
  letter-spacing: 0.05em;
}

.quest-body {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.quest-name {
  font-size: 1.2rem;
  font-weight: 800;
  margin-bottom: 0.625rem;
  color: var(--text-dark);
}

.quest-name a {
  color: inherit;
}

.quest-name a:hover {
  opacity: 0.8;
}

.quest-desc {
  font-size: 0.875rem;
  color: var(--text-dark-muted);
  line-height: 1.5;
  margin-bottom: 1.25rem;
  flex: 1;
}

.quest-desc p,
.quest-desc .wp-block-post-excerpt__excerpt {
  margin: 0;
}

.quest-body .wp-block-woocommerce-product-price,
.quest-body .quest-price {
  text-align: left !important;
  font-weight: 800 !important;
  font-size: 1.1rem !important;
  color: var(--text-dark) !important;
  margin-top: 0 !important;
  margin-bottom: 1rem !important;
}

.quest-body .wp-block-woocommerce-product-price .wc-block-components-product-price {
  font-size: inherit !important;
  font-weight: inherit !important;
}

.quest-body .wp-block-read-more {
  width: fit-content;
  margin-top: auto;
}

.quest-actions {
  display: block;
  margin-top: auto;
}

.quest-actions .product-card-buttons {
  margin-top: 0;
}

.quest-actions .btn,
.quest-actions .wp-block-woocommerce-product-button .wp-block-button__link,
.quest-actions .wc-block-components-product-button__button {
  width: 100% !important;
  justify-content: center !important;
  padding: 0.75rem 0.25rem !important;
  font-size: 0.75rem !important;
  margin: 0 !important;
  min-width: 0 !important;
}

.quest-actions .wp-block-woocommerce-product-button {
  margin: 0 !important;
}

.quest-actions .wc-block-components-product-button__button {
  background: var(--accent) !important;
  color: #111 !important;
  border-radius: var(--radius-pill) !important;
  box-shadow: 0 0.5rem 1.375rem rgba(249, 225, 76, 0.25) !important;
  font-family: inherit !important;
  font-weight: 800 !important;
  letter-spacing: 0.06em !important;
  line-height: 1 !important;
  text-transform: uppercase !important;
  text-decoration: none !important;
}

/* Styles for buttons in a row on the tours page */
.wp-block-post-content.is-layout-constrained > :where(:not(.alignleft):not(.alignright):not(.alignfull)) {
  max-width: var(--container) !important;
  width: 100%;
}

.entry-content.has-global-padding {
  padding-left: var(--gutter) !important;
  padding-right: var(--gutter) !important;
}

body.page-id-66 .entry-content {
  padding-bottom: 6rem !important;
}

/* Custom header for the Tours page (page-id-66) */
body.page-id-66 .entry-content > p.has-large-font-size:first-child {
  display: flex !important;
  align-items: center;
  gap: 1.5rem;
  width: 100%;
  max-width: var(--container) !important;
  margin: 0 auto 2.25rem !important;
  font-size: 0 !important; /* Hide the original text "Стамбул" */
  text-align: left;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

body.page-id-66 .entry-content > p.has-large-font-size:first-child::before {
  content: "ВСЕ КВЕСТ-ЭКСКУРСИИ В СТАМБУЛЕ:";
  font-size: clamp(1.625rem, 3vw, 2.25rem) !important;
  font-weight: 800;
  line-height: 1.05;
  color: var(--text-dark);
  white-space: nowrap;
}

/* Remove large top gap on pages without hero */
body:not(.home) .wp-site-blocks {
  margin-top: 0 !important;
  padding-top: 0 !important;
}

body:not(.home) .entry-content {
  margin-top: 0 !important;
  padding-top: 0 !important;
}

body:not(.home) .wp-block-spacer {
  display: none !important;
}

body:not(.home) main.wp-block-group {
  margin-top: 0 !important;
  padding-top: 0 !important;
}

.wc-block-product {
  display: flex;
  flex-direction: column;
  gap: 0;
  background: #fff;
  padding: 0 !important;
  border-radius: var(--radius-md);
  border: 1px solid var(--card-light-border);
  box-shadow: var(--shadow-light);
  height: 100%;
  overflow: hidden;
}

.wc-block-product > :not(.wp-block-woocommerce-product-image) {
  padding-left: 1.5rem !important;
  padding-right: 1.5rem !important;
}

.wc-block-product,
.wc-block-product * {
  font-family: 'Manrope', system-ui, -apple-system, Segoe UI, Roboto, sans-serif !important;
}

.wc-block-product .wp-block-post-title {
  padding-top: 1.5rem !important;
  font-size: 1.2rem !important;
  font-weight: 800 !important;
  line-height: 1.1 !important;
  text-align: left !important;
  color: var(--text-dark) !important;
}

.wc-block-product .wp-block-post-title a {
  font-size: inherit !important;
  font-weight: inherit !important;
  line-height: inherit !important;
  color: inherit !important;
}

.wc-block-product .wp-block-post-excerpt,
.wc-block-product .wp-block-woocommerce-product-price {
  text-align: left !important;
}

.wc-block-product .wp-block-woocommerce-product-button {
  padding-bottom: 1.5rem !important;
}

.wc-block-product .wp-block-post-excerpt {
  flex: 1 1 auto;
  font-size: 0.875rem !important;
  line-height: 1.5 !important;
  color: var(--text-dark-muted) !important;
  margin-bottom: 1.25rem !important;
}

.wc-block-product .wp-block-woocommerce-product-price {
  flex: 0 0 auto;
  font-weight: 800 !important;
  font-size: 1.1rem !important;
  color: var(--text-dark) !important;
  margin-top: 0 !important;
  margin-bottom: 1rem !important;
}

.wc-block-product .wp-block-read-more,
.wc-block-product .wp-block-woocommerce-product-button {
  margin-top: 0 !important;
}

.wc-block-product .wp-block-woocommerce-product-button {
  flex: 0 0 auto;
}

.product-card-buttons {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: stretch;
  gap: 0.5rem;
  margin-top: 0;
  width: 100%;
}

.product-card-buttons > * {
  display: block;
  margin: 0 !important;
  padding: 0 !important;
  min-width: 0 !important;
  width: 100% !important;
}

.product-card-buttons .wp-block-button {
  margin: 0 !important;
  width: 100% !important;
  max-width: none !important;
}

.product-card-buttons .btn-details,
.product-card-buttons .wp-block-woocommerce-product-button a {
  display: flex !important;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  height: 3rem !important;
  min-height: 0;
  max-width: none !important;
  width: 100% !important;
  padding: 0.75rem 0.25rem !important;
  font-size: 0.75rem !important;
  letter-spacing: 0.06em !important;
  border-radius: var(--radius-pill) !important;
  font-family: inherit !important;
  font-weight: 800 !important;
  line-height: 1 !important;
  text-transform: uppercase !important;
  text-decoration: none !important;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.btn-details {
  background: var(--dark-btn) !important;
  color: #fff !important;
}

.btn-details:hover {
  background: var(--dark-btn-hover) !important;
}

.product-card-buttons .wc-block-components-product-button__button {
  background: var(--accent) !important;
  color: #111 !important;
  border-radius: var(--radius-pill) !important;
  box-shadow: 0 0.5rem 1.375rem rgba(249, 225, 76, 0.25) !important;
  font-family: inherit !important;
  font-size: 0.75rem !important;
  font-weight: 800 !important;
  letter-spacing: 0.06em !important;
  text-transform: uppercase !important;
  text-decoration: none !important;
}

.product-card-buttons .wc-block-components-product-button__button:hover {
  background: var(--accent-hover) !important;
}

/* ---------- Single product pages ---------- */

body.page-id-66,
body.single-product {
  font-family: 'Manrope', system-ui, -apple-system, Segoe UI, Roboto, sans-serif !important;
  color: var(--text-dark);
  background:
    radial-gradient(circle at top left, rgba(249, 225, 76, 0.22), transparent 28rem),
    var(--bg-light);
  --single-product-first-row-height: min(38rem, max(22rem, calc(100svh - var(--header-height) - 7.5rem)));
  --single-product-thumbs-height: 4.75rem;
  --single-product-gallery-gap: 0.75rem;
}

body.single-product .wp-site-blocks > .wp-block-group.woocommerce.product {
  padding: 2rem var(--gutter) 4.5rem;
}

body.single-product main.wp-block-group {
  max-width: var(--container) !important;
  margin: 0 auto !important;
  padding: 0 !important;
}

body.single-product .woocommerce-breadcrumb {
  margin: 0 0 1rem !important;
  color: var(--text-dark-dim);
  font-size: 0.8125rem;
  font-weight: 700;
}

body.single-product .woocommerce-breadcrumb a {
  color: var(--text-dark-muted);
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

body.single-product .woocommerce-breadcrumb a::before {
  content: "\f060";
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
  font-size: 0.75rem;
}

body.single-product .wp-block-columns.alignwide {
  align-items: stretch !important;
  gap: 1.5rem !important;
  max-width: var(--container) !important;
  margin: 0 auto 1.5rem !important;
  height: var(--single-product-first-row-height);
  min-height: 0;
}

body.single-product .wp-block-column {
  min-width: 0;
}

body.single-product .wp-block-woocommerce-product-image-gallery,
body.single-product .wp-block-columns.alignwide > .wp-block-column:last-child,
body.single-product .wp-block-woocommerce-product-details,
body.single-product .related.products {
  background: var(--card-light-bg);
  border: 1px solid var(--card-light-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-light);
}

body.single-product .wp-block-woocommerce-product-image-gallery {
  height: 100%;
  padding: 1rem;
  overflow: hidden;
}

body.single-product .woocommerce-product-gallery,
body.single-product .woocommerce-product-gallery__wrapper {
  height: 100%;
}

body.single-product .woocommerce-product-gallery {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: var(--single-product-gallery-gap);
}

body.single-product .woocommerce-product-gallery:not(.flexslider) .woocommerce-product-gallery__image:not(:first-child) {
  display: none;
}

body.single-product .woocommerce-product-gallery .flex-viewport {
  flex: 1 1 auto;
  height: calc(100% - var(--single-product-thumbs-height) - var(--single-product-gallery-gap)) !important;
  min-height: 0;
  overflow: hidden;
  border-radius: calc(var(--radius-lg) - 0.35rem);
  background: var(--bg-light-soft);
}

body.single-product .woocommerce-product-gallery__wrapper,
body.single-product .woocommerce-product-gallery__image,
body.single-product .woocommerce-product-gallery__image a {
  height: 100% !important;
}

body.single-product .woocommerce-product-gallery__image {
  margin: 0 !important;
  min-height: 100% !important;
}

body.single-product .woocommerce-product-gallery__image a {
  display: block;
  min-height: 100% !important;
  cursor: zoom-in;
}

body.single-product .woocommerce-product-gallery__image img {
  display: block !important;
  width: 100% !important;
  height: 100% !important;
  min-height: 100% !important;
  max-height: none !important;
  border-radius: calc(var(--radius-lg) - 0.35rem);
  object-fit: cover !important;
}

body.single-product .woocommerce-product-gallery .zoomImg {
  display: none !important;
}

body.single-product .woocommerce-product-gallery__trigger {
  display: none !important;
}

body.single-product .woocommerce-product-gallery .flex-control-thumbs {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(3rem, 1fr));
  gap: 0.5rem;
  flex: 0 0 var(--single-product-thumbs-height);
  height: var(--single-product-thumbs-height);
  margin: 0 !important;
  padding: 0 !important;
  overflow: hidden;
}

body.single-product .woocommerce-product-gallery .flex-control-thumbs::before,
body.single-product .woocommerce-product-gallery .flex-control-thumbs::after {
  display: none;
}

body.single-product .woocommerce-product-gallery .flex-control-thumbs li {
  width: auto !important;
  margin: 0 !important;
  list-style: none;
}

body.single-product .woocommerce-product-gallery .flex-control-thumbs img {
  width: 100%;
  height: 100%;
  border-radius: 0.65rem;
  object-fit: cover;
  opacity: 0.55;
  cursor: pointer;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

body.single-product .woocommerce-product-gallery .flex-control-thumbs img.flex-active,
body.single-product .woocommerce-product-gallery .flex-control-thumbs img:hover {
  opacity: 1;
  transform: translateY(-0.0625rem);
}

body.single-product .woocommerce-product-gallery .flex-direction-nav,
body.single-product .woocommerce-product-gallery .product-gallery-nav {
  margin: 0;
  padding: 0;
  list-style: none;
}

body.single-product .woocommerce-product-gallery .flex-direction-nav a,
body.single-product .woocommerce-product-gallery .product-gallery-nav__button {
  position: absolute;
  top: calc(50% - (var(--single-product-thumbs-height) / 2));
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: var(--radius-pill);
  border: 0;
  background: rgba(255, 255, 255, 0.88);
  color: transparent;
  cursor: pointer;
  font: inherit;
  box-shadow: var(--shadow-light);
  transform: translateY(-50%);
}

body.single-product .woocommerce-product-gallery .flex-direction-nav a::before,
body.single-product .woocommerce-product-gallery .product-gallery-nav__button::before {
  color: var(--text-dark);
  font-family: "Font Awesome 6 Free";
  font-size: 0.9rem;
  font-weight: 900;
}

body.single-product .woocommerce-product-gallery .flex-direction-nav .flex-prev,
body.single-product .woocommerce-product-gallery .product-gallery-nav__button--prev {
  left: 1.75rem;
}

body.single-product .woocommerce-product-gallery .flex-direction-nav .flex-next,
body.single-product .woocommerce-product-gallery .product-gallery-nav__button--next {
  right: 1.75rem;
}

body.single-product .woocommerce-product-gallery .flex-direction-nav .flex-prev::before,
body.single-product .woocommerce-product-gallery .product-gallery-nav__button--prev::before {
  content: "\f053";
}

body.single-product .woocommerce-product-gallery .flex-direction-nav .flex-next::before,
body.single-product .woocommerce-product-gallery .product-gallery-nav__button--next::before {
  content: "\f054";
}

body.single-product .woocommerce-product-gallery .flex-direction-nav .flex-disabled,
body.single-product .woocommerce-product-gallery .product-gallery-nav__button:disabled {
  opacity: 0.35;
  pointer-events: none;
}

body.single-product .woocommerce-product-gallery .flex-direction-nav {
  display: none !important;
}

body.single-product .wp-block-columns.alignwide > .wp-block-column:last-child {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 1.15rem;
  padding: clamp(1.5rem, 3vw, 2.5rem);
  overflow: auto;
}

body.single-product .wp-block-post-title {
  max-width: 42rem;
  color: var(--text-dark);
  font-family: inherit !important;
  font-size: clamp(1.25rem, 4.2vw, 2.75rem) !important;
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 1.05;
  overflow-wrap: break-word;
  word-break: break-word;
  hyphens: auto;
}

body.single-product .wp-block-woocommerce-product-price {
  margin: 0 !important;
  color: var(--text-dark) !important;
  font-family: inherit !important;
  font-size: 1.45rem !important;
  font-weight: 800;
}

body.single-product .wp-block-post-excerpt {
  display: block;
  margin: 0;
  color: var(--text-dark-muted);
  font-size: 1rem;
  line-height: 1.6;
  text-align: left;
  line-clamp: unset;
  -webkit-line-clamp: unset;
}

body.single-product .wp-block-post-excerpt__excerpt {
  margin: 0;
}

body.single-product .wp-block-add-to-cart-form,
body.single-product .wc-block-add-to-cart-form {
  margin: 0 !important;
  padding: 0 !important;
  text-align: left;
}

body.single-product form.cart {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
  margin: 0 !important;
  padding: 0 !important;
}

body.single-product .quantity {
  display: none !important;
}

body.single-product .single_add_to_cart_button {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  width: min(14rem, 100%);
  height: 2.75rem !important;
  min-height: 0;
  padding: 0.5rem 1.5rem !important;
  border: 0 !important;
  border-radius: var(--radius-pill) !important;
  background: var(--accent) !important;
  color: #111 !important;
  font-family: inherit !important;
  font-size: 0.75rem !important;
  font-weight: 800 !important;
  letter-spacing: 0.06em;
  line-height: 1 !important;
  margin: 0 !important;
  text-transform: uppercase;
  box-shadow: 0 0.5rem 1.375rem rgba(249, 225, 76, 0.25);
}

body.single-product .single_add_to_cart_button:hover {
  background: var(--accent-hover) !important;
}

body.single-product .wp-block-woocommerce-product-meta {
  display: none;
}

body.single-product .wp-block-woocommerce-product-details {
  max-width: 52rem !important;
  margin: 1.5rem auto 0 !important;
  padding: clamp(1.5rem, 3vw, 2.5rem);
}

body.single-product .woocommerce-tabs .tabs {
  display: none;
}

body.single-product .woocommerce-Tabs-panel {
  display: block !important;
  margin: 0 !important;
  padding: 0 !important;
}

body.single-product .woocommerce-Tabs-panel > * + * {
  margin-top: 1rem;
}

body.single-product .woocommerce-Tabs-panel h2,
body.single-product .woocommerce-Tabs-panel h3 {
  color: var(--text-dark);
  font-family: inherit !important;
  font-weight: 800;
  letter-spacing: -0.02em;
}

body.single-product .woocommerce-Tabs-panel h2 {
  font-size: clamp(1.6rem, 3vw, 2.25rem);
}

body.single-product .woocommerce-Tabs-panel h3 {
  margin-top: 1.75rem;
  font-size: 1.35rem;
}

body.single-product .woocommerce-Tabs-panel p,
body.single-product .woocommerce-Tabs-panel li {
  color: var(--text-dark-muted);
  font-size: 1rem;
  line-height: 1.75;
}

body.single-product .woocommerce-Tabs-panel ul {
  margin: 1rem 0 0;
  padding-left: 1.25rem;
}

body.single-product .woocommerce-Tabs-panel strong {
  color: var(--text-dark);
  font-weight: 800;
}

/* --- EC Product Specs & Reassurance --- */

.ec-specs {
  margin: 0 !important;
  padding: 0.35rem 0 0.25rem;
  border-top: 1px solid var(--border-light);
}

body.single-product .wp-block-post-excerpt {
  margin-block-end: 0.5rem !important;
}

body.single-product .wp-block-post-excerpt + .ec-specs {
  margin-block-start: 0 !important;
}

.ec-specs__title {
  font-size: 1.05rem;
  font-weight: 700;
  margin: 0 0 0.6rem;
  color: var(--text-dark);
  text-transform: none;
  letter-spacing: normal;
}

.ec-specs__list {
  list-style: none !important;
  padding: 0 !important;
  margin: 0 !important;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
}

.ec-specs__row {
  display: flex !important;
  gap: 0.6rem;
  align-items: center;
  font-size: 0.95rem;
  color: var(--text-dark-muted);
  line-height: 1.2;
  flex: 0 0 auto;
}

@media (max-width: 480px) {
  .ec-specs__list {
    gap: 0.5rem 1rem;
  }
}

.ec-specs__icon {
  width: 1.25rem;
  text-align: center;
  color: var(--text-dark-muted);
  font-size: 0.9rem;
}

.ec-buy-reassurance {
  background: #e6f7f5;
  color: #0a7a73;
  border-radius: 0.5rem;
  padding: 0.55rem 0.8rem;
  font-size: 0.85rem;
  display: flex;
  gap: 0.5rem;
  align-items: center;
  line-height: 1.3;
  margin: 0;
}

.ec-buy-row {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: nowrap;
  margin-block-start: 0 !important;
  margin-top: 0 !important;
}

body.single-product .ec-buy-row {
  margin-top: 0 !important;
}

.ec-buy-row .ec-buy-reassurance {
  flex: 1 1 auto;
  min-width: 0;
}

@media (max-width: 480px) {
  .ec-buy-row {
    gap: 0.6rem;
  }
  .ec-buy-row .ec-buy-reassurance {
    font-size: 0.75rem;
    padding: 0.45rem 0.6rem;
  }
}

body.single-product .wp-block-add-to-cart-form,
body.single-product .wc-block-add-to-cart-form {
  margin: 0 !important;
  padding: 0 !important;
  text-align: left;
  flex: 0 0 auto;
}

.ec-buy-reassurance i {
  font-size: 1rem;
}

/* Checkout compact version */
.woocommerce-checkout .ec-specs {
  border-top: 1px solid #eee;
  margin-top: 0.5rem;
  padding-top: 0.5rem;
}

.woocommerce-checkout .ec-specs__title {
  display: none;
}

.woocommerce-checkout .ec-specs__list {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.woocommerce-checkout .ec-specs__row {
  font-size: 0.85rem;
}

.woocommerce-checkout .ec-specs__icon {
  width: 1rem;
  font-size: 0.8rem;
}

@media (max-width: 720px) {
  .ec-specs__row {
    font-size: 0.9rem;
  }
}

body.single-product .woocommerce-Reviews,
body.single-product #reviews,
body.single-product #review_form_wrapper {
  display: none !important;
}

body.single-product .related.products {
  max-width: var(--container);
  margin: 1.5rem auto 0;
  padding: clamp(1.5rem, 3vw, 2.5rem);
}

body.single-product .related.products > h2 {
  margin-bottom: 1.5rem;
  color: var(--text-dark);
  font-family: inherit !important;
  font-size: clamp(1.6rem, 3vw, 2.25rem);
  font-weight: 800;
  letter-spacing: -0.02em;
}

body.single-product .related.products ul.products {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
  margin: 0 !important;
  padding: 0 !important;
}

body.single-product .related.products ul.products::before,
body.single-product .related.products ul.products::after {
  display: none;
}

body.single-product .related.products li.product {
  width: auto !important;
  margin: 0 !important;
}

body.single-product .related.products li.product .woocommerce-loop-product__title,
body.single-product .related.products li.product h2,
body.single-product .related.products li.product h3,
body.single-product .related.products li.product .wp-block-post-title {
  font-size: 1.125rem !important;
  line-height: 1.2 !important;
  letter-spacing: -0.01em !important;
  margin-top: 0.75rem !important;
  margin-bottom: 0.5rem !important;
}

body.single-product .related.products li.product .price,
body.single-product .related.products li.product .wp-block-woocommerce-product-price {
  font-size: 1rem !important;
  font-weight: 700 !important;
}

body.single-product .related.products li.product .button {
  padding: 0.5rem 1rem !important;
  font-size: 0.75rem !important;
  min-height: auto !important;
}

body.single-product [data-collection="woocommerce/product-collection/related"] .wp-block-post-title {
  font-size: 1.125rem !important;
  line-height: 1.2 !important;
  letter-spacing: -0.01em !important;
}

body.single-product [data-collection="woocommerce/product-collection/related"] .wp-block-woocommerce-product-price {
  font-size: 1rem !important;
  font-weight: 700 !important;
}

body.single-product [data-collection="woocommerce/product-collection/related"] .wp-block-button__link,
body.single-product [data-collection="woocommerce/product-collection/related"] .wc-block-components-product-button__button {
  padding: 0.5rem 1rem !important;
  font-size: 0.75rem !important;
  min-height: auto !important;
}

@media (max-width: 900px) {
  body.single-product {
    --single-product-first-row-height: auto;
    --single-product-thumbs-height: 4rem;
  }

  body.single-product .wp-block-columns.alignwide {
    flex-direction: column;
    height: auto;
  }

  body.single-product .wp-block-columns.alignwide > .wp-block-column {
    flex-basis: auto !important;
  }

  body.single-product .wp-block-woocommerce-product-image-gallery {
    height: min(32rem, calc(100svh - var(--header-height) - 4rem));
  }

  body.single-product .related.products ul.products {
    grid-template-columns: 1fr;
  }
}

.quests-footer {
  text-align: center;
}

.quests-empty {
  text-align: center;
  color: var(--text-dark-muted);
}

.decor-sparkle {
  position: absolute;
  right: 0.625rem;
  bottom: 1.75rem;
  color: #c9c9c9;
  font-size: 0.875rem;
  transform: rotate(45deg);
}

body.single-product .related.products,
body.single-product .up-sells.products,
body.single-product [data-collection="woocommerce/product-collection/related"] {
  display: none !important;
}

.back-to-tours-container {
  max-width: var(--container);
  margin: 2rem auto 0;
  text-align: center;
}

.back-to-tours-container .btn {
  min-width: 280px;
}

/* ---------- FAQ ---------- */

.faq {
  padding: 3.125rem 0 6.25rem;
  background: var(--bg-light);
}

.faq .section-title {
  margin-bottom: 3.125rem;
  text-align: center;
}

.faq-grid {
  max-width: 50rem;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 0.75rem; /* Уменьшил расстояние между вопросами */
}

.faq-item {
  background: var(--card-light-bg);
  border-radius: var(--radius-md);
  border: 1px solid var(--card-light-border);
  box-shadow: var(--shadow-light);
  overflow: hidden;
}

.faq-question {
  font-size: 1rem;
  font-weight: 800;
  color: var(--text-dark);
  padding: 1.25rem 1.875rem;
  cursor: pointer;
  list-style: none;
  position: relative;
  transition: background-color 0.2s ease;
}

.faq-question::-webkit-details-marker {
  display: none;
}

.faq-question::after {
  content: "\f078";
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
  position: absolute;
  right: 1.875rem;
  top: 50%;
  transform: translateY(-50%);
  font-size: 0.75rem;
  transition: transform 0.3s ease;
}

.faq-item[open] .faq-question::after {
  transform: translateY(-50%) rotate(180deg);
}

.faq-question:hover {
  background-color: rgba(0,0,0,0.02);
}

.faq-answer {
  padding: 0 1.875rem 1.5rem;
  font-size: 0.9375rem;
  color: var(--text-dark-muted);
  line-height: 1.6;
}

/* ---------- Footer ---------- */

.site-footer {
  position: relative;
  padding: 6.25rem var(--gutter) 3.75rem;
  background-image: 
    linear-gradient(to bottom, rgba(14, 14, 14, 0.1) 0%, rgba(14, 14, 14, 0.5) 100%),
    url('footer-bg.png');
  background-size: cover;
  background-position: center center; /* Обрезаем и сверху и снизу */
  color: #fff;
  text-align: center;
  margin-top: 0;
  min-height: 37.5rem; /* Высота 37.5rem */
  display: flex;
  align-items: center;
  justify-content: center;
}

.footer-container {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1.5fr 1fr;
  gap: 2.5rem;
  align-items: center;
}

.footer-left {
  text-align: left;
  font-size: 0.875rem;
  line-height: 1.8;
  color: rgba(255, 255, 255, 0.8);
}

.footer-left p {
  margin: 0;
}

.footer-center {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.footer-right {
  text-align: right;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.footer-link {
  font-size: 0.875rem;
  color: rgba(255, 255, 255, 0.8);
  transition: color 0.2s ease;
}

.footer-link:hover {
  color: var(--accent);
}

.footer-logo {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  margin-bottom: 1rem;
}

.footer-logo-img {
  width: 2rem;
  height: auto;
}

.footer-tagline {
  font-size: 1rem;
  color: rgba(255, 255, 255, 0.8);
  margin-bottom: 2.5rem;
  font-style: italic;
}

.footer-copyright {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.5);
  letter-spacing: 0.04em;
  padding-top: 0;
  border-top: 0;
}

@media (max-width: 1024px) {
  .footer-container {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 3.75rem;
  }
  .footer-left, .footer-right {
    text-align: center;
  }
  .footer-right {
    align-items: center;
  }
}

.site-footer::before {
  content: "";
  position: absolute;
  top: calc(-0.0625rem - 1px);
  left: 0;
  width: 100%;
  height: calc(0.8125rem + 2px);
  transform: translateZ(0);
  background-color: var(--bg-light);
  /* Инвертированный полигон: зубцы теперь смотрят ВНИЗ на картинку */
  clip-path: polygon(
    0% 0%, 0% 100%, 1.25% 0%, 2.5% 100%, 3.75% 0%, 5% 100%, 6.25% 0%, 7.5% 100%, 8.75% 0%, 10% 100%, 
    11.25% 0%, 12.5% 100%, 13.75% 0%, 15% 100%, 16.25% 0%, 17.5% 100%, 18.75% 0%, 20% 100%, 
    21.25% 0%, 22.5% 100%, 23.75% 0%, 25% 100%, 26.25% 0%, 27.5% 100%, 28.75% 0%, 30% 100%, 
    31.25% 0%, 32.5% 100%, 33.75% 0%, 35% 100%, 36.25% 0%, 37.5% 100%, 38.75% 0%, 40% 100%, 
    41.25% 0%, 42.5% 100%, 43.75% 0%, 45% 100%, 46.25% 0%, 47.5% 100%, 48.75% 0%, 50% 100%, 
    51.25% 0%, 52.5% 100%, 53.75% 0%, 55% 100%, 56.25% 0%, 57.5% 100%, 58.75% 0%, 60% 100%, 
    61.25% 0%, 62.5% 100%, 63.75% 0%, 65% 100%, 66.25% 0%, 67.5% 100%, 68.75% 0%, 70% 100%, 
    71.25% 0%, 72.5% 100%, 73.75% 0%, 75% 100%, 76.25% 0%, 77.5% 100%, 78.75% 0%, 80% 100%, 
    81.25% 0%, 82.5% 100%, 83.75% 0%, 85% 100%, 86.25% 0%, 87.5% 100%, 88.75% 0%, 90% 100%, 
    91.25% 0%, 92.5% 100%, 93.75% 0%, 95% 100%, 96.25% 0%, 97.5% 100%, 98.75% 0%, 100% 100%, 
    100% 0%
  );
}

/* =============================================================
   Responsive
   ============================================================= */

/* Tablet: progress map drops below the hero text, cards 2-up */
@media (max-width: 1024px) {
  .hero {
    padding: 6.875rem var(--gutter) 6.25rem;
  }

  .hero-inner {
    grid-template-columns: 1fr;
    gap: 1.75rem;
  }

  .progress-map {
    margin-top: 0.5rem;
    justify-self: start;
    max-width: 18rem;
  }

  .feature-cards {
    grid-template-columns: repeat(2, 1fr);
    margin-top: 2.5rem;
  }

  .main-nav {
    gap: 1.375rem;
    margin-left: 0.75rem;
  }

  .main-nav a {
    font-size: 0.6875rem;
  }

  /* Light section tablet adjustments */
  .experience-grid {
    grid-template-columns: 1fr;
    gap: 3.125rem;
  }

  .riddle-stack {
    justify-self: start;
    max-width: 28.75rem;
  }

  .quest-experience {
    padding: 4.375rem 0 3.75rem;
  }

  .how-it-works {
    padding: 2.5rem 0 4.375rem;
  }

  .gallery {
    grid-template-columns: repeat(3, 1fr);
    gap: 0.875rem;
  }
}

  @media (max-width: 1024px) {
    .quests-grid {
      grid-template-columns: repeat(2, 1fr);
    }
  }

  @media (max-width: 720px) {
    .quests-grid {
      grid-template-columns: 1fr;
    }
  }

  /* Mobile */
  @media (max-width: 720px) {
  :root {
    --gutter: 1.25rem;
  }

  .site-header {
    padding: 0.75rem var(--gutter);
    gap: 0.75rem;
  }

  .site-header-container {
    gap: 0.75rem;
    flex-wrap: nowrap;
    align-items: center;
  }

  .site-header-container:has(.nav-toggle) .nav-toggle {
    display: inline-flex;
    flex-shrink: 0;
  }

  .main-nav {
    display: none;
  }

  .site-header-container:has(.nav-toggle) .main-nav {
    display: flex;
    position: absolute;
    z-index: 1001;
    left: 0;
    right: 0;
    top: calc(100% + 0.375rem);
    margin-left: 0;
    flex: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 0;
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    background: rgba(18, 18, 18, 0.97);
    -webkit-backdrop-filter: blur(0.75rem);
    backdrop-filter: blur(0.75rem);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 0.75rem;
    box-shadow: 0 1rem 2.5rem rgba(0, 0, 0, 0.45);
    transition:
      max-height 0.35s ease,
      opacity 0.22s ease,
      padding 0.22s ease,
      visibility 0s linear 0.35s;
  }

  .site-header.nav-open .site-header-container:has(.nav-toggle) .main-nav {
    max-height: min(70vh, 28rem);
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    padding: 0.375rem;
    gap: 0.125rem;
    transition:
      max-height 0.35s ease,
      opacity 0.22s ease,
      padding 0.22s ease,
      visibility 0s linear 0s;
  }

  .site-header-container:has(.nav-toggle) .main-nav a {
    padding: 0.8125rem 1rem;
    border-radius: 0.5rem;
    text-align: center;
  }

  .site-header-container:has(.nav-toggle) .main-nav a:hover,
  .site-header-container:has(.nav-toggle) .main-nav a:focus-visible {
    background: rgba(255, 255, 255, 0.07);
  }

  .auth {
    margin-left: auto;
    gap: 0.875rem;
  }

  .login-link {
    display: none;
  }

  body.nav-drawer-open {
    overflow: hidden;
  }

  .hero {
    padding: 6.25rem var(--gutter) 5rem;
  }

  .hero-content {
    padding-top: 0.5rem;
  }

  .hero-title {
    font-size: clamp(1.875rem, 8vw, 2.625rem);
  }

  .hero-lead br {
    display: none;
  }

  .cta-buttons {
    margin-top: 1.75rem;
  }

  .btn {
    padding: 0.875rem 1.25rem;
    font-size: 0.75rem;
  }

  .feature-cards {
    grid-template-columns: 1fr;
    margin-top: 2rem;
    gap: 0.875rem;
  }

  .progress-map {
    max-width: 18rem;
  }

  .map-mock {
    height: 13rem;
  }

  /* Light section mobile adjustments */
  .quest-experience {
    padding: 3.75rem 0 3.125rem;
  }

  .how-it-works {
    padding: 1.875rem 0 3.75rem;
  }

  .inside-quest {
    padding: 1.25rem 0 4.375rem;
  }

  .riddle-stack {
    height: 13.75rem;
    max-width: 100%;
  }

  .riddle-card {
    padding: 1.125rem 1.25rem;
  }

  .riddle-text {
    font-size: 1rem;
  }

  .riddle-key {
    font-size: 2.75rem;
  }

  .steps-grid {
    grid-template-columns: 1fr;
    gap: 0.875rem;
    margin-bottom: 1.5rem;
  }

  .steps-progress {
    display: none;
  }

  .step-card {
    padding: 1.75rem 1.25rem 1.375rem;
    flex-direction: row;
    justify-content: flex-start;
    text-align: left;
    gap: 1rem;
  }

  .step-icon {
    font-size: 1.625rem;
  }

  .gallery {
    grid-template-columns: 1fr;
    gap: 0.875rem;
  }

  .section-heading-row {
    margin-bottom: 1.5rem;
  }
}

/* My Promos Link & Modal */
.my-promos-link {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.my-promos-count {
  background: var(--accent-color, #0088cc);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 800;
  padding: 0.1rem 0.4rem;
  border-radius: 1rem;
  line-height: 1;
  min-width: 1.2rem;
  text-align: center;
}

.ec-promos-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 10000;
  display: none;
  align-items: center;
  justify-content: center;
  font-family: 'Manrope', sans-serif;
}

.ec-promos-modal--open {
  display: flex;
}

.ec-promos-modal__overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(26, 26, 46, 0.85);
  backdrop-filter: blur(4px);
}

.ec-promos-modal__dialog {
  position: relative;
  background: #fff;
  width: 90%;
  max-width: 500px;
  max-height: 85vh;
  border-radius: 16px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.3);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  animation: ecModalFadeIn 0.3s ease-out;
}

@keyframes ecModalFadeIn {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

.ec-promos-modal__close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: none;
  border: none;
  font-size: 2rem;
  line-height: 1;
  color: #888;
  cursor: pointer;
  z-index: 1;
  padding: 0.5rem;
}

.ec-promos-modal__close:hover {
  color: #333;
}

.ec-promos-modal__title {
  padding: 1.5rem 2rem 1rem;
  margin: 0;
  font-size: 1.5rem;
  font-weight: 800;
  color: #1a1a2e;
  border-bottom: 1px solid #eee;
}

.ec-promos-modal__content {
  padding: 1.5rem 2rem;
  overflow-y: auto;
  flex: 1;
}

.ec-promos-modal__footer {
  padding: 1rem 2rem;
  background: #f8f9fa;
  border-top: 1px solid #eee;
  font-size: 0.85rem;
  color: #666;
  line-height: 1.5;
}

.ec-promos-modal__footer a {
  color: #0088cc;
  text-decoration: none;
  font-weight: 700;
}

.ec-promos-modal__entry {
  background: #f4f7fb;
  border: 1px solid #dde6f0;
  border-radius: 12px;
  padding: 1.25rem;
  margin-bottom: 1.25rem;
}

.ec-promos-modal__entry:last-child {
  margin-bottom: 0;
}

.ec-promos-modal__entry-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
}

.ec-promos-modal__entry-date {
  font-size: 0.8rem;
  font-weight: 700;
  color: #888;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.ec-promos-modal__delete-btn {
  background: none;
  border: none;
  color: #ccc;
  font-size: 1.25rem;
  cursor: pointer;
  padding: 0.25rem;
  line-height: 1;
}

.ec-promos-modal__delete-btn:hover {
  color: #ff4d4d;
}

.ec-promos-modal__entry-items {
  font-weight: 700;
  color: #1a1a2e;
  margin-bottom: 1rem;
  line-height: 1.4;
}

.ec-promos-modal__code-row {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
}

.ec-promos-modal__code-row:last-child {
  margin-bottom: 0;
}

.ec-promos-modal__code-value {
  flex: 1;
  background: #fff;
  border: 2px dashed #0088cc;
  border-radius: 8px;
  padding: 0.6rem;
  font-family: 'Courier New', monospace;
  font-size: 1.1rem;
  font-weight: 800;
  color: #0088cc;
  text-align: center;
  letter-spacing: 1px;
}

.ec-promos-modal__copy-btn {
  background: #0088cc;
  color: #fff;
  border: none;
  border-radius: 8px;
  padding: 0 1rem;
  font-size: 0.75rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s;
  white-space: nowrap;
}

.ec-promos-modal__copy-btn:hover {
  background: #0077b3;
}

.ec-promos-modal__copy-btn--success {
  background: #28a745 !important;
}

.ec-promos-modal__empty {
  text-align: center;
  color: #888;
  padding: 2rem 0;
}

@media (max-width: 600px) {
  .ec-promos-modal__dialog {
    width: 95%;
    max-height: 90vh;
  }
  .ec-promos-modal__content {
    padding: 1rem;
  }
  .ec-promos-modal__title {
    padding: 1.25rem 1.5rem 0.75rem;
  }
  .ec-promos-modal__footer {
    padding: 0.85rem 1.25rem;
  }
  .ec-promos-modal__code-value {
    font-size: 1rem;
  }
}
