/* קרן ישמח דוד — עיצוב האתר */

:root {
  --gold: oklch(72% 0.11 82);
  --gold-soft: oklch(78% 0.12 82);
  --ink: oklch(21.5% 0.018 264);
  --focus-ring: oklch(72% 0.11 82 / 0.55);
}

body {
  margin: 0;
  background:
    radial-gradient(ellipse 900px 500px at 12% -8%, oklch(30% 0.035 82 / 0.16), transparent 60%),
    radial-gradient(ellipse 700px 500px at 100% 0%, oklch(32% 0.03 255 / 0.14), transparent 55%),
    oklch(21.5% 0.018 264);
  background-attachment: fixed;
  font-family: 'Heebo', sans-serif;
  direction: rtl;
  color: oklch(90% 0.015 85);
  -webkit-font-smoothing: antialiased;
}
* { box-sizing: border-box; }
a { color: oklch(78% 0.13 82); text-decoration: none; transition: color 0.15s ease; }
a:hover { color: oklch(85% 0.14 85); }
input, textarea, select, button { font-family: 'Heebo', sans-serif; }
::placeholder { color: oklch(50% 0.02 264); }
:focus-visible { outline: 2px solid var(--focus-ring); outline-offset: 2px; border-radius: 3px; }

@keyframes riseIn { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: translateY(0); } }
.rise { opacity: 0; animation: riseIn 0.6s cubic-bezier(.2,.7,.2,1) forwards; }

@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
#main { animation: fadeIn 0.35s ease; }

.gold-text { color: oklch(72% 0.11 82); }

.cube-card { transition: border-color 0.25s ease, box-shadow 0.25s ease, transform 0.25s ease; will-change: transform; }
.cube-card:hover { border-color: oklch(55% 0.03 85 / 0.55); box-shadow: 0 10px 28px oklch(7% 0 0 / 0.38); transform: translateY(-3px); }
.cube-card .progress-bar { transition: width 0.5s cubic-bezier(.2,.7,.2,1); }

.btn-gold { transition: filter 0.15s ease, border-color 0.15s ease, transform 0.15s ease, box-shadow 0.15s ease; }
.btn-gold:hover { filter: brightness(1.08); transform: translateY(-1px); }
.btn-gold:active { transform: translateY(0); filter: brightness(0.97); }
.btn-primary { box-shadow: 0 4px 14px oklch(70% 0.12 80 / 0.28); }
.btn-primary:hover { box-shadow: 0 6px 20px oklch(70% 0.12 80 / 0.4); }

.nav-link { position: relative; border:none; background:transparent; padding:10px 16px; border-radius:8px; font-size:14.5px; font-weight:600; cursor:pointer; color:oklch(72% 0.02 85); transition: color 0.15s ease, background 0.15s ease; }
.nav-link:hover { color:oklch(85% 0.06 85); }
.nav-link.active { color:oklch(85% 0.1 82); background:oklch(70% 0.12 80 / 0.14); }
.nav-link::after { content:''; position:absolute; right:14px; left:14px; bottom:4px; height:1px; background:oklch(72% 0.12 80); transform:scaleX(0); transition:transform 0.3s ease; }
.nav-link:hover::after, .nav-link.active::after { transform:scaleX(1); }

/* ---- מבנה ---- */
.site-wrap { min-height:100vh; color:oklch(90% 0.015 85); display:flex; flex-direction:column; }
.site-main { flex:1; }

.site-header { position:sticky; top:0; z-index:50; background:oklch(20% 0.015 264 / 0.85); backdrop-filter:blur(14px); border-bottom:1px solid oklch(70% 0.1 80 / 0.18); }
.header-inner { max-width:1240px; margin:0 auto; padding:14px 30px; display:flex; align-items:center; justify-content:space-between; gap:24px; flex-wrap:wrap; }
.brand { display:flex; align-items:center; gap:14px; cursor:pointer; }
.brand-logo { width:52px; height:52px; border-radius:10px; overflow:hidden; border:1.5px solid oklch(70% 0.12 80 / 0.6); box-shadow:0 2px 6px oklch(7% 0 0 / 0.3); flex-shrink:0; }
.brand-logo img { width:100%; height:100%; object-fit:cover; object-position:center 20%; }
.brand-title { font-family:'Frank Ruhl Libre',serif; font-weight:800; font-size:22px; }
.brand-sub { font-size:11.5px; color:oklch(65% 0.02 85); letter-spacing:0.6px; margin-top:3px; }
.main-nav { display:flex; align-items:center; gap:4px; flex-wrap:wrap; }
.header-cta { display:flex; align-items:center; gap:10px; }

/* ---- תפריט המבורגר + מגירה צדדית (מובייל) ---- */
.menu-toggle { display:none; flex-direction:column; justify-content:center; gap:5px; width:38px; height:38px; border:1px solid oklch(70% 0.1 80 / 0.3); border-radius:6px; background:transparent; cursor:pointer; padding:0; flex-shrink:0; }
.menu-toggle span { display:block; width:18px; height:2px; margin:0 auto; background:oklch(80% 0.1 82); border-radius:2px; transition:transform 0.25s ease, opacity 0.2s ease; }
.menu-toggle.open span:nth-child(1) { transform:translateY(7px) rotate(45deg); }
.menu-toggle.open span:nth-child(2) { opacity:0; }
.menu-toggle.open span:nth-child(3) { transform:translateY(-7px) rotate(-45deg); }

.drawer-overlay { position:fixed; inset:0; background:oklch(7% 0 0 / 0.55); opacity:0; pointer-events:none; transition:opacity 0.25s ease; z-index:90; }
.drawer-overlay.open { opacity:1; pointer-events:auto; }

.side-drawer { position:fixed; top:0; bottom:0; right:0; width:300px; max-width:84vw; background:oklch(19% 0.02 264); border-right:1px solid oklch(70% 0.1 80 / 0.2); box-shadow:-12px 0 32px oklch(7% 0 0 / 0.4); z-index:95; transform:translateX(100%); transition:transform 0.3s cubic-bezier(.2,.7,.2,1); display:flex; flex-direction:column; padding:20px; }
.side-drawer.open { transform:translateX(0); }
.drawer-header { display:flex; align-items:center; justify-content:space-between; margin-bottom:18px; padding-bottom:16px; border-bottom:1px solid oklch(70% 0.1 80 / 0.18); }
.drawer-close { background:transparent; border:1px solid oklch(70% 0.1 80 / 0.3); color:oklch(80% 0.02 85); width:32px; height:32px; border-radius:6px; cursor:pointer; font-size:15px; }
.drawer-nav { display:flex; flex-direction:column; gap:4px; flex:1; }
.drawer-nav .nav-link { text-align:right; width:100%; padding:13px 14px; }
.drawer-nav .nav-link::after { display:none; }
.drawer-cta { padding-top:16px; border-top:1px solid oklch(70% 0.1 80 / 0.18); }

@media (max-width: 900px) {
  .main-nav, .header-cta { display:none; }
  .menu-toggle { display:flex; }
}

.site-footer { border-top:1px solid oklch(70% 0.1 80 / 0.2); background:oklch(20% 0.015 264); padding:30px 30px; }
.footer-inner { max-width:1240px; margin:0 auto; display:flex; align-items:center; justify-content:space-between; flex-wrap:wrap; gap:12px; }
.footer-text { font-size:13px; color:oklch(58% 0.02 85); }
.footer-admin { font-size:12.5px; color:oklch(55% 0.02 85); }

/* ---- כפתורים ---- */
.btn-primary { background:oklch(72% 0.11 82); color:oklch(21% 0.02 60); border:none; border-radius:4px; font-weight:700; cursor:pointer; }
.btn-outline { background:transparent; color:oklch(85% 0.1 82); border:1.5px solid oklch(42% 0.015 85 / 0.5); border-radius:4px; font-weight:700; cursor:pointer; }
.btn-sm { padding:11px 22px; font-size:14.5px; border-radius:6px; }
.btn-lg { padding:16px 32px; font-size:16px; }
.btn-lg-outline { padding:14.5px 30px; font-size:16px; }

.pill { padding:9px 16px; border-radius:5px; font-size:13.5px; font-weight:600; cursor:pointer; border:1px solid oklch(40% 0.02 85 / 0.35); background:transparent; color:oklch(75% 0.02 85); transition: all 0.15s ease; }
.pill:hover { border-color: oklch(70% 0.12 80 / 0.5); color: oklch(85% 0.06 85); }
.pill.active { background:oklch(72% 0.11 82); color:oklch(21% 0.02 60); border-color:oklch(72% 0.11 82); }

.tab-btn { border:none; background:transparent; padding:12px 18px; font-size:15px; font-weight:600; cursor:pointer; border-bottom:3px solid transparent; margin-bottom:-1px; color:oklch(60% 0.02 85); transition: color 0.15s ease, border-color 0.2s ease; white-space: nowrap; }
.tab-btn:hover { color: oklch(78% 0.06 85); }
.tab-btn.active { color:oklch(85% 0.11 82); border-bottom-color:oklch(75% 0.13 82); }

/* ---- טפסים ---- */
.form-card { background:oklch(25% 0.02 264); border-radius:6px; border:1px solid oklch(70% 0.1 80 / 0.25); padding:28px; display:flex; flex-direction:column; gap:18px; box-shadow: 0 8px 24px oklch(7% 0 0 / 0.22); }
.form-label { font-size:13.5px; font-weight:600; display:block; margin-bottom:7px; color:oklch(78% 0.02 85); }
.form-input { width:100%; padding:13px 15px; border-radius:5px; border:1px solid oklch(70% 0.1 80 / 0.3); background:oklch(21.5% 0.015 264); color:oklch(93% 0.01 85); font-size:15px; transition: border-color 0.15s ease, background 0.15s ease; }
.form-input:focus { border-color: oklch(70% 0.12 80 / 0.7); background: oklch(23.5% 0.018 264); outline: none; }
textarea.form-input { resize:vertical; font-family:inherit; }
input[type="file"].form-input { padding: 9px 10px; cursor: pointer; }

/* ---- קוביות ---- */
.cubes-grid { display:grid; grid-template-columns:repeat(3, 1fr); gap:18px; }
.progress-track { height:6px; border-radius:4px; background:oklch(7% 0 0 / 0.35); overflow:hidden; margin-bottom:9px; }
.progress-bar { height:100%; border-radius:4px; }

/* ---- כותרות עמוד ---- */
.page-title { font-family:'Frank Ruhl Libre',serif; font-size:33px; font-weight:800; margin:0 0 12px; color:oklch(93% 0.01 85); }
.page-sub { font-size:15px; color:oklch(65% 0.02 85); margin:0 0 30px; line-height:1.8; }

/* ---- רספונסיבי ---- */
@media (max-width: 900px) {
  .hero-grid { grid-template-columns:1fr !important; }
  .cubes-grid { grid-template-columns:repeat(2, 1fr); }
  .tiles-grid { grid-template-columns:1fr !important; }
  .form-grid-2 { grid-template-columns:1fr !important; }
}
@media (max-width: 640px) {
  .cubes-grid { grid-template-columns:1fr; }
  .header-inner { justify-content:center; }
  .brand-title { font-size:19px !important; }
  h1.hero-title { font-size:32px !important; line-height:1.18 !important; }
  .page-title { font-size:26px !important; }
  .btn-lg, .btn-lg-outline { padding:14px 22px !important; font-size:15px !important; }
  .form-card { padding:20px !important; }
  section { padding-left:18px !important; padding-right:18px !important; }
  .admin-tabs { flex-wrap:nowrap !important; overflow-x:auto; -webkit-overflow-scrolling:touch; padding-bottom:4px; }
  .admin-tabs::-webkit-scrollbar { height:4px; }
}
@media (max-width: 480px) {
  .header-inner { padding:12px 16px; }
  .brand-logo { width:42px; height:42px; }
  .header-cta .btn-sm { padding:9px 14px; font-size:13px; }
}
