@import url('https://fonts.googleapis.com/css2?family=Orbitron:wght@400;700&display=swap');

body {
    font-family: 'Orbitron', sans-serif;
    background: linear-gradient(135deg, #080808, #111);
    color: #fff;
    padding: 40px;
    text-align: center;
    overflow: auto;
    transition: background 0.5s ease-in-out, color 0.5s ease-in-out;
}

/* Text Box Styling */
.text-box {
    max-width: 900px;
    margin: 40px auto;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 20px 30px;
    box-shadow: 0px 5px 15px rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(8px);
    text-align: left;
    transition: 0.3s ease-in-out;
}

/* Citation Styling */
.citation {
    display: inline-block;
    text-decoration: none;
    background: rgba(0, 255, 255, 0.2);
    border: 1px solid rgba(0, 255, 255, 0.8);
    border-radius: 10px;
    padding: 5px 10px;
    font-size: 0.5em;
    font-weight: bold;
    color: cyan;
    cursor: pointer;
    position: relative;
    transition: all 0.4s ease-in-out;
    animation: flicker 1.5s infinite alternate;
}

/* Hover - Glow Effect */
.citation:hover {
    background: rgba(0, 255, 255, 0.4);
    box-shadow: 0 0 20px rgba(0, 255, 255, 0.8);
    transform: scale(1.3);
}

/* Tooltip Styling */
.citation::after {
    content: attr(data-tooltip);
    visibility: hidden;
    opacity: 0;
    background: rgba(0, 255, 255, 0.9);
    color: #000;
    text-align: center;
    padding: 10px;
    border-radius: 5px;
    position: absolute;
    bottom: 180%;
    left: 50%;
    transform: translateX(-50%) scale(0.9);
    font-size: 0.75em;
    white-space: nowrap;
    box-shadow: 0px 4px 15px rgba(0, 255, 255, 0.9);
    transition: opacity 0.3s ease-in-out, transform 0.3s ease-in-out;
}

/* Show Tooltip on Hover */
.citation:hover::after {
    visibility: visible;
    opacity: 1;
    transform: translateX(-50%) scale(1);
}

/* Background Effect */
.background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('https://source.unsplash.com/1600x900/?futuristic,technology') no-repeat center center/cover;
    opacity: 0.2;
    animation: backgroundMove 20s infinite linear;
}

@keyframes backgroundMove {
    from { background-position: 0% 0%; }
    to { background-position: 100% 100%; }
}

/* Flickering Effect */
@keyframes flicker {
    0% { opacity: 1; }
    50% { opacity: 0.8; }
    100% { opacity: 1; }
}

/* Slider Toggle Switch Styles */
.physical-switch {
  position: fixed;
  top: 20px;
  right: 20px;
  width: 80px;
  height: 40px;
  display: inline-block;
  margin: 10px; /* adjust as needed */
}

.physical-switch input {
  display: none;
}

.physical-switch label {
  display: block;
  width: 89%;
  height: 80%;
  background: #ccc;
  border-radius: 20px;
  cursor: pointer;
  position: relative;
  transition: background-color 0.3s ease-in-out;
}

.physical-switch label::after {
  content: '';
  position: absolute;
  width: 28px;
  height: 28px;
  background: white;
  border-radius: 50%;
  top: 2px;
  left: 2px;
  box-shadow: 0px 2px 5px rgba(0, 0, 0, 0.3);
  transition: transform 0.3s ease-in-out;
}

.physical-switch input:checked + label {
  background-color: #4caf50; /* Green when switched on */
}

.physical-switch input:checked + label::after {
  transform: translateX(40px); /* Moves the slider */
}

/* Light Mode (White Mode) */
.light-mode {
    background: linear-gradient(135deg, #f7f7f7, #ffffff);
    color: #333;
}

.light-mode .text-box {
    background: rgba(0, 0, 0, 0.1);
    box-shadow: 0px 5px 15px rgba(0, 0, 0, 0.1);
}

.light-mode .citation {
    background: rgba(0, 100, 255, 0.2);
    border-color: rgba(0, 100, 255, 0.6);
    color: #0044ff;
}

.light-mode .citation:hover {
    background: rgba(0, 100, 255, 0.4);
    box-shadow: 0 0 20px rgba(0, 100, 255, 0.8);
}