/* Calendar, choir directory, forms, shop, and the parts shared across pages. */

.skip { position: absolute; left: -9999px; top: 0; z-index: 60; background: var(--gold); color: var(--navy); font-weight: 700; padding: 12px 18px; border-radius: 0 0 10px 0; text-decoration: none; }
.skip:focus { left: 0; }
/* Two rings, so the focus shows on every background: navy against light, gold against dark. */
:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; box-shadow: 0 0 0 2px var(--navy); border-radius: 4px; }
main:focus { outline: none; }
.listed { font-weight: 500; }
.btn-outline { border-color: var(--navy); color: var(--navy); background: transparent; }
.btn-disabled, .btn-disabled:hover { background: var(--line); color: var(--muted); cursor: default; transform: none; border-color: transparent; }
.section-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }
.nav a[aria-current="page"] { opacity: 1; color: var(--gold); }

/* Mobile menu (six links need it earlier than the old breakpoint) */
.menu-btn { display: none; margin-left: auto; background: none; border: 2px solid rgba(255,255,255,.4); color: #fff; font: 600 .9rem var(--body); border-radius: 999px; padding: 8px 14px; cursor: pointer; }
@media (max-width: 980px) {
  .top { flex-wrap: wrap; gap: 12px; }
  .menu-btn { display: inline-block; }
  .top .btn-small { margin-left: 0; }
  .nav { display: none; order: 3; flex-basis: 100%; flex-direction: column; gap: 0; margin: 0 0 6px; }
  .top.open .nav { display: flex; }
  .nav a { padding: 12px 2px; border-top: 1px solid rgba(255,255,255,.12); }
}

/* Page header on inner pages */
.page-head { background: radial-gradient(ellipse at 80% 0%, #2c3872 0%, var(--navy) 55%, var(--navy-deep) 100%); color: #fff; padding: clamp(56px, 8vw, 96px) 0 clamp(48px, 6vw, 76px); }
.page-head h1 { font-size: clamp(3rem, 9vw, 6.2rem); margin-bottom: 18px; }
.page-head .lede { max-width: 660px; font-size: 1.15rem; opacity: .9; margin: 0 0 28px; }
.head-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.preview-note { display: inline-block; background: var(--gold); color: var(--navy); font-weight: 600; font-size: .85rem; border-radius: 999px; padding: 6px 14px; margin: 0 0 20px; }
.load-note { background: var(--pink); color: var(--navy); border-radius: 12px; padding: 12px 16px; font-weight: 500; }

/* Filters */
.filters { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-bottom: 26px; }
.seg { display: inline-flex; background: #fff; border-radius: 999px; padding: 4px; box-shadow: inset 0 0 0 2px var(--field); }
.seg button { font: 600 .9rem var(--body); border: 0; background: none; padding: 9px 16px; border-radius: 999px; cursor: pointer; color: var(--navy); }
.seg button[aria-pressed="true"] { background: var(--navy); color: #fff; }
.filters select, .filters input[type="search"] { font: inherit; font-size: .95rem; padding: 10px 16px; border-radius: 999px; border: 2px solid var(--field); background: #fff; color: var(--ink); }
.filters input[type="search"] { flex: 1 1 220px; min-width: 0; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { font: 600 .85rem var(--body); border: 2px solid var(--field); background: #fff; color: var(--navy); border-radius: 999px; padding: 7px 13px; cursor: pointer; }
.chip[aria-pressed="true"] { background: var(--red); border-color: var(--red); color: #fff; }
.result-count { color: var(--muted); font-weight: 500; margin: -8px 0 20px; }
.filters + .filters { margin-top: -14px; }
.filter-clear { color: var(--red-dark); font-weight: 600; font-size: .9rem; }

/* Calendar rows */
.cal-body { min-width: 0; }
.cal-kicker { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-bottom: 4px; }
.tag { font-size: .72rem; font-weight: 600; letter-spacing: .03em; background: var(--pink); color: var(--navy); border-radius: 999px; padding: 2px 9px; }
.tag-sing { background: var(--red); color: #fff; }
.tag-example { background: var(--gold); color: var(--navy); }
.cal-row.featured .tag-sing { background: #fff; color: var(--red); }
.cal-type { font-size: .72rem; font-weight: 600; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); }
.month-head { list-style: none; font-family: var(--display); font-weight: 900; text-transform: uppercase; font-size: 1.9rem; color: var(--navy); margin: 18px 0 0; }
.month-head:first-child { margin-top: 0; }
.cal-row.full { grid-template-columns: 110px 1fr auto auto; align-items: start; }
.cal-row.full .btn { align-self: center; }
.cal-desc { margin: 8px 0 0; max-width: 640px; }
.cal-facts { display: flex; flex-wrap: wrap; gap: 6px 16px; margin: 6px 0 0; font-size: .9rem; font-weight: 600; color: var(--navy); }
.cal-img { width: 120px; height: 120px; object-fit: cover; border-radius: 12px; }
.empty { list-style: none; padding: 30px; text-align: center; color: var(--muted); background: #fff; border-radius: var(--radius); }

.subscribe { display: grid; grid-template-columns: 1.1fr 1fr; gap: 40px; align-items: center; }
.subscribe p { color: var(--muted); font-size: 1.08rem; }
.subscribe-box a:not(.btn), .form-intro a:not(.btn), .private a:not(.btn), .form-thanks a:not(.btn) { color: var(--red-dark); }
.subscribe-box { display: flex; flex-wrap: wrap; gap: 10px; background: var(--cream); border-radius: var(--radius); padding: 28px; }
.subscribe-box .help { flex-basis: 100%; margin: 4px 0 0; }

/* Home: choir + shop promos */
.promo { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
.promo > a { display: block; border-radius: var(--radius); padding: clamp(28px, 4vw, 44px); text-decoration: none; color: #fff; background: var(--navy); transition: transform .15s; }
.promo > a:hover { transform: translateY(-3px); }
.promo > a.promo-red { background: var(--red); }
.promo h3 { color: #fff; font-size: clamp(2.2rem, 4vw, 3rem); margin: 0 0 12px; }
.promo p { margin: 0 0 18px; }
.promo .go { font-weight: 700; }

/* Choir directory */
.choir-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(310px, 1fr)); gap: 22px; }
.choir { background: #fff; border-radius: var(--radius); overflow: hidden; box-shadow: 0 1px 0 var(--line), 0 10px 30px rgba(28,36,75,.06); display: flex; flex-direction: column; }
.choir-img { width: 100%; height: 170px; object-fit: cover; display: block; }
.choir-img-blank { display: grid; place-items: center; height: 96px; background: linear-gradient(135deg, var(--navy), #2c3872); color: var(--gold); font-family: var(--display); font-weight: 900; font-size: 2.8rem; letter-spacing: .08em; }
.choir-body { padding: 22px 24px 24px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.choir h3 { font-size: 1.9rem; }
.choir p { margin: 0; color: var(--muted); }
.badges { display: flex; flex-wrap: wrap; gap: 6px; }
.badge { font-size: .8rem; font-weight: 600; border-radius: 999px; padding: 4px 11px; }
.badge-green { background: #dcf2e2; color: #1b6532; }
.badge-navy { background: #e3e6f3; color: var(--navy); }
.badge-gold { background: #fff0c7; color: #6f4f00; }
.badge-grey { background: #eeeeee; color: #555; }
.facts { display: grid; grid-template-columns: auto 1fr; gap: 6px 14px; margin: 4px 0 0; font-size: .92rem; }
.facts dt { font-weight: 600; color: var(--navy); }
.facts dd { margin: 0; }
.job-list { max-width: 780px; gap: 10px 24px; font-size: 1rem; }
.job-list dt { font-family: var(--display); font-weight: 900; text-transform: uppercase; font-size: 1.25rem; }
.job-list dd { color: var(--muted); }
.choir-links { display: flex; flex-wrap: wrap; gap: 10px; margin-top: auto; padding-top: 8px; }
.updated { font-size: .78rem; }

.signup-block { text-align: center; }
.signup-block .signup input { border-color: var(--field); }
.signup-block .signup input:focus { border-color: var(--red); }
.signup-block p { color: var(--muted); }

/* Find a choir quiz */
.quiz { background: #fff; border-radius: var(--radius); padding: clamp(26px, 5vw, 44px); box-shadow: 0 10px 30px rgba(28,36,75,.06); }
.quiz-progress { color: var(--muted); font-weight: 600; font-size: .85rem; text-transform: uppercase; letter-spacing: .1em; margin: 0 0 10px; }
.quiz-ask { font-size: clamp(2rem, 5vw, 3rem); margin-bottom: 24px; }
.quiz-ask:focus { outline: none; }
.quiz-options { display: flex; flex-direction: column; gap: 10px; }
.quiz-option { font: 600 1.05rem var(--body); text-align: left; background: var(--cream); border: 2px solid var(--field); border-radius: 14px; padding: 16px 20px; cursor: pointer; color: var(--ink); transition: transform .12s, border-color .12s; }
.quiz-option:hover { transform: translateX(3px); border-color: var(--red); }
.quiz-option[aria-pressed="true"] { background: var(--pink); border-color: var(--red); }
.quiz-nav { display: flex; flex-wrap: wrap; gap: 16px; align-items: center; margin-top: 24px; }
.quiz-nav .linklike { color: var(--navy); font-weight: 600; }
.quiz-nav .btn { margin-left: auto; }
.quiz-result-head { margin-bottom: 30px; }
.quiz-result-head .head-actions { margin-top: 22px; }
.why { margin: 0; }
.why li { background: var(--pink); color: var(--navy); font-weight: 600; font-size: .8rem; }

/* Forms */
.form-wrap { max-width: 780px; }
.form-intro { background: var(--cream); border-radius: var(--radius); padding: 18px 22px; margin-bottom: 34px; color: var(--navy); }
.sing-form fieldset { border: 0; padding: 0; margin: 0 0 36px; min-width: 0; }
.sing-form legend { font-family: var(--display); font-weight: 900; text-transform: uppercase; font-size: 1.8rem; color: var(--navy); margin-bottom: 16px; padding: 0; }
.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 18px; min-width: 0; }
.field > label, .field > .label { font-weight: 600; color: var(--navy); }
.field.req > label::after, .field.req > .label::after { content: " *"; color: var(--red); }
.sing-form input:not([type="checkbox"]):not([type="radio"]):not([type="file"]), .sing-form select, .sing-form textarea { font: inherit; padding: 12px 14px; border: 2px solid var(--field); border-radius: 12px; background: #fff; color: var(--ink); width: 100%; }
.sing-form input:focus, .sing-form select:focus, .sing-form textarea:focus { outline: none; border-color: var(--red); }
.sing-form textarea { min-height: 120px; resize: vertical; }
.sing-form input[type="file"] { font: inherit; font-size: .9rem; }
.help { color: var(--muted); font-size: .86rem; margin: 0; }
.row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }
.row-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0 16px; }
.checks { display: flex; flex-wrap: wrap; gap: 8px; }
.checks label { display: inline-flex; align-items: center; gap: 8px; background: #fff; border: 2px solid var(--field); border-radius: 999px; padding: 7px 14px; cursor: pointer; font-weight: 500; }
.checks label:has(input:checked) { border-color: var(--red); background: var(--pink); }
.checks input, .consent input { accent-color: var(--red); }
.private { background: var(--cream); border-radius: var(--radius); padding: 22px 22px 6px; }
.private legend { float: left; width: 100%; }
.private legend + * { clear: both; }
.consent { display: flex; gap: 10px; align-items: flex-start; font-weight: 500; margin-bottom: 18px; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-status { color: var(--red); font-weight: 600; min-height: 1.5em; margin: 12px 0 0; }
.form-progress { margin: 12px 0 0; }
.form-progress:empty { display: none; }
.form-thanks .upload-missed { color: var(--navy); font-weight: 600; background: #fff; border-radius: 12px; padding: 12px 16px; margin: 16px auto; max-width: 560px; }
.form-thanks { background: var(--cream); border-radius: var(--radius); padding: clamp(28px, 5vw, 48px); text-align: center; }
.form-thanks h2 { margin-bottom: 12px; }
.form-thanks p { color: var(--muted); font-size: 1.08rem; }
.preview-sent { color: var(--navy) !important; font-weight: 600; }

/* Shop */
.shop-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 24px; }
.product { background: #fff; border-radius: var(--radius); overflow: hidden; box-shadow: 0 1px 0 var(--line), 0 10px 30px rgba(28,36,75,.06); display: flex; flex-direction: column; }
.product-img { position: relative; aspect-ratio: 1; background: var(--pink); display: grid; place-items: center; overflow: hidden; }
.product-img img { width: 100%; height: 100%; object-fit: cover; }
.product-placeholder { font-family: var(--display); font-weight: 900; font-size: 4.5rem; color: var(--red); transform: rotate(-6deg); }
.product-body { padding: 20px 22px 24px; display: flex; flex-direction: column; gap: 8px; flex: 1; align-items: flex-start; }
.product h3 { font-size: 1.8rem; }
.product p { margin: 0; color: var(--muted); }
.product .price { font-weight: 700; color: var(--red); font-size: 1.15rem; }
.product .btn, .product .inline-field { margin-top: auto; }
.img-pick { position: absolute; left: 10px; bottom: 10px; background: var(--navy); color: #fff; font-size: .8rem; font-weight: 600; padding: 6px 12px; border-radius: 999px; cursor: pointer; }
.img-pick input { display: none; }
.inline-field { width: 100%; display: flex; flex-direction: column; gap: 4px; font-size: .8rem; font-weight: 600; color: var(--navy); }
.inline-field input { font: inherit; font-weight: 400; padding: 8px 10px; border: 2px solid var(--gold); border-radius: 8px; width: 100%; }
.add-product { border: 3px dashed var(--line); background: transparent; font: 700 1.1rem var(--body); color: var(--navy); cursor: pointer; min-height: 320px; align-items: center; justify-content: center; box-shadow: none; }
body.editing .product [contenteditable] { outline: 2px dashed rgba(220,35,69,.45); outline-offset: 3px; border-radius: 4px; cursor: text; }
.shop-note { margin-top: 30px; color: var(--muted); }
.buy-row { margin-top: auto; width: 100%; display: flex; flex-direction: column; align-items: flex-start; gap: 10px; padding-top: 6px; }
.buy-row .btn { margin-top: 0; }
.buy-row .form-status { margin: 0; min-height: 0; font-size: .9rem; }
.inline-field select { font: inherit; font-weight: 400; padding: 9px 10px; border: 2px solid var(--field); border-radius: 8px; width: 100%; background: #fff; color: var(--ink); }
.shop-thanks { margin-bottom: 30px; }
#shopEditNote { margin-bottom: 20px; }

@media (max-width: 760px) {
  .promo, .subscribe { grid-template-columns: 1fr; }
  .cal-row.full { grid-template-columns: 70px 1fr; }
  .cal-row.full .cal-img { grid-column: 2; width: 100%; height: 170px; }
  .row-2, .row-3 { grid-template-columns: 1fr; }
}
