/* רדיו סהר - עיצוב האתר (הועבר מתוך index.html והורחב) */

.sr-only {
	position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
	overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}

/* קישור דילוג - מופיע רק כשמגיעים אליו במקלדת */
.skip-link {
	position: absolute; top: -100px; right: 1rem; z-index: 10001;
	background: #8B0000; color: #fff; padding: .75rem 1.25rem; border-radius: 0 0 6px 6px;
	font-weight: bold; text-decoration: none;
}
html[dir="ltr"] .skip-link { right: auto; left: 1rem; }
.skip-link:focus { top: 0; color: #fff; }

a:focus, button:focus, input:focus, select:focus, textarea:focus, iframe:focus, [role="button"]:focus {
	outline: 3px solid #8B0000;
	outline-offset: 2px;
}

/* ===== סרגל עליון ===== */
.top-bar {
	display: flex; flex-wrap: wrap; gap: 1rem; justify-content: flex-end; align-items: center;
	padding: .6rem 1rem; background: rgba(255, 255, 255, 0.95); border-bottom: 2px solid #8B0000;
	position: relative; z-index: 10;
}
.top-bar-item { display: flex; align-items: center; gap: .5rem; }
.top-bar label { margin: 0; font-weight: bold; color: #333; white-space: nowrap; flex-shrink: 0; }
.top-bar select { width: auto; min-width: 0; max-width: 100%; height: 2.4rem; }
.toolbar-button, .a11y-actions button, .song-form button, #loadMoreSongs, .song-results button, .modal-alert button {
	height: auto; line-height: 1.4; padding: .55rem 1.1rem; text-transform: none; white-space: normal;
	background-color: #8B0000; color: #fff !important; font-weight: bold; font-size: 1rem; border-radius: 5px;
}
.toolbar-button:hover, .toolbar-button:focus, .a11y-actions button:hover, .a11y-actions button:focus,
.song-form button:hover, .song-form button:focus, #loadMoreSongs:hover, #loadMoreSongs:focus {
	background-color: #5c0000; color: #fff !important;
}
.toolbar-button[aria-expanded="true"] { background-color: #333; }

/* ===== לוח אפשרויות הנגישות ===== */
.a11y-panel {
	background: #fff; border: 2px solid #8B0000; border-radius: 6px; margin: .75rem auto; padding: 1rem 1.25rem;
	width: 60rem; max-width: 92%; color: #222; position: relative; z-index: 10;
}
.a11y-panel h2 { color: #8B0000; font-size: 1.3em; margin: 0 0 .5rem; }
.a11y-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(14rem, 1fr)); gap: .75rem 1.5rem; margin: .75rem 0; }
.a11y-field label { display: block; font-weight: bold; margin-bottom: .25rem; }
.a11y-field select { width: 100%; height: 2.4rem; }
.a11y-check { display: flex; align-items: center; gap: .5rem; }
.a11y-check input[type="checkbox"] {
	/* התבנית מסתירה תיבות סימון; כאן הן חייבות להיות אמיתיות וגלויות */
	position: relative; z-index: 1; opacity: 1; width: 1.3rem; height: 1.3rem; margin: 0; appearance: auto; -webkit-appearance: checkbox; float: none; display: inline-block;
}
.a11y-check label { margin: 0; padding: 0; cursor: pointer; font-weight: normal; }
.a11y-check label:before, .a11y-check label:after { display: none !important; content: none !important; }
.a11y-wide { grid-column: 1 / -1; }
.a11y-actions { display: flex; flex-wrap: wrap; gap: .75rem; }

/* ===== אזור התוכן ===== */
#main { display: block; }
#main .inner {
	margin: 0 auto 2rem; width: 60rem; max-width: 90%;
	background: rgba(255, 255, 255, 0.95);
	box-shadow: 0 0 15px 0 rgba(0, 0, 0, 0.75);
	border-radius: 4px; padding: 1.5rem;
}
.extra-section { padding: 0; }
.section-wrapper { margin-bottom: 10px; }
h2.section-heading { margin: 0; padding: 0; font-size: 1em; border: 0; }
h2.section-heading:after, h2.section-heading:before { display: none; }

.section-button {
	width: 100%; padding: 20px; background-color: #f8f9fa; border: 1px solid #ddd; border-radius: 5px;
	cursor: pointer; font-size: 1.2em; font-weight: bold; color: #8B0000 !important;
	display: inline-block; vertical-align: top; box-sizing: border-box; position: relative; padding-inline-end: 3.2em;
	height: auto; line-height: 1.4; text-transform: none; white-space: normal; text-align: start;
	margin-bottom: 10px; transition: background-color .3s;
}
.section-button:hover, .section-button:focus { background-color: #e9ecef; color: #8B0000 !important; }
.section-button.active, .section-button.active:hover, .section-button.active:focus { background-color: #8B0000; color: #fff !important; }
.section-indicator { font-size: 1.2em; transition: transform .3s; position: absolute; inset-inline-end: 20px; top: 50%; transform: translateY(-50%); line-height: 1; }
.section-button.active .section-indicator { transform: translateY(-50%) rotate(90deg); }
/* המצב ("פתוח" / "סגור") של כל כותרת: מוסתר מהעין, ונמצא באותה שורה של הכותרת אצל קוראי המסך
   (הכותרת והמצב הם רכיבים "בתוך השורה", ולכן NVDA ו-JAWS מקריאים אותם יחד ולא כשורה נפרדת) */
.section-status { position: static !important; display: inline-block !important; width: 1px !important; height: 1px !important; overflow: hidden !important; clip-path: inset(50%) !important; white-space: nowrap !important; margin: 0 -1px 0 0 !important; padding: 0 !important; border: 0 !important; vertical-align: top; }

.content-area {
	min-height: 400px; padding: 20px; background-color: #fff; border-radius: 5px; border: 1px solid #ddd;
	margin-bottom: 20px; color: #222; line-height: 1.6;
}
.content-area[hidden] { display: none; }
.content-area iframe { width: 100%; border: none; display: block; }
.content-area iframe.frame-player { height: 760px; }
.content-area iframe.frame-tall { height: 620px; }
.content-area iframe.frame-auto { height: 320px; }
.content-area ul { list-style: disc; padding-inline-start: 1.5rem; margin-bottom: 1rem; }
.content-area ul.contact-links { list-style: none; padding: 0; }
.content-area li { margin-bottom: .5rem; }
.content-area h3 { color: #8B0000; font-size: 1.35em; margin: 1.6rem 0 .8rem; border-bottom: 2px solid #8B0000; padding-bottom: .3rem; }
.content-area h4 { color: #8B0000; font-size: 1.1em; margin: 1.2rem 0 .4rem; }
.content-area a { color: #8B0000; text-decoration: underline; font-weight: bold; }
.content-area a:hover, .content-area a:focus { background-color: #8B0000; color: #fff; }

.highlight-box { background-color: #fff5f5; border: 1px solid #8B0000; padding: 15px; border-radius: 5px; margin: 15px 0; }
.contact-info { background-color: #f8f9fa; padding: 20px; border-radius: 8px; border: 2px solid #8B0000; margin: 20px 0; }
.contact-info h3 { margin-top: 0; border: 0; }
.contact-label { font-weight: bold; color: #333; }
.fb-like-container { margin-top: 20px; padding-top: 20px; border-top: 1px solid #ddd; }

/* ===== בקשת שירים ===== */
.song-form { margin: 1rem 0; }
.song-form label { display: block; font-weight: bold; margin-bottom: .35rem; color: #333; }
.song-search-row { display: flex; gap: .5rem; flex-wrap: wrap; }
.song-search-row input { flex: 1 1 14rem; }
.hint { font-size: .9em; color: #555; margin: .35rem 0 0; }
.song-results { list-style: none !important; padding: 0 !important; margin: 0 0 1rem; max-height: 22rem; overflow-y: auto; }
.song-results:empty { display: none; }
.song-results li { margin: 0 0 .4rem; }
.song-results button {
	width: 100%; text-align: start; background: #f8f9fa; color: #222 !important; border: 1px solid #ccc; font-weight: normal;
}
.song-results button:hover, .song-results button:focus { background: #e9ecef; color: #000; }
.song-results button[aria-pressed="true"] { background: #8B0000; color: #fff !important; }
.song-form textarea { width: 100%; }
.song-request-actions { display: flex; gap: .75rem; flex-wrap: wrap; margin-top: .75rem; }
.song-form .secondary-button { background-color: #555; }
#songRequestResult:empty { display: none; }
#songRequestResult.success { background-color: #d4edda; color: #155724; border: 1px solid #c3e6cb; padding: 10px; margin-top: 10px; border-radius: 5px; }
#songRequestResult.error { background-color: #f8d7da; color: #721c24; border: 1px solid #f5c6cb; padding: 10px; margin-top: 10px; border-radius: 5px; }

/* ===== הודעה כללית ===== */
.modal-overlay { position: fixed; inset: 0; background-color: rgba(0, 0, 0, .6); z-index: 9998; display: none; }
.modal-alert {
	position: fixed; top: 50%; left: 50%; transform: translate(-50%, -50%); background: #fff; border: 2px solid #8B0000;
	border-radius: 8px; padding: 25px; min-width: 300px; max-width: 90%; z-index: 9999; text-align: center;
	box-shadow: 0 4px 15px rgba(0, 0, 0, .3);
}
.modal-alert[hidden] { display: none; }
.modal-alert p { font-size: 1.1em; margin: 0 0 20px; color: #333; line-height: 1.5; text-align: start; }

/* ===== דיאלוגי הקלטה ===== */
.recording-modal-overlay { display: none; position: fixed; inset: 0; background: rgba(0, 0, 0, .6); z-index: 10000; justify-content: center; align-items: center; }
.recording-modal-overlay.active { display: flex; }
.recording-modal-dialog { background: #fff; padding: 30px; border-radius: 15px; box-shadow: 0 8px 24px rgba(0, 0, 0, .3); max-width: 500px; width: 90%; text-align: start; }
.recording-modal-dialog h2 { margin-top: 0; color: #333; font-size: 1.4em; }
.recording-modal-dialog p { color: #555; margin: 15px 0; line-height: 1.5; }
.recording-modal-buttons { display: flex; flex-wrap: wrap; gap: 10px; justify-content: flex-end; margin-top: 20px; }
.recording-modal-buttons button { font-size: 16px; padding: 10px 20px; height: auto; line-height: 1.4; border-radius: 8px; border: none; background-color: #007cba; color: #fff !important; text-transform: none; }
.recording-modal-buttons button:hover { background-color: #005a87; }
.recording-modal-buttons button:focus { outline: 3px solid #ffa500; outline-offset: 2px; }
.recording-modal-buttons .danger { background-color: #c33; }
.recording-modal-buttons .secondary { background-color: #666; }

#main header.special p { color: #444; }
#footer .site-links { display: flex; flex-wrap: wrap; justify-content: center; gap: .4rem 1.2rem; margin-bottom: 1rem; }
#footer .site-links a { color: #fff; text-decoration: underline; font-weight: bold; }
#footer .copyright img { vertical-align: middle; max-height: 2.5rem; }

@media screen and (max-width: 600px) {
	#main .inner { padding: 1rem; max-width: 96%; }
	.content-area { padding: 12px; }
	.content-area iframe.frame-player { height: 900px; }
	.content-area iframe.frame-tall { height: 75vh; }
	.top-bar { justify-content: center; }
}
.a11y-field input[type="range"] { width: 100%; }
