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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    min-height: 100vh;
    color: #fff;
}

.hidden {
    display: none !important;
}

/* Login Screen */
.screen {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.login-box {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 40px;
    width: 100%;
    max-width: 400px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.login-box h1 {
    text-align: center;
    margin-bottom: 30px;
    color: #4ecca3;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: #ccc;
    font-size: 14px;
}

.form-group input {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.05);
    color: #fff;
    font-size: 16px;
    transition: border-color 0.3s;
}

.form-group input:focus {
    outline: none;
    border-color: #4ecca3;
}

.form-group input::placeholder {
    color: #666;
}

.btn {
    padding: 12px 24px;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-primary {
    width: 100%;
    background: #4ecca3;
    color: #1a1a2e;
}

.btn-primary:hover {
    background: #3db892;
    transform: translateY(-2px);
}

.btn-success {
    background: #4ecca3;
    color: #1a1a2e;
}

.btn-success:hover {
    background: #3db892;
}

.btn-danger {
    background: #e74c3c;
    color: #fff;
}

.btn-danger:hover {
    background: #c0392b;
}

.btn-small {
    padding: 8px 16px;
    font-size: 12px;
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

.btn-small:hover {
    background: rgba(255, 255, 255, 0.2);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.15);
    color: #ccc;
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.25);
    color: #fff;
}

.btn-small.btn-danger {
    background: rgba(231, 76, 60, 0.7);
}

.btn-small.btn-danger:hover {
    background: #e74c3c;
}

.error-text {
    color: #e74c3c;
    text-align: center;
    margin-top: 15px;
    font-size: 14px;
}

/* Dashboard */
#dashboard-screen {
    display: block;
    padding: 20px;
}

#dashboard-screen.hidden {
    display: none;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
}

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 15px;
    margin-bottom: 20px;
}

header h1 {
    color: #4ecca3;
    font-size: 24px;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

.logout-buttons {
    display: flex;
    gap: 10px;
}

.current-time {
    font-size: 18px;
    color: #ccc;
}

.current-time span:last-child {
    color: #4ecca3;
    font-weight: bold;
    margin-left: 10px;
    font-family: monospace;
    font-size: 22px;
}

.main-content {
    display: grid;
    grid-template-columns: 350px 1fr;
    grid-template-rows: auto 1fr;
    gap: 20px;
}

.settings-panel {
    grid-row: 1 / 3;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 15px;
    padding: 25px;
}

.settings-panel h2,
.results-panel h2,
.log-panel h2 {
    color: #4ecca3;
    margin-bottom: 20px;
    font-size: 18px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.countdown-box {
    background: rgba(78, 204, 163, 0.1);
    border: 2px solid #4ecca3;
    border-radius: 15px;
    padding: 20px;
    text-align: center;
    margin: 20px 0;
}

.countdown-label {
    color: #ccc;
    font-size: 14px;
}

.countdown {
    font-size: 36px;
    font-weight: bold;
    color: #4ecca3;
    font-family: monospace;
    margin: 10px 0;
}

.button-group {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

.button-group .btn {
    flex: 1;
}

.results-panel {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 15px;
    padding: 25px;
}

#results-container {
    display: flex;
    gap: 20px;
}

.result-box {
    flex: 1;
    padding: 15px;
    border-radius: 10px;
}

.result-box h3 {
    margin-bottom: 10px;
    font-size: 14px;
}

.result-box ul {
    list-style: none;
}

.result-box li {
    padding: 8px 12px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 5px;
    margin-bottom: 5px;
    font-family: monospace;
}

.success-box {
    background: rgba(78, 204, 163, 0.2);
    border: 1px solid #4ecca3;
}

.success-box h3 {
    color: #4ecca3;
}

.error-box {
    background: rgba(231, 76, 60, 0.2);
    border: 1px solid #e74c3c;
}

.error-box h3 {
    color: #e74c3c;
}

.log-panel {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 15px;
    padding: 25px;
    display: flex;
    flex-direction: column;
}

.log-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.log-header h2 {
    margin-bottom: 0;
}

.log-container {
    flex: 1;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 10px;
    padding: 15px;
    min-height: 300px;
    max-height: 400px;
    overflow-y: auto;
    font-family: monospace;
    font-size: 13px;
}

.log-placeholder {
    color: #666;
    font-style: italic;
}

.log-entry {
    padding: 8px 12px;
    border-radius: 5px;
    margin-bottom: 5px;
    word-break: break-all;
}

.log-info {
    background: rgba(255, 255, 255, 0.05);
    color: #ccc;
}

.log-success {
    background: rgba(78, 204, 163, 0.2);
    color: #4ecca3;
}

.log-warning {
    background: rgba(241, 196, 15, 0.2);
    color: #f1c40f;
}

.log-error {
    background: rgba(231, 76, 60, 0.2);
    color: #e74c3c;
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* Responsive */
@media (max-width: 900px) {
    .main-content {
        grid-template-columns: 1fr;
        grid-template-rows: auto auto auto;
    }

    .settings-panel {
        grid-row: auto;
    }
}
