/* VPSRox — terms of service page */

/* ── Hero (centered) ── */

.tos-hero {
    padding: 72px 0 48px;
    text-align: center;
}

.tos-crumb {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: var(--text-muted);
    margin-bottom: 28px;
}

.tos-crumb a {
    color: var(--text-secondary);
    transition: color 0.2s;
}

.tos-crumb a:hover { color: var(--bg-card); }

.tos-crumb-current { color: var(--text-main); font-weight: 600; }

.tos-hero h1 {
    font-size: 44px;
    font-weight: 800;
    letter-spacing: -1.1px;
    line-height: 1.15;
    color: var(--text-main);
    max-width: 760px;
    margin: 0 auto 20px;
}

.tos-hero-lead {
    font-size: 18px;
    color: var(--text-secondary);
    line-height: 1.65;
    max-width: 640px;
    margin: 0 auto 28px;
}

.tos-meta-chips {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px;
}

.tos-meta-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 12px;
    background: var(--bg-white);
    border: 1px solid var(--border-light);
    border-radius: 9999px;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-secondary);
    line-height: 1.35;
}

.tos-meta-chip svg { flex-shrink: 0; color: var(--text-muted); }

.tos-meta-chip a {
    color: var(--bg-card);
    text-decoration: underline;
    text-underline-offset: 2px;
}

/* ── Quick jump strip ── */

.tos-jump-strip {
    padding: 0 0 40px;
}

.tos-jump-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
}

.tos-jump-card {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 20px 22px;
    background: var(--bg-white);
    border: 1px solid var(--border-light);
    border-radius: 18px;
    text-align: left;
    transition: border-color 0.25s, transform 0.2s, box-shadow 0.25s;
}

.tos-jump-card:hover {
    border-color: rgba(42, 211, 135, 0.45);
    transform: translateY(-2px);
    box-shadow: 0 12px 28px rgba(15, 42, 29, 0.06);
}

.tos-jump-label {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    color: var(--accent-green);
}

.tos-jump-title {
    font-size: 16px;
    font-weight: 700;
    color: var(--text-main);
    margin: 0;
}

.tos-jump-desc {
    font-size: 13px;
    color: var(--text-muted);
    line-height: 1.45;
    margin: 0;
}

/* ── Main docs area ── */

.tos-docs-wrap {
    padding: 48px 0 100px;
    background: var(--bg-white);
    border-top: 1px solid var(--border-light);
}

.tos-docs-layout {
    display: grid;
    grid-template-columns: 1fr 220px;
    gap: 56px;
    align-items: start;
    margin-bottom: 64px;
    min-width: 0;
}

.tos-content { min-width: 0; }

.tos-sidebar {
    position: sticky;
    top: 96px;
    order: 2;
    min-width: 0;
}

.tos-sidebar-title {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 16px;
}

.tos-nav {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.tos-nav-link {
    display: block;
    padding: 10px 14px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-secondary);
    border-left: 3px solid transparent;
    transition: background 0.2s, color 0.2s, border-color 0.2s;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.tos-nav-link:hover {
    background: var(--bg-main);
    color: var(--text-main);
}

.tos-nav-link.is-active {
    background: rgba(42, 211, 135, 0.1);
    color: var(--bg-card);
    border-left-color: var(--accent-green);
    font-weight: 600;
}

/* ── Article sections ── */

.tos-section {
    margin-bottom: 56px;
    scroll-margin-top: 100px;
}

.tos-section:last-child { margin-bottom: 0; }

.tos-section h2 {
    font-size: 26px;
    font-weight: 800;
    color: var(--text-main);
    margin-bottom: 16px;
    letter-spacing: -0.5px;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--bg-main);
}

.tos-section h3 {
    font-size: 17px;
    font-weight: 700;
    color: var(--text-main);
    margin: 24px 0 10px;
}

.tos-section p {
    font-size: 15px;
    color: var(--text-secondary);
    line-height: 1.75;
    margin-bottom: 14px;
}

.tos-section p:last-child { margin-bottom: 0; }

.tos-section a {
    color: var(--bg-card);
    font-weight: 600;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.tos-list {
    margin: 14px 0;
    padding-left: 22px;
    list-style: disc;
}

.tos-list li {
    font-size: 15px;
    color: var(--text-secondary);
    line-height: 1.75;
    margin-bottom: 8px;
}

.tos-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 20px 0;
}

.tos-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    border-radius: 9999px;
    background: var(--bg-main);
    border: 1px solid var(--border-light);
    font-size: 14px;
    font-weight: 600;
    color: var(--text-main);
}

.tos-pill span {
    font-size: 12px;
    font-weight: 500;
    color: var(--text-muted);
}

.tos-prohibited {
    margin: 20px 0;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px 20px;
    padding: 20px 22px;
    background: rgba(220, 38, 38, 0.04);
    border: 1px solid rgba(220, 38, 38, 0.15);
    border-radius: 16px;
}

.tos-prohibited li {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.55;
    list-style: none;
}

.tos-prohibited li::before {
    content: '×';
    color: #dc2626;
    font-weight: 700;
    margin-right: 8px;
}

.tos-callout {
    display: flex;
    gap: 14px;
    padding: 18px 20px;
    border-radius: 14px;
    margin: 20px 0;
    font-size: 14px;
    line-height: 1.65;
}

.tos-callout svg { flex-shrink: 0; margin-top: 2px; }

.tos-callout p {
    margin: 0;
    font-size: 14px;
}

.tos-callout--warn {
    background: rgba(234, 179, 8, 0.12);
    border: 1px solid rgba(234, 179, 8, 0.3);
    color: #854d0e;
}

.tos-callout--info {
    background: rgba(42, 211, 135, 0.1);
    border: 1px solid rgba(42, 211, 135, 0.25);
    color: #166534;
}

.tos-contact-list {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
    margin-top: 16px;
}

.tos-contact-item {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 20px;
    background: var(--bg-main);
    border-radius: 16px;
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.6;
}

.tos-contact-item svg {
    color: var(--bg-card);
}

.tos-contact-item strong {
    display: block;
    color: var(--text-main);
    font-size: 15px;
    margin-bottom: 4px;
}

.tos-contact-item a {
    color: var(--bg-card);
    font-weight: 600;
    text-decoration: underline;
    text-underline-offset: 2px;
}

/* ── Footer CTA inside docs wrap ── */

.tos-footer-panel {
    background: var(--bg-card);
    color: var(--text-light);
    border-radius: 24px;
    padding: 48px;
    text-align: center;
    box-sizing: border-box;
    max-width: 100%;
    overflow: hidden;
}

.tos-footer-panel h2 {
    font-size: 28px;
    font-weight: 800;
    margin-bottom: 12px;
    letter-spacing: -0.5px;
}

.tos-footer-panel p {
    font-size: 16px;
    color: var(--text-light-secondary);
    margin-bottom: 28px;
    max-width: 520px;
    margin-left: auto;
    margin-right: auto;
}

.tos-footer-actions {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
    width: 100%;
    max-width: 100%;
}

.tos-footer-actions .btn {
    box-sizing: border-box;
    max-width: 100%;
    min-width: 0;
    text-align: center;
}

.tos-footer-actions .btn-secondary {
    border-color: rgba(255, 255, 255, 0.25);
    color: var(--text-light);
}

.tos-footer-actions .btn-secondary:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.4);
}

.tos-footer-actions .btn-primary {
    background: #ffffff;
    color: var(--bg-card);
    border-color: #ffffff;
}

.tos-footer-actions .btn-primary:hover {
    background: rgba(255, 255, 255, 0.92);
    color: var(--bg-card);
    transform: none;
}

/* ── Responsive ── */

@media (max-width: 1024px) {
    .tos-jump-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .tos-contact-list {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 960px) {
    .tos-jump-strip {
        display: none;
    }

    .tos-docs-wrap {
        padding-top: 28px;
    }

    .tos-docs-layout {
        grid-template-columns: 1fr;
        gap: 0;
        min-width: 0;
    }

    .tos-sidebar {
        position: sticky;
        top: var(--tos-sticky-top, 64px);
        z-index: 90;
        order: -1;
        box-sizing: border-box;
        width: 100%;
        min-width: 0;
        max-width: 100%;
        margin: 0 0 16px;
        padding: 0;
        background: rgba(247, 246, 242, 0.96);
        backdrop-filter: blur(12px);
        -webkit-backdrop-filter: blur(12px);
        border-bottom: 1px solid var(--border-light);
        overflow: hidden;
    }

    .tos-sidebar::after {
        content: '';
        position: absolute;
        top: 0;
        right: 0;
        bottom: 0;
        width: 32px;
        background: linear-gradient(to right, rgba(247, 246, 242, 0), rgba(247, 246, 242, 0.96));
        pointer-events: none;
    }

    .tos-sidebar-title {
        display: none;
    }

    .tos-nav {
        display: flex;
        flex-direction: row;
        flex-wrap: nowrap;
        align-items: center;
        gap: 6px;
        width: 100%;
        min-width: 0;
        max-width: 100%;
        margin: 0;
        padding: 10px 0 8px;
        overflow-x: auto;
        overflow-y: hidden;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        scroll-snap-type: x proximity;
        scroll-padding-inline: 4px;
    }

    .tos-nav::-webkit-scrollbar {
        display: none;
    }

    .tos-nav-link {
        display: inline-flex;
        align-items: center;
        flex: 0 0 auto;
        width: auto;
        max-width: none;
        white-space: nowrap;
        overflow-wrap: normal;
        word-break: normal;
        border-left: none;
        border-radius: 9999px;
        padding: 8px 16px;
        font-size: 14px;
        font-weight: 600;
        line-height: 1.2;
        color: var(--text-secondary);
        background: transparent;
        border: 1px solid transparent;
        scroll-snap-align: start;
        transition: background 0.2s, color 0.2s, border-color 0.2s;
    }

    .tos-nav-link:hover {
        background: var(--bg-white);
        color: var(--text-main);
    }

    .tos-nav-link.is-active {
        background: var(--bg-card);
        color: var(--text-light);
        border-color: var(--bg-card);
        font-weight: 600;
    }

    .tos-prohibited {
        grid-template-columns: 1fr;
    }

    .tos-section[id] {
        scroll-margin-top: calc(var(--tos-sticky-top, 64px) + var(--tos-nav-h, 48px) + 16px);
    }

    .tos-footer-panel {
        position: relative;
        z-index: 100;
        border-radius: 16px;
        padding: 28px 20px 32px;
    }

    .tos-footer-panel p {
        margin-bottom: 20px;
    }

    .tos-footer-panel h2 {
        font-size: 22px;
    }

    .tos-footer-actions {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }

    .tos-footer-actions .btn {
        display: flex;
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
        padding: 12px 16px;
    }

    .tos-hero h1 { font-size: 32px; }
}

@media (max-width: 768px) {
    .tos-hero {
        padding: 40px 0 28px;
        text-align: left;
    }

    .tos-crumb {
        margin-bottom: 20px;
    }

    .tos-hero h1 {
        font-size: 28px;
        letter-spacing: -0.6px;
        margin-left: 0;
        margin-right: 0;
    }

    .tos-hero-lead {
        font-size: 16px;
        margin-left: 0;
        margin-right: 0;
    }

    .tos-meta-chips {
        justify-content: flex-start;
        gap: 6px;
    }

    .tos-meta-chip {
        width: fit-content;
        max-width: 100%;
        font-size: 12px;
        padding: 6px 10px;
        gap: 5px;
    }

    .tos-pills {
        flex-direction: column;
        align-items: center;
        gap: 8px;
        margin: 16px 0;
    }

    .tos-pill {
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 4px;
        width: fit-content;
        max-width: 100%;
        box-sizing: border-box;
        padding: 12px 14px;
        border-radius: 14px;
        font-size: 13px;
    }

    .tos-pill span {
        font-size: 12px;
        line-height: 1.45;
    }

    .tos-section {
        margin-bottom: 40px;
    }

    .tos-section h2 {
        font-size: 22px;
    }

    .tos-section h3 {
        font-size: 16px;
    }

    .tos-docs-wrap {
        padding-bottom: 64px;
    }

    .tos-prohibited {
        padding: 16px;
    }

    .tos-callout {
        flex-direction: column;
        gap: 10px;
        padding: 14px 16px;
    }

    .tos-contact-item {
        align-items: center;
        text-align: center;
        padding: 16px;
    }
}

@media (max-width: 600px) {
    .tos-jump-grid { grid-template-columns: 1fr; }
}

@media (max-width: 480px) {
    .tos-hero h1 {
        font-size: 24px;
    }

    .tos-hero-lead {
        font-size: 15px;
    }
}
