/* ==== ROOT VARIABLES & BODY ==== */
:root {
    /* Variabel Warna Ungu Baru */
    --tg-gold-light: #a37e2c;
    --tg-gold-mid: #d4af37;
    --tg-gold-dark: #ffd700;
    --tg-gold-deep: #1a1208;

    /* Variabel Warna Status */
    --tg-red: #e02424;
    --tg-green: #16a34a;

    /* Variabel Warna Dasar */
    --tg-gray: #666;
    --tg-black: #000;
    --tg-white: #fff;

    font-family: "Inter", Arial, sans-serif;
    color: #f0f0f0;
}

body {
    background: linear-gradient(180deg, #000000, #1a1208, #4a3820, #a67c00, #ffd700);
    background-size: cover;
    background-repeat: no-repeat;
    background-attachment: fixed;
    background-position: center;
    margin: 0;
    padding: 0;
}

/* Tambah WIB di belakang semua value jam */
.time-value::after {
  content: " WIB";
  font-size: 11px;
  font-weight: normal;
  color: #ccc;
  margin-left: 3px;
}


/* ==== LAYOUT & HEADER ==== */
.container {
    max-width: 1200px;
    margin: 20px auto;
    padding: 20px;
    background-color: rgba(64, 53, 0, 0.88); 
    border-radius: 15px;
    border: 2px solid #ffd700;
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
}

.ttg-hdr {
    margin: 10px auto 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
}

@keyframes ttg-slideHue {
    0% { background-position: 0% 50%; }
    100% { background-position: 200% 50%; }
}

.ttg-hdg {
    font-size: clamp(1.8rem, 5vw, 2.4rem);
    font-weight: 900;
    margin: 0;
    line-height: 1.1;
    background: linear-gradient(45deg, var(--tg-gold-mid), var(--tg-gold-light), var(--tg-gold-mid));
    background-size: 200% 200%;
    background-clip: text;
    -webkit-background-clip: text;
    color: transparent;
    animation: ttg-slideHue 4s linear infinite;
    white-space: nowrap;
}

/* ==== SEARCH BAR ==== */
.ttg-srch input[type="search"] {
    border: 2px solid var(--tg-gold-mid);
    border-radius: 30px;
    padding: 10px 16px;
    min-width: 250px;
    font-size: 1rem;
    transition: box-shadow .25s;
    outline: none;
    background: #f0f0f0;
    color: #333;
}

.ttg-srch input[type="search"]:focus {
    box-shadow: 0 0 0 4px rgba(255, 223, 97, 0.25);
}

.ttg-srch input[type="search"]::placeholder {
    color: #888;
}

/* ==== RUNNING TEXT & JACKPOT ==== */
@keyframes marquee-scroll-seamless {
    0% { transform: translateX(0%); }
    100% { transform: translateX(-50%); }
}

.marquee-container,
.jackpot-marquee-container {
    background-color: rgba(0, 0, 0, 0.4);
    border-radius: 8px;
    padding: 8px 15px;
    overflow: hidden;
    margin-bottom: 15px;
    border: 2px solid var(--tg-gold-mid);
    display: flex;
}

.jackpot-marquee-container {
    background-color: rgba(255, 234, 97, 0.1);
    border: 2px solid var(--tg-gold-dark);
    box-shadow: 0 0 10px rgba(255, 226, 97, 0.3);
    margin-top: 15px;
}

.marquee-content {
    display: flex;
    white-space: nowrap;
    -webkit-transform: translateZ(0);
    transform: translateZ(0);
    animation: marquee-scroll-seamless 25s linear infinite;
}

.jackpot-marquee-container .marquee-content {
    animation-duration: 120s;
}

.marquee-text,
#jackpot-text {
    display: block;
    margin: 0;
    font-size: 14px;
    padding-right: 50px;
}

#jackpot-text {
    font-size: 15px;
    font-weight: 500;
}

#jackpot-text strong {
    color: var(--tg-gold-light);
    font-weight: 700;
}

/* ==== GRID & CARDS ==== */
.ttg-sep {
    border: none;
    border-top: 2px solid var(--tg-gold-mid);
    margin: 20px auto;
}

.ttg-grid {
    margin: 0 auto 40px;
    display: grid;
    gap: 22px;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
}

.ttg-card {
    background: linear-gradient(180deg, #000000, #1a1208, #4a3820, #a67c00, #ffd700);
    border: 2px solid var(--tg-gold-mid);
    border-radius: 12px;
    box-shadow: 0px 4px 15px -4px rgba(0,0,0,0.5);
    padding: 15px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    transition: transform .25s, box-shadow .25s;
}

.ttg-card:hover {
    transform: translateY(-5px);
    box-shadow: 0px 8px 25px -6px rgba(255, 247, 97, 0.25);
}

.ttg-card__title {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--tg-white);
    text-align: center;
    margin-bottom: 4px;
    border-bottom: 2px solid #444;
    padding-bottom: 10px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
}

.ttg-card__row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 14px;
}

.ttg-card__label {
    color: #ccc;
    font-weight: 500;
}

.ttg-card__value {
    font-weight: 700;
    color: var(--tg-white);
}

.ttg-card__value--tutup { color: var(--tg-red); }
.ttg-card__value--buka { color: var(--tg-green); }

.ttg-card__site a {
    border: none;
    display: block;
    margin-top: 8px;
    text-align: center;
    background: linear-gradient(90deg, #a37e2c 0%, #d4af37 40%, #ffd700 100%);
    color: var(--tg-black);
    padding: 10px 0;
    border-radius: 6px;
    border: 2px solid #000000;
    font-weight: 700;
    text-decoration: none;
    text-transform: uppercase;
    transition: background .25s, transform 0.2s;
}

.ttg-card__site a:hover {
    background: linear-gradient(135deg, #7d5a20 0%, #d4af37 30%, #ffdf00 50%, #d4af37 70%, #7d5a20 100%);
    transform: scale(1.03);
}

/* ==== STATUS & UTILITIES ==== */
.loading-text, .not-found-text {
    grid-column: 1 / -1;
    text-align: center;
    font-size: 1.2rem;
    color: #ccc;
    padding: 40px;
    background-color: rgba(0,0,0,0.3);
    border-radius: 8px;
}

.status {
    display: inline-block;
    padding: 4px 12px;
    font-size: 11px;
    font-weight: 700;
    color: #fff;
    border-radius: 12px;
    vertical-align: middle;
    text-transform: uppercase;
}

.status-buka {
    background-color: var(--tg-green);
    box-shadow: 0 0 8px rgba(22, 163, 74, 0.5);
}

.status-tutup {
    background-color: var(--tg-red);
    box-shadow: 0 0 8px rgba(224, 36, 36, 0.5);
}

/* ==== RESPONSIVE FIX ==== */
@media (max-width: 600px) {
  .container {
    margin: 10px;
    padding: 12px;
  }

  .ttg-hdr {
    flex-direction: column;
    gap: 10px;
    text-align: center;
  }

  .ttg-hdg {
    font-size: 1.4rem;
    white-space: normal; 
    text-align: center;
  }

  .ttg-srch input[type="search"] {
    width: 100%;
    min-width: unset; 
  }

  .marquee-text,
  #jackpot-text {
    font-size: 12px;
  }

  .ttg-card {
    padding: 12px;
  }

  .ttg-card__title {
    font-size: 1rem;
  }

  .ttg-card__row {
    font-size: 12px;
    flex-wrap: wrap;
    gap: 6px;
  }
}
