/* -------------------------------------------------------- */
/* VARIABLES */
/* -------------------------------------------------------- */

:root {
  /* Background Colors */
  --background-color: #161013;
  --content-background-color: #161013;
  --sidebar-background-color: #161013;

  /* Text */
  --font: 'Typecast', sans-serif;
  --heading-font: 'Typecast', sans-serif;
  --font-size: 20px;
  --sidebar-text-color: #ffffff;
  --link-color: #ffffff;
  --link-color-hover: #ff0;

  /* Other Settings */
  --margin: 26px;
  --padding: 16px;
  --border: none;
  --round-borders: 0px;
}

.header-wrapper {
  grid-area: header;
  position: relative;
  width: 100%;
}

.pre-heading {
  position: absolute;
  top: -5px;           /* adjust distance above header */
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--heading-font);
  font-size: 1.2em;
  color: black;
  z-index: 1100;        /* above header */
  text-align: center;
}

/* HEADER */

header {
  grid-area: header;
  width: 100%;
  max-width: 1200px;
  height: auto;
  aspect-ratio: 1200 / 215;
  margin-top: 5px;
  position: relative;
  transform: rotate(0.5deg);
  background: black;
  border: 1px dashed white;
  box-shadow: 5px 5px black;
  color: black;
  padding: 15px 0;
}

@keyframes gentle-bounce {
  0%   { transform: translateY(0); }
  50%  { transform: translateY(-5px); }  /* move up 5px gently */
  100% { transform: translateY(0); }
}

.header-content {
  position: relative;
  margin: 0 auto;
  padding: 10px;
  top: 50%;                    
  z-index: 10;
  transform: translateY(-50%) rotate(-0.5deg);
}

.header-image-wrapper {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  pointer-events: none;  /* ensures clicks go to text/buttons above */
  z-index: 1;
  background-color: transparent;
  box-sizing: border-box;
}

header p {
  margin-top: 0;
  font-family: 'Typecast', sans-serif;
  font-size: 24px;  /* ~12pt */
  line-height: 1.5;
  transform: rotate(-0.5deg);
}

.header-image img {
  width: 100%;
  height: auto;
  object-fit: cover;
  display: block;
  margin: 0;
  margin-top: 13px;
}

/* -------------------------------------------------------- */
/* BASICS */
/* -------------------------------------------------------- */

body {
  margin: 0;
  margin-left: 2%;
  margin-top: 4%;
  background-color: transparent;
  padding: 0;
  overflow-x: hidden;
  font-family: 'Typecast', sans-serif;
  font-size: 20px;  /* ~12pt */
  line-height: 1.5;
  
  /*background*/
  
  background-image: url("https://noblestar.neocities.org/☆Images☆/redwall.png");
  background-repeat: repeat;        /* tile the GIF */
  background-size: auto;            /* keep original size */
  background-position: top left;
  background-attachment: scroll;    /* scroll with content */
}


::selection {
  background: rgba(0, 0, 0, 0.2);
}

mark {
  text-shadow: 1px 1px 4px var(--link-color);
  background-color: inherit;
  color: var(--link-color);
}

a,
a:visited {
  color: var(--link-color);
  text-decoration: underline;
}

a:hover,
a:focus {
  color: var(--link-color-hover);
  text-decoration: none;
}

/* -------------------------------------------------------- */
/* PAGE WRAPPER */
/* -------------------------------------------------------- */
.page-wrapper {
  max-width: 1200px;   /* keeps page from getting too wide */
  width: 85%;
  margin: 0 auto;      /* centers the whole page */
  padding-left: 0;     /* adjust if you want the page panned */
  padding-right: 0;
  box-sizing: border-box;
}

/* -------------------------------------------------------- */
/* LAYOUT */
/* -------------------------------------------------------- */

.layout {
  width: 100%;       
  margin: 0 auto;
  grid-template-areas:
    "header header"
    "content"
    "footer footer";
  grid-template-rows: auto 1fr auto;
  background: transparent;
  gap: 0
}

.main { 
  grid-area: main;
  min-height: 500px;
}

.content-container {
  width: 100%;
  margin:  5px 0 30px 0;
  grid-area: content;
  display: grid;
  gap: 25px;
  max-width: 1070px;
  min-height: 400px;
  margin-right: auto;
  grid-template-columns: 74% calc(26% - 25px);
  grid-template-areas: "main right-sidebar";
  background: transparent;
  justify-content: space-between;
}

.main-box {
  position: relative;
  width: 100%;
  max-width: 1202px;
  min-height: 800px;
  margin: 0;
  margin-top: 5%;
  margin-bottom: 5%;
  padding: 25px;
  background: black;
  color: #fff;
  border: 1px dashed white;
  box-shadow: 5px 5px #000;
  box-sizing: border-box;
}
.main-wrapper {
  width: 100%;
  max-width: 1200px;    /* match your main box max width */
  margin: 0;
  margin-top: 5%;
  display: flex;
  flex-direction: column; 
  justify-content: flex-start;
 gap: 1em;                   /* remove for now to avoid pushing */
}

.text-block {
  margin-top: 190px; /* pushes heading + paragraphs down together */
}

/* -------------------------------------------------------- */
/* SIDEBARS */
/* -------------------------------------------------------- */

aside {
  border: var(--border);
  border-radius: var(--round-borders);
  overflow: hidden;
  background-color: transparent;
  padding: var(--padding);
}

.right-sidebar {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: flex-start;
  width: 100%;
  grid-area: right-sidebar;
}

.right-sidebar .button-nav {
  display: flex;
  flex-direction: column;
  gap: 20%; /* space between buttons */
}

.sidebar-title {
  font-weight: bold;
  font-size: 1.2em;
  font-family: var(--heading-font);
}

.sidebar-section:not(:last-child) {
  margin-bottom: 3em;
}

.sidebar-section ul,
.sidebar-section ol {
  padding-left: 1.5em;
}

.sidebar-section > *:not(p):not(ul):not(ol):not(blockquote) {
  margin-top: 20px;
}

.sidebar-section blockquote {
  background: rgba(0, 0, 0, 0.1);
  padding: 15px;
  margin: 1em 0;
  border-radius: 10px;
  overflow: hidden;
}

.sidebar-section blockquote > *:first-child {
  margin-top: 0;
}

.sidebar-section blockquote > *:last-child {
  margin-bottom: 0;
}

/* -------------------------------------------------------- */
/* BUTTONS */
/* -------------------------------------------------------- */

.mini-box-button {
  width: 250px;
  height: auto;
  margin-bottom: 10%;
  margin-top: 10%;
  background-color: black;
  border: 1px dashed white;
  padding: 25px;
  font-size: 16px;
  cursor: pointer;
  box-shadow: 5px 5px black;
  transform: rotate(-0.5deg);
  transition: transform 0.2s ease, background-color 0.2s ease;
}

.mini-box-button:hover {
  transform: rotate(0.5deg) scale(1.05);
  background-color: white;
}

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

.site-button textarea {
  font-family: monospace;
  font-size: 0.7em;
}

.button-overlay {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  pointer-events: none;
}

/* -------------------------------------------------------- */
/* CONTENT */
/* -------------------------------------------------------- */

#content {
  grid-area: main;
}

main {
  line-height: 1.5;
}

main a,
main a:visited {
  color: var(--link-color);
}

main a:hover,
main a:focus {
  color: var(--link-color-hover);
  text-decoration-style: wavy;
}

main p,
main .image,
main .full-width-image,
main .two-columns {
  margin: 0.75em 0;
}

main ol,
main ul {
  margin: 0.5em 0;
  padding-left: 1.5em;
}

main ol li,
main ul li {
  margin-bottom: 0.2em;
  line-height: 1.3;
}

main ol {
  padding-left: 2em;
}

main blockquote {
  background: rgba(0, 0, 0, 0.1);
  padding: 15px;
  margin: 1em 0;
  border-radius: 10px;
}

main pre {
  margin: 1em 0 1.5em;
}

main code {
  text-transform: none;
}

main center {
  margin: 1em 0;
  padding: 0 1em;
}

main hr {
  border: 0;
  border-top: var(--border);
  margin: 1.5em 0;
}

/* HEADINGS */

main h1,
main h2,
main h3,
main h4,
main h5,
main h6 {
  font-family: var(--heading-font);
  margin-bottom: 0;
  line-height: 1.5;
}

main h1:first-child,
main h2:first-child,
main h3:first-child,
main h4:first-child,
main h5:first-child,
main h6:first-child {
  margin-top: 0;
}

main h1 { font-size: 1.5em; }
main h2 { font-size: 1.4em; }
main h3 { font-size: 1.3em; }
main h4 { font-size: 1.2em; }
main h5 { font-size: 1.1em; }
main h6 { font-size: 1em; }

/* COLUMNS */

.two-columns {
  display: flex;
}

.two-columns > * {
  flex: 1 1 0;
  margin: 0;
}

.two-columns > *:first-child { padding-right: 0.75em; }
.two-columns > *:last-child { padding-left: 0.75em; }

/* IMAGES */

.image { display: block; width: auto; height: auto; max-width: 100%; }
.full-width-image { display: block; width: 100%; height: auto; }

.images {
  display: flex;
  width: calc(100% + 10px);
  margin-left: -5px;
  margin-right: -5px;
}

.images img {
  width: 100%;
  height: auto;
  padding: 5px;
  margin: 0;
  overflow: hidden;
}

/* -----------------------------------------
   IMAGES AND GIFS
----------------------------------------- */

.carebear {
  width: 30%;               /* size */
  position: absolute;        /* allows free movement */
  right: -10%;               /* distance from right edge in px */
  top: 5%;                 /* distance from top edge in px */
  z-index: 2;                /* on top of header */
  animation: rock-bounce 3s ease-in-out infinite; /* rocking animation */
  transform-origin: bottom center; /* pivots from feet */
}

@keyframes rock-bounce {
  0%   { transform: rotate(-10deg) translateY(0); }
  25%  { transform: rotate(-5deg) translateY(-15px); }  /* moves up */
  50%  { transform: rotate(10deg) translateY(0); }
  75%  { transform: rotate(5deg) translateY(-15px); }   /* moves up */
  100% { transform: rotate(-10deg) translateY(0); }
}


.tv-wrapper {
  position: absolute; /* position wrapper anywhere */
  display: inline-block;
  top: -15%;                 /* adjust */
  left: -12%;
  overflow: hidden;
}

.pookie {
  position: absolute;
  top: 25%;     
  left: 15%;    
  width: 55%;    /* make it smaller than wrapper */
  height: 45%;   /* maintain proportions */
  object-fit: cover;  /* scales nicely inside wrapper */
  z-index: 1;
}

.tv {
  position: relative;
  top: 0;
  left: 0;
  width: 100%;
  height: auto;
  z-index: 2;          /* always on top */
  display: block;
  pointer-events: none; /* lets clicks pass through */
}

.hydrant {
  position: fixed;
  bottom: 100px;
  right: 130px;
  width: 150px;            
  height: auto;            
  z-index: 0;              
  pointer-events: none;    
}

/* Responsive tweaks */
@media (max-width: 768px) {
  .hydrant {
    width: 180px;
    top: 15%;
  }
}

@media (max-width: 480px) {
  .hydrant {
    width: 120px;
    top: 10%;
  }
}

.pin {
  width: 100px;              /* size of pin */
  position: absolute;       /* allows floating above header */
  left: 80px;                /* adjust distance from left edge */
  top: -30px;               /* adjust distance from top edge */
  z-index: 3;               /* higher than background, lower than text if needed */
  transform: rotate(-5deg); /* give it a playful tilt */
}


/* -------------------------------------------------------- */
/* MUSIC PLAYER */
/* -------------------------------------------------------- */

#music-player-container {
  position: fixed;
  bottom: 10px;
  left: 0;
  display: flex;
  align-items: center;
  transition: transform 0.3s ease-in-out;
  z-index: 9999;
}

.music-player {
  display: flex;
  align-items: center;
  gap: 15px;
  background-color: white;
  padding: 10px;
  border: 1px solid black;
}

.music-player button {
  background-color: black;
  color: white;
  border: 1px solid black;
  padding: 10px;
  font-size: 18px;
  cursor: pointer;
  display: flex;
  justify-content: center;
  align-items: center;
}

.music-player button:hover {
  background-color: gray;
  opacity: 0.8;
  color: white;
}

.music-player input[type="range"] {
  appearance: none;
  width: 150px;
  height: 8px;
  background: #ddd;
  outline: none;
  margin: 0;
}

.music-player input[type="range"]::-webkit-slider-thumb {
  appearance: none;
  width: 15px;
  height: 15px;
  background: black;
  cursor: pointer;
}

#volume-label {
  font-size: 14px;
  color: black;
}

#song-info {
  display: flex;
  flex-direction: column;
  margin-right: 15px;
  font-size: 14px;
  color: black;
  text-align: center;
}

#song-title { font-weight: bold; color: black; }
#song-artist { font-style: italic; color: black; }

#toggle-button {
  background-color: black;
  color: white;
  border: 1px solid black;
  padding: 10px;
  font-size: 18px;
  cursor: pointer;
  margin-left: 5px;
}

#toggle-button:hover {
  background-color: gray;
  color: white;
}

/* -------------------------------------------------------- */
/* CUSTOM FONTS */
/* -------------------------------------------------------- */

@font-face {
  font-family: 'Typecast';
  src: url('/☆Fonts☆/typecast-regular.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
}

@font-face {
  font-family: 'Typecast';
  src: url('/☆Fonts☆/typecast-bold.ttf') format('truetype');
  font-weight: bold;
}

@font-face {
  font-family: 'Typecast';
  src: url('/☆Fonts☆/typecast-italic.ttf') format('truetype');
  font-style: italic;
}

@font-face {
  font-family: 'Starborn';
  src: url('/☆Fonts☆/starborn-regular.ttf') format('truetype');
  font-style: normal;
}

@media (max-width: 768px) {
  .tv { width: 60vw; top: 12%; }
  .POOKIE { width: 50vw; top: 15%; }
}

@media (max-width: 480px) {
  .tv { width: 80vw; top: 10%; }
  .POOKIE { width: 70vw; top: 13%; }
}

@media (max-width: 900px) {
  .content-container {
    grid-template-columns: 1fr;           /* single column */
    grid-template-areas:
      "main"
      "right-sidebar";
    gap: 18px;
    max-width: 100%;
  }
}

/* -------------------------------------------------------- */
/* FOOTER */
/* -------------------------------------------------------- */

footer {
  grid-area: footer;
  overflow: hidden;
  padding: 1%;
  background: black;
  color: #fff;
  border: 1px dashed white;
  box-shadow: 5px 5px #000;
  z-index: 2;
  font-family: 'Typecast', sans-serif;
  font-size: 20px;  /* ~12pt */
  line-height: 1;
  
  display: flex;
  justify-content: center;
  align-items: center;

  height: 10%;            /* make footer 8% of viewport height */
  min-height: 40px;      /* optional: ensures it doesn’t get too small */
  max-height: 90px;     /* optional: ensures it doesn’t get too tall */
}

footer a,
footer a:visited { color: var(--link-color); }

footer a:hover,
footer a:focus { color: var(--link-color-hover); }