/* Game of Life - Neural Network Predictor Stylesheet (Nature Scientific Style) */

:root {
    --bg-primary: #2a2d2d;
    --bg-panel-dark: #1f2020;
    --bg-panel-light: #f8f9fa;
    --bg-cream: #fefefe;
    --bg-accent-light: #f0f2f5;
    --bg-accent-dark: #404142;
    
    /* Control panel colors (dark theme) */
    --text-panel-primary: #ffffff;
    --text-panel-secondary: #e0e0e0;
    --text-panel-muted: #b8b8b8;
    
    /* Display area colors (light theme) */
    --text-display-primary: #1a1a1a;
    --text-display-secondary: #424242;
    --text-display-muted: #6b6b6b;
    
    /* Title highlight color */
    --title-highlight: #8b4513;
    --title-highlight-light: #a0522d;
    
    /* Light blue for grid sizes and info */
    --light-blue: #87ceeb;
    --light-blue-dark: #5f9ea0;
    
    /* Nature journal inspired colors */
    --nature-blue: #0073e6;
    --nature-green: #4caf50;
    --nature-orange: #ff6d00;
    --nature-red: #d32f2f;
    --nature-purple: #7b1fa2;
    --nature-teal: #00796b;
    --nature-amber: #ffa000;
    
    /* Cream yellow system for control buttons */
    --cream-yellow: #f5deb3;
    --cream-yellow-hover: #deb887;
    --cream-yellow-active: #cdaa7d;
    
    /* Cyan colors for play button */
    --cyan-primary: #20b2ab;
    --cyan-hover: #48d1cc;
    --cyan-active: #008b8b;
    
    /* Brown-red colors for random mode */
    --brown-red: #8b4513;
    --brown-red-hover: #a0522d;
    --brown-red-active: #654321;
    
    /* Borders and lines */
    --border-dark: #555555;
    --border-light: #e0e0e0;
    --border-accent: #cccccc;
    
    /* Shadows */
    --shadow-deep: 0 4px 12px rgba(0,0,0,0.15);
    --shadow-medium: 0 2px 8px rgba(0,0,0,0.1);
    --shadow-light: 0 1px 4px rgba(0,0,0,0.08);
    --shadow-paper: 0 2px 4px rgba(0,0,0,0.05);
    
    --radius-small: 0.375rem;
    --radius-medium: 0.5rem;
}

* {
    box-sizing: border-box;
}

body {
    font-family: 'Microsoft YaHei', '微软雅黑', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin: 0;
    padding: 2rem;
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.2;
    font-size: medium;
    font-weight: 300;
    min-height: 100vh;
}

.container {
    max-width: 1600px;
    margin: 0 auto;
    background: transparent;
}

h1 {
    text-align: center;
    color: #ffffff;
    margin: 0 0 1rem 0;
    font-size: 2.2rem;
    font-weight: 400;
    font-family: 'Times New Roman', serif;
    letter-spacing: -0.3px;
    line-height: 1.2;
}

.subtitle {
    text-align: center;
    color: #cccccc;
    margin: 0 0 2rem 0;
    font-size: 1rem;
    font-weight: 300;
    line-height: 1.3;
    font-style: italic;
    font-family: 'Times New Roman', serif;
}

.main-content {
    display: flex;
    gap: 3rem;
    align-items: flex-start;
}

.control-panel {
    flex: 0 0 360px;
    background: var(--bg-panel-dark);
    background-image: 
        linear-gradient(45deg, rgba(255,255,255,0.04) 1px, transparent 1px),
        linear-gradient(-45deg, rgba(255,255,255,0.04) 1px, transparent 1px);
    background-size: 14px 14px;
    background-position: 0 0, 7px 7px;
    padding: 2rem;
    border-radius: var(--radius-medium);
    border: 1px solid var(--border-dark);
    margin-top: 0.5rem;
    box-shadow: var(--shadow-medium);
}

.center-right-content {
    flex: 1;
    display: flex;
    gap: 3rem;
    align-items: flex-start;
}

.grid-container {
    flex: 1;
    min-width: 600px;
    background: var(--bg-cream);
    padding: 2.5rem;
    border: 1px solid var(--border-light);
    position: relative;
}

/* Enhanced book pages stacked effect */
.grid-container::before {
    content: '';
    position: absolute;
    top: -4px;
    left: 4px;
    right: -4px;
    bottom: 4px;
    background: linear-gradient(135deg, #f8f8f8 0%, #ececec 100%);
    border: 1px solid #d8d8d8;
    z-index: -2;
    box-shadow: 
        0 3px 6px rgba(0,0,0,0.08),
        inset 0 1px 0 rgba(255,255,255,0.6);
}

.grid-container::after {
    content: '';
    position: absolute;
    top: -8px;
    left: 8px;
    right: -8px;
    bottom: 8px;
    background: linear-gradient(135deg, #f2f2f2 0%, #e0e0e0 100%);
    border: 1px solid #cccccc;
    z-index: -3;
    box-shadow: 
        0 2px 8px rgba(0,0,0,0.12),
        inset 0 1px 0 rgba(255,255,255,0.4);
}

/* Additional page shadow for depth */
.grid-container {
    box-shadow: 
        0 4px 12px rgba(0,0,0,0.15),
        0 1px 3px rgba(0,0,0,0.1),
        inset 0 1px 0 rgba(255,255,255,0.8);
}



.grid-title {
    font-size: 1.4rem;
    font-weight: 600;
    margin-bottom: 1.2rem;
    color: #000;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-family: 'Times New Roman', serif;
    padding-top: 0.5rem;
    text-shadow: none;
}

.grid-title.design-title {
    color: #000;
    text-shadow: none;
}

.grid-title.evolution-title {
    color: #000;
    text-shadow: none;
}

.grid-size-info {
    font-size: 0.8em;
    color: var(--light-blue);
    font-weight: 400;
}

.size-selector {
    background: var(--bg-accent-light);
    border: 1px solid var(--border-accent);
    padding: 0.6rem 0.8rem;
    border-radius: var(--radius-small);
    font-size: 0.9rem;
    color: var(--text-display-primary);
    cursor: pointer;
    transition: all 0.2s ease;
    width: 100%;
    font-weight: 400;
}

.size-selector:hover {
    border-color: var(--nature-blue);
    background: var(--bg-cream);
    box-shadow: 0 0 0 2px rgba(0, 115, 230, 0.1);
}

.size-selector:focus {
    outline: none;
    border-color: var(--nature-blue);
    box-shadow: 0 0 0 3px rgba(0, 115, 230, 0.15);
    background: var(--bg-cream);
}

.grid {
    display: inline-grid;
    gap: 1px;
    background: #e8e8e8;
    padding: 0.6rem;
    margin-bottom: 1.5rem;
    border: 1px solid #cccccc;
    box-shadow: 
        0 2px 4px rgba(0,0,0,0.08),
        inset 0 1px 0 rgba(255,255,255,0.3);
}

.cell {
    background: #ffffff;
    border: 1px solid #cccccc;
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
    border-radius: 0;
}

.cell:hover {
    background: #f0f0f0;
    border-color: var(--nature-blue);
    box-shadow: inset 0 0 0 1px var(--nature-blue);
}

.cell.alive {
    background: var(--nature-blue);
    border-color: #404142;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.1);
}

.cell.alive:hover {
    background: var(--nature-green);
    border-color: #006b5a;
}

.button {
    width: 100%;
    padding: 0.7rem 0.9rem;
    margin: 0.3rem 0;
    border: 1px solid var(--border-dark);
    font-size: 0.85rem;
    font-weight: 400;
    cursor: pointer;
    transition: all 0.2s ease;
    background: linear-gradient(135deg, #4a4b4b 0%, #3a3b3b 100%);
    color: var(--text-panel-primary);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-transform: none;
    letter-spacing: 0.3px;
    box-shadow: 
        0 2px 4px rgba(0,0,0,0.2),
        inset 0 1px 0 rgba(255,255,255,0.1);
}

.button:hover {
    background: linear-gradient(135deg, #5a5b5b 0%, #4a4b4b 100%);
    border-color: var(--nature-blue);
    color: var(--nature-blue);
    box-shadow: 
        0 3px 6px rgba(0,0,0,0.25),
        0 0 0 1px var(--nature-blue),
        inset 0 1px 0 rgba(255,255,255,0.15);
    transform: translateY(-1px);
}

.play-button {
    background: linear-gradient(135deg, var(--cyan-primary) 0%, #189a91 100%);
    color: white;
    border-color: var(--cyan-primary);
    font-weight: 500;
    box-shadow: 
        0 3px 6px rgba(32, 178, 170, 0.3),
        inset 0 1px 0 rgba(255,255,255,0.2);
}

.play-button:hover {
    background: linear-gradient(135deg, var(--cyan-hover) 0%, var(--cyan-primary) 100%);
    color: white;
    border-color: var(--cyan-hover);
    box-shadow: 
        0 4px 8px rgba(72, 209, 204, 0.4),
        inset 0 1px 0 rgba(255,255,255,0.25);
    transform: translateY(-1px);
}

.play-button:active {
    background: linear-gradient(135deg, var(--cyan-active) 0%, #167a73 100%);
    border-color: var(--cyan-active);
    transform: translateY(0);
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.2);
}

.clear-button {
    background: linear-gradient(135deg, #5a5b5b 0%, #4a4b4b 100%);
    color: var(--text-panel-secondary);
    border-color: var(--border-dark);
    box-shadow: 
        0 2px 4px rgba(0,0,0,0.2),
        inset 0 1px 0 rgba(255,255,255,0.1);
}

.clear-button:hover {
    background: linear-gradient(135deg, #6a6b6b 0%, #5a5b5b 100%);
    color: var(--nature-orange);
    border-color: var(--nature-orange);
    box-shadow: 
        0 3px 6px rgba(0,0,0,0.25),
        0 0 0 1px var(--nature-orange),
        inset 0 1px 0 rgba(255,255,255,0.15);
    transform: translateY(-1px);
}

.preset-button {
    background: linear-gradient(135deg, #4a4b4b 0%, #3a3b3b 100%);
    color: var(--text-panel-secondary);
    font-size: 0.7rem;
    font-weight: 300;
    padding: 0.4rem 0.2rem;
    width: 100%;
    height: 2rem;
    margin: 2px;
    border: 1px solid var(--border-dark);
    text-align: center;
    transition: all 0.2s ease;
    box-shadow: 
        0 1px 3px rgba(0,0,0,0.15),
        inset 0 1px 0 rgba(255,255,255,0.08);
}

.preset-button:hover {
    background: linear-gradient(135deg, #5a5b5b 0%, #4a4b4b 100%);
    color: var(--nature-orange);
    border-color: var(--nature-orange);
    box-shadow: 
        0 2px 4px rgba(0,0,0,0.2),
        0 0 0 1px var(--nature-orange),
        inset 0 1px 0 rgba(255,255,255,0.12);
    transform: translateY(-1px);
}

.preset-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2px;
    margin-bottom: 8px;
}

.random-preset {
    width: 100%;
    margin-top: 0.6rem;
    font-size: 0.8rem;
    height: 2.2rem;
    background: linear-gradient(135deg, var(--brown-red) 0%, #7a3e0f 100%);
    color: white;
    border-color: var(--brown-red);
    font-weight: 500;
    box-shadow: 
        0 3px 6px rgba(139, 69, 19, 0.3),
        inset 0 1px 0 rgba(255,255,255,0.2);
}

.random-preset:hover {
    background: linear-gradient(135deg, var(--brown-red-hover) 0%, var(--brown-red) 100%);
    color: white;
    border-color: var(--brown-red-hover);
    box-shadow: 
        0 4px 8px rgba(160, 82, 45, 0.4),
        inset 0 1px 0 rgba(255,255,255,0.25);
    transform: translateY(-1px);
}

.random-preset:active {
    background: linear-gradient(135deg, var(--brown-red-active) 0%, #5a2e0a 100%);
    border-color: var(--brown-red-active);
    transform: translateY(0);
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.2);
}

.preset-section {
    margin-top: 16px;
}

.preset-section h3 {
    color: var(--text-panel-primary);
    margin: 0 0 0.6rem 0;
    font-size: 0.95rem;
    font-weight: 500;
    font-family: 'Microsoft YaHei', '微软雅黑', 'Helvetica Neue', Arial, sans-serif;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 1px solid var(--border-dark);
    padding-bottom: 0.3rem;
}

.animation-container {
    margin-top: 24px;
}

.step-counter {
    font-size: 1rem;
    font-weight: 500;
    margin: 1rem 0;
    color: var(--text-display-primary);
    text-align: center;
    background: var(--bg-accent-light);
    padding: 0;
    position: relative;
    overflow: hidden;
    box-shadow: var(--shadow-light);
}

.step-counter .progress-text {
    padding: 0.8rem 1rem;
    position: relative;
    z-index: 1;
}

.progress-container {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--bg-accent-dark);
    cursor: pointer;
    border-radius: inherit;
}

.step-counter .progress-bar {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 100%;
    background: linear-gradient(90deg, var(--light-blue-dark), var(--light-blue));
    transition: width 0.2s ease-out;
    width: 0%;
    box-shadow: 0 0 0 2px var(--light-blue-dark);
    border: 2px solid var(--light-blue-dark);
    box-sizing: border-box;
    border-radius: inherit;
}

.progress-handle {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 18px;
    height: 18px;
    background: white;
    border: 3px solid var(--light-blue-dark);
    border-radius: 50%;
    cursor: grab;
    box-shadow: 0 2px 6px rgba(0,0,0,0.3);
    transition: all 0.2s ease;
    z-index: 10;
    left: 0%;
}

.progress-handle:hover {
    transform: translateY(-50%) scale(1.1);
    box-shadow: 0 3px 8px rgba(0,0,0,0.4);
}

.progress-handle:active,
.progress-handle.dragging {
    cursor: grabbing;
    transform: translateY(-50%) scale(1.15);
    box-shadow: 0 4px 12px rgba(0,0,0,0.5);
}

.step-counter .progress-text {
    position: relative;
    z-index: 2;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.8rem 1rem;
    pointer-events: none;
}

.step-counter .progress-percentage {
    font-size: 0.85rem;
    color: var(--text-display-primary);
    font-weight: 600;
}

.info-container {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
    align-items: stretch;
}

.model-info-section {
    flex: 1;
    min-width: 0;
}

.status-info-section {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
}

.model-info-section h3,
.status-info-section h3 {
    color: var(--light-blue);
    font-weight: 600;
    font-family: 'Microsoft YaHei', '微软雅黑', sans-serif;
    text-shadow: 0 1px 2px rgba(135, 206, 235, 0.3);
    margin-bottom: 0.8rem;
    font-size: 1.1rem;
}

.info-box {
    background: var(--bg-cream);
    border: 1px solid var(--border-light);
    color: var(--text-display-secondary);
    padding: 1rem;
    border-radius: var(--radius-small);
    font-size: 0.8rem;
    margin-bottom: 0.6rem;
    font-weight: 300;
    line-height: 1.4;
    box-shadow: var(--shadow-paper);
}

.info-box strong {
    color: var(--text-display-primary);
    font-weight: 500;
}

.status-box {
    background: var(--bg-accent-light);
    border: 1px solid var(--border-accent);
    color: var(--text-display-primary);
    padding: 0.6rem 0.8rem;
    border-radius: var(--radius-small);
    font-size: 0.8rem;
    font-weight: 400;
    text-align: center;
    margin-bottom: 0.6rem;
    border-left: 4px solid var(--nature-green);
}

/* Grid size styles */
.grid-size-8 { 
    grid-template-columns: repeat(8, 24px); 
    grid-template-rows: repeat(8, 24px); 
}
.grid-size-8 .cell { 
    width: 24px; 
    height: 24px; 
}

.grid-size-10 { 
    grid-template-columns: repeat(10, 20px); 
    grid-template-rows: repeat(10, 20px); 
}
.grid-size-10 .cell { 
    width: 20px; 
    height: 20px; 
}

.grid-size-16 { 
    grid-template-columns: repeat(16, 16px); 
    grid-template-rows: repeat(16, 16px); 
}
.grid-size-16 .cell { 
    width: 16px; 
    height: 16px; 
}

/* Control styles */
label {
    font-weight: 400;
    margin-bottom: 0.5rem;
    display: block;
    color: var(--text-panel-primary);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

input[type="range"] {
    width: 100%;
    margin: 0.6rem 0;
    accent-color: var(--nature-blue);
    height: 6px;
    border-radius: 3px;
    background: var(--bg-accent-dark);
}

/* Animation control buttons */
.animation-container .button {
    width: auto;
    padding: 0.6rem 1rem;
    margin: 0 0.4rem;
    font-size: 0.8rem;
    min-width: 4rem;
    font-weight: 500;
    background: var(--cream-yellow);
    color: var(--text-display-primary);
    border: 1px solid var(--cream-yellow-hover);
    box-shadow: 0 2px 4px rgba(0,0,0,0.15);
    text-shadow: none;
}

.animation-container .button:hover {
    background: var(--cream-yellow-hover);
    color: var(--text-display-primary);
    border-color: var(--cream-yellow-active);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
    transform: translateY(-1px);
}

.animation-container .button:active {
    background: var(--cream-yellow-active);
    transform: translateY(0);
    box-shadow: 0 1px 2px rgba(0,0,0,0.1);
}

.animation-container .button:first-child {
    margin-left: 0;
}

.animation-container .button:last-child {
    margin-right: 0;
}

/* Mobile responsive design */
@media (max-width: 768px) {
    body {
        padding: 1rem;
    }
    
    h1 {
        font-size: 2rem;
    }
    
    .main-content {
        flex-direction: column;
        gap: 1.5rem;
    }
    
    .control-panel {
        flex: none;
        width: 100%;
        margin-top: 0;
        padding: 1.5rem;
    }
    
    .center-right-content {
        flex-direction: column;
        gap: 1.5rem;
    }
    
    .info-panel {
        flex: none;
        width: 100%;
        margin-top: 0;
    }
    
    .grid-container {
        padding: 1.5rem;
    }
    
    .grid-title {
        font-size: 1rem;
    }
    
    .grid-size-8 { 
        grid-template-columns: repeat(8, 20px); 
        grid-template-rows: repeat(8, 20px); 
    }
    .grid-size-8 .cell { 
        width: 20px; 
        height: 20px; 
    }
    
    .grid-size-10 { 
        grid-template-columns: repeat(10, 16px); 
        grid-template-rows: repeat(10, 16px); 
    }
    .grid-size-10 .cell { 
        width: 16px; 
        height: 16px; 
    }
    
    .grid-size-16 { 
        grid-template-columns: repeat(16, 12px); 
        grid-template-rows: repeat(16, 12px); 
    }
    .grid-size-16 .cell { 
        width: 12px; 
        height: 12px; 
    }
    
    .info-container {
        flex-direction: column;
        gap: 12px;
    }
    
    .info-panel {
        margin-top: 12px;
    }
    
    .info-links {
        flex-direction: column;
        gap: 0.5rem;
    }
}

/* Information Panel Styles */
.info-panel {
    flex: 0 0 320px;
    background: var(--bg-panel-dark);
    background-image: 
        linear-gradient(45deg, rgba(255,255,255,0.04) 1px, transparent 1px),
        linear-gradient(-45deg, rgba(255,255,255,0.04) 1px, transparent 1px);
    background-size: 14px 14px;
    background-position: 0 0, 7px 7px;
    padding: 2rem;
    border-radius: var(--radius-medium);
    border: 1px solid var(--border-dark);
    margin-top: 0.5rem;
    box-shadow: var(--shadow-medium);
}

.info-panel h3 {
    color: var(--text-panel-primary);
    margin: 0 0 1rem 0;
    font-size: 1.1rem;
    font-weight: 500;
    font-family: 'Microsoft YaHei', '微软雅黑', 'Helvetica Neue', Arial, sans-serif;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 1px solid var(--border-dark);
    padding-bottom: 0.5rem;
}

.info-links {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.info-link {
    display: block;
    padding: 0.8rem 1rem;
    background: linear-gradient(135deg, #4a4b4b 0%, #3a3b3b 100%);
    border: 1px solid var(--border-dark);
    border-radius: var(--radius-small);
    color: var(--text-panel-primary);
    text-decoration: none;
    transition: all 0.2s ease;
    box-shadow: 
        0 2px 4px rgba(0,0,0,0.2),
        inset 0 1px 0 rgba(255,255,255,0.1);
}

.info-link:hover {
    background: linear-gradient(135deg, #5a5b5b 0%, #4a4b4b 100%);
    border-color: var(--nature-blue);
    color: var(--nature-blue);
    box-shadow: 
        0 3px 6px rgba(0,0,0,0.25),
        0 0 0 1px var(--nature-blue),
        inset 0 1px 0 rgba(255,255,255,0.15);
    transform: translateY(-1px);
}

.info-link .link-title {
    display: block;
    font-size: 0.9rem;
    font-weight: 500;
    margin-bottom: 0.2rem;
    color: inherit;
}

.info-link .link-desc {
    display: block;
    font-size: 0.75rem;
    color: var(--text-panel-muted);
    font-weight: 300;
    font-style: italic;
}

.info-link:hover .link-desc {
    color: var(--text-panel-secondary);
}

/* Control Button Groups */
.control-button-group {
    display: flex;
    gap: 0.5rem;
    margin: 0.5rem 0;
}

.control-button-group .button {
    margin: 0;
}

/* Play/Pause Toggle Button */
.play-pause-button {
    background: linear-gradient(135deg, var(--nature-green) 0%, #388e3c 100%);
    color: white;
    border-color: var(--nature-green);
    font-weight: 500;
    position: relative;
    min-width: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 
        0 3px 6px rgba(76, 175, 80, 0.3),
        inset 0 1px 0 rgba(255,255,255,0.2);
}

.play-pause-button:hover {
    background: linear-gradient(135deg, #66bb6a 0%, var(--nature-green) 100%);
    color: white;
    border-color: #66bb6a;
    box-shadow: 
        0 4px 8px rgba(102, 187, 106, 0.4),
        inset 0 1px 0 rgba(255,255,255,0.25);
    transform: translateY(-1px);
}

.play-pause-button.paused {
    background: linear-gradient(135deg, var(--nature-orange) 0%, #f57c00 100%);
    border-color: var(--nature-orange);
    box-shadow: 
        0 3px 6px rgba(255, 109, 0, 0.3),
        inset 0 1px 0 rgba(255,255,255,0.2);
}

.play-pause-button.paused:hover {
    background: linear-gradient(135deg, #ffb74d 0%, var(--nature-orange) 100%);
    border-color: #ffb74d;
    box-shadow: 
        0 4px 8px rgba(255, 183, 77, 0.4),
        inset 0 1px 0 rgba(255,255,255,0.25);
}

/* Play/Pause Icon */
.play-icon, .pause-icon {
    width: 0;
    height: 0;
    display: inline-block;
}

.play-icon {
    border-left: 8px solid currentColor;
    border-top: 6px solid transparent;
    border-bottom: 6px solid transparent;
    margin-left: 2px;
}

.pause-icon {
    position: relative;
    width: 12px;
    height: 12px;
}

.pause-icon::before,
.pause-icon::after {
    content: '';
    position: absolute;
    top: 0;
    width: 4px;
    height: 12px;
    background: currentColor;
}

.pause-icon::before {
    left: 0;
}

.pause-icon::after {
    right: 0;
}

/* Reset Button */
.reset-button {
    background: linear-gradient(135deg, var(--nature-red) 0%, #b71c1c 100%);
    color: white;
    border-color: var(--nature-red);
}

.reset-button:hover {
    background: linear-gradient(135deg, #f44336 0%, var(--nature-red) 100%);
    color: white;
    border-color: #f44336;
    box-shadow: 
        0 3px 6px rgba(211, 47, 47, 0.3),
        0 0 0 1px #f44336,
        inset 0 1px 0 rgba(255,255,255,0.15);
    transform: translateY(-1px);
}

/* Step Button */
.step-button {
    background: linear-gradient(135deg, var(--cyan-primary) 0%, var(--cyan-active) 100%);
    color: white;
    border-color: var(--cyan-primary);
}

.step-button:hover {
    background: linear-gradient(135deg, var(--cyan-hover) 0%, var(--cyan-primary) 100%);
    color: white;
    border-color: var(--cyan-hover);
    box-shadow: 
        0 3px 6px rgba(32, 178, 171, 0.3),
        0 0 0 1px var(--cyan-hover),
        inset 0 1px 0 rgba(255,255,255,0.15);
    transform: translateY(-1px);
}

/* Raw value display for neural network output */
.cell.raw-value {
    transition: none !important;
}

/* Cell tooltip for displaying values */
.cell-tooltip {
    position: absolute;
    background: rgba(0, 0, 0, 0.9);
    color: white;
    padding: 0.5rem;
    border-radius: 4px;
    font-size: 0.75rem;
    line-height: 1.2;
    pointer-events: none;
    z-index: 1000;
    white-space: nowrap;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    font-family: 'Courier New', monospace;
}

.cell-tooltip::before {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    margin-left: -5px;
    border: 5px solid transparent;
    border-top-color: rgba(0, 0, 0, 0.9);
}