/*
Theme Name: Rabdoma Gemini
Theme URI: https://rabdoma.ru
Description: Modern Gemini-inspired redesign for rabdoma.ru.
Author: Codex
Template: twentytwentyfive
Version: 1.0.0
Text Domain: rabdoma-gemini
*/

:root {
  --rd-bg: #f7f9ff;
  --rd-surface: rgba(255, 255, 255, 0.82);
  --rd-surface-solid: #ffffff;
  --rd-text: #121826;
  --rd-muted: #59647a;
  --rd-line: rgba(25, 38, 72, 0.11);
  --rd-blue: #1a73e8;
  --rd-cyan: #00bcd4;
  --rd-violet: #8e5cf7;
  --rd-green: #19b36b;
  --rd-orange: #ff8a3d;
  --rd-shadow: 0 24px 80px rgba(28, 48, 94, 0.14);
  --rd-soft-shadow: 0 14px 40px rgba(28, 48, 94, 0.1);
  --rd-radius: 24px;
}

html {
  scroll-behavior: smooth;
}

body {
  background:
    radial-gradient(circle at 8% 8%, rgba(26, 115, 232, 0.16), transparent 29rem),
    radial-gradient(circle at 91% 2%, rgba(142, 92, 247, 0.15), transparent 28rem),
    radial-gradient(circle at 82% 60%, rgba(0, 188, 212, 0.12), transparent 25rem),
    linear-gradient(180deg, #ffffff 0%, var(--rd-bg) 42%, #ffffff 100%);
  color: var(--rd-text);
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  letter-spacing: 0;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(26, 115, 232, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(26, 115, 232, 0.045) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.9), transparent 72%);
}

body .wp-site-blocks {
  overflow-x: clip;
}

.wp-site-blocks > header,
.wp-site-blocks > .wp-block-template-part:first-child {
  position: sticky;
  top: 0;
  z-index: 20;
  border-bottom: 1px solid var(--rd-line);
  background: rgba(255, 255, 255, 0.78);
  backdrop-filter: blur(18px);
  box-shadow: 0 10px 30px rgba(31, 42, 68, 0.06);
}

.wp-site-blocks > header .wp-block-group,
.wp-site-blocks > .wp-block-template-part:first-child .wp-block-group {
  min-height: 68px;
}

.site-title,
.wp-block-site-title a {
  color: var(--rd-text);
  font-weight: 800;
  text-decoration: none;
}

.wp-block-navigation a {
  color: var(--rd-muted);
  font-weight: 650;
  text-decoration: none;
}

.wp-block-navigation a:hover {
  color: var(--rd-blue);
}

main.wp-block-group {
  margin-top: 0 !important;
}

a {
  color: var(--rd-blue);
  text-underline-offset: 0.18em;
}

h1, h2, h3, h4, .wp-block-heading {
  color: var(--rd-text);
  font-weight: 850;
  line-height: 1.05;
  letter-spacing: 0;
}

p {
  color: var(--rd-muted);
  line-height: 1.75;
}

.rdg-hero {
  position: relative;
  padding: clamp(64px, 9vw, 118px) 0 clamp(44px, 6vw, 82px);
}

.rdg-hero::before,
.rdg-hero::after {
  content: "";
  position: absolute;
  pointer-events: none;
  border-radius: 999px;
  filter: blur(4px);
}

.rdg-hero::before {
  width: min(52vw, 660px);
  height: min(52vw, 660px);
  right: -18vw;
  top: -18vw;
  background: radial-gradient(circle, rgba(142, 92, 247, 0.22), transparent 63%);
}

.rdg-hero::after {
  width: 400px;
  height: 400px;
  left: -220px;
  bottom: -80px;
  background: radial-gradient(circle, rgba(0, 188, 212, 0.17), transparent 62%);
}

.rdg-hero-grid {
  display: grid !important;
  grid-template-columns: minmax(0, 1.08fr) minmax(300px, 0.92fr);
  gap: clamp(28px, 6vw, 72px) !important;
  align-items: center;
  position: relative;
  z-index: 1;
}

.rdg-kicker {
  width: fit-content;
  margin: 0 0 18px !important;
  padding: 9px 14px;
  border: 1px solid rgba(26, 115, 232, 0.18);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  box-shadow: 0 10px 30px rgba(26, 115, 232, 0.1);
  color: #21519c;
  font-size: 14px;
  font-weight: 750;
}

.rdg-gradient-title {
  max-width: 900px;
  margin: 0 !important;
  font-size: clamp(42px, 7vw, 88px) !important;
  background: linear-gradient(106deg, #101828 0%, #1a73e8 42%, #8e5cf7 72%, #00a5c8 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.rdg-lead {
  max-width: 720px;
  margin-top: 22px !important;
  color: #3e4960;
  font-size: clamp(18px, 2vw, 22px);
}

.rdg-checks {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin: 28px 0 0 !important;
  padding: 0 !important;
  list-style: none;
}

.rdg-checks li {
  position: relative;
  padding: 14px 15px 14px 44px;
  border: 1px solid var(--rd-line);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: 0 10px 28px rgba(45, 65, 110, 0.07);
  color: #263147;
  font-weight: 700;
}

.rdg-checks li::before {
  content: "";
  position: absolute;
  left: 15px;
  top: 15px;
  width: 18px;
  height: 18px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--rd-blue), var(--rd-cyan));
  box-shadow: 0 7px 18px rgba(26, 115, 232, 0.25);
}

.rdg-checks li::after {
  content: "";
  position: absolute;
  left: 21px;
  top: 19px;
  width: 5px;
  height: 9px;
  border: solid #fff;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.rdg-actions,
.wp-block-buttons {
  gap: 12px !important;
}

.rdg-actions {
  margin-top: 30px !important;
}

.wp-block-button__link,
.rdg-button .wp-block-button__link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  border: 0;
  border-radius: 999px !important;
  box-shadow: 0 15px 36px rgba(26, 115, 232, 0.22);
  font-weight: 800;
  line-height: 1.2;
  text-decoration: none;
  transition: transform 180ms ease, box-shadow 180ms ease, filter 180ms ease;
}

.wp-block-button__link:hover {
  transform: translateY(-2px);
  box-shadow: 0 22px 48px rgba(26, 115, 232, 0.25);
  filter: saturate(1.08);
}

.rdg-button-primary .wp-block-button__link,
.wp-block-button__link.has-accent-3-background-color {
  background: linear-gradient(135deg, #1a73e8, #8e5cf7) !important;
  color: #fff !important;
}

.rdg-button-telegram .wp-block-button__link,
.wp-block-button__link[style*="#4c95e3"] {
  background: linear-gradient(135deg, #2aabee, #1a73e8) !important;
  color: #fff !important;
}

.rdg-button-whatsapp .wp-block-button__link,
.wp-block-button__link[style*="#00e751"] {
  background: linear-gradient(135deg, #22c55e, #00bcd4) !important;
  color: #fff !important;
}

.rdg-button-call .wp-block-button__link,
.wp-block-button__link.has-accent-1-background-color {
  background: linear-gradient(135deg, #ff8a3d, #ff4d79) !important;
  color: #fff !important;
}

.rdg-visual-card {
  position: relative;
  min-height: 520px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.8);
  border-radius: 32px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.92), rgba(255, 255, 255, 0.54)),
    linear-gradient(135deg, rgba(26, 115, 232, 0.18), rgba(142, 92, 247, 0.12));
  box-shadow: var(--rd-shadow);
  backdrop-filter: blur(18px);
}

.rdg-visual-card::before {
  content: "";
  position: absolute;
  inset: 18px;
  border-radius: 24px;
  background:
    linear-gradient(180deg, rgba(18, 24, 38, 0.1), rgba(18, 24, 38, 0.46)),
    url("https://rabdoma.ru/wp-content/uploads/2025/01/hostel.jpg") center / cover;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.5);
}

.rdg-visual-card::after {
  content: "2000-4000 ₽ / день";
  position: absolute;
  left: 36px;
  right: 36px;
  bottom: 36px;
  padding: 18px 20px;
  border: 1px solid rgba(255, 255, 255, 0.55);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 20px 50px rgba(13, 26, 54, 0.22);
  color: #101828;
  font-size: clamp(22px, 3vw, 34px);
  font-weight: 900;
  backdrop-filter: blur(16px);
}

.rdg-floating-note {
  position: absolute;
  top: 38px;
  left: 38px;
  z-index: 2;
  max-width: 230px;
  padding: 14px 16px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: var(--rd-soft-shadow);
  color: #253149;
  font-weight: 800;
}

.rdg-section {
  padding-top: clamp(46px, 7vw, 86px) !important;
  padding-bottom: clamp(46px, 7vw, 86px) !important;
}

.rdg-section-soft {
  position: relative;
  border-top: 1px solid var(--rd-line);
  border-bottom: 1px solid var(--rd-line);
  background: linear-gradient(180deg, rgba(255,255,255,0.58), rgba(236,244,255,0.72));
}

.rdg-section h2,
.rdg-section .wp-block-heading {
  margin-bottom: 12px !important;
  font-size: clamp(30px, 4.5vw, 56px) !important;
}

.rdg-section-intro {
  max-width: 760px;
  margin-top: 0 !important;
  color: #4b5870;
  font-size: 18px;
}

.rdg-card-grid {
  display: grid !important;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px !important;
}

.rdg-card,
body .wp-block-post,
.wp-block-query .wp-block-post-template > li {
  border: 1px solid var(--rd-line);
  border-radius: var(--rd-radius);
  background: var(--rd-surface);
  box-shadow: var(--rd-soft-shadow);
  overflow: hidden;
  backdrop-filter: blur(16px);
}

.rdg-card {
  padding: 14px;
}

.rdg-card .wp-block-cover {
  min-height: 220px;
  border-radius: 18px;
  overflow: hidden;
}

.rdg-card p {
  margin: 14px 6px 6px !important;
  color: #222d44;
  font-weight: 800;
}

.wp-block-cover {
  border-radius: 22px;
  box-shadow: var(--rd-soft-shadow);
  overflow: hidden;
}

.wp-block-cover img {
  transition: transform 420ms ease;
}

.wp-block-cover:hover img {
  transform: scale(1.045);
}

.rdg-metrics {
  display: grid !important;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px !important;
  margin-top: 30px !important;
}

.rdg-metric {
  padding: 20px;
  border: 1px solid var(--rd-line);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.72);
  box-shadow: 0 12px 32px rgba(28, 48, 94, 0.08);
}

.rdg-metric strong {
  display: block;
  margin-bottom: 6px;
  color: #101828;
  font-size: 28px;
  font-weight: 900;
}

.rdg-metric span {
  color: var(--rd-muted);
  font-size: 14px;
  font-weight: 700;
}

.rdg-map-wrap {
  padding: 14px;
  border: 1px solid var(--rd-line);
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: var(--rd-shadow);
  overflow: hidden;
}

.rdg-map-wrap script,
.rdg-map-wrap iframe,
.rdg-map-wrap ymaps {
  border-radius: 20px;
}

.rdg-final-cta {
  margin-bottom: clamp(42px, 7vw, 82px) !important;
  padding: clamp(32px, 6vw, 70px) !important;
  border: 1px solid rgba(255, 255, 255, 0.78);
  border-radius: 32px;
  background:
    linear-gradient(135deg, rgba(26, 115, 232, 0.92), rgba(142, 92, 247, 0.88) 55%, rgba(0, 188, 212, 0.86)),
    #1a73e8;
  box-shadow: var(--rd-shadow);
}

.rdg-final-cta h2,
.rdg-final-cta p {
  color: #fff !important;
}

.wp-block-post {
  padding: 18px !important;
}

.wp-block-post-title a {
  color: var(--rd-text);
  text-decoration: none;
}

.wp-block-post-title a:hover {
  color: var(--rd-blue);
}

.wp-block-post-featured-image img {
  border-radius: 18px;
}

.wp-block-search__inside-wrapper {
  border: 1px solid var(--rd-line) !important;
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 12px 34px rgba(28, 48, 94, 0.09);
  overflow: hidden;
}

.wp-block-search__input {
  border: 0 !important;
  padding-left: 18px !important;
}

.wp-block-search__button {
  border: 0 !important;
  border-radius: 999px !important;
  background: linear-gradient(135deg, var(--rd-blue), var(--rd-violet)) !important;
  color: #fff !important;
  font-weight: 800;
}

.wp-site-blocks > footer,
.wp-site-blocks > .wp-block-template-part:last-child {
  border-top: 1px solid var(--rd-line);
  background: rgba(255, 255, 255, 0.72);
  backdrop-filter: blur(14px);
}

@media (max-width: 900px) {
  .rdg-hero-grid,
  .rdg-card-grid,
  .rdg-metrics {
    grid-template-columns: 1fr;
  }

  .rdg-visual-card {
    min-height: 430px;
  }
}

@media (max-width: 640px) {
  .rdg-hero {
    padding-top: 42px;
  }

  .rdg-checks {
    grid-template-columns: 1fr;
  }

  .rdg-gradient-title {
    font-size: 40px !important;
  }

  .rdg-actions .wp-block-button,
  .rdg-actions .wp-block-button__link,
  .wp-block-buttons .wp-block-button,
  .wp-block-buttons .wp-block-button__link {
    width: 100%;
  }

  .rdg-visual-card {
    min-height: 360px;
    border-radius: 24px;
  }

  .rdg-visual-card::before {
    inset: 12px;
    border-radius: 18px;
  }

  .rdg-visual-card::after {
    left: 24px;
    right: 24px;
    bottom: 24px;
  }

  .rdg-floating-note {
    top: 24px;
    left: 24px;
    right: 24px;
  }
}

.rdg-site-header {
  margin: 0 !important;
  padding: 10px 0 !important;
}

.rdg-header-inner {
  min-height: 58px !important;
  gap: 18px !important;
}

.rdg-logo {
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
  text-decoration: none;
}

.rdg-logo img {
  display: block;
  width: 176px;
  height: 44px;
}

.rdg-header-actions {
  gap: 14px !important;
  margin: 0 !important;
}

.rdg-header-phone {
  margin: 0 !important;
  white-space: nowrap;
  font-size: 15px;
  font-weight: 850;
  line-height: 1;
}

.rdg-header-phone a {
  color: var(--rd-text);
  text-decoration: none;
}

.rdg-header-phone a:hover {
  color: var(--rd-blue);
}

.rdg-header-button .wp-block-button__link {
  min-height: 42px;
  padding: 11px 18px;
  box-shadow: 0 10px 26px rgba(26, 115, 232, 0.18);
}

@media (max-width: 640px) {
  .rdg-site-header {
    padding: 8px 0 !important;
  }

  .rdg-header-inner {
    min-height: 54px !important;
    gap: 10px !important;
  }

  .rdg-logo img {
    width: 138px;
    height: auto;
  }

  .rdg-header-phone {
    display: none;
  }

  .rdg-header-actions .wp-block-buttons,
  .rdg-header-actions .wp-block-button,
  .rdg-header-actions .wp-block-button__link {
    width: auto !important;
  }

  .rdg-header-button .wp-block-button__link {
    min-height: 40px;
    padding: 10px 14px;
    font-size: 14px;
  }
}

.rdg-header-actions {
  margin-left: auto !important;
}

.rdg-logo img {
  width: 220px;
  max-width: min(52vw, 220px);
}

@media (max-width: 640px) {
  .rdg-logo img {
    width: 172px;
    max-width: 54vw;
  }
}

.rdg-logo {
  min-width: 240px;
}

.rdg-logo img {
  width: 240px;
  max-width: min(58vw, 240px);
  object-fit: contain;
}

@media (max-width: 640px) {
  .rdg-logo {
    min-width: 186px;
  }

  .rdg-logo img {
    width: 186px;
    max-width: 58vw;
  }
}

.rdg-metro-cover {
  margin-top: 0 !important;
  margin-bottom: 28px !important;
}

.rdg-metro-cover img {
  width: 100%;
  border-radius: 24px;
  box-shadow: var(--rd-shadow);
  object-fit: cover;
}

.rdg-aviamotornaya-gallery {
  margin-top: 0 !important;
  margin-bottom: 30px !important;
  gap: 16px !important;
}

.rdg-aviamotornaya-gallery .wp-block-image img {
  aspect-ratio: 16 / 9;
  width: 100%;
  height: 100%;
  border-radius: 24px;
  box-shadow: var(--rd-shadow);
  object-fit: cover;
}

@media (max-width: 700px) {
  .rdg-aviamotornaya-gallery {
    grid-template-columns: 1fr !important;
  }
}
