/* BOM Volunteer Manager – Public Form Styles */

.bom-form-wrap {
    max-width: 720px;
    margin: 0 auto;
    font-family: inherit;
    padding: 0 20px 40px;
    box-sizing: border-box;
}
.bom-form-wrap h2 {
    font-size: 1.5em;
    font-weight: 700;
    color: #1d2327;
    margin: 24px 0 6px;
}
.bom-form-wrap > p {
    margin: 0 0 20px;
    color: #475569;
}

.bom-form-section {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 20px 24px;
    margin-bottom: 20px;
}
.bom-form-section h3 {
    font-size: 16px;
    line-height: 16px;
    font-family: proxima-nova, sans-serif;
    font-weight: 700;
    padding: 0;
    margin: 0 0 20px 0;
    text-transform: uppercase;
    color: #1d2327;
    border-bottom: none;
}
.bom-form-row {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
    margin-bottom: 0;
}
.bom-form-field {
    flex: 1;
    min-width: 200px;
    display: flex;
    flex-direction: column;
    margin-bottom: 20px;
}
.bom-field-sm { flex: 0 0 100px; min-width: 80px; }
/* Required field asterisk */
.bom-req {
    color: #F2542D;
    font-weight: 700;
}

.bom-form-field label {
    font-size: 16px;
    line-height: 20px;
    font-family: proxima-nova, sans-serif;
    font-weight: 400;
    margin: 0 0 6px 0;
    color: #1d2327;
    text-transform: none;
    letter-spacing: normal;
}
.bom-form-field input,
.bom-form-field select,
.bom-form-field textarea {
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    padding: 9px 12px;
    font-size: .95em;
    transition: border-color .15s;
    width: 100%;
    box-sizing: border-box;
    background: #f8fafc;
}
.bom-form-field input:focus,
.bom-form-field select:focus,
.bom-form-field textarea:focus {
    border-color: #2563eb;
    outline: none;
    background: #fff;
    box-shadow: 0 0 0 3px rgba(37,99,235,.1);
}
.bom-form-field textarea { resize: vertical; min-height: 80px; }

/* Combined waiver block — notice + checkbox merged */
.bom-waiver-combined {
    background: #fff8e1;
    border-left: 4px solid #f0a500;
    border-radius: 0 6px 6px 0;
    padding: 16px 18px;
    margin-bottom: 20px;
}
.bom-waiver-combined p {
    margin: 0 0 12px;
    font-size: .9em;
    color: #1d2327;
}
.bom-waiver-combined p a {
    color: #c2410c;
}
.bom-waiver-check {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: .9em;
    margin: 0;
    padding: 0;
    background: none;
    border-radius: 0;
}
.bom-waiver-check input[type=checkbox] {
    margin-top: 2px;
    flex-shrink: 0;
    width: 18px;
    height: 18px;
}

.bom-submit-btn {
    font-family: proxima-nova, sans-serif;
    font-weight: 700;
    font-style: normal;
    font-size: 16px;
    line-height: 16px;
    letter-spacing: 1px;
    display: inline-block;
    text-align: center;
    background-color: #003063;
    color: #ffffff;
    text-transform: uppercase;
    min-width: 150px;
    border-radius: 4px;
    padding: 15px 25px;
    margin: 15px 0 0;
    transition: background 500ms;
    text-decoration: none;
    border: none;
    cursor: pointer;
    width: 100%;
    box-sizing: border-box;
}
.bom-submit-btn:hover,
.bom-submit-btn:focus {
    background-color: #002145;
    color: #ffffff !important;
    text-decoration: none !important;
    cursor: pointer !important;
}
.bom-submit-btn:active {
    background-color: #001530;
}

.bom-form-success {
    background: #f7ab22;
    border: none;
    border-radius: 8px;
    padding: 24px;
    text-align: center;
    margin-bottom: 20px;
}
.bom-form-success h3 { margin: 0 0 8px; color: #191919; font-size: 1.3em; }
.bom-form-success p  { margin: 0 0 10px; color: #191919; }
.bom-form-success p:last-child { margin-bottom: 0; }

/* Larger ministry success message */
.bom-form-success-lg {
    padding: 40px 32px;
    max-width: 600px;
    margin: 40px auto;
    background: #f7ab22;
    border: none;
}
.bom-form-success-lg h3 {
    font-size: 1.6em;
    margin-bottom: 16px;
    color: #191919;
}
.bom-form-success-lg p {
    font-size: 1.05em;
    line-height: 1.6;
    color: #191919;
}

.bom-form-notice,
.bom-form-error {
    background: #fee2e2;
    border: 1px solid #fca5a5;
    border-radius: 8px;
    padding: 16px;
    color: #991b1b;
    margin-bottom: 16px;
}
.bom-form-notice { background: #fef3c7; border-color: #fcd34d; color: #92400e; }

@media (max-width: 600px) {
    .bom-form-row { flex-direction: column; }
    .bom-field-sm { flex: 1; min-width: unset; }
    .bom-form-section { padding: 16px; }
}

/* Honeypot spam field — hidden from humans, visible to bots */
.bom-confirm-email {
    opacity: 0 !important;
    position: absolute !important;
    top: -9999px !important;
    left: -9999px !important;
    height: 0 !important;
    overflow: hidden !important;
    pointer-events: none !important;
}


.bom-event-date-bar {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
    margin: 0 0 18px;
    padding: 12px 14px;
    border: 1px solid #bfd4ea;
    border-radius: 6px;
    background: #eef5fb;
    color: #1d2327;
    font-size: 14px;
    line-height: 20px;
}
.bom-event-date-bar strong {
    font-weight: 700;
    color: #003063;
}
.bom-event-date-bar[hidden] {
    display: none !important;
}

/* Group size layout */
.bom-group-size-inputs {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 24px;
}
.bom-group-size-inputs .bom-form-field {
    min-width: 0;
}
.bom-group-total-display {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-top: 4px;
    padding: 6px 12px 6px 18px;
    height: 50px;
    min-height: 50px;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    background: #f8fafc;
    box-sizing: border-box;
}
.bom-group-total-label {
    font-size: 15px;
    line-height: 18px;
    font-family: proxima-nova, sans-serif;
    font-weight: 700;
    color: #1d2327;
}
.bom-group-total-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    min-width: 36px;
    height: 36px;
    padding: 0;
    border-radius: 50%;
    background: #003063;
    color: #fff;
    font-size: 15px;
    font-weight: 700;
    flex-shrink: 0;
}

@media (max-width: 600px) {
    .bom-group-size-inputs {
        grid-template-columns: 1fr;
        gap: 0;
    }
}


/* Brand palette standardization
   Primary: #003063 | Gold: #f7ab22 | Orange: #F2542D | Grays */
:root {
    --bom-navy: #003063;
    --bom-navy-dark: #001f42;
    --bom-navy-soft: #eef5fb;
    --bom-navy-border: #bfd4ea;

    --bom-gold: #f7ab22;
    --bom-gold-dark: #b96a00;
    --bom-gold-soft: #fff6df;
    --bom-gold-border: #f6d18a;

    --bom-orange: #F2542D;
    --bom-orange-dark: #b92f16;
    --bom-orange-soft: #fff1ed;
    --bom-orange-border: #f7b8a8;

    --bom-gray-900: #1d2327;
    --bom-gray-700: #475569;
    --bom-gray-300: #cbd5e1;
    --bom-gray-200: #e2e8f0;
    --bom-gray-100: #f8fafc;
}

.bom-req {
    color: var(--bom-orange);
}

.bom-form-section {
    border-color: var(--bom-gray-200);
}

.bom-form-section h3 {
    color: var(--bom-gray-900);
}

.bom-form-field input,
.bom-form-field select,
.bom-form-field textarea,
.bom-group-total-display {
    border-color: var(--bom-gray-300);
    background: var(--bom-gray-100);
}

.bom-form-field input:focus,
.bom-form-field select:focus,
.bom-form-field textarea:focus {
    border-color: var(--bom-navy);
    box-shadow: 0 0 0 3px rgba(0, 48, 99, .12);
}

.bom-submit-btn,
.bom-submit-btn:visited {
    background-color: var(--bom-navy);
    border-color: var(--bom-navy);
}

.bom-submit-btn:hover,
.bom-submit-btn:focus {
    background-color: var(--bom-navy-dark);
    border-color: var(--bom-navy-dark);
}

.bom-waiver-combined {
    background: var(--bom-gold-soft);
    border-left-color: var(--bom-gold);
}

.bom-waiver-combined p a {
    color: var(--bom-orange);
}

.bom-form-success {
    background: var(--bom-navy-soft);
    border-color: var(--bom-navy-border);
    color: var(--bom-navy);
}

.bom-form-error,
.bom-form-notice {
    background: var(--bom-orange-soft);
    border-color: var(--bom-orange-border);
    color: var(--bom-orange-dark);
}

.bom-event-date-bar {
    background: var(--bom-navy-soft);
    border-color: var(--bom-navy-border);
}

.bom-event-date-bar strong {
    color: var(--bom-navy);
}

.bom-group-total-count {
    background: var(--bom-navy);
}

.bom-form-wrap a {
    color: var(--bom-navy);
}

.bom-form-wrap a:hover {
    color: var(--bom-orange);
}


/* Cross-browser public form field sizing and mobile overflow fixes */
.bom-form-wrap,
.bom-form-wrap *,
.bom-form-wrap *::before,
.bom-form-wrap *::after {
    box-sizing: border-box;
}

.bom-form-wrap {
    width: 100%;
    max-width: 720px;
    overflow-x: hidden;
}

.bom-form-section {
    width: 100%;
    max-width: 100%;
    overflow: hidden;
}

.bom-form-row {
    width: 100%;
}

.bom-form-field {
    min-width: 0;
    max-width: 100%;
}

.bom-form-field input:not([type="checkbox"]):not([type="radio"]),
.bom-form-field select {
    display: block;
    width: 100%;
    max-width: 100%;
    height: 50px;
    min-height: 50px;
    padding: 0 12px;
    line-height: 50px;
    box-sizing: border-box;
    font-family: inherit;
    font-size: .95em;
    border-radius: 6px;
    -webkit-appearance: none;
    appearance: none;
}

.bom-form-field input[type="date"] {
    min-width: 0;
    -webkit-appearance: none;
    appearance: none;
}

.bom-form-field input[type="date"]::-webkit-date-and-time-value {
    min-height: 50px;
    line-height: 50px;
    text-align: left;
}

.bom-form-field input[type="date"]::-webkit-calendar-picker-indicator {
    margin-right: 0;
}

.bom-form-field select {
    padding-right: 42px;
    background-image:
        linear-gradient(45deg, transparent 50%, #1d2327 50%),
        linear-gradient(135deg, #1d2327 50%, transparent 50%);
    background-position:
        calc(100% - 22px) 22px,
        calc(100% - 15px) 22px;
    background-size: 7px 7px, 7px 7px;
    background-repeat: no-repeat;
}

.bom-form-field textarea {
    width: 100%;
    max-width: 100%;
}

@media (max-width: 600px) {
    .bom-form-wrap {
        padding-left: 12px;
        padding-right: 12px;
    }

    .bom-form-section {
        padding: 16px;
    }

    .bom-form-row {
        display: block;
    }

    .bom-form-field,
    .bom-field-sm {
        width: 100%;
        max-width: 100%;
        min-width: 0;
        flex: 0 0 100%;
    }

    .bom-form-field input:not([type="checkbox"]):not([type="radio"]),
    .bom-form-field select,
    .bom-form-field textarea,
    .bom-group-total-display {
        width: 100%;
        max-width: 100%;
    }

    .bom-event-date-bar {
        width: 100%;
        max-width: 100%;
    }
}


/* Public form layout: keep a maximum of two fields per row on larger screens */
.bom-form-row {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
}

.bom-form-row > .bom-form-field {
    flex: 0 1 calc(50% - 8px);
    min-width: 0;
    max-width: calc(50% - 8px);
}

.bom-form-row > .bom-field-sm {
    flex: 0 1 calc(50% - 8px);
    min-width: 0;
    max-width: calc(50% - 8px);
}

.bom-group-size-inputs {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

@media (max-width: 700px) {
    .bom-form-row {
        display: block;
    }

    .bom-form-row > .bom-form-field,
    .bom-form-row > .bom-field-sm {
        width: 100%;
        max-width: 100%;
        min-width: 0;
        flex: 0 0 100%;
    }

    .bom-group-size-inputs {
        grid-template-columns: 1fr;
    }
}
