/* Placeholder for frontend styles */
body {
    font-family: Arial, sans-serif;
    background: #f8f9fa;
    margin: 0;
    padding: 0;
}

.container {
    max-width: 900px;
    margin: 40px auto;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    padding: 32px;
}

.version {
    color: #6c757d;
    font-family: monospace;
    font-size: 0.85rem;
    margin-top: -12px;
}

.primary-button {
    background: #007bff;
    color: #fff;
    border: none;
    border-radius: 4px;
    padding: 10px 20px;
    cursor: pointer;
    font-size: 1rem;
}

.primary-button:hover {
    background: #0056b3;
}

.refresh-button {
    background: #28a745;
    color: #fff;
    border: none;
    border-radius: 4px;
    padding: 10px 20px;
    cursor: pointer;
    font-size: 1rem;
    margin-bottom: 16px;
    margin-left: 8px;
}

.refresh-button:hover {
    background: #218838;
}

.apply-button {
    background: #28a745;
    color: #fff;
    border: none;
    border-radius: 4px;
    padding: 10px 20px;
    cursor: pointer;
    font-size: 1rem;
    margin-bottom: 16px;
    margin-left: 8px;
}

.apply-button:hover {
    background: #218838;
}

.toggle-button {
    background: #28a745;
    color: #fff;
    border: none;
    border-radius: 4px;
    padding: 10px 20px;
    cursor: pointer;
    font-size: 1rem;
    margin-bottom: 16px;
    margin-left: 8px;
}

.toggle-button:hover {
    background: #218838;
}

.apply-section {
    text-align: center;
    margin: 16px 0;
}

.control-bar {
    text-align: center;
    margin: 16px 0;
}

.loading {
    color: #888;
    font-style: italic;
}

.status-bar {
    background: #e9ecef;
    padding: 8px 16px;
    border-radius: 4px;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
}

.status-bar.hidden {
    display: none;
}

.hidden {
    display: none;
}

/* Filter styling */
.filter-section {
    margin: 16px 0;
}

.filter-input {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid #ced4da;
    border-radius: 4px;
    font-size: 1rem;
    box-sizing: border-box;
}

.filter-input:focus {
    outline: none;
    border-color: #007bff;
    box-shadow: 0 0 0 2px rgba(0, 123, 255, 0.25);
}

.env-filter-toggles {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    clear: both;
    padding: 8px 0;
}

.env-filter-toggle {
    background: #fff;
    color: #495057;
    border: 1px solid #adb5bd;
    border-radius: 4px;
    padding: 8px 14px;
    cursor: pointer;
    font-size: 0.9rem;
}

.env-filter-toggle:hover,
.env-filter-toggle.active {
    background: #007bff;
    color: #fff;
    border-color: #007bff;
}

.env-filter-toggle.has-pipeline-problem {
    border: 2px solid #dc3545;
}

/* Branches table styling */
.branches-table {
    width: 100%;
    border-collapse: collapse;
    margin: 16px 0;
}

.branches-table th {
    background: #f8f9fa;
    padding: 12px 8px;
    text-align: left;
    font-weight: 600;
    color: #495057;
    border-bottom: 2px solid #dee2e6;
}

.branches-table td {
    padding: 12px 8px;
    vertical-align: middle;
    border-bottom: 1px solid #dee2e6;
}

.branch-row:hover {
    background: #f8f9fa;
}

.branch-name {
    font-weight: 500;
}

.env-label {
    color: #6c757d;
    font-size: 0.9em;
    font-weight: normal;
}

.desired-commit {
    margin-right: 8px;
    padding: 4px 8px;
    border: 1px solid #ced4da;
    border-radius: 4px;
    font-size: 0.9em;
}

.commit-input {
    padding: 4px 8px;
    border: 1px solid #ced4da;
    border-radius: 4px;
    font-size: 0.9em;
    width: 200px;
    font-family: monospace;
}

.deployed-commit {
    font-family: monospace;
    font-size: 0.9em;
    color: #6c757d;
}

/* Checkbox styling */
input[type="checkbox"] {
    margin: 0;
    transform: scale(1.2);
}

/* Dry run play/pause button */
.env-title {
    display: flex;
    align-items: center;
    gap: 12px;
}

.dry-run-btn {
    margin-left: auto;
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1.2rem;
    line-height: 1;
    padding: 2px 6px;
    border-radius: 4px;
    color: #aaaaaa;
    transition: color 0.15s, background 0.15s;
}

.dry-run-btn:hover {
    background: rgba(0,0,0,0.06);
}

.dry-run-btn.dry-run-active {
    color: #ffc107;
}

/* Step spinner */
@keyframes step-spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.step-spinner {
    display: inline-block;
    width: 12px;
    height: 12px;
    border: 2px solid #007bff;
    border-top-color: transparent;
    border-radius: 50%;
    animation: step-spin 0.7s linear infinite;
    margin-right: 6px;
    vertical-align: middle;
    flex-shrink: 0;
}
