.mud-root, .mud-typography {
    font-family: 'Inter', Helvetica, Arial, sans-serif !important;
}


.validation-message {
    color: red;
}

/* --- Add Photos surfaces (ImageGrid web) --- */
.add-photos-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
}

@media (min-width: 600px) {
    .add-photos-grid {
        grid-template-columns: 1fr 1fr;
    }
}

.add-photo-tile {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 20px 16px;
    border-radius: 12px;
    border-style: dashed !important;
    cursor: pointer;
    transition: background-color 0.15s ease, border-color 0.15s ease;
    min-height: 120px;
    overflow: hidden;
}

.add-photo-tile:hover {
    background-color: var(--mud-palette-action-default-hover);
    border-color: var(--mud-palette-primary) !important;
}

.add-photo-tile-icon {
    font-size: 32px !important;
    margin-bottom: 6px;
}

.add-photo-tile-disabled {
    opacity: 0.5;
    pointer-events: none;
}

/* Transparent click target overlay — used for both the <input type="file">
   (drops + click) on the device tile and a <button> on the Google Photos tile.
   Symmetric pattern: the overlay fills the tile, clicks land reliably. */
.add-photo-tile-overlay {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
    border: none;
    padding: 0;
    background: transparent;
    font: inherit;
    color: inherit;
}

.add-photo-tile-overlay:disabled {
    cursor: not-allowed;
}

/* When .add-photo-tile is a <button>, reset native button chrome so it matches the div tile. */
.add-photo-tile-button {
    appearance: none;
    -webkit-appearance: none;
    width: 100%;
    background: transparent;
    color: inherit;
    font: inherit;
}

.add-photo-tile-button:disabled {
    cursor: not-allowed;
}

/* Subtle tint + primary border so the tile clearly says "I'll accept this"
   without the visual weight of a full error/warning colour. */
.add-photo-tile-dragover {
    background-color: rgba(230, 57, 70, 0.06);
    border-color: var(--mud-palette-primary) !important;
}

#blazor-error-ui {
    background: #D62828;
    color: #F1FAEE;
    bottom: 0;
    box-shadow: 0 -2px 8px rgba(0, 0, 0, 0.3);
    box-sizing: border-box;
    display: none;
    left: 0;
    padding: 0.75rem 3rem 0.75rem 1.25rem;
    position: fixed;
    width: 100%;
    z-index: 1000;
    font-family: 'Inter', Helvetica, Arial, sans-serif;
    font-size: 0.95rem;
}

    #blazor-error-ui a.reload {
        color: #F1FAEE;
        font-weight: 600;
        text-decoration: underline;
        margin-left: 0.5rem;
    }

    #blazor-error-ui .dismiss {
        cursor: pointer;
        position: absolute;
        right: 1rem;
        top: 50%;
        transform: translateY(-50%);
        opacity: 0.8;
    }

    #blazor-error-ui .dismiss:hover {
        opacity: 1;
    }

.blazor-error-boundary {
    background: #fef2f2;
    border: 1px solid #D62828;
    border-radius: 4px;
    padding: 1.5rem 1.5rem 1.5rem 3.5rem;
    color: #264653;
    position: relative;
}

    .blazor-error-boundary::before {
        content: "⚠";
        position: absolute;
        left: 1rem;
        top: 1.4rem;
        font-size: 1.5rem;
        color: #D62828;
    }

    .blazor-error-boundary::after {
        content: "An error occurred in this section.";
        display: block;
        font-weight: 600;
    }

/* Initial app splash — shown before the Blazor WASM bundle has loaded.
   Plain HTML/CSS only; no Blazor available yet. */
.initial-splash {
    min-height: 100dvh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 16px;
    background-color: #FDE3CA;
    font-family: 'Inter', Helvetica, Arial, sans-serif;
    text-align: center;
}

.initial-splash-logo {
    font-size: 2rem;
    font-weight: 600;
    color: #E63946;
    letter-spacing: -0.02em;
}

.initial-splash-bar {
    width: 240px;
    max-width: 60vw;
    height: 3px;
    background-color: rgba(230, 57, 70, 0.18);
    border-radius: 2px;
    overflow: hidden;
}

.initial-splash-bar-track {
    width: 40%;
    height: 100%;
    background-color: #E63946;
    border-radius: 2px;
    animation: initial-splash-slide 1.4s ease-in-out infinite;
}

@keyframes initial-splash-slide {
    0%   { transform: translateX(-100%); }
    100% { transform: translateX(350%); }
}

.initial-splash-message {
    font-size: 0.95rem;
    color: #264653;
}

code {
    color: #c02d76;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
    color: var(--bs-secondary-color);
    text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
    text-align: start;
}

/* Loader bar — sits flush at the bottom of the MudAppBar.
   MudAppBar visually is 56px tall on mobile and 64px on >=600px viewports,
   so we pin the loader to those literal heights rather than --mud-appbar-height
   (which is always 64px and doesn't track the responsive bar height). */
.loader-bar {
    position: fixed !important;
    top: 56px;
    left: 0;
    width: 100% !important;
    z-index: 1050;
}

@media (min-width: 600px) {
    .loader-bar {
        top: 64px;
    }
}
