/* ==== VARIABLES ==== */
:root {
  --gap: 10px;

  /* overall frame size */
  --container-width: 960px;
  --container-height: 960px;

  /* box border */
  --border: 2px solid #65ff51;
  --border-width: 2px;
  --border-style: solid;

  /* widths */
  --w-small: 45%;
  --w-med:   29.3%;
  --w-large: 70%;

  /* heights (percent of container) */
  --h-header:     20.83%;
  --h-subheader:   3.13%;
  --h-row3:       26.04%;
  --h-row4:       27.7%;
  --h-row2:       21.83%;
}

.crt::before {
    content: "";
    display: block;
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: 
        linear-gradient(rgba(18, 16, 16, 0) 50%, rgba(0, 0, 0, 0.25) 50%),
        linear-gradient(90deg, rgba(255, 0, 0, 0.06), rgba(0, 255, 0, 0.02), rgba(0, 0, 255, 0.06));
    background-size: 100% 2px, 3px 100%;
    z-index: 9999;
    pointer-events: none;
}

.crt::after {
    content: "";
    display: block;
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(18, 16, 16, 0.1);
    opacity: 0;
    z-index: 9999;
    pointer-events: none;
    animation: flicker 0.15s infinite;
}

/* ==== RESET ==== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* ==== PAGE + LAYOUT ==== */
body {
  display: flex;
  justify-content: center;
  padding: 20px;
  background: #fafafa;
}

.layout {
  width:  var(--container-width);
  height: var(--container-height);
  display: flex;
  flex-direction: column;
  gap: var(--gap);
  position: relative;
}


/* ==== BOX BASE ==== */
.box {
  border-width: var(--border-width);
  border-style: var(--border-style);
  border: none;
  box-shadow:
    0 0 0 1.5px rgb(255, 255, 255),
    0 0 0 3px rgb(255, 0, 0);
  background: white;
}

/* ==== HEADER BARS ==== */
.header    { height: var(--h-header);    }
.subheader { height: var(--h-subheader); }

/* ==== ROWS + HEIGHTS ==== */
.row {
  display: flex;
  gap: var(--gap);
}
.row-3 { 
  height: 800px;
  justify-content: center; 
}

.row-4 { 
  height: var(--h-row4); 
  justify-content: center;
}
.row-2 {
  height: var(--h-row2);
  display: flex;
  gap: var(--gap);
  justify-content: center;
}

/* ==== CHILD BOXES FILL THEIR ROW ==== */
.row .small  { flex: 0 0 var(--w-small);  height: 100%; }
.row .medium { flex: 0 0 var(--w-med);    height: 100%; }
.row .large  { flex: 0 0 var(--w-large);  height: 100%; }
.row-2 .bottom {
  flex: 0 0 var(--w-med);
  height: 100%;
}

/* ==== NAV BAR & SECTION HEADER STYLE ==== */
.nav-header {
  padding:8px;
  text-align: center;
  font-weight: bold;
  background-image: url("images/christmas/tile.png");
  background-size: contain;
  border: 1px solid #c22727;
  font-size: 15px;
}

#box-row3-left .nav-list {
  list-style: none;
  padding: 5px 15px 15px 15px;
  margin: 5;
  flex-grow: 1;
  overflow-y: auto;
}
#box-row3-left .nav-list li {
  margin:4px 0;
}
#box-row3-left .nav-list a {
  display: block;
  padding: .5px 6px;
  text-decoration: none;
  color: #db1e1e;
  text-shadow: 0 0 3px #ffffff, 0 0 5px #ffffff;
  font-weight: 600;
  font-size: 18px;
  background: url(images/christmas/tilem.png);
  border: 1px solid #008a22;
  border-radius: 10px;

  transition: transform .2s, box-shadow .2s, background .2s;

  cursor: pointer;
  margin-bottom: 4px;
}

#box-row3-left .nav-list a:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 8px rgba(0,0,0,0.4), inset 0 1px 0 rgba(255,255,255,0.7);
  background: linear-gradient(to bottom, #9ac4ff, #bbeeff);
  text-decoration: none;
  color: #fff;
}

#box-row3-left .nav-list a:active {
  transform: translateY(0);
  box-shadow: 0 2px 4px rgba(0,0,0,0.3), inset 0 1px 0 rgba(255,255,255,0.3);
}


#box-row3-left .nav-list a:hover {
  text-decoration: none;
  color: #fff; 
  cursor: pointer;
}
/* ==== Centers the Link me thingy==== */
#box-row4-right .nav-header {
  align-self: stretch;
  width: calc(100% + 20px);
  margin: 0 -10px;
  box-sizing: border-box;
}

#box-row4-right .link-me-content img {
  margin-top: 4px;
}

#box-row4-right {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 10px;
  flex: 0 0 19.2%;
  background-image: url("images/christmas/nav.png");
  background-size: contain;
}
#box-row4-right .link-me-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}
#box-row4-right textarea {
  max-width: 90%;
}

/* ==== USER ID OVERRIDES ==== */
#box-row3-right {
  flex: 0 0 20.5%;
}
#box-row3-center {
  flex: 0 0 86.8%;
}
#box-subheader {
  position: relative;
  flex: 0 0 3%;
  width: 134.5%;
left: -17.2%;
  background-image: url("images/christmas/tile.png");
}

#box-subheader2 {
  position: relative;
  flex: 0 0 3%;
  width: 134.5%;
   left: -17.2%;
  background-image: url("images/christmas/tilem.png");
  background-size: contain;
}
#box-header {
  position: relative;
  z-index: auto !important;
  background: url('images/Header.png') center/cover no-repeat;
  height: 30%;
  width: 134.5%;
left: -17.2%;
}

/* So the logo stays on top of the tree */
#box-header img {
  position: relative;
  z-index: 9999;
  
}

/* Prevent the box from growing if the image is larger */
#box-row2-right {
  overflow: hidden;
  position: relative;
  background-image: url("images/christmas/nav.png");
  background-size: contain;
}

#box-row2-right img {
  display: block;
  max-width: 80%;
  max-height: 90%;
  width: auto;
  height: auto;
  object-fit: contain;
  margin: 4px auto;
}
#box-row4-left {
  display: flex;
  width: 150%;
  flex-direction: column;
  background-image: url("images/christmas/nav.png");
  background-size: contain;
}

/* content area grows & scrolls */
#box-row4-left .changelog-content {
  flex: 1;
  overflow-y: auto;
  padding: 8px;
}

/* nice bullet spacing */
#box-row4-left .changelog-content ul {
  list-style: disc inside;
  margin: 0;
  padding-left: 1em;
}

#box-row4-left .changelog-content li {
  margin-bottom: 0.5em;
}

#box-header {
  position: relative;
  z-index: 100;
}


#box-header img {
  position: relative;  
  left: -100px;
  z-index: 101;
}

/* Hover animation */
.overlay-gif2:hover {
  transform: scale(1.1) rotate(5deg);
  filter: brightness(1.2) contrast(1.2);
  cursor: pointer;
}
/*chao gif*/
.overlay-gif3 {
  position: fixed;
  top: 54%;
  left: 77%;
  z-index: 999;  
  pointer-events: auto;
  transition: 
  
    transform 0.3s ease-in-out, 
    filter    0.3s ease-in-out;
}

.overlay-gif4 {
  position: absolute;
  top: 13.6%;
  left: 107%;
  z-index: 999;
  pointer-events: none;

  width: 62px;
  height: auto;

  image-rendering: auto;
}

#row-4 {
  position: relative;
}


#box-row2-left {
  flex: 0 0 26%;
  height: 100%;
}

#box-row2-left {
  position: relative;
margin-left: 99px;;
}
#box-row2-left .overlay-gif {
  position: absolute;  
  top: -267px;
  left: -281px;
  z-index: 90;
}

#box-row3-right {
  position: relative;
  overflow: hidden;
  height: 66%;
  top: 34%;
}

/* make the image fill the entire box */
#box-row3-right img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: auto;
}

/* tree overlay: sits on top*/
.tree-gif {
  top: -10px;
  left: 15%;               
  transform: translateX(-50%); 
  z-index: 188;
  pointer-events: none;    /* clicks pass through to underlying elements */
  position: fixed;
  image-rendering: pixelated; 
}

#box-header {
  z-index: auto !important;
}

#box-header > img {
  position: relative !important;
  z-index: 999 !important;
    display: inline-block;       /* let transform work properly */
  animation: bounce 1.5s ease-in-out infinite;
}

#box-row2-filler-left {
  visibility: visible;
  position: absolute;
  top: 301px; 
  left: 928px;
  height: 27%;
  z-index: 189;
  width: 20.49%;
}

/* make the iframe inside fill its container */
#box-row2-filler-left iframe {
  transform: scale(1.06);
  transform-origin: top left;
  width: 125%; 
  height: 125%;
  border: none;
}

#box-row3-left {
  position: relative;
  background-image: url("images/christmas/nav.png");
  background-size: cover;
  z-index: 990;
    flex: 0 0 25%;
}

#box-row4-mid1 {
  flex: 0 0 20%;	
}

@keyframes bounce {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-8px); /* how high it bounces */
  }
}
#box-row3-center {
  background-image: url(images/christmas/bgt.png);
  background-size: repeat;
  padding: 20px;                   /* breathe room */
  overflow-y: auto;                /* scroll if content grows */
  max-height: 100%;                /* fit inside the flex row */
}


#box-row3-center h2,
#box-row3-center h3,
#box-row3-center p {
  color: #e00000;
}


/* ensure each tab is spaced nicely */
#box-row3-center .tab-content {
  margin-bottom: 1em;
}


#box-row3-left .nav-list a:hover {
  text-decoration: underline;
  color: blue;
  cursor: pointer;
}

@keyframes click-jump {
  0%, 100%   { transform: translateY(0); }
  50%        { transform: translateY(-10px); }
}

.overlay-gif3.jump {
  animation: click-jump 0.3s ease;
}


#box-row4-mid2 {
  height: 100%;  
  overflow-y: auto;        
  overflow-x: hidden;      
     
}

.dragonair-shrine:hover {
  transform: scale(1.1) rotate(5deg);
  filter: brightness(1.2) contrast(1.2);
  cursor: pointer;
}

/* AERO WEBRING */
#aero-ring {
    background: linear-gradient(
    to top,
    rgb(217, 0, 0) 0%,
    rgb(214, 0, 0) 47%,
    rgb(255, 35, 35) 47%,
    rgb(255, 119, 119) 100%
  );
    border-radius: 8px;
    box-shadow: 0 0 4px rgba(2, 21, 223, 0.5),
    inset 0 2px 1px rgba(255, 255, 255, 0.2),
    inset 0 -2px 1px rgba(0, 15, 219, 0.35);
    margin: 10px auto 0px auto;
    padding: 0.75rem;
    max-width: 15rem;
    font-family: Arial, sans-serif;
  }

  #aero-ring a,
  #aero-ring a:visited {
    color: white !important;
}
  #aero-ring a:focus,
  #aero-ring a:hover {
  color: #47e05b !important;
}
  #aero-ring a:active {
  color: #72f183 !important;
}


/* AYO BRUH SHOUTOUT W3SCHOOLS*/
::-webkit-scrollbar {
  width: 10px;
}

/* Track */
::-webkit-scrollbar-track {
  box-shadow: inset 0 0 5px grey; 
  border-radius: 10px;
}
 
/* Handle */
::-webkit-scrollbar-thumb {
  box-shadow: inset 0 0 10px White; 
  background: #ff0000; 
  border-radius: 10px;
}

/* Handle on hover */
::-webkit-scrollbar-thumb:hover {
  background: #23ff35; 
}

/* Start https://www.cursors-4u.com */ * {cursor: url(https://cur.cursors-4u.net/games/gam-12/gam1112.cur), auto !important;} /* End https://www.cursors-4u.com */

.marquee {
  display: flex;
  overflow: hidden;
  white-space: nowrap;
}

.marquee__inner {
  display: flex;
  animation: scroll 80s linear infinite;
}

.marquee__inner img {
  flex-shrink: 0;
  margin: 2px;
}

@keyframes scroll {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); } 
}

/* Welcome tab boxes */
.welcome-top-box {
  background: linear-gradient(to bottom, #e6f3ff, #98ff8f, #ffffff);
  padding: 15px;
  margin: -1px 0;
  box-shadow: 0 2px 4px rgba(0,89,255,0.2);

  border: 10px solid transparent;

  animation: welcomeBorder 0.8s steps(1) infinite;

}

@keyframes welcomeBorder {
  0% {
    border-image: url("images/christmas/fp9ci4-1.png") 8 fill round;
  }
  50% {
    border-image: url("images/christmas/fp9ci4-2.png") 8 fill round;
  }

}

.welcome-top-box h4 {
  color: #26c000;
  margin-bottom: 8px;
}

.welcome-top-box p {
  color: #1f69ff;
  margin: 0;
  font-size: 107%;
}

.welcome-box-row {
  display: flex;
  gap: 15px;
  margin: 20px 0;
  justify-content: space-between;
}

.welcome-small-box {
  flex: 1;
  background: linear-gradient(to bottom, #f0f8ff, #2bd439);
  border: 10px solid transparent;

  animation: welcomeBorder 0.8s steps(1) infinite;
  padding: 8px;
  text-align: center;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  box-shadow: 0 2px 4px rgba(88,224,242,0.2);
}

.welcome-small-box:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(88,224,242,0.3);
}

.welcome-small-box h5 {
  color: #1f69ff;
  margin-bottom: 6px;
  font-size: 16px;
}

.welcome-small-box p {
  color: #1f69ff;
  font-size: 14px;
  margin: 0;
}

.doll {
  position: relative;
  float: right;
  top: -110px;
  image-rendering: pixelated;
}

.res {
  position: relative;
  float: right;
  top: -50px;
  image-rendering: pixelated;
}

.per {
position: relative;
float: left;
  image-rendering: pixelated;
}

.aboutme-row {
  display: flex;
  gap: 15px;
  flex-wrap: wrap;
}

.aboutme-row .images-box {
  flex: 1.7; 
}

.aboutme-row .interests-box {
  flex: 1;  
}

.images-box {
  display: grid;
  grid-template-columns: repeat(2, 50%);
  justify-content: center;   
  gap: 2px;
}

.images-box img {
  width: 100%; 
  height: auto;
  display: block;
}

.images-box2 {
  justify-content: center;   
}

.images-box2 img {
  width: 100%; 
  height: auto;
  display: block;
}

        .quiz-grid {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(370px, 1fr));
            gap: 2px;
            padding: 20px;
        }

        .quiz-item {
             background: linear-gradient(to bottom, #e6f3ff,#aaf2ff, #ccff7a);
  border-width: 10px;
          border-style: solid;
          border-image: url("images/christmas/fp9ci4.png") 8 fill round;
      
            padding: 1px;
            border-radius: 10px;
            box-shadow: 0 2px 8px rgba(0,0,0,0.1);
            text-align: center;
            transition: transform 0.2s ease, box-shadow 0.2s ease;
        }

        .quiz-item:hover {
            transform: translateY(-2px);
            box-shadow: 0 4px 12px rgba(0,0,0,0.15);
        }

        .quiz-item img {
            max-width: 100%;
            height: auto;
            max-height: 150px;
            object-fit: contain;
            border-radius: 5px;
        }

        .quiz-item a {
            display: block;
            text-decoration: none;
        }


        .quiz-grid-uniform .quiz-item {
            aspect-ratio: 1;
            display: flex;
            align-items: center;
            justify-content: center;
        }

        .quiz-grid-uniform .quiz-item img {
            max-width: 90%;
            max-height: 90%;
            object-fit: contain;
        }

/* STATUS.CAFE WIDGET*/
#statuscafe {
  background: linear-gradient(to bottom, #e6f3ff, #ffaaaa, #b3ff61, #ffffff);
  border-width: 10px;
  border-style: solid;
  border-image: url("images/christmas/fp9ci4-1.png") 8 fill round;
  padding: 4px;
  margin: 1px 0;
  box-shadow: 0 2px 4px rgba(0,89,255,0.2);
  font-family: ms ui gothic, sans-serif;
  color: #1f69ff;
}

/* Username styled like a mini header */
#statuscafe-username {
  font-weight: bold;
  font-size: 13px;
  margin-bottom: 6px;
  color: #0059ff;
  text-shadow: 0 0 3px #9ac4ff;
}

/* Status content */
#statuscafe-content {
  font-size: 14px;
  line-height: 1.4;
  margin: 0;
  padding: 8px;
  background: rgba(255, 255, 255, 0.64);
  border-radius: 6px;
  border: 1px solid #9ac4ff;
  box-shadow: inset 0 1px 2px rgba(0,0,0,0.1);
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  border: 0;
}

/* i used to have a crush on the T-Mobile lady */
@media (max-width: 1200px) {
  .layout {
    transform: scale(0.9) translateX(5.5%);
    transform-origin: top center;
    margin-bottom: -10%; /* getting rid of that weird gap happening on the bottom */
  }
}
@media (max-width: 900px) {
  .layout {
    transform: scale(0.75) translateX(16.5%);
    transform-origin: top center;
    margin-bottom: -25%;
  }
}
@media (max-width: 600px) {
  .layout {
    transform: scale(0.6) translateX(33%);
    transform-origin: top center;
    margin-bottom: -40%;
  }
}

@media (max-width: 900px) {
  .tree-gif,
  .overlay-gif3 {
    display: none !important;
  }
}

@media (max-width: 900px) {
  #box-header {
    text-align: center; 
  }

  #box-header img {
    position: relative !important;
    left: 0 !important;
    margin: 0 auto;
    display: block;
    max-width: 90%;
    height: auto;
  }
}

/*SNOW*/

.snow,
.snow::before,
.snow::after {
  position: fixed;
  inset: 0;
  top: -600px;
  pointer-events: none;
  z-index: 9999;
  content: "";
  background-repeat: repeat;
  background-size: 600px 600px;
  animation-name: snow-fall;
  animation-timing-function: linear;
  animation-iteration-count: infinite;
}

/* lay1 */
.snow {
  background-image:
    radial-gradient(5px 5px at 100px 120px, rgba(255,255,255,0.9) 50%, transparent),
    radial-gradient(4px 4px at 300px 80px, rgba(255,255,255,0.8) 50%, transparent),
    radial-gradient(6px 6px at 500px 200px, rgba(255,255,255,0.95) 50%, transparent),
    radial-gradient(5px 5px at 200px 350px, rgba(255,255,255,0.85) 50%, transparent),
    radial-gradient(4px 4px at 600px 450px, rgba(255,255,255,0.9) 50%, transparent),
    radial-gradient(6px 6px at 350px 530px, rgba(255,255,255,1) 50%, transparent),
    radial-gradient(5px 5px at 80px 600px, rgba(255,255,255,0.9) 50%, transparent);
  animation-duration: 6s;
}

/* lay2*/
.snow::before {
  background-image:
    radial-gradient(3px 3px at 150px 50px, rgba(255,255,255,0.5) 50%, transparent),
    radial-gradient(2px 2px at 450px 150px, rgba(255,255,255,0.4) 50%, transparent),
    radial-gradient(3px 3px at 250px 280px, rgba(255,255,255,0.6) 50%, transparent),
    radial-gradient(2px 2px at 550px 330px, rgba(255,255,255,0.5) 50%, transparent),
    radial-gradient(3px 3px at 370px 470px, rgba(255,255,255,0.6) 50%, transparent),
    radial-gradient(2px 2px at 120px 580px, rgba(255,255,255,0.5) 50%, transparent);
  animation-duration: 14s;
  opacity: 0.55;
  filter: blur(1.5px);
}

/* lay3*/
.snow::after {
  background-image:
    radial-gradient(8px 8px at 200px 90px, rgba(255,255,255,0.95) 50%, transparent),
    radial-gradient(7px 7px at 480px 160px, rgba(255,255,255,1) 50%, transparent),
    radial-gradient(9px 9px at 340px 260px, rgba(255,255,255,0.95) 50%, transparent),
    radial-gradient(8px 8px at 120px 420px, rgba(255,255,255,1) 50%, transparent),
    radial-gradient(7px 7px at 520px 520px, rgba(255,255,255,0.95) 50%, transparent);
  animation-duration: 8s;
  margin-left: -250px; /* for parallax */
  opacity: 0.7;
  filter: blur(2.5px);
}

@keyframes snow-fall {
  to {
    transform: translateY(600px);
  }
}