/* --- Global Variables & Resets --- */
:root {
    --bg-primary: #0a0a0f;
    --bg-secondary: #151520;
    --text-primary: #e0e0e0;
    --text-secondary: #a0a0b0;
    --accent-cyan: #00ffff;
    --accent-magenta: #ff00ff;
    --accent-yellow: #ffff00;
    --panel-bg: rgba(20, 20, 35, 0.7);
    --glow-color: var(--accent-cyan);
    --proton-color: #ff4136;
    --neutron-color: #0074d9;
    --electron-color: #2ecc40;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    overflow: hidden;
    height: 100vh;
    display: flex;
    flex-direction: column;
}

/* --- Futuristic Typography --- */
h1, h2, h3 {
    font-family: 'Orbitron', monospace;
    font-weight: 700;
}

h1 {
    font-size: 3.5rem;
    font-weight: 900;
    letter-spacing: 0.1em;
}

/* --- Animated Starfield Background --- */
.starfield {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

.star {
    position: absolute;
    background-color: white;
    border-radius: 50%;
    animation: twinkle 5s infinite;
}

@keyframes twinkle {
    0%, 100% { opacity: 0.3; transform: scale(1); }
    50% { opacity: 1; transform: scale(1.2); }
}

/* --- Glitch Text Effect --- */
.glitch {
    position: relative;
    color: var(--text-primary);
    text-shadow: 0 0 10px var(--glow-color);
}

.glitch::before,
.glitch::after {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--bg-primary);
    overflow: hidden;
}

.glitch::before {
    left: 2px;
    text-shadow: -2px 0 var(--accent-magenta);
    animation: glitch-anim-1 2s infinite linear alternate-reverse;
}

.glitch::after {
    left: -2px;
    text-shadow: -2px 0 var(--accent-cyan), 2px 2px var(--accent-yellow);
    animation: glitch-anim-2 2s infinite linear alternate-reverse;
}

@keyframes glitch-anim-1 {
    0% { clip-path: inset(40% 0 61% 0); }
    20% { clip-path: inset(92% 0 1% 0); }
    40% { clip-path: inset(43% 0 1% 0); }
    60% { clip-path: inset(25% 0 58% 0); }
    80% { clip-path: inset(54% 0 7% 0); }
    100% { clip-path: inset(58% 0 43% 0); }
}

@keyframes glitch-anim-2 {
    0% { clip-path: inset(25% 0 61% 0); }
    20% { clip-path: inset(52% 0 31% 0); }
    40% { clip-path: inset(13% 0 71% 0); }
    60% { clip-path: inset(65% 0 11% 0); }
    80% { clip-path: inset(84% 0 1% 0); }
    100% { clip-path: inset(45% 0 45% 0); }
}

/* --- Layout --- */
.main-header {
    text-align: center;
    padding: 1.5rem;
    background: linear-gradient(180deg, rgba(10,10,15,0.8) 0%, rgba(10,10,15,0) 100%);
    z-index: 10;
	
    margin: 0 auto;                 
    max-height: 100px;              
	
}





.main-header p {
    color: var(--text-secondary);
    font-family: 'Orbitron', sans-serif;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    font-size: 0.8rem;
    margin-top: 0.5rem;
}

#isotope-canvas {
    width: 90%;
    height: 80%;
    display: block;
}






.webgl-fallback {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    color: var(--text-secondary);
    padding: 2rem;
    background: var(--panel-bg);
    border-radius: 10px;
    border: 1px solid var(--accent-magenta);
}

.webgl-fallback i { font-size: 3rem; color: var(--accent-magenta); margin-bottom: 1rem; }











/* --- Control Panel (Glassmorphism) --- */
.control-panel {
    background: var(--panel-bg);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-left: 1px solid rgba(255, 255, 255, 0.1);
    padding: 2rem;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    overflow-y: auto;
	
	
	
	
	
}




/* Zoom Buttons */
.viewport-container button {
  margin: 0.5rem;
  padding: 0.6rem 1rem;
  border: none;
  border-radius: 6px;
  font-family: 'Orbitron', monospace;
  font-weight: 600;
  font-size: 0.85rem;
  text-transform: uppercase;
  cursor: pointer;
  transition: all 0.3s ease;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

/* Primary (Zoom In/Out) */
.viewport-container .btn-primary {
  background: linear-gradient(45deg, var(--accent-cyan), #00cccc);
  color: var(--bg-primary);
}
.viewport-container .btn-primary:hover {
  box-shadow: 0 0 15px var(--accent-cyan);
  transform: translateY(-2px) scale(1.05);
}

/* Secondary (Reset) */
.viewport-container .btn-secondary {
  background: transparent;
  color: var(--text-primary);
  border: 1px solid var(--text-secondary);
}
.viewport-container .btn-secondary:hover {
  border-color: var(--glow-color);
  color: var(--glow-color);
  box-shadow: 0 0 10px rgba(0, 255, 255, 0.3);
  transform: translateY(-2px) scale(1.05);
}

/* Icons inside buttons */
.viewport-container button i {
  font-size: 1rem;
  transition: transform 0.3s ease;
}
.viewport-container button:hover i {
  transform: scale(1.2);
}











#isotope-canvas {
  transform-origin: center center;
  transition: transform 0.3s ease;
}

.zoom-in {
  transform: scale(1.2);
}

.zoom-out {
  transform: scale(0.8);
}







.app-container {
  display: flex;          /* children side by side */
  flex-direction: row;    /* horizontal split */
  width: 100%;
  height: 90%;           /* optional, full viewport height */
  
  
    overflow-y: auto;
  
  
  
}










.panel-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding-bottom: 1rem;
}

.panel-header i { font-size: 1.5rem; color: var(--glow-color); }
.panel-header h2 { font-size: 1.2rem; color: var(--text-primary); }

/* --- Form Controls --- */
.control-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.select-wrapper {
    position: relative;
}

.neon-select {
    width: 100%;
    padding: 0.75rem 2.5rem 0.75rem 1rem;
    background-color: var(--bg-secondary);
    color: var(--text-primary);
    border: 1px solid rgba(0, 255, 255, 0.3);
    border-radius: 5px;
    font-family: 'Inter', sans-serif;
    font-size: 1rem;
    appearance: none;
    cursor: pointer;
    transition: all 0.3s ease;
}

.neon-select:hover, .neon-select:focus {
    border-color: var(--glow-color);
    box-shadow: 0 0 10px rgba(0, 255, 255, 0.5);
    outline: none;
}

.select-wrapper::after {
    content: '\25bc';
    position: absolute;
    top: 50%;
    right: 1rem;
    transform: translateY(-50%);
    pointer-events: none;
    color: var(--glow-color);
}

/* --- Info Card --- */
.info-card {
    background: rgba(30, 30, 50, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 1.5rem;
    transition: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.info-card.radioactive {
    border-color: var(--accent-magenta);
    box-shadow: 0 0 20px rgba(255, 0, 255, 0.4), inset 0 0 20px rgba(255, 0, 255, 0.1);
    animation: radioactive-pulse 2s infinite;
}

@keyframes radioactive-pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.02); }
}

.info-card h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    color: var(--glow-color);
}

.isotope-meta {
    display: flex;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.tag {
    background: rgba(0, 255, 255, 0.1);
    color: var(--accent-cyan);
    padding: 0.25rem 0.75rem;
    border-radius: 15px;
    font-size: 0.8rem;
    font-family: 'Orbitron', monospace;
    border: 1px solid rgba(0, 255, 255, 0.3);
}

.tag.radioactive-tag {
    background: rgba(255, 0, 255, 0.1);
    color: var(--accent-magenta);
    border-color: rgba(255, 0, 255, 0.3);
}

.decay-info h4 { margin-top: 1rem; color: var(--text-secondary); }
.decay-info p { color: var(--accent-magenta); font-family: 'Orbitron', monospace; }













/* --- Buttons --- */
.action-buttons {
    display: flex;
    gap: 1rem;
}

.btn {
    flex-grow: 1;
    padding: 0.75rem 1rem;
    border: none;
    border-radius: 5px;
    font-family: 'Orbitron', monospace;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    text-transform: uppercase;
}

.btn-primary {
    background: linear-gradient(45deg, var(--accent-cyan), #00cccc);
    color: var(--bg-primary);
}

.btn-primary:hover {
    box-shadow: 0 0 15px var(--accent-cyan);
    transform: translateY(-2px);
}

.btn-secondary {
    background: transparent;
    color: var(--text-primary);
    border: 1px solid var(--text-secondary);
}

.btn-secondary:hover {
    border-color: var(--glow-color);
    color: var(--glow-color);
    box-shadow: 0 0 10px rgba(0, 255, 255, 0.3);
}






a.btn {
  text-decoration: none;       /* remove underline */
  display: inline-flex;        /* align icon + text */
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1.25rem;
  border-radius: 5px;
  font-family: 'Orbitron', monospace;
  font-weight: 600;
  font-size: 0.9rem;
  text-transform: uppercase;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn-primary {
  background: linear-gradient(45deg, var(--accent-cyan), #00cccc);
  color: var(--bg-primary);
}

.btn-primary:hover {
  box-shadow: 0 0 15px var(--accent-cyan);
  transform: translateY(-2px);
}
















/* --- QR Code Container --- */
.qr-code-container {
    margin-top: 1rem;
    padding: 1rem;
    background: white;
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.qr-code-container p {
    color: var(--bg-primary);
    font-size: 0.8rem;
    text-align: center;
}

/* --- Responsive Design --- */
@media (max-width: 900px) {
    .app-container {
        grid-template-columns: 1fr;
        grid-template-rows: 1fr auto;
    }
    .control-panel {
        border-left: none;
        border-top: 1px solid rgba(255, 255, 255, 0.1);
        padding: 1.5rem;
    }
    h1 { font-size: 0.5rem; }
    .main-header { padding: 0.5rem; }
    .main-header p { font-size: 0.7rem; }
}









/* --- Add these new styles to your existing styles.css --- */

/* --- Attractive Data Table --- */
.data-table {
    margin: 1rem 0;
    padding: 1rem;
    background: rgba(10, 10, 20, 0.4);
    border: 1px solid rgba(0, 255, 255, 0.2);
    border-radius: 8px;
    font-family: 'Orbitron', monospace;
}

.data-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.data-row:last-child {
    border-bottom: none;
}

.data-label {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.data-value {
    color: var(--accent-cyan);
    font-weight: 700;
    text-shadow: 0 0 5px var(--accent-cyan);
}





/* --- Description Article --- */
.description-article {
    margin-top: 1rem;
    max-height: 150px; /* Limit height for scrollability */
    overflow-y: auto;
    padding-right: 0.5rem;
}

.description-article::-webkit-scrollbar {
    width: 6px;
}

.description-article::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 3px;
}

.description-article::-webkit-scrollbar-thumb {
    background: var(--accent-cyan);
    border-radius: 3px;
}











/* --- Links Section Panel --- */
.links-section {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background: var(--panel-bg);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border-top: 1px solid rgba(0, 255, 255, 0.3);
    padding: 2rem;
    transform: translateY(100%);
    transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    z-index: 1000;
}








.links-section.visible {
    transform: translateY(0);
}






.close-btn {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: transparent;
    border: none;
    color: var(--text-secondary);
    font-size: 1.5rem;
    cursor: pointer;
    transition: color 0.3s ease;
}

.close-btn:hover {
    color: var(--accent-magenta);
}

.links-content h3 {
    text-align: center;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
    font-size: 1.5rem;
}

.social-icons {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
}

.social-icons a {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 50px;
    color: var(--text-primary);
    text-decoration: none;
    font-family: 'Inter', sans-serif;
    font-weight: 600;
    transition: all 0.3s ease;
}

.social-icons a:hover {
    background: var(--accent-cyan);
    color: var(--bg-primary);
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 255, 255, 0.4);
}

.social-icons i {
    font-size: 1.2rem;
}

/* --- Responsive Design Update for Links --- */
@media (max-width: 600px) {
    .social-icons a {
        padding: 0.5rem 1rem;
        font-size: 0.9rem;
    }
    .social-icons i {
        font-size: 1rem;
    }
}











/* --- Add these new styles to your existing styles.css --- */

/* --- Navigation Buttons Styling --- */
.action-buttons {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
}

.btn {
    padding: 0.6rem 0.8rem;
    font-size: 0.8rem;
}

.Table-page header {
    background: linear-gradient(180deg, rgba(10,10,15,0.8) 0%, rgba(10,10,15,0) 100%);
    padding: 1.5rem;
    text-align: center;
    position: relative;
    z-index: 10;
}

.Table-page header h1 {
    font-family: 'Orbitron', monospace;
    font-size: 2.5rem;
    margin: 0;
    color: var(--text-primary);
    text-shadow: 0 0 10px var(--glow-color);
}

.Table-page .container {
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 2rem;
}

.Table-page table {
    width: 100%;
    border-collapse: collapse;
    background: var(--panel-bg);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.Table-page th, .Table-page td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.Table-page th {
    background: rgba(0, 255, 255, 0.1);
    color: var(--accent-cyan);
    font-family: 'Orbitron', monospace;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    position: sticky;
    top: 0;
    z-index: 5;
}

.Table-page tr:hover {
    background: rgba(0, 255, 255, 0.05);
}

.Table-page tr:last-child td {
    border-bottom: none;
}

.Table-page .navigation-buttons {
    display: flex;
    justify-content: center;
    margin: 2rem 0;
}

.Table-page .btn-back {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 5px;
    font-family: 'Orbitron', monospace;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: linear-gradient(45deg, var(--accent-cyan), #00cccc);
    color: var(--bg-primary);
}

.Table-page .btn-back:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.Table-page footer {
    text-align: center;
    padding: 2rem;
    color: var(--text-secondary);
}

.Table-page footer a {
    color: var(--accent-cyan);
    text-decoration: none;
}

/* --- Responsive Design for Articles and Table Pages --- */
@media (max-width: 768px) {
    .articles-page .container {
        flex-direction: column;
    }
    
    .articles-page .toc {
        position: static;
        margin-bottom: 2rem;
    }
    
    .articles-page #articlesContent {
        grid-template-columns: 1fr;
    }
    
    .Table-page table {
        font-size: 0.8rem;
    }
    
    .Table-page th, .Table-page td {
        padding: 0.5rem;
    }
}



























/* --- Articles Page Styles --- */
.articles-page {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    margin: 0;
    padding: 0;
   overflow-y: auto;
    min-height: 100vh;
}







.articles-page .starfield {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

.articles-page header {
    background: linear-gradient(180deg, rgba(10,10,15,0.8) 0%, rgba(10,10,15,0) 100%);
    padding: 1.5rem;
    text-align: center;
    position: relative;
    z-index: 10;
}

.articles-page header h1 {
    font-family: 'Orbitron', monospace;
    font-size: 2.5rem;
    margin: 0;
    color: var(--text-primary);
    text-shadow: 0 0 10px var(--glow-color);
}

.articles-page .container {
    display: flex;
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 2rem;
    gap: 2rem;
}









.articles-page .toc {
    flex: 0 0 250px;
    background: var(--panel-bg);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: 10px;
    padding: 1.5rem;
    height: fit-content;
    position: sticky;
    top: 2rem;
}







.articles-page .toc h6 {
    font-family: 'Orbitron', monospace;
    font-size: 1.2rem;
    margin-top: 0;
    margin-bottom: 1rem;
    color: var(--accent-cyan);
    text-transform: uppercase;
    letter-spacing: 0.1em;
}









.articles-page .toc ul {
    list-style: none;
    padding: 0;
    margin: 0;
    columns: 4;          /* number of columns */
    column-gap: 1rem;    /* space between columns */
}

.articles-page .toc li {
    break-inside: avoid; /* prevent awkward breaks */
    margin-bottom: 0.5rem;
}






.articles-page .toc a {
    color: var(--accent-cyan);                  /* bright futuristic base color */
    text-decoration: none;
    display: block;
    padding: 0.6rem 0.8rem;
    border-radius: 8px;
    font-weight: 600;
    font-family: 'Orbitron', monospace;        /* futuristic font */
    background: rgba(0, 255, 255, 0.05);       /* subtle glowing background */
    border: 1px solid rgba(0, 255, 255, 0.2);  /* faint border glow */
    box-shadow: 0 0 8px rgba(0, 255, 255, 0.2);/* soft glow */
    transition: all 0.3s ease;
}

.articles-page .toc a:hover {
    background: rgba(0, 255, 255, 0.2);
    color: #fff;                               /* invert for clarity */
    transform: scale(1.05) translateY(-2px);   /* hover lift */
    box-shadow: 0 0 15px rgba(0, 255, 255, 0.6),
                0 0 30px rgba(255, 0, 255, 0.3); /* cyan + magenta glow */
}












.articles-page .content {
    flex: 1;
}

.articles-page #articlesContent {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(500px, 1fr));
    gap: 2rem;
}

.articles-page article {
    background: var(--panel-bg);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: 10px;
    padding: 1.5rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.articles-page article:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
    border-color: var(--accent-cyan);
}

.articles-page article h4 {
    font-family: 'Orbitron', monospace;
    color: var(--accent-cyan);
    margin-top: 0;
    margin-bottom: 1rem;
}

.articles-page article h5 {
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.articles-page article h7, .articles-page article h8 {
    color: var(--text-primary);
    margin-bottom: 1rem;
    line-height: 1.6;
}

.articles-page article pre {
    background: rgba(0, 0, 0, 0.3);
    padding: 1rem;
    border-radius: 5px;
    overflow-x: auto;
    margin: 1rem 0;
}

.articles-page article code {
    color: var(--accent-yellow);
    font-family: 'Courier New', monospace;
}

.articles-page .references {
    margin-top: 2rem;
    background: var(--panel-bg);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: 10px;
    padding: 1.5rem;
}

.articles-page .references ul {
    list-style: none;
    padding: 0;
}

.articles-page .references li {
    margin-bottom: 0.5rem;
    padding-left: 1.5rem;
    position: relative;
}

.articles-page .references li:before {
    content: "▶";
    position: absolute;
    left: 0;
    color: var(--accent-cyan);
}

.articles-page .navigation-buttons {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin: 2rem 0;
}

.articles-page .btn-back, .articles-page .btn-Table {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 5px;
    font-family: 'Orbitron', monospace;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.articles-page .btn-back {
    background: linear-gradient(45deg, var(--accent-cyan), #00cccc);
    color: var(--bg-primary);
}

.articles-page .btn-Table {
    background: linear-gradient(45deg, var(--accent-magenta), #cc00cc);
    color: var(--bg-primary);
}

.articles-page .btn-back:hover, .articles-page .btn-Table:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.articles-page footer {
    text-align: center;
    padding: 2rem;
    color: var(--text-secondary);
}

.articles-page footer a {
    color: var(--accent-cyan);
    text-decoration: none;
}

/* --- Table Page Styles --- */
.Table-page {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    margin: 0;
    padding: 0;
}

.Table-page .starfield {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}
