/*
Theme Name: 2SafeNet
Theme URI: https://2safenet.com
Author: 2SafeNet
Description: Corporate theme for 2SafeNet — AI-based systems development and integration. Hebrew / RTL.
Version: 1.2.0
Requires at least: 6.5
Requires PHP: 8.1
License: Proprietary
Text Domain: 2safenet
*/

/* ---------- Tokens ---------- */
:root {
  --sn-blue: #1F23E0;
  --sn-navy: #0A1166;
  --sn-navy-2: #141C7A;
  --sn-red: #E3100F;
  --sn-steel: #357EBF;
  --sn-sky: #4FA3FF;
  --sn-gray: #C9C9C9;
  --sn-bg: #F2F4F8;
  --sn-bg-2: #EEF1F8;
  --sn-line: #E3E6EE;
  --sn-text: #0A1166;
  --sn-muted: #4A5072;
  --sn-on-dark: #DCE2FF;
  --sn-max: 1240px;
  --sn-radius: 6px;
  --sn-font: 'Heebo', 'Arial Hebrew', Arial, sans-serif;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--sn-font);
  color: var(--sn-text);
  background: #fff;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--sn-blue); }
a:hover { color: var(--sn-navy); }
h1, h2, h3 { line-height: 1.15; margin: 0; }
.sn-container { max-width: var(--sn-max); margin: 0 auto; padding: 0 24px; }
.screen-reader-text {
  position: absolute !important; width: 1px; height: 1px; overflow: hidden;
  clip: rect(1px, 1px, 1px, 1px); white-space: nowrap;
}
.sn-skip:focus {
  position: fixed; top: 8px; inset-inline-start: 8px; z-index: 1000;
  width: auto; height: auto; clip: auto; background: #fff; padding: 10px 16px; border-radius: 4px;
}
:focus-visible { outline: 3px solid var(--sn-sky); outline-offset: 2px; }

.sn-section { padding: 64px 0 72px; }
.sn-section--light { background: var(--sn-bg); }
.sn-section--dark { background: var(--sn-navy); color: #fff; }
.sn-h2 {
  font-size: 34px; font-weight: 800; display: inline-block;
  padding-bottom: 10px; border-bottom: 3px solid var(--sn-blue); margin-bottom: 36px;
}
.sn-section--dark .sn-h2 { border-color: var(--sn-sky); }

.sn-btn {
  display: inline-flex; align-items: center; gap: 10px;
  background: var(--sn-red); color: #fff; text-decoration: none;
  padding: 14px 34px; border-radius: 4px; border: 0;
  font: inherit; font-size: 18px; font-weight: 700; min-height: 52px; cursor: pointer;
  transition: background .15s;
}
.sn-btn:hover, .sn-btn:focus-visible { background: #B80C0B; color: #fff; }
.sn-btn svg { width: 14px; height: 14px; }

/* ---------- Top bar ---------- */
.sn-topbar { background: var(--sn-steel); color: #fff; font-size: 14px; }
.sn-topbar .sn-container {
  display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center;
  gap: 6px 24px; padding-top: 8px; padding-bottom: 8px;
}
.sn-topbar a { color: #fff; text-decoration: none; }
.sn-topbar__meta { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; }
.sn-topbar__meta span, .sn-topbar__meta a { display: inline-flex; align-items: center; gap: 6px; }
.sn-topbar__sep { width: 1px; height: 14px; background: #9CC2E4; }

/* ---------- Header ---------- */
.sn-header { background: #fff; box-shadow: 0 1px 0 var(--sn-line); position: sticky; top: 0; z-index: 50; }
.admin-bar .sn-header { top: 32px; }
.sn-header .sn-container {
  display: flex; flex-wrap: wrap; align-items: center; gap: 12px 64px;
  padding-top: 14px; padding-bottom: 14px;
}
.sn-logo { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--sn-navy); }
.sn-logo__mark { width: 40px; height: 30px; flex: none; }
.sn-logo__word { font-size: 27px; font-weight: 800; letter-spacing: -0.3px; direction: ltr; }
.sn-logo__word b { color: var(--sn-blue); font-weight: 800; }
.sn-nav ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px 36px; }
.sn-nav a { color: var(--sn-navy); text-decoration: none; font-size: 16px; font-weight: 500; padding: 8px 0; display: inline-block; }
.sn-nav a:hover, .sn-nav .current-menu-item > a { color: var(--sn-blue); }
.sn-nav-toggle { display: none; }

@media (max-width: 860px) {
  .sn-header .sn-container { justify-content: space-between; gap: 12px; }
  .sn-nav-toggle {
    display: inline-flex; align-items: center; justify-content: center;
    width: 44px; height: 44px; border: 1px solid var(--sn-line); border-radius: 4px; background: #fff; cursor: pointer;
  }
  .sn-nav { display: none; flex-basis: 100%; }
  .sn-nav.is-open { display: block; }
  .sn-nav ul { flex-direction: column; gap: 0; }
  .sn-nav a { padding: 12px 0; display: block; border-top: 1px solid var(--sn-line); }
}

/* ---------- Hero ---------- */
.sn-hero {
  color: #fff; min-height: 640px; display: flex; align-items: center;
  background-color: var(--sn-navy);
  background-size: cover; background-position: left center; background-repeat: no-repeat;
}
.sn-hero .sn-container { width: 100%; padding-top: 80px; padding-bottom: 80px; }
.sn-hero__inner { max-width: 520px; }
.sn-hero h1 {
  font-size: clamp(38px, 5.2vw, 64px); line-height: 1.08; font-weight: 900; margin-bottom: 22px;
  text-shadow: 0 2px 18px #050A3A;
}
.sn-hero h1 span { color: var(--sn-sky); }
.sn-hero p { font-size: 21px; color: var(--sn-on-dark); margin: 0 0 34px; text-shadow: 0 1px 10px #050A3A; }
@media (max-width: 760px) {
  .sn-hero { min-height: 0; background-position: 20% center; }
  .sn-hero::before { content: none; }
  .sn-hero .sn-container { background: linear-gradient(0deg, rgba(10,17,102,.85), rgba(10,17,102,.55)); }
}

/* ---------- Services ---------- */
.sn-services { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr)); gap: 18px; }
.sn-service {
  background: #fff; border: 1px solid var(--sn-line); border-radius: var(--sn-radius);
  padding: 30px 24px 22px; text-decoration: none; color: var(--sn-navy);
  display: flex; flex-direction: column; align-items: center; gap: 14px; min-height: 180px;
  transition: border-color .15s, box-shadow .15s, transform .15s;
}
.sn-service:hover { border-color: var(--sn-blue); box-shadow: 0 8px 24px rgba(31,35,224,.08); transform: translateY(-2px); color: var(--sn-navy); }
.sn-service svg.sn-icon { width: 64px; height: 64px; }
.sn-service__title { font-size: 20px; font-weight: 700; text-align: center; }
.sn-service__more { align-self: flex-end; width: 16px; height: 16px; }

/* ---------- Process ---------- */
.sn-steps { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 32px 0; list-style: none; margin: 0; padding: 0; }
.sn-step { display: flex; flex-direction: column; align-items: center; position: relative; }
.sn-step:not(:last-child)::after {
  content: ""; position: absolute; top: 22px; inset-inline-start: calc(50% + 34px);
  width: calc(100% - 68px); border-top: 2px dotted #9AA6D9;
}
.sn-step__num {
  position: relative; z-index: 1; width: 44px; height: 44px; border-radius: 50%;
  background: var(--sn-blue); color: #fff; display: flex; align-items: center; justify-content: center;
  font-size: 17px; font-weight: 700; direction: ltr;
}
.sn-step__icon {
  width: 84px; height: 84px; border-radius: 50%; background: #EEF1FA;
  display: flex; align-items: center; justify-content: center; margin-top: -10px;
}
.sn-step__icon svg { width: 34px; height: 34px; }
.sn-step__title { margin-top: 16px; font-size: 19px; font-weight: 700; text-align: center; }
@media (max-width: 860px) {
  .sn-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .sn-step::after { display: none; }
}

/* ---------- Featured project ---------- */
.sn-project { background: var(--sn-bg-2); padding: 48px 0 0; overflow: hidden; }
.sn-project .sn-container { display: flex; flex-wrap: wrap; gap: 40px; align-items: flex-end; }
.sn-project__text { flex: 1 1 260px; min-width: 0; align-self: stretch; display: flex; flex-direction: column; padding-bottom: 40px; }
.sn-project__text .sn-h2 { align-self: flex-start; margin-bottom: 48px; }
.sn-project__title { font-size: 28px; line-height: 1.3; font-weight: 700; margin-bottom: 14px; }
.sn-project__desc { color: var(--sn-muted); font-size: 17px; margin: 0 0 18px; }
.sn-project__list { margin: 0; padding: 0 20px 0 0; color: var(--sn-text); display: grid; gap: 6px; }

.sn-dash {
  flex: 2 1 620px; min-width: 0; direction: ltr; background: #0B1022; color: #E6E9F5;
  border-radius: 10px 10px 0 0; padding: 14px; display: flex; gap: 14px; font-size: 12px; overflow-x: auto;
}
.sn-dash__side { flex: none; width: 150px; display: flex; flex-direction: column; gap: 4px; }
.sn-dash__brand { display: flex; align-items: center; gap: 6px; font-size: 14px; font-weight: 800; padding: 6px 4px 14px; }
.sn-dash__brand b { color: var(--sn-sky); font-weight: 800; }
.sn-dash__item { padding: 7px 10px; border-radius: 4px; color: #AAB2D0; }
.sn-dash__item.is-active { background: var(--sn-blue); color: #fff; }
.sn-dash__main { flex: 1 1 auto; min-width: 440px; display: flex; flex-direction: column; gap: 12px; }
.sn-dash__bar { height: 8px; border-radius: 4px; background: #161D36; }
.sn-dash__grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.sn-dash__grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.sn-dash__img { grid-column: span 2; grid-row: span 2; border-radius: 6px; min-height: 150px; background: #161D36 center / cover no-repeat; }
.sn-dash__card { background: #161D36; border-radius: 6px; padding: 10px; }
.sn-dash__card--wide { grid-column: span 2; }
.sn-dash__label { color: #AAB2D0; }
.sn-dash__value { font-size: 24px; font-weight: 700; }
.sn-ok { color: #4ADE80; font-size: 10px; }
.sn-crit { color: #F87171; font-size: 10px; }
.sn-bars { display: flex; align-items: flex-end; gap: 4px; height: 70px; margin-top: 8px; }
.sn-bars span { flex: 1; background: #2F5BFF; border-radius: 1px; }
.sn-axis { display: flex; justify-content: space-between; color: #6E77A0; font-size: 10px; margin-top: 4px; }
.sn-donut-wrap { display: flex; align-items: center; gap: 16px; margin-top: 8px; }
.sn-donut {
  width: 76px; height: 76px; border-radius: 50%; flex: none;
  background: conic-gradient(#22C55E 0 87%, #EF4444 87% 95%, #60A5FA 95% 100%);
  display: flex; align-items: center; justify-content: center;
}
.sn-donut span { width: 54px; height: 54px; border-radius: 50%; background: #161D36; display: flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 700; }
.sn-legend { display: grid; gap: 5px; font-size: 11px; flex: 1; }
.sn-legend div { display: flex; justify-content: space-between; }

/* ---------- Videos ---------- */
.sn-videos { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 20px; }
.sn-video { display: flex; flex-direction: column; gap: 6px; color: var(--sn-navy); text-decoration: none; }
.sn-video__thumb { position: relative; aspect-ratio: 16 / 9; border-radius: 4px; overflow: hidden; background: var(--sn-navy); }
.sn-video__thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s; }
.sn-video:hover .sn-video__thumb img { transform: scale(1.03); }
.sn-video__play {
  position: absolute; top: 50%; left: 50%; width: 64px; height: 64px; margin: -32px 0 0 -32px;
  border-radius: 50%; border: 3px solid #fff; background: rgba(10,17,102,.6);
  display: flex; align-items: center; justify-content: center;
}
.sn-video__play svg { width: 22px; height: 22px; margin-inline-start: 3px; }
.sn-video__title { font-size: 17px; font-weight: 700; margin-top: 6px; }
.sn-video__time { font-size: 14px; color: #5A6390; direction: ltr; text-align: end; }

/* ---------- Contact ---------- */
.sn-contact { background: var(--sn-bg); }
.sn-contact__wrap { max-width: 1440px; margin: 0 auto; display: flex; flex-wrap: wrap-reverse; align-items: stretch; }
.sn-contact__form-col { flex: 1 1 480px; min-width: 0; padding: 56px 24px 64px; }
.sn-contact__form-inner { max-width: 560px; margin-inline-start: max(0px, calc((100% - 560px) / 2)); }
.sn-contact__img { flex: 1 1 480px; min-width: 0; min-height: 400px; background: #F2F4F8 left center / cover no-repeat; }
.sn-form { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.sn-form label { display: flex; flex-direction: column; gap: 4px; font-size: 14px; font-weight: 500; }
.sn-form input, .sn-form textarea {
  font: inherit; font-size: 16px; padding: 10px 12px; border: 1px solid #D5DAE6; border-radius: 4px;
  background: #fff; min-height: 46px; color: var(--sn-text);
}
.sn-form textarea { resize: vertical; min-height: 110px; }
.sn-form input:focus, .sn-form textarea:focus { border-color: var(--sn-blue); outline: none; box-shadow: 0 0 0 3px rgba(31,35,224,.15); }
.sn-form__full { grid-column: 1 / -1; }
.sn-form__hp { position: absolute; inset-inline-start: -9999px; width: 1px; height: 1px; overflow: hidden; }
.sn-notice { grid-column: 1 / -1; padding: 12px 14px; border-radius: 4px; font-weight: 500; }
.sn-notice--ok { background: #E7F7EE; color: #11603A; }
.sn-notice--err { background: #FDECEC; color: #8A1111; }
@media (max-width: 560px) { .sn-form { grid-template-columns: 1fr; } }

/* ---------- Footer ---------- */
.sn-footer { background: var(--sn-navy); color: #fff; padding: 30px 0 22px; }
.sn-footer__top { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 18px 40px; padding-bottom: 22px; }
.sn-footer .sn-logo { color: #fff; }
.sn-footer .sn-logo__word { font-size: 23px; }
.sn-footer .sn-logo__word b { color: var(--sn-sky); }
.sn-footer__nav ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px 0; }
.sn-footer__nav li:not(:last-child)::after { content: "|"; color: #4A5590; margin: 0 14px; }
.sn-footer__nav a { color: #fff; text-decoration: none; font-size: 15px; }
.sn-footer__nav a:hover { color: var(--sn-sky); }
.sn-social { display: flex; gap: 10px; }
.sn-social a {
  width: 44px; height: 44px; border: 2px solid #fff; border-radius: 50%;
  display: flex; align-items: center; justify-content: center; color: #fff; text-decoration: none; font-weight: 800; font-size: 15px;
}
.sn-social a:hover { background: #fff; color: var(--sn-navy); }
.sn-social a:hover svg { stroke: var(--sn-navy); fill: var(--sn-navy); }
.sn-social svg { width: 16px; height: 16px; }
.sn-footer__bottom {
  border-top: 1px solid #26307A; padding-top: 16px; display: flex; flex-wrap: wrap;
  justify-content: space-between; gap: 8px; font-size: 13px; color: #C7CCF2;
}
.sn-footer__bottom a { color: #C7CCF2; }

/* ---------- Generic content (blog, pages) ---------- */
.sn-page-head { background: var(--sn-navy); color: #fff; padding: 56px 0; }
.sn-page-head h1 { font-size: clamp(30px, 4vw, 44px); font-weight: 800; }
.sn-page-head p { color: var(--sn-on-dark); margin: 10px 0 0; }
.sn-content { padding: 48px 0 72px; }
.sn-prose { max-width: 760px; font-size: 18px; }
.sn-prose h2 { font-size: 28px; margin: 36px 0 12px; }
.sn-prose h3 { font-size: 22px; margin: 28px 0 10px; }
.sn-prose img { border-radius: var(--sn-radius); margin: 20px 0; }
.sn-prose blockquote { border-inline-start: 4px solid var(--sn-blue); margin: 24px 0; padding: 4px 18px; color: var(--sn-muted); }
.sn-posts { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 22px; }
.sn-post-card { background: #fff; border: 1px solid var(--sn-line); border-radius: var(--sn-radius); overflow: hidden; display: flex; flex-direction: column; text-decoration: none; color: var(--sn-navy); }
.sn-post-card:hover { border-color: var(--sn-blue); }
.sn-post-card__img { aspect-ratio: 16 / 9; background: var(--sn-bg) center / cover no-repeat; }
.sn-post-card__body { padding: 18px 20px 22px; display: flex; flex-direction: column; gap: 8px; }
.sn-post-card__title { font-size: 20px; font-weight: 700; }
.sn-post-card__date { font-size: 13px; color: var(--sn-muted); }
.sn-pagination { margin-top: 36px; display: flex; gap: 8px; flex-wrap: wrap; }
.sn-pagination .page-numbers { padding: 8px 14px; border: 1px solid var(--sn-line); border-radius: 4px; text-decoration: none; }
.sn-pagination .current { background: var(--sn-blue); color: #fff; border-color: var(--sn-blue); }
.sn-meta { font-size: 14px; color: var(--sn-muted); margin-bottom: 24px; }

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; scroll-behavior: auto !important; }
}

/* ---------- v1.1 additions ---------- */
.sn-service__text { font-size: 15px; color: var(--sn-muted); text-align: center; }
.sn-services--page { margin-top: 36px; }
.sn-project__more { margin: 18px 0 0; }
.sn-project__more a { font-weight: 700; text-decoration: none; }
.sn-form__note { font-size: 13px; color: var(--sn-muted); margin: 0; }
.sn-crumbs { margin: 0 0 8px; font-size: 15px; }
.sn-crumbs a { color: var(--sn-on-dark); }

.sn-prose ul, .sn-prose ol { padding-inline-start: 22px; }
.sn-prose li { margin-bottom: 6px; }
.sn-prose table { width: 100%; border-collapse: collapse; margin: 20px 0; font-size: 16px; }
.sn-prose th, .sn-prose td { border: 1px solid var(--sn-line); padding: 10px 12px; text-align: start; vertical-align: top; }
.sn-prose th { background: var(--sn-bg); }
.sn-prose .sn-lead { font-size: 21px; color: var(--sn-muted); }
.sn-prose figure { margin: 24px 0; }
.sn-prose figcaption { font-size: 14px; color: var(--sn-muted); }
.sn-prose hr { border: 0; border-top: 1px solid var(--sn-line); margin: 36px 0; }

.sn-cta {
  margin-top: 48px; padding: 28px 32px; background: var(--sn-bg-2); border-radius: var(--sn-radius);
  border-inline-start: 4px solid var(--sn-blue);
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 18px;
}
.sn-cta h2 { font-size: 24px; margin-bottom: 6px; }
.sn-cta p { margin: 0; color: var(--sn-muted); }

.sn-contact-page { display: flex; flex-wrap: wrap; gap: 48px; }
.sn-contact-page__info { flex: 1 1 320px; min-width: 0; }
.sn-contact-page__form { flex: 1.4 1 420px; min-width: 0; }
.sn-cdetails { list-style: none; margin: 24px 0 0; padding: 0; display: grid; gap: 14px; font-size: 18px; }
.sn-cdetails li { display: flex; flex-direction: column; gap: 2px; }
.sn-cdetails span { font-size: 14px; color: var(--sn-muted); }
.sn-cdetails a { text-decoration: none; font-weight: 700; align-self: flex-start; unicode-bidi: isolate; }

.sn-footer__contacts { display: flex; flex-wrap: wrap; gap: 8px 28px; padding: 0 0 18px; font-size: 15px; color: #C7CCF2; }
.sn-footer__contacts a { color: #fff; text-decoration: none; }
.sn-footer__contacts a:hover { color: var(--sn-sky); }
.sn-footer__legal { display: inline-flex; gap: 18px; }

.sn-wa {
  position: fixed; bottom: 20px; inset-inline-end: 20px; z-index: 60;
  width: 56px; height: 56px; border-radius: 50%; background: #1E9E55;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 6px 18px rgba(0,0,0,.25);
}
.sn-wa:hover { background: #17824A; }
.sn-wa svg { width: 30px; height: 30px; }

/* ---------- v1.2: featured projects slider ---------- */
.sn-project { padding: 48px 0 0; }
.sn-project__head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; }
.sn-project__head .sn-h2 { margin-bottom: 28px; }
.sn-slider-nav { display: flex; gap: 8px; margin-bottom: 28px; }
.sn-slider-btn {
  width: 44px; height: 44px; border-radius: 50%; border: 2px solid var(--sn-blue); background: #fff; color: var(--sn-blue);
  display: inline-flex; align-items: center; justify-content: center; cursor: pointer; padding: 0;
}
.sn-slider-btn:hover { background: var(--sn-blue); color: #fff; }
.sn-slider-btn svg { width: 20px; height: 20px; }
.sn-slide__inner { display: flex; flex-wrap: wrap; gap: 40px; align-items: flex-end; }
.sn-js .sn-slide { display: none; }
.sn-js .sn-slide.is-active { display: block; animation: sn-fade .35s ease; }
.sn-slide + .sn-slide { margin-top: 32px; }           /* no-JS: slides stacked */
.sn-js .sn-slide + .sn-slide { margin-top: 0; }
@keyframes sn-fade { from { opacity: 0; } to { opacity: 1; } }
.sn-slide .sn-project__text { padding-bottom: 32px; }
.sn-slide .sn-project__title { margin-bottom: 14px; }
.sn-slide__media {
  flex: 2 1 620px; min-width: 0; border-radius: 10px 10px 0 0; overflow: hidden; background: #0B1022;
  aspect-ratio: 16 / 9; max-height: 420px;
}
.sn-slide__media img { width: 100%; height: 100%; object-fit: cover; }
.sn-slider-dots { display: flex; justify-content: flex-start; gap: 8px; padding-top: 18px; padding-bottom: 22px; }
.sn-no-js .sn-slider-dots, .sn-no-js .sn-slider-nav { display: none; }
.sn-dot {
  width: 10px; height: 10px; border-radius: 5px; border: 0; padding: 0; background: #B9C2DE; cursor: pointer;
  transition: width .2s, background .2s;
}
.sn-dot.is-active { width: 26px; background: var(--sn-blue); }
.sn-dot:focus-visible, .sn-slider-btn:focus-visible { outline: 3px solid var(--sn-sky); outline-offset: 2px; }
@media (max-width: 760px) {
  .sn-slide__media { flex-basis: 100%; }
}
