/* --- Base Typography & Spacing --- */
h2 {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    color: #1e293b;
    margin-bottom: 0.5rem;
    font-weight: 600;
}

p {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    color: #64748b;
    margin-top: 0;
    margin-bottom: 2rem;
    line-height: 1.5;
}

/* --- Action Bar --- */
.action-bar {
    margin-bottom: 1.5rem;
}

.bar-btn-sect {
    display: flex;
    gap: 1rem; /* Creates space between the Create and Generate buttons */
}

/* --- Buttons --- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.625rem 1.25rem;
    font-size: 0.95rem;
    font-weight: 500;
    font-family: inherit;
    text-decoration: none;
    border-radius: 6px;
    border: none;
    cursor: pointer;
    transition: background-color 0.2s ease, transform 0.1s ease;
    outline: none;
}

/* Focus styles for accessibility */
.btn:focus-visible {
    outline: 2px solid #2563eb;
    outline-offset: 2px;
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.2);
}

/* Click effect */
.btn:active {
    transform: scale(0.98);
}

.btn-sm {
    padding: 0.35rem 0.75rem;
    font-size: 0.85rem;
    border-radius: 4px;
}

.btn-primary {
    background-color: #2563eb;
    color: #ffffff;
}

.btn-primary:hover {
    background-color: #1d4ed8;
}

.btn-primary:focus-visible {
    outline-color: #2563eb;
}

.btn-secondary {
    background-color: #ffffff;
    color: #334155;
    border: 1px solid #cbd5e1;
}

.btn-secondary:hover {
    background-color: #f1f5f9;
}

.btn-secondary:focus-visible {
    outline-color: #64748b;
}

.btn-danger {
    background-color: #dc2626;
    color: #ffffff;
}

.btn-danger:hover {
    background-color: #b91c1c;
}

.btn-danger:focus-visible {
    outline-color: #dc2626;
    box-shadow: 0 0 0 4px rgba(220, 38, 38, 0.2);
}

/* Form wrapper for inline delete button */
form[style*="display:inline"] {
    margin: 0;
}

/* --- Table Styles --- */
table {
    width: 100%;
    border-collapse: collapse;
    background-color: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 8px; /* Rounded corners for the table */
    overflow: hidden; /* Ensures rounded corners apply to the whole table structure */
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    text-align: left;
}

thead {
    background-color: #f8fafc;
    border-bottom: 2px solid #e2e8f0;
}

th {
    padding: 1rem;
    font-weight: 600;
    color: #475569;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.025em;
}

td {
    padding: 1rem;
    border-bottom: 1px solid #e2e8f0;
    color: #334155;
    vertical-align: middle;
}

/* Hover effect on table rows */
tbody tr:hover {
    background-color: #f8fafc;
}

/* Remove bottom border on the last row */
tbody tr:last-child td {
    border-bottom: none;
}

/* --- Associated Positions List --- */
td ul {
    margin: 0;
    padding-left: 1.25rem;
    color: #475569;
}

td ul li {
    margin-bottom: 0.25rem;
}

td ul li:last-child {
    margin-bottom: 0;
}

td span {
    color: #94a3b8;
    font-style: italic;
}