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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    min-height: 100vh;
    color: #fff;
}

.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 40px 20px;
}

h1 {
    text-align: center;
    margin-bottom: 30px;
    font-size: 2rem;
    color: #fff;
}

.back-link {
    display: inline-block;
    color: #4dabf7;
    text-decoration: none;
    margin-bottom: 20px;
    font-size: 0.9rem;
}

.back-link:hover {
    color: #74c0fc;
}

/* Tabs */
.tabs {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 30px;
}

.tab-btn {
    padding: 12px 30px;
    border: none;
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1rem;
    transition: all 0.3s ease;
}

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

.tab-btn.active {
    background: #4dabf7;
    color: #fff;
}

.tab-content {
    animation: fadeIn 0.3s ease;
}

.tab-content.hidden {
    display: none;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* App Grid */
.app-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 20px;
}

.app-card {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 25px 15px;
    text-align: center;
    text-decoration: none;
    color: #fff;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.app-card:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.app-icon {
    font-size: 3rem;
    margin-bottom: 10px;
}

.app-name {
    font-size: 0.95rem;
    font-weight: 500;
}

.empty-message {
    text-align: center;
    color: rgba(255, 255, 255, 0.5);
    font-style: italic;
}

/* Status Box */
.status-box {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    background: rgba(255, 255, 255, 0.1);
    padding: 20px;
    border-radius: 12px;
    margin-bottom: 30px;
}

.status-indicator {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #868e96;
}

.status-indicator.running {
    background: #51cf66;
    box-shadow: 0 0 10px #51cf66;
    animation: pulse 2s infinite;
}

.status-indicator.stopped {
    background: #ff6b6b;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

/* Buttons */
.button-group {
    display: flex;
    justify-content: center;
    gap: 20px;
}

.btn {
    padding: 15px 50px;
    border: none;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

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

.btn-start {
    background: #51cf66;
    color: #fff;
}

.btn-start:hover:not(:disabled) {
    background: #40c057;
    transform: translateY(-2px);
}

.btn-stop {
    background: #ff6b6b;
    color: #fff;
}

.btn-stop:hover:not(:disabled) {
    background: #fa5252;
    transform: translateY(-2px);
}

/* Message */
.message {
    text-align: center;
    margin-top: 20px;
    padding: 10px;
    border-radius: 8px;
    min-height: 40px;
}

.message.success {
    background: rgba(81, 207, 102, 0.2);
    color: #51cf66;
}

.message.error {
    background: rgba(255, 107, 107, 0.2);
    color: #ff6b6b;
}

/* Form Elements */
.form-group {
    margin-bottom: 25px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: rgba(255, 255, 255, 0.9);
    font-weight: 500;
}

.form-input,
.form-select {
    width: 100%;
    padding: 14px 16px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.form-input:focus,
.form-select:focus {
    outline: none;
    border-color: #4dabf7;
    background: rgba(255, 255, 255, 0.15);
}

.form-input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.form-select option {
    background: #1a1a2e;
    color: #fff;
}

/* Progress Container */
.progress-container {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 20px;
    margin-top: 25px;
}

.progress-container.hidden {
    display: none;
}

.progress-status {
    display: flex;
    align-items: center;
    gap: 15px;
}

.spinner {
    width: 24px;
    height: 24px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-top-color: #4dabf7;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

#progress-text {
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.95rem;
}
