/*
Theme Name: Footlab-3-11-25
Author: Footlab
Description: Footlab topic page layout
Version: 1.6
Text Domain: footlab-3-11-25
*/

/* הטמעת פונט Assistant */
@import url('https://fonts.googleapis.com/css2?family=Assistant:wght@400;500;600;700&display=swap');

/* בסיס */
html { 
  box-sizing: border-box; 
  scroll-behavior: smooth; 
}
*, *:before, *:after { 
  box-sizing: inherit; 
}
:root { 
  --header-height:160px; 
}

body {
  margin: 0;
  direction: rtl;
  text-align: right;
  font-family: 'Assistant', Arial, sans-serif;
  font-weight: 400;
  font-size: 18px;
  line-height: 1.6;
  background-color: #f9fbfc;
  color: #555 !important;
  padding-right: 10px; 
}

/* טיפוגרפיה כללית */
h1, h2, h3, h4, h5, h6 {
  font-family: 'Assistant', Arial, sans-serif;
  font-weight: 700;
  margin: 1.2em 0 0.6em;
  line-height: 1.3;
  color: #678292 !important;
}

h1 { font-size: 30px; }
h2 { font-size: 26px; }
h3 { font-size: 24px; }
h4 { font-size: 22px; }
h5 { font-size: 20px; }
h6 { font-size: 18px; }

/* כותרת עמוד עליונה (דורבן) – שליטה מלאה במיקום */
.entry-header,
.page-header {
  margin-right: 0;
  padding-right: 0;
}

/* כאן אנחנו דואגים שהמרג'ין *באמת* ישלוט */
h1.entry-title,
.entry-header h1.entry-title,
.wp-block-post-title {
  font-size: 30px;
  margin-top:40px !important;           /* מרחק מההדר */
  margin-bottom: 1rem;
  font-weight: 700;
  color: #678292 !important;
  margin-right: 16px !important;  /* הזזה עדינה שמאלה – עכשיו זה חייב להגיב */
  margin-left: 30px;
  text-align: right;
}

/* טקסט רגיל */
p,
.entry-content,
.entry-content p {
  margin: 0 0 1em;
  font-size: 18px;
  font-weight: 400;
  color: #555 !important;
  margin-right: 10px;
  margin-left: 30px;
}

/* קישורים */
a {
  color:#336699 !important;
  text-decoration:none;
  font-weight:600;
  font-size:18px;
}
a:hover { text-decoration:underline; }

/* ============================= */
/*       בלוק ההקדמה + תמונה     */
/* ============================= */

.page-summary {
  display: grid;
  grid-template-columns: 5.2fr 1.3fr;   /* טקסט + עמודת תמונה שלך מעט רחבה יותר */
  margin-top: -22px;                    /* קיזוז עדין מול הכותרת */
  margin-bottom: 30px;
  align-items: flex-start;
  background: #f9fbfc;
  padding: 20px;
  border-radius: 6px;
  gap: 0 !important;                    /* ללא GAP – המרווח נשלט רק ע"י padding */
}

/* עמודת טקסט – הימנית */
.summary-right {
  padding-left: 40px;   /* רווח נקי בין הטקסט לתמונה */
}

/* עמודת תמונה – השמאלית */
.summary-left  {
  margin-top: 60px;
}

/* התמונה שלך */
.summary-left .author-image-box .author-img {
  width:100% !important;
  max-width:370px !important;
  height:auto !important;
  display:block;
  border-radius:8px;
}

/* טקסט מתחת לשם שלך */
.author-caption {
  font-size: 12px;
  color:#678292;
  line-height:1.6;
  text-align:right;
  margin-top: 10px;             /* רווח קטן מהתמונה */
}

/* ============================= */
/*            נושאים            */
/* ============================= */

.topic-row {
  display:flex;
  justify-content:space-between;
  align-items:flex-start;
  margin-bottom:30px;
  position:relative;
}

.topic-row .summary-right { 
  flex:4; 
  padding-left:20px; 
}

.topic-row .summary-left  { 
  flex:1; 
  display:flex; 
  justify-content:center; 
  align-items:flex-start; 
}

/* תמונות הנושא – הוגדלו בכ~60% בסך הכול */
.topic-row .summary-left img {
  max-width:550px !important;   /* גדול וברור */
  height:auto;
  border-radius:8px;
}

/* כפתורים */
.open-btn,
.close-btn {
  text-align:center;
  font-size:16px;
  color:#2a4a63;
  font-weight:bold;
  letter-spacing:3px;
  user-select:none;
  cursor:pointer;
}

.open-btn {
  position:static !important;
  display:inline-block !important;
  margin:8px 0 10px;
}

.topic-details .close-btn {
  display:none;
}

.topic-details.open .close-btn {
  display:inline-block !important;
  position:static !important;
  width:auto !important;
  white-space:nowrap !important;
  margin-top:12px;
}

/* פרטי נושא */
.topic-details {
  max-height:0;
  overflow:hidden;
  opacity:0;
  transition:max-height 1.1s ease, opacity 0.8s ease, padding 0.8s ease;
  margin-top:0;
  padding:0 15px;
  background:#f4f7f9;
  border-radius:8px;
  font-size:18px;
  line-height:1.6;
}

.topic-details.open {
  max-height:2000px;
  opacity:1;
  margin-top:15px;
  padding:15px;
}

/* ============================= */
/*         תוכן העניינים        */
/* ============================= */

#auto-toc li,
.toc-list li {
  font-size:18px;
  font-weight:500;
  color:#678292;
}

#auto-toc li::before,
.toc-list li::before {
  content: counter(toc) ". ";
  font-size:18px;
  font-weight:600;
  color:#8a9aa6;
}

#auto-toc a,
.toc-list a {
  color:#678292;
  text-decoration:none;
  transition:color .3s ease;
}

#auto-toc a:hover,
.toc-list a:hover {
  color:#336699;
  text-decoration:underline;
}

/* ============================= */
/*         רספונסיביות          */
/* ============================= */

@media (max-width:800px) {
  .page-summary { 
    grid-template-columns:1fr !important; 
  }
  .summary-right { 
    padding-left:0; 
  }
  .topic-details img { 
    margin:0 auto 15px auto; 
    max-width:100% !important; 
  }
}

/* מצב עמודה אחת */
.page-summary.one-col {
  grid-template-columns:1fr !important;
}