html, body {
  height: 100%;
  margin: 0;
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;

  font-family: 'Press Start 2P', sans-serif; /* 👈 новый шрифт */
  color: white;
  text-shadow: 0 0 5px rgba(255,255,255,0.2);

  font-size: 17px; /* 👈 больше текст */

  background: url("ofcminecraft.png") center/cover no-repeat fixed;
}

#logoutBtn {
    display: none;
    width: 100%;
    margin-top: 10px;
    background: #ff5555;
    color: white;
}

/* затемнение */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.65);
  z-index: -1;
}

/* HEADER */
.header {
  display: flex;
  justify-content: space-between;
  align-items: center;

  padding: 15px 25px;
  background: rgba(20,20,40,0.6);
  backdrop-filter: blur(10px);

  position: sticky;
  top: 0;
  z-index: 1000;
}

.menu a {
  margin-left: 15px;
  cursor: pointer;
  color: white;
  text-decoration: none;
}

.menu a:hover {
  color: #41FB04;
}

/* CONTENT */
.content {
  flex: 1;
}

/* PAGES */
.page {
  display: none;
  padding: 40px 20px;
}

.active {
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* HERO */
.hero {
  display: flex;
  justify-content: center;
  margin-top: 20px;
}

.hero-card {
  text-align: center;
}

.ip {
  opacity: 0.8;
}

.desc {
  margin-top: 10px;
}

/* BUTTONS */
.btn-row {
  margin-top: 15px;
  display: flex;
  gap: 10px;
  justify-content: center;
}

.play-btn, .copy-btn {
  padding: 10px 18px;
  border-radius: 10px;
  border: none;
  cursor: pointer;
}

.play-btn {
  background: #38bdf8;
  color: black;
}

.copy-btn {
  background: rgba(255,255,255,0.1);
  color: white;
}

/* GRID */
.grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 15px;

  width: 85%;
  max-width: 1000px;
  margin: 30px auto;
}

/* CARD */
.card {
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.1);
  backdrop-filter: blur(2px);

  padding: 20px;
  border-radius: 15px;
}

/* RULES */
.rules-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
}

.rule-section {
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.1);
  backdrop-filter: blur(10px);

  padding: 20px;
  border-radius: 15px;

  width: 85%;
  max-width: 900px;
}

.rule-title {
  color: #41FB04;
  margin-bottom: 10px;
}

.rule {
  margin-bottom: 5px;
}

.rule-code {
  font-size: 12px;
  opacity: 0.7;
  margin-bottom: 10px;
}

/* FOOTER */
.footer {
  margin-top: auto;
  text-align: center;
  padding: 25px;
  background: rgba(0,0,0,0.5);
}

/* MOBILE */
@media (max-width: 768px) {
  .grid {
    grid-template-columns: 1fr;
  }

  .btn-row {
    flex-direction: column;
  }

  .header {
    flex-direction: column;
    gap: 10px;
  }
}
.logo img {
  height: 45px;
  width: auto;
  display: block;
}

/* Адаптив */
@media (max-width: 768px) {
  .logo img {
    height: 35px;
  }
}

@media (max-width: 480px) {
  .logo img {
    height: 28px;
  }
}

/* ===== ADMIN PANEL (КРАСИВО) ===== */

.admin-panel {
  position: fixed;
  inset: 0;
  background: radial-gradient(circle at center, rgba(0,0,0,0.7), rgba(0,0,0,0.95));
  display: none;
  justify-content: center;
  align-items: center;
  z-index: 999;

  animation: fadeInAdmin 0.3s ease;
}

@keyframes fadeInAdmin {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* BOX */
.admin-box {
  background: rgba(20,20,40,0.85);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255,255,255,0.08);

  padding: 30px;
  border-radius: 20px;
  width: 280px;

  text-align: center;
  box-shadow: 0 0 30px rgba(56,189,248,0.2);

  animation: popUp 0.3s ease;
}

@keyframes popUp {
  from { transform: scale(0.8); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

.admin-box h2 {
  margin-bottom: 15px;
}

/* INPUTS */
.admin-box input {
  width: 100%;
  padding: 12px;
  margin: 10px 0;

  border-radius: 10px;
  border: none;
  outline: none;

  background: rgba(255,255,255,0.07);
  color: white;

  transition: 0.2s;
}

.admin-box input:focus {
  background: rgba(255,255,255,0.12);
  box-shadow: 0 0 10px rgba(56,189,248,0.4);
}

/* BUTTON */
.admin-box button {
  width: 100%;
  padding: 12px;
  margin-top: 10px;

  border-radius: 12px;
  border: none;

  background: linear-gradient(135deg, #38bdf8, #0ea5e9);
  color: black;
  font-weight: bold;

  cursor: pointer;
  transition: 0.25s;
}

.admin-box button:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 15px #38bdf8;
}

.admin-box button:active {
  transform: scale(0.97);
}
.admin-close {
  position: absolute;
  top: 10px;
  right: 15px;

  font-size: 20px;
  cursor: pointer;

  color: rgba(255,255,255,0.6);
  transition: 0.2s;
}

.admin-close:hover {
  color: #ff4d4d;
  transform: scale(1.2);
}

/* ===== MAP STYLE ===== */

.map-card {
  text-align: center;
  width: 85%;
  max-width: 800px;
}

.map-card h2 {
  margin-bottom: 10px;
}

.map-btn {
  display: inline-block;
  margin-top: 15px;
  padding: 12px 20px;

  background: linear-gradient(135deg, #38bdf8, #0ea5e9);
  color: black;
  font-weight: bold;
  text-decoration: none;

  border-radius: 12px;
  transition: 0.25s;
}

.map-btn:hover {
  transform: scale(1.08);
  box-shadow: 0 0 25px rgba(56,189,248,0.6);
}

.console-card {
  width: 85%;
  max-width: 900px;
  margin: auto;

  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.1);

  backdrop-filter: blur(10px);
  border-radius: 15px;

  padding: 20px;

  text-align: center;
}

#consoleOutput {
  height: 250px;
  overflow-y: auto;

  background: rgba(0,0,0,0.4);
  padding: 10px;

  border-radius: 10px;
  margin-bottom: 10px;

  font-size: 13px;
  text-align: left;
  color: #38bdf8;
}

#consoleInput {
  width: 100%;
  padding: 10px;

  margin-top: 10px;

  border-radius: 10px;
  border: none;

  background: rgba(255,255,255,0.07);
  color: white;

  outline: none;
}

#consoleInput:focus {
  background: rgba(255,255,255,0.12);
  box-shadow: 0 0 10px rgba(56,189,248,0.4);
}

.console-card button {
  margin-top: 10px;
  padding: 10px;
  width: 100%;

  border: none;
  border-radius: 12px;

  background: linear-gradient(135deg, #38bdf8, #0ea5e9);
  color: black;

  font-weight: bold;
  cursor: pointer;

  transition: 0.25s;
}

.console-card button:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 15px rgba(56,189,248,0.6);
}

.console-card button:active {
  transform: scale(0.97);
}

/* ===== TOAST (вместо alert) ===== */
.toast {
  position: fixed;
  top: 20px;
  right: 20px;

  background: rgba(20,40,20,0.9);
  color: #4ade80;

  padding: 12px 18px;
  border-radius: 10px;

  opacity: 0;
  transform: translateY(-20px);

  transition: 0.3s;
  z-index: 9999;
  
  pointer-events: none;
}

.toast.show {
  opacity: 1;
  transform: translateY(0);
}

/* ===== SHAKE (ошибка) ===== */
.shake {
  animation: shake 0.3s;
}

@keyframes shake {
  0% { transform: translateX(0); }
  25% { transform: translateX(-5px); }
  50% { transform: translateX(5px); }
  75% { transform: translateX(-5px); }
  100% { transform: translateX(0); }
}

/* ===== УЛУЧШЕННЫЙ ADMIN BOX ===== */
.admin-box {
  position: relative;
  width: 300px;

  background: rgba(20,20,40,0.85);
  backdrop-filter: blur(25px);

  border-radius: 20px;
  padding: 30px;

  box-shadow:
    0 0 30px rgba(56,189,248,0.3),
    inset 0 0 10px rgba(255,255,255,0.05);

  text-align: center;
}

/* INPUT glow */
.admin-box input:focus {
  box-shadow: 0 0 12px #38bdf8;
}

/* BUTTON glow сильнее */
.admin-box button:hover {
  box-shadow: 0 0 25px #38bdf8;
}

/* КРЕСТИК */
.admin-close {
  position: absolute;
  top: 10px;
  right: 15px;
  font-size: 20px;
  cursor: pointer;
  opacity: 0.6;
}

.admin-close:hover {
  color: red;
  opacity: 1;
  transform: scale(1.2);
}

.particle {
  position: absolute;
  width: 5px;
  height: 5px;

  background: #41FB04;
  border-radius: 50%;

  opacity: 0.8;

  animation: floatUp linear forwards;
}

@keyframes floatUp {
  from {
    transform: translateY(50px);
    opacity: 1;
  }
  to {
    transform: translateY(-200px);
    opacity: 0;
  }
}
/* GLOW при удержании */
.logo.holding img {
  filter: drop-shadow(0 0 10px #41FB04)
          drop-shadow(0 0 20px #41Fb04)
          drop-shadow(0 0 35px #41FB04);

  transform: scale(1.05);
  transition: 0.2s;
}

/* пульсация */
.logo.holding {
  animation: glowPulse 1s infinite;
}

@keyframes glowPulse {
  0% { filter: brightness(1); }
  50% { filter: brightness(1.3); }
  100% { filter: brightness(1); }
}

h1 {
  font-size: 42px;
}

h2 {
  font-size: 26px;
}

p {
  font-size: 17px;
}

@media (min-width: 1024px) {
  body {
    font-size: 19px;
  }

  h1 {
    font-size: 52px;
  }

  h2 {
    font-size: 30px;
  }
}

.status {
  margin-top: 20px;
  font-size: 14px;
  opacity: 0.8;
}

.btn-row {
  margin-top: 20px;
}

button {
  font-family: 'Press Start 2P', sans-serif;
}

.hero-card img {
  width: 400px;
  margin-bottom: 15px;
  margin-bottom: 20px;
}

/* iPad */
@media (max-width: 1024px) {
  .hero-card img {
    width: 90px;
  }
}

/* телефон */
@media (max-width: 480px) {
  .hero-card img {
    width: 70px;
  }
}

.burger {
  display: none;
  font-size: 26px;
  cursor: pointer;
}

/* MOBILE */
@media (max-width: 768px) {

  .burger {
    display: block;
  }

  .menu {
    position: absolute;
    top: 70px;
    left: 0;
    width: 100%;

    background: rgba(20,20,40,0.95);
    flex-direction: column;

    display: none;
    text-align: center;
    padding: 20px 0;
  }

  .menu a {
    display: block;
    margin: 10px 0;
  }

  .menu.active {
    display: flex;
  }
}

@media (max-width: 1024px) {

  body {
    font-size: 15px;
  }

  h1 {
    font-size: 36px;
  }

  h2 {
    font-size: 22px;
  }

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

  .btn-row {
    flex-direction: column;
  }
}

.play-btn, .copy-btn {
  transition: 0.25s;
}

.play-btn:hover {
  transform: scale(1.1);
  box-shadow: 0 0 20px #41FB04;
}

.copy-btn:hover {
  background: rgba(255,255,255,0.2);
  transform: scale(1.05);
}

.page {
  opacity: 0;
  transform: translateY(20px);
  pointer-events: none;
  transition: 0.4s ease;
}

.page.active {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.card {
  transition: transform 0.2s ease, box-shadow 0.2s;
}

.card:hover {
  box-shadow: 0 20px 40px rgba(0,0,0,0.5);
}

.play-btn {
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(56,189,248,0.6); }
  70% { box-shadow: 0 0 0 15px rgba(56,189,248,0); }
  100% { box-shadow: 0 0 0 0 rgba(56,189,248,0); }
}

button {
  position: relative;
  overflow: hidden;
}

.ripple {
  position: absolute;
  width: 100px;
  height: 100px;
  background: rgba(255,255,255,0.4);
  border-radius: 50%;
  transform: translate(-50%, -50%) scale(0);
  animation: ripple 0.6s linear;
}

@keyframes ripple {
  to {
    transform: translate(-50%, -50%) scale(4);
    opacity: 0;
  }
}

.card {
  opacity: 0;
  transform: translateY(30px);
  animation: fadeUp 0.6s forwards;
}

.card:nth-child(1) { animation-delay: 0.1s; }
.card:nth-child(2) { animation-delay: 0.2s; }
.card:nth-child(3) { animation-delay: 0.3s; }
.card:nth-child(4) { animation-delay: 0.4s; }

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

.active-link {
  color: #41FB04;
  text-shadow: 0 0 10px #41FB04;
}

.card::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 15px;
  background: linear-gradient(120deg, transparent, rgba(255,255,255,0.1), transparent);
  opacity: 0;
  transition: 0.3s;
}

.card:hover::before {
  opacity: 1;
}

#bgParticles {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -2;
}

.play-btn {
  background: linear-gradient(180deg, #41FB04, #41FB04);
  box-shadow: 0 5px 0 #0369a1, 0 0 15px #41FB04;
}

.play-btn:active {
  transform: translateY(4px);
  box-shadow: 0 1px 0 #0369a1;
}

.menu a {
  position: relative;
  padding: 5px 10px;
}

.menu a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -3px;
  width: 0%;
  height: 2px;
  background: #41FB04;
  transition: 0.3s;
}

.menu a:hover::after {
  width: 100%;
}

.card:hover {
  box-shadow:
    0 0 10px #41FB04,
    0 0 25px rgba(56,189,248,0.5),
    0 20px 40px rgba(0,0,0,0.6);
}


.rules-container {
  padding: 25px 10px;
}

.rule-section {
  padding: 25px;
  margin-bottom: 25px;

  line-height: 1.6;

  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.08);
  backdrop-filter: blur(10px);

  border-radius: 18px;
}

/* каждая строка правила — как блок */
.rule {
  padding: 10px 12px;
  margin: 8px 0;

  background: rgba(0,0,0,0.25);
  border-radius: 10px;

  font-size: 13px;
  line-height: 1.5;

  transition: 0.2s;
}

.rule:hover {
  background: rgba(65,251,4,0.08);
  transform: translateX(3px);
}

.rule-code {
  margin-left: 10px;
  margin-bottom: 12px;
  opacity: 0.6;
  font-size: 11px;
}

@media (max-width: 1024px) {
  .rule-section {
    width: 95%;
    padding: 18px;
  }

  .rule {
    font-size: 12px;
  }
}

@media (max-width: 768px) {
  .rules-container {
    gap: 15px;
  }

  .rule-section {
    width: 98%;
    padding: 15px;
  }

  .rule {
    font-size: 11px;
  }

  .rule-code {
    font-size: 10px;
  }
}

@media (max-width: 480px) {
  .rule {
    font-size: 10px;
    padding: 8px;
  }
}

/* ПОИСК */
.rules-search {
  width: 100%;
  max-width: 900px;
  padding: 12px;
  margin-bottom: 10px;

  border-radius: 10px;
  border: none;
  outline: none;

  background: rgba(0,0,0,0.4);
  color: white;

  font-size: 14px;
}

/* автоподсказки */
.suggestions {
  width: 100%;
  max-width: 900px;
  margin: 5px auto 10px auto;
}

.suggestion-item {
  background: rgba(0,0,0,0.55);
  padding: 10px;
  margin-top: 6px;

  border-radius: 10px;
  cursor: pointer;

  font-size: 12px;

  transition: 0.2s;
}

.suggestion-item:hover {
  background: rgba(65,251,4,0.2);
  transform: translateX(3px);
}

/* НЕТ РЕЗУЛЬТАТОВ */
.no-results {
  display: none;
  text-align: center;

  padding: 12px;
  margin-top: 10px;

  background: rgba(0,0,0,0.4);
  border-radius: 10px;

  color: #ff5555;
}

/* ПОДСВЕТКА */
.highlight {
  background: rgba(65,251,4,0.3);
  padding: 2px 4px;
  border-radius: 5px;
}

.rule {
  transition: 0.25s ease;
  transform: translateY(0);
  position: relative;
  border-radius: 12px;
}

/* Hypixel-style hover */
.rule:hover {
  transform: translateY(-4px) scale(1.01);
  background: rgba(65,251,4,0.08);
  box-shadow:
    0 10px 25px rgba(0,0,0,0.4),
    0 0 15px rgba(65,251,4,0.2);
}

/* плавное появление текста */
.rule-text {
  font-size: 13px;
  margin-bottom: 4px;
}

.rule-punishment {
  font-size: 11px;
  opacity: 0.7;
  margin-left: 10px;
}

iframe {
  pointer-events: auto !important;
  position: relative;
  z-index: 10;
}

.add-rule {
  display: flex;
  flex-direction: column;
  gap: 10px;

  width: 100%;
  max-width: 700px;

  margin-bottom: 20px;
}

.add-rule select {
  padding: 12px;
  border-radius: 10px;
  border: none;

  background: rgba(0,0,0,0.4);
  color: white;

  font-family: 'Press Start 2P', sans-serif;
}

.rule button {
  margin-top: 10px;
}

textarea {
  width: 100%;
  min-height: 90px;

  padding: 12px;
  margin-top: 10px;

  border: none;
  border-radius: 12px;

  resize: vertical;

  background: rgba(255,255,255,0.07);
  color: white;

  font-family: 'Press Start 2P', sans-serif;
  font-size: 11px;

  outline: none;

  transition: 0.2s;
}

textarea:focus {
  background: rgba(255,255,255,0.12);
  box-shadow: 0 0 12px #38bdf8;
}