/* Common styles for Galactic Fix website */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    line-height: 1.6;
    color: #333;
    overflow-x: hidden;
}

/* Основной контейнер - одинаковый для всех страниц */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Специальный контейнер для контента без боковых отступов */
.content-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0;
}

/* Navigation styles */
.navbar {
    background-color: white;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    padding: 10px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo img {
    height: 40px;
    width: auto;
}

.nav-links {
    display: flex;
    gap: 20px;
}

.nav-links a {
    color: #333;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s;
}

.nav-links a:hover {
    color: #007AFF;
}

/* Mobile menu styles */
.mobile-menu-toggle {
    display: none;
    cursor: pointer;
    font-size: 24px;
    color: #333;
}

@media (max-width: 768px) {
    .mobile-menu-toggle {
        display: block;
    }

    .nav-links {
        position: absolute;
        top: 60px;
        left: 0;
        right: 0;
        background-color: white;
        flex-direction: column;
        padding: 20px;
        box-shadow: 0 5px 10px rgba(0, 0, 0, 0.1);
        display: none;
        z-index: 1000;
    }

    .nav-links.active {
        display: flex;
    }

    .nav-links a {
        padding: 10px 0;
        width: 100%;
        text-align: center;
    }
}

/* Hero section - консистентная ширина */
.hero {
    background: linear-gradient(135deg, #007AFF 0%, #0051D5 100%);
    color: white;
    padding: 100px 20px;
    text-align: center;
    position: relative;
    overflow: hidden;
    width: calc(100% - 40px);
    max-width: 1160px;
    margin: 30px auto;
    border-radius: 12px;
}

/* Добавляем эффект сетки для hero, как в оригинальном дизайне */
.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grid" width="10" height="10" patternUnits="userSpaceOnUse"><path d="M 10 0 L 0 0 0 10" fill="none" stroke="rgba(255,255,255,0.1)" stroke-width="0.5"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
    opacity: 0.3;
}

/* Обеспечиваем корректное отображение содержимого поверх фона */
.hero .container {
    position: relative;
    z-index: 1;
    max-width: none;
    padding: 0;
}

.hero h1 {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 20px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    color: white;
}

.hero p {
    font-size: 1.4rem;
    margin-bottom: 40px;
    opacity: 0.9;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    color: white;
}

.cta-button {
    display: inline-block;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    color: white;
    padding: 18px 40px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    border: 2px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.cta-button:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.2);
}

/* Features section */
.features {
    padding: 100px 0;
    background-color: white;
}

.features h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 60px;
    color: #333;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 40px;
    margin-top: 60px;
}

.feature-card {
    background: white;
    padding: 40px;
    border-radius: 20px;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid rgba(0, 122, 255, 0.1);
}

.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.15);
}

.feature-icon {
    font-size: 3rem;
    margin-bottom: 20px;
    display: block;
}

.feature-card h3 {
    font-size: 1.5rem;
    margin-bottom: 15px;
    color: #007AFF;
}

.feature-card p {
    color: #666;
    line-height: 1.6;
}

/* Service area */
.service-area {
    padding: 80px 0;
    background: white;
    text-align: center;
}

.service-area h2 {
    font-size: 2.5rem;
    margin-bottom: 30px;
    color: #333;
}

.location-badge {
    display: inline-block;
    background: linear-gradient(135deg, #007AFF, #0051D5);
    color: white;
    padding: 15px 30px;
    border-radius: 50px;
    font-size: 1.2rem;
    font-weight: 600;
    box-shadow: 0 8px 25px rgba(0, 122, 255, 0.3);
}

/* Phone mockup */
.phone-mockup {
    max-width: 300px;
    margin: 0 auto;
    background: #333;
    border-radius: 30px;
    padding: 20px;
    margin-top: 40px;
}

.phone-screen {
    background: linear-gradient(135deg, #007AFF, #0051D5);
    border-radius: 20px;
    padding: 40px 20px;
    color: white;
    text-align: center;
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-20px);
    }
}

.floating {
    animation: float 6s ease-in-out infinite;
}

/* Logo styles */
.logo {
    margin-bottom: 20px;
    text-align: center;
}

.logo img {
    max-width: 200px;
    height: auto;
    border-radius: 10px;
}

/* App section - консистентная ширина */
.app-section {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    text-align: center;
    padding: 100px 20px 0;
    /* Убираем нижний отступ */
    width: calc(100% - 40px);
    max-width: 1160px;
    margin: 30px auto;
    border-radius: 12px;
    overflow: hidden;
}

.app-section h2 {
    font-size: 2.5rem;
    margin-bottom: 30px;
}

.app-section p {
    font-size: 1.2rem;
    margin-bottom: 40px;
    opacity: 0.9;
}

/* App Store кнопки */
.app-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap;
    margin: 30px 0;
}

.app-store-btn {
    display: inline-block;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    color: white;
    padding: 15px 30px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.3s ease;
    border: 2px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
    min-width: 180px;
}

.app-store-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.2);
}

/* Карусель скриншотов с навигацией */
.screenshots-carousel {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 40px;
    margin-bottom: 0;
    padding-bottom: 140px;
    /* Добавляем внутренний отступ */
    position: relative;
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
}

.screenshots-viewport {
    overflow: hidden;
    width: 100%;
    max-width: 660px;
    /* 3 скриншота по 200px + отступы между ними */
    cursor: grab;
}

.screenshots-viewport:active {
    cursor: grabbing;
}

.screenshots-track {
    display: flex;
    gap: 30px;
    transition: transform 0.4s ease;
    padding: 0;
    will-change: transform;
}

.screenshots-track.dragging {
    transition: none;
    /* Убираем анимацию во время перетаскивания */
}

.screenshot-container {
    flex-shrink: 0;
    user-select: none;

    /* Предотвращаем выделение изображений */
}

.screenshot-img {
    width: 200px;
    height: auto;
    border-radius: 15px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
    border: 2px solid rgba(255, 255, 255, 0.2);
    pointer-events: none;
    /* Предотвращаем выделение изображения */
}

/* Стрелки навигации */
.carousel-arrow {
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    border: none;
    color: white;
    font-size: 28px;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 10;
    margin: 0 15px;
    position: relative;
}

.carousel-arrow:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.1);
}

.carousel-arrow.edge-indicator {
    background: rgba(255, 87, 87, 0.3);
    border: 2px solid rgba(255, 87, 87, 0.5);
}

.carousel-arrow.edge-indicator:hover {
    background: rgba(255, 87, 87, 0.4);
    border-color: rgba(255, 87, 87, 0.7);
}

.carousel-arrow.edge-indicator::after {
    content: '↻';
    position: absolute;
    top: -8px;
    right: -8px;
    background: #ff5757;
    color: white;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    font-size: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: pulse 1.5s ease-in-out infinite;
}

@keyframes pulse {

    0%,
    100% {
        transform: scale(1);
        opacity: 1;
    }

    50% {
        transform: scale(1.1);
        opacity: 0.8;
    }
}

.carousel-arrow.left {
    order: -1;
}

.carousel-arrow.right {
    order: 1;
}

/* Footer styles */
.footer {
    background: #1a1a2e;
    color: white;
    padding: 60px 0 30px;
    text-align: center;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer-section h3 {
    margin-bottom: 20px;
    color: #007AFF;
}

.footer-section p,
.footer-section a {
    color: #ccc;
    text-decoration: none;
    line-height: 1.8;
}

.footer-section a:hover {
    color: #007AFF;
}

.footer-bottom {
    border-top: 1px solid #555;
    padding-top: 20px;
    color: #999;
}

/* Support page styles - консистентная ширина */
.header {
    text-align: center;
    background: linear-gradient(135deg, #007AFF, #0051D5);
    color: white;
    padding: 60px 20px;
    border-radius: 12px;
    width: calc(100% - 40px);
    max-width: 1160px;
    margin: 30px auto 40px;
}

.header h1 {
    font-size: 2.5rem;
    margin-bottom: 15px;
}

.header p {
    font-size: 1.2rem;
    max-width: 800px;
    margin: 0 auto;
    opacity: 0.9;
}

/* Белый блок с контактной информацией - консистентная ширина */
.contact-box {
    background: white;
    padding: 40px 20px;
    border-radius: 12px;
    margin: 0 auto 60px;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    width: calc(100% - 40px);
    max-width: 1160px;
}

.contact-box h2 {
    color: #007AFF;
    margin-bottom: 30px;
    font-size: 2rem;
}

.contact-info {
    font-size: 1.2em;
    margin: 20px auto;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
    max-width: 600px;
}

/* Контейнер для страницы поддержки */
.support-container {
    width: 100%;
    margin: 0 auto;
    padding: 0;
}

/* Instructions page styles - консистентная ширина */
.instructions {
    width: 100%;
    margin: 0 auto;
    padding: 20px;
}

.step {
    margin-bottom: 60px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.step-header {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
    width: 100%;
    max-width: 900px;
}

.step-number {
    background-color: #007AFF;
    color: white;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    margin-right: 15px;
    flex-shrink: 0;
}

.step h2 {
    font-size: 1.8rem;
    color: #333;
    margin: 0;
}

.step-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    max-width: 900px;
}

.step-text {
    margin-bottom: 20px;
    font-size: 1.1rem;
    line-height: 1.6;
    width: 100%;
}

.screenshot {
    max-width: 300px;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    margin: 20px 0;
    border: 1px solid #ddd;
}

/* Responsive design */
@media (max-width: 768px) {

    .container,
    .content-container {
        padding: 0 15px;
    }

    .support-container {
        padding: 0;
        width: 100%;
        max-width: none;
    }

    .hero,
    .app-section {
        width: calc(100% - 30px);
        max-width: none;
        margin: 20px auto;
        border-radius: 8px;
    }

    /* Специфичные правила для support page на мобильных */
    .header,
    .contact-box {
        width: calc(100% - 30px) !important;
        max-width: none !important;
        margin: 20px auto !important;
        border-radius: 8px !important;
    }

    .hero h1 {
        font-size: 2.5rem;
    }

    .hero p {
        font-size: 1.2rem;
    }

    .app-section h2,
    .header h1 {
        font-size: 2rem;
    }

    .features,
    .service-area {
        padding: 60px 0;
    }

    .features h2,
    .service-area h2 {
        font-size: 2rem;
    }

    .step h2 {
        font-size: 1.5rem;
    }

    .app-buttons {
        flex-direction: column;
        align-items: center;
        gap: 15px;
    }

    .app-store-btn {
        width: 100%;
        max-width: 250px;
    }

    .screenshots-viewport {
        max-width: 170px;
        /* 1 скриншот точно */
    }

    .screenshots-track {
        gap: 20px;
    }

    .screenshot-img {
        width: 170px;
    }

    .carousel-arrow {
        width: 45px;
        height: 45px;
        font-size: 22px;
        margin: 0 8px;
    }
}

/* Кнопка "Наверх" */
.scroll-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #007AFF, #0051D5);
    color: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    font-size: 20px;
    box-shadow: 0 4px 15px rgba(0, 122, 255, 0.3);
    transition: all 0.3s ease;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
}

.scroll-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.scroll-to-top:hover {
    background: linear-gradient(135deg, #0056CC, #003D99);
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0, 122, 255, 0.4);
}

.scroll-to-top:active {
    transform: translateY(-1px);
}

/* Адаптация кнопки для мобильных */
@media (max-width: 768px) {
    .scroll-to-top {
        bottom: 20px;
        right: 20px;
        width: 45px;
        height: 45px;
        font-size: 18px;
    }
}

/* Кнопка "Наверх" */
.scroll-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #007AFF, #0051D5);
    color: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    font-size: 20px;
    box-shadow: 0 4px 15px rgba(0, 122, 255, 0.3);
    transition: all 0.3s ease;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
}

.scroll-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.scroll-to-top:hover {
    background: linear-gradient(135deg, #0056CC, #003D99);
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0, 122, 255, 0.4);
}

.scroll-to-top:active {
    transform: translateY(-1px);
}

/* Адаптация для мобильных */
@media (max-width: 768px) {
    .scroll-to-top {
        bottom: 20px;
        right: 20px;
        width: 45px;
        height: 45px;
        font-size: 18px;
    }
}



/* Убираем черную полосу внизу скриншотов */
.screenshot-img {
    display: block;
    border-radius: 15px;
    /* Скругляем углы изображения */
    border-bottom: none;
    /* Убираем нижнюю границу */
}

/* Стили для кнопок загрузки в hero секции */
.hero-download-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
    align-items: center;
    margin: 30px 0 20px 0;
    flex-wrap: wrap;
}

.download-btn {
    display: inline-flex;
    align-items: center;
    padding: 12px 20px;
    background: linear-gradient(135deg, #000000, #333333);
    color: white;
    text-decoration: none;
    border-radius: 12px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    min-width: 160px;
    justify-content: center;
}

.download-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
    background: linear-gradient(135deg, #333333, #555555);
}

.download-text {
    display: flex;
    flex-direction: column;
    align-items: center;
    line-height: 1.2;
}

.download-text small {
    font-size: 12px;
    opacity: 0.8;
}

.download-text strong {
    font-size: 16px;
    font-weight: 600;
}

.ios-btn {
    background: linear-gradient(135deg, #007AFF, #0051D5) !important;
}

.ios-btn:hover {
    background: linear-gradient(135deg, #0051D5, #003BB5) !important;
}

.android-btn {
    background: linear-gradient(135deg, #34A853, #137333) !important;
}

.android-btn:hover {
    background: linear-gradient(135deg, #137333, #0F5132) !important;
}

/* Адаптация для мобильных устройств */
@media (max-width: 768px) {
    .hero-download-buttons {
        flex-direction: column;
        gap: 10px;
    }

    .download-btn {
        width: 100%;
        max-width: 250px;
    }
}

/* Улучшаем существующие кнопки в app-section */
.app-store-btn {
    display: inline-block;
    padding: 15px 30px;
    margin: 0 10px 10px 0;
    background: linear-gradient(135deg, #007AFF, #0051D5);
    color: white;
    text-decoration: none;
    border-radius: 12px;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 122, 255, 0.3);
}

.app-store-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 122, 255, 0.4);
    background: linear-gradient(135deg, #0051D5, #003BB5);
}

.app-store-btn:nth-child(2) {
    background: linear-gradient(135deg, #34A853, #137333);
    box-shadow: 0 4px 15px rgba(52, 168, 83, 0.3);
}

.app-store-btn:nth-child(2):hover {
    background: linear-gradient(135deg, #137333, #0F5132);
    box-shadow: 0 6px 20px rgba(52, 168, 83, 0.4);
}