/* ============================================
   MODERN CHURCH WEBSITE STYLES
   ============================================ */

/* CSS Variables */
:root {
  /* Color Palette - Modern & Elegant Sacred Design */
  --primary-gold: #C9A961;
  --primary-gold-light: #E5C78A;
  --primary-gold-dark: #A68B4F;
  --primary-deep: #3D2817;
  --primary-deep-light: #5C3F2F;
  --primary-deep-dark: #2A1810;
  --accent-warm: #F5E6D3;
  --accent-warm-dark: #E8D4B8;
  --accent-soft: #D4C4B0;
  --accent-brown: #8B6F47;
  --accent-brown-light: #A68B62;
  --text-dark: #2B2016;
  --text-light: #6B5748;
  --white: #FFFFFF;
  --shadow-sm: 0 2px 12px rgba(61, 40, 23, 0.06);
  --shadow-md: 0 4px 20px rgba(61, 40, 23, 0.08);
  --shadow-lg: 0 8px 32px rgba(61, 40, 23, 0.12);
  --shadow-xl: 0 16px 48px rgba(61, 40, 23, 0.16);
  --shadow-glow: 0 4px 20px rgba(201, 169, 97, 0.2);
  
  /* Spacing */
  --spacing-xs: 0.5rem;
  --spacing-sm: 1rem;
  --spacing-md: 1.5rem;
  --spacing-lg: 2rem;
  --spacing-xl: 3rem;
  --spacing-xxl: 4rem;
  
  /* Typography */
  --font-heading: 'Playfair Display', serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  
  /* Transitions */
  --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-normal: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 0.5s cubic-bezier(0.4, 0, 0.2, 1);
  
  /* Border Radius */
  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-xl: 32px;
}

/* Reset & Base Styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
  overflow-x: hidden;
  width: 100%;
  max-width: 100vw;
}

body {
  font-family: var(--font-body);
  color: var(--text-dark);
  line-height: 1.75;
  background: linear-gradient(135deg, var(--accent-warm) 0%, var(--white) 40%, var(--accent-warm) 100%);
  background-attachment: fixed;
  overflow-x: hidden;
  position: relative;
  width: 100%;
  max-width: 100vw;
  margin: 0;
  padding: 0;
  padding-top: 90px;
}

/* Floating Decorative Elements */
.floating-elements {
  display: none; /* Убираем фоновые эмодзи храма */
}

.floating-icon {
  position: absolute;
  font-size: 200px;
  color: var(--primary-deep);
  animation: float 20s infinite ease-in-out;
}

.floating-icon:nth-child(1) {
  top: 10%;
  left: 10%;
  animation-delay: 0s;
}

.floating-icon:nth-child(2) {
  top: 50%;
  right: 15%;
  animation-delay: 7s;
}

.floating-icon:nth-child(3) {
  bottom: 15%;
  left: 20%;
  animation-delay: 14s;
}

@keyframes float {
  0%, 100% {
    transform: translate(0, 0) rotate(0deg);
    opacity: 0.03;
  }
  33% {
    transform: translate(30px, -30px) rotate(120deg);
    opacity: 0.05;
  }
  66% {
    transform: translate(-20px, 20px) rotate(240deg);
    opacity: 0.03;
  }
}

/* Container */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--spacing-md);
  position: relative;
  z-index: 2;
  width: 100%;
  box-sizing: border-box;
  left: 0;
  right: 0;
}

/* ============================================
   HEADER STYLES
   ============================================ */
.main-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(255, 255, 255, 0.97);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: 0 2px 20px rgba(61, 40, 23, 0.06);
  transition: all var(--transition-normal);
  border-bottom: 2px solid rgba(201, 169, 97, 0.2);
  width: 100%;
  max-width: 100vw;
  overflow-x: hidden;
}

.main-header.scrolled {
  box-shadow: 0 4px 30px rgba(61, 40, 23, 0.1);
  background: rgba(255, 255, 255, 0.99);
  border-bottom: 2px solid rgba(201, 169, 97, 0.25);
}

.header-background {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, var(--white) 0%, var(--accent-warm) 100%);
  opacity: 0.95;
  z-index: -1;
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--spacing-md) 0;
  gap: var(--spacing-lg);
  position: relative;
  min-height: 0;
}

/* Logo */
.logo {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
  text-decoration: none;
  color: var(--text-dark);
  z-index: 10;
  flex-shrink: 0;
  min-width: 0;
}

.logo-icon {
  width: 60px;
  height: 60px;
  object-fit: contain;
  display: block;
  transition: transform var(--transition-normal);
}

.logo:hover .logo-icon {
  transform: translateY(-2px) scale(1.05);
}

.logo-text {
  display: flex;
  flex-direction: column;
}

.logo-title {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--primary-deep);
  line-height: 1.2;
}

.logo-subtitle {
  font-size: 0.875rem;
  color: var(--text-light);
  font-weight: 400;
}

/* Mobile Menu Toggle */
.mobile-menu-toggle {
  display: none;
  flex-direction: column;
  gap: 6px;
  background: none;
  border: none;
  cursor: pointer;
  padding: var(--spacing-xs);
  z-index: 1001;
  transition: transform var(--transition-fast);
  position: relative;
}

/* Скрываем мобильное меню на десктопе */
@media (min-width: 769px) {
  .mobile-menu-overlay {
    display: none !important;
  }
  
  .mobile-menu-close {
    display: none !important;
  }
  
  .main-nav {
    position: relative !important;
    right: auto !important;
    width: auto !important;
    height: auto !important;
    background: none !important;
    box-shadow: none !important;
    overflow: visible !important;
  }
}

.mobile-menu-toggle span {
  width: 28px;
  height: 3px;
  background: var(--primary-deep);
  border-radius: 3px;
  transition: all var(--transition-fast);
  transform-origin: center;
}

.mobile-menu-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translateY(10px);
}

.mobile-menu-toggle.active span:nth-child(2) {
  opacity: 0;
}

.mobile-menu-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translateY(-10px);
}

/* Navigation */
.main-nav {
  flex: 1 1 auto;
  min-width: 0;
  max-width: 100%;
  overflow: hidden;
  position: relative;
}

.nav-list {
  display: flex;
  list-style: none;
  gap: var(--spacing-xs);
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  margin: 0;
  padding: 0;
}

.nav-list li {
  flex-shrink: 0;
}

.nav-link {
  position: relative;
  color: var(--text-dark);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.875rem;
  padding: var(--spacing-xs) var(--spacing-sm);
  border-radius: var(--radius-sm);
  transition: all var(--transition-fast);
  display: inline-block;
  white-space: nowrap;
  background: transparent;
  flex-shrink: 1;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 6px;
  left: 50%;
  transform: translateX(-50%) scaleX(0);
  width: calc(100% - 16px);
  height: 2px;
  background: linear-gradient(90deg, var(--primary-gold) 0%, var(--primary-gold-dark) 100%);
  border-radius: 2px;
  transition: transform var(--transition-normal);
}

.nav-link:hover {
  color: var(--primary-deep);
  background: rgba(201, 169, 97, 0.12);
  transform: translateY(-1px);
}

.nav-link:hover::after {
  transform: translateX(-50%) scaleX(1);
}

.nav-link:active {
  transform: translateY(0);
}

/* ============================================
   HERO SECTION
   ============================================ */
.hero {
  position: relative;
  min-height: 90vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: 
    linear-gradient(135deg, rgba(42, 24, 16, 0.75) 0%, rgba(61, 40, 23, 0.75) 50%, rgba(139, 111, 71, 0.75) 100%),
    url('/img/background.jpg');
  background-size: cover, cover;
  background-position: center, center;
  background-repeat: no-repeat, no-repeat;
  overflow: hidden;
  color: var(--white);
  margin-bottom: var(--spacing-xxl);
  isolation: isolate;
}

.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(212, 175, 55, 0.05) 0%, transparent 70%);
  animation: rotate 30s linear infinite;
  z-index: 0;
}

.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: 
    radial-gradient(circle at 20% 50%, rgba(212, 175, 55, 0.08) 0%, transparent 50%),
    radial-gradient(circle at 80% 80%, rgba(212, 175, 55, 0.05) 0%, transparent 50%);
  z-index: 1;
}

.hero-pattern {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: 
    repeating-linear-gradient(45deg, transparent, transparent 2px, rgba(255, 255, 255, 0.03) 2px, rgba(255, 255, 255, 0.03) 4px);
  opacity: 0.5;
  z-index: 1;
}

.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  animation: fadeInUp 1s ease-out;
  max-width: 900px;
  margin: 0 auto;
  padding: var(--spacing-xl) 0;
}

.hero-badge {
  display: inline-block;
  padding: var(--spacing-xs) var(--spacing-md);
  background: rgba(212, 175, 55, 0.2);
  border: 2px solid var(--primary-gold);
  border-radius: 50px;
  font-size: 0.875rem;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  margin-bottom: var(--spacing-lg);
  backdrop-filter: blur(10px);
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% {
    box-shadow: 0 0 0 0 rgba(212, 175, 55, 0.7);
  }
  50% {
    box-shadow: 0 0 0 10px rgba(212, 175, 55, 0);
  }
}

.hero-title {
  font-family: var(--font-heading);
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: var(--spacing-md);
  text-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.title-line {
  display: block;
  animation: fadeInUp 1s ease-out 0.2s both;
}

.title-line.highlight {
  background: linear-gradient(135deg, var(--primary-gold) 0%, var(--primary-gold-light) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: fadeInUp 1s ease-out 0.4s both;
}

.hero-subtitle {
  font-size: clamp(1rem, 2vw, 1.25rem);
  margin-bottom: var(--spacing-lg);
  opacity: 0.95;
  line-height: 1.8;
  animation: fadeInUp 1s ease-out 0.6s both;
}

.hero-info {
  display: flex;
  justify-content: center;
  gap: var(--spacing-lg);
  flex-wrap: wrap;
  animation: fadeInUp 1s ease-out 0.8s both;
}

.hero-info-item {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  padding: var(--spacing-md);
  background: rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-md);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.info-icon {
  width: 24px;
  height: 24px;
  color: var(--primary-gold);
}

.hero-scroll-indicator {
  position: absolute;
  bottom: var(--spacing-lg);
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  animation: bounce 2s infinite;
}

.scroll-arrow {
  width: 30px;
  height: 30px;
  border-right: 3px solid var(--primary-gold);
  border-bottom: 3px solid var(--primary-gold);
  transform: rotate(45deg);
}

@keyframes bounce {
  0%, 100% {
    transform: translateX(-50%) translateY(0);
  }
  50% {
    transform: translateX(-50%) translateY(10px);
  }
}

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

/* ============================================
   MAIN CONTENT
   ============================================ */
.main-content {
  position: relative;
  z-index: 2;
  padding: var(--spacing-xxl) 0;
  min-height: 60vh;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  margin: 0;
  left: 0;
  right: 0;
}
.content-section {
  margin-bottom: var(--spacing-xxl);
  animation: fadeIn 0.8s ease-out;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

/* Section Headers */
.section-header {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--spacing-md);
  margin-bottom: var(--spacing-xl);
  overflow: hidden;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

.section-decoration {
  flex: 1;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--primary-gold), transparent);
  max-width: 150px;
}

.section-title {
  font-family: var(--font-heading);
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 700;
  text-align: center;
  color: var(--primary-deep);
  position: relative;
  padding: 0 calc(var(--spacing-md) + 20px);
  max-width: 100%;
  box-sizing: border-box;
  min-width: 0;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.section-title::after {
  content: '';
  position: absolute;
  top: 50%;
  right: 8px;
  transform: translateY(-50%);
  width: 8px;
  height: 8px;
  background: var(--primary-gold);
  border-radius: 50%;
  opacity: 0.7;
  box-shadow: 
    0 0 0 1px rgba(218, 165, 32, 0.3),
    0 0 0 2px rgba(218, 165, 32, 0.15);
}

.section-title::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 8px;
  transform: translateY(-50%);
  width: 8px;
  height: 8px;
  background: var(--primary-gold);
  border-radius: 50%;
  opacity: 0.7;
  box-shadow: 
    0 0 0 1px rgba(218, 165, 32, 0.3),
    0 0 0 2px rgba(218, 165, 32, 0.15);
}

/* ============================================
   NEWS SECTION
   ============================================ */
.news-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: var(--spacing-lg);
  margin-top: var(--spacing-xl);
}

.news-card {
  background: var(--white);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(61, 40, 23, 0.06), 0 0 0 1px rgba(201, 169, 97, 0.1);
  transition: all var(--transition-normal);
  position: relative;
  border: 1px solid rgba(201, 169, 97, 0.15);
  animation: fadeInUp 0.6s ease-out both;
  backdrop-filter: blur(10px);
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

.news-card:nth-child(1) { animation-delay: 0.1s; }
.news-card:nth-child(2) { animation-delay: 0.2s; }
.news-card:nth-child(3) { animation-delay: 0.3s; }
.news-card:nth-child(4) { animation-delay: 0.4s; }
.news-card:nth-child(5) { animation-delay: 0.5s; }
.news-card:nth-child(6) { animation-delay: 0.6s; }

.news-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: linear-gradient(90deg, var(--primary-gold) 0%, var(--primary-gold-dark) 100%);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--transition-normal);
}

.news-card:hover {
  transform: translateY(-10px) scale(1.02);
  box-shadow: 0 12px 40px rgba(61, 40, 23, 0.12), 0 0 0 1px rgba(201, 169, 97, 0.3);
  border-color: rgba(201, 169, 97, 0.3);
}

.news-card:hover::before {
  transform: scaleX(1);
}

.news-card img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  transition: transform var(--transition-slow);
}

.news-card:hover img {
  transform: scale(1.05);
}

.news-card-content {
  padding: var(--spacing-lg);
}

.news-card h3 {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  color: var(--primary-deep);
  margin-bottom: var(--spacing-sm);
  line-height: 1.3;
}

.news-card p {
  color: var(--text-light);
  margin-bottom: var(--spacing-md);
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  line-height: 1.7;
}

.news-card-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: var(--spacing-md);
  padding-top: var(--spacing-md);
  border-top: 1px solid var(--accent-warm-dark);
}

.news-card-author {
  font-size: 0.875rem;
  color: var(--text-light);
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: var(--spacing-xs);
}

.news-author-icon {
  font-size: 1rem;
}

.news-card-date {
  font-size: 0.875rem;
  color: var(--primary-gold-dark);
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: var(--spacing-xs);
}

.news-card-date::before {
  content: '📆';
  font-size: 1rem;
}

.news-read-more-btn {
  display: inline-block;
  margin-top: var(--spacing-md);
  padding: var(--spacing-xs) var(--spacing-lg);
  background: linear-gradient(135deg, var(--primary-gold) 0%, var(--primary-gold-dark) 100%);
  color: var(--white);
  border: none;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-normal);
  font-family: var(--font-body);
}

.news-read-more-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(201, 169, 97, 0.4);
}

.news-read-more-btn:active {
  transform: translateY(0);
}

.news-card-content {
  cursor: pointer;
}

.news-card-content:hover {
  opacity: 0.95;
}

/* Пагинация новостей */
.news-pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: var(--spacing-lg);
  margin-top: var(--spacing-xl);
  padding: var(--spacing-lg) 0;
}

.pagination-btn {
  background: var(--white);
  border: 2px solid rgba(201, 169, 97, 0.3);
  color: var(--primary-deep);
  padding: var(--spacing-sm) var(--spacing-lg);
  border-radius: var(--radius-md);
  font-size: 1rem;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition-normal);
  font-family: var(--font-body);
}

.pagination-btn:hover:not(:disabled) {
  background: var(--primary-gold);
  color: var(--white);
  border-color: var(--primary-gold);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(201, 169, 97, 0.3);
}

.pagination-btn:active:not(:disabled) {
  transform: translateY(0);
}

.pagination-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.pagination-info {
  color: var(--text-light);
  font-size: 0.95rem;
  font-weight: 500;
  padding: 0 var(--spacing-md);
}

/* Адаптивность для пагинации */
@media (max-width: 768px) {
  .news-pagination {
    flex-wrap: wrap;
    gap: var(--spacing-md);
  }
  
  .pagination-btn {
    padding: var(--spacing-xs) var(--spacing-md);
    font-size: 0.9rem;
  }
  
  .pagination-info {
    width: 100%;
    text-align: center;
    order: -1;
  }
}

/* Карусель изображений в новостях */
.news-carousel {
  position: relative;
  width: 100%;
  height: 220px;
  overflow: hidden;
  touch-action: pan-y pinch-zoom; /* Разрешаем вертикальную прокрутку и масштабирование, но предотвращаем горизонтальную прокрутку браузера */
}

.carousel-container {
  position: relative;
  width: 100%;
  height: 100%;
  touch-action: none; /* Полный контроль над жестами для свайпа */
}

.carousel-slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 0.5s ease-in-out;
}

.carousel-slide.active {
  opacity: 1;
  z-index: 1;
}

.carousel-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.carousel-controls {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 100%;
  display: flex;
  justify-content: space-between;
  padding: 0 10px;
  z-index: 2;
  pointer-events: none;
}

.carousel-btn {
  background: rgba(255, 255, 255, 0.3);
  border: none;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 24px;
  color: var(--primary-deep);
  transition: all var(--transition-normal);
  pointer-events: all;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  backdrop-filter: blur(4px);
}

.carousel-btn:hover {
  background: rgba(255, 255, 255, 0.6);
  transform: scale(1.1);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.carousel-btn:active {
  transform: scale(0.95);
}

.carousel-indicators {
  position: absolute;
  bottom: 10px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
  z-index: 2;
}

.carousel-indicator {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: 2px solid var(--white);
  background: rgba(255, 255, 255, 0.5);
  cursor: pointer;
  transition: all var(--transition-normal);
  padding: 0;
}

.carousel-indicator:hover {
  background: rgba(255, 255, 255, 0.8);
  transform: scale(1.2);
}

.carousel-indicator.active {
  background: var(--white);
  transform: scale(1.3);
}

.news-card:hover .carousel-btn {
  opacity: 1;
}

/* Изображения в новостях - курсор указатель */
.news-image-clickable {
  cursor: pointer;
  transition: transform var(--transition-normal);
}

.news-image-clickable:hover {
  transform: scale(1.02);
}

/* Модальное окно для просмотра изображений */
.image-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s ease-in-out;
}

.image-modal.active {
  opacity: 1;
}

.image-modal-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.9);
  backdrop-filter: blur(5px);
}

.image-modal-content {
  position: relative;
  z-index: 10001;
  max-width: 90%;
  max-height: 90%;
  display: flex;
  align-items: center;
  justify-content: center;
  transform: scale(0.8);
  transition: transform 0.3s ease-in-out;
}

.image-modal.active .image-modal-content {
  transform: scale(1);
}

.image-modal-content img {
  max-width: 100%;
  max-height: 90vh;
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: var(--radius-md);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
}

.image-modal-close {
  position: absolute;
  top: -40px;
  right: 0;
  background: rgba(255, 255, 255, 0.2);
  border: 2px solid rgba(255, 255, 255, 0.5);
  color: var(--white);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-normal);
  z-index: 10002;
}

.image-modal-close:hover {
  background: rgba(255, 255, 255, 0.3);
  border-color: var(--white);
  transform: rotate(90deg);
}

/* Адаптивность для модального окна */
@media (max-width: 768px) {
  .image-modal-content {
    max-width: 95%;
    max-height: 85%;
  }
  
  .image-modal-content img {
    max-height: 85vh;
  }
  
  .image-modal-close {
    top: -35px;
    width: 35px;
    height: 35px;
    font-size: 24px;
  }
}

/* ============================================
   SCHEDULE SECTION
   ============================================ */
.schedule-list {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-xl);
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  margin: 0 auto;
}

/* День расписания */
.schedule-day {
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: var(--spacing-xl);
  box-shadow: 0 4px 20px rgba(61, 40, 23, 0.06), 0 0 0 1px rgba(201, 169, 97, 0.1);
  border: 1px solid rgba(201, 169, 97, 0.15);
  backdrop-filter: blur(10px);
  position: relative;
  overflow: hidden;
  transition: all var(--transition-normal);
  animation: fadeInUp 0.6s ease-out both;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
  width: 100%;
}

.schedule-day::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 5px;
  height: 100%;
  background: linear-gradient(180deg, var(--primary-gold) 0%, var(--primary-gold-dark) 100%);
  transform: scaleY(0);
  transform-origin: top;
  transition: transform var(--transition-normal);
}

.schedule-day:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 30px rgba(61, 40, 23, 0.12), 0 0 0 1px rgba(201, 169, 97, 0.25);
  border-color: rgba(201, 169, 97, 0.3);
}

.schedule-day:hover::before {
  transform: scaleY(1);
}

/* Заголовок дня */
.schedule-day-header {
  margin-bottom: var(--spacing-lg);
  padding-bottom: var(--spacing-md);
  border-bottom: 2px solid var(--accent-warm-dark);
}

.schedule-day-date {
  font-family: var(--font-heading);
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--primary-deep);
  line-height: 1.3;
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  margin-bottom: var(--spacing-xs);
}

.schedule-day-date::before {
  content: '📆';
  font-size: 1.5rem;
  opacity: 0.7;
}

/* Информация о дне (седмица, церковное описание) */
.schedule-day-info {
  margin-top: var(--spacing-sm);
  padding: var(--spacing-md);
  background: linear-gradient(135deg, rgba(201, 169, 97, 0.08) 0%, rgba(201, 169, 97, 0.03) 100%);
  border-radius: var(--radius-sm);
  border-left: 3px solid var(--primary-gold);
}

.schedule-day-info div {
  font-size: 1rem;
  line-height: 1.7;
  color: var(--text-dark);
  font-weight: 500;
  margin-bottom: var(--spacing-xs);
}

.schedule-day-info div:last-child {
  margin-bottom: 0;
}

.schedule-day-info div:first-child {
  color: var(--primary-deep);
  font-weight: 600;
}

/* Контейнер событий дня */
.schedule-day-events {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-md);
  margin-top: var(--spacing-lg);
}

/* Одно событие */
.schedule-event {
  display: grid;
  grid-template-columns: auto auto 1fr;
  align-items: start;
  gap: var(--spacing-md);
  padding: var(--spacing-md) var(--spacing-lg);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.9) 0%, rgba(245, 230, 211, 0.25) 100%);
  border-radius: var(--radius-md);
  border: 1px solid rgba(201, 169, 97, 0.2);
  transition: all var(--transition-fast);
  position: relative;
}

.schedule-event::before {
  display: none;
}

.schedule-event:hover {
  background: linear-gradient(135deg, rgba(201, 169, 97, 0.15) 0%, rgba(245, 230, 211, 0.4) 100%);
  border-color: rgba(201, 169, 97, 0.4);
  transform: translateX(6px);
  box-shadow: 0 4px 16px rgba(61, 40, 23, 0.1);
}

.schedule-event:hover::before {
  opacity: 0.4;
}

/* Время события */
.schedule-event-time {
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--primary-gold-dark);
  min-width: 80px;
  text-align: right;
  padding: var(--spacing-xs) var(--spacing-sm);
  background: rgba(201, 169, 97, 0.15);
  border-radius: var(--radius-sm);
  font-family: 'Courier New', monospace;
  letter-spacing: 0.5px;
  flex-shrink: 0;
}

/* Разделитель */
.schedule-event-separator {
  color: var(--primary-gold);
  font-weight: 600;
  font-size: 1.2rem;
  margin: 0 var(--spacing-xs);
  flex-shrink: 0;
  opacity: 0.6;
}

/* Название службы */
.schedule-event-name {
  flex: 1;
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text-dark);
  line-height: 1.6;
}

/* Описание события */
.schedule-event-description {
  grid-column: 1 / -1;
  margin-top: var(--spacing-sm);
  font-size: 0.95rem;
  color: var(--text-light);
  font-style: italic;
  line-height: 1.7;
  padding: var(--spacing-sm) var(--spacing-md);
  padding-left: calc(var(--spacing-md) + var(--spacing-lg));
  border-left: 3px solid rgba(201, 169, 97, 0.35);
  background: rgba(201, 169, 97, 0.05);
  border-radius: var(--radius-sm);
}

/* ============================================
   CONTENT BLOCKS
   ============================================ */
.content-block {
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: var(--spacing-xl);
  margin-bottom: var(--spacing-lg);
  box-shadow: 0 4px 20px rgba(61, 40, 23, 0.06), 0 0 0 1px rgba(201, 169, 97, 0.1);
  border-left: 4px solid var(--primary-gold);
  transition: all var(--transition-normal);
  backdrop-filter: blur(10px);
  position: relative;
  overflow: hidden;
}

.content-block::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
  background: linear-gradient(180deg, var(--primary-gold) 0%, var(--primary-gold-dark) 100%);
  transform: scaleY(0);
  transform-origin: top;
  transition: transform var(--transition-normal);
}

.content-block:hover {
  box-shadow: 0 8px 30px rgba(61, 40, 23, 0.1), 0 0 0 1px rgba(201, 169, 97, 0.2);
  transform: translateX(6px);
}

.content-block:hover::before {
  transform: scaleY(1);
}

.content-block h2 {
  font-family: var(--font-heading);
  font-size: 2rem;
  color: var(--primary-deep);
  margin-bottom: var(--spacing-md);
  line-height: 1.3;
}

.content-block p {
  line-height: 1.5;
  color: var(--text-dark);
  margin-bottom: var(--spacing-sm);
  font-size: 1.05rem;
}

.content-block img {
  max-width: 100%;
  height: auto;
  border-radius: var(--radius-md);
  margin: var(--spacing-md) 0;
}

.content-block ul,
.content-block ol {
  margin: var(--spacing-md) 0;
  padding-left: var(--spacing-xl);
}

.content-block ul li,
.content-block ol li {
  margin-bottom: var(--spacing-xs);
  line-height: 1.5;
}

.content-block h1,
.content-block h3 {
  font-family: var(--font-heading);
  color: var(--primary-deep);
  margin-top: var(--spacing-lg);
  margin-bottom: var(--spacing-md);
  font-weight: 700;
}

.content-block h1 {
  font-size: 2rem;
}

.content-block h3 {
  font-size: 1.5rem;
}

.content-block a {
  color: var(--primary-gold-dark);
  text-decoration: underline;
  transition: color var(--transition-normal);
}

.content-block a:hover {
  color: var(--primary-gold);
}

.content-block u {
  text-decoration: underline;
}

.content-block s {
  text-decoration: line-through;
}

.content-block [style*="text-align: center"],
.content-block .ql-align-center {
  text-align: center;
}

.content-block [style*="text-align: right"],
.content-block .ql-align-right {
  text-align: right;
}

.content-block [style*="text-align: justify"],
.content-block .ql-align-justify {
  text-align: justify;
}

.content-block blockquote {
  border-left: 4px solid var(--primary-gold);
  padding-left: var(--spacing-md);
  margin: var(--spacing-lg) 0;
  font-style: italic;
  color: var(--text-light);
}

/* Page Content Styles */
.page-content-full {
  width: 100%;
}

/* Page Images Styles */
.page-image-wrapper {
  margin: var(--spacing-xl) 0;
  border-radius: var(--radius-md);
  overflow: hidden;
}

.page-image-wrapper img {
  width: 100%;
  height: auto;
  max-height: 600px;
  object-fit: contain;
  display: block;
  border-radius: var(--radius-md);
}

.page-carousel {
  position: relative;
  width: 100%;
  height: 500px;
  overflow: hidden;
  touch-action: pan-y pinch-zoom;
}

.page-carousel .carousel-container {
  position: relative;
  width: 100%;
  height: 100%;
  touch-action: none;
}

.page-carousel .carousel-slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 0.5s ease-in-out;
}

.page-carousel .carousel-slide.active {
  opacity: 1;
  z-index: 1;
}

.page-carousel .carousel-slide img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

/* Предотвращение горизонтальной прокрутки для медиа-элементов */
img,
video,
iframe,
embed,
object {
  max-width: 100%;
  height: auto;
}

/* ============================================
   WIDGETS
   ============================================ */
.widgets-wrapper {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: var(--spacing-lg);
  margin-top: var(--spacing-xl);
}

.widget {
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: var(--spacing-lg);
  box-shadow: 0 4px 20px rgba(61, 40, 23, 0.06), 0 0 0 1px rgba(201, 169, 97, 0.1);
  border: 1px solid rgba(201, 169, 97, 0.15);
  transition: all var(--transition-normal);
  backdrop-filter: blur(10px);
  position: relative;
  overflow: hidden;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

.widget::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 3px;
  background: linear-gradient(90deg, var(--primary-gold) 0%, var(--primary-gold-dark) 100%);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--transition-normal);
}

.widget:hover {
  transform: translateY(-6px);
  box-shadow: 0 8px 30px rgba(61, 40, 23, 0.1), 0 0 0 1px rgba(201, 169, 97, 0.25);
  border-color: rgba(201, 169, 97, 0.25);
}

.widget:hover::after {
  transform: scaleX(1);
}

.widget-title {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  color: var(--primary-deep);
  margin-bottom: var(--spacing-md);
  padding-bottom: var(--spacing-sm);
  border-bottom: 2px solid var(--primary-gold);
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
}

.widget-title::before {
  content: '✨';
  font-size: 1.2rem;
}

/* Calendar Widget */
.calendar-widget {
  text-align: center;
  padding: var(--spacing-md) 0;
}

.calendar-widget .current-date {
  font-size: 4rem;
  font-weight: 700;
  color: var(--primary-gold);
  font-family: var(--font-heading);
  line-height: 1;
  margin-bottom: var(--spacing-xs);
}

.calendar-widget .current-month {
  font-size: 1.2rem;
  color: var(--text-dark);
  font-weight: 500;
  margin-bottom: var(--spacing-md);
  text-transform: capitalize;
}

.calendar-widget .current-holiday {
  color: var(--primary-deep);
  font-size: 1rem;
  font-weight: 500;
  padding: var(--spacing-sm);
  background: rgba(201, 169, 97, 0.15);
  border-radius: var(--radius-sm);
  display: inline-block;
}

/* ============================================
   DONATIONS SECTION
   ============================================ */
.donations-wrapper {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--spacing-md);
}

/* Описание пожертвований */
.donation-description-section {
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: var(--spacing-xl);
  margin-bottom: var(--spacing-xl);
  box-shadow: var(--shadow-md);
  border: 1px solid rgba(201, 169, 97, 0.15);
  animation: fadeInUp 0.6s ease-out;
}

.donation-text-content {
  color: var(--text-dark);
  font-size: 1.1rem;
  line-height: 1.8;
}

.donation-text-content p {
  margin-bottom: var(--spacing-md);
  color: var(--text-dark);
}

.donation-text-content p:last-child {
  margin-bottom: 0;
}

.donation-text-content strong {
  color: var(--primary-deep);
  font-weight: 600;
}

/* Секция с реквизитами */
.donation-details-section {
  margin-top: var(--spacing-xl);
}

.donation-details-title {
  font-family: var(--font-heading);
  font-size: clamp(1.75rem, 3vw, 2.5rem);
  font-weight: 700;
  color: var(--primary-deep);
  text-align: center;
  margin-bottom: var(--spacing-xl);
  position: relative;
  padding-bottom: var(--spacing-md);
}

.donation-details-title::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100px;
  height: 3px;
  background: linear-gradient(90deg, transparent, var(--primary-gold), transparent);
  border-radius: 2px;
}

.donation-details-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: var(--spacing-lg);
  margin-bottom: var(--spacing-xl);
}

@media (min-width: 1024px) {
  .donation-details-grid {
    grid-template-columns: repeat(auto-fill, minmax(380px, 1fr));
  }
}

/* Карточка реквизита */
.donation-detail-card {
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: var(--spacing-lg);
  box-shadow: var(--shadow-md);
  border: 1px solid rgba(201, 169, 97, 0.15);
  transition: all var(--transition-normal);
  position: relative;
  overflow: hidden;
  animation: fadeInUp 0.6s ease-out both;
  min-width: 0; /* Позволяет карточке сжиматься при необходимости */
  width: 100%;
}

.donation-detail-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: linear-gradient(90deg, var(--primary-gold) 0%, var(--primary-gold-dark) 100%);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--transition-normal);
}

.donation-detail-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
  border-color: rgba(201, 169, 97, 0.3);
}

.donation-detail-card:hover::before {
  transform: scaleX(1);
}

.donation-detail-card:nth-child(1) { animation-delay: 0.1s; }
.donation-detail-card:nth-child(2) { animation-delay: 0.2s; }
.donation-detail-card:nth-child(3) { animation-delay: 0.3s; }
.donation-detail-card:nth-child(4) { animation-delay: 0.4s; }

/* Заголовок карточки */
.donation-detail-header {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
  margin-bottom: var(--spacing-lg);
  padding-bottom: var(--spacing-md);
  border-bottom: 2px solid var(--accent-warm);
}

.donation-type-badge {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  flex-shrink: 0;
  box-shadow: var(--shadow-sm);
}

.donation-type-card {
  background: linear-gradient(135deg, var(--primary-gold) 0%, var(--primary-gold-dark) 100%);
}

.donation-type-sbp {
  background: linear-gradient(135deg, #4CAF50 0%, #388E3C 100%);
}

.donation-type-title {
  font-family: var(--font-heading);
  font-size: 1.3rem;
  font-weight: 600;
  color: var(--primary-deep);
  margin: 0;
  flex: 1;
}

/* Тело карточки */
.donation-detail-body {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-md);
}

.donation-field {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-xs);
}

.donation-field-label {
  font-size: 0.9rem;
  color: var(--text-light);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.donation-field-value {
  font-size: 1.05rem;
  color: var(--text-dark);
  font-weight: 500;
}

.donation-payment-number {
  font-size: clamp(1rem, 2.5vw, 1.3rem);
  font-weight: 700;
  color: var(--primary-deep);
  font-family: 'Courier New', 'Monaco', monospace;
  letter-spacing: 0.05em;
  padding: var(--spacing-sm) var(--spacing-md);
  background: linear-gradient(135deg, var(--accent-warm) 0%, var(--accent-warm-dark) 100%);
  border-radius: var(--radius-md);
  text-align: center;
  border: 2px solid rgba(201, 169, 97, 0.2);
  margin-top: var(--spacing-xs);
  transition: all var(--transition-normal);
  word-break: break-word;
  overflow-wrap: break-word;
  line-height: 1.4;
  min-height: 3rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.donation-payment-number:hover {
  background: linear-gradient(135deg, var(--accent-warm-dark) 0%, var(--accent-warm) 100%);
  border-color: rgba(201, 169, 97, 0.4);
  transform: scale(1.02);
}

/* Благодарность */
.donation-thanks {
  text-align: center;
  font-size: 1.1rem;
  color: var(--text-light);
  font-style: italic;
  margin-top: var(--spacing-xl);
  padding: var(--spacing-lg);
  background: linear-gradient(135deg, var(--accent-warm) 0%, var(--white) 100%);
  border-radius: var(--radius-md);
  border: 1px solid rgba(201, 169, 97, 0.2);
}

/* Адаптивность */
@media (max-width: 768px) {
  .donation-details-grid {
    grid-template-columns: 1fr;
  }
  
  .donation-description-section {
    padding: var(--spacing-lg);
  }
  
  .donation-text-content {
    font-size: 1rem;
  }
  
  .donation-payment-number {
    font-size: 1.1rem;
    padding: var(--spacing-sm);
  }
  
  .donation-detail-card {
    padding: var(--spacing-md);
  }
}


/* ============================================
   FOOTER
   ============================================ */
.main-footer {
  background: var(--primary-deep-dark);
  color: var(--white);
  margin-top: var(--spacing-xxl);
  position: relative;
  padding: var(--spacing-xxl) 0 var(--spacing-lg);
  overflow: hidden;
}

.footer-background {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: 
    linear-gradient(135deg, var(--primary-deep-dark) 0%, var(--primary-deep) 100%),
    repeating-linear-gradient(45deg, transparent, transparent 2px, rgba(201, 169, 97, 0.05) 2px, rgba(201, 169, 97, 0.05) 4px);
  opacity: 0.95;
  z-index: -1;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: var(--spacing-xl);
  margin-bottom: var(--spacing-xl);
}

.footer-section {
  position: relative;
  z-index: 1;
}

.footer-title {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  margin-bottom: var(--spacing-md);
  color: var(--primary-gold);
}

.footer-subtitle {
  font-size: 1.2rem;
  margin-bottom: var(--spacing-md);
  color: var(--primary-gold-light);
}

.footer-nav {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-sm);
}

.footer-nav a {
  color: rgba(255, 255, 255, 0.8);
  text-decoration: none;
  transition: all var(--transition-fast);
  padding: var(--spacing-xs) 0;
  position: relative;
  padding-left: var(--spacing-md);
}

.footer-nav a::before {
  content: '→';
  position: absolute;
  left: 0;
  opacity: 0;
  transition: all var(--transition-fast);
}

.footer-nav a:hover {
  color: var(--primary-gold);
  padding-left: var(--spacing-lg);
}

.footer-nav a:hover::before {
  opacity: 1;
}

.footer-bottom {
  text-align: center;
  padding-top: var(--spacing-lg);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.7);
  position: relative;
  z-index: 1;
}

.footer-credits-link {
  color: rgba(255, 255, 255, 0.7);
  text-decoration: underline;
  transition: opacity var(--transition-normal);
}

.footer-credits-link:hover {
  opacity: 0.9;
}

/* ============================================
   BUTTONS
   ============================================ */
.btn {
  display: inline-block;
  padding: var(--spacing-md) var(--spacing-lg);
  background: linear-gradient(135deg, var(--primary-gold) 0%, var(--primary-gold-dark) 100%);
  color: var(--white);
  text-decoration: none;
  border-radius: var(--radius-md);
  font-weight: 600;
  transition: all var(--transition-normal);
  border: none;
  cursor: pointer;
  font-size: 1rem;
  box-shadow: var(--shadow-md);
  position: relative;
  overflow: hidden;
}

.btn::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.3);
  transform: translate(-50%, -50%);
  transition: width 0.6s, height 0.6s;
}

.btn:hover::before {
  width: 300px;
  height: 300px;
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.btn:active {
  transform: translateY(0);
}

.btn-secondary {
  background: linear-gradient(135deg, var(--white) 0%, var(--accent-warm) 100%);
  color: var(--primary-deep);
  border: 2px solid var(--primary-gold);
}

.btn-secondary:hover {
  background: linear-gradient(135deg, var(--primary-gold-light) 0%, var(--primary-gold) 100%);
  color: var(--white);
}

/* ============================================
   FULL NEWS PAGE
   ============================================ */
.full-news-section {
  padding: var(--spacing-xl) 0 var(--spacing-xl) 0;
  margin-top: 0;
  min-height: 70vh;
}

/* Дополнительный отступ сверху для полной новости, чтобы не пряталась под хедером */
#main-content .full-news-section {
  padding-top: var(--spacing-lg);
  margin-top: 0;
}

.full-news-container {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 var(--spacing-md);
}

.full-news-back-btn {
  display: inline-flex;
  align-items: center;
  gap: var(--spacing-xs);
  padding: var(--spacing-md) var(--spacing-lg);
  background: var(--white);
  border: 2px solid rgba(201, 169, 97, 0.3);
  color: var(--primary-deep);
  border-radius: var(--radius-md);
  font-size: 1rem;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition-normal);
  font-family: var(--font-body);
  flex: 0 0 auto;
}

.full-news-back-btn:hover {
  background: var(--primary-gold);
  color: var(--white);
  border-color: var(--primary-gold);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(201, 169, 97, 0.3);
}

.full-news-back-btn:active {
  transform: translateY(0);
}

.full-news-article {
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: var(--spacing-xxl);
  box-shadow: 0 4px 20px rgba(61, 40, 23, 0.06), 0 0 0 1px rgba(201, 169, 97, 0.1);
  border: 1px solid rgba(201, 169, 97, 0.15);
  backdrop-filter: blur(10px);
}

.full-news-header {
  margin-bottom: var(--spacing-xl);
  padding-bottom: var(--spacing-lg);
  border-bottom: 2px solid var(--accent-warm-dark);
}

.full-news-title {
  font-family: var(--font-heading);
  font-size: clamp(2rem, 4vw, 3rem);
  color: var(--primary-deep);
  margin-bottom: var(--spacing-lg);
  line-height: 1.3;
}

.full-news-meta {
  display: flex;
  gap: var(--spacing-xl);
  flex-wrap: wrap;
  align-items: center;
}

.full-news-author,
.full-news-date {
  display: flex;
  align-items: center;
  gap: var(--spacing-xs);
  font-size: 1rem;
  color: var(--text-light);
  font-weight: 500;
}

.news-date-icon {
  font-size: 1.1rem;
}

.full-news-image-wrapper {
  margin: var(--spacing-xl) 0;
  border-radius: var(--radius-md);
  overflow: hidden;
}

.full-news-image-wrapper img {
  width: 100%;
  height: auto;
  max-height: 600px;
  object-fit: contain;
  display: block;
  border-radius: var(--radius-md);
}

.full-news-carousel {
  position: relative;
  width: 100%;
  height: 500px;
  overflow: hidden;
  touch-action: pan-y pinch-zoom;
}

.full-news-carousel .carousel-container {
  position: relative;
  width: 100%;
  height: 100%;
  touch-action: none;
}

.full-news-carousel .carousel-slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 0.5s ease-in-out;
}

.full-news-carousel .carousel-slide.active {
  opacity: 1;
  z-index: 1;
}

.full-news-carousel .carousel-slide img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.full-news-content {
  margin-top: var(--spacing-xl);
  line-height: 1.9;
  color: var(--text-dark);
  font-size: 1.1rem;
}

.full-news-content p {
  margin-bottom: var(--spacing-lg);
  text-align: justify;
}

.full-news-content img {
  max-width: 100%;
  height: auto;
  border-radius: var(--radius-md);
  margin: var(--spacing-lg) 0;
}

.full-news-content strong {
  color: var(--primary-deep);
  font-weight: 600;
}

.full-news-content ul,
.full-news-content ol {
  margin: var(--spacing-md) 0;
  padding-left: var(--spacing-xl);
}

.full-news-content ul li,
.full-news-content ol li {
  margin-bottom: var(--spacing-xs);
  line-height: 1.8;
}

.full-news-content h1,
.full-news-content h2,
.full-news-content h3 {
  font-family: var(--font-heading);
  color: var(--primary-deep);
  margin-top: var(--spacing-lg);
  margin-bottom: var(--spacing-md);
  font-weight: 700;
}

.full-news-content h1 {
  font-size: 2rem;
}

.full-news-content h2 {
  font-size: 1.75rem;
}

.full-news-content h3 {
  font-size: 1.5rem;
}

.full-news-content a {
  color: var(--primary-gold-dark);
  text-decoration: underline;
  transition: color var(--transition-normal);
}

.full-news-content a:hover {
  color: var(--primary-gold);
}

.full-news-content u {
  text-decoration: underline;
}

.full-news-content s {
  text-decoration: line-through;
}

.full-news-content [style*="text-align: center"],
.full-news-content .ql-align-center {
  text-align: center;
}

.full-news-content [style*="text-align: right"],
.full-news-content .ql-align-right {
  text-align: right;
}

.full-news-content [style*="text-align: justify"],
.full-news-content .ql-align-justify {
  text-align: justify;
}

.full-news-content blockquote {
  border-left: 4px solid var(--primary-gold);
  padding-left: var(--spacing-md);
  margin: var(--spacing-lg) 0;
  font-style: italic;
  color: var(--text-light);
}

.full-news-footer {
  margin-top: var(--spacing-xxl);
  padding-top: var(--spacing-xl);
  border-top: 2px solid var(--accent-warm-dark);
}

.full-news-navigation {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--spacing-md);
  flex-wrap: wrap;
}

.full-news-navigation > div:empty {
  flex: 1 1 0;
  min-width: 0;
}

.full-news-nav-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--spacing-xs);
  padding: var(--spacing-md) var(--spacing-lg);
  background: var(--white);
  border: 2px solid rgba(201, 169, 97, 0.3);
  color: var(--primary-deep);
  text-decoration: none;
  border-radius: var(--radius-md);
  font-size: 1rem;
  font-weight: 500;
  transition: all var(--transition-normal);
  font-family: var(--font-body);
  white-space: nowrap;
}

.full-news-nav-btn:hover {
  background: var(--primary-gold);
  color: var(--white);
  border-color: var(--primary-gold);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(201, 169, 97, 0.3);
}

.full-news-nav-btn:active {
  transform: translateY(0);
}

.full-news-nav-btn.full-news-prev {
  order: 1;
  flex: 0 1 auto;
}

.full-news-back-btn {
  order: 2;
  flex: 0 0 auto;
}

.full-news-nav-btn.full-news-next {
  order: 3;
  flex: 0 1 auto;
  margin-left: auto;
}

.full-news-error {
  text-align: center;
  padding: var(--spacing-xxl);
  color: var(--text-light);
}

.full-news-error h2 {
  font-family: var(--font-heading);
  color: var(--primary-deep);
  margin-bottom: var(--spacing-md);
}

/* Адаптивность для полной новости */
@media (max-width: 768px) {
  .full-news-section {
    padding: var(--spacing-xs) 0 var(--spacing-xl) 0;
    margin-top: calc(-1 * var(--spacing-xl) + var(--spacing-xs));
  }
  
  .full-news-container {
    max-width: 100%;
    padding: 0;
  }
  
  .full-news-article {
    padding: var(--spacing-lg);
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
  }
  
  .full-news-title {
    font-size: 1.75rem;
  }
  
  .full-news-meta {
    flex-direction: column;
    align-items: flex-start;
    gap: var(--spacing-md);
  }
  
  .full-news-content {
    font-size: 1rem;
  }
  
  .full-news-navigation {
    flex-direction: column;
    gap: var(--spacing-md);
  }
  
  .full-news-navigation > div:empty {
    display: none;
  }
  
  .full-news-nav-btn,
  .full-news-back-btn {
    width: 100%;
    justify-content: center;
    order: unset !important;
    margin-left: 0 !important;
  }
  
  .full-news-carousel {
    height: auto;
    min-height: 200px;
    margin: calc(var(--spacing-xl) / 3) 0;
  }
  
  .full-news-carousel .carousel-container {
    height: auto;
  }
  
  .full-news-carousel .carousel-slide {
    position: relative;
    height: auto;
    opacity: 0;
    display: none;
  }
  
  .full-news-carousel .carousel-slide.active {
    position: relative;
    height: auto;
    opacity: 1;
    display: block;
  }
  
  .full-news-carousel .carousel-slide img {
    width: 100%;
    height: auto;
    max-height: 70vh;
    object-fit: contain;
  }
  
  .page-carousel {
    height: auto;
    min-height: 200px;
    margin: calc(var(--spacing-xl) / 3) 0;
  }
  
  .page-carousel .carousel-container {
    height: auto;
  }
  
  .page-carousel .carousel-slide {
    position: relative;
    height: auto;
    opacity: 0;
    display: none;
  }
  
  .page-carousel .carousel-slide.active {
    position: relative;
    height: auto;
    opacity: 1;
    display: block;
  }
  
  .page-carousel .carousel-slide img {
    width: 100%;
    height: auto;
    max-height: 70vh;
    object-fit: contain;
  }
  
  /* Уменьшаем отступы у изображений и каруселей на мобильных в 3 раза */
  .page-image-wrapper {
    margin: calc(var(--spacing-xl) / 3) 0;
  }
  
  .full-news-image-wrapper {
    margin: calc(var(--spacing-xl) / 3) 0;
  }
  
  /* Уменьшаем отступы у изображений внутри контента на мобильных в 3 раза */
  .full-news-content img {
    margin: calc(var(--spacing-lg) / 3) 0;
  }
  
  .content-block img {
    margin: calc(var(--spacing-md) / 3) 0;
  }
  
  /* Контейнеры контента для страниц "О храме", "Воскресная школа", "Социальная деятельность", "История" */
  .content-block {
    padding: var(--spacing-md);
    width: 100%;
    max-width: 100%;
    margin-left: 0;
    margin-right: 0;
    box-sizing: border-box;
  }
  
  /* Раздел "Духовенство" */
  .clergy-section {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
  }
  
  .clergy-grid {
    padding: 0;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
  }
  
  .clergy-card {
    width: 100%;
    max-width: 100%;
    padding: var(--spacing-md);
    box-sizing: border-box;
    margin-left: 0;
    margin-right: 0;
  }
  
  .clergy-contact {
    flex-wrap: wrap;
    justify-content: flex-start;
    padding: var(--spacing-sm);
    width: 100%;
  }
  
  .clergy-contact a {
    font-size: 0.875rem;
    line-height: 1.4;
  }
}

/* ============================================
   LOADING STATE
   ============================================ */
.loading {
  text-align: center;
  padding: var(--spacing-xl);
  color: var(--text-light);
  font-size: 1.1rem;
  position: relative;
}

.loading::after {
  content: '...';
  animation: dots 1.5s steps(4, end) infinite;
}

@keyframes dots {
  0%, 20% {
    content: '.';
  }
  40% {
    content: '..';
  }
  60%, 100% {
    content: '...';
  }
}

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */
@media (max-width: 1024px) {
  .news-grid {
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  }
  
  /* Уменьшаем размер навигации на средних экранах */
  .nav-link {
    font-size: 0.8rem;
    padding: var(--spacing-xs) calc(var(--spacing-xs) + 2px);
  }
  
  .nav-list {
    gap: 2px;
  }
}

@media (max-width: 768px) {
  html {
    font-size: 14px;
  }
  
  .container {
    padding: 0 var(--spacing-sm);
  }
  
  body {
    padding-top: 70px;
  }
  
  /* Header Mobile */
  .main-header {
    overflow: visible;
    z-index: 100;
  }
  
  .header-content {
    padding: var(--spacing-sm) 0;
    overflow: visible;
  }
  
  .logo {
    gap: var(--spacing-sm);
  }
  
  .logo-icon {
    width: 50px;
    height: 50px;
  }
  
  .logo-title {
    font-size: 1rem;
  }
  
  .logo-subtitle {
    font-size: 0.75rem;
  }
  
  /* Mobile Menu */
  .mobile-menu-toggle {
    display: flex;
  }
  
  .mobile-menu-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    /* Ширина будет установлена через JavaScript в зависимости от ширины меню */
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.5);
    z-index: 9998;
    opacity: 0;
    transition: opacity 0.3s ease-out;
    pointer-events: none;
  }
  
  .mobile-menu-overlay.active {
    display: block;
    opacity: 1;
    /* Overlay визуальный, но НЕ блокирует события - они проходят через него */
    pointer-events: none;
  }
  
  .main-nav {
    position: fixed !important;
    top: 0;
    right: -100%;
    width: 85%;
    max-width: 380px;
    height: 100vh;
    background: linear-gradient(180deg, var(--white) 0%, var(--accent-warm) 100%);
    box-shadow: -4px 0 32px rgba(0, 0, 0, 0.15);
    transition: right var(--transition-normal) ease-in-out;
    z-index: 10000;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 0;
    margin: 0;
    pointer-events: auto;
    touch-action: auto;
    -webkit-overflow-scrolling: touch;
  }
  
  .main-nav.active {
    right: 0 !important;
  }
  
  .main-nav * {
    pointer-events: auto;
    -webkit-tap-highlight-color: transparent;
  }
  
  /* Кнопка закрытия меню (крестик) */
  .mobile-menu-close {
    position: absolute;
    top: var(--spacing-md);
    right: var(--spacing-md);
    width: 44px;
    height: 44px;
    background: rgba(61, 40, 23, 0.1);
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10001;
    transition: all var(--transition-fast);
    color: var(--primary-deep);
    font-size: 0;
  }
  
  .mobile-menu-close span {
    font-size: 2rem;
    line-height: 1;
    font-weight: 300;
    display: block;
  }
  
  .mobile-menu-close:hover {
    background: rgba(61, 40, 23, 0.2);
    transform: scale(1.1);
  }
  
  .mobile-menu-close:active {
    transform: scale(0.95);
  }
  
  /* Overlay для мобильного меню будет через отдельный элемент */
  
  .nav-list {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 90px var(--spacing-lg) var(--spacing-xl);
    margin: 0;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
  }
  
  .nav-list li {
    width: 100%;
    border-bottom: 1px solid rgba(201, 169, 97, 0.15);
  }
  
  .nav-list li:last-child {
    border-bottom: none;
  }
  
  .nav-link {
    display: block;
    padding: var(--spacing-md);
    font-size: 1.05rem;
    width: 100%;
    border-radius: var(--radius-sm);
    margin: var(--spacing-xs) 0;
    white-space: normal;
  }
  
  .nav-link::after {
    display: none;
  }
  
  .nav-link:hover {
    background: rgba(201, 169, 97, 0.15);
    transform: translateX(8px);
    padding-left: calc(var(--spacing-md) + 8px);
  }
  
  /* Hero Mobile */
  .hero {
    min-height: 70vh;
    margin-bottom: var(--spacing-xl);
  }
  
  .hero-content {
    padding: var(--spacing-lg) 0;
  }
  
  .hero-info {
    flex-direction: column;
    align-items: center;
  }
  
  /* Sections Mobile */
  .section-header {
    flex-direction: column;
    gap: var(--spacing-sm);
    padding: 0 var(--spacing-md);
  }
  
  .section-decoration {
    max-width: 100px;
  }
  
  .section-title {
    padding: 0 calc(var(--spacing-sm) + 16px);
  }
  
  .section-title::before,
  .section-title::after {
    width: 6px;
    height: 6px;
  }
  
  .section-title::before {
    left: 4px;
  }
  
  .section-title::after {
    right: 4px;
  }
  
  /* Уменьшаем отступ от шапки до заголовка на мобильных */
  .main-content {
    padding-top: var(--spacing-xs);
    padding-bottom: var(--spacing-md);
  }
  
  /* News Mobile */
  .news-grid {
    grid-template-columns: 1fr;
    gap: var(--spacing-md);
  }
  
  .news-card-footer {
    flex-direction: column;
    align-items: flex-start;
    gap: var(--spacing-xs);
  }
  
  .news-read-more-btn {
    width: 100%;
    text-align: center;
  }
  
  /* Schedule Mobile */
  .schedule-day {
    padding: var(--spacing-md);
  }
  
  .schedule-day-date {
    font-size: 1.4rem;
    flex-direction: column;
    align-items: flex-start;
    gap: var(--spacing-xs);
  }
  
  .schedule-day-date::before {
    font-size: 1.3rem;
  }
  
  .schedule-day-info {
    padding: var(--spacing-sm);
  }
  
  .schedule-day-info div {
    font-size: 0.9rem;
  }
  
  .schedule-event {
    flex-direction: column;
    gap: var(--spacing-sm);
    padding: var(--spacing-sm);
  }
  
  .schedule-event::before {
    display: none;
  }
  
  .schedule-event-time {
    min-width: auto;
    text-align: left;
    width: 100%;
    padding: var(--spacing-xs);
  }
  
  .schedule-event-separator {
    display: none;
  }
  
  .schedule-event-name {
    font-size: 1rem;
  }
  
  .schedule-event-description {
    padding-left: var(--spacing-sm);
    font-size: 0.9rem;
  }
  
  /* Widgets Mobile */
  .widgets-wrapper {
    grid-template-columns: 1fr;
  }
  
  /* Footer Mobile */
  .footer-content {
    grid-template-columns: 1fr;
    gap: var(--spacing-lg);
  }
}

@media (max-width: 480px) {
  .hero-title {
    font-size: 2rem;
  }
  
  .section-title {
    font-size: 1.75rem;
    padding: 0 calc(var(--spacing-xs) + 14px);
  }
  
  .section-title::before,
  .section-title::after {
    width: 5px;
    height: 5px;
  }
  
  .section-title::before {
    left: 2px;
  }
  
  .section-title::after {
    right: 2px;
  }
  
  .content-block {
    padding: var(--spacing-md);
  }
  
  .news-card-content,
  .widget {
    padding: var(--spacing-md);
  }
  
  .clergy-card img {
    width: 150px;
    height: 150px;
  }
}

/* ============================================
   PRINT STYLES
   ============================================ */
@media print {
  .floating-elements,
  .main-header,
  .main-footer,
  .hero-scroll-indicator {
    display: none;
  }
  
  body {
    background: white;
  }
  
  .news-card,
  .content-block,
  .widget {
    break-inside: avoid;
    box-shadow: none;
    border: 1px solid #ddd;
  }
}

/* ============================================
   ACCESSIBILITY
   ============================================ */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* Focus styles for keyboard navigation */
a:focus,
button:focus,
.nav-link:focus {
  outline: 3px solid var(--primary-gold);
  outline-offset: 2px;
}

/* Skip to main content link */
.skip-link {
  position: absolute;
  top: -40px;
  left: 0;
  background: var(--primary-deep);
  color: var(--white);
  padding: var(--spacing-sm);
  text-decoration: none;
  z-index: 10000;
}

.skip-link:focus {
  top: 0;
}

/* ============================================
   CLERGY SECTION
   ============================================ */

.clergy-section {
  margin-bottom: var(--spacing-xxl);
}

.clergy-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--spacing-xl);
  margin-top: var(--spacing-xl);
  padding: 0 var(--spacing-sm);
}

.clergy-card {
  background: linear-gradient(135deg, var(--white) 0%, var(--accent-warm) 100%);
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(61, 40, 23, 0.06), 0 0 0 1px rgba(201, 169, 97, 0.1);
  transition: all var(--transition-normal);
  display: flex;
  flex-direction: column;
  padding: var(--spacing-xl);
  position: relative;
  border: 1px solid rgba(201, 169, 97, 0.15);
  backdrop-filter: blur(10px);
  animation: fadeInUp 0.6s ease-out both;
}

.clergy-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 5px;
  background: linear-gradient(90deg, var(--primary-gold) 0%, var(--primary-gold-dark) 50%, var(--primary-gold) 100%);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--transition-normal);
}

.clergy-card:hover::before {
  transform: scaleX(1);
}

.clergy-card:hover {
  box-shadow: 0 12px 40px rgba(61, 40, 23, 0.15), 0 0 0 1px rgba(201, 169, 97, 0.3);
  transform: translateY(-8px);
  border-color: rgba(201, 169, 97, 0.4);
}

.clergy-card-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--spacing-lg);
}

.clergy-photo {
  width: 100%;
  max-width: 280px;
  aspect-ratio: 1;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(61, 40, 23, 0.15), 0 0 0 4px rgba(201, 169, 97, 0.1);
  position: relative;
  transition: all var(--transition-normal);
  background: linear-gradient(135deg, var(--accent-warm-dark) 0%, var(--white) 100%);
}

.clergy-card:hover .clergy-photo {
  box-shadow: 0 12px 32px rgba(61, 40, 23, 0.2), 0 0 0 4px rgba(201, 169, 97, 0.2);
  transform: scale(1.02);
}

.clergy-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform var(--transition-slow);
}

.clergy-card:hover .clergy-photo img {
  transform: scale(1.05);
}

.clergy-info {
  flex: 1;
  width: 100%;
  text-align: center;
}

.clergy-name {
  font-family: var(--font-heading);
  font-size: 2rem;
  font-weight: 700;
  color: var(--primary-deep);
  margin-bottom: var(--spacing-lg);
  padding-bottom: var(--spacing-md);
  position: relative;
  line-height: 1.3;
}

.clergy-name::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 80px;
  height: 3px;
  background: linear-gradient(90deg, transparent 0%, var(--primary-gold) 50%, transparent 100%);
  border-radius: 2px;
}

.clergy-details {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-md);
  margin-bottom: var(--spacing-lg);
  text-align: left;
}

.clergy-detail {
  padding: var(--spacing-md);
  background: rgba(255, 255, 255, 0.6);
  border-radius: var(--radius-md);
  border-left: 3px solid var(--primary-gold);
  transition: all var(--transition-fast);
  line-height: 1.7;
}

.clergy-detail:hover {
  background: rgba(255, 255, 255, 0.9);
  border-left-color: var(--primary-gold-dark);
  transform: translateX(4px);
}

.clergy-label {
  font-weight: 600;
  color: var(--primary-deep);
  display: flex;
  align-items: flex-start;
  gap: var(--spacing-xs);
  margin-bottom: var(--spacing-xs);
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.clergy-label::before {
  content: '▸';
  color: var(--primary-gold);
  font-size: 0.8rem;
  margin-top: 0.2rem;
  flex-shrink: 0;
}

.clergy-value {
  color: var(--text-light);
  display: block;
  font-size: 0.95rem;
  line-height: 1.6;
}

.clergy-value div {
  margin-top: var(--spacing-xs);
  padding-left: var(--spacing-sm);
}

.clergy-contacts {
  margin-top: var(--spacing-lg);
  padding-top: var(--spacing-lg);
  border-top: 2px solid rgba(201, 169, 97, 0.2);
  display: flex;
  flex-direction: column;
  gap: var(--spacing-md);
  width: 100%;
}

.clergy-contact {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--spacing-sm);
  padding: var(--spacing-sm) var(--spacing-md);
  background: rgba(255, 255, 255, 0.5);
  border-radius: var(--radius-md);
  transition: all var(--transition-fast);
  width: 100%;
  box-sizing: border-box;
}

.clergy-contact:hover {
  background: rgba(255, 255, 255, 0.8);
  transform: translateY(-2px);
}

.clergy-contact-icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  color: var(--primary-gold-dark);
}

.clergy-contact svg {
  width: 100%;
  height: 100%;
  stroke: currentColor;
  fill: none;
}

.clergy-contact .clergy-label {
  display: flex;
  align-items: center;
  margin: 0;
  font-size: 0.85rem;
  text-transform: none;
  letter-spacing: 0;
  color: var(--primary-deep);
}

.clergy-contact .clergy-label::before {
  display: none;
}

.clergy-contact a {
  color: var(--primary-gold-dark);
  text-decoration: none;
  transition: var(--transition-fast);
  font-weight: 500;
  font-size: 0.95rem;
  word-break: break-word;
  overflow-wrap: break-word;
  flex: 1;
  min-width: 0;
}

.clergy-contact a:hover {
  color: var(--primary-gold);
  text-decoration: underline;
}

/* Tablet styles for clergy */
@media (min-width: 768px) {
  .clergy-grid {
    grid-template-columns: repeat(auto-fit, minmax(450px, 1fr));
    gap: var(--spacing-xl);
    padding: 0;
  }

  .clergy-card {
    padding: var(--spacing-xl);
  }

  .clergy-card-content {
    flex-direction: row;
    align-items: flex-start;
    text-align: left;
  }

  .clergy-photo {
    max-width: 220px;
    flex-shrink: 0;
  }

  .clergy-info {
    text-align: left;
  }

  .clergy-name {
    font-size: 2.25rem;
    text-align: left;
    padding-left: 0;
  }

  .clergy-name::after {
    left: 0;
    transform: none;
  }

  .clergy-contacts {
    flex-direction: row;
    justify-content: flex-start;
    gap: var(--spacing-md);
  }

  .clergy-contact {
    flex: 0 1 auto;
  }
}

/* Desktop styles for clergy */
@media (min-width: 1024px) {
  .clergy-grid {
    grid-template-columns: repeat(auto-fit, minmax(550px, 1fr));
    gap: var(--spacing-xxl);
  }

  .clergy-card {
    padding: var(--spacing-xl) var(--spacing-xxl);
  }

  .clergy-photo {
    max-width: 250px;
  }

  .clergy-name {
    font-size: 2.5rem;
  }

  .clergy-details {
    gap: var(--spacing-lg);
  }

  .clergy-detail {
    padding: var(--spacing-lg);
  }

  .clergy-contacts {
    flex-direction: row;
    justify-content: flex-start;
    gap: var(--spacing-xl);
  }
}

/* ============================================
   CALENDAR WIDGET
   ============================================ */

/* Модальное окно календаря */
.calendar-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease-in-out, visibility 0.3s ease-in-out;
}

.calendar-modal.active {
  opacity: 1;
  visibility: visible;
}

.calendar-modal-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(5px);
}

.calendar-modal-content {
  position: relative;
  z-index: 10001;
  max-width: 35%;
  max-height: 95vh;
  width: auto;
  min-width: 400px;
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: var(--spacing-xl);
  box-shadow: 0 8px 48px rgba(0, 0, 0, 0.3);
  transform: scale(0.9);
  transition: transform 0.3s ease-in-out;
  overflow-y: auto;
  overflow-x: hidden;
}

.calendar-modal.active .calendar-modal-content {
  transform: scale(1);
}

.calendar-modal-close {
  position: absolute;
  top: 20px;
  right: 20px;
  background: rgba(61, 40, 23, 0.1);
  border: 2px solid rgba(61, 40, 23, 0.2);
  color: var(--primary-deep);
  width: 45px;
  height: 45px;
  border-radius: 50%;
  font-size: 30px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-normal);
  z-index: 10002;
  font-weight: 300;
}

.calendar-modal-close:hover {
  background: var(--primary-gold);
  color: var(--white);
  border-color: var(--primary-gold);
  transform: rotate(90deg) scale(1.1);
}

.calendar-modal-close:active {
  transform: rotate(90deg) scale(0.95);
}

#calendar-container {
  padding: var(--spacing-md);
  min-height: 400px;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

/* Стили для содержимого виджета календаря */
#calendar-container > * {
  max-width: 100%;
  box-sizing: border-box;
}

/* Улучшение отображения календаря внутри модального окна */
.calendar-modal-content #calendar-container {
  overflow: visible;
}

/* Стили для iframe календаря (если используется) */
#calendar-container iframe {
  width: 100% !important;
  max-width: 100% !important;
  border: none !important;
  display: block;
}

/* Стили для элементов календаря ortox */
#calendar-container [id*="ortox"],
#calendar-container [class*="ortox"],
#calendar-container [id*="calendar"],
#calendar-container [class*="calendar"] {
  width: 100% !important;
  max-width: 100% !important;
  box-sizing: border-box;
}

/* Адаптивность для модального окна календаря */
@media (min-width: 1025px) {
  .calendar-modal-content {
    max-width: 32%;
    min-width: 380px;
  }
}

@media (max-width: 1024px) {
  .calendar-modal-content {
    max-width: 60%;
    min-width: 400px;
  }
}

@media (max-width: 768px) {
  .calendar-modal-content {
    max-width: 95%;
    max-height: 95vh;
    padding: var(--spacing-lg);
    min-width: auto;
    width: 95%;
  }

  .calendar-modal-close {
    top: 15px;
    right: 15px;
    width: 40px;
    height: 40px;
    font-size: 26px;
  }

  #calendar-container {
    padding: var(--spacing-sm);
    min-height: 300px;
  }
}

@media (max-width: 480px) {
  .calendar-modal-content {
    padding: var(--spacing-md);
    border-radius: var(--radius-md);
  }

  .calendar-modal-close {
    top: 10px;
    right: 10px;
    width: 35px;
    height: 35px;
    font-size: 24px;
  }
}
