/* Global box-sizing */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  width: 100vw;
  height: 100vh;
  overflow: hidden;
  margin: 0;
  padding: 0;
  font-family: "Tahoma", sans-serif;
  background-color: #c0c0c0; /* Classic light grey */
  color: black;
  text-align: center;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
}

/* Optional container for maximum size */
.container {
  width: 100%;
  height: 100%;
  max-width: 1024px;
  max-height: 768px;
  margin: auto;
  display: flex;
  flex-direction: column;
}

/* Header */
header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background-color: #1f1b36;
  padding: clamp(10px, 1.5vh, 20px);
  width: 100%;
  border-bottom: 2px solid #808080; /* Windows 2000-style separator */
}

/* Clock */
#clock {
  font-size: clamp(16px, 1.8vw, 24px);
  color: white;
  text-align: left;
  padding-left: clamp(10px, 2vw, 20px);
}

/* Logo */
#logo-container {
  padding: clamp(2px, 0.5vh, 8px); /* Reduced padding */
  display: flex;
  justify-content: center;
  align-items: center;
}

#logo {
  height: clamp(50px, 5vh, 80px); /* Slightly increased height */
  width: auto; /* Maintain aspect ratio */
  padding: clamp(2px, 0.5vh, 8px); /* Adjusted padding to prevent overlap */
  margin-right: clamp(
    5px,
    1vw,
    15px
  ); /* Tweaked margin for better positioning */
}

/* Main UI area */
main {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  flex-grow: 1;
  padding: clamp(10px, 2vh, 20px) 0;
  overflow: hidden;
}

/* Button Rows */
.button-row {
  display: flex;
  justify-content: center;
  gap: clamp(15px, 3vw, 30px);
  width: 90%;
  margin-bottom: clamp(10px, 2vh, 20px);
}

.button-row:first-of-type {
  height: clamp(140px, 15vh, 180px);
}

.button-row:nth-of-type(2) {
  height: clamp(120px, 14vh, 160px);
}

.button-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex-grow: 1;
}

/* Windows 2000-Style Buttons */
.menu-button {
  background-color: #d4d0c8;
  border: 2px solid #808080;
  padding: clamp(5px, 1vw, 10px);
  box-shadow: inset -3px -3px 3px white, inset 3px 3px 3px #808080;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
}

.menu-button img {
  width: clamp(30px, 4vw, 45px);
  height: clamp(30px, 4vw, 45px);
  margin-bottom: clamp(2px, 1vh, 5px);
}

.menu-button span {
  font-size: clamp(14px, 1.8vw, 18px);
}

/* Windows 2000-style pressed effect */
.menu-button:active {
  box-shadow: inset 3px 3px 3px #808080, inset -3px -3px 3px white;
  background-color: #b0aca4; /* Slightly darker when pressed */
}

/* Advertisement Row */
.advertisement-row {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 90%;
  margin-top: clamp(10px, 2vh, 20px);
}

.advertisement-container {
  flex: 1;
  display: flex;
  justify-content: flex-start;
}

.advertisement-container img {
  width: 100%;
  height: 100%;
}

.ad-text-container {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: left;
  font-size: clamp(14px, 1.8vw, 16px);
  color: black;
  padding: clamp(5px, 1vw, 10px);
}

/* Dynamic Content in `temp.html` */
#dynamic-content {
  flex-grow: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  font-size: clamp(14px, 2vw, 18px);
  padding: clamp(10px, 2vw, 20px);
  width: 90%;
}

/* Cancel Button */
#cancelButton {
  width: clamp(100px, 20vw, 200px);
  padding: clamp(5px, 1vw, 10px);
  background-color: #e05656;
  border: 2px solid #800000;
  color: white;
  font-weight: bold;
  cursor: pointer;
  box-shadow: inset -2px -2px 2px white, inset 2px 2px 2px #800000;
  margin-top: 10px;
}

#cancelButton:active {
  box-shadow: inset 2px 2px 2px #800000, inset -2px -2px 2px white;
}

/* Media query for very small screens */
@media (max-width: 600px) {
  header,
  main {
    padding: 10px;
  }
  .button-row {
    flex-direction: column;
    height: auto;
  }
  .menu-button img {
    width: 50px;
    height: 50px;
  }
  .menu-button span {
    font-size: 16px;
  }
}
