/* =========================================================
$MEME — Main Stylesheet
========================================================= */

:root {
--bg: #080808;
--bg-soft: #101010;
--card: #111111;
--card-hover: #161616;
--border: #292929;
--text: #f5f5f5;
--muted: #8b8b8b;
--accent: #b7ff00;
--accent-dark: #8fca00;
--danger: #ff3b3b;
--shadow: rgba(0, 0, 0, 0.45);
--radius: 14px;
--max-width: 1150px;
}

/* =========================================================
RESET
========================================================= */

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

html {
scroll-behavior: smooth;
}

body {
min-height: 100vh;
background:
radial-gradient(circle at 50% -10%, rgba(183, 255, 0, 0.08), transparent 35%),
var(--bg);
color: var(--text);
font-family: Arial, Helvetica, sans-serif;
line-height: 1.5;
}

a {
color: inherit;
text-decoration: none;
}

button,
input {
font: inherit;
}

/* =========================================================
HEADER
========================================================= */

.site-header {
width: 100%;
max-width: var(--max-width);
margin: 0 auto;
padding: 24px 28px;

display: flex;
align-items: center;
justify-content: space-between;

position: relative;
z-index: 10;
}

.logo {
font-size: 30px;
font-weight: 1000;
letter-spacing: -2px;
color: var(--accent);
}

.navbar {
display: flex;
align-items: center;
gap: 10px;
}

.welcome {
color: var(--muted);
font-size: 14px;
margin-right: 8px;
}

.nav-link {
color: var(--muted);
font-size: 14px;
padding: 10px 12px;
transition: color 0.2s ease;
}

.nav-link:hover {
color: var(--text);
}

/* =========================================================
BUTTONS
========================================================= */

.button {
display: inline-flex;
align-items: center;
justify-content: center;

min-height: 42px;
padding: 10px 18px;

border: 1px solid var(--accent);
border-radius: 9px;

background: var(--accent);
color: #050505;

font-size: 14px;
font-weight: 800;

cursor: pointer;

transition:
transform 0.15s ease,
background 0.15s ease,
box-shadow 0.15s ease;
}

.button:hover {
background: #caff45;
transform: translateY(-2px);
box-shadow: 0 8px 30px rgba(183, 255, 0, 0.15);
}

.button:active {
transform: translateY(0);
}

.button.secondary {
background: transparent;
color: var(--text);
border-color: var(--border);
}

.button.secondary:hover {
border-color: var(--accent);
color: var(--accent);
box-shadow: none;
}

.button.large {
min-height: 54px;
padding: 13px 30px;
border-radius: 11px;
font-size: 16px;
}

button:disabled {
opacity: 0.45;
cursor: not-allowed;
transform: none;
box-shadow: none;
}

/* =========================================================
FLASH MESSAGES
========================================================= */

.flash-container {
width: min(100% - 40px, 700px);
margin: 10px auto 0;
}

.flash {
padding: 13px 16px;
margin-bottom: 10px;
border-radius: 9px;
border: 1px solid var(--border);
background: var(--card);
font-size: 14px;
}

.flash.success {
border-color: rgba(183, 255, 0, 0.4);
}

.flash.error,
.flash.danger {
border-color: rgba(255, 59, 59, 0.5);
}

/* =========================================================
MAIN LAYOUT
========================================================= */

.main-layout {
width: min(100% - 40px, var(--max-width));
margin: 0 auto;
padding: 70px 0 100px;
}

/* =========================================================
HERO
========================================================= */

.hero {
min-height: 570px;

display: flex;
flex-direction: column;
align-items: center;
justify-content: center;

text-align: center;

position: relative;

border-bottom: 1px solid var(--border);
}

.hero::before {
content: "";
position: absolute;

width: 420px;
height: 420px;

left: 50%;
top: 50%;

transform: translate(-50%, -50%);

background: var(--accent);
opacity: 0.035;

filter: blur(100px);

pointer-events: none;
}

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

.hero-badge {
margin-bottom: 25px;

padding: 7px 13px;

border: 1px solid rgba(183, 255, 0, 0.3);
border-radius: 999px;

color: var(--accent);

font-size: 11px;
font-weight: 900;
letter-spacing: 2px;
}

.hero h1 {
font-size: clamp(70px, 12vw, 145px);
line-height: 0.82;
letter-spacing: -8px;
font-weight: 1000;

margin-bottom: 35px;
}

.hero-text {
max-width: 500px;
margin-bottom: 32px;

color: var(--muted);
font-size: 17px;
}

/* =========================================================
CARDS
========================================================= */

.card {
width: 100%;

margin-top: 25px;
padding: 32px;

background:
linear-gradient(
145deg,
rgba(255, 255, 255, 0.025),
transparent
),
var(--card);

border: 1px solid var(--border);
border-radius: var(--radius);

box-shadow: 0 20px 60px var(--shadow);
}

.section-label {
margin-bottom: 10px;

color: var(--accent);

font-size: 11px;
font-weight: 900;
letter-spacing: 2px;
text-transform: uppercase;
}

.card h2 {
font-size: 36px;
line-height: 1.1;
letter-spacing: -1.5px;
margin-bottom: 10px;
}

.card p {
color: var(--muted);
}

/* =========================================================
GIVEAWAY
========================================================= */

.giveaway-card {
text-align: center;

padding-top: 45px;
padding-bottom: 45px;

background:
radial-gradient(
circle at 50% 100%,
rgba(183, 255, 0, 0.08),
transparent 50%
),
var(--card);
}

.giveaway-card h2 {
font-size: clamp(38px, 7vw, 65px);
color: var(--text);
}

.countdown {
display: flex;
align-items: center;
justify-content: center;

gap: 8px;

margin-top: 30px;

font-size: clamp(30px, 5vw, 50px);
font-weight: 900;
letter-spacing: 2px;
}

.countdown span:not(:nth-child(even)) {
min-width: 70px;

padding: 12px 10px;

background: #080808;
border: 1px solid var(--border);
border-radius: 9px;
}

.countdown-label {
margin-top: 10px;

color: var(--muted);

font-size: 10px;
font-weight: 800;
letter-spacing: 2px;
}

/* =========================================================
GAME
========================================================= */

.game-card {
min-height: 300px;

display: flex;
flex-direction: column;
align-items: center;
justify-content: center;

text-align: center;

background:
linear-gradient(
135deg,
rgba(183, 255, 0, 0.035),
transparent 45%
),
var(--card);
}

.game-card h2 {
font-size: 48px;
}

.game-card p {
margin-bottom: 25px;
}

#snake-game {
  width: 100%;
  max-width: 420px;
  height: auto;
  aspect-ratio: 1 / 1;
  display: block;
  margin: 0 auto;
}

/* =========================================================
LEADERBOARD
========================================================= */

.section-header {
display: flex;
align-items: flex-start;
justify-content: space-between;

margin-bottom: 25px;
}

.live-indicator {
color: var(--accent);
font-size: 11px;
font-weight: 900;
letter-spacing: 1px;
}

.leaderboard {
overflow: hidden;

border: 1px solid var(--border);
border-radius: 10px;
}

.leaderboard-row {
min-height: 62px;
padding: 0 18px;

display: grid;
grid-template-columns: 55px 1fr auto;
align-items: center;

border-bottom: 1px solid var(--border);

background: #0d0d0d;

transition: background 0.15s ease;
}

.leaderboard-row:last-child {
border-bottom: none;
}

.leaderboard-row:hover {
background: var(--card-hover);
}

.leaderboard-row.top {
background:
linear-gradient(
90deg,
rgba(183, 255, 0, 0.06),
transparent
),
#0d0d0d;
}

.rank {
font-size: 16px;
font-weight: 900;
color: var(--muted);
}

.player {
font-weight: 700;
}

.score {
color: var(--accent);
font-weight: 900;
font-variant-numeric: tabular-nums;
}

/* =========================================================
HOW IT WORKS
========================================================= */

.how-it-works {
padding: 90px 0 20px;
}

.how-it-works > .section-label {
text-align: center;
margin-bottom: 30px;
}

.steps {
display: grid;
grid-template-columns: repeat(3, 1fr);
gap: 15px;
}

.step {
min-height: 190px;

padding: 25px;

border: 1px solid var(--border);
border-radius: var(--radius);

background: var(--card);
}

.step-number {
display: block;

margin-bottom: 30px;

color: var(--accent);

font-size: 12px;
font-weight: 900;
letter-spacing: 2px;
}

.step h3 {
margin-bottom: 7px;

font-size: 19px;
letter-spacing: 0.5px;
}

.step p {
color: var(--muted);
font-size: 14px;
}

/* =========================================================
MODALS
========================================================= */

.modal {
position: fixed;

inset: 0;

display: flex;
align-items: center;
justify-content: center;

padding: 20px;

background: rgba(0, 0, 0, 0.82);

opacity: 0;
visibility: hidden;

transition:
opacity 0.2s ease,
visibility 0.2s ease;

z-index: 1000;
}

.modal:target {
opacity: 1;
visibility: visible;
}

.modal-content {
width: min(100%, 430px);

position: relative;

padding: 35px;

background: #111111;

border: 1px solid var(--border);
border-radius: 14px;

box-shadow: 0 30px 100px rgba(0, 0, 0, 0.7);
}

.modal-content h2 {
margin-bottom: 25px;

font-size: 32px;
letter-spacing: -1px;
}

.close {
position: absolute;

top: 15px;
right: 20px;

color: var(--muted);

font-size: 30px;
line-height: 1;

transition: color 0.15s ease;
}

.close:hover {
color: var(--text);
}

/* =========================================================
FORMS
========================================================= */

.modal-content form {
display: flex;
flex-direction: column;
gap: 12px;
}

.modal-content input[type="text"],
.modal-content input[type="email"],
.modal-content input[type="password"] {
width: 100%;

padding: 13px 14px;

border: 1px solid var(--border);
border-radius: 8px;

outline: none;

background: #090909;
color: var(--text);

font-size: 14px;

transition: border-color 0.15s ease;
}

.modal-content input:focus {
border-color: var(--accent);
}

.modal-content input::placeholder {
color: #5f5f5f;
}

.modal-content form .button {
margin-top: 5px;
width: 100%;
}

.modal-content > p {
margin-top: 18px;

color: var(--muted);

font-size: 13px;
}

.modal-content > a:not(.close) {
display: inline-block;

margin-top: 18px;

color: var(--accent);

font-size: 13px;
}

.modal-content > a:not(.close):hover {
text-decoration: underline;
}

/* =========================================================
TERMS
========================================================= */

.terms-box {
margin: 4px 0;
}

.terms-label {
display: flex;
align-items: flex-start;
gap: 9px;

color: var(--muted);

font-size: 12px;
}

.terms-label input {
margin-top: 3px;
accent-color: var(--accent);
}

.terms-label a {
color: var(--accent);
}

/* =========================================================
SEED PHRASE
========================================================= */

.seed-phrase-box {
padding: 18px;

border: 1px solid rgba(183, 255, 0, 0.35);
border-radius: 9px;

background: rgba(183, 255, 0, 0.04);
}

.seed-phrase-box pre {
margin: 15px 0;

padding: 15px;

overflow-x: auto;

border-radius: 7px;

background: #050505;

color: var(--accent);

white-space: pre-wrap;
word-break: break-word;

font-size: 13px;
}

.warning {
color: #ffb000 !important;
font-size: 12px !important;
}

/* =========================================================
FOOTER
========================================================= */

.site-footer {
width: min(100% - 40px, var(--max-width));

margin: 0 auto;
padding: 30px 0 40px;

border-top: 1px solid var(--border);

text-align: center;

color: #555;

font-size: 12px;
}

/* =========================================================
MOBILE
========================================================= */

@media (max-width: 700px) {

.site-header {
padding: 18px 20px;
}

.logo {
font-size: 25px;
}

.navbar {
gap: 5px;
}

.welcome {
display: none;
}

.nav-link {
display: none;
}

.main-layout {
width: min(100% - 24px, var(--max-width));
padding-top: 35px;
}

.hero {
min-height: 500px;
}

.hero h1 {
font-size: clamp(60px, 19vw, 100px);
letter-spacing: -5px;
}

.hero-text {
font-size: 15px;
padding: 0 15px;
}

.card {
padding: 22px;
}

.card h2 {
font-size: 30px;
}

.giveaway-card h2 {
font-size: 38px;
}

.countdown {
gap: 4px;
font-size: 25px;
}

.countdown span:not(:nth-child(even)) {
min-width: 55px;
padding: 9px 6px;
}

.game-card {
min-height: 260px;
}

.game-card h2 {
font-size: 38px;
}

.leaderboard-row {
grid-template-columns: 45px 1fr auto;
min-height: 56px;
padding: 0 13px;
}

.steps {
grid-template-columns: 1fr;
}

.step {
min-height: auto;
}

.how-it-works {
padding-top: 60px;
}

.modal-content {
padding: 28px 22px;
}
}

/* =========================================================
SMALL PHONES
========================================================= */

@media (max-width: 400px) {

.button {
padding-left: 14px;
padding-right: 14px;
}

.button.large {
width: 100%;
}

.hero h1 {
letter-spacing: -4px;
}

.countdown span:not(:nth-child(even)) {
min-width: 48px;
}
}

/* =========================================================
   $MEME TOKEN ADDRESS
========================================================= */

.token-address {
  width: 100%;
  max-width: 700px;
  margin: 24px auto;
  padding: 16px 18px;

  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);

  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;

  box-shadow: 0 8px 30px var(--shadow);
}

.token-label {
  color: var(--accent);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 1px;
  white-space: nowrap;
}

.token-address code {
  flex: 1;
  min-width: 220px;

  padding: 10px 12px;

  background: var(--bg-soft);
  border: 1px solid var(--border);
  border-radius: 8px;

  color: var(--muted);
  font-family: monospace;
  font-size: 12px;

  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.token-address button {
  min-height: 38px;
  padding: 8px 14px;

  border: 1px solid var(--accent);
  border-radius: 8px;

  background: transparent;
  color: var(--accent);

  font-weight: 800;
  cursor: pointer;

  transition: 0.2s ease;
}

.token-address button:hover {
  background: var(--accent);
  color: #050505;
  transform: translateY(-1px);
}

@media (max-width: 600px) {
  .token-address {
    align-items: stretch;
  }

  .token-address code {
    width: 100%;
    flex-basis: 100%;
  }

  .token-address button {
    width: 100%;
  }
}

/* =========================================================
   LEADERBOARD TABS
========================================================= */

.leaderboard-tabs {
  display: flex;
  gap: 6px;
}

.leaderboard-tab {
  padding: 8px 13px;

  border: 1px solid var(--border);
  border-radius: 7px;

  background: transparent;
  color: var(--muted);

  font-size: 11px;
  font-weight: 900;
  letter-spacing: 1px;

  cursor: pointer;
  transition: 0.15s ease;
}

.leaderboard-tab:hover {
  color: var(--text);
  border-color: var(--accent);
}

.leaderboard-tab.active {
  background: var(--accent);
  border-color: var(--accent);
  color: #050505;
}

@media (max-width: 600px) {
  .section-header {
    align-items: center;
    gap: 12px;
  }

  .leaderboard-tabs {
    flex-shrink: 0;
  }

  .leaderboard-tab {
    padding: 7px 10px;
    font-size: 10px;
  }
}


.logo {
  display: flex;
  align-items: center;
  gap: 10px;
}

.logo img {
  width: 42px;
  height: 42px;
  object-fit: cover;
  border-radius: 50%;
  display: block;
}

/* =========================
   LIVE CHAT
   ========================= */

.chat-card {
  margin-top: 24px;
}

.chat-status {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 1px;
}

.chat-status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #35d07f;
  box-shadow: 0 0 8px rgba(53, 208, 127, 0.7);
}

.chat-messages {
  height: 320px;
  overflow-y: auto;
  margin-top: 20px;
  padding: 15px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.18);
}

.chat-empty {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  opacity: 0.45;
  font-size: 14px;
}

.chat-form {
  display: flex;
  gap: 10px;
  margin-top: 12px;
}

.chat-form input {
  flex: 1;
  min-width: 0;
}

.chat-form .button {
  flex-shrink: 0;
}

.chat-login-message {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: 20px;
  padding: 25px;
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.18);
}

.chat-login-message p {
  margin: 0;
}

.chat-login-message .button {
  margin-left: 5px;
}

@media (max-width: 600px) {
  .chat-messages {
    height: 280px;
  }

  .chat-form {
    gap: 8px;
  }

  .chat-form .button {
    padding-left: 14px;
    padding-right: 14px;
  }
}

.chat-message {
    padding: 10px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.chat-message:last-child {
    border-bottom: none;
}

.chat-message-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 4px;
}

.chat-message-header strong {
    font-size: 14px;
}

.chat-message-header span {
    font-size: 11px;
    opacity: 0.4;
}

.chat-message-text {
    font-size: 14px;
    line-height: 1.5;
    overflow-wrap: anywhere;
}
