:root {
    --theme-color-1: #CC0000;
    --theme-color-2: #AA3939;
    --theme-color-3: #800000;
    --theme-highlight-color: #CC0000;
    --theme-hover-color: #FF6666;
    --theme-glow-color: rgba(204, 0, 0, 0.4);
    --theme-message-box-shadow: rgba(170, 57, 57, 0.5);
    --theme-powered-by-color: #CC3333;
    --theme-crimson-x-gradient: linear-gradient(to right, #CC0000, #FF6666, #FFCC66, #FF6666, #CC0000);
    
    --body-bg-color: #000000;
    --theme-input-bg: #1A1A1A;
    --theme-input-border: #444444;
    --theme-text-color-light: #F0F0F0;
}

body, html {
    margin: 0;
    padding: 0;
    background-color: var(--body-bg-color);
	color: var(--theme-text-color-light);
	font-family: Chakra Petch Medium, sans-serif;
}
* {
    box-sizing: border-box;
}

input, select {
  font-family: "Chakra Petch Medium", sans-serif;
  font-size: 14px;
  margin-top: 0px;
  display: block;
  width: 250px;
  padding: 0.5rem 1rem;
  background-color: var(--theme-input-bg);
  border: 1px solid var(--theme-input-border);
  color: var(--theme-text-color-light);
  border-radius: 5px;
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
}

select {
    background-image: url('data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20viewBox%3D%220%200%20256%20256%22%3E%3Cpath%20fill%3D%22%23F5F5F5%22%20d%3D%22M200.75%2099.25l-72%2072a6%206%200%2001-8.5%200l-72-72a6%206%200%20018.5-8.5l67.75%2067.75%2067.75-67.75a6%206%200%20018.5%208.5z%22%2F%3E%3C%2Fsvg%3E');
    background-repeat: no-repeat;
    background-position: right 0.7rem center;
    background-size: 1.2em;
    padding-right: 2.5rem;
    cursor: pointer;
}

label[for="themeSelector"] {
    display: block;
    margin-top: 20px;
    font-size: 1em;
    color: var(--theme-color-2);
}

input::-webkit-calendar-picker-indicator {
    filter: invert(1) brightness(2);
    cursor: pointer;
    opacity: 1;
}

input::-moz-calendar-picker-indicator {
    filter: invert(1) brightness(2);
    cursor: pointer;
    opacity: 1;
}

input:focus, select:focus {
    outline: none;
    border-color: var(--theme-color-2);
    box-shadow: 0 0 0 3px var(--theme-message-box-shadow);
}

.theme-selection-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-top: 10px;
    width: 100%;
}

.arrow-btn {
    background-color: var(--theme-input-bg);
    border: 1px solid var(--theme-input-border);
    color: var(--theme-text-color-light);
    padding: 8px 12px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1.2em;
    transition: all 0.2s ease-in-out;
    line-height: 1;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.arrow-btn:hover {
    background-color: var(--theme-color-2);
    border-color: var(--theme-color-1);
    box-shadow: 0 0 5px var(--theme-glow-color);
}

.arrow-btn:active {
    transform: translateY(1px);
}

.container {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

#clock {
    font-size: 18vw;
	margin: 40px 0px 0px 0px;
	width: 100%;
	text-align: center;
    background-image: linear-gradient(to bottom,
        var(--theme-color-1),
		var(--theme-color-2),
		var(--theme-color-3)
	);
    background-clip: text;
    -webkit-background-clip: text;
    -moz-background-clip: text;
    -webkit-text-fill-color: transparent; 
    -moz-text-fill-color: transparent;
    text-shadow: 0 0 20px var(--theme-glow-color);
}

#countdownDisplay {
    font-size: 0.8em;
    margin-top: 15px;
    margin-bottom: 15px;
    color: var(--theme-color-2);
    text-align: center;
    width: 100%;
}

.frame {
  width: 100%;
  margin: 40px auto;
  text-align: center;
}

.custom-btn {
  width: 150px;
  height: 45px;
  color: var(--theme-text-color-light);
  border-radius: 8px;
  padding: 10px 25px;
	margin: 15px 15px;
	font-family: Chakra Petch Medium, sans-serif;
  font-weight: 500;
  background: transparent;
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
  display: inline-block;
   box-shadow:inset 2px 2px 5px 0px rgba(255,255,255,.1),
   7px 7px 20px 0px rgba(0,0,0,.2),
   4px 4px 5px 0px rgba(0,0,0,.2);
  outline: none;
  border: none;
}

.link-btn {
  background: linear-gradient(to bottom, var(--theme-color-2) 0%, var(--theme-color-3) 100%);
  width: 150px;
  height: 45px;
  line-height: 45px;
  padding: 0;
  border: none;
}

.link-btn span {
  position: relative;
  display: block;
  width: 100%;
  height: 100%;
  border-radius: 8px;
  z-index: 2;
}

.link-btn:before,
.link-btn:after {
  position: absolute;
  content: "";
  right: 0;
  top: 0;
   background: var(--theme-highlight-color);
  transition: all 0.3s ease;
  border-radius: 8px;
}
.link-btn:before {
  height: 0%;
  width: 2px;
}
.link-btn:after {
  width: 0%;
  height: 2px;
}
.link-btn:hover{
   background: transparent;
  box-shadow: none;
}
.link-btn:hover:before {
  height: 100%;
}
.link-btn:hover:after {
  width: 100%;
}
.link-btn span:hover{
   color: var(--theme-hover-color);
}
.link-btn span:before,
.link-btn span:after {
  position: absolute;
  content: "";
  left: 0;
  bottom: 0;
   background: var(--theme-highlight-color);
  transition: all 0.3s ease;
  border-radius: 8px;
}
.link-btn span:before {
  width: 2px;
  height: 0%;
}
.link-btn span:after {
  width: 0%;
  height: 2px;
}
.link-btn span:hover:before {
  height: 100%;
}
.link-btn span:hover:after {
  width: 100%;
}

.custom-message-box {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: var(--theme-input-bg);
    color: var(--theme-text-color-light);
    padding: 20px;
    border-radius: 8px;
    z-index: 1000;
    font-family: 'Chakra Petch Medium', sans-serif;
    box-shadow: 0 0 15px var(--theme-message-box-shadow);
    border: 1px solid var(--theme-color-2);
    text-align: center;
    max-width: 80%;
    box-sizing: border-box;
}

.powered-by-text {
    font-size: 0.7em;
    color: var(--theme-powered-by-color);
    margin-bottom: -10px;
}

.crimson-x-animated {
    display: inline-block;
    background-image: var(--theme-crimson-x-gradient);
    background-size: 600% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: colorFlow 5s linear infinite;
    -webkit-animation-timing-function: ease-in-out;
    text-decoration: none;
    font-weight: bold;
    font-size: 2.4em;
    line-height: 1;
    text-shadow: 0 0 5px rgba(255, 0, 0, 0.2);
}

.crimson-x-animated:hover {
    text-shadow: 0 0 10px rgba(255, 0, 0, 0.4), 0 0 20px rgba(255, 0, 0, 0.2);
}

@keyframes colorFlow {
  0% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
  100% {
    background-position: 0% 50%;
  }
}

#alarmControls input[type="datetime-local"] {
    margin: 10px auto;
}