﻿:root {
      --teal: #3dbfbf;
      --teal-dark: #2a9d9d;
      --teal-deeper: #1a7a7a;
      --teal-light: #7de0e0;
      --black: #0d0d0d;
      --white: #f5f5f0;
      --card-bg: #111a1a;
      --wave-color: rgba(0,0,0,0.18);
    }

    *, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

    html { scroll-behavior: smooth; }

    body {
      background: var(--black);
      color: var(--white);
      font-family: 'Heebo', sans-serif;
      direction: rtl;
      overflow-x: hidden;
    }

    /* ---- CURSOR (desktop only) ---- */
    @media (hover: hover) and (pointer: fine) {
      body { cursor: none; }
    }
    @media (hover: none), (pointer: coarse) {
      #cursor, #cursor-ring { display: none; }
    }
    #cursor {
      position: fixed; width: 14px; height: 14px;
      background: var(--teal); border-radius: 50%;
      pointer-events: none; z-index: 9999;
      transform: translate(-50%, -50%);
      transition: transform 0.08s, width 0.2s, height 0.2s, background 0.2s;
      mix-blend-mode: screen;
    }
    #cursor-ring {
      position: fixed; width: 38px; height: 38px;
      border: 2px solid var(--teal-light);
      border-radius: 50%; pointer-events: none; z-index: 9998;
      transform: translate(-50%, -50%);
      transition: transform 0.18s ease, width 0.2s, height 0.2s;
      opacity: 0.5;
    }
    a:hover ~ #cursor, button:hover ~ #cursor { width: 24px; height: 24px; }

    /* ---- HEADER / NAV ---- */
    header {
      position: fixed; top: 0; width: 100%; z-index: 100;
      padding: 18px 5vw;
      display: flex; align-items: center; justify-content: space-between;
      background: rgba(13,13,13,0.75);
      backdrop-filter: blur(14px);
      border-bottom: 1px solid rgba(61,191,191,0.12);
    }
    .logo-wrap {
      display: flex; align-items: center; gap: 12px;
      text-decoration: none; color: inherit;
    }
    .logo-img {
      width: 44px; height: 44px; border-radius: 10px;
      object-fit: cover;
      box-shadow: 0 0 16px rgba(61,191,191,0.4);
    }
    .logo-text {
      font-size: 1.35rem; font-weight: 700;
      letter-spacing: -0.02em;
      background: linear-gradient(135deg, var(--teal-light), var(--teal-dark));
      -webkit-background-clip: text; -webkit-text-fill-color: transparent;
    }
    nav { display: flex; gap: 28px; }
    nav a {
      color: rgba(245,245,240,0.7); text-decoration: none;
      font-size: 0.95rem; font-weight: 400;
      transition: color 0.2s;
      position: relative;
    }
    nav a::after {
      content: ''; position: absolute; bottom: -3px; right: 0;
      width: 0; height: 1.5px; background: var(--teal);
      transition: width 0.25s;
    }
    nav a:hover { color: var(--teal-light); }
    nav a:hover::after { width: 100%; }

    /* ---- HERO ---- */
    .hero {
      min-height: 100vh;
      display: flex; flex-direction: column;
      align-items: center; justify-content: center;
      position: relative; overflow: hidden;
      padding: 120px 5vw 80px;
      text-align: center;
    }

    /* animated SVG wave background */
    .hero-bg {
      position: absolute; inset: 0; z-index: 0;
      overflow: hidden;
    }
    .hero-bg svg {
      position: absolute; width: 200%; height: 200%;
      top: -50%; left: -50%;
      opacity: 0.22;
      animation: rotateBg 40s linear infinite;
    }
    @keyframes rotateBg {
      from { transform: rotate(0deg); }
      to   { transform: rotate(360deg); }
    }

    /* Glowing orbs */
    .orb {
      position: absolute; border-radius: 50%;
      filter: blur(80px); pointer-events: none;
    }
    .orb-1 {
      width: 500px; height: 500px;
      background: radial-gradient(circle, rgba(61,191,191,0.28) 0%, transparent 70%);
      top: -100px; right: -100px;
      animation: floatOrb 8s ease-in-out infinite;
    }
    .orb-2 {
      width: 350px; height: 350px;
      background: radial-gradient(circle, rgba(125,224,224,0.18) 0%, transparent 70%);
      bottom: 50px; left: 0;
      animation: floatOrb 11s ease-in-out infinite reverse;
    }
    @keyframes floatOrb {
      0%, 100% { transform: translateY(0px); }
      50% { transform: translateY(-40px); }
    }

    .hero-content { position: relative; z-index: 1; }

    .hero-badge {
      display: inline-block;
      background: rgba(61,191,191,0.12);
      border: 1px solid rgba(61,191,191,0.3);
      color: var(--teal-light);
      font-size: 0.8rem; letter-spacing: 0.1em;
      padding: 6px 16px; border-radius: 100px;
      margin-bottom: 28px;
      animation: fadeUp 0.8s ease both;
    }

    .hero h1 {
      font-size: clamp(3rem, 9vw, 7.5rem);
      font-weight: 900;
      line-height: 1.0;
      letter-spacing: -0.03em;
      animation: fadeUp 0.9s 0.1s ease both;
    }
    .hero h1 span {
      background: linear-gradient(135deg, var(--teal-light) 0%, var(--teal) 50%, var(--teal-dark) 100%);
      -webkit-background-clip: text; -webkit-text-fill-color: transparent;
    }

    .hero-sub {
      margin-top: 20px;
      font-size: clamp(1rem, 2.5vw, 1.35rem);
      color: rgba(245,245,240,0.6);
      font-weight: 300;
      max-width: 560px; margin-left: auto; margin-right: auto;
      animation: fadeUp 1s 0.2s ease both;
    }

    .hero-cta {
      margin-top: 44px;
      display: flex; gap: 16px; justify-content: center; flex-wrap: wrap;
      animation: fadeUp 1s 0.3s ease both;
    }

    .btn-primary {
      background: linear-gradient(135deg, var(--teal), var(--teal-dark));
      color: var(--black); font-weight: 700;
      padding: 14px 32px; border-radius: 12px;
      border: none; font-size: 1rem; font-family: inherit;
      cursor: none; text-decoration: none;
      transition: transform 0.2s, box-shadow 0.2s;
      box-shadow: 0 8px 30px rgba(61,191,191,0.35);
      display: inline-block;
    }
    .btn-primary:hover {
      transform: translateY(-3px);
      box-shadow: 0 14px 40px rgba(61,191,191,0.5);
    }
    .btn-outline {
      background: transparent;
      border: 1.5px solid rgba(61,191,191,0.45);
      color: var(--teal-light); font-weight: 400;
      padding: 14px 32px; border-radius: 12px;
      font-size: 1rem; font-family: inherit;
      cursor: none; text-decoration: none;
      transition: transform 0.2s, background 0.2s, border-color 0.2s;
      display: inline-block;
    }
    .btn-outline:hover {
      background: rgba(61,191,191,0.1);
      border-color: var(--teal);
      transform: translateY(-3px);
    }

    .hero-stats {
      margin-top: 72px;
      display: flex; gap: 48px; justify-content: center;
      animation: fadeUp 1s 0.4s ease both;
    }
    .stat { text-align: center; }
    .stat-num {
      font-size: 2.4rem; font-weight: 900;
      color: var(--teal-light);
      line-height: 1;
    }
    .stat-label {
      font-size: 0.8rem; color: rgba(245,245,240,0.45);
      margin-top: 4px; letter-spacing: 0.06em;
    }

    @keyframes fadeUp {
      from { opacity: 0; transform: translateY(28px); }
      to   { opacity: 1; transform: translateY(0); }
    }

    /* ---- SCROLL INDICATOR ---- */
    .scroll-hint {
      position: absolute; bottom: 36px; left: 50%; transform: translateX(-50%);
      display: flex; flex-direction: column; align-items: center; gap: 8px;
      opacity: 0.4; font-size: 0.75rem; color: var(--teal-light);
      animation: fadeUp 1s 0.8s ease both;
    }
    .scroll-hint-line {
      width: 1px; height: 48px;
      background: linear-gradient(to bottom, transparent, var(--teal));
      animation: scrollPulse 2s ease-in-out infinite;
    }
    @keyframes scrollPulse {
      0%, 100% { transform: scaleY(1); opacity: 0.4; }
      50% { transform: scaleY(1.3); opacity: 0.9; }
    }

    /* ---- SECTION COMMON ---- */
    section { padding: 100px 5vw; }
    .section-label {
      font-size: 0.75rem; letter-spacing: 0.15em;
      color: var(--teal); text-transform: uppercase;
      margin-bottom: 12px; font-weight: 700;
    }
    .section-title {
      font-size: clamp(1.8rem, 4.5vw, 3rem);
      font-weight: 900; letter-spacing: -0.02em;
      line-height: 1.15;
    }
    .section-title span { color: var(--teal-light); }

    /* ---- GAMES SECTION ---- */
    #games { background: linear-gradient(180deg, var(--black) 0%, #0a1515 100%); }
    .games-intro { max-width: 600px; margin-bottom: 64px; }

    .games-grid {
      display: grid;
      grid-template-columns: repeat(auto-fill, minmax(min(260px, calc(50% - 12px)), 1fr));
      gap: 24px;
    }

    .game-card {
      background: var(--card-bg);
      border: 1px solid rgba(61,191,191,0.1);
      border-radius: 20px;
      overflow: hidden;
      transition: transform 0.3s, border-color 0.3s, box-shadow 0.3s;
      position: relative;
      display: flex; flex-direction: column;
    }
    .game-card:hover {
      transform: translateY(-8px);
      border-color: rgba(61,191,191,0.4);
      box-shadow: 0 24px 60px rgba(61,191,191,0.15);
    }
    .game-card::before {
      content: ''; position: absolute; inset: 0;
      background: linear-gradient(135deg, rgba(61,191,191,0.05), transparent);
      opacity: 0; transition: opacity 0.3s;
      pointer-events: none; border-radius: 20px;
    }
    .game-card:hover::before { opacity: 1; }

    .game-thumb {
      height: clamp(120px, 26vw, 190px);
      display: flex; align-items: center; justify-content: center;
      font-size: 5rem;
      position: relative; overflow: hidden;
    }
    .game-thumb-milmila {
      background: linear-gradient(135deg, #4a9e4a 0%, #6abf6a 100%);
    }
    .game-thumb-chess {
      background: linear-gradient(135deg, #1a2a2a 0%, #2a4040 100%);
    }
    .game-thumb-cards {
      background: linear-gradient(135deg, #1a1a2a 0%, #2a2a4a 100%);
    }

    /* chess pattern */
    .chess-pattern {
      position: absolute; inset: 0;
      background-image:
        linear-gradient(45deg, rgba(61,191,191,0.15) 25%, transparent 25%),
        linear-gradient(-45deg, rgba(61,191,191,0.15) 25%, transparent 25%),
        linear-gradient(45deg, transparent 75%, rgba(61,191,191,0.15) 75%),
        linear-gradient(-45deg, transparent 75%, rgba(61,191,191,0.15) 75%);
      background-size: 40px 40px;
      background-position: 0 0, 0 20px, 20px -20px, -20px 0px;
    }

    /* card suit pattern */
    .card-pattern {
      position: absolute; inset: 0;
      opacity: 0.15;
      background: repeating-linear-gradient(
        -45deg,
        rgba(61,191,191,0.3),
        rgba(61,191,191,0.3) 2px,
        transparent 2px,
        transparent 24px
      );
    }

    .game-logo {
      width: 80px; height: 80px; object-fit: cover;
      border-radius: 16px; position: relative; z-index: 1;
      box-shadow: 0 8px 24px rgba(0,0,0,0.4);
    }
    .game-icon-large {
      position: relative; z-index: 1;
      font-size: 4rem;
    }

    .game-body { padding: 24px; flex: 1; display: flex; flex-direction: column; }
    .game-platform {
      display: inline-flex; align-items: center; gap: 6px;
      background: rgba(61,191,191,0.1);
      border: 1px solid rgba(61,191,191,0.2);
      color: var(--teal-light); font-size: 0.72rem;
      padding: 4px 10px; border-radius: 6px;
      margin-bottom: 14px; font-weight: 600; letter-spacing: 0.05em;
    }
    .game-name {
      font-size: 1.5rem; font-weight: 900;
      margin-bottom: 6px; letter-spacing: -0.01em;
    }
    .game-desc {
      font-size: 0.9rem; color: rgba(245,245,240,0.55);
      line-height: 1.65; flex: 1; margin-bottom: 20px;
      font-family: 'Assistant', sans-serif;
    }
    .game-link {
      display: inline-flex; align-items: center; gap: 8px;
      background: rgba(61,191,191,0.12);
      border: 1px solid rgba(61,191,191,0.25);
      color: var(--teal-light);
      padding: 11px 20px; border-radius: 10px;
      text-decoration: none; font-size: 0.88rem; font-weight: 600;
      transition: background 0.2s, transform 0.2s;
      align-self: flex-start;
    }
    .game-link:hover {
      background: rgba(61,191,191,0.22);
      transform: translateX(-4px);
    }
    .game-link svg { flex-shrink: 0; }

    /* Milmila special card */
    .game-card-milmila .game-name { color: #8de08d; }
    .game-card-chess .game-name { color: var(--teal-light); }
    .game-card-cards .game-name { color: #b0a0ff; }
    .game-card-guessword .game-name { color: #f5c842; }
    .game-card-imposter .game-name { color: #ff7a45; }
    .game-thumb-guessword {
      background: linear-gradient(135deg, #1a1400 0%, #2e2200 100%);
    }
    .game-thumb-imposter {
      background: linear-gradient(135deg, #1a0e00 0%, #2e1400 100%);
    }
    .game-thumb-category {
      background: linear-gradient(135deg, #1a0a2e 0%, #2a1a4a 100%);
    }
    .game-thumb-hirtotim {
      background: linear-gradient(135deg, #001a1a 0%, #0a2a2e 100%);
    }
    .game-card-category .game-name { color: #b87eff; }
    .game-card-hirtotim .game-name { color: #2dd4bf; }
    .word-pattern {
      position: absolute; inset: 0; overflow: hidden;
    }
    .word-pattern::before {
      content: 'נחש תמילה נחש תמילה נחש תמילה נחש תמילה נחש תמילה נחש תמילה נחש תמילה נחש תמילה נחש תמילה נחש תמילה נחש תמילה נחש תמילה נחש תמילה נחש תמילה נחש תמילה נחש תמילה נחש תמילה נחש תמילה נחש תמילה נחש תמילה';
      position: absolute; inset: 0;
      font-size: 1.3rem; font-weight: 900; letter-spacing: 0.15em;
      color: rgba(245,200,66,0.13); line-height: 2.0;
      word-break: break-all; padding: 10px;
      font-family: 'Assistant', sans-serif;
    }
    .word-pattern-imposter::before {
      content: 'המתחזה המתחזה המתחזה המתחזה המתחזה המתחזה המתחזה המתחזה המתחזה המתחזה המתחזה המתחזה המתחזה המתחזה המתחזה המתחזה המתחזה';
      position: absolute; inset: 0;
      font-size: 1.3rem; font-weight: 900; letter-spacing: 0.15em;
      color: rgba(255,122,69,0.13); line-height: 2.0;
      word-break: break-all; padding: 10px;
      font-family: 'Assistant', sans-serif;
    }
    .category-pattern {
      position: absolute; inset: 0; overflow: hidden;
    }
    .category-pattern::before {
      content: 'קטגוריה קטגוריה קטגוריה קטגוריה קטגוריה קטגוריה קטגוריה קטגוריה קטגוריה קטגוריה קטגוריה קטגוריה קטגוריה קטגוריה קטגוריה קטגוריה קטגוריה קטגוריה קטגוריה קטגוריה';
      position: absolute; inset: 0;
      font-size: 1.3rem; font-weight: 900; letter-spacing: 0.15em;
      color: rgba(184,126,255,0.15); line-height: 2.0;
      word-break: break-all; padding: 10px;
      font-family: 'Assistant', sans-serif;
    }
    .hirtotim-pattern {
      position: absolute; inset: 0; overflow: hidden;
    }
    .hirtotim-pattern::before {
      content: 'חירטוט חירטוט חירטוט חירטוט חירטוט חירטוט חירטוט חירטוט חירטוט חירטוט חירטוט חירטוט חירטוט חירטוט חירטוט חירטוט חירטוט חירטוט חירטוט חירטוט חירטוט';
      position: absolute; inset: 0;
      font-size: 1.3rem; font-weight: 900; letter-spacing: 0.15em;
      color: rgba(45,212,191,0.15); line-height: 2.0;
      word-break: break-all; padding: 10px;
      font-family: 'Assistant', sans-serif;
    }

    /* ---- ABOUT SECTION ---- */
    #about {
      background: #0a1515;
      position: relative; overflow: hidden;
    }
    .about-inner {
      display: grid;
      grid-template-columns: 1fr 1fr;
      gap: 80px; align-items: center;
    }
    .about-visual {
      position: relative;
      display: flex; align-items: center; justify-content: center;
    }
    .about-logo-big {
      width: 200px; height: 200px; object-fit: cover;
      border-radius: 28px;
      box-shadow: 0 0 60px rgba(61,191,191,0.3), 0 0 120px rgba(61,191,191,0.1);
      position: relative; z-index: 1;
      animation: logoFloat 6s ease-in-out infinite;
    }
    @keyframes logoFloat {
      0%, 100% { transform: translateY(0) rotate(0deg); }
      50% { transform: translateY(-12px) rotate(1deg); }
    }
    .about-ring {
      position: absolute;
      border: 1px dashed rgba(61,191,191,0.2);
      border-radius: 50%;
      animation: ringRotate 20s linear infinite;
    }
    .about-ring-1 { width: 300px; height: 300px; }
    .about-ring-2 { width: 400px; height: 400px; animation-direction: reverse; animation-duration: 30s; }
    @keyframes ringRotate { from { transform: rotate(0); } to { transform: rotate(360deg); } }

    .about-dot {
      position: absolute;
      width: 10px; height: 10px;
      background: var(--teal); border-radius: 50%;
      box-shadow: 0 0 12px var(--teal);
    }
    /* position the dot on ring-1 */
    .about-ring-1 .about-dot { top: -5px; left: 50%; transform: translateX(-50%); }

    .about-text .section-title { margin-bottom: 20px; }
    .about-p {
      font-size: 1rem; color: rgba(245,245,240,0.6);
      line-height: 1.75; font-family: 'Assistant', sans-serif;
      margin-bottom: 16px;
    }
    .about-p strong { color: var(--teal-light); font-weight: 700; }

    .about-tags {
      display: flex; flex-wrap: wrap; gap: 8px; margin-top: 28px;
    }
    .tag {
      background: rgba(61,191,191,0.08);
      border: 1px solid rgba(61,191,191,0.18);
      color: var(--teal-light); font-size: 0.8rem;
      padding: 6px 14px; border-radius: 100px;
    }

    /* ---- FOOTER ---- */
    footer {
      background: #060e0e;
      border-top: 1px solid rgba(61,191,191,0.1);
      padding: 48px 5vw;
      display: flex; align-items: center; justify-content: space-between;
      flex-wrap: wrap; gap: 20px;
    }
    .footer-logo { display: flex; align-items: center; gap: 10px; }
    .footer-logo-img { width: 36px; border-radius: 8px; }
    .footer-logo-text { font-size: 1rem; font-weight: 700; color: var(--teal-light); }
    .footer-copy { font-size: 0.8rem; color: rgba(245,245,240,0.3); }
    .footer-link {
      font-size: 0.85rem; color: rgba(61,191,191,0.7);
      text-decoration: none; transition: color 0.2s;
    }
    .footer-link:hover { color: var(--teal-light); }

    /* ---- REVEAL ANIMATION ---- */
    .reveal {
      opacity: 0; transform: translateY(36px);
      transition: opacity 0.7s ease, transform 0.7s ease;
    }
    .reveal.visible { opacity: 1; transform: none; }

    /* ---- DIVIDER ---- */
    .wave-divider {
      width: 100%; overflow: hidden; line-height: 0;
      height: 60px;
    }
    .wave-divider svg { display: block; }

    /* ---- GAMES PAGE ---- */
    .games-page-header {
      position: sticky; top: 0;
      background: rgba(13,13,13,0.92);
      backdrop-filter: blur(12px);
      border-bottom: 1px solid rgba(61,191,191,0.1);
      padding: 16px 5vw;
      display: flex; align-items: center; gap: 16px;
      z-index: 100;
    }
    .back-btn {
      display: flex; align-items: center; gap: 6px;
      color: var(--teal-light); text-decoration: none;
      font-size: 0.9rem; font-weight: 700;
      padding: 8px 14px;
      border: 1px solid rgba(61,191,191,0.3);
      border-radius: 10px;
      transition: background 0.2s, border-color 0.2s;
      white-space: nowrap;
    }
    .back-btn:hover { background: rgba(61,191,191,0.1); border-color: var(--teal); }
    .games-page-title { font-size: 1.2rem; font-weight: 900; color: var(--white); }
    .games-controls {
      padding: 28px 5vw 0;
      display: flex; flex-direction: column; gap: 14px;
      max-width: 900px; margin: 0 auto; width: 100%;
    }
    .games-search-input {
      width: 100%; padding: 14px 18px;
      background: rgba(61,191,191,0.05);
      border: 1px solid rgba(61,191,191,0.2);
      border-radius: 14px; color: var(--white);
      font-family: 'Heebo', sans-serif; font-size: 1rem;
      outline: none; transition: border-color 0.2s; direction: rtl;
    }
    .games-search-input:focus { border-color: var(--teal); }
    .games-search-input::placeholder { color: rgba(245,245,240,0.3); }
    .filter-tabs { display: flex; gap: 8px; }
    .filter-tab {
      padding: 8px 18px;
      border: 1px solid rgba(61,191,191,0.2);
      border-radius: 20px; background: transparent;
      color: rgba(245,245,240,0.5);
      font-family: 'Heebo', sans-serif;
      font-size: 0.85rem; font-weight: 700;
      cursor: none; transition: all 0.2s;
    }
    .filter-tab.active { background: var(--teal); border-color: var(--teal); color: var(--black); }
    .games-page-grid {
      padding: 28px 5vw 60px;
      display: grid; grid-template-columns: repeat(auto-fill, minmax(min(260px, calc(50% - 12px)), 1fr));
      gap: 24px; max-width: 900px; margin: 0 auto; width: 100%;
    }
    .game-card.hidden { display: none; }
    .no-results {
      grid-column: 1 / -1; text-align: center;
      color: rgba(245,245,240,0.3); font-size: 1rem; padding: 60px 0;
    }
    .games-page-footer {
      text-align: center; padding: 0 5vw 60px;
    }

    /* ---- RESPONSIVE ---- */
    @media (max-width: 768px) {
      .about-inner { grid-template-columns: 1fr; gap: 48px; }
      .about-visual { display: none; }
      nav { display: none; }
      .hero-stats { gap: 28px; }
    }