/*
Theme Name: Colette Avital
Theme URI: https://coletteavital.org.il/
Author: Colette Avital
Description: תבנית מותאמת לאתר קולט אביטל, משחזרת את עיצוב האתר המקורי כתבנית וורדפרס דינמית.
Version: 1.1.0
Requires at least: 6.0
Requires PHP: 7.4
Text Domain: colette-avital
*/

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html, body { min-height: 100%; }
body {
	margin: 0;
	direction: rtl;
	color: #0F2A38;
	font: 13px/1.5 Khmer, Arial, "Arial Unicode MS", Helvetica, sans-serif;
	background: #7D84BB linear-gradient(180deg, #E8E9F3 0, #5861A7 695px, #31365E 1050px) no-repeat fixed;
}
a { color: #328DBD; text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; height: auto; }
h1, h2, h3, h4, h5, h6 { font-family: "Didact Gothic", Arial, "Arial Unicode MS", Helvetica, sans-serif; font-weight: normal; line-height: 1.2; color: #65838B; margin: 10px 0 0; }
h1 { font-size: 26px; } h2 { font-size: 22px; } h3 { font-size: 20px; } h4 { font-size: 16px; } h5 { font-size: 14px; }
.screen-reader-text { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(1px,1px,1px,1px); }

.site { max-width: 960px; margin: 0 auto; }

/* ---------- Header ---------- */
.site-header { position: relative; border-radius: 5px 5px 0 0; overflow: hidden; }
.site-header img { display: block; width: 100%; height: auto; }
.site-header .site-branding-text { padding: 60px 20px; text-align: center; }
.site-header .site-title { font: 40px "Didact Gothic", Arial, sans-serif; color: #133649; margin: 0; }

/* ---------- Sheet ---------- */
.sheet { background: #fff; border-radius: 5px; box-shadow: 0 0 7px 4px rgba(0,0,0,.1); padding: 5px; }

/* ---------- Main navigation ---------- */
.main-nav { background: #000; border-radius: 3px; padding: 3px; position: relative; z-index: 100; }
.main-nav ul { list-style: none; margin: 0; padding: 0; }
.main-nav > .menu-toggle { display: none; }
.main-nav .menu { display: flex; justify-content: center; flex-wrap: wrap; }
.main-nav .menu > li { position: relative; }
.main-nav .menu > li + li::before { content: ""; position: absolute; right: -1px; top: 12px; bottom: 12px; width: 1px; background: #333; }
.main-nav .menu > li > a {
	display: flex; flex-direction: column; justify-content: center; align-items: center;
	height: 50px; padding: 0 34px; color: #D6DFE1; font-size: 14px; text-decoration: none; text-align: center; line-height: 1.35;
}
.main-nav .menu > li > a .menu-en { font-size: 12px; color: #A9C3CC; }
.main-nav .menu > li > a:hover, .main-nav .menu > li:hover > a { color: #DFEEF6; background: #1b1b1b; }
.main-nav .menu > li.current-menu-item > a,
.main-nav .menu > li.current-menu-ancestor > a,
.main-nav .menu > li.current_page_item > a { background: #2A759D; color: #fff; }
.main-nav .menu > li.current-menu-item > a .menu-en,
.main-nav .menu > li.current-menu-ancestor > a .menu-en { color: #E3F1F8; }

.main-nav .sub-menu {
	position: absolute; top: 100%; right: 0; min-width: 200px; padding: 8px 0;
	background: rgba(66,86,92,.95); visibility: hidden; opacity: 0; transition: opacity .15s;
}
.main-nav li:hover > .sub-menu, .main-nav li:focus-within > .sub-menu { visibility: visible; opacity: 1; }
.main-nav .sub-menu .sub-menu { top: 0; right: 100%; }
.main-nav .sub-menu a { display: block; padding: 0 22px; line-height: 39px; color: #D9E1E3; font-size: 13px; white-space: nowrap; text-align: right; }
.main-nav .sub-menu a:hover { background: #DFEEF6; color: #000; text-decoration: none; }

/* ---------- Layout ---------- */
.layout { display: flex; margin-top: 10px; align-items: stretch; }
.content-area { flex: 1 1 auto; min-width: 0; }
.sidebar { flex: 0 0 250px; border-right: 1px solid #A9BCC1; }

/* ---------- Posts ---------- */
.post-box { background: rgba(222,229,231,.6); padding: 3px; margin: 10px; }
.post-box-header { background: rgba(130,190,222,.5); border-bottom: 1px solid #56A7D2; padding: 1px 8px; margin-bottom: 5px; }
.post-title { font-size: 26px; color: #133649; margin: 5px 0; }
.post-title a { color: #133649; }
.post-title a:hover { color: #356D7E; text-decoration: none; }
.post-meta { font-size: 12px; color: #45595F; padding: 0 8px 4px; }
.entry { padding: 0 10px 6px; }
.entry p { margin: 12px 0; }
.entry h1, .entry h2, .entry h3, .entry h4 { color: #65838B; }
.entry ul, .entry ol { margin: 1em 18px 1em 0; padding: 0; }
.entry li { margin: 5px 0; }
.entry img { border: 1px solid #5DA5BB; }
.entry img.alignleft, .entry .alignleft { float: left; margin: 7px 0 7px 14px; }
.entry img.alignright, .entry .alignright { float: right; margin: 7px 14px 7px 0; }
.entry .aligncenter { display: block; margin: 7px auto; }
.entry iframe { max-width: 100%; }
.entry::after { content: ""; display: table; clear: both; }
.entry blockquote { margin: 12px 20px; padding: 6px 14px; border-right: 3px solid #82BEDE; background: rgba(255,255,255,.5); }
.entry .wp-caption { max-width: 100%; }
.entry .wp-caption-text { font-size: 12px; color: #45595F; }
.ltr, .entry .ltr { direction: ltr; text-align: left; }
.read-more { display: inline-block; margin: 4px 0 8px; font-weight: bold; }
.post-thumb { float: right; margin: 6px 0 8px 12px; }
.post-thumb img { border: 1px solid #5DA5BB; display: block; }

.more-in-section { background: rgba(222,229,231,.6); padding: 10px 14px; margin: 10px; }
.more-in-section strong { display: block; margin-bottom: 6px; color: #0F2A38; }
.more-in-section ul { list-style: none; margin: 0; padding: 0; }
.more-in-section li { position: relative; padding-right: 14px; margin: 5px 0; }
.more-in-section li::before { content: ""; position: absolute; right: 0; top: .55em; width: 6px; height: 6px; background: #328DBD; }

.pagination { margin: 10px; text-align: center; }
.pagination .page-numbers { display: inline-block; padding: 4px 10px; margin: 2px; border: 1px solid #25698D; color: #25698D; }
.pagination .page-numbers.current { background: #328DBD; color: #fff; }
.archive-header { margin: 10px; padding: 8px 10px; background: rgba(130,190,222,.5); border-bottom: 1px solid #56A7D2; }
.archive-header h1 { margin: 0; color: #133649; }

/* ---------- Sidebar widgets ---------- */
.widget { margin: 10px; }
.widget-title { background: #328DBD; border: 1px solid #25698D; padding: 10px 15px; margin: 0 0 15px; color: #D6DFE1; font-size: 20px; line-height: 24px; }
.widget-content, .widget > :not(.widget-title) { padding: 0 5px; color: #113040; font-size: 12px; }
.widget ul { list-style: none; margin: 0; padding: 0; }
.widget li { position: relative; padding-right: 14px; margin: 5px 10px 0 0; font-size: 13px; color: #18323A; }
.widget li::before { content: ""; position: absolute; right: 0; top: .55em; width: 5px; height: 5px; background: #328DBD; }
.widget img { border: 1px solid #5DA5BB; }
.widget a:visited { color: #27515D; }

.search-form { position: relative; }
.search-form .search-field { width: 100%; padding: 8px 10px 8px 34px; border: 1px solid #A9BCC1; background: #fff; color: #113040; font: 13px Khmer, Arial, sans-serif; border-radius: 0; }
.search-form .search-submit { position: absolute; left: 0; top: 0; bottom: 0; width: 32px; border: 0; background: transparent; cursor: pointer; padding: 0; }
.search-form .search-submit svg { width: 16px; height: 16px; fill: #328DBD; vertical-align: middle; }

/* ---------- Footer ---------- */
.site-footer { background: #C7D3D6; border-radius: 3px; border-top: 1px solid #A9BCC1; padding: 10px; margin-top: 10px; color: #181F21; text-align: center; }
.site-footer p { margin: 4px 0; }
.site-footer a { color: #27515D; }
.site-footer .footer-menu { list-style: none; margin: 0 0 4px; padding: 0; display: flex; justify-content: center; flex-wrap: wrap; }
.site-footer .footer-menu li + li::before { content: "|"; margin: 0 6px; color: #45595F; }
.site-footer .widget { margin: 0; }
.page-footer { padding: 10px; text-align: center; font: 10px Arial, sans-serif; color: #1C4E69; }
.page-footer a { color: #1C4E69; text-decoration: underline; }

/* ---------- Gallery ---------- */
.gallery { display: grid; gap: 10px; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); margin: 12px 0 !important; }
.gallery .gallery-item { margin: 0 !important; width: auto !important; text-align: center; }
.gallery img { border: 1px solid #5DA5BB !important; }
.gallery-caption { font-size: 12px; }

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
	.site { margin: 0 10px; }
	.main-nav .menu > li > a { padding: 0 18px; }
}
@media (max-width: 760px) {
	.layout { flex-direction: column; }
	.sidebar { flex-basis: auto; border-right: 0; border-top: 1px solid #A9BCC1; }
	.main-nav > .menu-toggle {
		display: block; width: 100%; background: transparent; color: #fff; border: 0;
		font: 16px Khmer, Arial, sans-serif; padding: 12px; cursor: pointer; text-align: right;
	}
	.main-nav .menu { display: none; flex-direction: column; }
	.main-nav.is-open .menu { display: flex; }
	.main-nav .menu > li + li::before { display: none; }
	.main-nav .menu > li > a { height: auto; padding: 10px 14px; align-items: flex-start; flex-direction: row; gap: 8px; }
	.main-nav .sub-menu { position: static; visibility: visible; opacity: 1; background: #222; min-width: 0; padding: 0; }
	.main-nav .sub-menu a { padding-right: 30px; }
	.post-title { font-size: 22px; }
	.post-thumb { float: none; margin: 6px 0; }
}

/* ---------- Accessibility: base ---------- */
a:focus-visible, button:focus-visible, input:focus-visible, [tabindex]:focus-visible { outline: 3px solid #F5A623; outline-offset: 2px; }
.skip-link:focus { position: fixed !important; top: 8px; right: 8px; width: auto; height: auto; clip: auto; z-index: 100000; background: #fff; color: #133649; padding: 10px 16px; border: 2px solid #133649; }
.footer-a11y { font-size: 12px; }

/* ---------- Accessibility widget ---------- */
.a11y-widget { position: fixed; left: 12px; bottom: 90px; z-index: 9998; direction: rtl; }
.a11y-toggle { width: 48px; height: 48px; border-radius: 50%; border: 2px solid #fff; background: #1d5c86; color: #fff; cursor: pointer; box-shadow: 0 2px 8px rgba(0,0,0,.35); display: flex; align-items: center; justify-content: center; padding: 0; }
.a11y-toggle svg { width: 28px; height: 28px; fill: #fff; }
.a11y-panel { position: absolute; left: 0; bottom: 58px; width: 220px; background: #fff; border: 1px solid #25698D; border-radius: 6px; box-shadow: 0 4px 16px rgba(0,0,0,.25); padding: 10px; display: flex; flex-direction: column; gap: 6px; }
.a11y-panel[hidden] { display: none; }
.a11y-title { margin: 0 0 4px; font: bold 16px Arial, sans-serif; color: #133649; }
.a11y-panel button { font: 14px Arial, sans-serif; text-align: right; padding: 8px 10px; border: 1px solid #A9BCC1; background: #F3F7F8; color: #0F2A38; border-radius: 4px; cursor: pointer; }
.a11y-panel button:hover { background: #DFEEF6; }
.a11y-panel button[aria-pressed="true"] { background: #1d5c86; color: #fff; border-color: #1d5c86; }
.a11y-panel .a11y-reset { background: #fff; }
.a11y-panel .a11y-close { background: #fff; text-align: center; }
.a11y-panel .a11y-statement { font: 14px Arial, sans-serif; text-align: center; padding: 4px; color: #1d5c86; text-decoration: underline; }

/* Accessibility modes */
html.a11y-contrast body { background: #000 !important; }
html.a11y-contrast .sheet, html.a11y-contrast .post-box, html.a11y-contrast .more-in-section, html.a11y-contrast .site-footer, html.a11y-contrast .post-box-header, html.a11y-contrast .archive-header, html.a11y-contrast .widget-title { background: #000 !important; color: #fff !important; border-color: #fff !important; }
html.a11y-contrast body, html.a11y-contrast p, html.a11y-contrast li, html.a11y-contrast h1, html.a11y-contrast h2, html.a11y-contrast h3, html.a11y-contrast h4, html.a11y-contrast .post-title, html.a11y-contrast .widget-content, html.a11y-contrast .page-footer { color: #fff !important; }
html.a11y-contrast a, html.a11y-contrast .post-title a { color: #FFEB3B !important; }
html.a11y-contrast .main-nav .menu > li > a, html.a11y-contrast .main-nav .menu-en { color: #fff !important; }
html.a11y-grayscale body > *:not(.a11y-widget) { filter: grayscale(1); }
html.a11y-links a { text-decoration: underline !important; outline: 1px dashed currentColor; outline-offset: 1px; }
html.a11y-readable body, html.a11y-readable body * { font-family: Arial, Helvetica, sans-serif !important; letter-spacing: .02em; }
html.a11y-noanim *, html.a11y-noanim *::before, html.a11y-noanim *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
html.a11y-cursor, html.a11y-cursor * { cursor: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='40' height='40'><path d='M4 2l26 14-11 3-5 11z' fill='black' stroke='white' stroke-width='2'/></svg>") 4 2, auto !important; }
html.a11y-resized body { font-size: 1rem; }
html.a11y-resized .main-nav .menu > li > a { height: auto; min-height: 50px; padding-top: 6px; padding-bottom: 6px; }

/* ---------- Cookie banner ---------- */
.cookie-banner { position: fixed; bottom: 0; right: 0; left: 0; z-index: 9999; background: rgba(15,42,56,.97); color: #fff; display: flex; align-items: center; justify-content: center; gap: 16px; flex-wrap: wrap; padding: 12px 16px; font: 14px Arial, sans-serif; box-shadow: 0 -2px 10px rgba(0,0,0,.3); }
.cookie-banner[hidden] { display: none; }
.cookie-banner p { margin: 0; }
.cookie-banner a { color: #9fd3f0; text-decoration: underline; }
.cookie-accept { background: #328DBD; color: #fff; border: 0; padding: 8px 22px; border-radius: 3px; font: bold 14px Arial, sans-serif; cursor: pointer; }
.cookie-accept:hover { background: #2A759D; }
@media (max-width: 760px) { .a11y-widget { bottom: 110px; } }
