
:root{
      --purple-1:#4124b8;
      --purple-2:#5b3bea;
      --accent:#ffd24d;
      --muted:#8b8ea9;
      --card:#ffffff;
      --glass: rgba(255,255,255,0.06);
      --shadow: 0 8px 30px rgba(23,18,58,0.08);
      --radius:12px;
      --brand:#6c2bd9;
      --ink:#222;
      --line:#eaeaea;
      --bg:#ffffff;
      --chip:#f5f5f7;
}

html,body{
      height:100%;
}

body{
      font-family: "Poppins", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial;
      color:#222;
      background:#fff;
      -webkit-font-smoothing:antialiased;
      -moz-osx-font-smoothing:grayscale;
}

/* --------------- Header--------------------*/
.navbar {
      background-color: white;
    }
    .btn-login {
      background: linear-gradient(90deg, #6a11cb, #2575fc);
      border: none;
      color: white;
      font-weight: 500;
    }
    .btn-login:hover {
      opacity: 0.9;
    }
    .navbar{
      background:#fff;
      border-bottom:1px solid var(--line);
    }
    .navbar-brand{
      font-weight:700;
      color:var(--brand)!important;
      letter-spacing:.3px
    }
    .navbar-nav .nav-link{
      color:#333!important;
      margin-right:18px
    }
    
    
/* NAV */
    
    .brand{
      display:flex; 
      align-items:center; 
      gap:.5rem; 
      font-weight:700; 
      color:var(--purple-2);
    }

    .brand .logo{
      width:36px; 
      height:36px; 
      border-radius:8px; 
      display:grid; 
      place-items:center; 
      background:linear-gradient(135deg,#6a41e2,#3b2ccf); 
      color:#fff;
      box-shadow: 0 4px 12px rgba(59,44,207,0.25);
    }


/* Hero */
    .hero {
      background: linear-gradient(135deg, #5b2be0, #7f5df0);
      color: #fff;
      text-align: center;
      padding: 80px 20px;
    }
    .hero .title {
      font-size: 2.8rem;
      font-weight: 700;
      margin: 20px 0;
      line-height: 1.05;
    }
    .prize-pill {
      background: #ffef9f;
      border-radius: 50px;
      padding: 10px 20px;
      font-weight: 600;
      color: #5b3b00;
      display: inline-flex;
      align-items: center;
    }
    .prize-pill i { margin-right: .5rem; color: #5b3b00; }

    .btn-cta {
      background: #ffca2c;
      color: #000;
      font-weight: 700;
      border-radius: 50px;
      padding: 12px 30px;
      margin-top: 20px;
      border: none;
    }
    .btn-cta:hover { opacity: .95; }

    .kpi-row {
      display: flex;
      justify-content: center;
      gap: 40px;
      margin-top: 40px;
      flex-wrap: wrap;
    }
    .kpi {
      text-align: center;
      min-width: 140px;
    }
    .kpi .num {
      font-size: 1.6rem;
      font-weight: 700;
    }
    .kpi .label {
      font-size: 0.9rem;
      color: rgba(255,255,255,0.9);
    }

    /* Sections */
    .section {
      padding: 60px 0;
    }

    /* Winners */
    .winner-card {
      background: #fff;
      border-radius: 12px;
      overflow: hidden;
      box-shadow: 0 4px 12px rgba(0,0,0,0.08);
      text-align: center;
      transition: transform 0.2s;
      position: relative;
    }
    .winner-card:hover {
      transform: translateY(-6px);
    }
    .winner-card img {
      width: 100%;
      height: 220px;
      object-fit: cover;
    }
    .winner-body {
      padding: 15px;
    }
    .winner-name {
      font-weight: 600;
      font-size: 1.05rem;
    }
    .winner-win {
      color: #28a745;
      font-weight: 700;
      margin-top: .4rem;
    }
    .winner-date {
      font-size: 0.88rem;
      color: #888;
      margin-top: .25rem;
    }

    /* Winner Ribbons */
    .badge-win {
      position: absolute;
      top: 12px;
      left: -30px;
      background: #ffca2c;
      color: #000;
      font-size: 0.75rem;
      font-weight: 700;
      padding: 5px 40px;
      transform: rotate(-45deg);
      box-shadow: 0 2px 6px rgba(0,0,0,0.15);
    }
    .crown {
      position: absolute;
      top: 12px;
      right: 12px;
      background: #fff;
      color: #eab308;
      font-size: 0.9rem;
      font-weight: 700;
      border-radius: 50%;
      padding: 10px 14px;
      box-shadow: 0 2px 6px rgba(0,0,0,0.15);
    }

    /* How to Participate */
    .how-card {
      background: #f9f9f9;
      border-radius: 12px;
      padding: 20px;
      text-align: center;
      transition: 0.3s;
      height: 100%;
    }
    .how-card:hover {
      background: #fff;
      box-shadow: 0 6px 14px rgba(0,0,0,0.06);
    }
    .how-icon {
      font-size: 1.9rem;
      color: #5b2be0;
      margin-bottom: 10px;
    }

    /* Why list & CTA two-column */
    .why-section { margin-top: 30px; }
    .why-list {
      list-style: none;
      padding: 0;
      margin: 0;
    }
    .why-list li {
      display: flex;
      align-items: flex-start;
      gap: 12px;
      margin-bottom: 14px;
      font-size: 0.98rem;
    }
    .why-list li i {
      color: #28a745;
      font-size: 1.15rem;
      margin-top: 2px;
      background: rgba(40,167,69,0.08);
      padding: 6px;
      border-radius: 8px;
    }

    .cta-panel {
      background: linear-gradient(135deg, #5b2be0, #7f5df0);
      color: #fff;
      padding: 28px 22px;
      border-radius: 12px;
      margin-top: 10px;
      height: 100%;
      display: flex;
      flex-direction: column;
      justify-content: center;
      align-items: center;
      text-align: center;
    }
    .cta-panel .btn {
      background: #ffca2c;
      border: none;
      color: #000;
      font-weight: 700;
      border-radius: 50px;
      padding: 12px 30px;
      margin-top: 12px;
    }
    .cta-panel .btn:hover { opacity: .96; }

    /* small screens tweaks */
    @media (max-width: 767px) {
      .hero .title { font-size: 1.9rem; }
      .kpi-row { gap: 18px; }
      .kpi .num { font-size: 1.3rem; }
      .winner-card img { height: 180px; }
    }


/* Footer gradient */
    footer{
      background: linear-gradient(135deg,#6a41e2 0%, #8b6ef2 50%, #c99df9 100%);
      color:#fff;
      padding:36px 0 22px; 
      margin-top:36px;
    }

    footer a{ 
      color:rgba(255,255,255,0.95); 
      text-decoration:none;
    }

    .small-muted{ 
      color:rgba(0,0,0,0.45);
     }

/* Results Page */
/* Page width like screenshot */
  .page{
    max-width:980px;
    margin:0 auto;
    padding:0 16px
  }

  /* Title */
  .page-title{
    margin:42px 0 6px;
    text-align:center
  }

  .page-title h1{
    font-weight:800;
    font-size:2.25rem;
    margin:0
  }

  .page-title p{
    margin:8px 0 0;
    color:var(--muted)
  }

  /* Back button (soft grey) */
  .back-wrap{
    text-align:center;
    margin:14px 0 22px
  }

  .back-btn{
    background:#f7f7f8;
    border:1px solid var(--line);
    border-radius:8px;
    font-weight:600;
    color:#3b3b3b;
    padding:.4rem .9rem
  }

  .back-btn i{
    margin-right:6px
  }

  /* Segmented nav (All Entries / Leaderboard / Rules / Prizes) */
  .seg{
    display:flex;
    gap:2px;
    background:#f3f4f6;
    border-radius:10px;
    padding:4px;
    max-width:820px;
    margin:0 auto 24px;
    border:1px solid var(--line)
  }

  .seg .seg-btn{
    flex:1;
    background:transparent;
    border:0;
    border-radius:8px;
    padding:.6rem 0;
    font-weight:600;
    color:#4b5563
  }

  .seg .seg-btn.active{
    background:#fff;
    color:var(--ink);
    box-shadow:0 1px 2px rgba(0,0,0,.04)
  }

  /* Age category segmented bar */
  .seg.age{
    max-width:870px;
    margin:0 auto 22px;
    border-color:#eee
  }

  .seg.age .seg-btn{
    background:#f5f5f7;
    color:#555;
    border:1px solid transparent
  }

  .seg.age .seg-btn.active{
    background:#fff;
    border:1px solid var(--line);
    color:var(--brand);
  }
  
  /* Age category content */
  .age-content {
    display: none;
  }

  .age-content.active {
    display: block;
  }


  /* Section header text */
  .section-intro{
    text-align:center;
    margin:6px 0 24px;
  }

  .section-intro h5{
    font-weight:800;
    margin-bottom:6px;
  }

  .section-intro p{
    color:var(--muted);
    margin:0;
  }

  /* Cards */
  .entry-card{
    border:1px solid var(--line);
    border-radius:14px;
    background:#fff;
    overflow:hidden;
  }

  .entry-img{
    width:100%;
    height:320px;
    object-fit:cover;
    background:#fafafa
  }

  .entry-body{
    padding:14px;
  }

  .entry-name{
    font-weight:700;
    margin:0 0 2px;
  }

  .badge-cat{
    background:#f3f4f6;
    border:1px solid #ededed;
    border-radius:999px;
    padding:2px 10px;
    font-size:.72rem;
    margin-left:6px;
  }

  .meta{
    color:#69707a;
    font-size:.92rem;
  }

  .entry-ctl{
    display:flex;
    justify-content:space-between;
    align-items:center;
    margin-top:12px;
  }

  .votes{
    color:#e03131;
    font-weight:600;
  }

  .vote-btn{
    border:1px solid #dcdcdc;
    background:#fff;
    border-radius:999px;
    padding:4px 16px;
    font-weight:600;
  }

  .vote-btn:hover{
    border-color:var(--brand);
    background:var(--brand);
    color:#fff;
  }

  .vote-btn.voted{
    background:var(--brand);
    color:#fff;
    border-color:var(--brand);
  }

  /* Grid like screenshot (2 cards centered) */
  .grid{
    max-width:900px;
    margin:0 auto;
  }

  /* ============ Added styles for new pages ============ */
  .tab-screen{
    display:none;
  }

  .tab-screen.active{
    display:block
  }


  /* Leaderboard */
  .lb-wrap{
    max-width:840px;
    margin:0 auto;
  }

  .lb-item{
    display:flex;
    align-items:center;
    justify-content:space-between;
    padding:16px 18px;
    border:1px solid var(--line);
    border-radius:12px;
    background:#fff;
    margin-bottom:12px;
  }

  .lb-left{
    display:flex;
    align-items:center;
    gap:12px;
  }

  .lb-rank{
    width:32px;
    height:32px;
    display:inline-flex;
    align-items:center;
    justify-content:center;
    border-radius:999px;
    background:#f8f7ff;
    border:1px solid #eee;
    font-weight:700;
    color:#8b5cf6;
  }

  .lb-name{
    font-weight:700;
  }

  .lb-meta{
    color:#6b7280;
    font-size:.92rem;
  }

  .lb-right{
    display:flex;
    align-items:center;
    gap:10px;
  }

  .lb-votes{
    color:var(--brand);
    font-weight:800;
  }

  .chip{
    background:#f5f5f7;
    border:1px solid #ededed;
    border-radius:999px;
    padding:2px 8px;
    font-size:.72rem;
  }

  /* avatar for leaderboard */
.lb-avatar{
  width:48px;height:48px;
  border-radius:50%;
  object-fit:cover;
  border:1px solid #eee;
  background:#fafafa;
}


  /* Prizes */
  .prize-grid{
    max-width:980px;
    margin:0 auto;
  }

  .prize-card{
    border:1px solid var(--line);
    border-radius:14px;
    background:#fff;
    padding:26px;
    text-align:center;
    height:100%;
  }

  .prize-card .icon{
    font-size:28px;
    margin-bottom:10px;
  }

  .prize-card h6{
    font-weight:800;
    margin:4px 0;
  }

  .prize-amt{
    color:var(--brand);
    font-weight:800;
    font-size:1.75rem;
    margin:4px 0 8px;
  }

  .benefits-card{
    border:1px solid var(--line);
    border-radius:14px;
    background:#fff;
    padding:20px;
  }

  .benefits-card h6{
    font-weight:800;
    margin-bottom:8px;
  }

  .benefits-list{
    columns:2;
  }

  .benefits-list li{
    margin:6px 0;
  }

  /* Rules */
  .rules-card{
    border:1px solid var(--line);
    border-radius:14px;
    background:#fff;
    padding:18px 16px;
  }

  .rules-card h6{
    font-weight:800;
    margin-bottom:12px;

  }
  .num-list{
    counter-reset:item;
    list-style:none;
    padding-left:0;
    margin:0;
  }

  .num-list li{
    counter-increment:item;
    margin:10px 0;
    padding:10px 10px;
    border:1px solid #f0f0f0;
    border-radius:10px;
  }

  .num-list li::before{
    content: counter(item);
    display:inline-flex;
    align-items:center;
    justify-content:center;
    width:24px;
    height:24px;
    border-radius:999px;
    background:#f3f4f6;
    border:1px solid #eaeaea;
    font-size:.8rem;
    font-weight:700;
    margin-right:8px;
    color:#6b7280
  }

  .dates-grid{
    display:grid;
    grid-template-columns:1fr 1fr;
    gap:12px;
  }

  .date-row{
    display:flex;
    justify-content:space-between;
    border:1px solid #f0f0f0;
    border-radius:10px;
    padding:12px;
  }

  .date-row .label{
    color:#6b7280;
  }

  .date-row .value
  {
    font-weight:700;
  }