html {
    font-size: 14px;
}

@media (min-width: 768px) {
    html {
        font-size: 16px;
    }
}

.btn:focus,
.btn:active:focus,
.btn-link.nav-link:focus,
.form-control:focus,
.form-check-input:focus {
    box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

.card-header .btn-link {
    text-decoration: none !important;
}

.btn-link {
    text-decoration: none !important;
}


html {
    position: relative;
    min-height: 100%;
}

body {
    margin-bottom: 60px;
}

.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;
}

/* === Mr. Golf League Brand Styles from Copilot=== */

/* Brand Colors */
:root {
    --fairway-green: #3E7D4A;
    --flagstick-red: #D94F4F;
    --sky-blue: #A3D5F7;
    --sandtrap-beige: #F5E9D3;
    --clubhouse-charcoal: #333333;
}

/* Typography */
body {
    font-family: 'Lato', 'Open Sans', sans-serif;
    background-color: var(--sandtrap-beige);
    color: var(--clubhouse-charcoal);
    margin: 0;
    padding: 0;
}

h1,
h2,
h3 {
    font-family: 'Montserrat', 'Poppins', sans-serif;
    color: var(--fairway-green);
    margin-bottom: 0.5em;
}

.accent-script {
    font-family: 'Pacifico', cursive;
    color: var(--flagstick-red);
}

/* Header */
header {
    background-color: var(--fairway-green);
    color: black;
    padding: 1em;
    text-align: center;
}

/* Navigation */
nav {
    display: flex;
    justify-content: space-around;
    background-color: var(--clubhouse-charcoal);
    padding: 0.5em;
}

nav a {
    color: var(--sandtrap-beige);
    text-decoration: none;
    font-weight: bold;
}

nav a:hover {
    color: var(--sky-blue);
}

/* Buttons */
.button {
    background-color: var(--flagstick-red);
    color: white;
    border: none;
    padding: 0.75em 1.5em;
    border-radius: 5px;
    font-weight: bold;
    cursor: pointer;
}

.button:hover {
    background-color: #b83e3e;
}

/* Cards */
.card {
    background-color: white;
    border: 1px solid var(--fairway-green);
    border-radius: 8px;
    padding: 1em;
    margin: 1em;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

/* Leaderboard Table */
table.leaderboard {
    width: 100%;
    border-collapse: collapse;
    background-color: white;
}

table.leaderboard th {
    background-color: var(--sky-blue);
    color: var(--clubhouse-charcoal);
    padding: 0.75em;
    text-align: left;
}

table.leaderboard td {
    padding: 0.75em;
    border-bottom: 1px solid var(--sandtrap-beige);
}

/* Holes Table */
table.holes {
    width: 100%;
    border-collapse: collapse;
    background-color: white;
}

table.holes th {
    background-color: var(--sky-blue);
    color: var(--clubhouse-charcoal);
    border: 1px solid black;
    padding: 8px;
    /* Add some space around content */
    text-align: center;
    /* Align text to the left */
    /* Optional: handle content that overflows the fixed width */
    overflow: hidden;
    text-overflow: ellipsis;
    /* Add "..." to overflowing text */
    white-space: nowrap;
    /* Prevent text from wrapping into new lines */
}

table.holes td {
    border-bottom: 1px solid var(--sandtrap-beige);
    border: 1px solid black;
    padding: 8px;
    /* Add some space around content */
    text-align: center;
    /* Align text to the left */
    /* Optional: handle content that overflows the fixed width */
    overflow: hidden;
    text-overflow: ellipsis;
    /* Add "..." to overflowing text */
    white-space: nowrap;
    /* Prevent text from wrapping into new lines */
}

/* Responsive Layout */
@media (max-width: 768px) {
    nav {
        flex-direction: column;
        align-items: center;
    }

    .card {
        margin: 0.5em;
    }

    table.leaderboard th,
    table.leaderboard td {
        font-size: 0.9em;
    }
}

.fps-container {
    display: flex;
    gap: 20px;
}

.fps-column {
    flex: 1;
}

.fps-search {
    width: 100%;
    padding: 8px;
    margin-bottom: 10px;
}

.fps-list {
    list-style: none;
    padding: 0;
    margin: 0;
    border: 1px solid #ccc;
    min-height: 200px;
}

.fps-list li {
    padding: 8px 10px;
    border-bottom: 1px solid #eee;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
}

.fps-list li:hover {
    background: #f5f5f5;
}

.fps-title {
    font-weight: bold;
    margin-bottom: 8px;
}

.trash-icon {
    color: #2B2B2B;
    /* Clubhouse Charcoal */
    width: 16px;
    height: 16px;
}

button:hover .trash-icon {
    color: #E63946;
    /* Flagstick Red */
}

.dual-list {
    border: 1px solid #ccc;
    height: 260px;
    overflow-y: auto;
    list-style: none;
    padding: 0;
    margin: 0;
}

.dual-list li {
    padding: 6px 10px;
    cursor: pointer;
}

.dual-list li:hover {
    background: #f0f0f0;
}

.header-avatar {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    border: 2px solid #000000;
    background: #ffffff;
    object-fit: cover;
    object-position: center;
    display: inline-block;
}

.header-avatar--blank {
    box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.2);
}

.header-settings-btn {
    font-size: 1.15rem;
    line-height: 1;
}

.site-header {
    /*height: 72px;*/
    padding: 0 1rem;
    transition: height 0.25s ease, padding 0.25s ease;
}

.site-header.header--compact {
    height: 44px;
    padding: 0 .5rem;
    background: rgba(0, 0, 0, 0.75);
    /* optional */
    backdrop-filter: blur(6px);
    /* optional */
}

.site-header.header--compact .logo {
    transform: scale(.75);
    transform-origin: left center;
}

.navbar.navbar--compact {
    padding-top: .25rem;
    padding-bottom: .25rem;
}

.navbar.navbar--compact .navbar-brand img {
    width: 56px;
    height: 56px;
}

.navbar.navbar--compact .nav-link,
.navbar.navbar--compact .navbar-text,
.navbar.navbar--compact .dropdown-item {
    font-size: .9rem;
    padding-top: .35rem;
    padding-bottom: .35rem;
}

@media (max-width: 768px) {
    .navbar .navbar-brand img {
        width: 72px;
        height: 72px;
    }

    .navbar .nav-link,
    .navbar .navbar-text,
    .navbar .dropdown-item {
        font-size: 0.95rem;
    }
}

/* upsize standard menu dropdown chevron arow */
.navbar .dropdown-toggle::after {
    transform: scale(2);
    /*margin-left: -0.25rem;*/
}

/* Keep the Admin/Editting grid tight and centered */
.stableford-grid {
    max-width: 420px;
    /* perfect for 3 columns of tiny inputs */
    margin: 0;
    /* or auto if you want it centered */
}

/* Single-digit input width */
.stableford-input {
    width: 4ch;
    padding-left: 0;
    padding-right: 0;
}

.player-thumb-sm {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    object-fit: cover;
    box-shadow: var(--shadow-sm, 0 1px 2px rgba(0, 0, 0, 0.15));
}

/* Icon sizes used for emojis all over the place */
.icon {
    font-size: 1.25rem;
    /* 20px */
    line-height: 1;
}

.icon-sm {
    font-size: 1rem;
    /* 16px */
}

.icon-lg {
    font-size: 1.5rem;
    /* 24px */
}

@media (min-width: 1024px) {
    .icon {
        font-size: 1.5rem;
        /* 24px */
    }

    .icon-sm {
        font-size: 1.125rem;
        /* 18px */
    }

    .icon-lg {
        font-size: 1.75rem;
        /* 28px */
    }
}

/* Event calendar and timeline items */
/* Modal Container */
.event-modal {
    position: fixed;
    bottom: -100%;
    left: 0;
    right: 0;
    background: #fff;
    border-radius: 20px 20px 0 0;
    padding: 1rem 1.25rem 2rem;
    box-shadow: 0 -6px 20px rgba(0, 0, 0, 0.15);
    transition: bottom 0.3s ease;
    max-height: 80vh;
    overflow-y: auto;
    z-index: 1000;
}

.event-modal.open {
    bottom: 0;
}

/* Header */
.event-modal-header h3 {
    font-size: 1.25rem;
    font-weight: 600;
}

/* Type Picker */
.event-type-picker {
    display: flex;
    overflow-x: auto;
    gap: 1rem;
    padding-bottom: 0.5rem;
    margin-bottom: 1rem;
}

.event-type-option {
    text-align: center;
    min-width: 70px;
    padding: 0.5rem;
    border-radius: 12px;
    border: 1px solid #eee;
    cursor: pointer;
    transition: background 0.2s ease;
}

.event-type-option:hover {
    background: #f7f7f7;
}

.event-type-option.selected {
    border-color: var(--brand-accent, #2a8cff);
    background: #eef6ff;
}

.event-type-icon {
    font-size: 1.5rem;
}

.event-type-label {
    font-size: 0.85rem;
    margin-top: 0.25rem;
}

/* Dynamic Fields */
.event-field {
    display: none;
}

/* Day sheets */
/* Bottom Drawer */
.day-sheet {
    position: fixed;
    bottom: -100%;
    left: 0;
    right: 0;
    background: #fff;
    border-radius: 20px 20px 0 0;
    padding: 1rem 1.25rem 2rem;
    box-shadow: 0 -6px 20px rgba(0, 0, 0, 0.15);
    transition: bottom 0.3s ease;
    max-height: 75vh;
    overflow-y: auto;
    z-index: 999;
}

/* Open State */
.day-sheet.open {
    bottom: 0;
}

/* Drag Handle */
.day-sheet-handle {
    width: 40px;
    height: 5px;
    background: #ccc;
    border-radius: 3px;
    margin: 0 auto 1rem;
}

/* Header */
.day-sheet-header h3 {
    font-size: 1.25rem;
    font-weight: 600;
}

/* Summary */
.day-sheet-summary {
    font-size: 0.9rem;
}

/* Section */
.day-sheet-section {
    border-top: 1px solid #eee;
    padding-top: 1rem;
}

/* Items */
.day-sheet-item {
    padding: 0.5rem 0;
    border-bottom: 1px solid #f3f3f3;
}

.day-sheet-item:last-child {
    border-bottom: none;
}

/* Icon */
.day-sheet-icon {
    font-size: 1.3rem;
    width: 28px;
    text-align: center;
}

/* Text */
.day-sheet-title {
    font-size: 1rem;
    font-weight: 600;
}

.day-sheet-subtitle {
    font-size: 0.85rem;
    color: #666;
}

/* Round-specific styling */
.day-sheet-item.round .day-sheet-icon {
    color: var(--brand-accent, #2a8cff);
}

/* Timeline views */
/* Container */
.timeline-container {
    max-width: 700px;
    margin: 0 auto;
    padding: 1rem;
}

/* Month Separator */
.timeline-month {
    font-size: 1.1rem;
    font-weight: 600;
    margin: 1.5rem 0 0.5rem;
    color: #444;
}

.timeline-filters {
    display: grid;
    grid-template-columns: repeat(6, auto);
    gap: .5rem;
}

@media (max-width: 768px) {
    .timeline-filters {
        grid-template-columns: repeat(4, auto);
    }
}

/* Timeline Layout */
.timeline {
    position: relative;
}

.timeline-item {
    display: flex;
    align-items: flex-start;
    margin-bottom: 1.5rem;
    position: relative;
}

/* Spine */
.timeline-spine {
    width: 40px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.timeline-dot {
    width: 12px;
    height: 12px;
    background: var(--brand-accent, #2a8cff);
    border-radius: 50%;
    margin-top: 4px;
}

.timeline-line {
    flex-grow: 1;
    width: 2px;
    background: #ddd;
    margin-top: 4px;
}

/* Card */
.timeline-card {
    background: #fff;
    border-radius: 12px;
    padding: 1rem;
    flex-grow: 1;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
    border: 1px solid #eee;
}

.timeline-card-header {
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.timeline-icon {
    font-size: 1.2rem;
}

.timeline-title {
    font-size: 1rem;
}

.timeline-date {
    font-size: 0.85rem;
    color: #777;
    margin-bottom: 0.25rem;
}

.timeline-subtitle {
    font-size: 0.9rem;
    color: #555;
    margin-bottom: 0.25rem;
}

.timeline-description {
    font-size: 0.9rem;
    color: #444;
    margin-bottom: 0.5rem;
}

/* Round Summary */
.timeline-round-summary {
    background: #f7faff;
    padding: 0.5rem;
    border-radius: 8px;
    font-size: 0.9rem;
}

/* Type-Specific Colors */
.timeline-card.lesson .timeline-icon {
    color: #2a8cff;
}

.timeline-card.injury .timeline-icon {
    color: #d9534f;
}

.timeline-card.sickness .timeline-icon {
    color: #f0ad4e;
}

.timeline-card.recovery .timeline-icon {
    color: #5cb85c;
}

.timeline-card.equipment .timeline-icon {
    color: #7952b3;
}

.timeline-card.travel .timeline-icon {
    color: #0275d8;
}

.timeline-card.note .timeline-icon {
    color: #6c757d;
}

.timeline-card.round .timeline-icon {
    color: #20c997;
}

/* Calendar views */
/* Container */
.calendar-container {
    max-width: 600px;
    margin: 0 auto;
    padding: 1rem;
}

/* Header */
.calendar-header {
    margin-bottom: 1rem;
}

.calendar-month {
    font-size: 1.4rem;
    font-weight: 600;
}

/* Grid Layout */
.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 4px;
}

/* Day Labels */
.calendar-day-labels {
    margin-bottom: 4px;
}

.calendar-day-label {
    text-align: center;
    font-size: 0.8rem;
    color: #777;
}

/* Day Cell */
.calendar-day {
    background: #fff;
    border-radius: 8px;
    padding: 6px;
    min-height: 60px;
    position: relative;
    cursor: pointer;
    border: 1px solid #eee;
    transition: background 0.15s ease;
}

.calendar-day:hover {
    background: #f7f7f7;
}

.calendar-day.today {
    border: 2px solid var(--brand-accent, #2a8cff);
}

.calendar-day-number {
    font-size: 0.9rem;
    font-weight: 600;
}

/* Event Badges */
.calendar-badges {
    position: absolute;
    bottom: 4px;
    right: 4px;
    display: flex;
    gap: 2px;
}

.calendar-round-badge {
    position: absolute;
    top: 4px;
    right: 4px;
    background: #e6f7ff;
    color: #0077cc;
    padding: 2px 2px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 600;
}


.calendar-badge {
    background: #eee;
    border-radius: 4px;
    padding: 2px 4px;
    font-size: 0.7rem;
    line-height: 1;
}

.calendar-badge.more {
    background: #ddd;
    font-weight: 600;
}

/* Day Sheet (Bottom Drawer) */
.day-sheet {
    position: fixed;
    bottom: -100%;
    left: 0;
    right: 0;
    background: #fff;
    border-radius: 16px 16px 0 0;
    padding: 1rem;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.15);
    transition: bottom 0.25s ease;
    max-height: 70vh;
    overflow-y: auto;
}

.day-sheet.open {
    bottom: 0;
}

.day-sheet-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.day-sheet-content {
    margin-top: 1rem;
}