:root {
    --bg-color: #0d1117;
    --text-color: #e6edf3;
    --accent-color: #ff3b30;
    --accent-hover: #ff6961;
}

body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    overflow: hidden;
}

#main-ui {
    text-align: center;
    width: 100%;
    max-width: 480px;
    padding: 20px;
    transition: all 1.5s ease;
}

.main-title {
    font-size: 28px;
    font-weight: bold;
    margin-bottom: 8px;
    color: #fff;
}

.subtitle {
    font-size: 14px;
    color: #8b949e;
    margin-bottom: 40px;
}

#gauge-container {
    margin: 20px 0;
}

.gauge {
    width: 100%;
    height: 12px;
    background: #21262d;
    border-radius: 6px;
    overflow: hidden;
    position: relative;
    box-shadow: inset 0 1px 3px rgba(0,0,0,0.5);
}

.gauge-fill {
    height: 100%;
    background: linear-gradient(90deg, #ff9500, #ff3b30);
    transition: width 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.status-text {
    margin-top: 12px;
    font-size: 16px;
    font-weight: 600;
}

.anonym-info {
    font-size: 12px;
    color: #8b949e;
    font-weight: normal;
}

.btn-primary {
    appearance: none;
    border: none;
    background: var(--accent-color);
    color: #fff;
    font-size: 28px;
    font-weight: bold;
    width: 180px;
    height: 180px;
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(255, 59, 48, 0.4), inset 0 -6px 12px rgba(0,0,0,0.2);
    transition: transform 0.1s, box-shadow 0.1s, background 0.2s;
    margin-top: 20px;
}

.btn-primary:hover:not([disabled]) {
    background: var(--accent-hover);
    transform: scale(1.05);
    box-shadow: 0 6px 20px rgba(255, 59, 48, 0.6), inset 0 -4px 8px rgba(0,0,0,0.2);
}

.btn-primary:active:not([disabled]) {
    transform: scale(0.95);
    box-shadow: 0 2px 8px rgba(255, 59, 48, 0.4), inset 0 -8px 16px rgba(0,0,0,0.3);
}

.btn-primary[disabled] {
    background: #30363d;
    color: #8b949e;
    cursor: not-allowed;
    box-shadow: none;
    transform: scale(1);
}

/* Triggered Mode (Ending Screen) */
.triggered-mode {
    animation: fadeToEnding 2s forwards;
    background-color: #000;
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

.ending-screen {
    text-align: center;
}

.ending-title {
    font-size: 32px;
    color: #ff9500;
    text-shadow: 0 0 10px rgba(255, 149, 0, 0.8);
    margin-bottom: 16px;
}

.ending-sub {
    font-size: 18px;
    color: #ccc;
}

@keyframes fadeToEnding {
    0% { opacity: 0; }
    50% { opacity: 0; }
    100% { opacity: 1; }
}
