IDEAS
DESIGN
TECHNOLOGY
PEOPLE
MOTION
FOR A
BRIGHTER WEB
ZAKAI · MOTION LABכפתור שמגלה לאן הוא עומד לקחת אותך.
עברו עם העכבר להצצה · לחצו כדי להיכנס.
בחלק המתקדם בלשונית הסטייל:
/* אזור הפתיחה */
#portal-start.zrp-intro {
position: relative;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
gap: 16px;
padding: 48px 24px;
overflow: hidden;
border-radius: 20px;
background:
radial-gradient(
ellipse at 50% 60%,
rgba(71, 51, 36, .33),
transparent 65%
),
#141311;
color: #fff4e3;
text-align: center;
direction: rtl;
}
#portal-start.zrp-intro > .e-con-inner {
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
gap: 16px;
}
/* הטקסטים */
#portal-start :is(
.zrp-kicker, .zrp-title, .zrp-subtitle, .zrp-hint
) {
width: 100%;
max-width: 760px;
text-align: center;
}
#portal-start :is(
.zrp-kicker, .zrp-title, .zrp-subtitle, .zrp-hint
) :is(h1, h2, h3, h4, h5, h6, p) {
margin: 0;
}
#portal-start .zrp-kicker,
#portal-start .zrp-kicker :is(h4, p, span, code) {
color: #f0ca83;
font-size: 12px;
font-weight: 400;
line-height: 1.5;
letter-spacing: 3px;
background: transparent;
}
#portal-start .zrp-kicker code {
padding: 0;
border: 0;
font-family: inherit;
}
#portal-start .zrp-title,
#portal-start .zrp-title :is(h1, h2, h3, p, span, strong) {
color: #fff4e3;
font-size: clamp(30px, 4vw, 48px);
font-weight: 400;
line-height: 1.25;
letter-spacing: normal;
}
#portal-start .zrp-subtitle,
#portal-start .zrp-subtitle :is(p, span, strong) {
color: #e0d3c1;
font-size: 17px;
font-weight: 400;
line-height: 1.7;
}
#portal-start .zrp-hint,
#portal-start .zrp-hint :is(p, span, strong) {
color: #f0ca83;
font-size: 14px;
font-weight: 400;
line-height: 1.6;
}
/* כפתור Elementor */
#portal-start .zrp-button-widget {
width: 100%;
margin: 20px 0;
text-align: center;
}
#portal-start .zrp-button-widget .elementor-button.zrp-ready {
position: relative;
display: inline-block;
vertical-align: middle;
box-sizing: border-box;
width: 250px;
height: 250px;
padding: 0;
border: 0;
border-radius: 50%;
background: transparent;
color: #e4c18b;
box-shadow: none;
cursor: pointer;
overflow: visible;
transform: none;
text-decoration: none;
-webkit-tap-highlight-color: transparent;
}
#portal-start .zrp-button-widget
.elementor-button.zrp-ready:is(:hover, :focus) {
background: transparent;
color: #e4c18b;
box-shadow: none;
transform: none;
}
#portal-start .zrp-button-widget
.elementor-button.zrp-ready:focus-visible {
outline: 2px solid #ffe0a5;
outline-offset: 8px;
}
/* הטקסט המקורי נשאר נגיש לקוראי מסך */
#portal-start .zrp-ready .elementor-button-content-wrapper {
position: absolute;
width: 1px;
height: 1px;
padding: 0;
margin: -1px;
overflow: hidden;
clip-path: inset(50%);
white-space: nowrap;
}
/* הטבעת */
#portal-start .zrp-ready .zrp-ring {
position: absolute;
inset: 0;
display: block;
width: 100%;
height: 100%;
max-width: none;
overflow: visible;
pointer-events: none;
transform-origin: 50% 50%;
}
#portal-start .zrp-ring text {
fill: #f0ca83;
font-family: Arial, sans-serif;
font-size: 12px;
font-weight: 400;
letter-spacing: 2.5px;
direction: ltr;
}
#portal-start .zrp-orbit {
fill: none;
stroke: #d6b47a;
stroke-width: .6;
opacity: .4;
}
#portal-start .zrp-spark {
fill: #ffe4b6;
filter: drop-shadow(0 0 5px #e9b960);
}
/* מרכז הכפתור */
#portal-start .zrp-center {
position: absolute;
inset: 48px;
display: block;
box-sizing: border-box;
overflow: hidden;
border: 1px solid rgba(214, 180, 122, .55);
border-radius: 50%;
pointer-events: none;
box-shadow:
0 0 0 8px rgba(223, 183, 118, .02),
0 16px 40px rgba(0, 0, 0, .33);
transition:
box-shadow .6s ease,
border-color .6s ease;
}
/* העולם שמאחורי הדלתות */
#portal-start .zrp-world {
position: absolute;
inset: 0;
display: block;
overflow: hidden;
background:
radial-gradient(
circle at 65% 22%,
#f7ce8c,
transparent 42%
),
linear-gradient(
145deg,
#813fe7,
#f27464 55%,
#f6bc5b
);
transform: scale(1.2);
transition: transform .8s ease;
}
#portal-start .zrp-world::before {
content: "";
position: absolute;
left: -20px;
top: 36px;
width: 105px;
height: 105px;
box-sizing: border-box;
border: 18px solid rgba(255, 244, 223, .69);
border-radius: 50%;
box-shadow: 0 0 35px rgba(255, 244, 223, .2);
}
#portal-start .zrp-world::after {
content: "";
position: absolute;
right: -20px;
top: 40px;
width: 90px;
height: 150px;
border-radius: 45px 45px 10px 10px;
background: linear-gradient(135deg, #311755, #9d5ad6);
transform: rotate(35deg);
}
/* הדלתות */
#portal-start .zrp-door {
position: absolute;
top: 0;
bottom: 0;
z-index: 2;
display: block;
width: 50%;
box-sizing: border-box;
background: linear-gradient(135deg, #35302a, #1c1a17 70%);
transition: transform .75s cubic-bezier(.22, 1, .36, 1);
}
#portal-start .zrp-door-left {
left: 0;
border-right: 1px solid rgba(228, 193, 139, .15);
}
#portal-start .zrp-door-right {
right: 0;
border-left: 1px solid rgba(228, 193, 139, .15);
}
/* החץ */
#portal-start .zrp-arrow {
position: absolute;
inset: 0;
z-index: 3;
display: grid;
place-items: center;
pointer-events: none;
transition:
opacity .3s ease,
transform .6s ease;
}
#portal-start .zrp-arrow svg {
display: block;
width: 42px;
height: 42px;
fill: none;
stroke: #ffe0a5;
stroke-width: 1.5;
}
/* הצצה במעבר עכבר ובמיקוד מקלדת */
#portal-start .zrp-ready.zrp-peek .zrp-door-left {
transform: translateX(-42%);
}
#portal-start .zrp-ready.zrp-peek .zrp-door-right {
transform: translateX(42%);
}
#portal-start .zrp-ready.zrp-peek .zrp-arrow {
opacity: 0;
transform: translateY(10px);
}
#portal-start .zrp-ready.zrp-peek .zrp-world {
transform: scale(1);
}
#portal-start .zrp-ready.zrp-peek .zrp-center {
border-color: #ffe0a5;
box-shadow:
0 0 0 8px rgba(223, 183, 118, .04),
0 0 35px rgba(223, 183, 118, .2),
0 16px 40px rgba(0, 0, 0, .33);
}
/* פתיחה מלאה בלחיצה */
#portal-start .zrp-ready.zrp-opened .zrp-door-left {
transform: translateX(-105%);
}
#portal-start .zrp-ready.zrp-opened .zrp-door-right {
transform: translateX(105%);
}
#portal-start .zrp-ready.zrp-opened .zrp-arrow {
opacity: 0;
}
#portal-start .zrp-ready.zrp-opened .zrp-world {
transform: scale(1);
}
/* הגלריה */
#portal-work.zrp-gallery {
padding: 40px 28px;
border-radius: 20px;
background: #eee6d9;
color: #30251f;
direction: rtl;
}
#portal-work .zrp-gallery-title,
#portal-work .zrp-gallery-title :is(h1, h2, h3, p, span) {
color: #30251f;
font-size: clamp(28px, 4vw, 40px);
font-weight: 400;
line-height: 1.25;
}
#portal-work .zrp-cards,
#portal-work .zrp-cards > .e-con-inner {
display: flex;
flex-direction: row;
gap: 18px;
}
#portal-work .zrp-card {
flex: 1 1 0;
min-width: 0;
}
#portal-work .zrp-card .elementor-widget-image img {
display: block;
width: 100%;
height: auto;
aspect-ratio: 4 / 3;
object-fit: cover;
border-radius: 12px;
}
#portal-work .zrp-card :is(
.elementor-heading-title,
.elementor-widget-text-editor,
.elementor-widget-text-editor p
) {
color: #68564a;
font-size: 16px;
line-height: 1.6;
}
/* הגלריה מוסתרת עד ללחיצה */
html.zrp-enhanced
#portal-work.zrp-gallery:not(.zrp-revealed) {
display: none;
}
/* אזור השער מוסתר אחרי ההחלפה */
html.zrp-enhanced #portal-start.zrp-intro[hidden] {
display: none;
}
/* נייד */
@media (max-width: 767px) {
#portal-start.zrp-intro {
padding: 36px 20px;
}
#portal-start .zrp-button-widget .elementor-button.zrp-ready {
width: 230px;
height: 230px;
}
#portal-start .zrp-title,
#portal-start .zrp-title :is(h1, h2, h3, p, span, strong) {
font-size: clamp(28px, 7vw, 36px);
}
#portal-start .zrp-subtitle,
#portal-start .zrp-subtitle :is(p, span, strong) {
font-size: 16px;
}
#portal-work.zrp-gallery {
padding: 30px 20px;
}
#portal-work .zrp-cards,
#portal-work .zrp-cards > .e-con-inner {
flex-direction: column;
}
#portal-work .zrp-card {
flex: 0 0 auto;
width: 100%;
}
}
/* תנועה מופחתת */
@media (prefers-reduced-motion: reduce) {
#portal-start :is(
.zrp-center, .zrp-world, .zrp-door, .zrp-arrow
) {
transition: none;
}
}
המבנה מסודר-
ZAKAI · MOTION LAB
סיבוב קטן. עולם שלם בפנים.
כפתור שמגלה לאן הוא עומד לקחת אותך.
עברו עם העכבר להצצה · לחצו במרכז כדי לגלות.
זה העולם שמאחורי הכפתור.
EXPLORE / LEARN / REUSE / CREATE
.Costomize to fit your vision
בנייד, נגיעה במרכז הכפתור מחליפה את השער בגלריה. אין צורך במעבר עכבר.
לשינוי גודל הכפתור בנייד, חפשו ב־CSS את מקטע @media (max-width: 767px) ואת הכלל של .elementor-button.zrp-ready. שנו את width: 230px ואת height: 230px לאותו ערך.
הכרטיסים מוצגים בטור באמצעות flex-direction: column. הרווח ביניהם נקבע ב־gap: 18px בכלל של .zrp-cards.
ריווח אזור הפתיחה בנייד נקבע ב־padding: 36px 20px, וריווח הגלריה ב־padding: 30px 20px.
הטבעת מסתובבת עם כיוון השעון.
להיפוך כיוון הסיבוב, חפשו בסקריפט את השורה שמתחילה ב־angle = והחליפו אותה בשורה המופיעה להלן.
השאירו את ערכי speed ו־targetSpeed חיוביים. הם משמשים גם להאטה ולעצירה במעבר עכבר.
כיוון הסיבוב אינו משנה את כיוון הקריאה של הטקסטים או את סדר הכרטיסים.
השורה להחלפה בכיוון ההפוך: (בסקריפט)
angle = (angle - speed * dt / 1000 + 360) % 360;עוצמת פתיחת הדלתות בהצצה נקבעת ב־CSS, בכללים של .zrp-ready.zrp-peek.
הערכים translateX(-42%) ו־translateX(42%) מזיזים את שתי הדלתות לצדדים. להקטנת ההצצה, שנו אותם ל־-30% ול־30%. לפתיחה רחבה יותר, השתמשו ב־-60% וב־60%.
בפתיחה המלאה, הכללים של .zrp-ready.zrp-opened משתמשים ב־-105% וב־105%, כדי להוציא את הדלתות לגמרי מהמרכז.
תנועת כניסת הגלריה נקבעת בסקריפט באמצעות translateY(12px). הקטינו את המספר לתנועה עדינה יותר, או הגדילו אותו לתנועה מורגשת יותר. השאירו את מצב הסיום translateY(0).
מהירות הטבעת נקבעת בסקריפט בשני מקומות: let speed = 12 ובערך 12 שבסוף הגדרת targetSpeed. שנו את שניהם לאותו מספר.
הערך 12 יוצר סיבוב מלא בכ־30 שניות. הערך 6 יוצר סיבוב בכ־60 שניות, והערך 18 בכ־20 שניות.
מהירות פתיחת הדלתות נקבעת ב־CSS של .zrp-door, באמצעות transform .75s. מספר גדול יותר יוצר פתיחה איטית יותר.
משך היעלמות השער נקבע בסקריפט ב־duration: 240, ומשך כניסת הגלריה ב־duration: 420. הערכים נמדדים באלפיות שנייה.
הערך 170 בנוסחת ההאטה של הטבעת קובע את רכות העצירה. הגדלתו תיצור עצירה הדרגתית יותר.
את הצבעים משנים ב־CSS, לפי האלמנט:
• רקע אזור הפתיחה: #141311 בכלל #portal-start.zrp-intro.
• הכותרת הראשית: #fff4e3 בכלל .zrp-title.
• הטקסט המסתובב: fill: #f0ca83 בכלל .zrp-ring text.
• קו הטבעת: stroke: #d6b47a בכלל .zrp-orbit.
• החץ: stroke: #ffe0a5 בכלל .zrp-arrow svg.
• הדלתות: צבעי הגרדיאנט בכלל .zrp-door.
• העולם שמאחורי הדלתות: צבעי הגרדיאנטים בכלל .zrp-world.
• רקע הגלריה: #eee6d9 בכלל #portal-work.zrp-gallery.
• כותרת הגלריה: #30251f בכלל .zrp-gallery-title.
• כותרות הכרטיסים: #68564a בכלל של .zrp-card.
שימו לב: צבעי SVG מוגדרים באמצעות fill או stroke, ולא באמצעות color.
גודל הכפתור בדסקטופ נקבע ב־CSS בכלל .elementor-button.zrp-ready, באמצעות width: 250px ו־height: 250px. שנו את שניהם לאותו ערך כדי לשמור על עיגול.
גודל המרכז נקבע בכלל .zrp-center, באמצעות inset: 48px. ערך קטן יותר יגדיל את המרכז; ערך גדול יותר יקטין אותו.
גודל הכותרת נקבע בכלל .zrp-title, באמצעות clamp(30px, 4vw, 48px): גודל מינימלי, גודל גמיש לפי רוחב המסך וגודל מקסימלי.
יחס התמונות נקבע באמצעות aspect-ratio: 4 / 3. לשינוי לתמונות ריבועיות, השתמשו ב־aspect-ratio: 1 / 1.
את התמונות עצמן מחליפים בווידג׳טי התמונה באלמנטור. אין צורך בגובה קבוע לכרטיסים.
עוד שתי התאמות שימושיות:
את הכיתוב המסתובב =EXPLORE · CREATE · DISCOVER · משנים בשני המקומות בסקריפט.
את טקסט הכפתור ואת יעד הקישור משנים בווידג׳ט הכפתור באלמנטור; אם משנים את portal-work, צריך לעדכן גם את ה־ID של הגלריה ואת סלקטורי ה־CSS התואמים.
הערה חשובה 🚩
הרכיב פועל באמצעות CSS ו־JavaScript רגיל ואינו דורש GSAP או ScrollTrigger. יש להגדיר את הקלאסים ואת ה־ID בהתאם למבנה ולהוסיף את הסקריפט פעם אחת בלבד, בווידג׳ט HTML מתחת לכפתור ולפני מיכל הגלריה.
מעבר עכבר מאפשר הצצה. לחיצה במרכז הכפתור מחליפה את אזור השער בגלריה, ללא גלילה יזומה. בנייד הפעולה מתבצעת בנגיעה, ובמקלדת באמצעות Enter. הרכיב מכבד את העדפת המשתמש לתנועה מופחתת.