/* CSS Variables for Telegram WebApp header offset */
:root {
  /* Telegram header height (back button + title) */
  --tg-header-height: 0px;
  /* Combined safe top: Telegram header + device safe area (notch) */
  --safe-top: calc(var(--tg-header-height) + env(safe-area-inset-top, 0px));
  /* Content padding that accounts for Telegram header */
  --content-top-padding: max(20px, var(--safe-top));
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  height: 100%;
  width: 100%;
  overflow: hidden;
  background-color: #e8e4dc; /* Darker beige background */
  -webkit-text-size-adjust: 100%;
  -webkit-tap-highlight-color: transparent;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: #e8e4dc;
  color: #2a2a2a;
  height: 100vh;
  height: 100dvh; /* Dynamic viewport height for mobile */
  width: 100vw;
  overflow: hidden;
  user-select: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  /* Handle safe area for notch/status bar */
  padding-top: env(safe-area-inset-top);
  padding-left: env(safe-area-inset-left);
  padding-right: env(safe-area-inset-right);
  /* Bottom padding handled by bottom-nav */
  padding-bottom: 0;
  /* Prevent overscroll bounce */
  overscroll-behavior: none;
  -webkit-overflow-scrolling: touch;
}

.app-container {
  height: 100vh;
  height: 100dvh; /* Dynamic viewport height for mobile */
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
  /* Account for fixed bottom navigation */
  padding-bottom: calc(50px + env(safe-area-inset-bottom));
}

/* Main Content */
.main-content {
  flex: 1;
  position: relative;
  overflow: hidden;
}

.main-content .section {
  overflow-y: auto;
}

/* Loading Screen */
.loading-screen {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: #e8e4dc;
}

.loading-spinner {
  width: 40px;
  height: 40px;
  border: 3px solid rgba(220, 38, 38, 0.3);
  border-top: 3px solid #dc2626;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin-bottom: 1rem;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.loading-text {
  color: #888;
  font-size: 0.9rem;
}

/* Profile Setup */
.profile-setup {
  position: absolute;
  inset: 0;
  padding: var(--content-top-padding, 2rem) 2rem 2rem 2rem;
  background: #e8e4dc;
  overflow-y: auto;
}

.profile-setup h2 {
  text-align: center;
  margin-bottom: 2rem;
  color: #dc2626;
}

.form-group {
  margin-bottom: 1.5rem;
}

.form-group label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 500;
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 0.8rem;
  border: 2px solid #ccc;
  border-radius: 8px;
  background: #ffffff;
  color: #2a2a2a;
  font-size: 1rem;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: none;
  border-color: #dc2626;
}

/* Social Media Inputs */
.social-media-inputs {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.social-input {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.social-icon {
  width: 24px;
  height: 24px;
  min-width: 24px;
  color: #888;
  transition: color 0.2s ease;
}

.social-input:hover .social-icon {
  color: #555;
}

.social-input:focus-within .social-icon {
  color: #dc2626;
}

.social-input input {
  flex: 1;
  padding: 0.8rem;
  border: 2px solid #ccc;
  border-radius: 8px;
  background: #ffffff;
  color: #2a2a2a;
  font-size: 1rem;
}

.social-input input:focus {
  outline: none;
  border-color: #dc2626;
}

.radio-group {
  display: flex;
  gap: 1rem;
}

.radio-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
}

.checkbox-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.checkbox-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  font-weight: normal;
  margin-bottom: 0;
}

.checkbox-label input[type="checkbox"] {
  width: auto;
  margin: 0;
  padding: 0;
}

.form-group small {
  display: block;
  margin-top: 0.25rem;
  color: #888;
  font-size: 0.875rem;
}

.form-group select option {
  background: #ffffff;
  color: #2a2a2a;
}

.form-group select,
.form-group select option,
.form-group select optgroup {
  -webkit-user-select: text;
  -moz-user-select: text;
  -ms-user-select: text;
  user-select: text;
  pointer-events: auto;
}

/* Card Stack */
.card-stack {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 1rem 1rem 1rem;
  perspective: 1000px;
  pointer-events: none;
}

.profile-card {
  width: 90%;
  max-width: none;
  height: 76vh;
  background: #e8e4dc;
  border-radius: 20px;
  overflow: hidden;
  position: absolute;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
  cursor: grab;
  transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  transform-origin: center center;
  backface-visibility: hidden;
  pointer-events: auto;
  will-change: transform, opacity;
  contain: layout style paint;
}

.profile-card.dragging {
  cursor: grabbing;
  transition: none;
}

.profile-card.top-card {
  z-index: 10;
  transform: scale(1) translateY(0) rotateY(0deg);
}

.profile-card.next-card {
  z-index: 9;
  transform: scale(0.95) translateY(20px);
  opacity: 0.8;
}

.profile-card.hidden-card {
  z-index: 8;
  transform: scale(0.9) translateY(40px);
  opacity: 0;
  pointer-events: none;
  visibility: hidden;
}

.profile-card.swiping-right {
  transform: translateX(100px) rotate(10deg) scale(1.02);
  opacity: 0.8;
}

.profile-card.swiping-left {
  transform: translateX(-100px) rotate(-10deg) scale(1.02);
  opacity: 0.8;
}

.profile-card.swipe-out-right {
  transform: translateX(150vw) rotate(30deg) scale(0.8);
  opacity: 0;
}

.profile-card.swipe-out-left {
  transform: translateX(-150vw) rotate(-30deg) scale(0.8);
  opacity: 0;
}

.card-image {
  width: 100%;
  height: 100%;
  background: linear-gradient(45deg, #333, #555);
  position: relative;
  overflow: hidden;
}

.card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.card-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.7));
  padding: 4rem 1.5rem 4rem;
  color: white;
}

.card-overlay h3 {
  font-size: 1.8rem;
  font-weight: 700;
  margin: 0 0 0.5rem 0;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.8);
}

.card-overlay .age {
  font-size: 1.4rem;
  font-weight: 400;
  opacity: 0.9;
  margin-left: 0.5rem;
}

.card-location {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1.1rem;
  font-weight: 500;
  background: rgba(0, 0, 0, 0.65);
  padding: 0.4rem 0.7rem;
  border-radius: 12px;
  backdrop-filter: blur(4px);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
  margin-top: 0.3rem;
  transition: all 0.2s ease;
}

.card-location .location-icon {
  flex-shrink: 0;
  width: 18px;
  height: 18px;
  filter: drop-shadow(0 0 2px rgba(255, 255, 255, 0.3));
}

.card-location span {
  line-height: 1.4;
  color: #ffffff;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
}

.card-header {
  margin-bottom: 1rem;
}

.card-name {
  font-size: 1.4rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.card-details {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  font-size: 0.9rem;
  color: #aaa;
}

.card-tag {
  background: rgba(220, 38, 38, 0.2);
  color: #dc2626;
  padding: 0.2rem 0.6rem;
  border-radius: 12px;
  font-size: 0.8rem;
}

.card-tag.native-lang {
  background: rgba(34, 197, 94, 0.2);
  color: #22c55e;
  font-weight: 600;
}

.country-tag {
  background: rgba(59, 130, 246, 0.2);
  color: #3b82f6;
  padding: 0.2rem 0.6rem;
  border-radius: 12px;
  font-size: 0.8rem;
  margin-right: 0.5rem;
}

.card-bio {
  font-size: 0.9rem;
  line-height: 1.4;
  color: #ccc;
}

/* No Cards */
.no-cards {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.no-cards-content {
  text-align: center;
  padding: 2rem;
}

.no-cards-icon {
  font-size: 4rem;
  margin-bottom: 1rem;
}

.no-cards-content h3 {
  margin-bottom: 1rem;
  color: var(--text-primary, #1f2937);
}

.no-cards-content p {
  color: var(--text-secondary, #6b7280);
  margin-bottom: 0.5rem;
  line-height: 1.5;
}

.no-cards-thanks {
  margin-top: 1rem;
  font-style: italic;
}

/* Action Buttons */
.action-buttons {
  position: fixed;
  bottom: calc(55px + env(safe-area-inset-bottom, 0px));
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 1rem;
  z-index: 110;
  pointer-events: auto;
}

.action-btn {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  border: 3px solid #2a2a2a;
  background: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.action-btn:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.3);
}

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

.action-btn svg {
  stroke: #2a2a2a;
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
  transition: all 0.2s ease;
}

/* Undo button - стрелка назад (белая с черным контуром) */
.undo-btn {
  background: #ffffff;
  border-color: #2a2a2a;
}

.undo-btn svg {
  stroke: #2a2a2a;
}

.undo-btn:hover {
  border-color: #1a1a1a;
}

.undo-btn:hover svg {
  stroke: #1a1a1a;
  stroke-width: 3;
}

/* Dislike button - крестик (красная заливка с белой иконкой) */
.dislike-btn {
  background: #d94949;
  border-color: #d94949;
}

.dislike-btn svg {
  stroke: #ffffff;
  stroke-width: 2.5;
}

.dislike-btn:hover {
  background: #c54444;
  border-color: #c54444;
  box-shadow: 0 6px 16px rgba(217, 73, 73, 0.4);
}

.dislike-btn:hover svg {
  stroke: #ffffff;
  stroke-width: 3;
}

/* Detail button - стрелка вниз (белая с черным контуром) */
.detail-btn {
  background: #ffffff;
  border-color: #2a2a2a;
}

.detail-btn svg {
  stroke: #2a2a2a;
  fill: none;
}

.detail-btn:hover {
  border-color: #1a1a1a;
}

.detail-btn:hover svg {
  stroke: #1a1a1a;
  stroke-width: 3;
}

/* Like button - сердце (красная заливка с белой иконкой) */
.like-btn {
  background: #d94949;
  border-color: #d94949;
}

.like-btn svg {
  fill: none;
  stroke: #ffffff;
  stroke-width: 2.5;
}

.like-btn:hover {
  background: #c54444;
  border-color: #c54444;
  box-shadow: 0 6px 16px rgba(217, 73, 73, 0.4);
}

.like-btn:hover svg {
  stroke: #ffffff;
  stroke-width: 3;
}

/* Skip button - стрелка вперёд (белая с черным контуром) */
.skip-btn {
  background: #ffffff;
  border-color: #2a2a2a;
}

.skip-btn svg {
  stroke: #2a2a2a;
}

.skip-btn:hover {
  border-color: #1a1a1a;
}

.skip-btn:hover svg {
  stroke: #1a1a1a;
  stroke-width: 3;
}

/* Bottom Navigation */
.bottom-nav {
  position: fixed;
  bottom: env(safe-area-inset-bottom, 0px);
  left: 0;
  right: 0;
  background: #ffffff;
  padding: 0.7rem 2rem;
  display: flex;
  justify-content: space-around;
  align-items: center;
  border-top: 1px solid #e5e5e5;
  box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.05);
  z-index: 100;
}

/* Белый фон под safe-area на iPhone */
.bottom-nav::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  height: env(safe-area-inset-bottom, 0px);
  background: #ffffff;
}

.nav-btn {
  background: none;
  border: none;
  color: #2a2a2a;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.5rem;
  transition: all 0.2s ease;
  cursor: pointer;
  position: relative;
}

.nav-btn svg {
  stroke: #2a2a2a;
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
  transition: all 0.2s ease;
}

.nav-btn:hover svg {
  stroke: #d94949;
  transform: scale(1.1);
}

.nav-btn.active svg {
  stroke: #d94949;
  stroke-width: 3;
}

.nav-btn.disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.nav-btn.disabled:hover {
  color: #2a2a2a;
}

.nav-btn.disabled:hover svg {
  stroke: #2a2a2a;
  transform: none;
}

/* Modal */
.modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.8);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

.modal-content {
  background: #e8e4dc;
  border-radius: 20px;
  padding: 2rem;
  max-width: 90%;
  max-height: 90%;
  overflow-y: auto;
}

/* Profile Detail Modal */
.profile-detail-modal {
  max-width: 100%;
  max-height: 100%;
  padding: 0;
  width: 100vw;
  height: 100vh;
  border-radius: 0;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  margin: 0;
}

.modal-header {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  padding: 1rem;
  background: transparent;
  z-index: 20;
  border-radius: 0;
}

.modal-close {
  position: absolute;
  top: calc(1rem + var(--safe-top, 0px));
  right: 1rem;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(10px);
  border: none;
  color: white;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  z-index: 30;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.modal-close:hover {
  background: rgba(220, 38, 38, 0.9);
  transform: scale(1.05);
}

.modal-close:active {
  transform: scale(0.95);
}

.modal-body {
  overflow-y: auto;
  height: 100vh;
  width: 100%;
  position: relative;
}

/* Photo Carousel in Modal */
.profile-photo-carousel {
  position: relative;
  height: 60vh;
  min-height: 400px;
  overflow: hidden;
}

.carousel-container {
  position: relative;
  width: 100%;
  height: 100%;
}

.carousel-photos {
  display: flex;
  transition: transform 0.3s ease;
  height: 100%;
}

.carousel-photo {
  min-width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.carousel-photo.no-photo {
  background: #e8e4dc;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 4rem;
  color: #666;
}

.carousel-indicators {
  position: absolute;
  top: 60px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 6px;
  z-index: 15;
}

.carousel-indicator {
  width: 24px;
  height: 3px;
  background: rgba(255, 255, 255, 0.4);
  border-radius: 2px;
  cursor: pointer;
  transition: all 0.3s ease;
  backdrop-filter: blur(2px);
}

.carousel-indicator.active {
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

.carousel-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0, 0, 0, 0.5);
  border: none;
  color: white;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  z-index: 5;
}

.carousel-nav:hover {
  background: rgba(0, 0, 0, 0.8);
}

.carousel-prev {
  left: 10px;
}

.carousel-next {
  right: 10px;
}

/* Profile Information Section */
.profile-info-section {
  padding: 1.5rem;
  background: #e8e4dc;
  min-height: 40vh;
}

.profile-detail-modal .profile-info-section {
  background: #e8e4dc;
}

.profile-header {
  margin-bottom: 1.5rem;
  text-align: center;
  padding-top: 0.5rem;
}

.profile-name {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  color: #2a2a2a;
}

.profile-age {
  font-size: 1.3rem;
  color: #555;
}

.profile-details {
  margin-bottom: 2rem;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

.detail-item {
  margin-bottom: 1.2rem;
  padding-bottom: 1.2rem;
  border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

.detail-item:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.detail-label {
  font-weight: 600;
  color: #888;
  margin-bottom: 0.6rem;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.8px;
}

.detail-value {
  color: #2a2a2a;
  font-size: 1.05rem;
  line-height: 1.6;
}

/* Social media links */
.social-media-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.social-link {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.4rem 0.7rem;
  background: #f5f5f5;
  border-radius: 8px;
  color: #2a2a2a;
  text-decoration: none;
  font-size: 0.95rem;
  transition: background 0.2s ease, transform 0.2s ease;
}

.social-link:hover {
  background: #e8e8e8;
  transform: translateY(-1px);
}

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

.social-link-instagram:hover {
  background: #fce4ec;
}

.social-link-telegram:hover {
  background: #e3f2fd;
}

.social-link-vk:hover {
  background: #e8eaf6;
}

.social-link-whatsapp:hover {
  background: #e8f5e9;
}

.social-link-facebook:hover {
  background: #e3f2fd;
}

/* Distance emphasis in detail modal */
#modalProfileCity {
  font-weight: 500;
  font-size: 1.1rem;
}

/* Modal Action Buttons */
.modal-actions {
  display: flex;
  justify-content: center;
  gap: 2rem;
  padding: 2rem 0 3rem;
  max-width: 600px;
  margin: 0 auto;
}

.modal-action-btn {
  width: 70px;
  height: 70px;
  border-radius: 50%;
  border: 3px solid #2a2a2a;
  background: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.modal-action-btn:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.3);
}

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

.modal-action-btn svg {
  stroke: #2a2a2a;
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
  transition: all 0.2s ease;
}

/* Modal Dislike button - красная заливка с белой иконкой */
.modal-dislike-btn {
  background: #d94949;
  border-color: #d94949;
}

.modal-dislike-btn svg {
  stroke: #ffffff;
  stroke-width: 2.5;
}

.modal-dislike-btn:hover {
  background: #c54444;
  border-color: #c54444;
  box-shadow: 0 6px 16px rgba(217, 73, 73, 0.4);
}

.modal-dislike-btn:hover svg {
  stroke: #ffffff;
  stroke-width: 3;
}

/* Modal Like button - красная заливка с белой иконкой */
.modal-like-btn {
  background: #d94949;
  border-color: #d94949;
}

.modal-like-btn svg {
  fill: none;
  stroke: #ffffff;
  stroke-width: 2.5;
}

.modal-like-btn:hover {
  background: #c54444;
  border-color: #c54444;
  box-shadow: 0 6px 16px rgba(217, 73, 73, 0.4);
}

.modal-like-btn:hover svg {
  stroke: #ffffff;
  stroke-width: 3;
}

/* ===== MATCH MODAL ===== */
.match-modal-new {
    text-align: center;
    background: #ffffff;
    max-width: 400px;
    width: 90%;
    border-radius: 20px;
    padding: 2rem 1.5rem;
    animation: modalSlideUp 0.4s ease-out;
}

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

.match-header {
    margin-bottom: 1.5rem;
}

.match-icon {
    font-size: 3.5rem;
    margin-bottom: 0.5rem;
    display: inline-block;
    animation: matchIconPulse 1.5s ease-in-out infinite;
}

@keyframes matchIconPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

.match-modal-new .match-title {
    font-size: 1.8rem;
    font-weight: 800;
    color: #d94949;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin: 0 0 0.5rem 0;
}

.match-modal-new .match-subtitle {
    font-size: 1rem;
    color: #666;
    margin: 0;
    font-weight: 500;
}

/* Match card inside modal - uses same styles as matches section */
.match-modal-new .match-card-horizontal {
    margin: 1.5rem 0;
    background: #f8f8f8;
}

.btn-continue-swiping {
    background: transparent;
    border: none;
    color: #999;
    font-weight: 500;
    padding: 1rem;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.2s ease;
    width: 100%;
}

.btn-continue-swiping:hover {
    color: #666;
}

/* Buttons */
.btn {
  padding: 0.8rem 1.5rem;
  border: none;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  flex: 1;
}

.btn-primary {
  background: linear-gradient(135deg, #dc2626, #ef4444);
  color: #ffffff;
}

.btn-primary:hover {
  background: linear-gradient(135deg, #b91c1c, #dc2626);
  transform: translateY(-2px);
}

.btn-secondary {
  background: #f5f5f5;
  color: #2a2a2a;
  border: 1px solid #ddd;
}

.btn-secondary:hover {
  background: #e8e8e8;
}

.gps-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
  padding: 0.75rem 1rem;
  background: #ffffff;
  color: #2a2a2a;
  border: 1px solid rgba(217, 73, 73, 0.3);
  border-radius: 8px;
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s ease;
}

.gps-btn:hover {
  background: rgba(217, 73, 73, 0.1);
  border-color: #d94949;
  transform: translateY(-1px);
}

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

.gps-btn svg {
  stroke: #d94949;
  flex-shrink: 0;
}

.gps-btn.loading {
  opacity: 0.6;
  cursor: wait;
}

.gps-btn.success {
  background: rgba(34, 197, 94, 0.1);
  border-color: #22c55e;
  color: #22c55e;
}

.gps-btn.success svg {
  stroke: #22c55e;
}

/* City autocomplete */
.city-autocomplete-container {
  position: relative;
  width: 100%;
}

.city-suggestions {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: #ffffff;
  border: 1px solid rgba(217, 73, 73, 0.3);
  border-top: none;
  border-radius: 0 0 8px 8px;
  max-height: 200px;
  overflow-y: auto;
  z-index: 100;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.city-suggestion-item {
  padding: 12px 16px;
  cursor: pointer;
  font-size: 0.95rem;
  color: #2a2a2a;
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
  transition: background-color 0.15s ease;
}

.city-suggestion-item:last-child {
  border-bottom: none;
}

.city-suggestion-item:hover,
.city-suggestion-item.active {
  background: rgba(217, 73, 73, 0.1);
}

.city-suggestion-item.active {
  background: rgba(217, 73, 73, 0.15);
}

.city-status {
  display: block;
  font-size: 0.8rem;
  margin-top: 0.25rem;
  color: #666;
  min-height: 1.2em;
}

.city-status.auto {
  color: #22c55e;
}

.city-status.manual {
  color: #f59e0b;
}

/* Utility */
.hidden {
  display: none !important;
}

/* Section Styles */
.section {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    padding: var(--content-top-padding, 20px) 20px calc(70px + env(safe-area-inset-bottom, 0px)) 20px;
    overflow-y: auto;
}

.section-header {
    margin-bottom: 30px;
    text-align: center;
}

.section-header h2 {
    font-size: 28px;
    font-weight: 600;
    margin-bottom: 8px;
    color: #2a2a2a;
}

.section-header p {
    color: #666;
    font-size: 16px;
}

/* ===== MATCHES SECTION ===== */
.matches-count {
    font-size: 1rem;
    color: #d94949;
    font-weight: 600;
    margin: 0.5rem 0 1.5rem 0;
}

/* Matches List - Vertical list layout */
.matches-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-bottom: 20px;
    padding-top: 12px;
    padding-right: 12px;
    overflow: visible;
}

.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: #666;
}

.empty-icon {
    font-size: 48px;
    margin-bottom: 16px;
}

.empty-state h3 {
    font-size: 20px;
    margin-bottom: 8px;
    color: #2a2a2a;
}

.empty-state p {
    font-size: 14px;
    line-height: 1.5;
}

/* Match Cards - Horizontal Layout */
.match-card-horizontal {
    display: flex;
    align-items: center;
    background: #ffffff;
    border-radius: 16px;
    padding: 0.75rem;
    gap: 0.75rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    position: relative;
}

.match-card-horizontal:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
}

.match-card-horizontal .match-card-photo {
    width: 70px;
    height: 70px;
    min-width: 70px;
    border-radius: 12px;
    overflow: hidden;
    background: linear-gradient(135deg, #f5f5f5, #e0e0e0);
}

.match-card-horizontal .match-card-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.match-card-info {
    flex: 1;
    min-width: 0;
}

.match-card-info h4 {
    font-size: 1.05rem;
    font-weight: 700;
    margin: 0;
    color: #2a2a2a;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Vertical action buttons on the right */
.match-card-actions-vertical {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    flex-shrink: 0;
}

.match-card-actions-vertical .match-action-btn {
    padding: 0.5rem 0.75rem;
    border: none;
    border-radius: 10px;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    white-space: nowrap;
}

.match-card-actions-vertical .match-action-btn svg {
    width: 18px;
    height: 18px;
}

.match-card-actions-vertical .match-action-btn.btn-chat {
    background: linear-gradient(135deg, #dc2626, #ef4444);
    color: #ffffff;
    text-decoration: none;
}

.match-card-actions-vertical .match-action-btn.btn-chat:hover {
    background: linear-gradient(135deg, #b91c1c, #dc2626);
}

.match-card-actions-vertical .match-action-btn.btn-view {
    background: rgba(217, 73, 73, 0.1);
    color: #d94949;
    border: 1px solid rgba(217, 73, 73, 0.3);
}

.match-card-actions-vertical .match-action-btn.btn-view:hover {
    background: rgba(217, 73, 73, 0.2);
    border-color: #d94949;
}

/* Remove match button (X in corner) */
.match-card-remove {
    position: absolute;
    top: -10px;
    right: -10px;
    width: 24px;
    height: 24px;
    border: 2px solid #ffffff;
    border-radius: 50%;
    background: #d94949;
    color: #ffffff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 1;
    transition: all 0.2s ease;
    z-index: 10;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

.match-card-remove:hover {
    background: #c73a3a;
    transform: scale(1.15);
}

.match-card-remove:active {
    transform: scale(0.95);
}

.match-card-remove svg {
    width: 12px;
    height: 12px;
}

/* ==================== LIKES SECTION ==================== */

/* Menu Badge for Likes */
.likes-badge,
.support-badge {
    background: linear-gradient(135deg, #dc2626, #ef4444);
    color: white;
    font-size: 11px;
    font-weight: 700;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    border-radius: 9px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 4px rgba(220, 38, 38, 0.4);
    animation: badgePop 0.3s ease-out;
}

.likes-badge.hidden,
.support-badge.hidden {
    display: none !important;
}

@keyframes badgePop {
    0% { transform: scale(0); }
    50% { transform: scale(1.2); }
    100% { transform: scale(1); }
}

/* Likes Section Header */
#likesSection .section-header {
    padding: 16px;
    border-bottom: 1px solid #eee;
}

#likesSection .section-header h2 {
    margin: 0 0 4px;
    font-size: 1.3rem;
    font-weight: 700;
    color: #2a2a2a;
}

#likesSection .likes-count {
    margin: 0;
    font-size: 0.9rem;
    color: #888;
}

/* Likes Grid */
.likes-grid {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 16px;
}

/* Like Card - Horizontal Layout (similar to match-card) */
.like-card-horizontal {
    display: flex;
    align-items: center;
    background: #ffffff;
    border-radius: 16px;
    padding: 0.75rem;
    gap: 0.75rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    position: relative;
}

.like-card-horizontal:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
}

/* New like indicator - red dot */
.like-card-horizontal.is-new::before {
    content: '';
    position: absolute;
    top: 10px;
    left: 10px;
    width: 10px;
    height: 10px;
    background: #dc2626;
    border-radius: 50%;
    box-shadow: 0 0 0 3px white, 0 2px 4px rgba(220, 38, 38, 0.3);
    z-index: 5;
}

.like-card-horizontal .like-card-photo {
    width: 70px;
    height: 70px;
    min-width: 70px;
    border-radius: 12px;
    overflow: hidden;
    background: linear-gradient(135deg, #f5f5f5, #e0e0e0);
    background-size: cover;
    background-position: center;
}

.like-card-horizontal .like-card-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.like-card-info {
    flex: 1;
    min-width: 0;
}

.like-card-info h4 {
    font-size: 1.05rem;
    font-weight: 700;
    margin: 0;
    color: #2a2a2a;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.like-card-info .like-card-details {
    font-size: 0.8rem;
    color: #888;
    margin-top: 4px;
}

/* Vertical action buttons for like/match cards (unified style) */
.like-card-actions-vertical {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    flex-shrink: 0;
}

.like-card-actions-vertical .like-action-btn {
    padding: 0.5rem 0.75rem;
    border: none;
    border-radius: 10px;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    white-space: nowrap;
    text-decoration: none;
}

.like-card-actions-vertical .like-action-btn svg {
    width: 18px;
    height: 18px;
}

.like-card-actions-vertical .like-action-btn.btn-like {
    background: linear-gradient(135deg, #dc2626, #ef4444);
    color: #ffffff;
}

.like-card-actions-vertical .like-action-btn.btn-like:hover {
    background: linear-gradient(135deg, #b91c1c, #dc2626);
}

.like-card-actions-vertical .like-action-btn.btn-chat {
    background: linear-gradient(135deg, #dc2626, #ef4444);
    color: #ffffff;
    text-decoration: none;
}

.like-card-actions-vertical .like-action-btn.btn-chat:hover {
    background: linear-gradient(135deg, #b91c1c, #dc2626);
}

.like-card-actions-vertical .like-action-btn.btn-profile {
    background: rgba(217, 73, 73, 0.1);
    color: #d94949;
    border: 1px solid rgba(217, 73, 73, 0.3);
}

.like-card-actions-vertical .like-action-btn.btn-profile:hover {
    background: rgba(217, 73, 73, 0.2);
    border-color: #d94949;
}

/* Remove/Dislike button (X in corner) */
.like-card-remove {
    position: absolute;
    top: -8px;
    right: -8px;
    width: 24px;
    height: 24px;
    border: 2px solid #ffffff;
    border-radius: 50%;
    background: #9ca3af;
    color: #ffffff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 1;
    transition: all 0.2s ease;
    z-index: 10;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

.like-card-remove:hover {
    background: #d94949;
    transform: scale(1.15);
}

.like-card-remove:active {
    transform: scale(0.95);
}

.like-card-remove svg {
    width: 12px;
    height: 12px;
    stroke: currentColor;
}

/* Match card styling */
.like-card-horizontal.is-match {
    border-left: 3px solid #ec4899;
}

/* Likes Groups */
.likes-group {
    margin-bottom: 1.5rem;
}

.likes-group-title {
    font-size: 1rem;
    font-weight: 600;
    color: #374151;
    margin: 0 0 0.75rem 0;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid #e5e7eb;
}

/* Profile Section */
.profile-content {
    max-width: 400px;
    margin: 0 auto;
}

.profile-photo-section {
    text-align: center;
    margin-bottom: 30px;
}

.profile-photo {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    margin: 0 auto 16px;
    position: relative;
    background: #333;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.profile-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: none;
}

.photo-placeholder {
    font-size: 32px;
    color: #666;
}

.profile-info {
    margin-bottom: 30px;
}

.info-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid #e5e5e5;
}

.info-item:last-child {
    border-bottom: none;
}

.info-item label {
    color: #888;
    font-weight: 500;
}

.info-item span {
    color: #2a2a2a;
    text-align: right;
}

/* Settings Section */
.settings-content {
    max-width: 400px;
    margin: 0 auto;
    padding-bottom: 100px;
}

.settings-group {
    margin-bottom: 30px;
    padding: 20px;
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.settings-group h3 {
    font-size: 18px;
    margin-bottom: 16px;
    color: #2a2a2a;
}

.setting-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.setting-item:last-child {
    margin-bottom: 0;
}

.setting-item label {
    color: #2a2a2a;
    font-weight: 500;
}

.setting-item input[type="number"],
.setting-item select {
    background: #f5f5f5;
    border: 1px solid #ccc;
    border-radius: 6px;
    padding: 8px 12px;
    color: #2a2a2a;
    width: 100px;
}

.setting-item input[type="number"]:focus,
.setting-item select:focus {
    outline: none;
    border-color: #dc2626;
}

.toggle-label {
    display: flex;
    align-items: center;
    cursor: pointer;
}

/* Gender Preference Checkboxes */
.gender-preference-setting {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
}

.gender-checkboxes {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.gender-checkboxes .checkbox-label {
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    user-select: none;
}

.gender-checkboxes .checkbox-label input[type="checkbox"] {
    cursor: pointer;
}

.gender-checkboxes .checkbox-label span {
    color: #2a2a2a;
}

/* Age Range Slider */
.age-range-setting {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
}

.age-range-setting label {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

#ageRangeDisplay {
    color: #dc2626;
    font-weight: 600;
}

.age-range-slider {
    position: relative;
    height: 40px;
    width: 100%;
}

.slider-track {
    position: absolute;
    width: 100%;
    height: 4px;
    background: #ddd;
    border-radius: 2px;
    top: 50%;
    transform: translateY(-50%);
}

.slider-range {
    position: absolute;
    height: 4px;
    background: #dc2626;
    border-radius: 2px;
    top: 50%;
    transform: translateY(-50%);
}

.range-slider {
    position: absolute;
    width: 100%;
    height: 4px;
    background: transparent;
    pointer-events: none;
    -webkit-appearance: none;
    appearance: none;
    top: 50%;
    transform: translateY(-50%);
}

.range-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #dc2626;
    cursor: pointer;
    pointer-events: all;
    border: 2px solid #ffffff;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
}

.range-slider::-moz-range-thumb {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #dc2626;
    cursor: pointer;
    pointer-events: all;
    border: 2px solid #ffffff;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
}

.range-slider::-webkit-slider-thumb:hover {
    background: #b91c1c;
    transform: scale(1.1);
}

.range-slider::-moz-range-thumb:hover {
    background: #b91c1c;
    transform: scale(1.1);
}

.toggle-label input[type="checkbox"] {
    margin-right: 8px;
    transform: scale(1.2);
}

/* Section Responsive adjustments */
@media (max-width: 480px) {
    .section {
        padding: var(--content-top-padding, 16px) 16px 16px 16px;
    }
    
    .section-header h2 {
        font-size: 24px;
    }
    
    .likes-grid {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
        gap: 12px;
    }

    .matches-list {
        gap: 0.5rem;
    }

    .match-card-horizontal {
        padding: 0.5rem;
    }

    .match-card-horizontal .match-card-photo {
        width: 60px;
        height: 60px;
        min-width: 60px;
    }

    .match-card-info h4 {
        font-size: 0.95rem;
    }

    .match-card-actions-vertical .match-action-btn {
        padding: 0.4rem 0.6rem;
        font-size: 0.75rem;
    }

    .match-card-actions-vertical .match-action-btn svg {
        width: 16px;
        height: 16px;
    }
    
    .profile-photo {
        width: 100px;
        height: 100px;
    }
    
    .settings-group {
        padding: 16px;
    }
}

/* Profile View Container */
.profile-view-container {
    max-width: 500px;
    margin: 0 auto;
    background: #e8e4dc;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

/* Own Profile Actions */
.own-profile-actions {
    padding: 1.5rem 0 calc(1.5rem + env(safe-area-inset-bottom, 0px));
    display: flex;
    justify-content: center;
}

.btn-profile-settings {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem 2rem;
    font-size: 1rem;
    font-weight: 600;
    width: 100%;
    max-width: 300px;
}

.btn-profile-settings svg {
    flex-shrink: 0;
}

/* Mobile Responsiveness */
@media (max-width: 480px) {
  .action-buttons {
      bottom: calc(60px + env(safe-area-inset-bottom, 0px));
      gap: 0.8rem;
  }

  .action-btn {
      width: 55px;
      height: 55px;
      border-width: 2.5px;
  }

  .action-btn svg {
      width: 24px;
      height: 24px;
  }

  .profile-card {
      width: 95%;
      height: 76vh;
  }

  .profile-view-container {
      border-radius: 12px;
  }

  .btn-profile-settings {
      font-size: 0.9rem;
      padding: 0.8rem 1.5rem;
  }
}

/* Photo Upload Styles */
.photo-upload-section {
    margin-top: 12px;
}

.photo-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin-bottom: 16px;
    max-width: 300px;
}

.photo-slot {
    aspect-ratio: 1;
    border: 2px dashed #ccc;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    background: #f5f5f5;
    cursor: pointer;
    transition: all 0.3s ease;
}

.photo-slot:hover {
    border-color: #dc2626;
    background: rgba(220, 38, 38, 0.1);
}

.photo-slot.has-photo {
    border: 2px solid #dc2626;
    cursor: default;
}

.photo-slot.has-photo:hover {
    border-color: #dc2626;
    background: rgba(220, 38, 38, 0.05);
}

.photo-slot img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 6px;
}

.photo-slot-placeholder {
    color: #888;
    font-size: 24px;
}

.photo-slot.has-photo .photo-slot-placeholder {
    display: none;
}

.photo-remove-btn {
    position: absolute;
    top: 4px;
    right: 4px;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: rgba(220, 38, 38, 0.9);
    border: none;
    color: white;
    font-size: 14px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    z-index: 10;
}

.photo-remove-btn:hover {
    background: #dc2626;
    transform: scale(1.1);
}

.photo-loading {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #dc2626;
    font-size: 20px;
}

/* Photo drag handle for reordering */
.photo-drag-handle {
    position: absolute;
    top: 4px;
    left: 4px;
    width: 32px;
    height: 32px;
    background: rgba(0, 0, 0, 0.7);
    border-radius: 6px;
    color: white;
    font-size: 16px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    cursor: grab;
    z-index: 11;
    transition: all 0.2s ease;
    user-select: none;
    padding: 6px;
}

/* Визуальные полоски для drag handle */
.photo-drag-handle::before,
.photo-drag-handle::after {
    content: '';
    width: 14px;
    height: 2px;
    background: white;
    border-radius: 1px;
}

.photo-drag-handle:hover {
    background: rgba(220, 38, 38, 0.9);
    transform: scale(1.15);
}

.photo-drag-handle:hover::before,
.photo-drag-handle:hover::after {
    background: #fde047;
}

.photo-drag-handle:active {
    cursor: grabbing;
    transform: scale(0.95);
}

/* Star button for making photo main */
.photo-star-btn {
    position: absolute;
    top: 4px;
    right: 32px;
    width: 28px;
    height: 28px;
    border-radius: 4px;
    background: rgba(0, 0, 0, 0.6);
    border: none;
    color: #fbbf24;
    font-size: 16px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    z-index: 10;
}

.photo-star-btn:hover {
    background: rgba(0, 0, 0, 0.8);
    transform: scale(1.15);
}

.photo-star-btn.star-active {
    background: rgba(220, 38, 38, 0.9);
    color: #fde047;
    cursor: default;
}

.photo-star-btn.star-active:hover {
    transform: none;
}

/* Main photo badge */
.main-photo-badge {
    position: absolute;
    bottom: 4px;
    left: 4px;
    background: rgba(220, 38, 38, 0.95);
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 600;
    z-index: 10;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.pending-moderation-badge {
    position: absolute;
    top: 4px;
    left: 4px;
    background: rgba(255, 165, 0, 0.95);
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 600;
    z-index: 10;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* SortableJS animation classes */
.sortable-ghost {
    opacity: 0.4;
    background: rgba(220, 38, 38, 0.2);
    border: 2px dashed #dc2626 !important;
}

.sortable-chosen {
    cursor: grabbing;
    transform: scale(1.05);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
    z-index: 999;
}

.sortable-drag {
    opacity: 0.9;
    transform: rotate(2deg);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.4);
}

/* Улучшение для мобильных устройств */
@media (max-width: 768px) {
    .photo-drag-handle {
        width: 36px;
        height: 36px;
        touch-action: none;
    }

    .sortable-chosen {
        transform: scale(1.08);
    }
}

.photo-error {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #ef4444;
    font-size: 12px;
    text-align: center;
}

.photo-upload-controls {
    text-align: center;
}

#addPhotoBtn {
    margin-bottom: 8px;
    width: 100%;
    max-width: 200px;
}

/* Photo grid responsive */
@media (max-width: 480px) {
    .photo-grid {
        grid-template-columns: repeat(2, 1fr);
        max-width: 240px;
    }
}

/* Side Menu */
.side-menu {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1000;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.side-menu.active {
    pointer-events: all;
    opacity: 1;
}

.side-menu-backdrop {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(2px);
}

.side-menu-content {
    position: absolute;
    top: 0;
    left: -75%;
    width: 75%;
    max-width: 320px;
    height: 100%;
    background: #ffffff;
    box-shadow: 2px 0 20px rgba(0, 0, 0, 0.15);
    transition: left 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow-y: auto;
    display: flex;
    flex-direction: column;
}

.side-menu.active .side-menu-content {
    left: 0;
}

.side-menu-header {
    padding: calc(1rem + var(--safe-top, 0px)) 1rem 1rem 1rem;
    border-bottom: none;
}

.side-menu-profile {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    text-align: center;
}

.side-menu-avatar {
    position: relative;
    width: 70px;
    height: 70px;
    border-radius: 50%;
    overflow: hidden;
    background: #e0e0e0;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 0.3rem;
}

.side-menu-avatar #sideMenuAvatar {
    width: 100%;
    height: 100%;
    object-fit: cover;
    position: absolute;
    top: 0;
    left: 0;
    z-index: 2;
}

.avatar-placeholder {
    font-size: 24px;
    color: #999;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    position: relative;
    z-index: 1;
}

.avatar-logo {
    width: 60%;
    height: 60%;
    object-fit: contain;
    opacity: 0.3;
}

.side-menu-user-info h3 {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 2px;
    color: #1a1a1a;
}

.side-menu-user-info p {
    font-size: 0.85rem;
    color: #666;
    font-weight: 400;
}

.side-menu-items {
    padding: 0.3rem 0;
    flex: 1;
}

.side-menu-item {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    background: none;
    border: none;
    border-bottom: 1px solid #e5e5e5;
    color: #1a1a1a;
    font-size: 1.1rem;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: left;
}

.side-menu-item:hover {
    background: rgba(217, 73, 73, 0.05);
}

.side-menu-item:active {
    background: rgba(217, 73, 73, 0.1);
    transform: scale(0.98);
}

.side-menu-item span {
    font-weight: 500;
}

.side-menu-logo {
    padding: 0.5rem 1rem;
    display: flex;
    justify-content: center;
    align-items: center;
}

.tellme-logo-img {
    width: 100%;
    max-width: 150px;
    height: auto;
    object-fit: contain;
}

/* Side Menu - Large screens adaptation */
@media (min-height: 700px) {
    .side-menu-content {
        padding-bottom: env(safe-area-inset-bottom, 0px);
    }

    .side-menu-header {
        padding: calc(1.5rem + var(--safe-top, 0px)) 1rem 1rem 1rem;
    }

    .side-menu-avatar {
        width: 80px;
        height: 80px;
        margin-bottom: 0.4rem;
    }

    .side-menu-user-info h3 {
        font-size: 1.2rem;
    }

    .side-menu-user-info p {
        font-size: 0.9rem;
    }

    .side-menu-items {
        padding: 0.5rem 0;
        display: flex;
        flex-direction: column;
    }

    .side-menu-item {
        padding: 0.85rem 1.5rem;
        font-size: 1.15rem;
    }

    .side-menu-logo {
        padding: 0.5rem 1rem;
        margin-top: auto;
    }

    .tellme-logo-img {
        max-width: 160px;
    }
}

/* Side Menu - Extra large screens (iPhone Pro Max, etc.) */
@media (min-height: 850px) {
    .side-menu-header {
        padding: calc(1.5rem + var(--safe-top, 0px)) 1rem 1.25rem 1rem;
    }

    .side-menu-avatar {
        width: 90px;
        height: 90px;
        margin-bottom: 0.5rem;
    }

    .side-menu-user-info h3 {
        font-size: 1.25rem;
    }

    .side-menu-user-info p {
        font-size: 0.95rem;
    }

    .side-menu-item {
        padding: 0.9rem 1.5rem;
        font-size: 1.15rem;
    }

    .side-menu-logo {
        padding: 0.75rem 1rem;
    }
}

/* Support Section */
#supportSection {
    display: flex;
    flex-direction: column;
    height: 100%;
}

#supportSection .section-header {
    flex-shrink: 0;
    padding: 1rem;
    border-bottom: 1px solid #eee;
    text-align: left;
}

#supportSection .section-header h2 {
    margin: 0 0 4px;
    font-size: 1.3rem;
    font-weight: 700;
}

.support-status {
    font-size: 0.85rem;
    color: #64748b;
    margin-top: 0.25rem;
}

/* Support Empty State */
.support-empty-state {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 3rem 2rem;
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    border-radius: 1.5rem;
    margin: 1rem;
}

.support-empty-icon {
    font-size: 4rem;
    margin-bottom: 1.5rem;
    filter: grayscale(0.2);
    opacity: 0.9;
}

.support-empty-state h3 {
    font-size: 1.25rem;
    color: #1e293b;
    margin-bottom: 0.5rem;
    font-weight: 600;
}

.support-empty-state p {
    color: #64748b;
    font-size: 0.95rem;
    max-width: 280px;
}

/* Support Chat Container */
.support-chat-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    min-height: 200px;
}

.support-messages {
    flex: 1;
    overflow-y: auto;
    padding: 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.support-message {
    max-width: 85%;
    padding: 0.75rem 1rem;
    border-radius: 1rem;
    word-wrap: break-word;
    white-space: pre-wrap;
}

.support-message.from-user {
    align-self: flex-end;
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    color: white;
    border-bottom-right-radius: 0.25rem;
}

.support-message.from-admin {
    align-self: flex-start;
    background: #e0e7ff;
    color: #1e293b;
    border-bottom-left-radius: 0.25rem;
    border-left: 3px solid #6366f1;
}

.support-message-text {
    line-height: 1.4;
}

.support-message-time {
    font-size: 0.7rem;
    opacity: 0.7;
    margin-top: 0.25rem;
    text-align: right;
}

.support-message.from-admin .support-message-time {
    text-align: left;
}

/* Support Closed State */
.support-closed-state {
    background: #f9fafb;
    border-radius: 1rem;
    padding: 1.5rem;
    margin: 1rem;
    text-align: center;
}

.support-closed-state p {
    color: #666;
    margin-bottom: 1rem;
}

/* Support Input Area */
.support-input-area {
    flex-shrink: 0;
    padding: 1rem;
    padding-bottom: calc(1rem + env(safe-area-inset-bottom, 0px));
    border-top: 1px solid #e5e7eb;
    background: linear-gradient(180deg, #ffffff 0%, #f9fafb 100%);
}

.support-close-btn {
    width: 100%;
    margin-bottom: 0.75rem;
    font-size: 0.9rem;
    padding: 0.6rem 1rem;
    color: #dc2626;
    background: #fef2f2;
    border: 1px solid #fecaca;
    border-radius: 0.75rem;
    transition: all 0.2s ease;
}

.support-close-btn:hover {
    color: #b91c1c;
    background: #fee2e2;
    border-color: #fca5a5;
}

.support-input-wrapper {
    display: flex;
    gap: 0.5rem;
    align-items: flex-end;
}

.support-input-wrapper textarea {
    flex: 1;
    resize: none;
    border-radius: 1.25rem;
    padding: 0.75rem 1rem;
    border: 1px solid #e2e8f0;
    background: #fff;
    color: #1e293b;
    font-family: inherit;
    font-size: 0.95rem;
    line-height: 1.4;
    max-height: 120px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
    transition: all 0.2s ease;
}

.support-input-wrapper textarea:focus {
    outline: none;
    border-color: #6366f1;
    background: #fff;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.support-input-wrapper textarea::placeholder {
    color: #94a3b8;
}

.support-send-btn {
    width: 44px;
    height: 44px;
    min-width: 44px;
    max-height: 44px;
    border-radius: 50%;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    flex-grow: 0;
    align-self: flex-end;
}

.support-send-btn svg {
    width: 20px;
    height: 20px;
}

/* Support Section Mobile */
@media (max-width: 480px) {
    #supportSection .section-header {
        padding: 0.75rem 1rem;
    }

    #supportSection .section-header h2 {
        font-size: 1.1rem;
    }

    .support-empty-state {
        padding: 2rem 1.5rem;
        margin: 0.75rem;
        border-radius: 1rem;
    }

    .support-empty-icon {
        font-size: 3rem;
        margin-bottom: 1rem;
    }

    .support-empty-state h3 {
        font-size: 1.1rem;
    }

    .support-empty-state p {
        font-size: 0.9rem;
    }

    .support-messages {
        padding: 0.75rem;
        gap: 0.5rem;
    }

    .support-message {
        max-width: 90%;
        padding: 0.6rem 0.85rem;
        font-size: 0.9rem;
    }

    .support-closed-state {
        padding: 1rem;
        margin: 0.75rem;
    }

    .support-input-area {
        padding: 0.75rem;
        padding-bottom: calc(0.75rem + env(safe-area-inset-bottom, 0px));
    }

    .support-close-btn {
        padding: 0.5rem 0.75rem;
        font-size: 0.85rem;
        margin-bottom: 0.5rem;
    }

    .support-input-wrapper {
        gap: 0.4rem;
    }

    .support-input-wrapper textarea {
        padding: 0.6rem 0.85rem;
        font-size: 0.9rem;
        border-radius: 1rem;
    }

    .support-send-btn {
        width: 40px;
        height: 40px;
        min-width: 40px;
        max-height: 40px;
    }

    .support-send-btn svg {
        width: 18px;
        height: 18px;
    }
}

/* New Settings Section */
.new-settings-content {
    padding: 1rem;
    padding-bottom: calc(80px + env(safe-area-inset-bottom, 0px));
}

.new-settings-content .settings-group {
    margin-bottom: 2rem;
}

.new-settings-content .settings-group h3 {
    font-size: 1.1rem;
    margin-bottom: 1rem;
    color: #2a2a2a;
    font-weight: 600;
}

.document-links {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.document-link {
    color: #dc2626;
    text-decoration: none;
    font-weight: 500;
    padding: 0.8rem;
    background: #ffffff;
    border-radius: 8px;
    transition: all 0.2s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.document-link:hover {
    background: #f5f5f5;
    text-decoration: underline;
}

.btn-danger {
    background: #dc2626;
    color: white;
    border: none;
    padding: 0.8rem 1.5rem;
    border-radius: 8px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-danger:hover {
    background: #b91c1c;
    transform: translateY(-1px);
}

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

.btn-danger:disabled {
    background: #9ca3af;
    cursor: not-allowed;
    transform: none;
}

/* Delete Account Modal */
.delete-account-modal {
    max-width: 340px;
    text-align: center;
    padding: 2rem 1.5rem;
}

.delete-modal-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.delete-modal-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 1rem;
}

.delete-modal-text {
    font-size: 0.9rem;
    color: #4b5563;
    line-height: 1.5;
    margin-bottom: 1.5rem;
}

.delete-modal-buttons {
    display: flex;
    gap: 0.75rem;
    justify-content: center;
}

.delete-modal-buttons .btn {
    flex: 1;
    max-width: 140px;
}

/* Warning button (freeze account) */
.btn-warning {
    background: #f59e0b;
    color: white;
    border: none;
    padding: 0.8rem 1.5rem;
    border-radius: 8px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    width: 100%;
    margin-bottom: 0.75rem;
}

.btn-warning:hover {
    background: #d97706;
    transform: translateY(-1px);
}

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

/* Freeze Account Modal */
.freeze-account-modal {
    max-width: 340px;
    text-align: center;
    padding: 2rem 1.5rem;
}

.freeze-modal-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.freeze-modal-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 1rem;
}

.freeze-modal-text {
    font-size: 0.9rem;
    color: #4b5563;
    line-height: 1.5;
    margin-bottom: 1.5rem;
}

.freeze-modal-buttons {
    display: flex;
    gap: 0.75rem;
    justify-content: center;
}

.freeze-modal-buttons .btn {
    flex: 1;
    max-width: 140px;
}

/* Frozen account status banner */
.frozen-status-banner {
    background: linear-gradient(135deg, #dbeafe, #bfdbfe);
    border: 1px solid #93c5fd;
    border-radius: 12px;
    padding: 1rem;
    margin-bottom: 1rem;
    text-align: center;
}

.frozen-status-banner .frozen-icon {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.frozen-status-banner .frozen-title {
    font-size: 1rem;
    font-weight: 600;
    color: #1e40af;
    margin-bottom: 0.25rem;
}

.frozen-status-banner .frozen-description {
    font-size: 0.85rem;
    color: #3b82f6;
}

/* Document Modal */
.document-modal {
    width: 100%;
    height: 100%;
    max-width: 100%;
    max-height: 100%;
    border-radius: 0;
    display: flex;
    flex-direction: column;
    padding: 0;
}

.document-modal .modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: calc(1rem + var(--safe-top, 0px)) 1.5rem 1rem 1.5rem;
    border-bottom: 1px solid #d1cdc5;
    flex-shrink: 0;
}

.document-modal-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: #1f2937;
    margin: 0;
}

.document-modal-body {
    flex: 1;
    overflow-y: auto;
    padding: 1.5rem;
    -webkit-overflow-scrolling: touch;
}

.document-content {
    font-size: 0.9rem;
    line-height: 1.6;
    color: #374151;
}

.document-content h1 {
    font-size: 1.3rem;
    font-weight: 700;
    color: #1f2937;
    margin: 0 0 1rem 0;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid #d94949;
}

.document-content h2 {
    font-size: 1.1rem;
    font-weight: 600;
    color: #1f2937;
    margin: 1.5rem 0 0.75rem 0;
}

.document-content h3 {
    font-size: 1rem;
    font-weight: 600;
    color: #374151;
    margin: 1rem 0 0.5rem 0;
}

.document-content p,
.document-content .doc-paragraph {
    margin: 0.5rem 0;
}

.document-content ul {
    margin: 0.5rem 0;
    padding-left: 1.5rem;
}

.document-content li {
    margin: 0.25rem 0;
}

.document-content strong {
    color: #1f2937;
}

.document-content hr {
    border: none;
    border-top: 1px solid #d1cdc5;
    margin: 1.5rem 0;
}

/* Photo Carousel */
.photo-carousel {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.carousel-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.carousel-image.active {
    opacity: 1;
    pointer-events: auto;
}

.photo-indicators {
    position: absolute;
    top: 12px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 6px;
    z-index: 10;
}

.photo-indicator {
    width: 24px;
    height: 3px;
    background: rgba(255, 255, 255, 0.4);
    border-radius: 2px;
    transition: all 0.3s ease;
    backdrop-filter: blur(2px);
}

.photo-indicator.active {
    background: rgba(255, 255, 255, 0.9);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

.photo-navigation {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    z-index: 5;
}

.photo-nav-left,
.photo-nav-right {
    flex: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    outline: none;
    -webkit-tap-highlight-color: transparent;
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

/* Mobile optimizations */
@media (max-width: 768px) {
    .app-container {
        max-width: 100vw;
        /* Slightly larger padding on mobile for nav buttons */
        padding-bottom: calc(55px + env(safe-area-inset-bottom));
    }

    .main-content {
        /* Removed fixed padding - handled by app-container */
    }

    .side-menu-content {
        width: 300px;
        left: -300px;
    }

    .photo-indicator {
        width: 20px;
        height: 2px;
    }

    .photo-indicators {
        top: 10px;
        gap: 4px;
    }

    .carousel-indicator {
        width: 20px;
        height: 2px;
    }

    .carousel-indicators {
        top: 50px;
        gap: 4px;
    }
}

/* Moderation Notification */
.moderation-notification {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10000;
    max-width: 90%;
    width: 400px;
    opacity: 1;
    transition: opacity 0.3s ease;
    animation: slideDown 0.4s ease-out;
}

@keyframes slideDown {
    from {
        transform: translateX(-50%) translateY(-100px);
        opacity: 0;
    }
    to {
        transform: translateX(-50%) translateY(0);
        opacity: 1;
    }
}

.moderation-notification-content {
    background: #ffffff;
    border: 2px solid #fbbf24;
    border-radius: 16px;
    padding: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    display: flex;
    align-items: flex-start;
    gap: 15px;
    position: relative;
}

.moderation-icon {
    font-size: 32px;
    flex-shrink: 0;
}

.moderation-text {
    flex: 1;
}

.moderation-text strong {
    display: block;
    font-size: 16px;
    color: #fbbf24;
    margin-bottom: 8px;
}

.moderation-text p {
    font-size: 14px;
    color: #555;
    margin: 4px 0;
}

.moderation-hint {
    font-size: 12px !important;
    color: #888 !important;
    margin-top: 8px !important;
}

.moderation-close {
    position: absolute;
    top: 10px;
    right: 10px;
    background: transparent;
    border: none;
    color: #888;
    font-size: 20px;
    cursor: pointer;
    padding: 5px;
    line-height: 1;
    transition: color 0.2s;
}

.moderation-close:hover {
    color: #2a2a2a;
}

@media (max-width: 768px) {
    .moderation-notification {
        top: 10px;
        width: calc(100% - 20px);
        max-width: none;
    }

    .moderation-notification-content {
        padding: 15px;
        gap: 10px;
    }

    .moderation-icon {
        font-size: 24px;
    }

    .moderation-text strong {
        font-size: 14px;
    }

    .moderation-text p {
        font-size: 12px;
    }

    .moderation-hint {
        font-size: 11px !important;
    }
}

/* Moderation Status Badge */
.moderation-status-badge {
    background: #ffffff;
    backdrop-filter: blur(10px);
    border-radius: 12px;
    padding: 12px 16px;
    margin-bottom: 16px;
    border: 1px solid #e5e5e5;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.moderation-status-badge.hidden {
    display: none;
}

.moderation-status-content {
    display: flex;
    align-items: center;
    gap: 12px;
}

.moderation-status-icon {
    font-size: 24px;
    line-height: 1;
}

.moderation-status-text {
    font-size: 16px;
    font-weight: 600;
    color: #2a2a2a;
    flex: 1;
}

.moderation-status-details {
    margin-top: 8px;
    padding-left: 36px;
}

.moderation-status-details small {
    font-size: 13px;
    color: #666;
}

/* Status-specific styles */
.moderation-status-badge.status-pending {
    background: linear-gradient(135deg, rgba(251, 191, 36, 0.15) 0%, rgba(245, 158, 11, 0.15) 100%);
    border-color: rgba(251, 191, 36, 0.3);
}

.moderation-status-badge.status-pending .moderation-status-text {
    color: #fbbf24;
}

.moderation-status-badge.status-active {
    background: linear-gradient(135deg, rgba(34, 197, 94, 0.15) 0%, rgba(22, 163, 74, 0.15) 100%);
    border-color: rgba(34, 197, 94, 0.3);
}

.moderation-status-badge.status-active .moderation-status-text {
    color: #22c55e;
}

.moderation-status-badge.status-rejected {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.15) 0%, rgba(220, 38, 38, 0.15) 100%);
    border-color: rgba(239, 68, 68, 0.3);
}

.moderation-status-badge.status-rejected .moderation-status-text {
    color: #ef4444;
}

.moderation-status-badge.status-suspended {
    background: linear-gradient(135deg, rgba(107, 114, 128, 0.15) 0%, rgba(75, 85, 99, 0.15) 100%);
    border-color: rgba(107, 114, 128, 0.3);
}

.moderation-status-badge.status-suspended .moderation-status-text {
    color: #6b7280;
}

@media (max-width: 768px) {
    .moderation-status-badge {
        padding: 10px 14px;
        margin-bottom: 12px;
    }

    .moderation-status-icon {
        font-size: 20px;
    }

    .moderation-status-text {
        font-size: 14px;
    }

    .moderation-status-details {
        padding-left: 32px;
    }

    .moderation-status-details small {
        font-size: 12px;
    }
}

/* Moderation Pending Screen */
.moderation-pending-screen {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #e8e4dc;
}

.moderation-pending-content {
    text-align: center;
    padding: 2rem;
    max-width: 500px;
}

.moderation-pending-content .moderation-icon {
    font-size: 5rem;
    margin-bottom: 1.5rem;
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.7;
        transform: scale(1.1);
    }
}

.moderation-pending-content h2 {
    font-size: 1.75rem;
    margin-bottom: 1rem;
    color: #fbbf24;
}

.moderation-pending-content p {
    font-size: 1rem;
    line-height: 1.6;
    color: #555;
    margin-bottom: 0.75rem;
}

.moderation-actions {
    margin-top: 2rem;
}

.moderation-actions .btn {
    min-width: 200px;
}

@media (max-width: 768px) {
    .moderation-pending-content {
        padding: 1.5rem;
    }

    .moderation-pending-content .moderation-icon {
        font-size: 4rem;
    }

    .moderation-pending-content h2 {
        font-size: 1.5rem;
    }

    .moderation-pending-content p {
        font-size: 0.9rem;
    }

    .moderation-actions .btn {
        min-width: 150px;
    }
}

/* ===== STORIES MODAL ===== */
.stories-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: #000;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 1;
    transition: opacity 0.3s ease;
}

.stories-modal.hidden {
    display: none;
    opacity: 0;
}

.stories-container {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
}

/* Progress bars */
.stories-progress-container {
    position: absolute;
    top: calc(60px + var(--safe-top, 0px));
    left: 20px;
    right: 20px;
    display: flex;
    gap: 4px;
    z-index: 10001;
    padding: 0 10px;
}

.stories-progress-bar {
    flex: 1;
    height: 3px;
    background-color: rgba(255, 255, 255, 0.3);
    border-radius: 2px;
    overflow: hidden;
    position: relative;
}

.stories-progress-bar::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    width: 0;
    background-color: rgba(255, 255, 255, 0.9);
    transition: width 0.1s linear;
}

.stories-progress-bar.active::after {
    animation: progressBar 5s linear forwards;
}

.stories-progress-bar.completed::after {
    width: 100%;
}

@keyframes progressBar {
    from {
        width: 0;
    }
    to {
        width: 100%;
    }
}

/* Toast notifications */
@keyframes toastIn {
    from {
        opacity: 0;
        transform: translateX(-50%) translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
}

@keyframes toastOut {
    from {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
    to {
        opacity: 0;
        transform: translateX(-50%) translateY(20px);
    }
}

/* Skip button - hidden */
.stories-skip-btn {
    display: none;
}

.stories-skip-btn:hover {
    background-color: #ffffff;
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(217, 73, 73, 0.3);
}

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

.stories-skip-btn svg {
    stroke: #d94949;
    stroke-width: 2.5;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/* Stories content */
.stories-content {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    padding: 0 12px;
    box-sizing: border-box;
    overflow: hidden;
}

.stories-image {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: cover;
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    border-radius: 16px;
}

/* Navigation areas */
.stories-nav-area {
    position: absolute;
    top: 0;
    bottom: 0;
    width: 30%;
    z-index: 10000;
    cursor: pointer;
}

.stories-nav-prev {
    left: 0;
}

.stories-nav-next {
    right: 0;
}

/* Touch feedback removed - no visual feedback on tap */

/* Mobile optimizations */
@media (max-width: 768px) {
    .stories-progress-container {
        top: calc(50px + var(--safe-top, 0px));
        left: 16px;
        right: 16px;
        gap: 3px;
    }

    .stories-progress-bar {
        height: 2px;
    }

    .stories-content {
        padding: 0 8px;
    }

    .stories-image {
        border-radius: 12px;
    }
}

/* Prevent scrolling when stories are open */
body.stories-open {
    overflow: hidden;
}