* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Arial, sans-serif;
    background-color: #f0f0f0;
    transition: background-color 0.3s ease, color 0.3s ease;
}

.container {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    padding: 20px;
}

h1 {
    text-align: center;
    margin-bottom: 30px;
    font-size: 2.8em;
    color: #e0e0e0;  /* Light base color */
    text-transform: uppercase;
    letter-spacing: 3px;
    font-weight: 800;
    background-color: #f0f0f0;  /* Slightly lighter than body background */
    padding: 25px 0;
    text-shadow: 
        1px 1px 1px rgba(255,255,255,0.5),
        -1px -1px 1px rgba(0,0,0,0.3),
        -1px 1px 1px rgba(0,0,0,0.2);
    position: relative;
    border-bottom: 1px solid rgba(0,0,0,0.1);
    border-top: 1px solid rgba(255,255,255,0.5);
}

.periodic-table {
    display: grid;
    grid-template-columns: repeat(8, 100px);
    grid-gap: 4px;
    justify-content: center;
    margin: 0 auto;
    padding: 20px;
    border: 3px solid #e0e0e0;  /* Lighter border color */
    background-color: #f0f0f0;  /* Match body background */
    box-shadow: inset 0 0 10px rgba(0,0,0,0.1);  /* Inset shadow for depth */
}

.element {
    width: 100px;
    height: 100px;
    border: 2px solid #e0e0e0;  /* Lighter border color */
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    padding: 5px;
    cursor: pointer;
    box-shadow: inset 1px 1px 3px rgba(0,0,0,0.1);  /* Subtle inset shadow */
}

.element:hover {
    background-color: #e0e0e0;
}

.element .atomic-number {
    position: absolute;
    top: 5px;
    left: 5px;
    font-size: 12px;
}

.element .mass-number {
    position: absolute;
    bottom: 5px;
    left: 5px;
    font-size: 12px;
}

.element .symbol {
    font-size: 24px;
    font-weight: bold;
}

/* Hide the name div */
.element .name {
    display: none;
}

/* Update empty cell styles */
.empty {
    position: relative;
    cursor: default;
    background: transparent;
    border: none !important;
}

.empty::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
    border: none !important;
    z-index: 1; /* Add z-index */
}

/* Add pop-up hover effect with logo */
.empty:hover::after {
    content: '';
    background-image: url('./black_on_black_Shunks.png'); /* Make sure path is correct */
    background-size: 70% auto;
    background-position: center;
    background-repeat: no-repeat;
    opacity: 0;
    border: none !important;
    animation: popUp 0.3s ease forwards;
    z-index: 2; /* Ensure hover state appears above */
}

/* Pop-up animation */
@keyframes popUp {
    0% {
        opacity: 0;
        transform: scale(0) translateY(20px);
    }
    50% {
        transform: scale(1.2) translateY(-5px);
    }
    100% {
        opacity: 0.7;
        transform: scale(1) translateY(0);
    }
}

/* Remove any dark mode borders */
body.dark-mode .empty::after {
    border: none !important;
}

/* Modal styles */
.modal {
    display: none;
    position: fixed;
    z-index: 1;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.3); /* More transparent background */
}

.modal-content {
    background-color: #2a2a2a;
    margin: 5% auto;
    padding: 20px;
    border: 1px solid #888;
    width: 90%;  /* Increased from default */
    max-width: 800px;  /* Added max-width for larger screens */
    border-radius: 10px;
    position: relative;
    color: white;
}

.element-details {
    display: flex;
    flex-direction: column;  /* Stack items vertically */
    gap: 20px;
    margin: 20px auto;
    align-items: center;
    max-width: 800px;
}

.element-gif {
    width: 200px;  /* Reduced from 300px */
    border-radius: 10px;
    overflow: hidden;
    background: rgba(0,0,0,0.1);
    margin: 0 auto;
}

.element-gif img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 10px;  /* Match container's border radius */
}

.isotope-info {
    width: 100%;  /* Full width for table container */
}

.isotope-table {
    margin: 0 auto;
    width: 100%;
    border-collapse: collapse;
}

.energy-total {
    text-align: center;
    padding: 15px;
    margin-top: 20px;
}

.modal-content h2 {
    text-align: center;
    margin-bottom: 20px;
    color: black !important;  /* Force black color */
    border: none !important;  /* Remove any borders */
    background: none !important;  /* Remove any background */
    text-shadow: none !important;  /* Remove any text shadows */
}

.isotope-table th,
.isotope-table td {
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 8px;
    text-align: left;
    color: black; /* Ensure text remains readable */
}

.isotope-table th {
    background-color: rgba(0, 0, 0, 0.1);
}

.close {
    position: absolute;
    right: 20px;
    top: 15px;
    width: 32px;
    height: 32px;
    background: #2fe0d2;
    color: white;
    border: none;
    border-radius: 50%;  /* Makes it circular */
    font-size: 24px;
    line-height: 24px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.close:hover {
    background: #41a0b1;
    transform: rotate(90deg);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
}

.close:active {
    transform: rotate(90deg) scale(0.95);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

.close svg {
    width: 24px;
    height: 24px;
    fill: white;  /* Makes the X icon white */
}

/* Ensure proper positioning in modal */
.modal-content {
    position: relative;  /* For absolute positioning of close button */
}

#isotopes {
    margin-top: 20px;
    max-height: 70vh;
    overflow-y: auto;
}

h2 {
    text-align: center;
    font-size: 2em;
    margin: 20px 0;
    color: #e0e0e0;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-weight: bold;
    text-shadow: 
        1px 1px 1px rgba(255,255,255,0.5),
        -1px -1px 1px rgba(0,0,0,0.3);
    padding: 15px 0;
}

.beta-link {
    display: block;
    text-align: center;
    margin: 20px 0;
    color: #333;
    text-decoration: none;
}

.beta-link:hover {
    text-decoration: underline;
}

.page-number {
    display: inline-block;
    padding: 10px 30px;
    margin: 20px;
    background-color: #4CAF50;
    color: white;
    text-decoration: none;
    border-radius: 5px;
    font-size: 18px;
    font-weight: bold;
    transition: background-color 0.3s;
}

.page-number:hover {
    background-color: #45a049;
}

.menu-toggle {
    position: fixed;
    top: 20px;
    left: 20px;
    z-index: 1000;
    cursor: pointer;
}

.hamburger {
    font-size: 30px;
    color: #4CAF50;
}

.slide-menu {
    position: fixed;
    top: 0;
    left: -250px;
    width: 250px;
    height: 100%;
    background-color: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(5px);
    transition: left 0.3s ease;
    z-index: 1001;
    box-shadow: 2px 0 5px rgba(0,0,0,0.1);
}

.slide-menu.active {
    left: 0;
}

.menu-close {
    position: absolute;
    top: 10px;
    right: 20px;
    font-size: 24px;
    cursor: pointer;
    color: #333;
}

.menu-content {
    padding: 60px 20px;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.menu-item {
    display: block;
    padding: 10px 20px;
    background-color: #4CAF50;
    color: white;
    text-decoration: none;
    border-radius: 5px;
    font-size: 18px;
    font-weight: bold;
    transition: background-color 0.3s;
    text-align: center;
}

.menu-item:hover {
    background-color: #45a049;
}

.menu-item.otom {
    background-color: #FF69B4;
}

.menu-item.otom:hover {
    background-color: #FF1493;
}

.menu-item.alpha {
    background-color: #4169E1; /* Royal Blue */
}

.menu-item.alpha:hover {
    background-color: #1E90FF;
}

.menu-item.beta {
    background-color: #4CAF50;
}

.menu-item.beta:hover {
    background-color: #458ba0;
}

.menu-item.roadmap {
    background-color: #75ada6; /* Purple */
}

.menu-item.roadmap:hover {
    background-color: #5883b4;
}

.menu-item.faucet {
    background-color: #2e2e2d; /* Gold color */
    position: relative;
}

.menu-item.faucet:hover {
    background-color: #6d6d6b;
}

.menu-item.market {
    background-color: #6345b6; /* Green color - feel free to change */
    position: relative;
}

.menu-item.market:hover {
    background-color: #2485c5;
}

.menu-item.reaction {
    background-color: #020202; /* Purple color */
    position: relative;
}

.menu-item.reaction:hover {
    background-color: #626063;
}

.menu-item.reaction-log {
    background-color: #4CAF50; /* Green color */
    position: relative;
}

.menu-item.reaction-log:hover {
    background-color: #45a049;
}

.menu-item .subtitle {
    display: block;
    font-size: 12px;
    opacity: 0.8;
    font-weight: normal;
    margin-top: 4px;
}

/* Style menu section labels with borders */
.menu-divider {
    text-align: center;
    margin: 15px 0;
}

.menu-divider span {
    border: 1px solid black;
    padding: 5px 15px;
    border-radius: 4px;
    display: inline-block;
}

/* Remove all divider lines */
.menu-divider::before {
    display: none;
}

.slide-menu hr {
    display: none;
}

/* Dark mode */
body.dark-mode .menu-divider span {
    border-color: black;
}

.roadmap-modal .modal-content {
    max-width: 900px;
    max-height: 85vh;
    overflow-y: auto;
    background: rgba(30, 30, 40, 0.85);
    color: white;
    padding: 30px;
    box-shadow: 0 0 20px rgba(0,0,0,0.3);
}

.roadmap-steps {
    padding: 20px;
}

.roadmap-steps section {
    margin-bottom: 40px;
    background: rgba(255, 255, 255, 0.1);
    padding: 20px;
    border-radius: 15px;
    backdrop-filter: blur(5px);
}

.roadmap-steps h2 {
    color: #fff;
    font-size: 28px;
    margin-bottom: 25px;
    text-align: center;
    text-shadow: 0 0 10px rgba(255,255,255,0.3);
}

.roadmap-steps h3 {
    color: #fff;
    font-size: 22px;
    border-bottom: 2px solid rgba(255,255,255,0.2);
    padding-bottom: 10px;
    margin-bottom: 20px;
    text-shadow: 0 0 5px rgba(255,255,255,0.2);
}

.roadmap-steps p {
    color: rgba(255,255,255,0.8);
    margin-bottom: 15px;
    font-size: 16px;
}

.mineable-list, .direct-combinations, .advanced-combinations {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 15px;
    padding: 15px;
}

.isotope-item {
    background: rgba(255,255,255,0.1);
    padding: 15px;
    border-radius: 10px;
    border: 1px solid rgba(255,255,255,0.2);
    transition: transform 0.2s, box-shadow 0.2s;
    backdrop-filter: blur(5px);
}

.isotope-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
    background: rgba(255,255,255,0.15);
}

.isotope-item div:first-child {
    font-size: 18px;
    font-weight: bold;
    color: #fff;
    margin-bottom: 8px;
}

.isotope-item div:nth-child(2) {
    color: rgba(255,255,255,0.9);
    font-size: 14px;
}

.energy-cost {
    font-size: 14px;
    color: #8FD694;
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px solid rgba(255,255,255,0.1);
}

/* Custom scrollbar for the modal */
.roadmap-modal .modal-content::-webkit-scrollbar {
    width: 10px;
}

.roadmap-modal .modal-content::-webkit-scrollbar-track {
    background: rgba(255,255,255,0.1);
    border-radius: 5px;
}

.roadmap-modal .modal-content::-webkit-scrollbar-thumb {
    background: rgba(255,255,255,0.3);
    border-radius: 5px;
}

.roadmap-modal .modal-content::-webkit-scrollbar-thumb:hover {
    background: rgba(255,255,255,0.4);
}

/* Close button styling */
.roadmap-modal .close {
    color: white;
    opacity: 0.7;
    font-size: 28px;
    transition: opacity 0.2s;
}

.roadmap-modal .close:hover {
    opacity: 1;
}

.section-content {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 15px;
    padding: 15px;
}

.usage-count {
    font-size: 14px;
    color: #8FD694;
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px solid rgba(255,255,255,0.1);
    font-style: italic;
}

.user-input-btn {
    display: block;
    margin: 5px auto;
    padding: 8px 15px;
    background: #4CAF50;
    color: white;
    border: none;
    border-radius: 6px;
    text-align: center;
    transition: background-color 0.2s;
    cursor: pointer;
    font-size: 14px;
    width: calc(100% - 40px);
    max-width: 200px;
}

.user-input-btn:hover {
    background: #45a049;
}

.user-input-btn .subtitle {
    font-size: 12px;
    opacity: 0.8;
    margin-top: 4px;
}

.submit-btn {
    display: block;
    width: 100%;
    padding: 12px 20px;
    background: #2fe0d2; /* Purple to match your theme */
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 20px;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.submit-btn:hover {
    background: #71c2c2;
    transform: translateY(-2px);
    box-shadow: 0 6px 8px rgba(0, 0, 0, 0.2);
}

.submit-btn:active {
    transform: translateY(1px);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.close-btn {
    position: absolute;
    right: 20px;
    top: 15px;
    width: 32px;
    height: 32px;
    background: #2fe0d2;
    color: white;
    border: none;
    border-radius: 50%;
    font-size: 24px;
    line-height: 24px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.close-btn:hover {
    background: #41a0b1;
    transform: rotate(90deg);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
}

.close-btn:active {
    transform: rotate(90deg) scale(0.95);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

.view-issue {
    display: inline-block;
    padding: 6px 12px;
    background: #2fe0d2;
    color: white;
    text-decoration: none;
    border-radius: 4px;
    font-size: 14px;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.view-issue:hover {
    background: #4297a7;
    transform: translateX(2px);
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.2);
}

.view-issue:active {
    transform: translateX(1px);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

/* Dark mode toggle button */
.dark-mode-toggle {
    position: fixed;
    top: 20px;
    right: 80px; /* Position it to the left of the menu button */
    z-index: 1000;
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    padding: 8px;
    border-radius: 50%;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(5px);
}

.dark-mode-toggle:hover {
    transform: scale(1.1);
    background: rgba(255, 255, 255, 0.2);
}

.dark-mode-toggle .moon {
    display: none;
}

/* Dark mode classes */
body.dark-mode {
    background-color: #2a2a2a;  /* Match menu background */
    color: #ffffff;
}

body.dark-mode .element {
    background-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .atomic-number,
body.dark-mode .symbol,
body.dark-mode .mass-number,
body.dark-mode .name {
    color: black;  /* Keep text black */
}

/* Dark mode specific styles */
.dark-mode .dark-mode-toggle .sun {
    display: none;
}

.dark-mode .dark-mode-toggle .moon {
    display: inline;
}

/* Dark mode styles for headings and periodic table */
body.dark-mode h1,
body.dark-mode h2 {
    color: #3f3d3d;  /* Light gray, easily visible */
    text-shadow: 
        1px 1px 1px rgba(0,0,0,0.5),
        -1px -1px 1px rgba(255,255,255,0.1),
        -1px 1px 1px rgba(255,255,255,0.1);
    background-color: #2a2a2a;  /* Match periodic table background */
    border-bottom: 1px solid rgba(255,255,255,0.1);
    border-top: 1px solid rgba(0,0,0,0.3);
}

body.dark-mode .periodic-table {
    border: 3px solid #333333;  /* Darker border */
    background-color: #2a2a2a;  /* Darker background */
    box-shadow: inset 0 0 10px rgba(0,0,0,0.3);
}

/* Update empty grid spaces in dark mode */
body.dark-mode .empty::after {
    border: 1px dashed #333333;  /* Darker dashed lines */
    opacity: 0.3;
}

/* Update element borders in dark mode */
body.dark-mode .element {
    border: 2px solid #333333;  /* Darker border */
    box-shadow: inset 1px 1px 3px rgba(0,0,0,0.2);
}

body.dark-mode .element:hover {
    background-color: #2a2a2a;  /* Darker hover state */
}

/* Dark mode styles for the Periodic Table heading */
body.dark-mode h1 {
    color: #e0e0e0;  /* Light gray */
    text-shadow: 
        1px 1px 1px rgba(0,0,0,0.5),
        -1px -1px 1px rgba(255,255,255,0.1),
        -1px 1px 1px rgba(255,255,255,0.1);
}

/* Ensure element hover state doesn't affect text color */
body.dark-mode .element:hover .atomic-number,
body.dark-mode .element:hover .symbol,
body.dark-mode .element:hover .mass-number,
body.dark-mode .element:hover .name {
    color: black;  /* Maintain black text on hover */
}

/* Update the main title text colors in dark mode */
body.dark-mode h1 {
    color: #292929;  /* Light gray, easily visible */
    text-shadow: 
        1px 1px 1px rgba(0,0,0,0.5),
        -1px -1px 1px rgba(255,255,255,0.1),
        -1px 1px 1px rgba(255,255,255,0.1);
}

/* Specific style for the "Periodic Table of Otoms" text */
body.dark-mode h1:not(.modal h1) {
    color: #2e2d2d;  /* Light gray */
    text-shadow: 
        1px 1px 1px rgba(0,0,0,0.5),
        -1px -1px 1px rgba(255,255,255,0.1),
        -1px 1px 1px rgba(255,255,255,0.1);
}

/* Ensure the text itself is visible */
body.dark-mode h1 span,
body.dark-mode h2 span,
body.dark-mode .title-text {
    color: #2b2a2a;  /* Light gray */
}

/* Specific style for the main titles */
body.dark-mode .periodic-title,
body.dark-mode .universe-title {
    color: #353232;  /* Light gray */
    text-shadow: 
        1px 1px 1px rgba(0,0,0,0.5),
        -1px -1px 1px rgba(255,255,255,0.1),
        -1px 1px 1px rgba(255,255,255,0.1);
}

/* Update menu background in dark mode to match */
body.dark-mode .slide-menu {
    background-color: #2a2a2a;
    backdrop-filter: blur(5px);
}

/* Update modal background in dark mode */
body.dark-mode .modal-content {
    background-color: #2a2a2a;
}

/* Ensure consistent background for other elements */
body.dark-mode .periodic-table {
    background-color: #2a2a2a;
}

body.dark-mode h1,
body.dark-mode h2 {
    background-color: #2a2a2a;
}

/* Update isotope usage table text colors */
.isotope-usage-table {
    width: 100%;
    border-collapse: collapse;
    background: #2a2a2a;
    border-radius: 10px;
    overflow: hidden;
    color: white;  /* Set default text color to white */
}

.isotope-usage-table th,
.isotope-usage-table td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #333;
    color: white;  /* Ensure all text is white */
}

.isotope-usage-table th {
    background: #333;
    color: #4CAF50;  /* Keep headers green */
    font-weight: bold;
}

/* Ensure text stays white on hover */
.isotope-usage-table tr:hover {
    background: #333;
    color: white;
}

/* Keep modal headers consistent in dark mode */
body.dark-mode .modal-content h2,
body.dark-mode .isotope-table th {
    color: inherit;  /* This will keep the original color */
    background-color: transparent;  /* Keep original background */
}

/* Ensure modal content stays consistent in dark mode */
body.dark-mode .modal-content {
    color: inherit;  /* Keep original text color */
}

/* Specifically target the table headers in the modal */
body.dark-mode .isotope-table th {
    background-color: #333;  /* Keep the original header background */
    color: #4CAF50;  /* Keep the original green color */
}

/* Specifically remove dark mode effects */
body.dark-mode .modal-content h2 {
    color: black !important;
    border: none !important;
    background: none !important;
    text-shadow: none !important;
}

/* Remove borders from main page headers */
h1, h2 {
    border: none !important;
    background: none !important;
}

/* Also ensure dark mode doesn't add borders */
body.dark-mode h1,
body.dark-mode h2 {
    border: none !important;
    background: none !important;
}

/* Keep other header styles but remove borders */
.periodic-title,
.universe-title {
    border: none !important;
    background: none !important;
}

/* Style for menu dividers */
.menu-divider {
    border: none !important;
}

.menu-divider span {
    border: none !important;
    background: none !important;
}

/* Dark mode specific styles */
body.dark-mode .menu-divider {
    border: none !important;
}

body.dark-mode .menu-divider span {
    border: none !important;
    background: none !important;
}

/* Custom checkbox styling */
.isotope-table input[type="checkbox"] {
    appearance: none;
    -webkit-appearance: none;
    width: 20px;
    height: 20px;
    border: 2px solid #4CAF50;
    border-radius: 4px;
    outline: none;
    cursor: pointer;
    position: relative;
    background: transparent;
    transition: all 0.2s ease;
}

/* Checkbox hover effect */
.isotope-table input[type="checkbox"]:hover {
    border-color: #45a049;
    box-shadow: 0 0 5px rgba(76, 175, 80, 0.3);
}

/* Checkbox checked state */
.isotope-table input[type="checkbox"]:checked {
    background-color: #4CAF50;
    border-color: #4CAF50;
}

/* Checkmark symbol */
.isotope-table input[type="checkbox"]:checked::after {
    content: "✓";
    color: white;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 14px;
    font-weight: bold;
}

/* Dark mode adjustments */
body.dark-mode .isotope-table input[type="checkbox"] {
    border-color: #45a049;
}

body.dark-mode .isotope-table input[type="checkbox"]:checked {
    background-color: #45a049;
}

/* Style for completed elements */
.element.completed {
    position: relative;  /* For checkmark positioning */
}

.element.completed::before {
    content: "✓";
    position: absolute;
    top: 2px;
    right: 2px;
    color: #00ff00;
    opacity: 0.7;  /* Makes it translucent */
    font-weight: bold;
    font-size: 16px;
    text-shadow: 
        1px 1px 0 rgba(0, 0, 0, 0.7),
        -1px -1px 0 rgba(0, 0, 0, 0.7),
        1px -1px 0 rgba(0, 0, 0, 0.7),
        -1px 1px 0 rgba(0, 0, 0, 0.7);
    z-index: 1;
}

/* Optional hover effect to make it more visible on hover */
.element.completed:hover::before {
    opacity: 1;
    transition: opacity 0.2s ease;
}

/* Dark mode adjustment */
body.dark-mode .element.completed::before {
    color: #4CAF50;
}

.progress-tracker {
    text-align: center;
    padding: 20px;
    margin: 20px auto;
    max-width: 200px;
}

.progress-circle {
    position: relative;
    width: 100%;
}

.progress-circle svg {
    transform: rotate(-90deg);
    width: 100%;
}

.progress-circle path {
    stroke-linecap: round;
}

.progress-circle path.progress {
    stroke-dasharray: 0, 100;
    transition: stroke-dasharray 0.5s ease;
}

.progress-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
}

.progress-text .percentage {
    display: block;
    font-size: 24px;
    font-weight: bold;
    color: #4CAF50;
}

.progress-text .label {
    display: block;
    font-size: 12px;
    margin-top: 5px;
}

/* Dark mode adjustments */
body.dark-mode .progress-circle path.progress {
    stroke: #45a049;
}

body.dark-mode .progress-text .percentage {
    color: #45a049;
}

.reaction-form {
    width: 100%;
    max-width: 600px;  /* Added max-width */
    margin: 0 auto;  /* Center the form */
    padding: 20px 0;
}

.isotope-inputs {
    display: flex;
    flex-direction: column;
    gap: 10px;
    width: 100%;
}

.isotope-input {
    width: 100%;
    padding: 12px;
    border: 1px solid #444;
    border-radius: 6px;
    background: #333;
    color: white;
}

.simulate-btn {
    display: block;  /* Makes the button a block element */
    margin: 20px auto;  /* Centers the button with auto margins */
    background: #4CAF50;
    color: white;
    padding: 12px 24px;  /* Added more horizontal padding */
    border: none;
    border-radius: 6px;
    font-size: 16px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    width: fit-content;  /* Makes the button width fit its content */
    min-width: 200px;  /* Minimum width for the button */
}

.simulate-btn:hover {
    background: #45a049;
}

.reaction-result {
    margin-top: 20px;
    padding: 15px;
    border-radius: 6px;
    text-align: center;
}

.reaction-result .error {
    color: #f44336;
    font-weight: bold;
}

.reaction-result .success {
    color: #4CAF50;
    font-weight: bold;
}

/* Dark mode adjustments */
body.dark-mode .modal-content {
    background-color: #333;
    color: #fff;
}

body.dark-mode .isotope-input {
    background-color: #444;
    border-color: #555;
    color: #fff;
}

body.dark-mode .isotope-input::placeholder {
    color: #888;
}

body.dark-mode .close {
    color: #fff;
}

body.dark-mode .close:hover {
    color: #ddd;
}

.reaction-option {
    width: 100%;
    margin-bottom: 15px;
}

.reaction-header {
    margin-bottom: 10px;
}

.reaction-equation {
    font-size: 1.2em;
    color: #4CAF50;
    font-weight: bold;
}

.reaction-details {
    padding: 10px;
    background: rgba(0,0,0,0.2);
    border-radius: 4px;
}

.reaction-type {
    color: #FFA726;
    font-style: italic;
    margin-bottom: 10px;
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.energy-details {
    color: #90CAF9;
}

.energy-line {
    display: flex;
    justify-content: space-between;
    margin: 5px 0;
}

.energy-label {
    color: #90CAF9;
    opacity: 0.8;
}

.energy-value {
    font-weight: bold;
}

.error {
    color: #ff6b6b;
    padding: 15px;
    background: rgba(255,107,107,0.1);
    border-radius: 8px;
    text-align: center;
}

.success {
    padding: 15px;
}

/* Reaction Results Styling */
.reactions-container {
    width: 100%;
    max-width: 700px;  /* Added max-width */
    margin: 0 auto;  /* Center the results */
    padding: 20px 0;
}

.results-header {
    color: #4CAF50;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid #4CAF50;
}

.reaction-item {
    background: rgba(0, 0, 0, 0.05);
    border-radius: 8px;
    padding: 15px;
    margin: 10px 0;
}

.reaction-equation {
    font-size: 1.1em;
    margin-bottom: 10px;
}

.arrow {
    color: #4CAF50;
    margin: 0 10px;
}

.reaction-details {
    display: flex;
    justify-content: space-between;
    font-size: 0.9em;
    color: #666;
}

.no-result {
    color: #ff4444;
    text-align: center;
    padding: 20px;
}

.reaction-type {
    text-transform: capitalize;
}

/* Add these styles to your existing CSS */
.loader-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

/* Replace existing loader styles with these new styles */
.loader {
    width: 120px;
    height: 120px;
    position: relative;
}

/* First element */
.element1 {
    width: 30px;
    height: 30px;
    background: #4CAF50;
    border-radius: 50%;
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    animation: moveRight 2s infinite;
}

.element1::before,
.element1::after {
    content: '';
    position: absolute;
    width: 40px;
    height: 40px;
    border: 2px solid rgba(76, 175, 80, 0.3);
    border-radius: 50%;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    animation: orbit 1s infinite linear;
}

.element1::after {
    width: 35px;
    height: 35px;
    animation: orbit 0.8s infinite linear reverse;
}

/* Second element */
.element2 {
    width: 30px;
    height: 30px;
    background: #90CAF9;
    border-radius: 50%;
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    animation: moveLeft 2s infinite;
}

.element2::before,
.element2::after {
    content: '';
    position: absolute;
    width: 40px;
    height: 40px;
    border: 2px solid rgba(144, 202, 249, 0.3);
    border-radius: 50%;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    animation: orbit 1s infinite linear;
}

.element2::after {
    width: 35px;
    height: 35px;
    animation: orbit 0.8s infinite linear reverse;
}

/* Result element */
.result {
    width: 40px;
    height: 40px;
    background: #FFA726;
    border-radius: 50%;
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%) scale(0);
    animation: appear 2s infinite;
}

.result::before,
.result::after {
    content: '';
    position: absolute;
    width: 55px;
    height: 55px;
    border: 2px solid rgba(255, 167, 38, 0.3);
    border-radius: 50%;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    animation: orbit 1s infinite linear;
}

.result::after {
    width: 48px;
    height: 48px;
    animation: orbit 0.8s infinite linear reverse;
}

@keyframes moveRight {
    0%, 100% { left: 0; opacity: 1; }
    45% { left: 35px; opacity: 1; }
    50% { left: 35px; opacity: 0; }
    51% { left: 0; opacity: 0; }
    55% { left: 0; opacity: 1; }
}

@keyframes moveLeft {
    0%, 100% { right: 0; opacity: 1; }
    45% { right: 35px; opacity: 1; }
    50% { right: 35px; opacity: 0; }
    51% { right: 0; opacity: 0; }
    55% { right: 0; opacity: 1; }
}

@keyframes appear {
    0%, 45% { transform: translate(-50%, -50%) scale(0); opacity: 0; }
    50% { transform: translate(-50%, -50%) scale(1.2); opacity: 1; }
    55% { transform: translate(-50%, -50%) scale(1); opacity: 1; }
    90% { transform: translate(-50%, -50%) scale(1); opacity: 1; }
    100% { transform: translate(-50%, -50%) scale(0); opacity: 0; }
}

@keyframes orbit {
    0% { transform: translate(-50%, -50%) rotate(0deg); }
    100% { transform: translate(-50%, -50%) rotate(360deg); }
}

/* Dark mode adjustments */
#reactionLogModal.dark-mode .element1 {
    background: #45a049;
}

#reactionLogModal.dark-mode .element1::before,
#reactionLogModal.dark-mode .element1::after {
    border-color: rgba(69, 160, 73, 0.3);
}

#reactionLogModal.dark-mode .element2 {
    background: #64B5F6;
}

#reactionLogModal.dark-mode .element2::before,
#reactionLogModal.dark-mode .element2::after {
    border-color: rgba(100, 181, 246, 0.3);
}

#reactionLogModal.dark-mode .result {
    background: #FFA726;
}

#reactionLogModal.dark-mode .result::before,
#reactionLogModal.dark-mode .result::after {
    border-color: rgba(255, 167, 38, 0.3);
}

.sponsor-section {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    margin: 40px auto 20px auto;
    padding: 10px 0;
    width: 100%; /* Ensure full width of menu */
    text-align: center; /* Center all content */
}

.sponsor-title {
    color: #e0e0e0;
    font-size: 0.9em;
    margin-bottom: 15px;
    text-transform: uppercase;
    letter-spacing: 2px;
    width: 100%; /* Full width for text centering */
}

.sponsor-logo {
    width: 110px;
    height: 110px;
    animation: rotate 10s linear infinite;
    transition: transform 0.3s ease;
    display: block; /* Ensure block display */
    margin: 0 auto; /* Center the image */
}

.rotating {
    animation: rotate 10s linear infinite; /* Add animation to specific class */
}

.sponsor-logo:hover {
    transform: scale(1.1);
    animation-play-state: paused;
}

@keyframes rotate {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Light mode - slightly darker than white background */
.progress-background {
    stroke: #e0e0e0;  /* slightly darker than white */
}

/* Dark mode - slightly darker than dark background */
body.dark-mode .progress-background {
    stroke: #222222;  /* slightly darker than #2a2a2a */
}

/* BLOB Fee Tracker Styles */
.blob-fee-container {
    margin-top: 20px;
    text-align: center;
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

#blob-fee {
    display: inline-block;
    transition: all 0.3s ease;
}

#blob-fee .subtitle {
    font-size: 0.8em;
    opacity: 0.8;
    margin-top: 2px;
}

/* Dark mode support */
body.dark-mode #blob-fee {
    color: #fff;
}

body.dark-mode #blob-fee .subtitle {
    color: #aaa;
}