.body-container {
    padding: 16px; /* Inner spacing */
    margin: 0px auto; /* Space outside and center alignment */
    max-width: 1200px; /* Ensure consistent width */
    background-color: #ffffff; /* White background */
    box-sizing: border-box; /* Include padding in the width calculation */
    border-radius: 0px !important;
}
.mud-appbar,
.mud-appbar .mud-paper,
.mud-appbar-inner {
    border-radius: 0px !important;
}

/* Minimal spacing between checkboxes */
.tight-checkbox-container {
    display: block; /* Ensure each checkbox is on its own line */
    margin-bottom: 8px; /* Add a small gap between checkboxes */
}

.no-margin {
    margin: 0;
}
.tight-checkbox .mud-input-control {
    margin-bottom: 4px !important; /* Reduce bottom margin between checkboxes */
}
.mud-menu .mud-menu-list {
    width: 300px !important; /* Optional: Adjust width if needed */
    padding: 8px 0 !important; /* Optional: Adjust padding */
}

    .mud-menu .mud-menu-list .mud-menu-item {
        padding: 8px 16px !important; /* Optional: Adjust item padding */
        white-space: nowrap !important; /* Optional: Ensure no wrapping */
    }

/* Ensure input fields have a minimum font size to prevent auto-zoom on iOS */
.numeric-input input[type="number"] {
    font-size: 16px !important;
}

/* Optional: Ensure the input field doesn't shrink too small in dense tables */
.mud-table .mud-table-cell .numeric-input input {
    font-size: 16px !important;
}

/* Reduce padding in the dialog content to maximize table width */
.mud-dialog-content {
    padding: 8px !important; /* Reduce padding to give more space to the table */
}

/* Ensure the table doesn't overflow */
.scrollable-table.scoring-table {
    width: 100% !important;
    overflow-x: hidden !important; /* Prevent horizontal scrollbar */
}

/* Adjust numeric fields to prevent excessive width */
.mud-numeric-field {
    min-width: 80px !important;
    max-width: 120px !important;
}
/* Adjust spacing for MudGrid if it's causing extra space */
.mud-grid {
    gap: 0.25rem !important; /* Reduce grid gap */
}
.centered-text {
    text-align: center; /* Center-aligns the text inside the input */
}

/* Ensure consistent alignment for amount field with adornments */
.scoring-table .col-amount .mud-input {
    text-align: right;
}

.scoring-table .col-amount .mud-input-adorned-start .mud-input-field {
    padding-left: 24px; /* Adjust for dollar sign */
}

.scoring-table .col-amount .mud-input-adorned-end .mud-input-field {
    padding-right: 24px; /* Adjust for percentage sign */
}

/* Adjust column widths for the scoring table */
.scoring-table .col-place {
    width: 5% !important; /* Narrower for Place */
}

.scoring-table .col-category {
    width: 25% !important; /* Wider for Category */
}

.scoring-table .col-amount {
    width: 35% !important; /* Narrower for Amount */
}

.scoring-table .col-amount-type {
    width: 25% !important; /* Wider for Amount Type */
}

.scoring-table .col-actions {
    width: 10% !important; /* Keep Actions column narrow */
}
/* Shrink the size of the menu button */
.compact-menu .mud-button-root {
    padding: 0 !important; /* Remove extra padding */
    height: 30px !important; /* Set a smaller height */
    min-height: 30px !important; /* Ensure it doesn't stretch */
    width: 30px !important; /* Optional: Set a fixed width for consistency */
    font-size: 16px !important; /* Adjust icon size */
}

/* Ensure alignment within the table cell */
.compact-menu {
    display: flex;
    justify-content: flex-end;
    align-items: center;
}

/* Shrink the MudMenu popover */
.popup-menu .mud-popover {
    font-size: 0.675rem !important; /* Reduce font size */
    min-width: 60px !important; /* Optional: Adjust width */
    padding: 2px !important; /* Reduce padding inside the menu */
}

/* Adjust individual menu items */
.popup-menu .mud-menu-item {
    padding: 2px 2px !important; /* Tighten padding */
    font-size: 0.675rem !important; /* Match font size with menu */
    min-height: 14px !important; /* Reduce height of menu items */
}

    /* Optional: Hover effect for clarity */
    .popup-menu .mud-menu-item:hover {
        background-color: var(--mud-palette-primary-hover) !important; /* Maintain hover effect */
    }

.bottom-nav-container {
    display: none; /* Hidden by default */
}

.refresh-container {
    display: flex;
    justify-content: space-between; /* Push elements to opposite ends */
    align-items: center;
    width: 100%;
    padding-left: 0 !important;
    margin-left: 0 !important;
}


    .refresh-container .mud-typography {
        margin-left: 0 !important;
        padding-left: 0 !important;
    }


.less-margin-top {
    margin-top: -10px !important; /* Adjust to desired spacing */
}
.custom-active-tab {
    background-color: var(--mud-palette-primary); /* Primary color */
    color: white !important; /* Ensure text is white */
    border: none; /* Remove any existing border */
    box-shadow: none; /* Remove any shadow */
    padding-top: 2px; /* Adjust as needed */
    padding-bottom: 2px; /* Adjust as needed */
    min-height: auto; /* Allow the height to shrink with smaller padding */
}

/* Reduce padding around tab text */
.custom-tabs .mud-tab {
    padding-top: 2px; /* Adjust as needed */
    padding-bottom: 2px; /* Adjust as needed */
    min-height: auto; /* Allow the height to shrink with smaller padding */
    --mud-ripple-offset-x: 0;
    --mud-ripple-offset-y: 0;
}

.custom-tabs .mud-tab-active {
    padding-top: 2px;
    padding-bottom: 2px;
    --mud-ripple-offset-x: 0;
    --mud-ripple-offset-y: 0;
}

.mud-tooltip-root .mud-tooltip-inline .mud-tabs-tabbar-wrapper . {
    margin: 0; /* Remove any margin */
    padding: 0; /* Remove any padding */
    line-height: 0px; /* Reset line height */
    padding-top: 2px;
    padding-bottom: 2px;
    --mud-ripple-offset-x: 0;
    --mud-ripple-offset-y: 0;
}

.mud-tabs-tabbar .mud-tabs-tabbar-inner {
    display: flex;
    min-height: 0px;
}
/* Optionally reduce the tab panel content padding */
/*.custom-tab-panel {
    padding: 4px !important;*/ /* Reduce padding inside the tab panels */
/*}*/
@media (max-width: 600px) {
    .responsive-table {
        max-height: 220px;
        overflow-y: auto;
    }
}

@media (min-width: 601px) {
    .responsive-table {
        max-height: 400px;
        overflow-y: auto;
    }
}

@media (max-width: 600px) {
    .responsive-table-pool {
        max-height: 190px;
        overflow-y: auto;
    }
}

@media (min-width: 601px) {
    .responsive-table-pool {
        max-height: 400px;
        overflow-y: auto;
    }
}

@media (max-width: 600px) {
    .responsive-table-group {
        max-height: 150px;
        overflow-y: auto;
    }
}

@media (min-width: 601px) {
    .responsive-table-group {
        max-height: 400px;
        overflow-y: auto;
    }
}

@media (max-width: 600px) {
    .bottom-nav-container {
        display: flex; /* Show only when the screen width is less than 600px */
        justify-content: space-evenly; /* Evenly distribute the icons */
        position: fixed;
        bottom: 0;
        left: 0;
        width: 100%;
        z-index: 100;
        background-color: #3860B2; /* Ensure the background color matches the top bar */
        padding: 4px 0; /* Reduced padding to make the height smaller (consistent with top MudAppBar) */
    }

    .body-container {
        padding-bottom: 50px; /* Adds space for the bottom navigation to avoid overlap */
    }
}
.subtle-border {
    border: 1px solid #e0e0e0; /* Reduce the border thickness and use a lighter color */
    box-shadow: none; /* Remove any additional shadow around the table */
}

    .subtle-border .mud-table-container {
        border: 1px solid #e0e0e0; /* Inner container border control */
    }

    .subtle-border th,
    .subtle-border td {
        border-bottom: 1px solid #e0e0e0; /* Light and subtle cell border */
    }

    .subtle-border th {
        border-top: none; /* Remove top border from header to reduce visual weight */
    }

    .subtle-border tbody tr:hover {
        background-color: #f5f5f5; /* Optional: Add a light background color for hovered rows */
    }


/* Reduce the height of the tabs */
.small-tab-height .mud-tab {
    height: 36px; /* Adjust this value as needed */
    line-height: 36px; /* Align text vertically */
}

/* Add spacing above the Save/Cancel buttons */
.button-container {
    margin-top: 16px; /* Adjust this value to control spacing */
}

.mud-text-danger {
    color: red;
}

.strikeout {
    text-decoration: line-through;
    color: grey;
}
/* Custom styling for MudTabPanel to reduce height */
.custom-tab-panel {
    padding: 2px !important; /* Adjust padding to reduce height */
    margin: 0 !important; /* Remove any additional margins */
}

/*    .custom-tab-panel .mud-tab-panel-content {
        min-height: unset !important;  Override any minimum height 
        height: auto !important;  Set height to auto for content fit 
    }*/

.team-results-wrapper {
    margin-bottom: 2rem;
    padding: 1rem;
    background-color: #ffffff; /* White background for the paper */
}

.team-row {
    font-weight: bold;
    background-color: #f8f9fa; /* Light grey background for team rows */
}

.team-results-table {
    width: 100%; /* Full width table */
}

    .team-results-table th,
    .team-results-table td {
        text-align: left;
        width: auto; /* Adjust as necessary */
    }
.team-results-wrapper {
    margin-bottom: 2rem;
}

.mud-table-cell-custom-group {
    font-weight: bold;
    background-color: var(--mud-palette-background-gray);
    padding: 0.5rem;
}

/* Reduce padding for table rows */
.mud-table .mud-table-row {
    padding: 0 !important; /* Remove internal padding */
    height: auto !important; /* Allow the row height to shrink */
    min-height: 24px; /* Optional: Set a minimal height */
}

/* Adjust padding for table cells */
.mud-table .mud-table-cell {
    padding: 4px 8px !important; /* Tighten cell padding */
    vertical-align: middle; /* Align content vertically */
}


.mud-table-group-header .mud-table-group-expand {
    background-color: inherit !important; /* Match parent row background */
    width: 5% !important;
    border: none !important; /* Remove any borders */
    padding: 0 !important; /* Remove extra padding */
}

/* Target only the <td> within group header rows (Teams) */
.mud-table-cell-custom-group {
    background-color: var(--mud-palette-background-gray) !important; /* Apply grey background to team rows */
    width: 5% !important; /* Adjust the width */
    padding: 0 !important; /* Remove padding */
    text-align: center; /* Center align the content */
    border: none; /* Remove any borders */
}

/* Ensure the expander button inherits the correct background in team rows */
.mud-table-cell-custom-group .mud-table-row-expander {
    background-color: inherit !important; /* Match the group row background */
    width: 24px !important; /* Match the arrow size */
    height: 24px !important; /* Match the arrow size */
    border-radius: 50%; /* Optional: Make it circular */
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 0 !important; /* Remove button padding */
    margin: 0 auto; /* Center the button */
}

/* Handle any div wrapping the expander button within team rows */
.mud-table-cell-custom-group > div {
    padding: 0 !important;
    margin: 0 auto;
    display: flex;
    justify-content: center;
    align-items: center;
}



/* Smaller font size for team rows */
.team-row-font {
    font-size: 0.85rem; /* Adjust as needed */
    font-weight: bold;
}

/* Box styling for team position */
.team-position-box {
    display: inline-block;
    padding: 4px 8px;
    border: 1px solid #ccc;
    border-radius: 4px;
    margin-right: 8px;
    font-weight: bold;
    font-size: 0.85rem;
    color: #333;
    background-color: #f9f9f9;
}

/* Reduce the size of menu buttons inside the Actions column */
.right-aligned-menu {
    padding: 0 !important; /* Remove padding */
}


@media (max-width: 600px) {
    .hidden-xs {
        display: none !important;
    }

    .visible-xs {
        display: table-cell !important;
    }

    .mobile-reduced-font {
        font-size: 0.875rem !important;
    }

    .mobile-reduced-button .mud-button-label {
        font-size: 0.75rem !important;
    }
}

@media (min-width: 601px) {
    .visible-xs {
        display: none !important;
    }
}
/* Default header font sizes */
.mud-typography-h4.header-text {
    font-size: var(--mud-typography-h4-size) !important;
    font-weight: var(--mud-typography-h4-weight) !important;
    line-height: var(--mud-typography-h4-lineheight) !important;
}

@media (max-width: 600px) {
    .mud-typography-h4.header-text {
        font-size: 1.25rem !important; /* Directly set font size */
        font-weight: 500 !important;
        line-height: 1.6 !important;
    }
}
/* Default: Show desktop button and hide mobile button */
.desktop-button {
    display: inline-flex; /* Ensure it's visible */
}

.mobile-button {
    display: none; /* Hidden by default */
}

/* On smaller screens (<600px): Show mobile button and hide desktop button */
@media (max-width: 600px) {
    .desktop-button {
        display: none; /* Hide desktop button */
    }

    .mobile-button {
        display: inline-flex; /* Show mobile button */
    }
}
/* Right-align the Actions header */
.right-aligned-header {
    text-align: right !important; /* Force right alignment */
}

/* Remove border and right-align the MudMenu */
.borderless-menu {
    border: none !important; /* Remove border */
    text-align: right; /* Align content to the right */
    margin-left: auto; /* Push it to the far right */
}

.right-aligned-menu {
    display: flex; /* Ensures alignment works as expected */
    justify-content: flex-end; /* Right-aligns the content */
}



/* Default: Hide the mobile title and show the desktop title */
.desktop-title {
    display: block;
}

.mobile-title {
    display: none;
}

/* On smaller screens (<600px), swap visibility */
@media (max-width: 600px) {
    .desktop-title {
        display: none; /* Hide the desktop title */
    }

    .mobile-title {
        border: none;
        display: block; /* Show the mobile title */
    }
}



/* Ensure the Name column is left-aligned */
.custom-pool-table .mud-table-cell:first-child,
.custom-group-table .mud-table-cell:first-child {
    text-align: left !important; /* Enforce left alignment */
}

/* Keep headers visible and aligned */
.custom-pool-table .mud-table-header-cell,
.custom-group-table .mud-table-header-cell {
    display: table-cell !important; /* Make sure headers are visible */
    text-align: left; /* Align headers with content */
}

/* For smaller screens (e.g., iPhone) */
@media (max-width: 600px) {
    /* Ensure Name column remains left-aligned */
    .custom-pool-table .mud-table-cell:first-child,
    .custom-group-table .mud-table-cell:first-child {
        text-align: left !important; /* Maintain left alignment */
    }

    /* Keep table headers visible and adjust alignment */
    .custom-pool-table .mud-table-header-cell,
    .custom-group-table .mud-table-header-cell {
        display: table-cell !important; /* Force visibility */
        text-align: left; /* Align headers */
        font-size: 0.85rem; /* Slightly reduce font size for mobile */
    }

    /* Reduce padding for better fit on smaller screens */
    .mud-table-row,
    .mud-table-cell {
        padding: 4px 8px; /* Tighten row and cell spacing */
    }
}


.button-group {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.header-text {
    margin-bottom: 1rem;
}

.rounded-button {
    border-radius: 50%; /* Make the button circular */
    width: 40px; /* Adjust for consistent size */
    height: 40px; /* Match width */
    display: flex;
    justify-content: center;
    align-items: center;
}

    .rounded-button svg {
        color: white; /* Ensures the icon color is white */
    }

.strikethrough {
    text-decoration: line-through;
    color: gray; /* Optional: Dim the color for visual distinction */
}

@media print {
    /* Hide elements with the no-print class */
    .no-print {
        display: none !important;
    }

    /* Display print-only elements */
    .print-only {
        display: block !important;
    }

    /* Force larger font size for the print header */
    .print-header {
        font-size: 32px !important;
        font-weight: bold !important;
        text-align: center !important;
        margin-bottom: 16px !important;
    }

    /* Ensure tables print properly */
    .print-table {
        height: auto !important;
        overflow: visible !important;
    }
}

.print-only {
    display: none;
}

@media print {
    .print-only {
        display: block;
    }

    .page-break-after {
        page-break-after: always;
    }
}


/* Narrow tabs and subtle border around tab labels */
.custom-tabs .mud-tab {
    padding: 2px 12px !important; /* Reduce horizontal padding for narrower tabs */
    min-width: auto !important; /* Let tabs shrink to content size */
    margin-right: 4px; /* Small margin between tabs */
    border: 1px solid #e0e0e0; /* Subtle border around tabs */
    border-radius: 0px; /* Slightly rounded corners for aesthetics */
}

/* Adjust active tab appearance */
.custom-tabs .mud-tab-active {
    border: 1px solid var(--mud-palette-primary); /* Highlight active tab with primary color border */
    background-color: var(--mud-palette-primary);
    color: #fff !important;
}

/* Surrounding border around tab content, with top border below tabs */
.custom-tabs .mud-tabs-panels {
    border: 1px solid #e0e0e0;
    border-radius: 0 4px 4px 4px; /* Rounded corners except top-left */
    padding: 8px; /* Adjust padding as desired */
    margin-top: -1px; /* Connect top border to tabs seamlessly */
}

.scoring-table .mud-table-cell {
    padding: 2px 8px !important;
}

/* Ensure numeric fields have a consistent width and don't stretch */
.mud-numeric-field-sentence .mud-input {
    width: 60px !important; /* Fixed width for numeric fields */
}

/* Adjust padding for a tighter sentence look */
.mud-numeric-field-sentence .mud-input-control {
    padding: 0 4px !important;
}

/* Default: Show full text on desktop */
.responsive-header {
    white-space: nowrap;
}

/* On smaller screens (<600px): Hide full text and show short text */
@media (max-width: 600px) {
    .responsive-header {
        font-size: 0; /* Hide the original text */
    }

        .responsive-header::after {
            content: attr(data-short); /* Use the short text from data-short attribute */
            font-size: 0.875rem; /* Restore font size for the short text */
        }
}

/* Hide spinners on numeric fields with higher specificity */
.no-spinners .mud-input input[type="number"]::-webkit-inner-spin-button,
.no-spinners .mud-input input[type="number"]::-webkit-outer-spin-button {
    -webkit-appearance: none !important;
    margin: 0;
}

.no-spinners .mud-input input[type="number"] {
    -moz-appearance: textfield !important; /* For Firefox */
    appearance: none !important; /* For other browsers */
}

.custom-tabs {
    border: none !important; /* Removes unwanted outer border */
    box-shadow: none !important; /* Removes any unwanted shadow */
}

/* Increase width of Save button */
.save-button {
    min-width: 85px; /* Adjust this value as desired */
    padding-left: 16px;
    padding-right: 16px;
}
/* Fix button container to bottom with padding */
.fixed-button-container {
    position: fixed;
    bottom: 56px;
    left: 4px;
    width: 100%;
    padding: 12px;
    background-color: #ffffff; /* White background for clarity */
    display: flex;
    justify-content: left; /* Center-align buttons horizontally */
    gap: 12px; /* Space between buttons */
    border-top: none;
    z-index: 10; /* Ensure it sits above other content */
}

/* Ensure body content doesn't get hidden behind the fixed buttons */
.body-container {
    padding-bottom: 70px; /* Adjust this padding based on the height of your buttons */
}

/* Desktop view adjustments */
@media (min-width: 992px) {
    .fixed-button-container {
        position: absolute;
        bottom: 16px; /* small gap from bottom of page content */
        left: 4;
        width: 100%;
        padding: 12px;
        background-color: transparent; /* transparent or white as desired */
        justify-content: flex-start; /* aligned left */
        z-index: auto;
    }

    .body-container {
        padding-bottom: 80px; /* Reduced padding on desktop */
        position: relative; /* Ensure buttons stay within this container */
    }
}
/* Add margin between the icon and text in the print button */
.mr-1 {
    margin-right: 4px; /* Adjust spacing as needed */
}

/* Drag and Drop Styles for Tee Times */
.tee-time-drag-over {
    border: 2px dashed var(--mud-palette-primary) !important;
    background-color: rgba(var(--mud-palette-primary-rgb), 0.1) !important;
    box-shadow: 0 4px 12px rgba(var(--mud-palette-primary-rgb), 0.3) !important;
}

.mud-tr[draggable="true"] {
    cursor: move;
}

.mud-tr[draggable="true"]:hover {
    background-color: var(--mud-palette-background-grey);
}

.mud-tr[draggable="true"]:active {
    opacity: 0.5;
}

/* Tee Time Position Box Styles */
.position-box {
    transition: all 0.2s ease;
    border: 1px solid var(--mud-palette-lines-default);
}

.position-box:hover {
    transform: scale(1.05);
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

/* Mobile responsive adjustments for tee time cards */
@media (max-width: 600px) {
    .position-box {
        width: 45px !important;
        height: 45px !important;
    }
    
    .position-box .mud-typography-h6 {
        font-size: 0.875rem !important;
    }
    
    .position-box .mud-icon-size-small {
        font-size: 14px !important;
    }
    
    .position-box .mud-typography-caption {
        font-size: 0.625rem !important;
    }
    
    .position-box .mud-typography-body1 {
        font-size: 0.875rem !important;
    }
}
