:root {
    --bg-primary: #0f172a;
    --bg-secondary: #1e293b;
    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
    --accent-blue: #3b82f6;
    --accent-green: #10b981;
    --accent-red: #ef4444;
    --border-color: #334155;
}

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

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.5;
    padding: 2rem;
    min-height: 100vh;
}

.dashboard {
    max-width: 1200px;
    margin: 0 auto;
}

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
}

.logo {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.logo h1 {
    font-weight: 600;
    letter-spacing: -0.025em;
    background: linear-gradient(to right, #60a5fa, #a78bfa);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.icon {
    font-size: 2rem;
}

.status-badge {
    padding: 0.5rem 1rem;
    border-radius: 9999px;
    font-size: 0.875rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.status-badge::before {
    content: '';
    display: block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
}

.status-badge.offline {
    background: rgba(239, 68, 68, 0.1);
    color: var(--accent-red);
}

.status-badge.offline::before {
    background: var(--accent-red);
}

.status-badge.online {
    background: rgba(16, 185, 129, 0.1);
    color: var(--accent-green);
}

.status-badge.online::before {
    background: var(--accent-green);
    box-shadow: 0 0 8px var(--accent-green);
}

main {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
}

.card {
    background: var(--bg-secondary);
    border-radius: 1rem;
    padding: 1.5rem;
    border: 1px solid rgba(255, 255, 255, 0.05);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

.card h2 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
}

.form-group {
    margin-bottom: 1.25rem;
}

.coordinates {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

input[type="text"],
input[type="number"],
input[type="date"],
select.form-control {
    width: 100%;
    padding: 0.75rem 1rem;
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: 0.5rem;
    color: var(--text-primary);
    font-family: monospace;
    font-size: 1rem;
    transition: all 0.2s;
    appearance: none;
}

input:focus,
select.form-control:focus {
    outline: none;
    border-color: var(--accent-blue);
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.2);
}
    outline: none;
    border-color: var(--accent-blue);
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.2);
}

.mode-selector {
    margin: 1.5rem 0;
}

.mode-selector h3 {
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin-bottom: 0.75rem;
}

.radio-group {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.radio-card {
    display: block;
    padding: 1rem;
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: 0.5rem;
    cursor: pointer;
    transition: all 0.2s;
    position: relative;
}

.radio-card input {
    position: absolute;
    opacity: 0;
}

.radio-card .title {
    display: block;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.radio-card .desc {
    display: block;
    font-size: 0.75rem;
    color: var(--text-secondary);
}

.radio-card.active {
    border-color: var(--accent-blue);
    background: rgba(59, 130, 246, 0.1);
}

.hidden {
    display: none !important;
}

.actions {
    margin-top: 2rem;
}

.btn {
    width: 100%;
    padding: 1rem;
    border: none;
    border-radius: 0.5rem;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.btn-primary {
    background: linear-gradient(to right, #2563eb, #4f46e5);
    color: white;
    box-shadow: 0 4px 14px 0 rgba(79, 70, 229, 0.39);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(79, 70, 229, 0.5);
}

.btn-danger {
    background: linear-gradient(to right, #dc2626, #991b1b);
    color: white;
    box-shadow: 0 4px 14px 0 rgba(220, 38, 38, 0.39);
}

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

.spinner {
    width: 16px;
    height: 16px;
    border: 2px solid var(--border-color);
    border-top-color: var(--accent-green);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

.terminal {
    background: #000;
    border-radius: 0.5rem;
    padding: 1rem;
    height: calc(100% - 3rem);
    min-height: 400px;
    font-family: 'Consolas', 'Courier New', monospace;
    font-size: 0.85rem;
    overflow-y: auto;
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.5);
}

.log-line {
    margin-bottom: 0.25rem;
    color: #a3e635; /* Terminal green */
}

.log-line.text-muted {
    color: var(--text-secondary);
}

/* Scrollbar styling for terminal */
.terminal::-webkit-scrollbar {
    width: 8px;
}
.terminal::-webkit-scrollbar-track {
    background: rgba(0,0,0,0.3);
}
.terminal::-webkit-scrollbar-thumb {
    background: #333;
    border-radius: 4px;
}
