/* Seal Rifle & Pistol Club Members Area */
:root {
    --srpc-bg: #151915;
    --srpc-panel: #232925;
    --srpc-panel-2: #2f3732;
    --srpc-gold: #9f7a31;
    --srpc-gold-light: #f7df9b;
    --srpc-text: #f5f5f1;
    --srpc-muted: #c9c7be;
    --srpc-border: rgba(247, 223, 155, 0.22);
    --srpc-danger: #b94a48;
    --srpc-success: #4f8f5b;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: Arial, sans-serif;
    color: var(--srpc-text);
    background:
        radial-gradient(circle at top, rgba(159, 122, 49, 0.18), transparent 34rem),
        linear-gradient(180deg, #111 0%, var(--srpc-bg) 100%);
    line-height: 1.6;
}

.members-header {
    background: #fff;
    color: #000;
    text-align: center;
    padding: 14px 20px;
}

.members-header img {
    max-width: 120px;
    border-radius: 8px;
}

.members-nav {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 6px;
    background: linear-gradient(180deg, #303633 0%, #202522 100%);
    border-top: 1px solid rgba(255,255,255,0.08);
    border-bottom: 3px solid var(--srpc-gold);
    box-shadow: 0 4px 18px rgba(0,0,0,0.28);
    padding: 0 12px;
}

.members-nav a {
    color: #fff;
    padding: 14px 18px;
    text-decoration: none;
    display: inline-flex;
    gap: 8px;
    align-items: center;
    min-height: 52px;
    border-radius: 10px;
}

.members-nav a:hover {
    background: rgba(159, 122, 49, 0.24);
    color: var(--srpc-gold-light);
}

.menu-icon {
    width: 20px;
    height: 20px;
    stroke: currentColor;
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.members-shell {
    width: min(1180px, calc(100% - 32px));
    margin: 28px auto;
}

.panel {
    background: linear-gradient(180deg, rgba(47,55,50,0.96), rgba(35,41,37,0.96));
    border: 1px solid var(--srpc-border);
    border-radius: 18px;
    box-shadow: 0 18px 40px rgba(0,0,0,0.34);
    padding: 22px;
}

.hero-panel {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 18px;
    align-items: center;
    margin-bottom: 20px;
}

h1, h2, h3 {
    margin-top: 0;
}

.muted {
    color: var(--srpc-muted);
}

.login-card {
    width: min(480px, calc(100% - 32px));
    margin: 42px auto;
}

.form-row {
    margin-bottom: 14px;
}

label {
    display: block;
    margin-bottom: 6px;
    color: var(--srpc-gold-light);
    font-weight: bold;
}

input, select, textarea {
    width: 100%;
    padding: 11px 12px;
    border-radius: 10px;
    border: 1px solid var(--srpc-border);
    background: #111611;
    color: var(--srpc-text);
}

.button,
button {
    border: 0;
    border-radius: 999px;
    padding: 10px 16px;
    cursor: pointer;
    background: linear-gradient(180deg, #c69a43, var(--srpc-gold));
    color: #151515;
    font-weight: 700;
    box-shadow: 0 6px 18px rgba(0,0,0,0.28);
}

.button.secondary,
button.secondary {
    background: rgba(255,255,255,0.08);
    color: var(--srpc-text);
    border: 1px solid var(--srpc-border);
}

.button.disabled,
button:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

.notice {
    padding: 10px 12px;
    border-radius: 10px;
    margin-bottom: 14px;
}

.notice.error {
    background: rgba(185, 74, 72, 0.18);
    border: 1px solid rgba(185, 74, 72, 0.5);
}

.notice.success {
    background: rgba(79, 143, 91, 0.18);
    border: 1px solid rgba(79, 143, 91, 0.5);
}

.calendar-toolbar {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    align-items: center;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.calendar-toolbar h2 {
    margin: 0;
}

.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    gap: 8px;
}

.calendar-weekday {
    text-align: center;
    color: var(--srpc-gold-light);
    font-weight: bold;
    padding: 8px 4px;
    border-bottom: 1px solid var(--srpc-border);
}

.calendar-day {
    min-height: 150px;
    background: rgba(255,255,255,0.045);
    border: 1px solid rgba(247, 223, 155, 0.12);
    border-radius: 14px;
    padding: 9px;
    position: relative;
}

.calendar-day.empty {
    opacity: 0.25;
    background: transparent;
}

.day-number {
    font-weight: 700;
    color: var(--srpc-gold-light);
    margin-bottom: 8px;
}

.event-card {
    background: rgba(17,22,17,0.78);
    border: 1px solid var(--srpc-border);
    border-left: 4px solid var(--srpc-gold);
    border-radius: 12px;
    padding: 10px;
    margin-bottom: 8px;
}

.event-card h3 {
    font-size: 0.98rem;
    margin: 0 0 4px;
}

.event-meta {
    font-size: 0.86rem;
    color: var(--srpc-muted);
    margin-bottom: 8px;
}

.capacity-line {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    font-size: 0.88rem;
    margin: 8px 0 6px;
}

.capacity-bar {
    height: 7px;
    background: rgba(255,255,255,0.12);
    border-radius: 999px;
    overflow: hidden;
    margin-bottom: 9px;
}

.capacity-bar span {
    display: block;
    height: 100%;
    width: var(--fill, 0%);
    background: linear-gradient(90deg, var(--srpc-success), var(--srpc-gold-light));
    border-radius: inherit;
}

.attendees {
    margin-top: 8px;
    font-size: 0.86rem;
}

.attendees summary {
    cursor: pointer;
    color: var(--srpc-gold-light);
}

.attendees ul {
    margin: 6px 0 0 18px;
    padding: 0;
    color: var(--srpc-muted);
}

.event-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.rsvp-form {
    display: inline;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 8px;
    border-radius: 999px;
    background: rgba(247, 223, 155, 0.12);
    color: var(--srpc-gold-light);
    border: 1px solid var(--srpc-border);
    font-size: 0.82rem;
}

.full {
    color: #ffd1cf;
}

@media (max-width: 900px) {
    .calendar-grid {
        grid-template-columns: 1fr;
    }

    .calendar-weekday {
        display: none;
    }

    .calendar-day {
        min-height: auto;
    }

    .calendar-day.empty {
        display: none;
    }

    .hero-panel {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 700px) {
    .members-nav {
        flex-direction: column;
        align-items: stretch;
        padding: 8px;
    }

    .members-nav a {
        justify-content: flex-start;
    }
}


.admin-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 14px;
}

.admin-card {
    background: rgba(17,22,17,0.78);
    border: 1px solid var(--srpc-border);
    border-left: 4px solid var(--srpc-gold);
    border-radius: 14px;
    padding: 16px;
}

.table-wrap {
    overflow-x: auto;
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 14px;
}

.admin-table th,
.admin-table td {
    border-bottom: 1px solid rgba(247, 223, 155, 0.15);
    padding: 10px;
    text-align: left;
    vertical-align: top;
}

.admin-table th {
    color: var(--srpc-gold-light);
}

.inline-form {
    display: inline-block;
    margin: 2px;
}

.two-col {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

@media (max-width: 800px) {
    .two-col {
        grid-template-columns: 1fr;
    }
}

code {
    background: rgba(255,255,255,0.08);
    border: 1px solid var(--srpc-border);
    border-radius: 6px;
    padding: 2px 5px;
    color: var(--srpc-gold-light);
}

.checkin-button {
    margin-top: 8px;
}

#checkinMessage {
    margin-top: 14px;
}

.leaflet-container {
    background: #1f251f;
}

.lane-board {
    display: grid;
    grid-template-columns: 120px repeat(auto-fit, minmax(160px, 1fr));
    gap: 8px;
    align-items: stretch;
}

.lane-board-header,
.lane-time {
    padding: 10px;
    border-radius: 10px;
    background: rgba(247, 223, 155, 0.12);
    border: 1px solid var(--srpc-border);
    font-weight: 700;
    color: var(--srpc-gold-light);
}

.lane-slot {
    min-height: 92px;
    padding: 10px;
    border-radius: 12px;
    border: 1px solid var(--srpc-border);
    background: rgba(255,255,255,0.045);
}

.slot-past,
.slot-complete {
    background: rgba(120,120,120,0.18);
    border-color: rgba(180,180,180,0.22);
    color: rgba(255,255,255,0.62);
}

.slot-current {
    background: rgba(159, 122, 49, 0.24);
    border: 2px solid var(--srpc-gold-light);
    box-shadow: 0 0 0 3px rgba(247, 223, 155, 0.08);
}

.slot-future {
    border: 1px dashed rgba(255,255,255,0.62);
    background: rgba(255,255,255,0.035);
}

.lane-slot-actions {
    margin-top: 8px;
}

@media (max-width: 900px) {
    .lane-board {
        display: block;
    }

    .lane-board-header,
    .lane-time,
    .lane-slot {
        margin-bottom: 8px;
    }
}

.live-big-number {
    font-size: clamp(2rem, 6vw, 4rem);
    font-weight: 800;
    color: var(--srpc-gold-light);
    line-height: 1;
    margin: 10px 0;
}

.action-queue {
    display: grid;
    gap: 10px;
}

.action-queue-item {
    display: flex;
    align-items: center;
    gap: 12px;
    background: rgba(255,255,255,0.045);
    border: 1px solid var(--srpc-border);
    border-radius: 14px;
    padding: 12px;
}

.live-position {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 42px;
    height: 42px;
    border-radius: 999px;
    background: rgba(159, 122, 49, 0.28);
    color: var(--srpc-gold-light);
    font-weight: 800;
    border: 1px solid var(--srpc-border);
}

.live-range-hero {
    position: sticky;
    top: 0;
    z-index: 5;
}


/* V6 calendar/location polish */
.event-location-bi {
    border-left-color: #5fa8d3;
    background: linear-gradient(180deg, rgba(95,168,211,0.16), rgba(17,22,17,0.78));
}

.event-location-wr {
    border-left-color: #7fb069;
    background: linear-gradient(180deg, rgba(127,176,105,0.16), rgba(17,22,17,0.78));
}

.event-location-ly {
    border-left-color: #d08c60;
    background: linear-gradient(180deg, rgba(208,140,96,0.16), rgba(17,22,17,0.78));
}

.event-location-hy {
    border-left-color: #b56576;
    background: linear-gradient(180deg, rgba(181,101,118,0.16), rgba(17,22,17,0.78));
}

.event-location-ch {
    border-left-color: #a7c957;
    background: linear-gradient(180deg, rgba(167,201,87,0.16), rgba(17,22,17,0.78));
}

.date-picker-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px;
    align-items: center;
}

.checkbox-line {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    color: var(--srpc-text);
    margin-bottom: 6px;
}

.checkbox-line input {
    width: auto;
}

.stack-form {
    display: grid;
    grid-template-columns: minmax(160px, 1fr) auto;
    gap: 6px;
    margin-top: 8px;
}

@media print {
    .members-header,
    .members-nav,
    .event-actions,
    .rsvp-form,
    .attendees,
    .capacity-bar {
        display: none !important;
    }

    body {
        background: #fff !important;
        color: #111 !important;
    }

    .members-shell {
        width: 100%;
        margin: 0;
    }

    .panel,
    .event-card,
    .calendar-day {
        box-shadow: none !important;
        background: #fff !important;
        color: #111 !important;
        border-color: #bbb !important;
    }
}


/* V7.6 additions */
.probationary-test-panel {
    border-color: rgba(247, 223, 155, 0.45);
}

.probationary-badge {
    background: rgba(255, 193, 7, 0.24);
    border-color: rgba(255, 193, 7, 0.7);
    color: #ffe8a3;
}

.probationary-member-row {
    background: rgba(255, 193, 7, 0.12);
}

.probationary-booking {
    outline: 2px solid rgba(255, 193, 7, 0.85);
    box-shadow: inset 0 0 0 999px rgba(255, 193, 7, 0.08);
}

.announcement-images {
    display: grid;
    gap: 14px;
    margin: 16px 0;
}

.announcement-figure {
    margin: 0;
}

.announcement-figure img,
.announcement-image-preview {
    max-width: 100%;
    border-radius: 14px;
    border: 1px solid var(--srpc-border);
    box-shadow: 0 10px 24px rgba(0,0,0,0.28);
}

.announcement-figure figcaption {
    color: var(--srpc-muted);
    margin-top: 6px;
    font-size: 0.95rem;
}

.poll-box {
    margin-top: 18px;
    padding: 16px;
    border: 1px solid var(--srpc-border);
    border-radius: 14px;
    background: rgba(0,0,0,0.16);
}

.poll-option {
    display: block;
    color: var(--srpc-text);
    font-weight: normal;
    margin: 8px 0;
}

.poll-results {
    display: grid;
    gap: 10px;
}

.poll-result-row {
    display: grid;
    gap: 5px;
}

.poll-result-row span {
    color: var(--srpc-muted);
}

.poll-bar {
    height: 10px;
    border-radius: 999px;
    background: rgba(255,255,255,0.12);
    overflow: hidden;
}

.poll-bar span {
    display: block;
    height: 100%;
    background: var(--srpc-gold);
}


/* V7.7 close whole target-lane time slot */
.close-timeslot-form {
    margin-top: 8px;
}

.close-timeslot-form button {
    font-size: 0.82rem;
    padding: 6px 10px;
}


/* V7.8 member notifications */
.notification-panel {
    border-color: rgba(247, 223, 155, 0.48);
}

.notification-card {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    align-items: flex-start;
    padding: 12px 0;
    border-top: 1px solid var(--srpc-border);
}

.notification-card:first-of-type {
    border-top: 0;
}

.notification-card p {
    margin: 4px 0;
}


/* V7.8.1 event-management action button tidy-up */
.event-management-actions {
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
    margin-top: 18px;
}

.event-management-action {
    width: 100%;
    min-height: 46px;
    padding: 10px 16px;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    text-align: center;
    text-decoration: none;
    font-weight: 800;
    line-height: 1.2;
    box-shadow: 0 6px 18px rgba(0,0,0,0.22);
}

button.event-management-action {
    border: 0;
    font-family: inherit;
}

.event-management-action-primary {
    background: linear-gradient(180deg, #d7aa4d, var(--srpc-gold));
    color: #101510;
}

.event-management-action-secondary {
    background: rgba(255,255,255,0.035);
    color: var(--srpc-text);
    border: 1px solid rgba(247, 223, 155, 0.55);
}

.event-management-action-secondary:hover {
    background: rgba(159, 122, 49, 0.18);
    color: var(--srpc-gold-light);
}

.event-action-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 1.15em;
    opacity: 0.95;
}

@media (min-width: 760px) {
    .event-management-actions {
        margin-top: 20px;
    }
}


/* V7.8.5 consistent page element spacing */
.members-shell > * + * {
    margin-top: 24px;
}

.members-shell > .panel + .panel {
    margin-top: 30px;
}

.members-shell > .notice + .panel,
.members-shell > .panel + .notice,
.members-shell > .notice + .notice {
    margin-top: 20px;
}
