﻿body {
    font-family: "Montserrat", sans-serif;
}

.app-bar {
    opacity: 0.94;
}

/* "Back" FAB on every page - the one place that controls its look (opaque white, black arrow) */
.back-fab,
.back-fab:hover,
.back-fab:focus-visible,
.back-fab:active {
    background-color: #fff;
    color: #000;
}

.nav-drawer.mud-drawer {
    background-color: color-mix(in srgb, var(--mud-palette-drawer-background) 88%, transparent);
    backdrop-filter: blur(6px);
}

/* top-bar dropdowns must render above the (clipped) nav drawer */
.mud-popover-provider > .mud-popover.mud-popover-open {
    z-index: 1500 !important;
}

.center-elements {
    display: grid;
    place-items: center;
}

.to-the-right {
    display: flex;
    justify-content: flex-end;
}

.tin-form {
    width: 295px;
    margin: auto;
}


.medium-form {
    width: 350px;
    margin: auto;
}

.medium-wide-form {
    width: 440px;
    margin: auto;
}
.wide-form {
    width: 520px;
    margin: auto;
}
.extra-wide-form {
    width: 550px;
    margin: auto;
}
.extra-extra-wide-form {
    width: 750px;
    margin: auto;
}

.movement-grid-el {
    padding: 8px 14px;
    text-align: center;
    font-size: 13px;
    border-bottom: 1px solid #e0e0e0;
    min-height: 60px;
    border-radius: 12px;
    background-color: #f8f9fa;
    display: flex;
    flex-direction: column;
    justify-content: center;
    cursor: pointer;
}
.movement-grid-el:hover {
    background: linear-gradient(to right, #dde8f4, #a8c2d8);
}

.movement-card {
    display: flex;
    align-items: center;
    gap: 16px;
    background: #f8f9fa;
    border-radius: 12px;
    padding: 12px 16px;
    min-height: 68px;
    cursor: pointer;
    transition: background 0.2s ease;
    border-bottom: 1px solid #e0e0e0;
}

.movement-card:hover {
    background: linear-gradient(to right, #dde8f4, #a8c2d8);
}

.movement-card-text {
    flex: 9;
    text-align: center;
    font-size: 13px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.movement-card-desc {
    font-size: 12px;
    color: #888;
}

.movement-card-img {
    flex: 10;
    display: flex;
    justify-content: center;
    align-items: center;
}

.movement-thumb {
    width: 100%;
    max-width: 100px;
    height: unset;
}

.movement-grid-compact {
    padding: 8px;
    text-align: center;
    font-size: 13px;
    border-radius: 12px;
    background-color: #f8f9fa;
    display: flex;
    flex-direction: column;
    align-items: center;
    cursor: pointer;
}

.movement-grid-compact:hover {
    background: linear-gradient(to right, #dde8f4, #a8c2d8);
}

.movements-container {
    display: grid;
    place-items: center;
}

.poll-el {
    background-color: #dd89892e;
    box-shadow: var(--mud-elevation-1);
    margin-top: 10px;
    padding: 10px;
}
    .poll-el:hover {
        background-color: navajowhite;
        padding: -7px;
    }


    .index-page-bg {
        position: relative;
    }

        .index-page-bg::before {
            content: "";
            position: fixed;
            inset: 0;
            z-index: 14;
            pointer-events: none;
            background-image: url("/images/897fe5cf-2f2c-4cbf-b5cb-bc3ebd762a38.svg");
            background-repeat: no-repeat;
            background-position: bottom left;
            background-size: min(141px, 20vw);
            opacity: 0.61;
        }


    .center-div {
        display: grid;
        place-items: center;
    }


    .grid-my-movements {
        padding-top: 5px;
        padding-bottom: 5px;
        text-align: center;
        font-size: 13px;
        border-bottom: 1px solid @Colors.Red.Lighten2.ToString();
        Height: 110px;
    }

        .grid-my-movements:hover {
            background-color: @Colors.DeepOrange.Darken3.ToString();
            color: @Colors.Red.Lighten2.ToString();
            padding: 5px;
        }

    .form-labels {
        text-align: center;
    }

    .search-form {
        width: 350px;
        margin: auto;
    }


/* Nav menu: ikona po lewej, wyrównana w pionie z tekstem */
.mud-nav-link { flex-direction: row; justify-content: flex-start !important; align-items: center !important; }
.mud-nav-link .mud-nav-link-icon { margin-inline-start: 0; margin-inline-end: 12px; }
.mud-nav-link .mud-nav-link-text { display: flex; align-items: center; flex: 0 1 auto; }
.mud-nav-link .mud-nav-link-text > span { line-height: 1; }

.top-banner-title {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    max-width: calc(100% - 320px);
    text-align: center;
    pointer-events: none;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Mobile: title sits on the left and takes all free space; right-side buttons stay put. */
@media (max-width: 599.98px) {
    .top-banner-title {
        position: static;
        transform: none;
        flex: 1000 1 0;
        max-width: none;
        text-align: left;
        pointer-events: auto;
        font-size: 1.05rem;
        line-height: 1.2;
        white-space: normal;
        display: -webkit-box;
        -webkit-box-orient: vertical;
        -webkit-line-clamp: 2;
    }
}

/* Members page: back button + narrow table side by side */
.members-layout {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    gap: 0;
    padding: 33px 8px 0;
}

/* back button floats over the table's toolbar row (saves width) */
.members-layout > .mud-tooltip-root {
    flex: 0 0 auto;
    position: relative;
    z-index: 2;
}

.members-col {
    flex: 0 1 420px;
    min-width: 0;
    margin-left: -56px; /* overlap back button (Fab Large = 56px) */
}

/* search field must stay clear of the back button */
.mud-table.members-table .mud-table-toolbar {
    padding-left: 64px;
}

.mud-table.members-table .mud-table-toolbar .mud-input-control {
    flex: 0 1 200px;
    min-width: 0;
}

.mud-table.members-table .members-center {
    text-align: center;
}

.mud-table.members-table .members-weight {
    display: flex;
    align-items: center;
    justify-content: center;
}

.mud-table.members-table .members-weight .mud-input-control {
    margin: 0;
}

.mud-table.members-table .members-weight-input {
    flex: none;
    width: 100px; /* 83px +20% */
}

.mud-table.members-table.members-mobile .members-weight-input {
    width: 71px; /* 59px +20% */
}

.mud-table.members-table .members-weight-input .mud-input {
    width: 100%;
}

.mud-table.members-table .members-weight-input input {
    text-align: center;
}

.mud-table.members-table .members-center .mud-input-control-boolean-input .mud-input-control-input-container {
    display: flex;
    justify-content: center;
}

.mud-table.members-table .members-center .mud-checkbox {
    margin: 0;
    justify-content: center;
}

.members-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 4px 16px;
    margin-top: 8px;
    font-size: 0.75rem;
}

.members-legend-item {
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.members-col-wide {
    flex-basis: 600px;
}

.mud-table.members-table .mud-table-cell {
    padding: 4px 6px;
    font-size: 0.8rem;
    line-height: 1.2;
    white-space: nowrap;
}

/* columns that do not fit move to a per-row dropdown (Members.razor); label next to each control */
.members-menu .members-menu-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 4px 12px;
    font-size: 0.8rem;
    white-space: nowrap;
}

.members-menu .members-menu-ctl {
    display: flex;
    align-items: center;
}

.members-menu .members-weight {
    display: flex;
    align-items: center;
}

.members-menu .members-weight .mud-input-control {
    margin: 0;
}

.members-menu .members-weight-input {
    flex: none;
    width: 100px;
}

.members-menu .members-weight-input input {
    text-align: center;
}

.mud-table.members-table.members-mobile .mud-table-cell {
    padding: 4px 4px;
    font-size: 0.75rem;
}

.guest-footer {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 10;
    padding: 8px 16px;
    background: var(--mud-palette-surface);
    border-top: 1px solid var(--mud-palette-lines-default);
    font-size: 0.875rem;
}

/* guest pages: footer floats at the bottom of the viewport; padding keeps the last content line reachable */
.guest-main {
    padding-bottom: 96px;
}
