/* ============================================
   TOS PAGE - Page Specific Styles
   ============================================ */

/* Page Background */
.tos-page-bg {
    background:
        radial-gradient(ellipse at 20% 20%, rgba(139, 0, 0, 0.12) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 80%, rgba(139, 0, 0, 0.08) 0%, transparent 50%),
        linear-gradient(180deg, #0d0d0d 0%, var(--bg-dark) 50%, #0a0a0a 100%);
    min-height: 100vh;
    padding: 60px 0;
}

/* Header */
.tos-header {
    text-align: center;
    margin-bottom: 50px;
}

.tos-header h1 {
    color: var(--text-primary);
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
}

.tos-header h1 i {
    color: var(--red-accent);
}

.tos-header .breadcrumb-custom {
    display: flex;
    justify-content: center;
    gap: 10px;
    color: var(--text-secondary);
}

.tos-header .breadcrumb-custom a {
    color: var(--red-accent);
    text-decoration: none;
    transition: color 0.3s;
}

.tos-header .breadcrumb-custom a:hover {
    color: var(--red-light);
}

/* Main Card */
.tos-card {
    background: linear-gradient(145deg, var(--bg-primary) 0%, var(--bg-secondary) 100%);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

.tos-card-header {
    background: linear-gradient(135deg, var(--red-dark) 0%, var(--red-accent) 100%);
    padding: 25px 30px;
    display: flex;
    align-items: center;
    gap: 15px;
}

.tos-card-header i {
    font-size: 1.8rem;
    color: #fff;
}

.tos-card-header h2 {
    color: #fff;
    font-size: 1.5rem;
    font-weight: 600;
    margin: 0;
}

.tos-card-body {
    padding: 40px;
}

/* Intro Text */
.tos-intro {
    color: var(--text-secondary);
    font-size: 1.1rem;
    line-height: 1.8;
    margin-bottom: 35px;
    padding-bottom: 25px;
    border-bottom: 1px solid var(--border-color);
}

.tos-intro i {
    color: var(--red-accent);
}

/* Terms List */
.tos-list {
    list-style: none;
    padding: 0;
    margin: 0;
    counter-reset: tos-counter;
}

.tos-list li {
    position: relative;
    padding: 20px 20px 20px 80px;
    margin-bottom: 15px;
    background: var(--bg-tertiary, rgba(30, 30, 30, 0.5));
    border-radius: 12px;
    border-left: 4px solid var(--red-accent);
    color: var(--text-primary);
    font-size: 1rem;
    line-height: 1.7;
    transition: all 0.3s ease;
    counter-increment: tos-counter;
}

.tos-list li::before {
    content: counter(tos-counter);
    position: absolute;
    left: 20px;
    top: 50%;
    transform: translateY(-50%);
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, var(--red-dark) 0%, var(--red-accent) 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1rem;
    color: #fff;
}

.tos-list li:hover {
    background: rgba(139, 0, 0, 0.1);
    transform: translateX(5px);
}

.tos-list li a {
    color: var(--red-accent);
    text-decoration: none;
    transition: color 0.3s;
}

.tos-list li a:hover {
    color: var(--red-light);
    text-decoration: underline;
}

/* Code tags */
.tos-list code {
    background: rgba(255, 255, 255, 0.1);
    color: var(--red-accent);
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 0.9em;
}

/* Footer */
.tos-footer {
    margin-top: 40px;
    padding-top: 30px;
    border-top: 1px solid var(--border-color);
    text-align: center;
}

.tos-footer p {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 20px;
}

.tos-footer p i {
    color: var(--red-accent);
}

.tos-footer .btn-accept {
    background: linear-gradient(135deg, var(--red-dark) 0%, var(--red-accent) 100%);
    border: none;
    color: #fff;
    padding: 15px 40px;
    border-radius: 10px;
    font-weight: 600;
    font-size: 1.1rem;
    transition: all 0.3s ease;
}

.tos-footer .btn-accept:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(220, 20, 60, 0.3);
}

.tos-footer .btn-accept i {
    margin-right: 10px;
}

/* Last updated badge */
.tos-updated {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--bg-tertiary, rgba(30, 30, 30, 0.8));
    padding: 8px 16px;
    border-radius: 20px;
    color: var(--text-secondary);
    font-size: 0.85rem;
    margin-bottom: 30px;
}

.tos-updated i {
    color: var(--red-accent);
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 768px) {
    .tos-header h1 {
        font-size: 1.8rem;
    }

    .tos-card-body {
        padding: 25px;
    }

    .tos-list li {
        padding: 15px 15px 15px 60px;
    }

    .tos-list li::before {
        width: 32px;
        height: 32px;
        font-size: 0.85rem;
        left: 12px;
    }
}

/* ============================================
   FORUM THEME OVERRIDES
   Match Image Hosting style - dark backgrounds with teal borders
   ============================================ */
body.theme-forum .tos-page-bg {
    background:
        radial-gradient(ellipse at 20% 20%, rgba(38, 198, 218, 0.08) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 80%, rgba(38, 198, 218, 0.05) 0%, transparent 50%),
        linear-gradient(180deg, #0d0d0d 0%, #0a0a0a 50%, #080808 100%) !important;
}

body.theme-forum .tos-header h1 i {
    color: #26c6da !important;
}

body.theme-forum .tos-header .breadcrumb-custom a {
    color: #26c6da !important;
}

body.theme-forum .tos-header .breadcrumb-custom a:hover {
    color: #4dd0e1 !important;
}

/* Card - EXACT same style as launcher-card on Download page */
body.theme-forum .tos-card {
    background: rgba(8, 24, 28, 0.40) !important;
    border: none !important;
    box-shadow: inset 0 2px 0 rgba(255, 255, 255, 0.10), inset 0 -2px 0 rgba(0, 0, 0, 0.70), 0 18px 44px rgba(0, 0, 0, 0.55) !important;
}

/* Card Header - subtle gradient without visible border */
body.theme-forum .tos-card-header {
    background: linear-gradient(180deg, rgba(38, 198, 218, 0.08) 0%, rgba(8, 24, 28, 0.6) 100%) !important;
    border: none !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05) !important;
}

body.theme-forum .tos-card-header i {
    color: #26c6da !important;
}

body.theme-forum .tos-card-header h2 {
    color: #fff !important;
}

/* List items - same style as download-item cards */
body.theme-forum .tos-list li {
    background: rgba(8, 24, 28, 0.34) !important;
    border: none !important;
    border-left: none !important;
    box-shadow: inset 0 2px 0 rgba(255, 255, 255, 0.08), inset 0 -2px 0 rgba(0, 0, 0, 0.70), 0 8px 20px rgba(0, 0, 0, 0.30) !important;
}

/* Number circles - same style as launcher buttons */
body.theme-forum .tos-list li::before {
    background: rgba(8, 24, 28, 0.78) !important;
    border: none !important;
    color: #fff !important;
    box-shadow: inset 0 2px 0 rgba(255, 255, 255, 0.16), inset 0 -2px 0 rgba(0, 0, 0, 0.65), 0 6px 16px rgba(0, 0, 0, 0.40) !important;
}

body.theme-forum .tos-list li:hover {
    background: rgba(15, 43, 48, 0.50) !important;
    box-shadow: inset 0 2px 0 rgba(255, 255, 255, 0.10), inset 0 -2px 0 rgba(0, 0, 0, 0.78), 0 10px 24px rgba(0, 0, 0, 0.40) !important;
}

body.theme-forum .tos-list li a {
    color: #26c6da !important;
}

body.theme-forum .tos-list li a:hover {
    color: #4dd0e1 !important;
}

body.theme-forum .tos-list code {
    background: rgba(8, 24, 28, 0.6) !important;
    color: #26c6da !important;
    border: none !important;
}

body.theme-forum .tos-intro i {
    color: #26c6da !important;
}

body.theme-forum .tos-updated {
    background: rgba(8, 24, 28, 0.60) !important;
    border: none !important;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08), inset 0 -1px 0 rgba(0, 0, 0, 0.50) !important;
}

body.theme-forum .tos-updated i {
    color: #26c6da !important;
}

body.theme-forum .tos-footer p i {
    color: #26c6da !important;
}

/* Accept button - match Download page launcher buttons */
body.theme-forum .tos-footer .btn-accept {
    background: rgba(8, 24, 28, 0.78) !important;
    border: none !important;
    color: #fff !important;
    box-shadow: inset 0 2px 0 rgba(255, 255, 255, 0.16), inset 0 -2px 0 rgba(0, 0, 0, 0.65), 0 14px 32px rgba(0, 0, 0, 0.44) !important;
}

body.theme-forum .tos-footer .btn-accept:hover {
    background: rgba(15, 43, 48, 0.88) !important;
    box-shadow: inset 0 2px 0 rgba(255, 255, 255, 0.18), inset 0 -2px 0 rgba(0, 0, 0, 0.72), 0 18px 40px rgba(0, 0, 0, 0.52) !important;
    transform: none !important;
}