/**
 * AlpsCraft Adventures - Main Stylesheet
 * Alpine Professional Brand Identity
 *
 * This consolidated stylesheet contains all custom styles for the AlpsCraft Adventures application.
 * It implements the "Alpine Nature meets Viennese Professional" aesthetic.
 */

/* ==================== CSS Variables ==================== */

:root {
    /* Alpine Professional Brand Colors */
    --alps-sea-green: #2E8B57;
    --alps-forest-green: #008900cf;
    --alps-charcoal: #1C2331;
    --alps-mint-white: #F7FAF8;
    --alps-white: #FFFFFF;

    /* Bootstrap Theme Colors (mapped to Alpine palette) */
    --bs-primary: #2E8B57;
    --bs-primary-rgb: 46, 139, 87;
    --bs-secondary: #036f02;
    --bs-secondary-rgb: 27, 94, 63;
    --bs-dark: #1C2331;
    --bs-dark-rgb: 28, 35, 49;
    --bs-light: #F7FAF8;
    --bs-light-rgb: 247, 250, 248;
    --bs-white: #FFFFFF;
    --bs-white-rgb: 255, 255, 255;

    /* Functional Colors */
    --bs-success: #2E8B57;
    --bs-success-rgb: 46, 139, 87;
    --bs-info: #0d6efd;
    --bs-warning: #ffc107;
    --bs-danger: #dc3545;

    /* Legacy Variable Support (for backward compatibility) */
    --primary-color: var(--bs-primary);
    --secondary-color: var(--bs-secondary);
    --success-color: var(--bs-success);
    --danger-color: var(--bs-danger);
    --warning-color: var(--bs-warning);
    --info-color: var(--bs-info);

    /* Difficulty Level Colors (mapped to Bootstrap colors) */
    --difficulty-FAMILY: var(--bs-success);
    --difficulty-MEDIUM: var(--bs-warning);
    --difficulty-HARD: var(--bs-danger);

    /* Spacing (Bootstrap 8-point system) */
    --spacing-xs: 0.25rem;
    --spacing-sm: 0.5rem;
    --spacing-md: 1rem;
    --spacing-lg: 1.5rem;
    --spacing-xl: 2rem;

    /* Typography - Inter Font */
    --font-family-base: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --font-size-base: 1rem;
    --line-height-base: 1.6;

    /* Borders */
    --bs-border-radius: 0.25rem;
    --bs-border-radius-lg: 0.3rem;
    --bs-border-radius-sm: 0.2rem;

    /* Admin Theme Colors */
    --admin-primary: var(--alps-sea-green);
    --admin-secondary: var(--alps-forest-green);
    --admin-sidebar-width: 240px;
    --admin-navbar-height: 56px;

    /* Icon Gradients (Alpine Professional) */
    --icon-primary-gradient: linear-gradient(135deg, var(--alps-sea-green) 0%, var(--alps-forest-green) 100%);
    --icon-success-gradient: linear-gradient(135deg, #2E8B57 0%, #38ef7d 100%);
    --icon-warning-gradient: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    --icon-info-gradient: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);

    ----bs-card-bg: var(--alps-forest-green);

}

/* ==================== Global Layout ==================== */

body {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    font-family: var(--font-family-base);
    line-height: var(--line-height-base);
    background-color: var(--bs-light);
    color: var(--bs-dark);
}

main {
    flex: 1;
}

/* ==================== Typography ==================== */

h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    color: var(--bs-dark);
}

a {
    color: var(--bs-secondary);
    text-decoration: none;
    transition: color 0.2s ease-in-out;
}

a:hover {
    color: var(--bs-primary);
}

/* ==================== Buttons ==================== */

.btn {
    box-shadow: none !important;
    font-weight: 500;
    border-radius: var(--bs-border-radius);
}

.btn-primary {
    background-color: var(--bs-primary);
    border-color: var(--bs-primary);
    color: white;
}

.btn-primary:hover,
.btn-primary:focus {
    background-color: var(--bs-secondary);
    border-color: var(--bs-secondary);
}

.btn-secondary {
    background-color: var(--bs-secondary);
    border-color: var(--bs-secondary);
    color: white;
}

.btn-secondary:hover,
.btn-secondary:focus {
    background-color: var(--bs-primary);
    border-color: var(--bs-primary);
}

.btn-outline-primary {
    border-color: var(--bs-primary);
    color: var(--bs-primary);
}

.btn-outline-primary:hover,
.btn-outline-primary:focus {
    background-color: var(--bs-primary);
    border-color: var(--bs-primary);
    color: white;
}

.btn-outline-secondary {
    border-color: #1C2331;
    color: #1C2331;
    font-weight: 500;
}

.btn-outline-secondary:hover,
.btn-outline-secondary:focus {
    background-color: #1C2331;
    border-color: #1C2331;
    color: white;
}

/* ==================== Forms ==================== */

.form-control:focus,
.form-select:focus {
    border-color: var(--bs-primary);
    box-shadow: 0 0 0 0.25rem rgba(46, 139, 87, 0.25);
}

/* ==================== Cards ==================== */

.card {
    /* Black border for strong definition */
    border: 3px solid #000000;
    /* Enhanced shadow for modern depth and separation from mint background */
    box-shadow: 0 4px 16px rgba(28, 35, 49, 0.1);
    /* White background */
    background: #ffffff !important;
    border-radius: var(--bs-border-radius);
    transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out, border-color 0.2s ease-in-out, background 0.2s ease-in-out;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 28px rgba(28, 35, 49, 0.15);
    border-color: #000000;
    background: #ffffff !important;
}

/* ==================== Navigation ==================== */

/* Public Header */
.navbar-light {
    background-color: #036f02 !important;
    box-shadow: 0 2px 4px rgba(28, 35, 49, 0.05);
}

.navbar-brand {
    font-weight: 700;
    color: #ffffff !important;
}

.navbar-brand:hover {
    color: #e0e0e0 !important;
}

.nav-link {
    color: #ffffff;
    font-weight: 500;
    transition: color 0.2s ease-in-out;
}

.nav-link:hover,
.nav-link:focus {
    color: #e0e0e0;
}

.nav-link.active {
    color: #ffffff;
    font-weight: 600;
}

.navbar-toggler {
    border-color: rgba(255, 255, 255, 0.5);
}

.navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255, 255, 255, 1%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

/* Language Switcher - Distinct styling */
.language-switcher {
    color: #b0b0b0 !important;
    opacity: 0.9;
}

.language-switcher:hover,
.language-switcher:focus {
    color: #d0d0d0 !important;
}

.language-switcher i {
    color: #b0b0b0;
}

/* ==================== Footer ==================== */

footer {
    background-color: var(--bs-secondary);
    color: var(--bs-white);
}

footer h5,
footer h6 {
    color: var(--bs-white);
    font-weight: 700;
}

footer a {
    color: rgba(255, 255, 255, 0.75);
    text-decoration: none;
    transition: color 0.2s ease-in-out;
}

footer a:hover {
    color: var(--bs-white);
}

/* ==================== Difficulty Badges (Global) ==================== */

.difficulty-badge-FAMILY,
.difficulty-FAMILY,
.badge.bg-success,
.badge.difficulty-FAMILY {
    background-color: var(--bs-success) !important;
    color: white !important;
    font-weight: 500;
}

.difficulty-badge-MEDIUM,
.difficulty-MEDIUM,
.badge.bg-warning,
.badge.difficulty-MEDIUM {
    background-color: var(--bs-warning) !important;
    color: #333 !important;
    font-weight: 500;
}

.difficulty-badge-HARD,
.difficulty-HARD,
.badge.bg-danger,
.badge.difficulty-HARD {
    background-color: var(--bs-danger) !important;
    color: white !important;
    font-weight: 500;
}

/* ==================== Trail Cards ==================== */

.trail-card {
    /* Inherit base card styles and apply brand-aligned background */
    border: 1px solid #000000;
    box-shadow: 0 4px 16px rgba(28, 35, 49, 0.1);
    background: #ffffff !important;
    transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out, border-color 0.2s ease-in-out, background 0.2s ease-in-out;
    cursor: pointer;
}

.trail-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 28px rgba(28, 35, 49, 0.15);
    border-color: #000000;
    background: #ffffff !important;
}

.trail-card .card-img-top {
    height: 200px;
    object-fit: cover;
    border-top-left-radius: var(--bs-border-radius);
    border-top-right-radius: var(--bs-border-radius);
}

.trail-card .card-title {
    font-weight: 700;
    color: var(--bs-dark);
    font-size: 1.25rem;
    margin-bottom: 0.75rem;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.trail-card .card-text {
    line-height: 1.6;
    color: #6c757d;
    font-size: 0.9rem;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
}

.trail-card .card-footer {
    background-color: transparent;
    border-top: none;
    padding-top: 0;
}

.card-footer .btn-primary {
    background-color: #036f02 !important;
    border-color: #036f02 !important;
}

.card-footer .btn-primary:hover,
.card-footer .btn-primary:focus {
    background-color: #025501 !important;
    border-color: #025501 !important;
}

.trail-metrics {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    align-items: center;
    margin-bottom: 1rem;
}

.trail-metrics .badge {
    font-size: 0.875rem;
    padding: 0.375rem 0.625rem;
    font-weight: 500;
}

.trail-metrics .metric {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    font-size: 0.875rem;
    color: #6c757d;
}

.trail-location {
    margin-top: 0.75rem;
    padding-top: 0.75rem;
    border-top: 1px solid #dee2e6;
}

/* Trail List View */
.trail-cards-container.list-view .trail-card {
    display: flex;
    flex-direction: row;
    margin-bottom: 1rem;
}

.trail-cards-container.list-view .trail-card .card-img-top {
    width: 250px;
    height: 100%;
    object-fit: cover;
}

.trail-cards-container.list-view .trail-card .card-body {
    flex: 1;
}

/* ==================== Blog Cards ==================== */

.blog-card {
    /* Inherit base card styles and apply brand-aligned background */
    border: 1px solid #000000;
    box-shadow: 0 4px 16px rgba(28, 35, 49, 0.1);
    background: #ffffff !important;
    transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out, border-color 0.2s ease-in-out, background 0.2s ease-in-out;
}

.blog-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 28px rgba(28, 35, 49, 0.15);
    border-color: #000000;
    background: #ffffff !important;
}

.blog-card .card-title {
    font-weight: 700;
    color: var(--bs-dark);
}

.blog-card .card-title a {
    color: var(--bs-dark);
    text-decoration: none;
    transition: color 0.2s ease-in-out;
}

.blog-card .card-title a:hover {
    color: var(--bs-primary);
}

.blog-card .card-text {
    line-height: 1.6;
    color: #6c757d;
}

.blog-card .btn-outline-primary {
    font-weight: 500;
}

/* Blog Navigation Cards (Previous/Next) */
.blog-nav-card {
    border: 1px solid rgba(0, 0, 0, 0.2) !important;
}

.blog-nav-card:hover {
    border-color: rgba(0, 0, 0, 0.3) !important;
}

/* ==================== Filter Sidebar ==================== */

#filterSidebar .card {
    border: 1px solid #000000;
    box-shadow: 0 4px 16px rgba(28, 35, 49, 0.1);
    background: #ffffff !important;
}

#filterSidebar .card-header {
    background-color: transparent;
    border-bottom: 1px solid #dee2e6;
    padding: 1rem 1.25rem;
}

#filterSidebar .card-header h5 {
    color: #1C2331;
    font-weight: 700;
    font-size: 1.125rem;
}

#filterSidebar .card-header h5 i {
    color: #2E8B57;
    margin-right: 0.5rem;
}

#filterSidebar .card-header .btn-outline-secondary {
    border-color: #dc3545;
    color: #dc3545;
    font-weight: 500;
    padding: 0.25rem 0.75rem;
    font-size: 0.875rem;
}

#filterSidebar .card-header .btn-outline-secondary:hover {
    background-color: #dc3545;
    border-color: #dc3545;
    color: white;
}

#filterSidebar .card-body {
    padding: 1.25rem;
}

#filterSidebar hr {
    margin: 1.5rem 0;
    border-color: #dee2e6;
    opacity: 1;
}

.filter-section {
    padding: 0;
}

.filter-title {
    font-weight: 600;
    color: var(--bs-dark);
    font-size: 1rem;
    margin-bottom: 0.75rem;
}

.filter-section .btn-group-vertical {
    width: 100%;
}

.filter-section .btn-group-vertical .btn {
    font-weight: 500;
    padding: 0.625rem 1rem;
    text-align: left;
    border-width: 2px;
    transition: all 0.2s ease-in-out;
}

/* Difficulty Filter Buttons */
.filter-section .btn-outline-success {
    border-color: #2E8B57;
    color: #2E8B57;
}

.filter-section .btn-outline-success:hover {
    background-color: #2E8B57;
    border-color: #2E8B57;
    color: white;
}

.filter-section .btn-check:checked + .btn-outline-success {
    background-color: #2E8B57;
    border-color: #2E8B57;
    color: white;
}

.filter-section .btn-outline-warning {
    border-color: #ffc107;
    color: #856404;
}

.filter-section .btn-outline-warning:hover {
    background-color: #ffc107;
    border-color: #ffc107;
    color: #333;
}

.filter-section .btn-check:checked + .btn-outline-warning {
    background-color: #ffc107;
    border-color: #ffc107;
    color: #333;
}

.filter-section .btn-outline-danger {
    border-color: #dc3545;
    color: #dc3545;
}

.filter-section .btn-outline-danger:hover {
    background-color: #dc3545;
    border-color: #dc3545;
    color: white;
}

.filter-section .btn-check:checked + .btn-outline-danger {
    background-color: #dc3545;
    border-color: #dc3545;
    color: white;
}

/* Region Tree */
.region-tree {
    max-height: 300px;
    overflow-y: auto;
    padding-right: 0.5rem;
}

.region-tree::-webkit-scrollbar {
    width: 6px;
}

.region-tree::-webkit-scrollbar-track {
    background: #F7FAF8;
    border-radius: 3px;
}

.region-tree::-webkit-scrollbar-thumb {
    background: #2E8B57;
    border-radius: 3px;
}

.region-tree::-webkit-scrollbar-thumb:hover {
    background: #036f02;
}

.region-tree .country-group {
    margin-bottom: 1rem;
}

.region-tree .region-children {
    margin-left: 1.5rem;
    margin-top: 0.5rem;
}

.region-tree .form-check {
    padding-left: 1.5rem;
    margin-bottom: 0.5rem;
}

.region-tree .form-check-label {
    font-weight: 400;
    color: #1C2331;
}

.region-tree .country-checkbox {
    font-weight: bold;
}

.region-tree .form-check-label.fw-bold {
    font-weight: 600;
    color: #1C2331;
}

/* ==================== Range Sliders ==================== */

.range-slider-container {
    padding: 0.75rem 0;
}

.form-range {
    cursor: pointer;
    height: 6px;
}

.form-range::-webkit-slider-thumb {
    background-color: var(--bs-primary);
    width: 16px;
    height: 16px;
    border: 2px solid white;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    transition: all 0.2s ease-in-out;
}

.form-range::-webkit-slider-thumb:hover {
    background-color: var(--bs-secondary);
    transform: scale(1.1);
}

.form-range::-moz-range-thumb {
    background-color: var(--bs-primary);
    width: 16px;
    height: 16px;
    border: 2px solid white;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    cursor: pointer;
    transition: all 0.2s ease-in-out;
}

.form-range::-moz-range-thumb:hover {
    background-color: var(--bs-secondary);
    transform: scale(1.1);
}

.form-range::-webkit-slider-runnable-track {
    background-color: rgba(46, 139, 87, 0.2);
    height: 6px;
    border-radius: 3px;
}

.form-range::-moz-range-track {
    background-color: rgba(46, 139, 87, 0.2);
    height: 6px;
    border-radius: 3px;
}

.range-slider-container .badge {
    font-size: 0.875rem;
    padding: 0.375rem 0.625rem;
    font-weight: 500;
    background-color: #dee2e6;
    color: #1C2331;
}

/* ==================== Trail Detail Page ==================== */

/* Hero Section */
.hero-container {
    position: relative;
    width: 100%;
    height: 400px;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    overflow: hidden;
}

.hero-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.8) 0%, transparent 100%);
    padding: 2rem;
    color: white;
}

.hero-title {
    font-size: 2.5rem;
    font-weight: bold;
    margin-bottom: 1rem;
    color: #FFFFFF !important;
}

.metrics-container {
    display: flex;
    gap: 2rem;
    flex-wrap: wrap;
}

.metric-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.metric-icon {
    font-size: 1.5rem;
}

.metric-value {
    font-weight: bold;
    font-size: 1.2rem;
}

.metric-label {
    font-size: 0.9rem;
    opacity: 0.9;
}

/* Property Badges */
.property-badges {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin: 2rem 0;
}

.property-badge {
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Map Container */
#map-container {
    height: 500px;
    background-color: #e9ecef;
    border-radius: 0.5rem;
}

/* Overview Content */
.overview-content {
    line-height: 1.8;
}

.overview-content p {
    margin-bottom: 1rem;
}

.overview-content h2,
.overview-content h3 {
    margin-top: 1.5rem;
    margin-bottom: 1rem;
}

/* Gallery Carousel */
.carousel-item img {
    width: 100%;
    height: 500px;
    object-fit: cover;
    border-radius: 0.5rem;
}

.gallery-thumbnail {
    transition: transform 0.2s ease-in-out, opacity 0.2s ease-in-out;
    opacity: 0.7;
}

.gallery-thumbnail:hover {
    transform: scale(1.05);
    opacity: 1;
}

.carousel-caption {
    background-color: rgba(0, 0, 0, 0.6);
    padding: 0.5rem 1rem;
    border-radius: 0.25rem;
}

/* Related Trails */
.related-trail-card {
    border: 1px solid #000000;
    background: #ffffff !important;
    transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
}

.related-trail-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    border-color: #000000;
}

.related-trail-card img {
    height: 200px;
    object-fit: cover;
}

.related-trail-card .card-footer {
    background-color: #036f02;
    border-top: none;
    padding-top: 0;
}

/* Tab Navigation Styling */
#trailTabs .nav-link {
    color: #495057;
    background-color: #f8f9fa;
}

#trailTabs .nav-link:hover {
    color: #212529;
    background-color: #e9ecef;
}

#trailTabs .nav-link.active {
    color: #0d6efd;
    background-color: #fff;
}

/* ==================== Admin Panel ==================== */

.admin-gradient {
    background: linear-gradient(135deg, var(--admin-primary) 0%, var(--admin-secondary) 100%);
}

/* Login Page Styles */
.login-page {
    background: linear-gradient(135deg, var(--admin-primary) 0%, var(--admin-secondary) 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.login-container {
    max-width: 400px;
    width: 100%;
    padding: 15px;
}

.login-card {
    background: white;
    border-radius: 10px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
}

.login-header {
    background: linear-gradient(135deg, var(--admin-primary) 0%, var(--admin-secondary) 100%);
    color: white;
    padding: 30px;
    border-radius: 10px 10px 0 0;
    text-align: center;
}

.login-header h1 {
    margin: 0;
    font-size: 24px;
    font-weight: 600;
}

.login-header p {
    margin: 10px 0 0 0;
    opacity: 0.9;
    font-size: 14px;
}

.login-body {
    padding: 40px;
}

.login-body .form-floating {
    margin-bottom: 20px;
}

.btn-login {
    width: 100%;
    padding: 12px;
    font-size: 16px;
    font-weight: 600;
    background: linear-gradient(135deg, var(--admin-primary) 0%, var(--admin-secondary) 100%);
    border: none;
}

.btn-login:hover {
    background: linear-gradient(135deg, var(--admin-secondary) 0%, var(--admin-primary) 100%);
}

.login-body .alert {
    border-radius: 8px;
    margin-bottom: 20px;
}

/* Dashboard Page Styles */
.admin-dashboard body {
    background-color: #f8f9fa;
}

/* Top Navbar */
.admin-navbar {
    box-shadow: 0 2px 4px rgba(0,0,0,.08);
}

.admin-navbar .navbar-brand {
    font-weight: 700;
    color: var(--admin-primary) !important;
    font-size: 1.25rem;
}

/* Horizontal Navigation Menu */
.admin-navbar .nav-pills {
    --bs-nav-pills-border-radius: 0;
    --bs-nav-pills-link-active-bg: linear-gradient(135deg, var(--admin-primary) 0%, var(--admin-secondary) 100%);
}

.admin-navbar .nav-link {
    color: #6c757d;
    font-weight: 500;
    font-size: 0.9rem;
    padding: 0.75rem 0.5rem;
    border-radius: 0;
    transition: all 0.3s;
    border-bottom: 3px solid transparent;
}

.admin-navbar .nav-link:hover {
    color: var(--admin-primary);
    background-color: rgba(46, 139, 87, 0.05);
}

.admin-navbar .nav-link.active {
    color: var(--admin-primary);
    background: linear-gradient(180deg, rgba(46, 139, 87, 0.1) 0%, transparent 100%);
    border-bottom-color: var(--admin-primary);
    font-weight: 600;
}

.admin-navbar .nav-link i {
    margin-right: 4px;
    font-size: 1rem;
}

/* Main Content Area */
.admin-main {
    margin-left: 0;
    padding-top: 140px;
}

/* Dashboard Cards */
.dashboard-card {
    border: 3px solid #000000;
    border-radius: 10px;
    background: #ffffff !important;
    box-shadow: 0 2px 4px rgba(0,0,0,.08);
    transition: transform 0.3s, box-shadow 0.3s;
}

.dashboard-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 12px rgba(0,0,0,.15);
    border-color: #000000;
}

/* Card Icons */
.card-icon {
    width: 48px;
    height: 48px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
}

.icon-primary {
    background: var(--icon-primary-gradient);
    color: white;
}

.icon-success {
    background: var(--icon-success-gradient);
    color: white;
}

.icon-warning {
    background: var(--icon-warning-gradient);
    color: white;
}

.icon-info {
    background: var(--icon-info-gradient);
    color: white;
}

/* Welcome Banner */
.welcome-banner {
    background: linear-gradient(135deg, var(--admin-primary) 0%, var(--admin-secondary) 100%);
    color: white;
    border-radius: 10px;
    padding: 30px;
    margin-bottom: 30px;
}

.welcome-banner h1 {
    margin-bottom: 10px;
}

.welcome-banner p {
    margin-bottom: 0;
    opacity: 0.95;
}

/* Image Gallery Styles */
.card-img-top {
    cursor: pointer;
}

/* Translation Form Scrollable Content */
.trix-content {
    min-height: 300px;
    max-height: 500px;
    overflow-y: auto;
    overflow-x: hidden;
    scroll-behavior: smooth;
}

.trix-content::-webkit-scrollbar {
    width: 8px;
}

.trix-content::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

.trix-content::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 4px;
}

.trix-content::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

/* ==================== Loading States ==================== */

.loading-spinner {
    display: inline-block;
    width: 2rem;
    height: 2rem;
    border: 0.25rem solid rgba(0, 0, 0, 0.1);
    border-top-color: var(--bs-primary);
    border-radius: 50%;
    animation: spinner 0.6s linear infinite;
}

@keyframes spinner {
    to {
        transform: rotate(360deg);
    }
}

.htmx-indicator {
    display: none;
}

.htmx-request .htmx-indicator,
.htmx-request.htmx-indicator {
    display: flex;
}

.spinner-border {
    color: var(--bs-primary);
}

/* HTMX Swapping Animation */
.htmx-swapping {
    opacity: 0.5;
    transition: opacity 200ms ease-in;
}

.htmx-settling {
    opacity: 1;
    transition: opacity 200ms ease-out;
}

.htmx-request #trailResults {
    opacity: 0.5;
    pointer-events: none;
}

/* Loading Indicator */
#loadingSpinner {
    display: none;
}

#loadingSpinner.htmx-request {
    display: block;
}

/* ==================== Loading Skeleton Styles ==================== */

@keyframes skeleton-loading {
    0% {
        background-position: -200px 0;
    }
    100% {
        background-position: calc(200px + 100%) 0;
    }
}

.skeleton {
    background-color: #e0e0e0;
    background-image: linear-gradient(
        90deg,
        #e0e0e0 0px,
        #f5f5f5 40px,
        #e0e0e0 80px
    );
    background-size: 200px 100%;
    background-repeat: no-repeat;
    animation: skeleton-loading 1.2s ease-in-out infinite;
    border-radius: 4px;
    display: inline-block;
}

.skeleton-card {
    width: 100%;
    height: 100%;
    border-radius: 8px;
    overflow: hidden;
    background: white;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12);
}

.skeleton-card-image {
    width: 100%;
    height: 200px;
    background-color: #e0e0e0;
    background-image: linear-gradient(
        90deg,
        #e0e0e0 0px,
        #f5f5f5 40px,
        #e0e0e0 80px
    );
    background-size: 200px 100%;
    background-repeat: no-repeat;
    animation: skeleton-loading 1.2s ease-in-out infinite;
}

.skeleton-card-body {
    padding: 1rem;
}

.skeleton-title {
    height: 24px;
    width: 80%;
    margin-bottom: 12px;
}

.skeleton-text {
    height: 14px;
    width: 100%;
    margin-bottom: 8px;
}

.skeleton-text-short {
    height: 14px;
    width: 60%;
    margin-bottom: 8px;
}

.skeleton-badge {
    height: 24px;
    width: 80px;
    display: inline-block;
    margin-right: 8px;
    margin-bottom: 8px;
}

.skeleton-button {
    height: 36px;
    width: 100%;
    margin-top: 12px;
}

.skeleton-grid {
    display: grid;
    gap: 1.5rem;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
}

.loaded .skeleton-container {
    display: none;
}

/* ==================== Responsive Images ==================== */

.img-cover {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.img-contain {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

/* ==================== Content Styles (Blog, Static Pages, Trail Details) ==================== */

/* Base content container styling for rich text content */
.blog-content,
.page-content,
.overview-content {
    line-height: 1.8;
    font-size: 1rem;
    color: var(--bs-dark);
}

/* Heading hierarchy within content - ensure content headings are smaller than page title */
.blog-content h1,
.page-content h1,
.overview-content h1 {
    font-size: 1.75rem;
    font-weight: 700;
    margin-top: 2rem;
    margin-bottom: 1rem;
    color: var(--bs-dark);
    line-height: 1.3;
}

.blog-content h2,
.page-content h2,
.overview-content h2 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-top: 1.75rem;
    margin-bottom: 0.875rem;
    color: var(--bs-dark);
    line-height: 1.3;
}

.blog-content h3,
.page-content h3,
.overview-content h3 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
    color: var(--bs-dark);
    line-height: 1.4;
}

.blog-content h4,
.page-content h4,
.overview-content h4 {
    font-size: 1.125rem;
    font-weight: 600;
    margin-top: 1.25rem;
    margin-bottom: 0.625rem;
    color: var(--bs-dark);
    line-height: 1.4;
}

.blog-content h5,
.page-content h5,
.overview-content h5 {
    font-size: 1rem;
    font-weight: 600;
    margin-top: 1rem;
    margin-bottom: 0.5rem;
    color: var(--bs-dark);
    line-height: 1.5;
}

.blog-content h6,
.page-content h6,
.overview-content h6 {
    font-size: 0.875rem;
    font-weight: 600;
    margin-top: 1rem;
    margin-bottom: 0.5rem;
    color: #6c757d;
    line-height: 1.5;
}

/* Image styling - makes all images responsive and properly spaced */
.blog-content img,
.page-content img,
.overview-content img {
    /* Force full width for better readability */
    max-width: 100%;
    width: 100%;
    height: auto;
    /* Add visual polish */
    border-radius: 0.5rem;
    box-shadow: 0 4px 12px rgba(28, 35, 49, 0.1);
    /* Convert inline display to block for proper text flow */
    display: block;
    /* Center the image */
    margin-left: auto;
    margin-right: auto;
    /* Generous vertical spacing to separate from text */
    margin-top: 1.5rem;
    margin-bottom: 1.5rem;
    /* Add subtle border for definition */
    border: 1px solid rgba(28, 35, 49, 0.05);
    /* Smooth hover effect */
    transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
}

/* Hover effect for images */
.blog-content img:hover,
.page-content img:hover,
.overview-content img:hover {
    transform: scale(1.02);
    box-shadow: 0 8px 24px rgba(28, 35, 49, 0.15);
}

/* Figure elements (when images are wrapped in figure tags) */
.blog-content figure,
.page-content figure,
.overview-content figure {
    margin: 2rem 0;
    display: block;
    clear: both;
}

.blog-content figure img,
.page-content figure img,
.overview-content figure img {
    margin: 0 auto 1rem auto;
}

/* Figure captions */
.blog-content figcaption,
.page-content figcaption,
.overview-content figcaption {
    text-align: center;
    font-size: 0.875rem;
    color: #6c757d;
    margin-top: 0.5rem;
    padding: 0 1rem;
    font-style: italic;
    line-height: 1.5;
}

/* Paragraph spacing for better readability around images */
.blog-content p,
.page-content p,
.overview-content p {
    margin-bottom: 1rem;
    clear: both;
}

/* Ensure text doesn't wrap around images */
.blog-content p img,
.page-content p img,
.overview-content p img {
    display: block;
    float: none;
}

/* Handle Trix editor attachments specifically */
.blog-content .attachment,
.page-content .attachment,
.overview-content .attachment {
    display: block;
    margin: 1.5rem 0;
    clear: both;
}

.blog-content .attachment img,
.page-content .attachment img,
.overview-content .attachment img {
    display: block;
    margin: 0 auto;
}

/* ==================== Responsive Content Images ==================== */

/* Large screens - constrain very wide images */
@media (min-width: 992px) {
    .blog-content img,
    .page-content img,
    .overview-content img {
        max-width: 900px;
    }
}

/* Medium screens */
@media (min-width: 768px) and (max-width: 991.98px) {
    .blog-content img,
    .page-content img,
    .overview-content img {
        max-width: 100%;
        margin-top: 1.25rem;
        margin-bottom: 1.25rem;
    }
}

/* Small screens - reduce spacing and shadows */
@media (max-width: 767.98px) {
    .blog-content img,
    .page-content img,
    .overview-content img {
        margin-top: 1rem;
        margin-bottom: 1rem;
        border-radius: 0.375rem;
        box-shadow: 0 2px 8px rgba(28, 35, 49, 0.08);
    }

    .blog-content img:hover,
    .page-content img:hover,
    .overview-content img:hover {
        transform: none;
        box-shadow: 0 2px 8px rgba(28, 35, 49, 0.08);
    }

    .blog-content figure,
    .page-content figure,
    .overview-content figure {
        margin: 1.5rem 0;
    }

    .blog-content figcaption,
    .page-content figcaption,
    .overview-content figcaption {
        font-size: 0.8rem;
        padding: 0 0.5rem;
    }
}

/* Very small screens */
@media (max-width: 576px) {
    .blog-content img,
    .page-content img,
    .overview-content img {
        margin-top: 0.75rem;
        margin-bottom: 0.75rem;
        border-radius: 0.25rem;
    }
}

/* ==================== Table of Contents ==================== */

/* Modern Table of Contents Design */
.toc-container {
    background: linear-gradient(135deg, rgba(46, 139, 87, 0.08) 0%, rgba(3, 111, 2, 0.06) 100%);
    border-left: 4px solid var(--bs-primary);
    border-radius: 0.5rem;
    padding: 1.25rem 1.5rem;
    box-shadow: 0 2px 8px rgba(28, 35, 49, 0.08);
    transition: all 0.3s ease-in-out;
}

.toc-container:hover {
    box-shadow: 0 4px 12px rgba(28, 35, 49, 0.12);
    transform: translateX(2px);
}

/* Header with icon and title inline */
.toc-header {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 2px solid rgba(46, 139, 87, 0.15);
}

.toc-icon {
    font-size: 1.125rem;
    color: var(--bs-primary);
    flex-shrink: 0;
}

.toc-title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--bs-dark);
    margin: 0;
    letter-spacing: 0.02em;
    text-transform: uppercase;
}

/* Navigation list */
.toc-nav {
    margin: 0;
}

.toc-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.toc-item {
    margin: 0;
    padding: 0;
}

/* Link styling */
.toc-link {
    display: flex;
    align-items: center;
    padding: 0.5rem 0.75rem;
    color: var(--bs-dark);
    text-decoration: none;
    font-size: 0.9375rem;
    font-weight: 500;
    line-height: 1.5;
    border-radius: 0.375rem;
    transition: all 0.2s ease-in-out;
    position: relative;
}

/* Hover effect */
.toc-link:hover {
    background-color: rgba(46, 139, 87, 0.1);
    color: var(--bs-primary);
    padding-left: 1rem;
    transform: translateX(2px);
}

/* Active state (when scrolled to section) */
.toc-link:active,
.toc-link:focus {
    background-color: rgba(46, 139, 87, 0.15);
    color: var(--bs-primary);
    outline: 2px solid var(--bs-primary);
    outline-offset: -2px;
}

/* Add subtle indicator before link */
.toc-link::before {
    content: "";
    width: 6px;
    height: 6px;
    background-color: var(--bs-primary);
    border-radius: 50%;
    margin-right: 0.75rem;
    transition: all 0.2s ease-in-out;
    opacity: 0.4;
}

.toc-link:hover::before {
    opacity: 1;
    transform: scale(1.3);
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .toc-container {
        padding: 1rem 1.25rem;
    }

    .toc-title {
        font-size: 0.9375rem;
    }

    .toc-link {
        font-size: 0.875rem;
        padding: 0.4rem 0.625rem;
    }

    .toc-link:hover {
        padding-left: 0.875rem;
    }
}

/* Print styles for TOC */
@media print {
    .toc-container {
        background: #f8f9fa;
        box-shadow: none;
        border: 1px solid #dee2e6;
        page-break-inside: avoid;
    }

    .toc-link:hover {
        transform: none;
        padding-left: 0.75rem;
    }
}

/* ==================== Back to Top Button ==================== */

.back-to-top-btn {
    position: fixed;
    bottom: 2rem;
    left: 2rem;
    width: 3rem;
    height: 3rem;
    background: linear-gradient(135deg, var(--bs-primary) 0%, var(--bs-secondary) 100%);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    box-shadow: 0 4px 12px rgba(28, 35, 49, 0.2);
    transition: all 0.3s ease-in-out;
    z-index: 1000;
    border: 2px solid transparent;
}

.back-to-top-btn:hover {
    background: linear-gradient(135deg, var(--bs-secondary) 0%, var(--bs-primary) 100%);
    color: white;
    transform: translateY(-4px);
    box-shadow: 0 6px 16px rgba(28, 35, 49, 0.3);
    border-color: rgba(255, 255, 255, 0.3);
}

.back-to-top-btn:active {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(28, 35, 49, 0.2);
}

.back-to-top-btn:focus {
    outline: 2px solid var(--bs-primary);
    outline-offset: 3px;
}

.back-to-top-btn i {
    font-size: 1.25rem;
    font-weight: bold;
}

/* Smooth scroll behavior for anchor links */
html {
    scroll-behavior: smooth;
}

/* Responsive adjustments for back-to-top button */
@media (max-width: 768px) {
    .back-to-top-btn {
        bottom: 1.5rem;
        left: 1.5rem;
        width: 2.75rem;
        height: 2.75rem;
    }

    .back-to-top-btn i {
        font-size: 1.125rem;
    }
}

@media (max-width: 576px) {
    .back-to-top-btn {
        bottom: 1rem;
        left: 1rem;
        width: 2.5rem;
        height: 2.5rem;
    }

    .back-to-top-btn i {
        font-size: 1rem;
    }
}

/* Ensure back-to-top button doesn't overlap with mobile filter button */
@media (max-width: 991.98px) {
    /* If filter toggle is on the right, back-to-top stays on the left */
    .back-to-top-btn {
        /* Maintain left position */
    }
}

/* Print - hide back to top button */
@media print {
    .back-to-top-btn {
        display: none !important;
    }
}

/* Reduced motion - disable smooth scrolling */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    .back-to-top-btn:hover {
        transform: none;
    }
}

/* ==================== Utility Classes ==================== */

.text-shadow {
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.hover-lift {
    transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
}

.hover-lift:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.text-primary {
    color: var(--bs-primary) !important;
}

.text-secondary {
    color: var(--bs-secondary) !important;
}

.bg-primary {
    background-color: var(--bs-primary) !important;
}

.bg-secondary {
    background-color: var(--bs-secondary) !important;
}

.bg-light {
    background-color: var(--bs-light) !important;
}

.shadow-sm-custom {
    box-shadow: 0 2px 8px rgba(28, 35, 49, 0.05) !important;
}

.shadow-custom {
    box-shadow: 0 4px 12px rgba(28, 35, 49, 0.08) !important;
}

.shadow-lg-custom {
    box-shadow: 0 8px 24px rgba(28, 35, 49, 0.12) !important;
}

/* ==================== Custom Scrollbar ==================== */

::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: var(--bs-light);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb {
    background: var(--bs-primary);
    border-radius: 5px;
    opacity: 0.7;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--bs-secondary);
    opacity: 1;
}

/* ==================== Breadcrumbs ==================== */

.breadcrumb {
    background-color: transparent;
    padding: 0;
}

.breadcrumb-item a {
    color: var(--bs-secondary);
    text-decoration: none;
    font-weight: 500;
}

.breadcrumb-item a:hover {
    color: var(--bs-primary);
    text-decoration: underline;
}

.breadcrumb-item.active {
    color: #6c757d;
}

.breadcrumb-item + .breadcrumb-item::before {
    color: #6c757d;
}

/* ==================== Pagination ==================== */

.pagination {
    margin-bottom: 0;
}

.page-link {
    color: var(--bs-primary);
    border-color: #dee2e6;
    font-weight: 500;
    transition: all 0.2s ease-in-out;
}

.page-link:hover {
    color: var(--bs-secondary);
    background-color: rgba(46, 139, 87, 0.1);
    border-color: var(--bs-primary);
}

.page-link:focus {
    box-shadow: 0 0 0 0.25rem rgba(46, 139, 87, 0.25);
    color: var(--bs-primary);
}

.page-item.active .page-link {
    background-color: var(--bs-primary);
    border-color: var(--bs-primary);
    color: white;
}

.page-item.disabled .page-link {
    color: #6c757d;
    background-color: white;
    border-color: #dee2e6;
}

/* ==================== Page Headers ==================== */

.page-header h1 {
    color: var(--bs-dark);
    font-weight: 700;
}

.page-header .lead {
    color: #6c757d;
    line-height: 1.6;
}

.page-header i {
    color: var(--bs-primary);
}

/* Results Header Styling */
.d-flex.justify-content-between h2 {
    color: #1C2331;
    font-weight: 700;
}

.d-flex.justify-content-between .badge {
    background-color: #2E8B57;
    font-weight: 500;
}

/* View Mode Toggle Buttons */
.btn-group .btn-outline-secondary.active {
    background-color: #2E8B57;
    border-color: #2E8B57;
    color: white;
}

/* Empty State */
.empty-state {
    padding: 4rem 2rem;
}

.empty-state i {
    font-size: 4rem;
    opacity: 0.3;
}

.empty-state h3 {
    margin-top: 1rem;
    color: #6c757d;
}

/* Country Checkbox Indeterminate State */
.country-checkbox:indeterminate {
    background-color: #036f02;
    border-color: #036f02;
}

/* Custom Checkbox Styling - Alpine Professional */
.form-check-input:checked {
    background-color: #2E8B57;
    border-color: #2E8B57;
}

/* ==================== Accessibility ==================== */

/* Focus visible for keyboard navigation */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
.form-check-input:focus,
.form-range:focus,
.btn:focus,
.admin-navbar .nav-link:focus-visible,
.btn-login:focus-visible {
    outline: 2px solid var(--bs-primary);
    outline-offset: 2px;
    border-radius: var(--bs-border-radius-sm);
}

/* Skip to main content link */
.skip-to-main,
.skip-to-content {
    position: absolute;
    left: -9999px;
    z-index: 9999;
    padding: 1rem;
    background-color: var(--bs-primary);
    color: white;
    text-decoration: none;
    font-weight: 600;
}

.skip-to-main:focus,
.skip-to-content:focus {
    left: 0;
    top: 0;
}

/* ==================== Responsive Design ==================== */

/* Mobile Filter Toggle Button */
.filter-toggle-mobile {
    display: none;
}

@media (max-width: 992px) {
    .admin-navbar .nav-link {
        font-size: 0.85rem;
        padding: 0.6rem 0.3rem;
    }

    .admin-navbar .nav-link i {
        margin-right: 2px;
    }

    .admin-main {
        padding-top: 160px;
    }

    #filterSidebar .card {
        position: sticky;
        top: 20px;
    }
}

@media (max-width: 991.98px) {
    .filter-toggle-mobile {
        display: inline-block;
        position: fixed;
        bottom: 20px;
        right: 20px;
        z-index: 1000;
        border-radius: 50px;
        padding: 0.75rem 1.5rem;
        box-shadow: 0 4px 12px rgba(28, 35, 49, 0.2);
    }

    #filterSidebar {
        display: none;
        margin-bottom: 2rem;
    }
}

@media (min-width: 992px) {
    .offcanvas-lg {
        display: block !important;
        position: relative !important;
        width: auto !important;
        transform: none !important;
    }

    .filter-toggle-mobile {
        display: none !important;
    }
}

@media (max-width: 768px) {
    .admin-navbar .nav-link {
        font-size: 0.8rem;
        padding: 0.5rem 0.25rem;
    }

    .admin-navbar .nav-link i {
        display: block;
        margin-right: 0;
        margin-bottom: 2px;
    }

    .admin-main {
        padding-top: 180px;
    }

    .hero-container {
        height: 300px;
    }

    .hero-title {
        font-size: 1.8rem;
    }

    .metrics-container {
        gap: 1rem;
    }

    .metric-value {
        font-size: 1rem;
    }

    .metric-icon {
        font-size: 1.2rem;
    }

    .gallery-carousel .carousel-item img {
        height: 300px;
    }

    .trail-cards-container.list-view .trail-card {
        flex-direction: column;
    }

    .trail-cards-container.list-view .trail-card .card-img-top {
        width: 100%;
        height: 200px;
    }

    .region-tree {
        max-height: 200px;
    }

    .welcome-banner {
        padding: 20px;
    }

    .welcome-banner h1 {
        font-size: 1.5rem;
    }

    .dashboard-card {
        margin-bottom: 1rem;
    }
}

@media (max-width: 576px) {
    .hero-container {
        height: 250px;
    }

    .hero-title {
        font-size: 1.5rem;
    }

    .hero-overlay {
        padding: 1rem;
    }

    .metrics-container {
        gap: 0.75rem;
    }

    .property-badges {
        gap: 0.5rem;
    }

    .property-badge {
        padding: 0.4rem 0.8rem;
        font-size: 0.9rem;
    }

    .login-container {
        padding: 10px;
    }

    .login-header {
        padding: 20px;
    }

    .login-header h1 {
        font-size: 20px;
    }

    .login-body {
        padding: 30px 20px;
    }

    .card-icon {
        width: 40px;
        height: 40px;
        font-size: 20px;
    }
}

/* ==================== High Contrast Mode Support ==================== */

@media (prefers-contrast: high) {
    .hero-overlay {
        background: rgba(0, 0, 0, 0.95);
    }

    .carousel-caption {
        background-color: rgba(0, 0, 0, 0.9);
    }

    .admin-navbar .nav-link.active {
        background: #4a5568;
        color: white;
    }

    .welcome-banner {
        background: #4a5568;
    }
}

/* ==================== Reduced Motion Support ==================== */

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    .carousel-item {
        transition: none;
    }

    .gallery-thumbnail,
    .related-trail-card,
    .dashboard-card,
    .admin-navbar .nav-link,
    .btn-login,
    .trail-card,
    .btn,
    .form-check-input {
        transition: none;
    }

    .dashboard-card:hover,
    .trail-card:hover {
        transform: none;
    }
}

/* ==================== Print Styles ==================== */

@media print {
    /* Hide non-essential elements */
    header,
    footer,
    .nav-tabs,
    .carousel-control-prev,
    .carousel-control-next,
    .carousel-indicators,
    .btn,
    #map-container,
    .gallery-thumbnail,
    .admin-navbar,
    .btn-login,
    .welcome-banner {
        display: none !important;
    }

    /* Expand all tabs */
    .tab-pane {
        display: block !important;
        opacity: 1 !important;
    }

    /* Ensure readable colors */
    body {
        color: #000;
        background: #fff;
    }

    /* Page breaks */
    .property-badges,
    .tab-content {
        page-break-inside: avoid;
    }

    /* Images */
    img {
        max-width: 100%;
        page-break-inside: avoid;
    }

    .admin-main {
        margin-left: 0;
        padding-top: 0;
    }

    .dashboard-card {
        box-shadow: none;
        border: 1px solid #ddd;
        page-break-inside: avoid;
    }
}
