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

/* Variables - keeping the existing color scheme in mind */
:root {
  --main-bg-color: #36393f; /* Discord Dark Gray */
  --text-color: #dcddde; /* Discord Light Gray */
  --accent-color: #7289da; /* Discord Blurple */
}

body, html {
  height: 100%;
  font-family: Roboto, sans-serif; /* Modern system font stack */
  color: var(--text-color); /* Use variable */
  line-height: 1.6;
  /*background-image: url("https://raw.githubusercontent.com/Fetched-Fantasy/ffny/main/Copilot_20250903_093151.png");*/
  /*background-attachment: fixed;*/
  /*background-position: center;*/
  /*background-repeat: no-repeat;*/
  /*background-size: cover;*/
  /*filter: blur(5px);*/
  /*z-index: -1;*/
}

body {
  display: flex;
  flex-direction: column;
  min-height: 100vh; /* Ensure full height */
  background-color: #23272a !important; /* Discord Darker Gray */
}

/*ADDITION*/
body#interaction-page {
 background-color: #23272a;
 color: white;
 min-height: 100vh;
}

.container {
    max-width: 900px;
    margin: 2rem auto;
    background: var(--main-bg-color); /* Semi-transparent container */
    padding: 2rem;
    border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2); /* Softer shadow */
    position: relative; /* For search input positioning and top-right-buttons */
    bottom: 0px;
}

h1,
h2,
h3 {
  font-weight: 500; /* Standardize font weight */
  margin-bottom: 0.5em;
}

p {
  margin-bottom: 1em;
}

ul, ol {
  list-style: none;
  padding: 0;
}

a {
  color: var(--accent-color);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

/* Header */
.header {
 display: flex;
  flex-direction: column; /* Stack title and navigation */
  align-items: center; /* Center items horizontally */
  background-color: rgba(34, 34, 34, 0.8);
  padding: 0.5rem 2rem;
  text-align: center;
  position: relative;
  color: #ddd;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  backdrop-filter: blur(5px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: 2rem;
  position: relative;
}

.header h1 {
    flex-grow: 1; /* Prevent the title from taking up remaining space */
}

.sidebar-toggle {
    background: none;
 color: white;
 border: none;
    padding: 10px;
    font-size: 20px;
    cursor: pointer;
    position: absolute; /* Position the toggle button */
    top: 0.5rem; /* Distance from the top edge */
    left: 0.5rem; /* Distance from the left edge */
    transform: none; /* Remove vertical centering */
    z-index: 10; /* Ensure it's above other elements */
    color: #fff; /* Ensure the text color is white */
}

.sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: 250px;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    padding: 20px;
    overflow-y: auto;
    transition: transform 0.3s ease-in-out;
    transform: translateX(-100%); /* Initially hidden */
    z-index: 1000;
    color: #fff;
}

.sidebar.collapsed {
    transform: translateX(0%); /* Show the sidebar */
}

.header h1 {
    flex-grow: 1; /* Prevent the title from taking up remaining space */
    text-align: left; /* Align the title to the left */
    margin: 0; /* Remove default margin */
    font-size: 2rem;
    font-weight: 700;
    margin-left: 3rem; /* Add margin to the left of the title */
}
.parallax {
    position: relative;
    height: 100%;
    overflow: hidden;
    /*transition: margin-left 0.3s ease-in-out;*/
}

/* Navigation */
.nav-container {
  width: 100%; /* Make navigation full-width */
  justify-content: center; /* Center navigation items */
  margin-top: 1rem; /* Add some spacing between title and navigation */
    position: relative;
    margin: 0; /* Remove auto margins */
    display: flex;
    align-items: center;
}
 .nav {
    margin-top: 0; /* Remove top margin */
    display: flex;
    padding: 0;
    list-style: none;
    width: auto;;
  border-radius: 5px; /* Rounded corners */
  transition: background-color 0.2s ease-in-out;
}

.nav a:hover {
  background-color: rgba(255, 255, 255, 0.1); /* Hover effect */
  text-decoration: none;
}

.nav-arrow {
  display: none;
}

.nav-arrow.left {
  left: 0;
}

.nav-arrow.right {
  right: 0;
}

/* Parallax - I'm leaving this section largely untouched as it's a specific effect */
.parallax {
  position: relative;
  height: 100%;
  overflow: hidden;
    margin-left: 0; /* Make space for the sidebar */
    transition: margin-left 0.3s ease-in-out;
}

.parallax.contact-page {
  overflow: visible;
  min-height: auto;
}

.parallax::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  /* background-image: url("https://raw.githubusercontent.com/Fetched-Fantasy/ffny/main/Copilot_20250903_093151.png"); */
  /*background-attachment: fixed;*/
  /*background-position: center;*/
  /*background-repeat: no-repeat;*/
  /*background-size: cover;*/
  /*filter: blur(5px);*/
  z-index: -1;
}

/* About Me Section */
.about-me {
  padding: 3rem;
  background-color: rgba(0, 0, 0, 0.7);
  text-align: center;
  border-radius: 10px;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
  margin-bottom: 2rem;
}

.about-me hr {
        margin: 1rem 0;
    }

.about-me h3 {
  margin-top: 1rem;
  margin-bottom: 0.5rem;
}

.other-links {
 display: flex;
  flex-wrap: wrap;
  gap: 1rem;
 }

.other-link-box {
  display: block;
  padding: 0.5rem 1rem;
  background-color: rgba(0, 0, 0, 0.5);
  border-radius: 5px;
 color: white;
  text-decoration: none;
  transition: background-color 0.2s ease-in-out;
 }

.other-link-box:hover {
  background-color: rgba(0, 0, 0, 0.7);
 }

/* Buttons */
.button-container {
  margin-top: auto; /* Push to the bottom */
  display: flex;
  justify-content: center;
  margin-bottom: 2rem; /* Add some spacing at the bottom */
}

.discord-link,
.vrchat-link {
  display: inline-flex;
  align-items: center;
  padding: 0.4rem 0.6rem;
  margin: 0;
  color: var(--text-color);
  border-radius: 4px;
  gap: 0.5rem; /* Space between image and text */
  transition: background-color 0.2s ease-in-out;
  width: 140px;
  justify-content: center;
  text-align: center;
  font-size: 0.92rem;
}

.discord-link:hover {
  background-color: #677bc4; /* Slightly darker Discord color */
}

.vrchat-link:hover {
  background-color: #3b82f6; /* Slightly darker VRChat color */
}

.discord-link {
  background-color: #7289DA;
}

.vrchat-link {
  background-color: #4693FF;
}

.button-image {
  width: 24px; /* Adjust image size */
  height: 24px;
  vertical-align: middle; /* Align image with text */
}

/* Event Images */
.event-image {
  max-width: 100%; /* Make responsive */
  max-height: 300px; /* Adjust as needed */
  width: auto;
  height: auto;
  display: block;
  margin: 0 auto;
  border-radius: 8px;
  box-shadow: 0 0 8px rgba(0, 0, 0, 0.2);
}

/* Profile + Modal styles */
.profile-container { display: flex; flex-wrap: wrap; justify-content: center; gap: 2rem; margin: 3rem auto; }
.profile-square { cursor: pointer; width: 150px; padding: 1rem; background: #222; border-radius: 8px; transition: 0.3s; text-align: center; }
.profile-square:hover { background: #333; }
.profile-square img { width: 100%; border-radius: 8px; }
.profile-square p { margin: 0.5rem 0 0; }

.modal { display: none; position: fixed; z-index: 1000; left: 0; top: 0; width: 100%; height: 100%; background-color: rgba(0,0,0,0.8); }
.modal-content { background: #1a1a1a; margin: 10% auto; padding: 20px; border-radius: 10px; width: 80%; max-width: 600px; display: flex; gap: 1rem; }
.modal-left img { width: 120px; border-radius: 8px; }
.modal-left { flex: 1; }
.modal-right { flex: 2; text-align: left; }
.close { color: #fff; float: right; font-size: 28px; font-weight: bold; cursor: pointer; }
.close:hover { color: #f00; }
/* Toggle Button */
#toggleProfiles {
  background: linear-gradient(90deg, #0ff, #f0f); /* neon gradient */
  color: #111; /* dark text for contrast */
  border: none;
  padding: 10px 20px;
  margin: 1rem auto;
  display: block;
  font-size: 1rem;
  font-weight: bold;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.3s ease;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

#toggleProfiles:hover {
  background: linear-gradient(90deg, #f0f, #0ff);
  color: white;
  box-shadow: 0 0 10px #0ff, 0 0 20px #f0f;
}

/* Collapsible Profiles Wrapper */
#profilesWrapper {
  overflow: hidden;
  max-height: 0;
  transition: max-height 0.6s ease;
  background: rgba(0, 0, 0, 0.6); /* dark translucent background */
  border-radius: 10px;
  padding: 0 1rem; /* padding only visible when expanded */
  margin: 1rem auto;
  width: 85%;
}

#profilesWrapper.open {
  max-height: 2000px; /* large enough to fit all profiles */
  padding: 1rem; /* add padding when open */
  box-shadow: 0 0 15px #0ff, 0 0 25px #f0f;
}

/* Forms */
.form-container {
  max-width: 700px;
  margin: 2rem auto;
  padding: 1rem;
  background-color: rgba(0, 0, 0, 0.6);
  border-radius: 10px;
  box-shadow: 0 0 15px #0ff, 0 0 25px #f0f;
}

.contact-intro {
  max-width: 700px;
  margin: 2rem auto 1rem;
  padding: 1rem;
  text-align: center;
  background-color: rgba(0, 0, 0, 0.6);
  border-radius: 10px;
  box-shadow: 0 0 15px #0ff, 0 0 25px #f0f;
}

.contact-intro h2 {
  font-size: 1.8rem;
  color: #0ff;
  margin-bottom: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.contact-intro p {
  font-size: 1rem;
  color: #ddd;
  line-height: 1.5;
}

.loading-message {
  text-align: center;
  font-family: sans-serif;
  margin-top: 20px;
  color: #888;
}

/* Event Buttons */
.event-button {
  display: inline-block;
  padding: 10px 20px;
  background-color: #4CAF50; /* Green */
  color: white;
  text-decoration: none;
  border-radius: 5px;
  margin-top: 10px;
  transition: background-color 0.2s ease-in-out;
}

.event-button:hover {
  background-color: #3e8e41; /* Darker green */
}

.vip-section {
    margin-bottom: 2rem;
    padding: 1rem;
    border: 1px solid rgba(102, 179, 255, 0.3);
    border-radius: 8px;
    background-color: rgba(0, 21, 42, 0.3);
}

.vip-section h2 {
    color: #66b3ff;
    margin-top: 0;
}

.vip-box {
    padding: 1rem;
    background-color: rgba(0, 34, 68, 0.5);
    border: 1px solid rgba(102, 179, 255, 0.5);
    border-radius: 8px;
    color: #fff;
}

 .nav-active {
 transform: translateX(0%);
 }

/* Adjustments for smaller screens (Hamburger menu) */
@media (max-width: 768px) {
    .header {
        flex-direction: column; /* Stack title and hamburger */
        align-items: center; /* Center items */
    }

    .nav-container {
        position: fixed;
        top: 0;
        left: 0;
        height: 100%;
        width: 250px;
        background-color: rgba(0, 21, 42, 0.9);
        transform: translateX(-100%);
        transition: transform 0.3s ease-in-out;
        padding-top: 60px;
        z-index: 1000;
    }

    .nav {
        flex-direction: column;
        align-items: flex-start;
        padding-left: 20px;
    }

    .nav li {
        margin: 1rem 0;
    }
}

/* Form Styles */
.form {
 display: flex;
 flex-direction: column;
 width: 50%;
 color: black;
 }
 #webhook-url, #webhook-message, #webhook-title, #webhook-image-url, #webhook-author {
 width: 100%;
 padding: 8px;
 margin-bottom: 10px;
 border: 1px solid #ccc;
 border-radius: 4px;
 box-sizing: border-box; /* Ensures padding is included in the width */
 color: black; /* Ensures text is visible */
 }

 #webhook-button {
 background-color: #4CAF50;
 color: white;
 padding: 10px 15px;
 border: none;
 border-radius: 4px;
 cursor: pointer;
 }
 #webhook-button:hover {
 background-color: #45a049;
 }

#message-id {
 width: 100%; /* Make it the same width as other inputs */
 padding: 8px;
 margin-bottom: 10px;
 border: 1px solid #ccc;
 border-radius: 4px;
 box-sizing: border-box;
 color: black;
}

/* Footer Styles */
footer {
  background-color: rgba(34, 34, 34, 0.7);
  color: #ddd;
  padding: 1rem;
  text-align: center;
  margin-top: 2rem; /* Push footer to the bottom */
}

/* Adjust main content area */
.parallax {
    margin-left: 0; /* Make space for the sidebar */
    transition: margin-left 0.3s ease-in-out;
}

.top-right-buttons {
  position: fixed;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 1rem;
  justify-content: center;
  z-index: 1000;
}

.toast-notification {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background-color: #ff3333;
    color: white;
    padding: 16px 24px;
    border-radius: 4px;
    display: none;
    z-index: 1000;
    animation: slideIn 0.5s ease-in-out;
}

.toast-notification.show {
    display: block;
}

@keyframes slideIn {
    from {
        transform: translateY(100%);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Login overlay styles */
.login-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 3000;
}

.login-modal {
    background: rgba(20,20,20,0.95);
    padding: 2rem;
    border-radius: 8px;
    width: 320px;
    text-align: center;
    color: #fff;
    box-shadow: 0 8px 20px rgba(0,0,0,0.6);
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-top: 1rem;
}

#usernameInput {
    padding: 0.5rem;
    border-radius: 4px;
    border: 1px solid rgba(255,255,255,0.2);
    background: rgba(255,255,255,0.1);
    color: #fff;
    font-size: 1rem;
}

#usernameInput:focus {
    outline: none;
    border-color: var(--accent-color);
}

.login-error {
    color: #ff4444;
    font-size: 0.9rem;
    margin: 0;
    min-height: 1.2em;
}

/* Game container and canvas sizing */
.game-container {
  max-width: 1100px;
  margin: 1.5rem auto;
  background: rgba(0,0,0,0.45);
  padding: 0.5rem;
  border-radius: 8px;
  position: relative;
}

.game-canvas {
  width: 100%;
  height: calc(75vh); /* slightly smaller than full viewport */
  display: block;
  border-radius: 6px;
  background: #000;
}

.game-header {
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 50;
}

.game-badge {
  background: rgba(255,255,255,0.08);
  color: #fff;
  padding: 6px 10px;
  border-radius: 4px;
  font-size: 0.85rem;
  border: 1px solid rgba(255,255,255,0.06);
}

/* Pause overlay styles */
.pause-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.6);
  display: none; /* toggled via JS */
  align-items: center;
  justify-content: center;
  z-index: 2000;
}

.pause-menu {
  background: rgba(20,20,20,0.95);
  padding: 1.5rem;
  border-radius: 8px;
  width: 320px;
  text-align: center;
  color: #fff;
  box-shadow: 0 8px 20px rgba(0,0,0,0.6);
}

.pause-actions { 
    display: flex; 
    flex-direction: column;
    gap: 0.5rem; 
    margin: 1rem 0; 
}
.pause-footer { margin-top: 0.5rem; text-align: right; }

.pause-footer .btn { text-decoration: none; }

/* Click-to-lock hint */
.lock-hint {
  position: absolute;
  left: 50%;
  bottom: 12px;
  transform: translateX(-50%);
  background: rgba(0,0,0,0.6);
  color: #fff;
  padding: 6px 10px;
  border-radius: 6px;
  font-size: 0.85rem;
  z-index: 60;
  pointer-events: none; /* allows clicks to pass through to canvas */
}

/* Settings panel inside pause menu */
.settings-panel { margin-top: 0.75rem; text-align: left; }
.settings-panel h3 { margin-top: 0; margin-bottom: 0.5rem; }
.setting-row { margin-bottom: 0.75rem; }
.setting-row label { display: block; font-size: 0.9rem; margin-bottom: 0.25rem; }
.settings-actions { display: flex; gap: 0.5rem; justify-content: flex-end; }

/* World selection styles */
.mode-select {
    margin: 1rem 0;
    display: flex;
    justify-content: center;
    gap: 2rem;
}

.mode-select label {
    color: #fff;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.mode-select input[type="radio"] {
    cursor: pointer;
}

.world-select {
    margin: 1rem 0;
}

.world-select label {
    display: block;
    margin-bottom: 0.5rem;
    color: #fff;
}

#worldSelect, #inGameWorldSelect {
    width: 100%;
    padding: 0.5rem;
    border-radius: 4px;
    border: 1px solid rgba(255,255,255,0.2);
    background: rgba(255,255,255,0.1);
    color: #fff;
    font-size: 1rem;
    margin-bottom: 1rem;
}

#worldSelect:focus, #inGameWorldSelect:focus {
    outline: none;
    border-color: var(--accent-color);
}

.world-menu-content {
    display: flex;
    flex-direction: column;
    gap: 16px;
    width: 100%;
    max-width: 300px;
}

  .world-browser {
    background: rgba(20,20,20,0.95);
    border-radius: 12px;
    width: 90%;
    max-width: 1200px;
    height: 90vh;
    max-height: 800px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: 0 8px 32px rgba(0,0,0,0.3);
  }

  .world-browser-header {
    padding: 1.5rem;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
  }

  .world-search {
    width: 300px;
  }

  .world-search input {
    width: 100%;
    padding: 8px 16px;
    border-radius: 20px;
    border: 1px solid rgba(255,255,255,0.2);
    background: rgba(255,255,255,0.1);
    color: white;
    font-size: 14px;
  }

  .world-search input:focus {
    outline: none;
    border-color: var(--accent-color);
    background: rgba(255,255,255,0.15);
  }

  .world-browser-content {
    flex: 1;
    overflow-y: auto;
    padding: 1.5rem;
  }

  .world-section {
    margin-bottom: 2rem;
  }

  .world-section h3 {
    margin-bottom: 1rem;
    color: #fff;
    font-size: 1.2rem;
  }

  .world-categories {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin-bottom: 1.5rem;
  }

  .category-btn {
    padding: 8px 16px;
    border-radius: 20px;
    border: 1px solid rgba(255,255,255,0.2);
    background: rgba(255,255,255,0.1);
    color: white;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s;
  }

  .category-btn:hover {
    background: rgba(255,255,255,0.2);
  }

  .category-btn.active {
    background: var(--accent-color);
    border-color: var(--accent-color);
  }

  .world-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1rem;
    margin-top: 1rem;
  }

  .world-card {
    background: rgba(255,255,255,0.1);
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.2s;
    cursor: pointer;
  }

  .world-card:hover {
    transform: translateY(-4px);
  }

  .world-card-image {
    width: 100%;
    height: 120px;
    background-color: #2a2a2a;
    background-size: cover;
    background-position: center;
  }

  .world-card-content {
    padding: 1rem;
  }

  .world-card-title {
    font-size: 1rem;
    margin: 0;
    color: white;
  }

  .world-card-author {
    font-size: 0.8rem;
    color: rgba(255,255,255,0.6);
    margin-top: 0.25rem;
  }

  .world-grid-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
  }

  .world-sort select {
    padding: 6px 12px;
    border-radius: 4px;
    border: 1px solid rgba(255,255,255,0.2);
    background: rgba(255,255,255,0.1);
    color: white;
    font-size: 14px;
  }

  .world-sort select:focus {
    outline: none;
    border-color: var(--accent-color);
  }

  .world-browser-footer {
    padding: 1rem 1.5rem;
    border-top: 1px solid rgba(255,255,255,0.1);
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
  }

  /* Custom scrollbar for world browser */
  .world-browser-content::-webkit-scrollbar {
    width: 8px;
  }

  .world-browser-content::-webkit-scrollbar-track {
    background: rgba(255,255,255,0.1);
  }

  .world-browser-content::-webkit-scrollbar-thumb {
    background: rgba(255,255,255,0.3);
    border-radius: 4px;
  }

  .world-browser-content::-webkit-scrollbar-thumb:hover {
    background: rgba(255,255,255,0.4);
  }

.world-menu-actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.btn {
    padding: 8px 16px;
    border-radius: 4px;
    border: none;
    cursor: pointer;
    font-size: 14px;
    transition: background-color 0.2s;
}

.btn-primary {
    background-color: var(--accent-color);
    color: white;
}

.btn-primary:hover {
    background-color: #5b6eae;
}

.btn-secondary {
    background-color: #4a4d52;
    color: white;
}

.btn-secondary:hover {
    background-color: #3d4044;
}

.btn-danger {
    background-color: #dc3545;
    color: white;
}

.btn-danger:hover {
    background-color: #bb2d3b;
}

.world-actions {
    margin-top: 1rem;
    display: flex;
    justify-content: center;
    gap: 1rem;
}

.world-actions .btn {
    text-decoration: none;
}
