body {
    font-family: 'Montserrat', Arial, sans-serif;
    background: #f7f8fa;
    color: #222;
    margin: 0;
    padding: 0;
    height: 100vh;
    overflow: hidden;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
}

@font-face {
    font-family: 'Montserrat';
    src: url('/fonts/Montserrat-Regular.ttf') format('truetype');
    font-style: normal;
}

footer {
    display: none;
}

header {
    background: #495057;
    color: #fff;
    padding: 0;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
    height: 50px;
    display: flex;
    align-items: center;
}

#budgetPercent {
    width: 180px;
    accent-color: #1976d2;
    border-radius: 6px;
    height: 6px;
    background: linear-gradient(90deg, #1976d2 0%, #90caf9 100%);
    outline: none;
}

#budgetPercentValue {
    background: #1976d2;
    color: #fff;
    padding: 0.2em 0.7em;
    border-radius: 12px;
    font-weight: 600;
    min-width: 40px;
    display: inline-block;
    text-align: center;
    font-size: 1.1em;
    letter-spacing: 1px;
}
header h1 {
    font-size: 1.6rem;
    font-weight: 700;
    margin: 0;
    letter-spacing: 1.5px;
}

/* Header Navigation Styles - Enhanced for better UX */
.header-navigation {
    margin: 0;
    position: relative;
}

.header-nav-menu {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    gap: 0.5rem;
    position: relative;
}

/* Progress line connecting steps - REMOVED as requested */

.header-nav-menu li {
    margin: 0;
    position: relative;
    z-index: 2;
}

.header-nav-menu a {
    display: block;
    color: #fff;
    text-decoration: none;
    transition: all 0.3s ease;
    opacity: 0.7;
    position: relative;
}

.header-nav-menu a:hover {
    opacity: 1;
    transform: translateY(-2px);
}

.header-nav-menu a.active {
    opacity: 1;
}

.header-nav-menu a.completed {
    opacity: 0.9;
}

.nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    transition: all 0.3s ease;
    min-width: 50px;
    position: relative;
}

.header-nav-menu a:hover .nav-item {
    background-color: rgba(255, 255, 255, 0.15);
    transform: scale(1.05);
}

.header-nav-menu a.active .nav-item {
    background-color: rgba(255, 255, 255, 0.2);
    box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.3);
}

.header-nav-menu a.completed .nav-item {
    background-color: rgba(40, 167, 69, 0.2);
}

.step-number {
    display: inline-block;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.2);
    color: #fff;
    text-align: center;
    line-height: 20px;
    margin-bottom: 0.2rem;
    font-weight: 700;
    font-size: 0.6rem;
    transition: all 0.3s ease;
    border: 2px solid transparent;
    position: relative;
    z-index: 3;
}

.header-nav-menu a:hover .step-number {
    background-color: rgba(255, 255, 255, 0.3);
    transform: scale(1.1);
}

.header-nav-menu a.active .step-number {
    background-color: #fff;
    color: #495057;
    border-color: #fff;
    box-shadow: 0 0 10px rgba(255, 255, 255, 0.5);
}

.header-nav-menu a.completed .step-number {
    background-color: #28a745;
    color: #fff;
    border-color: #28a745;
}

/* ...existing code... */

.nav-item span {
    font-size: 0.55rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.2px;
    text-align: center;
    transition: all 0.3s ease;
}

/* ...existing code... */

.header-nav-menu a:hover .nav-item span {
    transform: translateY(-1px);
}

/* Tooltip for navigation items */
.nav-item::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: -35px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.8);
    color: #fff;
    padding: 0.3rem 0.6rem;
    border-radius: 4px;
    font-size: 0.7rem;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    z-index: 1000;
}

.header-nav-menu a:hover .nav-item::after {
    opacity: 1;
}

/* Disabled state for future steps */
.header-nav-menu a.disabled {
    opacity: 0.4;
    pointer-events: none;
    cursor: not-allowed;
}

.header-nav-menu a.disabled .step-number {
    background-color: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.5);
}

/* Progress line simplified - removed conflicting segments and progress line as requested */

main {
    max-width: 520px;
    margin: 1rem auto;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 3px 20px rgba(10,37,64,0.08);
    padding: 1.5rem;
}

form label {
    display: block;
    margin-bottom: 0.15rem;
    font-weight: 600;
    color: #0a2540;
    font-size: 0.7rem;
}

/* Form input styling */
.form-input {
    width: 100%;
    padding: 0.35rem;
    border: 1.5px solid #e0e6ed;
    border-radius: 4px;
    font-size: 0.7rem;
    background: #f7f8fa;
    transition: border 0.2s ease;
    box-sizing: border-box;
    font-family: inherit;
}

.form-input:focus {
    border: 1.5px solid #495057;
    outline: none;
    background: #fff;
}

.form-input::placeholder {
    color: #999;
    font-size: 0.9rem;
}

/* Additional input field polish and accessibility */
.form-input[type="number"] {
    appearance: textfield; /* Standard property */
    -moz-appearance: textfield; /* Firefox */
}

.form-input[type="number"]::-webkit-outer-spin-button,
.form-input[type="number"]::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* Improved focus states */
.form-input:focus,
.radius-input:focus {
    box-shadow: 0 0 0 3px rgba(73, 80, 87, 0.1);
}

/* Better placeholder styling */
.form-input:focus::placeholder {
    color: #bbb;
    opacity: 0.7;
}

/* Input validation states */
.form-input:invalid {
    border-color: #dc3545;
}

/* Remove green valid border - keep default styling */
.form-input:valid {
    border-color: #e0e6ed;
}

/* Disable validation styling until user interacts */
.form-input:not(:focus):not(:placeholder-shown):invalid {
    border-color: #e0e6ed;
}

/* Better typography for form elements */
.form-input,
.radius-input {
    line-height: 1.4;
    letter-spacing: 0.01em;
}

/* Consistent button sizing */
.find-btn,
.refresh-btn {
    line-height: 1.4;
    letter-spacing: 0.01em;
}

/* Form group styling */
.form-group {
    margin-bottom: 0.3rem;
}

.form-label {
    display: block;
    margin-bottom: 0.15rem;
    font-weight: 600;
    color: #0a2540;
    font-size: 0.65rem;
}

/* Location section styling */
.location-section {
    margin-bottom: 0.8rem;
}

.map-container {
    height: 100px;
    margin-bottom: 0.25rem;
    border-radius: 4px;
    border: 1.5px solid #e0e6ed;
}

.section-label {
    display: block;
    margin-bottom: 0.2rem;
    font-weight: 600;
    color: #0a2540;
    font-size: 0.65rem;
}

.location-input-group {
    display: flex;
    gap: 0.3rem;
    margin-bottom: 0.25rem;
}

.location-input-group .form-input {
    flex: 1;
}

.find-btn {
    padding: 0.45rem 0.75rem;
    background: #495057;
    color: #fff;
    border: none;
    border-radius: 6px;
    font-size: 0.75rem;
    cursor: pointer;
    white-space: nowrap;
    font-weight: 600;
    transition: background-color 0.2s ease;
}

.find-btn:hover {
    background: #343a40;
}

.radius-input-group {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.radius-label {
    margin: 0;
    font-size: 0.75rem;
    font-weight: 600;
    color: #0a2540;
}

.radius-input {
    width: 60px;
    padding: 0.35rem;
    border: 1.5px solid #e0e6ed;
    border-radius: 6px;
    font-size: 0.75rem;
    background: #f7f8fa;
    transition: border 0.2s ease;
    text-align: center;
}

.radius-input:focus {
    border: 1.5px solid #495057;
    outline: none;
    background: #fff;
}

.radius-unit {
    font-size: 0.75rem;
    color: #666;
}

/* Refresh button styling */
.refresh-btn {
    width: 100%;
    padding: 0.35rem 0.5rem;
    background: #495057;
    color: #fff;
    border: none;
    border-radius: 4px;
    font-size: 0.65rem;
    cursor: pointer;
    font-weight: 600;
    transition: background-color 0.3s ease;
}

.refresh-btn:hover {
    background: #343a40;
}

button {
    background: #495057;
    color: #fff;
    border: none;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
    box-shadow: 0 2px 8px rgba(30,114,197,0.07);
}

button:hover {
    background: #3a4045;
}

#priceDisplay {
    margin-bottom: 0.5rem;
    font-size: 0.7rem;
    color: #495057;
    font-weight: 600;
    background: #f0f6fc;
    border-radius: 4px;
    padding: 0.35rem 0.5rem;
}

#result {
    margin-top: 0.5rem;
    font-size: 0.7rem;
    color: #0a2540;
    background: #f7f8fa;
    border-radius: 4px;
    padding: 0.5rem 0.4rem;
    box-shadow: 0 1px 4px rgba(30,114,197,0.04);
}

input[type="number"]::-webkit-inner-spin-button,
input[type="number"]::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

footer {
    text-align: center;
    color: #888;
    font-size: 0.95rem;
    padding: 1rem 0 0.3rem 0;
    background: none;
}

/* Base layout reset - ensure no leftover sidebar margins */
.page-wrapper,
.content-wrapper {
    margin: 0;
    padding: 0;
    width: 100%;
    box-sizing: border-box;
}

.page-wrapper {
    height: calc(100vh - 50px); /* Subtract header height */
    overflow-y: auto;
    position: relative;
}

/* Responsive layout for desktop and mobile */

@media (min-width: 1200px) {
    .page-wrapper {
        display: flex;
        max-width: none;
        margin: 0 auto;
        gap: 0;
        padding: 1rem;
        width: 100%;
        min-height: calc(100vh - 70px);
        box-sizing: border-box;
        justify-content: center;
        align-items: flex-start;
    }
    
    /* Sidebar removed - navigation moved to header */
    
    .content-wrapper {
        flex: 1;
        display: flex;
        gap: 1rem;
        padding: 1rem;
        margin: 0;
        width: 95%;
        max-width: 1400px;
        min-height: calc(100vh - 120px);
        box-sizing: border-box;
    }
    
    main {
        display: flex;
        flex-direction: row;
        gap: 1rem;
        max-width: none;
        align-items: stretch;
        margin: 0;
        padding: 0;
        flex: 1;
        background: transparent;
        box-shadow: none;
        width: 100%;
        min-height: 500px;
        box-sizing: border-box;
    }
    
    /* Column 1: Map, Location and Form Inputs (merged) */
    .main-left {
        flex: 1;
        max-width: none;
        background: #fff;
        border-radius: 6px;
        box-shadow: 0 2px 8px rgba(10,37,64,0.04);
        padding: 1rem;
        display: flex;
        flex-direction: column;
        min-height: 500px;
        margin: 0;
        box-sizing: border-box;
    }
    
    /* Column 2: Hide the separate form column since it's merged with main-left */
    .form-column {
        display: none;
    }
    
    /* Column 2: Magazine Selection */
    .magazine-column {
        flex: 1;
        max-width: none;
        background: #fff;
        border-radius: 6px;
        box-shadow: 0 2px 8px rgba(10,37,64,0.04);
        padding: 1rem;
        min-height: 500px;
        display: flex;
        flex-direction: column;
        margin: 0;
        box-sizing: border-box;
    }
    
    /* Column 3: Recommendations */
    .main-right {
        flex: 1;
        max-width: none;
        background: #fff;
        border-radius: 6px;
        box-shadow: 0 2px 8px rgba(10,37,64,0.04);
        padding: 1rem;
        margin: 0;
        min-height: 500px;
        display: flex;
        flex-direction: column;
        box-sizing: border-box;
    }
    
    #magazineGroupsList {
        max-height: none;
        margin-bottom: 0;
        flex: 1;
        background: #f8f9fa;
        border-radius: 8px;
        padding: 1rem;
    }
    
    #result {
        margin-top: 0;
        background: none;
        box-shadow: none;
        padding: 0;
        font-size: 0.9rem;
        flex: 1;
        line-height: 1.4;
    }
    
    #pdfDownloadContainer {
        flex-shrink: 0;
        margin-top: 0.8rem;
        padding-top: 0.8rem;
        border-top: 1px solid #e0e6ed;
    }
}

/* Additional optimizations for four-column layout */
@media (min-width: 1200px) {
    body {
        overflow-x: hidden;
    }
    
    header {
        padding: 0.5rem 0 0.3rem 0;
    }
    
    header h1 {
        font-size: 1.3rem;
    }
    
    /* Optimized styling for all columns */
    .main-left .map-container {
        height: 200px;
        margin-bottom: 0.6rem;
    }
    
    .form-input,
    .radius-input {
        padding: 0.6rem;
        font-size: 0.9rem;
    }
    
    .form-label,
    .section-label {
        font-size: 0.9rem;
        margin-bottom: 0.4rem;
    }
    
    .find-btn,
    .refresh-btn {
        padding: 0.6rem 1rem;
        font-size: 0.9rem;
    }
    
    .form-group {
        margin-bottom: 0.6rem;
    }
    
    /* Magazine selection optimizations */
    #magazineGroupsList h3 {
        font-size: 1rem;
        margin-bottom: 0.6rem;
    }
    
    .magazine-group-item {
        margin-bottom: 0.4rem;
        padding: 0.6rem;
        font-size: 0.85rem;
    }
    
    .magazine-group-label {
        font-size: 0.85rem;
        line-height: 1.3;
    }
    
    .magazine-group-checkbox {
        margin-right: 0.6rem;
    }
    
    /* Recommendations optimizations */
    #result {
        font-size: 0.9rem;
        line-height: 1.4;
    }
    
    #result h3 {
        font-size: 1rem;
        margin-bottom: 0.6rem;
    }
    
    #result h4 {
        font-size: 0.9rem;
        margin: 0 0 0.4rem 0;
    }
    
    #pdfDownloadContainer button {
        padding: 0.6rem 1rem;
        font-size: 0.9rem;
    }
}

@media (min-width: 1400px) {
    .page-wrapper {
        max-width: 1800px;
        padding: 0 3rem;
    }
    
    .content-wrapper {
        gap: 2rem;
        padding: 2rem 0;
    }
    
    main {
        gap: 2rem;
    }
    
    .main-left {
        max-width: 400px;
        padding: 2rem;
    }
    
    .form-column {
        max-width: 380px;
        padding: 2rem;
    }
    
    .magazine-column {
        max-width: 450px;
        padding: 2rem;
    }
    
    .main-right {
        max-width: 500px;
        padding: 2rem;
    }
}

/* Enhanced styling for wider columns */
@media (min-width: 1200px) {
    /* Larger map for better visibility */
    .map-container {
        min-height: 240px;
    }
    
    /* Better font sizes for larger columns */
    .form-input,
    .radius-input {
        font-size: 0.95rem;
        padding: 0.7rem;
    }
    
    .form-label,
    .section-label {
        font-size: 0.95rem;
        font-weight: 600;
    }
    
    .magazine-group-item {
        padding: 0.7rem 0.9rem;
        font-size: 0.9rem;
    }
    
    #result {
        font-size: 0.9rem;
        line-height: 1.4;
    }
    
    .find-btn,
    .refresh-btn {
        padding: 0.7rem 1rem;
        font-size: 0.9rem;
        font-weight: 600;
    }
}

/* Mobile and smaller screen responsive styles */
@media (max-width: 1199px) {
    body {
        overflow-x: hidden;
        overflow-y: auto;
    }
    
    .page-wrapper {
        padding: 1rem;
        width: 100%;
        min-height: calc(100vh - 70px);
        box-sizing: border-box;
    }
    
    .content-wrapper {
        width: 100%;
        padding: 0;
        margin: 0;
        display: block;
    }
    
    main {
        display: block;
        max-width: 600px;
        margin: 0 auto;
        padding: 1rem;
        background: #fff;
        border-radius: 8px;
        box-shadow: 0 2px 12px rgba(0,0,0,0.1);
    }
    
    .main-left,
    .magazine-column,
    .main-right {
        width: 100%;
        margin-bottom: 1rem;
        background: #f8f9fa;
        border-radius: 6px;
        padding: 1rem;
        box-shadow: none;
    }
    
    /* Header navigation adjustments for mobile */
    .header-nav-menu {
        gap: 0.25rem;
    }
    
    .nav-item span {
        font-size: 0.5rem;
    }
    
    .step-number {
        width: 18px;
        height: 18px;
        line-height: 18px;
        font-size: 0.55rem;
    }
}

/* Page content styling for intro and signpost pages */
.page-content {
    max-width: 800px;
    margin: 0 auto;
    padding: 1.5rem;
    background: #fff;
    border-radius: 6px;
    box-shadow: 0 2px 8px rgba(10,37,64,0.04);
    line-height: 1.5;
    font-size: 0.9rem;
}

.page-content h2 {
    color: #495057;
    margin-bottom: 1.2rem;
    font-size: 1.4rem;
    font-weight: 700;
}

.page-content h3 {
    color: #495057;
    margin: 1.2rem 0 0.8rem 0;
    font-size: 1.1rem;
    font-weight: 600;
}

.page-content h4 {
    color: #495057;
    margin: 0.8rem 0 0.5rem 0;
    font-size: 0.95rem;
    font-weight: 600;
}

.page-content p {
    margin: 0.7rem 0;
    font-size: 0.85rem;
    line-height: 1.5;
}

.page-content ul, .page-content ol {
    margin: 0.7rem 0;
    padding-left: 1.5rem;
}

.page-content li {
    margin: 0.4rem 0;
    font-size: 0.85rem;
    line-height: 1.5;
}

/* Navigation buttons */
.page-navigation {
    display: flex;
    justify-content: space-between;
    margin-top: 1.5rem;
    gap: 1rem;
}

.nav-button {
    display: inline-block;
    padding: 0.7rem 1.2rem;
    text-decoration: none;
    border-radius: 4px;
    font-weight: 600;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    font-size: 0.85rem;
}

.nav-button.primary {
    background: #495057;
    color: #fff;
}

.nav-button.primary:hover {
    background: #343a40;
    transform: translateY(-1px);
}

.nav-button.secondary {
    background: #f8f9fa;
    color: #495057;
    border: 1px solid #dee2e6;
}

.nav-button.secondary:hover {
    background: #e9ecef;
    transform: translateY(-1px);
}

@media (max-width: 768px) {
    .page-navigation {
        flex-direction: column;
    }
    
    .nav-button {
        text-align: center;
        width: 100%;
        font-size: 0.8rem;
        padding: 0.6rem 1rem;
    }
    
    .page-content {
        padding: 1.2rem;
        font-size: 0.85rem;
    }
    
    .page-content h2 {
        font-size: 1.2rem;
    }
    
    .page-content h3 {
        font-size: 1rem;
    }
    
    .page-content h4 {
        font-size: 0.9rem;
    }
}

/* Progress breadcrumb for mobile */
@media (max-width: 768px) {
    .header-nav-menu {
        gap: 0.3rem;
    }
    
    .header-nav-menu::before {
        margin: 0 40px;
    }
    
    .nav-item {
        padding: 0.4rem 0.6rem;
        min-width: 60px;
    }
    
    .nav-item span {
        font-size: 0.65rem;
    }
    
    .step-number {
        width: 24px;
        height: 24px;
        line-height: 24px;
        font-size: 0.8rem;
    }
}

/* Package selection styling */
.package-row {
    transition: all 0.2s ease !important;
}

.package-row:hover {
    background-color: #f8f9fa !important;
    transform: translateX(2px);
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.package-row.selected {
    background: #e8f5e8 !important;
    border-left: 4px solid #28a745 !important;
}

.package-row.selected:hover {
    background: #d4edda !important;
}

.package-checkbox {
    transform: scale(1.2);
    accent-color: #28a745;
    cursor: pointer;
    margin: 0;
}

.package-checkbox:hover {
    transform: scale(1.3);
}

.selection-summary {
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Package selection styles */
.package-option {
    transition: all 0.2s ease !important;
    cursor: pointer;
    position: relative;
}

.package-option:not(.selected) {
    /* Ensure default styling is maintained for unselected packages */
    border: 1px solid #ddd !important;
    background: #f8f9fa !important;
    box-shadow: none !important;
    transform: none !important;
}

.package-option:hover:not(.selected) {
    transform: scale(1.02) !important;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15) !important;
}

.package-option.selected {
    border: 3px solid #007bff !important;
    box-shadow: 0 0 10px rgba(0,123,255,0.3) !important;
    background: #e3f2fd !important;
    transform: none !important;
}

.package-option.selected:hover {
    transform: scale(1.02) !important;
    box-shadow: 0 0 15px rgba(0,123,255,0.5) !important;
    cursor: pointer;
}

.selection-indicator {
    display: inline-block;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateX(-10px); }
    to { opacity: 1; transform: translateX(0); }
}

.selected-package-summary {
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Full width utilization for all screen sizes */
@media (min-width: 1400px) {
    .page-wrapper {
        padding: 0 0 0 1.5rem;
    }
    
    .content-wrapper {
        gap: 1.5rem;
    }
    
    main {
        gap: 1.5rem;
    }
    
    .main-left,
    .magazine-column,
    .main-right {
        width: calc(33.333% - 1rem);
    }
}

@media (min-width: 1800px) {
    .page-wrapper {
        padding: 0 0 0 2rem;
    }
    
    .content-wrapper {
        gap: 2rem;
    }
    
    main {
        gap: 2rem;
    }
    
    .main-left,
    .magazine-column,
    .main-right {
        width: calc(33.333% - 1.33rem);
    }
}

/* Skeleton Loading Styles */
.skeleton {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
    border-radius: 4px;
}

@keyframes loading {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}

.skeleton-container {
    padding: 1rem;
    background: #fff;
    border-radius: 6px;
    box-shadow: 0 2px 8px rgba(10,37,64,0.04);
}

.skeleton-map {
    width: 100%;
    height: 200px;
    margin-bottom: 1rem;
    border-radius: 6px;
}

.skeleton-input {
    width: 100%;
    height: 2rem;
    margin-bottom: 0.8rem;
    border-radius: 4px;
}

.skeleton-input.small {
    width: 60%;
    height: 1.5rem;
}

.skeleton-button {
    width: 80px;
    height: 2rem;
    border-radius: 4px;
    margin-top: 0.5rem;
}

.skeleton-text {
    height: 1rem;
    margin-bottom: 0.5rem;
    border-radius: 4px;
}

.skeleton-text.title {
    width: 70%;
    height: 1.5rem;
    margin-bottom: 1rem;
}

.skeleton-text.line {
    width: 100%;
    margin-bottom: 0.8rem;
}

.skeleton-text.short {
    width: 60%;
}

.skeleton-card {
    background: #f8f9fa;
    border-radius: 6px;
    padding: 1rem;
    margin-bottom: 0.8rem;
}

.skeleton-card-title {
    width: 80%;
    height: 1.2rem;
    margin-bottom: 0.8rem;
    border-radius: 4px;
}

.skeleton-card-content {
    width: 100%;
    height: 0.8rem;
    margin-bottom: 0.5rem;
    border-radius: 4px;
}

.skeleton-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1rem;
    margin-bottom: 1rem;
}

/* Hide skeleton when content is loaded */
.content-loaded .skeleton-container {
    display: none;
}

/* Show actual content only when loaded */
.main-left > *:not(.skeleton-container),
.magazine-column > *:not(.skeleton-container),
.main-right > *:not(.skeleton-container) {
    opacity: 0;
    transition: opacity 0.3s ease;
}

.content-loaded .main-left > *:not(.skeleton-container),
.content-loaded .magazine-column > *:not(.skeleton-container),
.content-loaded .main-right > *:not(.skeleton-container) {
    opacity: 1;
}

/* Skeleton specific to magazine column */
.skeleton-magazine-group {
    background: #f8f9fa;
    border-radius: 6px;
    padding: 0.8rem;
    margin-bottom: 0.6rem;
}

.skeleton-magazine-header {
    width: 70%;
    height: 1rem;
    margin-bottom: 0.6rem;
    border-radius: 4px;
}

.skeleton-magazine-item {
    width: 90%;
    height: 0.8rem;
    margin-bottom: 0.4rem;
    border-radius: 4px;
}

/* Skeleton for results column */
.skeleton-result-header {
    width: 60%;
    height: 1.5rem;
    margin-bottom: 1rem;
    border-radius: 4px;
}

.skeleton-result-section {
    margin-bottom: 1.5rem;
}

.skeleton-result-item {
    width: 100%;
    height: 1rem;
    margin-bottom: 0.6rem;
    border-radius: 4px;
}

/* Skeleton loading for content pages (intro, signpost) */
.page-content .skeleton-container {
    padding: 0;
    background: transparent;
    border-radius: 0;
    box-shadow: none;
    margin: 0;
}

.actual-content {
    opacity: 1;
    visibility: visible;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

/* Ensure skeleton buttons match navigation button styles */
.skeleton-container .skeleton-button {
    height: 2.5rem;
    border-radius: 4px;
}

/* Content page specific skeleton cards */
.skeleton-container .skeleton-card {
    background: #f8f9fa;
    border-radius: 6px;
    padding: 1.2rem;
    margin-bottom: 1rem;
    border-left: 3px solid #e9ecef;
}

.skeleton-container .skeleton-card:nth-child(3) {
    border-left-color: #1976d2;
}

.skeleton-container .skeleton-card:nth-child(4) {
    border-left-color: #28a745;
}

/* Mobile responsive skeleton for content pages */
@media (max-width: 768px) {
    .page-content .skeleton-container {
        padding: 0;
        margin: 0;
    }
    
    .skeleton-container .skeleton-card {
        padding: 1rem;
    }
    
    .skeleton-container .skeleton-button {
        height: 2rem;
        width: 100% !important;
        margin-bottom: 0.5rem;
    }
    
    .skeleton-container .skeleton-text.title {
        width: 90%;
    }
}

