/* Дополнительные мобильные улучшения для property/view.php */

/* Улучшения для touch-устройств */
@media (hover: none) and (pointer: coarse) {
    /* Убираем hover эффекты на touch-устройствах */
    .language-btn:hover,
    .btn:hover,
    .detail-item:hover,
    .amenity-item:hover,
    .contact-button:hover,
    .gradient-button:hover,
    .book-button:hover {
        transform: none;
        box-shadow: none;
    }
    
    /* Добавляем активные состояния для touch */
    .language-btn:active,
    .btn:active,
    .detail-item:active,
    .amenity-item:active,
    .contact-button:active,
    .gradient-button:active,
    .book-button:active {
        transform: scale(0.98);
        transition: transform 0.1s ease;
    }
}

/* Улучшения для ландшафтной ориентации на мобильных */
@media (max-width: 768px) and (orientation: landscape) {
    .property-container {
        margin-top: 40px;
    }
    
    .mainSwiper {
        height: 60vh; /* Меньше высота для ландшафтной ориентации */
        border-radius: 0 !important;
        border: none !important;
        box-shadow: none !important;
    }
    
    .thumbSwiper {
        height: 50px;
        border-radius: 0 !important;
        border: none !important;
    }
    
    .thumbSwiper .swiper-slide {
        width: 50px;
        height: 50px;
        border-radius: 0 !important;
        border: none !important;
    }
    
    .thumbSwiper .swiper-slide-thumb-active {
        border: none !important;
        opacity: 1;
    }
    
    .property-info h1 {
        font-size: 20px;
        margin-bottom: 8px;
    }
    
    .price {
        font-size: 20px;
        margin-bottom: 12px;
    }
    
    .book-button {
        padding: 10px 16px;
        font-size: 14px;
        margin-top: 12px;
    }
    
    /* Скрываем рейтинг и отзывы в ландшафтной ориентации */
    .property-rating-overlay {
        display: none !important;
    }
    
    .status.available {
        display: none !important;
    }
    
    .gallery-controls {
        display: none !important;
    }
    
    /* Убираем отступы у галереи */
    .property-gallery-wrapper {
        margin: 0 -10px 15px -10px;
    }
    
    .property-gallery {
        margin-bottom: 0;
        border-radius: 0;
        background: transparent;
        backdrop-filter: none;
        border: none;
        padding: 0;
    }
}

/* Улучшения для очень высоких экранов (iPhone SE и подобные) */
@media (max-width: 375px) {
    body {
        padding: 6px;
        font-size: 12px;
    }
    
    .container {
        padding: 6px;
    }
    
    .glass-card {
        padding: 10px;
        border-radius: 8px;
        margin-bottom: 12px;
    }
    
    .property-info h1 {
        font-size: 18px;
        margin-bottom: 6px;
    }
    
    .location {
        font-size: 12px;
        margin-bottom: 8px;
    }
    
    .price {
        font-size: 20px;
        margin-bottom: 12px;
    }
    
    .price .amount {
        font-size: 20px;
    }
    
    .price .currency {
        font-size: 14px;
    }
    
    .book-button {
        padding: 10px 14px;
        font-size: 13px;
        margin-top: 12px;
    }
    
    .mainSwiper {
        height: 80vh; /* Практически весь экран для очень маленьких устройств */
        border-radius: 0 !important;
        border: none !important;
        box-shadow: none !important;
    }
    
    .thumbSwiper {
        height: 60px;
        margin-top: 6px;
        border-radius: 0 !important;
        border: none !important;
    }
    
    .thumbSwiper .swiper-slide {
        width: 60px;
        height: 60px;
        border-radius: 0 !important;
        border: none !important;
    }
    
    .thumbSwiper .swiper-slide-thumb-active {
        border: none !important;
        opacity: 1;
    }
    
    /* Скрываем рейтинг и отзывы на очень маленьких экранах */
    .property-rating-overlay {
        display: none !important;
    }
    
    .status.available {
        display: none !important;
    }
    
    .gallery-controls {
        display: none !important;
    }
    
    /* Убираем отступы у галереи */
    .property-gallery-wrapper {
        margin: 0 -6px 12px -6px;
    }
    
    .property-gallery {
        margin-bottom: 0;
        border-radius: 0;
        background: transparent;
        backdrop-filter: none;
        border: none;
        padding: 0;
    }
    
    .detail-item, .amenity-item {
        padding: 8px;
        gap: 5px;
    }
    
    .detail-item i, .amenity-item i {
        font-size: 12px;
    }
    
    .detail-item .label {
        font-size: 10px;
    }
    
    .detail-item .value {
        font-size: 12px;
    }
    
    .detail-item span, .amenity-item span {
        font-size: 11px;
    }
    
    .property-description h2 {
        font-size: 16px;
        margin-bottom: 8px;
    }
    
    .description-content {
        font-size: 12px;
        line-height: 1.3;
    }
    
    .contact-info {
        padding: 12px;
        margin-top: 12px;
    }
    
    .phone {
        font-size: 12px;
        gap: 8px;
        margin-bottom: 8px;
    }
    
    .phone i {
        font-size: 14px;
    }
    
    /* Модальные окна для очень маленьких экранов */
    .modal {
        padding: 3px;
    }
    
    .modal-content {
        padding: 12px;
        border-radius: 8px;
    }
    
    .modal-header {
        padding: 10px 12px;
        margin: -12px -12px 12px -12px;
        border-radius: 8px 8px 0 0;
    }
    
    .modal-header h2 {
        font-size: 14px;
    }
    
    .modal-footer {
        padding: 10px 12px;
        margin: 12px -12px -12px -12px;
        border-radius: 0 0 8px 8px;
    }
    
    .modal-footer .gradient-button {
        padding: 8px 14px;
        font-size: 12px;
    }
    
    .form-group {
        margin-bottom: 10px;
    }
    
    .form-group label {
        font-size: 11px;
        margin-bottom: 4px;
    }
    
    .input-with-icon input,
    .input-with-icon select,
    .input-with-icon textarea {
        padding: 6px 8px 6px 30px;
        font-size: 12px;
        border-radius: 4px;
    }
    
    .input-with-icon textarea {
        padding-left: 8px;
        min-height: 60px;
    }
    
    .auth-buttons .gradient-button {
        padding: 8px 14px;
        font-size: 12px;
    }
    
    .modal-content p {
        font-size: 12px;
        margin-bottom: 10px;
    }
    
    .close {
        top: 10px;
        right: 10px;
        width: 24px;
        height: 24px;
        font-size: 14px;
    }
    
    .contact-buttons {
        gap: 6px;
        margin-top: 10px;
    }
    
    .contact-button {
        padding: 8px 12px;
        font-size: 11px;
        gap: 5px;
    }
    
    .btn-lg {
        padding: 8px 12px !important;
        font-size: 12px !important;
        border-radius: 8px !important;
    }
    
    .description-accordion.collapsed {
        max-height: 3.2em;
    }
    
    .desc-toggle-btn {
        padding: 5px 12px;
        font-size: 11px;
        margin-top: 6px;
    }
    
    .owner-info-block {
        margin-bottom: 12px;
    }
    
    .owner-info-block img,
    .owner-info-block span {
        width: 36px !important;
        height: 36px !important;
        font-size: 1.3em !important;
    }
    
    .owner-info-block span[style*="font-size"] {
        font-size: 0.9em !important;
    }
}

/* Улучшения для планшетов в портретной ориентации */
@media (min-width: 481px) and (max-width: 768px) {
    .property-info h1 {
        font-size: 24px;
    }
    
    .price {
        font-size: 26px;
    }
    
    .book-button {
        font-size: 17px;
    }
    
    .mainSwiper {
        height: 280px;
    }
    
    .thumbSwiper {
        height: 85px;
    }
    
    .thumbSwiper .swiper-slide {
        width: 85px;
        height: 85px;
    }
    
    .details-grid, .amenities-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
    
    .contact-buttons {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Улучшения для планшетов в ландшафтной ориентации */
@media (min-width: 769px) and (max-width: 1024px) and (orientation: landscape) {
    .property-container {
        margin-top: 50px;
    }
    
    .mainSwiper {
        height: 220px;
    }
    
    .thumbSwiper {
        height: 70px;
    }
    
    .thumbSwiper .swiper-slide {
        width: 70px;
        height: 70px;
    }
}

/* Улучшения для устройств с высоким DPI */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    .glass-card {
        border-width: 0.5px;
    }
    
    .modal-content {
        border-width: 0.5px;
    }
    
    .input-with-icon input,
    .input-with-icon select,
    .input-with-icon textarea {
        border-width: 0.5px;
    }
}

/* Улучшения для устройств с поддержкой темной темы */
@media (prefers-color-scheme: dark) {
    .glass-card {
        background: rgba(15, 21, 36, 0.98);
    }
    
    .modal-content {
        background: rgba(15, 21, 36, 0.98);
    }
}

/* Улучшения для устройств с поддержкой reduced motion */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    .book-button {
        animation: none;
    }
    
    .gradient-button:hover {
        transform: none;
    }
}

/* Улучшения для устройств с большими экранами (но не десктоп) */
@media (min-width: 1025px) and (max-width: 1366px) {
    .container {
        max-width: 1000px;
    }
    
    .mainSwiper {
        height: 350px;
    }
    
    .thumbSwiper {
        height: 90px;
    }
    
    .thumbSwiper .swiper-slide {
        width: 90px;
        height: 90px;
    }
}

/* Улучшения для устройств с очень большими экранами */
@media (min-width: 1367px) {
    .container {
        max-width: 1400px;
    }
    
    .mainSwiper {
        height: 400px;
    }
    
    .thumbSwiper {
        height: 100px;
    }
    
    .thumbSwiper .swiper-slide {
        width: 100px;
        height: 100px;
    }
    
    .property-info h1 {
        font-size: 36px;
    }
    
    .price {
        font-size: 32px;
    }
    
    .book-button {
        font-size: 20px;
        padding: 20px 35px;
    }
} 