/* Main styles for Random Variables Generation Simulation */
:root {
    --primary-color: #2196f3;
    --secondary-color: #607d8b;
    --success-color: #4caf50;
    --warning-color: #ff9800;
    --danger-color: #f44336;
    --text-color: #333;
    --bg-color: #f5f5f5;
    --card-bg: #fff;
    --border-color: #ddd;
    --shadow-color: rgba(0, 0, 0, 0.1);
    --border-radius: 8px;
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--bg-color);
}

.app-container {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Header Styles */
.app-header {
    background-color: var(--primary-color);
    color: white;
    padding: 1rem;
    box-shadow: 0 2px 4px var(--shadow-color);
}

.header-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

.header-content h1 {
    font-size: 1.8rem;
    margin-bottom: 0.5rem;
}

.header-description {
    font-size: 1rem;
    opacity: 0.9;
}

/* Main Content Styles */
.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    padding: 1rem;
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
}

/* Visualization Section */
.visualization-section {
    display: flex;
    gap: 1rem;
    flex: 1;
    min-height: 400px;
}

/* Canvas Container */
.canvas-container {
    position: relative;
    width: 100%;
    height: 500px;
    background: var(--bg-color);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.visualization-canvas {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 100%;
    height: 100%;
}

/* Canvas Controls */
.canvas-controls {
    position: absolute;
    top: 1rem;
    right: 1rem;
    display: flex;
    gap: 0.5rem;
    z-index: 10;
}

.info-panel {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    min-width: 300px;
}

.info-card {
    background: var(--card-bg);
    border-radius: 8px;
    padding: 1rem;
    box-shadow: 0 2px 4px var(--shadow-color);
}

.card-title {
    font-size: 1.2rem;
    margin-bottom: 1rem;
    color: var(--primary-color);
}

/* Status and Metrics */
.status-content,
.metrics-content {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.status-item,
.metric-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.status-label,
.metric-label {
    font-weight: 500;
}

.status-value,
.metric-value {
    font-family: monospace;
}

.status-waiting {
    color: var(--warning-color);
}

/* Control Section */
.control-section {
    background: var(--card-bg);
    border-radius: 8px;
    padding: 1rem;
    box-shadow: 0 2px 4px var(--shadow-color);
}

.control-panel {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.panel-section {
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 1rem;
}

.panel-section:last-child {
    border-bottom: none;
}

.section-title {
    font-size: 1.2rem;
    margin-bottom: 1rem;
    color: var(--primary-color);
}

/* Form Elements */
.form-group {
    margin-bottom: 1rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.form-control {
    width: 100%;
    padding: 0.5rem;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 1rem;
}

.range-with-value {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.form-range {
    flex: 1;
}

.range-value {
    min-width: 60px;
    text-align: right;
    font-family: monospace;
}

/* Buttons */
.btn {
    padding: 0.5rem 1rem;
    border: none;
    border-radius: 4px;
    font-size: 1rem;
    cursor: pointer;
    transition: background-color 0.2s;
}

.btn-icon {
    padding: 0.5rem;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
}

.btn-icon:hover {
    background: var(--bg-color);
}

.btn-primary {
    background-color: var(--primary-color);
    color: white;
}

.btn-secondary {
    background-color: var(--secondary-color);
    color: white;
}

.btn-success {
    background-color: var(--success-color);
    color: white;
}

.btn-warning {
    background-color: var(--warning-color);
    color: white;
}

.btn-danger {
    background-color: var(--danger-color);
    color: white;
}

.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.button-group {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

/* Footer */
.app-footer {
    background-color: var(--secondary-color);
    color: white;
    padding: 1rem;
    margin-top: auto;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    text-align: center;
}

/* Notifications */
.notification-container {
    position: fixed;
    top: 1rem;
    right: 1rem;
    z-index: 1000;
}

/* Canvas Overlay */
.canvas-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.overlay-content {
    max-width: 600px;
    background: white;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.overlay-content h3 {
    color: var(--primary-color);
    margin-bottom: 15px;
    font-size: 1.5em;
}

.overlay-content p {
    color: #666;
    margin-bottom: 20px;
    font-size: 1.1em;
}

.instructions-section {
    margin: 20px 0;
    text-align: left;
}

.instructions-section h4 {
    color: var(--primary-color);
    margin-bottom: 15px;
    font-size: 1.2em;
}

.instructions-section ol {
    padding-left: 20px;
    margin-bottom: 20px;
}

.instructions-section li {
    margin-bottom: 15px;
    color: #444;
}

.instructions-section li strong {
    color: var(--primary-color);
    display: block;
    margin-bottom: 5px;
}

.instructions-section ul {
    padding-left: 20px;
    margin-top: 5px;
}

.instructions-section ul li {
    margin-bottom: 5px;
    color: #666;
    font-size: 0.95em;
}

.overlay-content .btn {
    margin-top: 20px;
    font-size: 1.1em;
    padding: 12px 24px;
}