/*
// ╔╗ ╔═╗╔╗╔╔╦╗╔═╗
// ╠╩╗║╣ ║║║ ║ ║ ║
// ╚═╝╚═╝╝╚╝ ╩ ╚═╝
*/

/* V A R I A B L E S */
@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@300;400;700&display=swap');

:root {
  /* Font Size */
  --fg-primary: 12vh;
  --fg-secondary: 3vh;
  --fg-date: 8vh;
  --fg-list: 2vh;
  --icon: 3vh;

  /* Fonts Color */
  --fg: #1a2a3a;
  --sfg: #0f1a2a;

  /* Light Colors — cozy pastel blues + emerald accent */
  --accent: #5db88a;
  --background: #c8e6f7;
  --cards: #b8d4ef;

  /* Image background  */
  --imgbg: url(assets/background.jpg);
  --imgcol: linear-gradient(
    rgba(255, 255, 255, 0.7),
    rgba(255, 255, 255, 0.7)
  );
}

.darktheme {
  /* Dark Colors — deep cozy blue + emerald accent */
  --accent: #5db88a;
  --background: #0e1621;
  --cards: #162030;

  /* Fonts Color */
  --fg: #c8ddf0;
  --sfg: #0e1621;

  /* Image background  */
  --imgcol: linear-gradient(
    rgba(0, 0, 0, 0.85),
    rgba(0, 0, 0, 0.85)
  );
}

/* S T Y L E S */

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Manrope', sans-serif;
  transition: 0.2s ease-in-out;
}

body {
  width: 100vw;
  height: 100vh;
  background-color: var(--background);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.notransition {
  -webkit-transition: none;
  -moz-transition: none;
  -o-transition: none;
  transition: none;
}

.withImageBackground {
  background-image: var(--imgcol), var(--imgbg);
  background-size: cover;
}

#themeButton {
  position: absolute;
  margin: 2em 2em 0 0;
  right: 0;
  top: 0;
  color: var(--fg);
  border: none;
  cursor: pointer;
  background-color: #00000000;
  z-index: 50;
}

#themeIcon {
  width: 25px;
  height: 25px;
}

.container {
  width: 145vh;
  height: 85vh;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-template-rows: repeat(4, 1fr);
  grid-gap: 30px;
  padding: 20px;
  z-index: 1;
}

.card {
  background-color: var(--cards);
  box-shadow: 0 5px 7px rgba(0, 0, 0, 0.2);
  border-radius: 6px;
}

.card:hover {
  transform: translateY(-0.2rem);
  box-shadow: 0 10px 15px rgba(93, 184, 138, 0.2);
}

.timeBlock {
  grid-row: 1 / span 2;
  grid-column: 1 / span 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.weatherBlock {
  grid-column: 3 / span 2;
  grid-row: 1 / span 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  position: relative;
}

.date {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 30px;
}

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

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

#hour,
#separator,
#minutes {
  font-size: var(--fg-primary);
  font-weight: bolder;
  color: var(--fg);
}

#month,
#day {
  font-size: var(--fg-date);
  font-weight: bold;
  color: var(--fg);
}

#day {
  margin-left: 1.5rem;
}

#greetings {
  font-size: var(--fg-secondary);
  color: var(--fg);
}

.weatherIcon img {
  width: 70px;
  height: 70px;
}

.weatherValue p {
  font-size: var(--fg-secondary);
  font-weight: bolder;
  margin-left: 15px;
  color: var(--fg);
}

.weatherDescription p {
  font-size: var(--fg-secondary);
  margin-left: 15px;
  color: var(--fg);
}

.reduceGap {
  grid-gap: 2rem !important;
}

.removeGap {
  grid-gap: 0 !important;
}

.linksBlock {
  grid-row: 3 / span 2;
  grid-column: 1 / span 4;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-template-rows: repeat(2, 1fr);
  grid-gap: 1.5rem;
}

.linksBlockLeft {
  grid-row: 1 / span 2;
  grid-column: 1 / span 2;
}

.linksBlockRight {
  grid-row: 1 / span 2;
  grid-column: 3 / span 2;
}

.buttonsContainer {
  width: 100%;
  height: 100%;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: repeat(2, 1fr);
  grid-gap: 30px;
  padding: 20px;
}

.button {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  position: relative;
  text-decoration: none;
}

.buttonIcon {
  width: var(--icon);
  height: var(--icon);
  color: var(--fg);
}

.button__1 {
  grid-row: 1;
  grid-column: 1;
}
.button__2 {
  grid-row: 1;
  grid-column: 2;
}
.button__3 {
  grid-row: 2;
  grid-column: 1;
}
.button__4 {
  grid-row: 2;
  grid-column: 2;
}
.button__5 {
  grid-row: 1;
  grid-column: 3;
}
.button__6 {
  grid-row: 2;
  grid-column: 3;
}
.button:hover {
  background-color: var(--accent);
}
.button:hover svg {
  stroke: var(--sfg);
}

/* Tiny pokeball on button hover */
.button:hover::after {
  content: '';
  position: absolute;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  border: 1.5px solid var(--sfg);
  opacity: 0.25;
  bottom: 5px;
  right: 5px;
}

.listsContainer {
  width: 100%;
  height: 100%;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  grid-template-rows: repeat(2, 1fr);
  grid-gap: 3rem;
  padding: 0.4rem;
}

.list {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
}

.list__1 {
  grid-column: 1;
  grid-row: 1 / span 2;
}
.list__2 {
  grid-column: 2;
  grid-row: 1 / span 2;
}
.listIcon {
  margin-bottom: 2vh;
  color: var(--fg);
  width: var(--icon);
  height: var(--icon);
}
.listItem {
  text-decoration: none;
  font-size: var(--fg-list);
  color: var(--fg);
  margin-top: 1vh;
  padding: 8px 12px;
  border-radius: 4px;
  font-weight: bold;
  text-align: center;
  width: 80%;
}
.listItem:hover {
  background-color: var(--accent);
  color: var(--sfg);
}

/* ═══════════════════════════════════════════
   P O K E M O N  /  E M E R A L D   T H E M E
   ═══════════════════════════════════════════ */

/* Pokemon quote under greeting */
#pokemon-quote {
  font-size: 1.3vh;
  color: var(--fg);
  opacity: 0.45;
  margin-top: 1.2vh;
  max-width: 85%;
  text-align: center;
  font-style: italic;
  line-height: 1.6;
}

/* Jirachi in weather block */
.weather-pokemon {
  width: 50px;
  height: 50px;
  margin-top: 8px;
  opacity: 0.6;
  image-rendering: pixelated;
  transition: opacity 0.3s, transform 0.4s;
}

.weather-pokemon:hover {
  opacity: 1;
  transform: scale(1.3) rotate(-5deg);
}

/* Decorative Pokemon GIFs */
.pokemon-deco {
  position: fixed;
  z-index: 0;
  image-rendering: pixelated;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.6s;
}

/* They fade in after page loads (via JS) */
.pokemon-deco.visible {
  opacity: 1;
  pointer-events: auto;
}

/* Snorlax sleeping - bottom right */
.pokemon-snorlax {
  bottom: 10px;
  right: 20px;
  height: 65px;
  width: auto;
  cursor: pointer;
  animation: snorlax-breathe 4s ease-in-out infinite;
}

.pokemon-snorlax:hover {
  opacity: 0.9 !important;
}

@keyframes snorlax-breathe {
  0%, 100% { transform: scaleY(1); }
  50% { transform: scaleY(1.03); }
}

/* Cleffa - top left, small */
.pokemon-cleffa {
  top: 10px;
  left: 12px;
  height: 30px;
  width: auto;
  cursor: pointer;
  animation: cleffa-bounce 3s ease-in-out infinite;
}

@keyframes cleffa-bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-5px); }
}

/* Mudkip - top right corner */
.pokemon-mudkip {
  top: 10px;
  right: 50px;
  height: 24px;
  width: auto;
  cursor: pointer;
  animation: mudkip-wiggle 5s ease-in-out infinite;
}

@keyframes mudkip-wiggle {
  0%, 100% { transform: rotate(0deg); }
  25% { transform: rotate(-4deg); }
  75% { transform: rotate(4deg); }
}

/* Wooper - bottom left, happy bounce */
.pokemon-wooper {
  bottom: 10px;
  left: 60px;
  height: 35px;
  width: auto;
  cursor: pointer;
  animation: wooper-hop 2.5s ease-in-out infinite;
}

@keyframes wooper-hop {
  0%, 100% { transform: translateY(0) scaleX(1); }
  30% { transform: translateY(-8px) scaleX(1.02); }
  50% { transform: translateY(0) scaleX(0.98); }
  70% { transform: translateY(-4px) scaleX(1.01); }
}

/* Pokeball - bottom left corner */
#pokeball {
  position: fixed;
  bottom: 1.5em;
  left: 1.5em;
  width: 32px;
  height: 32px;
  cursor: pointer;
  z-index: 100;
  border-radius: 50%;
  overflow: hidden;
  border: 2px solid var(--fg);
  opacity: 0.3;
  transition: opacity 0.3s, transform 0.3s;
}

#pokeball:hover {
  opacity: 1;
  transform: scale(1.25);
}

.pokeball-top {
  height: 45%;
  background: #ee1515;
}

.pokeball-center {
  height: 10%;
  background: var(--fg);
  display: flex;
  align-items: center;
  justify-content: center;
}

.pokeball-button {
  width: 9px;
  height: 9px;
  background: #fff;
  border: 2px solid var(--fg);
  border-radius: 50%;
  position: relative;
  z-index: 1;
}

.pokeball-bottom {
  height: 45%;
  background: #fff;
}

.pokeball-shake {
  animation: pokeball-wobble 0.6s ease-in-out;
}

@keyframes pokeball-wobble {
  0% { transform: rotate(0deg); }
  20% { transform: rotate(-20deg); }
  40% { transform: rotate(20deg); }
  60% { transform: rotate(-15deg); }
  80% { transform: rotate(10deg); }
  100% { transform: rotate(0deg); }
}

/* Pokemon toast notification */
#pokemon-toast {
  position: fixed;
  bottom: 4.5em;
  left: 1.5em;
  background: var(--cards);
  color: var(--fg);
  padding: 0.7em 1.1em;
  border-radius: 8px;
  display: flex;
  align-items: center;
  gap: 0.6em;
  font-size: 1.3vh;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
  border: 1px solid var(--accent);
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.4s, transform 0.4s;
  pointer-events: none;
  z-index: 200;
}

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

#pokemon-toast img {
  width: 48px;
  height: 48px;
  image-rendering: pixelated;
}

/* Emerald Mode - activated via Konami code */
.emerald-mode {
  --accent: #3dd68c !important;
  --cards: #a8d8c8 !important;
}

.emerald-mode.darktheme {
  --cards: #142e24 !important;
}

.emerald-mode .card:hover {
  box-shadow: 0 10px 25px rgba(61, 214, 140, 0.3);
}

.emerald-mode #pokeball {
  opacity: 1;
}

.emerald-mode .pokeball-top {
  background: #2d8b4e;
}

.emerald-mode .pokemon-deco.visible {
  opacity: 1;
}

/* Snorlax tooltip */
.snorlax-tooltip {
  position: fixed;
  bottom: 80px;
  right: 20px;
  background: var(--cards);
  color: var(--fg);
  padding: 0.5em 0.8em;
  border-radius: 8px;
  font-size: 1.2vh;
  font-style: italic;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.2);
  opacity: 0;
  transition: opacity 0.3s;
  pointer-events: none;
  z-index: 100;
}

.snorlax-tooltip.show {
  opacity: 1;
}

/* M E D I A - Q U E R I E S */

@media only screen and (max-width: 68.75em) {
  .container {
    grid-gap: 20px;
    padding: 40px;
  }

  .timeBlock {
    grid-row: 1 / span 2;
    grid-column: 1 / span 4;
  }

  .weatherBlock {
    display: none;
  }

  #greetings {
    font-size: var(--fg-secondary);
  }

  .linksBlockRight {
    display: none;
  }

  .linksBlockLeft {
    grid-column: 1 / span 4;
  }

  .button {
    grid-gap: 3vw;
    padding-left: 100px;
    padding-right: 100px;
  }

  #pokemon-quote {
    display: none;
  }

  .pokemon-snorlax,
  .pokemon-cleffa,
  .pokemon-mudkip,
  .pokemon-wooper {
    display: none;
  }
}
