/* Subscription Preferences Page Styles */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue', sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #fff;
}

.subscription-preferences-container {
    max-width: 1170px;
    margin: 0 auto;
    padding: 0 20px 40px 20px;
    background-color: #fff;
    min-height: 100vh;
}

/* Header Styles */
.preferences-header {
    text-align: center;
    margin-bottom: 40px;
    overflow: hidden;
    position: relative;
}

.preferences-title {
    font-size: 32px;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 16px;
    line-height: 1.2;
}

.preferences-title-image {
    max-width: 100%;
    will-change: transform;
    display: block;
    margin: 0 auto;
}

/* Form Styles */
.preferences-form {
    margin-bottom: 24px;
    will-change: transform;
    padding-bottom: 30px;
}

.preferences-subtitle {
    font-size: 20px;
    color: #555;
    margin-bottom: 16px 0;
    font-weight: 500;
    text-align: center;
}

.preferences-headline {
    font-size: 16px;
    color: #666;
    margin-top: 20px;
    margin-bottom: 30px;
    text-align: center;
}

.subscription-category {
    margin-bottom: 24px;
}

.category-title {
    font-size: 24px;
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 1px solid #e0e0e0;
}

.subscription-options {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.subscription-option {
    background-color: #fafafa;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 16px;
    transition: all 0.2s ease;
}

.subscription-option:hover {
    background-color: #f0f0f0;
    border-color: #ccc;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.subscription-label {
    display: flex;
    align-items: flex-start;
    cursor: pointer;
    gap: 12px;
}

.subscription-label input[type="checkbox"] {
    margin-top: 4px;
    width: 20px;
    height: 20px;
    cursor: pointer;
    flex-shrink: 0;
}

.subscription-label input[type="checkbox"]:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.subscription-label input[type="checkbox"].disabled-by-unsubscribe {
    opacity: 0.5;
}

.subscription-info {
    flex: 1;
}

.subscription-title {
    font-size: 16px;
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: 4px;
}

.subscription-description {
    font-size: 14px;
    color: #666;
    line-height: 1.5;
}

/* Unsubscribe All Section */
.subscription-category:has(.unsubscribe-all-option) {
    border-top: 1px solid #e0e0e0;
    padding-top: 24px;
    margin-top: 24px;
}

/* Form Actions */
.form-actions {
    margin-top: 32px;
    text-align: center;
}

.btn-update-preferences {
    background-color: #0066cc;
    color: #fff;
    font-size: 16px;
    font-weight: 600;
    padding: 14px 40px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    min-width: 250px;
}

.btn-update-preferences:hover {
    background-color: #0052a3;
    box-shadow: 0 4px 8px rgba(0, 102, 204, 0.2);
}

.btn-update-preferences:active {
    transform: translateY(1px);
}

.btn-update-preferences:disabled {
    background-color: #ccc;
    cursor: not-allowed;
    box-shadow: none;
}

/* Success Message */
.success-message {
    text-align: center;
    padding: 60px 20px;
}

.success-content {
    max-width: 600px;
    margin: 0 auto;
    background-color: #f0f9f4;
    border: 1px solid #a8e6c1;
    border-radius: 8px;
    padding: 40px 30px;
}

.success-content h2 {
    font-size: 28px;
    font-weight: 700;
    color: #2e7d32;
    margin-bottom: 20px;
    line-height: 1.3;
}

.success-content p {
    font-size: 16px;
    color: #666;
    line-height: 1.6;
}

/* Error Message */
.error-message {
    text-align: center;
    padding: 60px 20px;
}

.error-content {
    max-width: 600px;
    margin: 0 auto;
    background-color: #fff3f3;
    border: 1px solid #ffcccc;
    border-radius: 8px;
    padding: 40px 30px;
}

.error-content h2 {
    font-size: 28px;
    font-weight: 700;
    color: #c62828;
    margin-bottom: 20px;
    line-height: 1.3;
}

.error-content p {
    font-size: 16px;
    color: #666;
    line-height: 1.6;
}

/* Footer Styles */
.preferences-footer {
    margin-top: 60px;
    padding-top: 30px;
    border-top: 2px solid #e0e0e0;
    text-align: center;
    color: #666;
    font-size: 13px;
}

.preferences-footer-logo {
    margin: 0 auto 20px;
    display: block;
}

.preferences-footer-logo img {
    width: 130px;
    height: 30px;
}

.preferences-footer p {
    margin: 8px 0;
}

/* Responsive Design */
@media (max-width: 768px) {
    .subscription-preferences-container {
        padding: 20px 16px;
    }

    .preferences-title {
        font-size: 24px;
    }

    .preferences-subtitle {
        font-size: 18px;
    }

    .preferences-headline {
        font-size: 14px;
    }

    .category-title {
        font-size: 20px;
    }

    .subscription-option {
        padding: 12px;
    }

    .subscription-title {
        font-size: 15px;
    }

    .subscription-description {
        font-size: 13px;
    }

    .btn-update-preferences {
        width: 100%;
        min-width: auto;
        padding: 12px 24px;
    }

    .success-content h2,
    .error-content h2 {
        font-size: 22px;
    }

    .success-content p,
    .error-content p {
        font-size: 14px;
    }

    .success-content,
    .error-content {
        padding: 30px 20px;
    }
}

@media (max-width: 480px) {
    .preferences-title {
        font-size: 20px;
    }

    .preferences-subtitle {
        font-size: 16px;
    }

    .subscription-label {
        gap: 8px;
    }

    .subscription-label input[type="checkbox"],
    .unsubscribe-all-checkbox input[type="checkbox"] {
        width: 18px;
        height: 18px;
    }
}
