/* Стили для страницы terms */
.terms-page {
    max-width: 1400px;
    margin: 0 auto;
    padding: clamp(15px, 2vw, 30px) clamp(10px, 1.5vw, 20px);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Хлебные крошки */
.breadcrumb {
    margin-bottom: 1.5rem;
    font-size: 0.9rem;
    color: #666;
}

.breadcrumb a {
    color: #e84118;
    text-decoration: none;
}

.breadcrumb a:hover {
    text-decoration: underline;
}

.breadcrumb span {
    color: #333;
    font-weight: 600;
}

/* Основной контент на всю ширину */
.terms-content-full {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    flex: 1;
}

.terms-content-full h1 {
    font-size: clamp(1.5rem, 3.5vw, 2.2rem);
    color: #2c3e50;
    margin-bottom: 1rem;
    text-align: center;
    line-height: 1.3;
    border-bottom: 2px solid #e84118;
    padding-bottom: 0.5rem;
}

.terms-intro {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    padding: 1.2rem;
    border-radius: 10px;
    margin-bottom: 2rem;
    text-align: center;
}

.terms-intro p {
    font-size: 1rem;
    line-height: 1.5;
    color: #555;
    margin: 0 0 0.5rem 0;
}

.terms-intro p:last-child {
    margin-bottom: 0;
}

/* Секция с условиями обслуживания */
.terms-policy-section {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.policy-item {
    padding: 1.5rem;
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    border-left: 4px solid #e84118;
}

.policy-item h2 {
    color: #e84118;
    font-size: 1.3rem;
    margin: 0 0 1rem 0;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid #e9ecef;
}

.policy-item h3 {
    color: #2c3e50;
    font-size: 1.1rem;
    margin: 1.5rem 0 0.5rem 0;
}

.policy-item p {
    font-size: 0.95rem;
    line-height: 1.6;
    color: #555;
    margin: 0 0 1rem 0;
}

.policy-item ul {
    margin: 1rem 0;
    padding-left: 1.5rem;
}

.policy-item li {
    font-size: 0.95rem;
    line-height: 1.6;
    color: #555;
    margin-bottom: 0.5rem;
}

.policy-item strong {
    color: #2c3e50;
    font-weight: 600;
}

.policy-item a {
    color: #e84118;
    text-decoration: none;
    font-weight: 500;
}

.policy-item a:hover {
    text-decoration: underline;
}

/* Стили для тарифных планов */
.pricing-plans {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    margin: 1.5rem 0;
}

.pricing-plan {
    padding: 1.8rem;
    border-radius: 12px;
    text-align: center;
    position: relative;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.pricing-plan:hover {
    transform: translateY(-5px);
}

/* Стили для Mini Plan */
.mini-plan {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border: 2px solid #95a5a6;
    box-shadow: 0 5px 15px rgba(149, 165, 166, 0.1);
}

.mini-plan h3 {
    color: #7f8c8d;
}

.mini-plan .price {
    color: #7f8c8d;
}

.mini-plan .price.annual {
    color: #5d6d7e;
}

/* Стили для Standard Plan */
.standard-plan {
    background: linear-gradient(135deg, #e3f2fd 0%, #bbdefb 100%);
    border: 2px solid #2196f3;
    box-shadow: 0 5px 15px rgba(33, 150, 243, 0.1);
}

.standard-plan h3 {
    color: #1565c0;
}

.standard-plan .price {
    color: #1976d2;
}

.standard-plan .price.annual {
    color: #0d47a1;
}

/* Стили для Premium Plan */
.premium-plan {
    background: linear-gradient(135deg, #fff9e6 0%, #ffeaa7 100%);
    border: 2px solid #fdcb6e;
    box-shadow: 0 8px 25px rgba(253, 203, 110, 0.3);
    position: relative;
    overflow: hidden;
}

.premium-plan:before {
    content: "RECOMMENDED";
    position: absolute;
    top: 15px;
    right: -30px;
    background: #e84118;
    color: white;
    padding: 5px 40px;
    font-size: 0.8rem;
    font-weight: 700;
    transform: rotate(45deg);
    letter-spacing: 1px;
}

.premium-plan h3 {
    color: #2c3e50;
}

.premium-plan .price {
    color: #e84118;
}

.premium-plan .price.annual {
    color: #c23616;
}

.pricing-plan h3 {
    color: #2c3e50;
    font-size: 1.5rem;
    margin: 0 0 1rem 0;
    font-weight: 700;
    line-height: 1.2;
}

.price {
    font-size: 2.2rem;
    font-weight: 700;
    margin: 0.5rem 0;
    line-height: 1;
}

.price.annual {
    font-size: 1.8rem;
    margin-top: 0.5rem;
    margin-bottom: 1rem;
}

.period {
    font-size: 1rem;
    color: #666;
    font-weight: 500;
}

.plan-description {
    font-style: italic;
    color: #666;
    margin-bottom: 1.5rem !important;
    font-size: 0.9rem;
    min-height: 2.5rem;
}

.pricing-plan ul {
    text-align: left;
    margin: 1.5rem 0 0 0;
    padding: 0;
    list-style: none;
    flex-grow: 1;
}

.pricing-plan li {
    padding: 0.5rem 0;
    border-bottom: 1px solid rgba(0,0,0,0.1);
    font-size: 0.85rem;
    position: relative;
    padding-left: 1.5rem;
    line-height: 1.3;
}

.pricing-plan li:before {
    content: "✓";
    color: #27ae60;
    font-weight: bold;
    position: absolute;
    left: 0;
}

.mini-plan li:before {
    color: #7f8c8d;
}

.standard-plan li:before {
    color: #2196f3;
}

.premium-plan li:before {
    color: #e84118;
}

.pricing-plan li:last-child {
    border-bottom: none;
}

/* Контактная информация */
.contact-info {
    background: #f8f9fa;
    padding: 1.2rem;
    border-radius: 8px;
    border-left: 3px solid #e84118;
    margin: 1.5rem 0;
}

.contact-info h3 {
    color: #e84118;
    margin: 0 0 0.8rem 0;
    font-size: 1.1rem;
}

.contact-info p {
    margin: 0.5rem 0;
    font-size: 0.95rem;
}

/* Навигация */
.page-links.terms-navigation {
    margin-top: auto;
    padding-top: 1.5rem;
    border-top: 2px solid #e9ecef;
    width: 100%;
}

.nav-buttons-container {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 1rem;
    align-items: center;
    width: 100%;
    max-width: 800px;
    margin: 0 auto;
}

.nav-button {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.7rem 1.2rem;
    border: 2px solid #e84118;
    border-radius: 6px;
    transition: all 0.3s ease;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
    text-align: center;
    min-height: 44px;
}

.prev-button {
    color: #e84118;
    background: white;
    justify-self: start;
}

.home-button {
    color: white;
    background: #e84118;
    border-color: #e84118;
    justify-self: center;
    min-width: 120px;
}

.next-button {
    color: white;
    background: #e84118;
    border-color: #e84118;
    justify-self: end;
}

.nav-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(232, 65, 24, 0.3);
}

.prev-button:hover {
    background: #e84118;
    color: white;
}

.next-button:hover {
    background: #c23616;
    border-color: #c23616;
    color: white;
}

.home-button:hover {
    background: #c23616;
    border-color: #c23616;
    color: white;
}

/* АДАПТИВНОСТЬ */

/* Планшеты в альбомной ориентации */
@media screen and (max-width: 1100px) {
    .pricing-plans {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
    }

    .premium-plan {
        grid-column: span 2;
    }

    .terms-content-full {
        max-width: 1000px;
    }
}

/* Планшеты в портретной ориентации */
@media screen and (max-width: 900px) {
    .terms-content-full {
        max-width: 100%;
    }

    .policy-item {
        padding: 1.2rem;
    }
}

/* Большие мобильные */
@media screen and (max-width: 768px) {
    .terms-content-full {
        max-width: 100%;
    }

    .policy-item {
        padding: 1rem;
    }

    .pricing-plans {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .premium-plan {
        grid-column: span 1;
    }

    .pricing-plan {
        padding: 1.5rem;
    }

    .premium-plan:before {
        top: 10px;
        right: -35px;
        font-size: 0.7rem;
        padding: 4px 35px;
    }

    /* Навигация для планшетов */
    .nav-buttons-container {
        grid-template-columns: 1fr;
        gap: 0.8rem;
        max-width: 300px;
    }

    .nav-button {
        width: 100%;
        justify-self: center;
    }
}

/* Мобильные устройства */
@media screen and (max-width: 480px) {
    .terms-page {
        padding: 10px;
    }

    .breadcrumb {
        font-size: 0.8rem;
        margin-bottom: 1rem;
    }

    .terms-content-full h1 {
        font-size: 1.4rem;
        margin-bottom: 0.8rem;
    }

    .terms-intro {
        padding: 1rem;
        margin-bottom: 1.5rem;
    }

    .terms-intro p {
        font-size: 0.9rem;
    }

    .policy-item {
        padding: 0.9rem;
    }

    .policy-item h2 {
        font-size: 1.2rem;
    }

    .policy-item p,
    .policy-item li {
        font-size: 0.9rem;
    }

    .pricing-plan {
        padding: 1.2rem;
    }

    .price {
        font-size: 1.8rem;
    }

    .price.annual {
        font-size: 1.5rem;
    }

    .pricing-plan li {
        font-size: 0.8rem;
        padding-left: 1.2rem;
    }

    .contact-info {
        padding: 1rem;
    }

    /* Навигация для мобильных */
    .terms-navigation {
        margin-top: 1.5rem;
        padding-top: 1rem;
    }

    .nav-buttons-container {
        gap: 0.6rem;
    }

    .nav-button {
        padding: 0.6rem 1rem;
        font-size: 0.85rem;
        min-height: 40px;
    }

    .home-button {
        min-width: 100px;
    }
}

/* Очень маленькие мобильные */
@media screen and (max-width: 360px) {
    .terms-content-full h1 {
        font-size: 1.2rem;
    }

    .policy-item h2 {
        font-size: 1.1rem;
    }

    .policy-item {
        padding: 0.8rem;
    }

    .pricing-plan {
        padding: 1rem;
    }

    .pricing-plan h3 {
        font-size: 1.3rem;
    }

    .price {
        font-size: 1.6rem;
    }

    .price.annual {
        font-size: 1.3rem;
    }

    .nav-button {
        padding: 0.5rem 0.8rem;
        font-size: 0.8rem;
    }
}

/* Улучшенная поддержка касаний */
@media (hover: none) and (pointer: coarse) {
    .nav-button:hover {
        transform: none;
        box-shadow: none;
    }

    .nav-button:active {
        transform: translateY(-1px);
    }

    .pricing-plan:hover {
        transform: none;
    }

    .pricing-plan:active {
        transform: translateY(-2px);
    }
}