/* Global app styles. Visual styling is handled by MudBlazor + the central MudTheme
   (see Theme/AppTheme.cs). Keep this file minimal — only framework-level error UI lives here. */

html, body {
    margin: 0;
}

h1:focus {
    outline: none;
}

/* Auth forms (Login / Register) run as static SSR, so they use Blazor InputText for
   reliable form posting rather than MudBlazor inputs. These classes give them a clean
   look that matches the MudBlazor theme via its CSS variables. */
.auth-field {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    margin-bottom: 1rem;
}

.auth-label {
    font-size: 0.85rem;
    color: var(--mud-palette-text-secondary);
}

.auth-input {
    width: 100%;
    padding: 0.75rem 0.9rem;
    font-size: 1rem;
    font-family: inherit;
    color: var(--mud-palette-text-primary);
    background: var(--mud-palette-surface);
    border: 1px solid var(--mud-palette-lines-inputs, rgba(0, 0, 0, 0.3));
    border-radius: var(--mud-default-borderradius, 8px);
    box-sizing: border-box;
    outline: none;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.auth-input:focus {
    border-color: var(--mud-palette-primary);
    box-shadow: 0 0 0 1px var(--mud-palette-primary);
}

.auth-input.invalid {
    border-color: var(--mud-palette-error);
}

.auth-validation {
    color: var(--mud-palette-error);
    font-size: 0.8rem;
}

.auth-check {
    flex-direction: row;
    align-items: center;
    gap: 0.5rem;
}

.radio-option {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.4rem 0;
    cursor: pointer;
    color: var(--mud-palette-text-primary);
}

/* Venue card thumbnail area (placeholder until photo upload lands). */
.venue-thumb {
    height: 160px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--mud-palette-primary) 0%, var(--mud-palette-secondary) 100%);
    color: #fff;
    overflow: hidden;
}

.venue-thumb .mud-icon-root {
    font-size: 3.5rem;
    opacity: 0.85;
}

.venue-thumb-img {
    width: 100%;
    height: 100%;
}

/* Honeypot field — present in the DOM but hidden from humans. */
.hp-field {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

/* Site footer. */
.app-footer {
    border-top: 1px solid var(--mud-palette-lines-default, rgba(0, 0, 0, 0.12));
    padding: 1.25rem 1rem;
    margin-top: 2rem;
    color: var(--mud-palette-text-secondary);
}

/* Venue detail photo gallery — the whole photo fits (contain) on a neutral frame. */
.venue-gallery-item {
    position: relative;
    height: 340px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #1c1c1c;
}

/* Always-white carousel controls (arrows + bullets) so they stay visible on photos in
   both light and dark mode; the drop-shadow keeps them readable on light images. */
.gallery-carousel,
.gallery-carousel .mud-icon-button {
    color: #fff !important;
}

.gallery-carousel .mud-icon-button {
    filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.6));
}

/* Fullscreen button overlaid on the gallery image (doesn't block carousel arrows). */
.gallery-fullscreen-btn {
    position: absolute;
    top: 8px;
    right: 8px;
    z-index: 2;
    background: rgba(0, 0, 0, 0.5) !important;
    color: #fff !important;
}

/* Full-screen photo viewer dialog. */
.photo-viewer {
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: zoom-out;
}

.photo-viewer-img {
    max-width: 100%;
    max-height: 82vh;
    object-fit: contain;
}

/* Leaflet map container. */
.venue-map {
    height: 280px;
    width: 100%;
    border-radius: 8px;
    z-index: 0;
}

/* Availability calendar day coloring (MudDatePicker AdditionalDateClassesFunc). */
.cal-available {
    background-color: rgba(76, 140, 74, 0.22) !important;
    font-weight: 600;
}

.cal-booked {
    background-color: rgba(192, 57, 43, 0.20) !important;
    text-decoration: line-through;
}

.legend-dot {
    display: inline-block;
    width: 0.8rem;
    height: 0.8rem;
    border-radius: 50%;
    margin-right: 0.3rem;
    vertical-align: middle;
}

.legend-available {
    background-color: rgba(76, 140, 74, 0.6);
}

.legend-booked {
    background-color: rgba(192, 57, 43, 0.6);
}

/* Blazor unhandled-error boundary (rendered by the framework). */
.blazor-error-boundary {
    background: #b32121;
    padding: 1rem 1rem 1rem 3.7rem;
    color: white;
}

    .blazor-error-boundary::after {
        content: "An error has occurred.";
    }

/* Circuit-level error UI shown by MainLayout when the SignalR connection drops. */
#blazor-error-ui {
    color-scheme: light only;
    background: #ffefc1;
    bottom: 0;
    box-shadow: 0 -1px 2px rgba(0, 0, 0, 0.2);
    box-sizing: border-box;
    display: none;
    left: 0;
    padding: 0.6rem 1.25rem 0.7rem 1.25rem;
    position: fixed;
    width: 100%;
    z-index: 1500;
}

    #blazor-error-ui .dismiss {
        cursor: pointer;
        position: absolute;
        right: 0.75rem;
        top: 0.5rem;
    }

/* Notification bell dropdown and notifications list. */
.notif-panel {
    min-width: 340px;
    max-width: 400px;
}

.notif-item {
    white-space: normal;
}

.notif-msg {
    white-space: normal;
    opacity: 0.85;
}

.notif-unread {
    border-left: 3px solid var(--mud-palette-primary);
    padding-left: 8px;
}

.notif-row {
    cursor: pointer;
    transition: background-color 0.15s ease;
}

    .notif-row:hover {
        background-color: var(--mud-palette-action-default-hover);
    }
